Skip to content

armgit / mimik

Public Imported from GitHub
0

🎬 A browser extension and desktop app that turns your clicks into step-by-step guides with annotated screenshots πŸ“–

chore(guides): declare the guide merge table

davbio894b2826108f
diff --git a/src/core/guides/db.ts b/src/core/guides/db.ts
index 4ca63db..433c72e 100644
--- a/src/core/guides/db.ts
+++ b/src/core/guides/db.ts
@@ -1,5 +1,5 @@
import Dexie, { type EntityTable } from 'dexie';
-import type { Guide, GuideTranscript, Screenshot, Snapshot, Step, VoiceClip } from './types';
+import type { Guide, GuideMerge, GuideTranscript, Screenshot, Snapshot, Step, VoiceClip } from './types';
export class MimikDB extends Dexie {
guides!: EntityTable<Guide, 'id'>;
@@ -8,6 +8,7 @@ export class MimikDB extends Dexie {
snapshots!: EntityTable<Snapshot, 'id'>;
voiceClips!: EntityTable<VoiceClip, 'id'>;
transcripts!: EntityTable<GuideTranscript, 'id'>;
+ guideMerges!: EntityTable<GuideMerge, 'id'>;
constructor() {
super('mimik');
@@ -25,6 +26,9 @@ export class MimikDB extends Dexie {
this.version(4).stores({
transcripts: 'id, guideId, [guideId+epochMs]',
});
+ this.version(5).stores({
+ guideMerges: 'id, targetGuideId, mergedAt',
+ });
}
}
diff --git a/src/core/guides/types.ts b/src/core/guides/types.ts
index a9ceffc..f7eccaf 100644
--- a/src/core/guides/types.ts
+++ b/src/core/guides/types.ts
@@ -122,6 +122,12 @@ export interface GuideTranscript {
lines: TranscriptLine[];
}
+export interface GuideMerge {
+ id: string;
+ targetGuideId: string;
+ mergedAt: number;
+}
+
export interface VoiceClip {
id: string;
bytes: ArrayBuffer;