refactor: simplify screen recording code

- Fix vite output path (was broken lib/background.mjs, now background.js)
- Import recording types from protocol.ts instead of duplicating in background.ts
- Remove dead getSessionId() and unused sessionId params from screen-recording.ts
- Replace 4 executor wrapper functions with single withRecordingDefaults helper
- Fix binary chunk routing with lastRecordingMetadataTabId tracking
- Add ExtensionStopRecordingResult type for proper extension/relay separation

Saves ~56 lines while improving correctness of multi-tab recording.
This commit is contained in:
Tommy D. Rossi
2026-01-24 15:48:52 +01:00
parent 3b5427ebe8
commit 8449006e59
6 changed files with 64 additions and 116 deletions
+1 -6
View File
@@ -58,12 +58,7 @@ export default defineConfig({
welcome: resolve(__dirname, 'src/welcome.html'),
},
output: {
entryFileNames: (chunkInfo) => {
if (chunkInfo.name === 'background') {
return 'lib/background.mjs';
}
return '[name].js';
},
entryFileNames: '[name].js',
format: 'es',
},
},