@bendyline/squisq 0.1.2 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{themeLibrary-DySHPcgj.d.ts → Doc-1hmT1LZl.d.ts} +1 -42
- package/dist/__tests__/animationUtils.test.d.ts +2 -0
- package/dist/__tests__/animationUtils.test.d.ts.map +1 -0
- package/dist/__tests__/animationUtils.test.js +60 -0
- package/dist/__tests__/animationUtils.test.js.map +1 -0
- package/dist/__tests__/contentExtractor.test.d.ts +2 -0
- package/dist/__tests__/contentExtractor.test.d.ts.map +1 -0
- package/dist/__tests__/contentExtractor.test.js +151 -0
- package/dist/__tests__/contentExtractor.test.js.map +1 -0
- package/dist/__tests__/geohash.test.d.ts +2 -0
- package/dist/__tests__/geohash.test.d.ts.map +1 -0
- package/dist/__tests__/geohash.test.js +87 -0
- package/dist/__tests__/geohash.test.js.map +1 -0
- package/dist/__tests__/getLayers.test.d.ts +2 -0
- package/dist/__tests__/getLayers.test.d.ts.map +1 -0
- package/dist/__tests__/getLayers.test.js +167 -0
- package/dist/__tests__/getLayers.test.js.map +1 -0
- package/dist/__tests__/haversine.test.d.ts +2 -0
- package/dist/__tests__/haversine.test.d.ts.map +1 -0
- package/dist/__tests__/haversine.test.js +56 -0
- package/dist/__tests__/haversine.test.js.map +1 -0
- package/dist/__tests__/localForageAdapter.test.d.ts +8 -0
- package/dist/__tests__/localForageAdapter.test.d.ts.map +1 -0
- package/dist/__tests__/localForageAdapter.test.js +130 -0
- package/dist/__tests__/localForageAdapter.test.js.map +1 -0
- package/dist/__tests__/markdown.test.d.ts +2 -0
- package/dist/__tests__/markdown.test.d.ts.map +1 -0
- package/dist/__tests__/markdown.test.js +654 -0
- package/dist/__tests__/markdown.test.js.map +1 -0
- package/dist/__tests__/markdownToDoc.test.d.ts +2 -0
- package/dist/__tests__/markdownToDoc.test.d.ts.map +1 -0
- package/dist/__tests__/markdownToDoc.test.js +313 -0
- package/dist/__tests__/markdownToDoc.test.js.map +1 -0
- package/dist/__tests__/seededRandom.test.d.ts +2 -0
- package/dist/__tests__/seededRandom.test.d.ts.map +1 -0
- package/dist/__tests__/seededRandom.test.js +125 -0
- package/dist/__tests__/seededRandom.test.js.map +1 -0
- package/dist/__tests__/slideshowGenerator.test.d.ts +2 -0
- package/dist/__tests__/slideshowGenerator.test.d.ts.map +1 -0
- package/dist/__tests__/slideshowGenerator.test.js +114 -0
- package/dist/__tests__/slideshowGenerator.test.js.map +1 -0
- package/dist/__tests__/storage.test.d.ts +2 -0
- package/dist/__tests__/storage.test.d.ts.map +1 -0
- package/dist/__tests__/storage.test.js +51 -0
- package/dist/__tests__/storage.test.js.map +1 -0
- package/dist/__tests__/templates.test.d.ts +2 -0
- package/dist/__tests__/templates.test.d.ts.map +1 -0
- package/dist/__tests__/templates.test.js +217 -0
- package/dist/__tests__/templates.test.js.map +1 -0
- package/dist/__tests__/timing.test.d.ts +2 -0
- package/dist/__tests__/timing.test.d.ts.map +1 -0
- package/dist/__tests__/timing.test.js +131 -0
- package/dist/__tests__/timing.test.js.map +1 -0
- package/dist/chunk-3E5F2XMR.js +129 -0
- package/dist/chunk-3E5F2XMR.js.map +1 -0
- package/dist/chunk-6YJPI6VI.js +35 -0
- package/dist/chunk-6YJPI6VI.js.map +1 -0
- package/dist/chunk-FVTQSNR7.js +100 -0
- package/dist/chunk-FVTQSNR7.js.map +1 -0
- package/dist/chunk-V543AI2F.js +1 -0
- package/dist/chunk-V543AI2F.js.map +1 -0
- package/dist/chunk-VP5SZTZ2.js +792 -0
- package/dist/chunk-VP5SZTZ2.js.map +1 -0
- package/dist/doc/docToMarkdown.d.ts +41 -0
- package/dist/doc/docToMarkdown.d.ts.map +1 -0
- package/dist/doc/docToMarkdown.js +88 -0
- package/dist/doc/docToMarkdown.js.map +1 -0
- package/dist/doc/getLayers.d.ts +65 -0
- package/dist/doc/getLayers.d.ts.map +1 -0
- package/dist/doc/getLayers.js +103 -0
- package/dist/doc/getLayers.js.map +1 -0
- package/dist/doc/index.d.ts +9 -3
- package/dist/doc/index.d.ts.map +1 -0
- package/dist/doc/index.js +6 -125
- package/dist/doc/index.js.map +1 -1
- package/dist/doc/markdownToDoc.d.ts +68 -0
- package/dist/doc/markdownToDoc.d.ts.map +1 -0
- package/dist/doc/markdownToDoc.js +225 -0
- package/dist/doc/markdownToDoc.js.map +1 -0
- package/dist/doc/templates/accentImage.d.ts +59 -0
- package/dist/doc/templates/accentImage.d.ts.map +1 -0
- package/dist/doc/templates/accentImage.js +275 -0
- package/dist/doc/templates/accentImage.js.map +1 -0
- package/dist/doc/templates/captionUtils.d.ts +20 -0
- package/dist/doc/templates/captionUtils.d.ts.map +1 -0
- package/dist/doc/templates/captionUtils.js +29 -0
- package/dist/doc/templates/captionUtils.js.map +1 -0
- package/dist/doc/templates/comparisonBar.d.ts +13 -0
- package/dist/doc/templates/comparisonBar.d.ts.map +1 -0
- package/dist/doc/templates/comparisonBar.js +127 -0
- package/dist/doc/templates/comparisonBar.js.map +1 -0
- package/dist/doc/templates/coverBlock.d.ts +51 -0
- package/dist/doc/templates/coverBlock.d.ts.map +1 -0
- package/dist/doc/templates/coverBlock.js +125 -0
- package/dist/doc/templates/coverBlock.js.map +1 -0
- package/dist/doc/templates/dateEvent.d.ts +15 -0
- package/dist/doc/templates/dateEvent.d.ts.map +1 -0
- package/dist/doc/templates/dateEvent.js +110 -0
- package/dist/doc/templates/dateEvent.js.map +1 -0
- package/dist/doc/templates/definitionCard.d.ts +13 -0
- package/dist/doc/templates/definitionCard.d.ts.map +1 -0
- package/dist/doc/templates/definitionCard.js +114 -0
- package/dist/doc/templates/definitionCard.js.map +1 -0
- package/dist/doc/templates/factCard.d.ts +15 -0
- package/dist/doc/templates/factCard.d.ts.map +1 -0
- package/dist/doc/templates/factCard.js +100 -0
- package/dist/doc/templates/factCard.js.map +1 -0
- package/dist/doc/templates/fullBleedQuote.d.ts +13 -0
- package/dist/doc/templates/fullBleedQuote.d.ts.map +1 -0
- package/dist/doc/templates/fullBleedQuote.js +54 -0
- package/dist/doc/templates/fullBleedQuote.js.map +1 -0
- package/dist/doc/templates/imageWithCaption.d.ts +13 -0
- package/dist/doc/templates/imageWithCaption.d.ts.map +1 -0
- package/dist/doc/templates/imageWithCaption.js +142 -0
- package/dist/doc/templates/imageWithCaption.js.map +1 -0
- package/dist/doc/templates/index.d.ts +104 -0
- package/dist/doc/templates/index.d.ts.map +1 -0
- package/dist/doc/templates/index.js +442 -0
- package/dist/doc/templates/index.js.map +1 -0
- package/dist/doc/templates/listBlock.d.ts +13 -0
- package/dist/doc/templates/listBlock.d.ts.map +1 -0
- package/dist/doc/templates/listBlock.js +89 -0
- package/dist/doc/templates/listBlock.js.map +1 -0
- package/dist/doc/templates/mapBlock.d.ts +17 -0
- package/dist/doc/templates/mapBlock.d.ts.map +1 -0
- package/dist/doc/templates/mapBlock.js +112 -0
- package/dist/doc/templates/mapBlock.js.map +1 -0
- package/dist/doc/templates/persistentLayers.d.ts +39 -0
- package/dist/doc/templates/persistentLayers.d.ts.map +1 -0
- package/dist/doc/templates/persistentLayers.js +447 -0
- package/dist/doc/templates/persistentLayers.js.map +1 -0
- package/dist/doc/templates/photoGrid.d.ts +20 -0
- package/dist/doc/templates/photoGrid.d.ts.map +1 -0
- package/dist/doc/templates/photoGrid.js +172 -0
- package/dist/doc/templates/photoGrid.js.map +1 -0
- package/dist/doc/templates/pullQuote.d.ts +13 -0
- package/dist/doc/templates/pullQuote.d.ts.map +1 -0
- package/dist/doc/templates/pullQuote.js +109 -0
- package/dist/doc/templates/pullQuote.js.map +1 -0
- package/dist/doc/templates/quoteBlock.d.ts +15 -0
- package/dist/doc/templates/quoteBlock.d.ts.map +1 -0
- package/dist/doc/templates/quoteBlock.js +97 -0
- package/dist/doc/templates/quoteBlock.js.map +1 -0
- package/dist/doc/templates/sectionHeader.d.ts +14 -0
- package/dist/doc/templates/sectionHeader.d.ts.map +1 -0
- package/dist/doc/templates/sectionHeader.js +96 -0
- package/dist/doc/templates/sectionHeader.js.map +1 -0
- package/dist/doc/templates/statHighlight.d.ts +15 -0
- package/dist/doc/templates/statHighlight.d.ts.map +1 -0
- package/dist/doc/templates/statHighlight.js +99 -0
- package/dist/doc/templates/statHighlight.js.map +1 -0
- package/dist/doc/templates/titleBlock.d.ts +13 -0
- package/dist/doc/templates/titleBlock.d.ts.map +1 -0
- package/dist/doc/templates/titleBlock.js +92 -0
- package/dist/doc/templates/titleBlock.js.map +1 -0
- package/dist/doc/templates/twoColumn.d.ts +15 -0
- package/dist/doc/templates/twoColumn.d.ts.map +1 -0
- package/dist/doc/templates/twoColumn.js +219 -0
- package/dist/doc/templates/twoColumn.js.map +1 -0
- package/dist/doc/templates/videoPullQuote.d.ts +20 -0
- package/dist/doc/templates/videoPullQuote.d.ts.map +1 -0
- package/dist/doc/templates/videoPullQuote.js +118 -0
- package/dist/doc/templates/videoPullQuote.js.map +1 -0
- package/dist/doc/templates/videoWithCaption.d.ts +20 -0
- package/dist/doc/templates/videoWithCaption.d.ts.map +1 -0
- package/dist/doc/templates/videoWithCaption.js +104 -0
- package/dist/doc/templates/videoWithCaption.js.map +1 -0
- package/dist/doc/utils/animationUtils.d.ts +34 -0
- package/dist/doc/utils/animationUtils.d.ts.map +1 -0
- package/dist/doc/utils/animationUtils.js +110 -0
- package/dist/doc/utils/animationUtils.js.map +1 -0
- package/dist/doc/utils/themeUtils.d.ts +55 -0
- package/dist/doc/utils/themeUtils.d.ts.map +1 -0
- package/dist/doc/utils/themeUtils.js +109 -0
- package/dist/doc/utils/themeUtils.js.map +1 -0
- package/dist/generate/contentExtractor.d.ts +112 -0
- package/dist/generate/contentExtractor.d.ts.map +1 -0
- package/dist/generate/contentExtractor.js +638 -0
- package/dist/generate/contentExtractor.js.map +1 -0
- package/dist/generate/index.d.ts +7 -0
- package/dist/generate/index.d.ts.map +1 -0
- package/dist/generate/index.js +4 -0
- package/dist/generate/index.js.map +1 -0
- package/dist/generate/slideshowGenerator.d.ts +72 -0
- package/dist/generate/slideshowGenerator.d.ts.map +1 -0
- package/dist/generate/slideshowGenerator.js +159 -0
- package/dist/generate/slideshowGenerator.js.map +1 -0
- package/dist/generate/templateMapper.d.ts +23 -0
- package/dist/generate/templateMapper.d.ts.map +1 -0
- package/dist/generate/templateMapper.js +114 -0
- package/dist/generate/templateMapper.js.map +1 -0
- package/dist/index.d.ts +9 -8
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +8 -216
- package/dist/index.js.map +1 -1
- package/dist/markdown/convert.d.ts +71 -0
- package/dist/markdown/convert.d.ts.map +1 -0
- package/dist/markdown/convert.js +746 -0
- package/dist/markdown/convert.js.map +1 -0
- package/dist/markdown/htmlParse.d.ts +26 -0
- package/dist/markdown/htmlParse.d.ts.map +1 -0
- package/dist/markdown/htmlParse.js +195 -0
- package/dist/markdown/htmlParse.js.map +1 -0
- package/dist/markdown/index.d.ts +19 -225
- package/dist/markdown/index.d.ts.map +1 -0
- package/dist/markdown/index.js +33 -32
- package/dist/markdown/index.js.map +1 -1
- package/dist/markdown/parse.d.ts +27 -0
- package/dist/markdown/parse.d.ts.map +1 -0
- package/dist/markdown/parse.js +90 -0
- package/dist/markdown/parse.js.map +1 -0
- package/dist/markdown/stringify.d.ts +32 -0
- package/dist/markdown/stringify.d.ts.map +1 -0
- package/dist/markdown/stringify.js +108 -0
- package/dist/markdown/stringify.js.map +1 -0
- package/dist/markdown/types.d.ts +496 -0
- package/dist/markdown/types.d.ts.map +1 -0
- package/dist/markdown/types.js +17 -0
- package/dist/markdown/types.js.map +1 -0
- package/dist/markdown/utils.d.ts +78 -0
- package/dist/markdown/utils.d.ts.map +1 -0
- package/dist/markdown/utils.js +149 -0
- package/dist/markdown/utils.js.map +1 -0
- package/dist/random/SeededRandom.d.ts +50 -0
- package/dist/random/SeededRandom.d.ts.map +1 -0
- package/dist/random/SeededRandom.js +115 -0
- package/dist/random/SeededRandom.js.map +1 -0
- package/dist/random/index.d.ts +2 -0
- package/dist/random/index.d.ts.map +1 -0
- package/dist/random/index.js +2 -0
- package/dist/random/index.js.map +1 -0
- package/dist/schemas/BlockTemplates.d.ts +583 -0
- package/dist/schemas/BlockTemplates.d.ts.map +1 -0
- package/dist/schemas/BlockTemplates.js +72 -0
- package/dist/schemas/BlockTemplates.js.map +1 -0
- package/dist/schemas/Doc.d.ts +411 -0
- package/dist/schemas/Doc.d.ts.map +1 -0
- package/dist/schemas/Doc.js +90 -0
- package/dist/schemas/Doc.js.map +1 -0
- package/dist/schemas/LayoutStrategy.d.ts +84 -0
- package/dist/schemas/LayoutStrategy.d.ts.map +1 -0
- package/dist/schemas/LayoutStrategy.js +123 -0
- package/dist/schemas/LayoutStrategy.js.map +1 -0
- package/dist/schemas/MediaProvider.d.ts +65 -0
- package/dist/schemas/MediaProvider.d.ts.map +1 -0
- package/dist/schemas/MediaProvider.js +13 -0
- package/dist/schemas/MediaProvider.js.map +1 -0
- package/dist/schemas/Theme.d.ts +163 -0
- package/dist/schemas/Theme.d.ts.map +1 -0
- package/dist/schemas/Theme.js +62 -0
- package/dist/schemas/Theme.js.map +1 -0
- package/dist/schemas/Types.d.ts +14 -0
- package/dist/schemas/Types.d.ts.map +1 -0
- package/dist/schemas/Types.js +5 -0
- package/dist/schemas/Types.js.map +1 -0
- package/dist/schemas/Viewport.d.ts +74 -0
- package/dist/schemas/Viewport.d.ts.map +1 -0
- package/dist/schemas/Viewport.js +63 -0
- package/dist/schemas/Viewport.js.map +1 -0
- package/dist/schemas/index.d.ts +10 -70
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +7 -60
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/themeLibrary.d.ts +41 -0
- package/dist/schemas/themeLibrary.d.ts.map +1 -0
- package/dist/schemas/themeLibrary.js +466 -0
- package/dist/schemas/themeLibrary.js.map +1 -0
- package/dist/spatial/Geohash.d.ts +85 -0
- package/dist/spatial/Geohash.d.ts.map +1 -0
- package/dist/spatial/Geohash.js +142 -0
- package/dist/spatial/Geohash.js.map +1 -0
- package/dist/spatial/Haversine.d.ts +24 -0
- package/dist/spatial/Haversine.d.ts.map +1 -0
- package/dist/spatial/Haversine.js +48 -0
- package/dist/spatial/Haversine.js.map +1 -0
- package/dist/spatial/index.d.ts +3 -111
- package/dist/spatial/index.d.ts.map +1 -0
- package/dist/spatial/index.js +2 -24
- package/dist/spatial/index.js.map +1 -1
- package/dist/storage/LocalForageAdapter.d.ts +36 -0
- package/dist/storage/LocalForageAdapter.d.ts.map +1 -0
- package/dist/storage/LocalForageAdapter.js +82 -0
- package/dist/storage/LocalForageAdapter.js.map +1 -0
- package/dist/storage/LocalStorageAdapter.d.ts +16 -0
- package/dist/storage/LocalStorageAdapter.d.ts.map +1 -0
- package/dist/storage/LocalStorageAdapter.js +50 -0
- package/dist/storage/LocalStorageAdapter.js.map +1 -0
- package/dist/storage/MemoryStorageAdapter.d.ts +15 -0
- package/dist/storage/MemoryStorageAdapter.d.ts.map +1 -0
- package/dist/storage/MemoryStorageAdapter.js +34 -0
- package/dist/storage/MemoryStorageAdapter.js.map +1 -0
- package/dist/storage/Storage.d.ts +23 -0
- package/dist/storage/Storage.d.ts.map +1 -0
- package/dist/storage/Storage.js +9 -0
- package/dist/storage/Storage.js.map +1 -0
- package/dist/storage/index.d.ts +6 -91
- package/dist/storage/index.d.ts.map +1 -0
- package/dist/storage/index.js +3 -10
- package/dist/storage/index.js.map +1 -1
- package/dist/story/index.d.ts +3 -2
- package/dist/themeLibrary-DR1VRo-8.d.ts +44 -0
- package/dist/timing/index.d.ts +4 -0
- package/dist/timing/index.d.ts.map +1 -0
- package/dist/timing/index.js +3 -0
- package/dist/timing/index.js.map +1 -0
- package/dist/timing/narrationTiming.d.ts +54 -0
- package/dist/timing/narrationTiming.d.ts.map +1 -0
- package/dist/timing/narrationTiming.js +190 -0
- package/dist/timing/narrationTiming.js.map +1 -0
- package/dist/timing/readingTime.d.ts +54 -0
- package/dist/timing/readingTime.d.ts.map +1 -0
- package/dist/timing/readingTime.js +49 -0
- package/dist/timing/readingTime.js.map +1 -0
- package/package.json +17 -3
- package/src/__tests__/contentExtractor.test.ts +183 -0
- package/src/__tests__/seededRandom.test.ts +142 -0
- package/src/__tests__/slideshowGenerator.test.ts +128 -0
- package/src/__tests__/timing.test.ts +167 -0
- package/src/generate/contentExtractor.ts +808 -0
- package/src/generate/index.ts +21 -0
- package/src/generate/slideshowGenerator.ts +273 -0
- package/src/generate/templateMapper.ts +170 -0
- package/src/index.ts +3 -0
- package/src/random/SeededRandom.ts +127 -0
- package/src/random/index.ts +1 -0
- package/src/timing/index.ts +17 -0
- package/src/timing/narrationTiming.ts +220 -0
- package/src/timing/readingTime.ts +94 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* localStorage adapter for web browsers.
|
|
3
|
+
* Supports a configurable key prefix to namespace stored data.
|
|
4
|
+
*/
|
|
5
|
+
export class LocalStorageAdapter {
|
|
6
|
+
constructor(prefix = '') {
|
|
7
|
+
this.supportsEnumeration = true;
|
|
8
|
+
this.prefix = prefix;
|
|
9
|
+
}
|
|
10
|
+
async get(key) {
|
|
11
|
+
try {
|
|
12
|
+
const raw = localStorage.getItem(this.prefix + key);
|
|
13
|
+
if (raw === null)
|
|
14
|
+
return null;
|
|
15
|
+
return JSON.parse(raw);
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
return null;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
async set(key, value) {
|
|
22
|
+
localStorage.setItem(this.prefix + key, JSON.stringify(value));
|
|
23
|
+
}
|
|
24
|
+
async remove(key) {
|
|
25
|
+
localStorage.removeItem(this.prefix + key);
|
|
26
|
+
}
|
|
27
|
+
async clear() {
|
|
28
|
+
const keysToRemove = [];
|
|
29
|
+
for (let i = 0; i < localStorage.length; i++) {
|
|
30
|
+
const k = localStorage.key(i);
|
|
31
|
+
if (k && k.startsWith(this.prefix)) {
|
|
32
|
+
keysToRemove.push(k);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
for (const k of keysToRemove) {
|
|
36
|
+
localStorage.removeItem(k);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
async keys() {
|
|
40
|
+
const result = [];
|
|
41
|
+
for (let i = 0; i < localStorage.length; i++) {
|
|
42
|
+
const k = localStorage.key(i);
|
|
43
|
+
if (k && k.startsWith(this.prefix)) {
|
|
44
|
+
result.push(k.slice(this.prefix.length));
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
return result;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
//# sourceMappingURL=LocalStorageAdapter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LocalStorageAdapter.js","sourceRoot":"","sources":["../../src/storage/LocalStorageAdapter.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,MAAM,OAAO,mBAAmB;IAI9B,YAAY,MAAM,GAAG,EAAE;QAHd,wBAAmB,GAAG,IAAI,CAAC;QAIlC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED,KAAK,CAAC,GAAG,CAAI,GAAW;QACtB,IAAI,CAAC;YACH,MAAM,GAAG,GAAG,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,GAAG,GAAG,CAAC,CAAC;YACpD,IAAI,GAAG,KAAK,IAAI;gBAAE,OAAO,IAAI,CAAC;YAC9B,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAM,CAAC;QAC9B,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,IAAI,CAAC;QACd,CAAC;IACH,CAAC;IAED,KAAK,CAAC,GAAG,CAAI,GAAW,EAAE,KAAQ;QAChC,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,GAAG,GAAG,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;IACjE,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,GAAW;QACtB,YAAY,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,GAAG,GAAG,CAAC,CAAC;IAC7C,CAAC;IAED,KAAK,CAAC,KAAK;QACT,MAAM,YAAY,GAAa,EAAE,CAAC;QAClC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,YAAY,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YAC7C,MAAM,CAAC,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;YAC9B,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;gBACnC,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;YACvB,CAAC;QACH,CAAC;QACD,KAAK,MAAM,CAAC,IAAI,YAAY,EAAE,CAAC;YAC7B,YAAY,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;QAC7B,CAAC;IACH,CAAC;IAED,KAAK,CAAC,IAAI;QACR,MAAM,MAAM,GAAa,EAAE,CAAC;QAC5B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,YAAY,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YAC7C,MAAM,CAAC,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;YAC9B,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;gBACnC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;YAC3C,CAAC;QACH,CAAC;QACD,OAAO,MAAM,CAAC;IAChB,CAAC;CACF"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* In-memory storage adapter for testing and SSR environments.
|
|
3
|
+
* Data does not persist across page reloads.
|
|
4
|
+
*/
|
|
5
|
+
import type { StorageAdapter } from './Storage.js';
|
|
6
|
+
export declare class MemoryStorageAdapter implements StorageAdapter {
|
|
7
|
+
readonly supportsEnumeration = true;
|
|
8
|
+
private store;
|
|
9
|
+
get<T>(key: string): Promise<T | null>;
|
|
10
|
+
set<T>(key: string, value: T): Promise<void>;
|
|
11
|
+
remove(key: string): Promise<void>;
|
|
12
|
+
clear(): Promise<void>;
|
|
13
|
+
keys(): Promise<string[]>;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=MemoryStorageAdapter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MemoryStorageAdapter.d.ts","sourceRoot":"","sources":["../../src/storage/MemoryStorageAdapter.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAEnD,qBAAa,oBAAqB,YAAW,cAAc;IACzD,QAAQ,CAAC,mBAAmB,QAAQ;IACpC,OAAO,CAAC,KAAK,CAA6B;IAEpC,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC;IAUtC,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAI5C,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAIlC,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;IAItB,IAAI,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;CAGhC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* In-memory storage adapter for testing and SSR environments.
|
|
3
|
+
* Data does not persist across page reloads.
|
|
4
|
+
*/
|
|
5
|
+
export class MemoryStorageAdapter {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.supportsEnumeration = true;
|
|
8
|
+
this.store = new Map();
|
|
9
|
+
}
|
|
10
|
+
async get(key) {
|
|
11
|
+
const val = this.store.get(key);
|
|
12
|
+
if (val === undefined)
|
|
13
|
+
return null;
|
|
14
|
+
try {
|
|
15
|
+
return JSON.parse(val);
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
return null;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
async set(key, value) {
|
|
22
|
+
this.store.set(key, JSON.stringify(value));
|
|
23
|
+
}
|
|
24
|
+
async remove(key) {
|
|
25
|
+
this.store.delete(key);
|
|
26
|
+
}
|
|
27
|
+
async clear() {
|
|
28
|
+
this.store.clear();
|
|
29
|
+
}
|
|
30
|
+
async keys() {
|
|
31
|
+
return Array.from(this.store.keys());
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
//# sourceMappingURL=MemoryStorageAdapter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MemoryStorageAdapter.js","sourceRoot":"","sources":["../../src/storage/MemoryStorageAdapter.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,MAAM,OAAO,oBAAoB;IAAjC;QACW,wBAAmB,GAAG,IAAI,CAAC;QAC5B,UAAK,GAAG,IAAI,GAAG,EAAkB,CAAC;IA2B5C,CAAC;IAzBC,KAAK,CAAC,GAAG,CAAI,GAAW;QACtB,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QAChC,IAAI,GAAG,KAAK,SAAS;YAAE,OAAO,IAAI,CAAC;QACnC,IAAI,CAAC;YACH,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAM,CAAC;QAC9B,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,IAAI,CAAC;QACd,CAAC;IACH,CAAC;IAED,KAAK,CAAC,GAAG,CAAI,GAAW,EAAE,KAAQ;QAChC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;IAC7C,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,GAAW;QACtB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IACzB,CAAC;IAED,KAAK,CAAC,KAAK;QACT,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,IAAI;QACR,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;IACvC,CAAC;CACF"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Storage - Abstract persistence interface
|
|
3
|
+
*
|
|
4
|
+
* Defines the contract for persistent storage across different environments.
|
|
5
|
+
* All values are JSON-serialized, so any serializable value can be stored.
|
|
6
|
+
* Keys can be automatically namespaced with a configurable prefix.
|
|
7
|
+
*/
|
|
8
|
+
/** Storage adapter interface - implemented by environment-specific adapters */
|
|
9
|
+
export interface StorageAdapter {
|
|
10
|
+
/** Get a value by key, returns null if not found */
|
|
11
|
+
get<T>(key: string): Promise<T | null>;
|
|
12
|
+
/** Set a value for a key */
|
|
13
|
+
set<T>(key: string, value: T): Promise<void>;
|
|
14
|
+
/** Remove a value by key */
|
|
15
|
+
remove(key: string): Promise<void>;
|
|
16
|
+
/** Clear all stored values (within our namespace) */
|
|
17
|
+
clear(): Promise<void>;
|
|
18
|
+
/** Get all keys (within our namespace) */
|
|
19
|
+
keys(): Promise<string[]>;
|
|
20
|
+
/** Check if this adapter supports enumeration */
|
|
21
|
+
readonly supportsEnumeration: boolean;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=Storage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Storage.d.ts","sourceRoot":"","sources":["../../src/storage/Storage.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,+EAA+E;AAC/E,MAAM,WAAW,cAAc;IAC7B,oDAAoD;IACpD,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC;IAEvC,4BAA4B;IAC5B,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE7C,4BAA4B;IAC5B,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEnC,qDAAqD;IACrD,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAEvB,0CAA0C;IAC1C,IAAI,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;IAE1B,iDAAiD;IACjD,QAAQ,CAAC,mBAAmB,EAAE,OAAO,CAAC;CACvC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Storage - Abstract persistence interface
|
|
3
|
+
*
|
|
4
|
+
* Defines the contract for persistent storage across different environments.
|
|
5
|
+
* All values are JSON-serialized, so any serializable value can be stored.
|
|
6
|
+
* Keys can be automatically namespaced with a configurable prefix.
|
|
7
|
+
*/
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=Storage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Storage.js","sourceRoot":"","sources":["../../src/storage/Storage.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG"}
|
package/dist/storage/index.d.ts
CHANGED
|
@@ -1,91 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
*/
|
|
8
|
-
/** Storage adapter interface - implemented by environment-specific adapters */
|
|
9
|
-
interface StorageAdapter {
|
|
10
|
-
/** Get a value by key, returns null if not found */
|
|
11
|
-
get<T>(key: string): Promise<T | null>;
|
|
12
|
-
/** Set a value for a key */
|
|
13
|
-
set<T>(key: string, value: T): Promise<void>;
|
|
14
|
-
/** Remove a value by key */
|
|
15
|
-
remove(key: string): Promise<void>;
|
|
16
|
-
/** Clear all stored values (within our namespace) */
|
|
17
|
-
clear(): Promise<void>;
|
|
18
|
-
/** Get all keys (within our namespace) */
|
|
19
|
-
keys(): Promise<string[]>;
|
|
20
|
-
/** Check if this adapter supports enumeration */
|
|
21
|
-
readonly supportsEnumeration: boolean;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* In-memory storage adapter for testing and SSR environments.
|
|
26
|
-
* Data does not persist across page reloads.
|
|
27
|
-
*/
|
|
28
|
-
|
|
29
|
-
declare class MemoryStorageAdapter implements StorageAdapter {
|
|
30
|
-
readonly supportsEnumeration = true;
|
|
31
|
-
private store;
|
|
32
|
-
get<T>(key: string): Promise<T | null>;
|
|
33
|
-
set<T>(key: string, value: T): Promise<void>;
|
|
34
|
-
remove(key: string): Promise<void>;
|
|
35
|
-
clear(): Promise<void>;
|
|
36
|
-
keys(): Promise<string[]>;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* localStorage adapter for web browsers.
|
|
41
|
-
* Supports a configurable key prefix to namespace stored data.
|
|
42
|
-
*/
|
|
43
|
-
|
|
44
|
-
declare class LocalStorageAdapter implements StorageAdapter {
|
|
45
|
-
readonly supportsEnumeration = true;
|
|
46
|
-
private prefix;
|
|
47
|
-
constructor(prefix?: string);
|
|
48
|
-
get<T>(key: string): Promise<T | null>;
|
|
49
|
-
set<T>(key: string, value: T): Promise<void>;
|
|
50
|
-
remove(key: string): Promise<void>;
|
|
51
|
-
clear(): Promise<void>;
|
|
52
|
-
keys(): Promise<string[]>;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* LocalForage adapter - IndexedDB storage with automatic fallbacks.
|
|
57
|
-
*
|
|
58
|
-
* Uses localforage which provides IndexedDB storage with automatic
|
|
59
|
-
* fallbacks to WebSQL and localStorage. This allows storing much more
|
|
60
|
-
* data than raw localStorage (which is limited to ~5MB).
|
|
61
|
-
*
|
|
62
|
-
* Unlike LocalStorageAdapter, this adapter can store binary data
|
|
63
|
-
* (ArrayBuffer, Blob, Uint8Array) natively without JSON serialization.
|
|
64
|
-
*
|
|
65
|
-
* Ported from qualla-internal/shared/services/StorageAdapters.ts with
|
|
66
|
-
* configurable store name and key prefix.
|
|
67
|
-
*/
|
|
68
|
-
|
|
69
|
-
interface LocalForageAdapterOptions {
|
|
70
|
-
/** IndexedDB database name (default: 'squisq') */
|
|
71
|
-
name?: string;
|
|
72
|
-
/** IndexedDB object store name (default: 'data') */
|
|
73
|
-
storeName?: string;
|
|
74
|
-
/** Key prefix for namespacing (default: '') */
|
|
75
|
-
prefix?: string;
|
|
76
|
-
/** Human-readable description (default: 'Squisq storage') */
|
|
77
|
-
description?: string;
|
|
78
|
-
}
|
|
79
|
-
declare class LocalForageAdapter implements StorageAdapter {
|
|
80
|
-
readonly supportsEnumeration = true;
|
|
81
|
-
private store;
|
|
82
|
-
private prefix;
|
|
83
|
-
constructor(options?: LocalForageAdapterOptions);
|
|
84
|
-
get<T>(key: string): Promise<T | null>;
|
|
85
|
-
set<T>(key: string, value: T): Promise<void>;
|
|
86
|
-
remove(key: string): Promise<void>;
|
|
87
|
-
clear(): Promise<void>;
|
|
88
|
-
keys(): Promise<string[]>;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
export { LocalForageAdapter, type LocalForageAdapterOptions, LocalStorageAdapter, MemoryStorageAdapter, type StorageAdapter };
|
|
1
|
+
export type { StorageAdapter } from './Storage.js';
|
|
2
|
+
export { MemoryStorageAdapter } from './MemoryStorageAdapter.js';
|
|
3
|
+
export { LocalStorageAdapter } from './LocalStorageAdapter.js';
|
|
4
|
+
export { LocalForageAdapter } from './LocalForageAdapter.js';
|
|
5
|
+
export type { LocalForageAdapterOptions } from './LocalForageAdapter.js';
|
|
6
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/storage/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,YAAY,EAAE,yBAAyB,EAAE,MAAM,yBAAyB,CAAC"}
|
package/dist/storage/index.js
CHANGED
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
MemoryStorageAdapter
|
|
5
|
-
} from "../chunk-VJN7UB2Z.js";
|
|
6
|
-
export {
|
|
7
|
-
LocalForageAdapter,
|
|
8
|
-
LocalStorageAdapter,
|
|
9
|
-
MemoryStorageAdapter
|
|
10
|
-
};
|
|
1
|
+
export { MemoryStorageAdapter } from './MemoryStorageAdapter.js';
|
|
2
|
+
export { LocalStorageAdapter } from './LocalStorageAdapter.js';
|
|
3
|
+
export { LocalForageAdapter } from './LocalForageAdapter.js';
|
|
11
4
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/storage/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC"}
|
package/dist/story/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { x as PersistentLayer, L as Layer, y as PersistentLayerConfig, a6 as TitleBlockInput, Y as TemplateContext, S as SectionHeaderInput, W as StatHighlightInput, Q as QuoteBlockInput, F as FactCardInput, aa as TwoColumnInput, k as DateEventInput, r as ImageWithCaptionInput, M as MapBlockInput, V as StartBlockConfig, p as FullBleedQuoteInput, t as ListBlockInput, J as PhotoGridInput, m as DefinitionCardInput, h as ComparisonBarInput, O as PullQuoteInput, ae as VideoWithCaptionInput, ad as VideoPullQuoteInput, A as AccentImage, a as AccentPosition, a1 as Theme, af as ViewportConfig, o as DocBlock, B as Block, X as TemplateBlock, _ as TemplateRegistry, b as Animation, c as AnimationType, a9 as TransitionType, a3 as ThemeColorScheme, n as Doc } from '../Doc-1hmT1LZl.js';
|
|
2
|
+
export { s as LayoutHints, R as RenderStyle, a2 as ThemeColorPalette, a4 as ThemeStyle, a5 as ThemeTypography, ab as VIEWPORT_PRESETS, ag as ViewportOrientation, ah as ViewportPreset, ak as createTemplateContext, ap as getLayoutHints, as as getTwoColumnPositions, at as getViewport, au as getViewportOrientation, aw as isTemplateBlock, ay as scaledFontSize } from '../Doc-1hmT1LZl.js';
|
|
3
3
|
import { p as MarkdownHeading, l as MarkdownDocument } from '../types-DHiv_Pnm.js';
|
|
4
|
+
export { D as DEFAULT_THEME, g as getAvailableThemes, b as getThemeSummaries, r as resolveTheme } from '../themeLibrary-DR1VRo-8.js';
|
|
4
5
|
|
|
5
6
|
/**
|
|
6
7
|
* Persistent Layers Expansion
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { a1 as Theme } from './Doc-1hmT1LZl.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Built-in Theme Library
|
|
5
|
+
*
|
|
6
|
+
* Ships 8 curated themes covering documentary, editorial, minimal, and
|
|
7
|
+
* cinematic styles. Each theme is fully JSON-serializable.
|
|
8
|
+
*
|
|
9
|
+
* Usage:
|
|
10
|
+
* ```ts
|
|
11
|
+
* import { THEMES, resolveTheme } from '@bendyline/squisq/schemas';
|
|
12
|
+
*
|
|
13
|
+
* const theme = resolveTheme('minimalist'); // look up by id
|
|
14
|
+
* const theme = THEMES.documentary; // direct access
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* All built-in themes, keyed by id.
|
|
20
|
+
*/
|
|
21
|
+
declare const THEMES: Record<string, Theme>;
|
|
22
|
+
/** The default theme id. */
|
|
23
|
+
declare const DEFAULT_THEME_ID = "documentary";
|
|
24
|
+
/** The default theme (documentary — migrated from old DEFAULT_THEME). */
|
|
25
|
+
declare const DEFAULT_THEME: Theme;
|
|
26
|
+
/**
|
|
27
|
+
* Resolve a theme by id. Returns the default theme when `id` is
|
|
28
|
+
* undefined or not found in the library.
|
|
29
|
+
*/
|
|
30
|
+
declare function resolveTheme(id: string | undefined): Theme;
|
|
31
|
+
/**
|
|
32
|
+
* Get all available theme ids.
|
|
33
|
+
*/
|
|
34
|
+
declare function getAvailableThemes(): string[];
|
|
35
|
+
/**
|
|
36
|
+
* Get a summary of all themes (id + name + description) for theme pickers.
|
|
37
|
+
*/
|
|
38
|
+
declare function getThemeSummaries(): Array<{
|
|
39
|
+
id: string;
|
|
40
|
+
name: string;
|
|
41
|
+
description?: string;
|
|
42
|
+
}>;
|
|
43
|
+
|
|
44
|
+
export { DEFAULT_THEME as D, THEMES as T, DEFAULT_THEME_ID as a, getThemeSummaries as b, getAvailableThemes as g, resolveTheme as r };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { DEFAULT_WORDS_PER_SECOND, estimateSpokenWordCount, countSpokenWords, estimateTimeFromText, calculatePrefixDuration, estimateNarrationDuration, } from './narrationTiming.js';
|
|
2
|
+
export { estimateReadingTime, estimateNarrationTime } from './readingTime.js';
|
|
3
|
+
export type { ReadingTimeEstimate, ReadingTimeOptions, NarrationTimeEstimate, NarrationTimeOptions, } from './readingTime.js';
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/timing/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,uBAAuB,EACvB,gBAAgB,EAChB,oBAAoB,EACpB,uBAAuB,EACvB,yBAAyB,GAC1B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAE9E,YAAY,EACV,mBAAmB,EACnB,kBAAkB,EAClB,qBAAqB,EACrB,oBAAoB,GACrB,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { DEFAULT_WORDS_PER_SECOND, estimateSpokenWordCount, countSpokenWords, estimateTimeFromText, calculatePrefixDuration, estimateNarrationDuration, } from './narrationTiming.js';
|
|
2
|
+
export { estimateReadingTime, estimateNarrationTime } from './readingTime.js';
|
|
3
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/timing/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,uBAAuB,EACvB,gBAAgB,EAChB,oBAAoB,EACpB,uBAAuB,EACvB,yBAAyB,GAC1B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Narration timing estimation.
|
|
3
|
+
*
|
|
4
|
+
* Estimates how long text takes to speak aloud, accounting for:
|
|
5
|
+
* - Numbers spoken as multiple words (e.g., "1910" → "nineteen ten")
|
|
6
|
+
* - Pauses at commas
|
|
7
|
+
* - Year pronunciation conventions (1000–2099)
|
|
8
|
+
*
|
|
9
|
+
* Ported from qualla-internal's AudioTiming.ts (pure functions, no Node.js deps).
|
|
10
|
+
*/
|
|
11
|
+
/** Default speaking rate in words per second (~150 WPM). */
|
|
12
|
+
export declare const DEFAULT_WORDS_PER_SECOND = 2.5;
|
|
13
|
+
/**
|
|
14
|
+
* Estimate how many "spoken word equivalents" a single token represents.
|
|
15
|
+
* Numbers get expanded (e.g., "175,000" → ~5 words × 1.3 multiplier).
|
|
16
|
+
*/
|
|
17
|
+
export declare function estimateSpokenWordCount(token: string): number;
|
|
18
|
+
/**
|
|
19
|
+
* Count "spoken word equivalents" in a block of text,
|
|
20
|
+
* expanding numbers and adding comma pauses.
|
|
21
|
+
*/
|
|
22
|
+
export declare function countSpokenWords(text: string): number;
|
|
23
|
+
/**
|
|
24
|
+
* Estimate audio time at a character offset using word-proportion mapping.
|
|
25
|
+
*
|
|
26
|
+
* Given the full source text and a character position, returns the
|
|
27
|
+
* estimated time (in seconds) at which that position would be spoken.
|
|
28
|
+
*
|
|
29
|
+
* @param text - Full source text
|
|
30
|
+
* @param charOffset - Character offset to estimate timing for
|
|
31
|
+
* @param totalDuration - Total audio duration in seconds
|
|
32
|
+
* @returns Estimated time in seconds
|
|
33
|
+
*/
|
|
34
|
+
export declare function estimateTimeFromText(text: string, charOffset: number, totalDuration: number): number;
|
|
35
|
+
/**
|
|
36
|
+
* Estimate how long a spoken prefix adds to audio duration.
|
|
37
|
+
*
|
|
38
|
+
* When audio includes a spoken title or header before the main content,
|
|
39
|
+
* this calculates the extra duration to offset timing calculations.
|
|
40
|
+
*
|
|
41
|
+
* @param prefix - Prefix text (e.g., an article title spoken before the body)
|
|
42
|
+
* @param wordsPerSecond - Speaking rate (default: 2.5)
|
|
43
|
+
* @returns Estimated duration in seconds
|
|
44
|
+
*/
|
|
45
|
+
export declare function calculatePrefixDuration(prefix: string, wordsPerSecond?: number): number;
|
|
46
|
+
/**
|
|
47
|
+
* Estimate narration duration for a block of text.
|
|
48
|
+
*
|
|
49
|
+
* @param text - The text to estimate
|
|
50
|
+
* @param wordsPerSecond - Speaking rate (default: 2.5, i.e. ~150 WPM)
|
|
51
|
+
* @returns Duration in seconds
|
|
52
|
+
*/
|
|
53
|
+
export declare function estimateNarrationDuration(text: string, wordsPerSecond?: number): number;
|
|
54
|
+
//# sourceMappingURL=narrationTiming.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"narrationTiming.d.ts","sourceRoot":"","sources":["../../src/timing/narrationTiming.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAQH,4DAA4D;AAC5D,eAAO,MAAM,wBAAwB,MAAM,CAAC;AAE5C;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAS7D;AA4FD;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CA4BrD;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,MAAM,EAClB,aAAa,EAAE,MAAM,GACpB,MAAM,CAOR;AAED;;;;;;;;;GASG;AACH,wBAAgB,uBAAuB,CACrC,MAAM,EAAE,MAAM,EACd,cAAc,GAAE,MAAiC,GAChD,MAAM,CAQR;AAED;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,IAAI,EAAE,MAAM,EACZ,cAAc,GAAE,MAAiC,GAChD,MAAM,CAGR"}
|
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Narration timing estimation.
|
|
3
|
+
*
|
|
4
|
+
* Estimates how long text takes to speak aloud, accounting for:
|
|
5
|
+
* - Numbers spoken as multiple words (e.g., "1910" → "nineteen ten")
|
|
6
|
+
* - Pauses at commas
|
|
7
|
+
* - Year pronunciation conventions (1000–2099)
|
|
8
|
+
*
|
|
9
|
+
* Ported from qualla-internal's AudioTiming.ts (pure functions, no Node.js deps).
|
|
10
|
+
*/
|
|
11
|
+
/** Numbers are spoken more slowly than regular words (1.3× multiplier). */
|
|
12
|
+
const NUMBER_SPEAKING_MULTIPLIER = 1.3;
|
|
13
|
+
/** Comma pause in "word equivalents" — speakers pause ~0.3 words at commas. */
|
|
14
|
+
const COMMA_PAUSE_PENALTY = 0.3;
|
|
15
|
+
/** Default speaking rate in words per second (~150 WPM). */
|
|
16
|
+
export const DEFAULT_WORDS_PER_SECOND = 2.5;
|
|
17
|
+
/**
|
|
18
|
+
* Estimate how many "spoken word equivalents" a single token represents.
|
|
19
|
+
* Numbers get expanded (e.g., "175,000" → ~5 words × 1.3 multiplier).
|
|
20
|
+
*/
|
|
21
|
+
export function estimateSpokenWordCount(token) {
|
|
22
|
+
const cleaned = token.replace(/,/g, '');
|
|
23
|
+
const num = parseFloat(cleaned);
|
|
24
|
+
if (isNaN(num) || !isFinite(num)) {
|
|
25
|
+
return 1; // Not a number — count as 1 word
|
|
26
|
+
}
|
|
27
|
+
return estimateNumberWordCount(cleaned, num) * NUMBER_SPEAKING_MULTIPLIER;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Raw word count for a number (before the speaking multiplier).
|
|
31
|
+
*/
|
|
32
|
+
function estimateNumberWordCount(cleaned, num) {
|
|
33
|
+
// Handle decimals: "3.14" → words("3") + "point" + 2 digits
|
|
34
|
+
if (cleaned.includes('.')) {
|
|
35
|
+
const [whole, decimal] = cleaned.split('.');
|
|
36
|
+
const wholeNum = parseFloat(whole) || 0;
|
|
37
|
+
return estimateNumberWordCount(whole, wholeNum) + 1 + decimal.length;
|
|
38
|
+
}
|
|
39
|
+
const absNum = Math.abs(num);
|
|
40
|
+
let words = num < 0 ? 1 : 0; // "negative" / "minus"
|
|
41
|
+
if (absNum === 0)
|
|
42
|
+
return 1; // "zero"
|
|
43
|
+
// Years (1000–2099) are spoken as two two-digit groups:
|
|
44
|
+
// "1910" → "nineteen ten", "2024" → "twenty twenty-four"
|
|
45
|
+
if (absNum >= 1000 && absNum <= 2099 && Number.isInteger(absNum)) {
|
|
46
|
+
const yearStr = absNum.toString();
|
|
47
|
+
if (yearStr.length === 4) {
|
|
48
|
+
const firstTwo = parseInt(yearStr.slice(0, 2));
|
|
49
|
+
const lastTwo = parseInt(yearStr.slice(2));
|
|
50
|
+
// First part
|
|
51
|
+
if (firstTwo >= 10 && firstTwo <= 19) {
|
|
52
|
+
words += 1;
|
|
53
|
+
}
|
|
54
|
+
else if (firstTwo >= 20 && firstTwo <= 99) {
|
|
55
|
+
words += firstTwo % 10 === 0 ? 1 : 2;
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
words += 2; // "two thousand"
|
|
59
|
+
}
|
|
60
|
+
// Second part
|
|
61
|
+
if (lastTwo === 0) {
|
|
62
|
+
if (firstTwo >= 10 && firstTwo <= 99 && firstTwo !== 20) {
|
|
63
|
+
words += 1; // "hundred"
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
else if (lastTwo >= 1 && lastTwo <= 9) {
|
|
67
|
+
words += 2; // "oh five"
|
|
68
|
+
}
|
|
69
|
+
else if (lastTwo >= 10 && lastTwo <= 19) {
|
|
70
|
+
words += 1;
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
words += lastTwo % 10 === 0 ? 1 : 2;
|
|
74
|
+
}
|
|
75
|
+
return Math.max(words, 2);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
// General number handling — each magnitude group adds words
|
|
79
|
+
let remaining = absNum;
|
|
80
|
+
if (remaining >= 1000000000) {
|
|
81
|
+
const billions = Math.floor(remaining / 1000000000);
|
|
82
|
+
words += estimateNumberWordCount(String(billions), billions);
|
|
83
|
+
words += 1; // "billion"
|
|
84
|
+
remaining %= 1000000000;
|
|
85
|
+
}
|
|
86
|
+
if (remaining >= 1000000) {
|
|
87
|
+
const millions = Math.floor(remaining / 1000000);
|
|
88
|
+
words += estimateNumberWordCount(String(millions), millions);
|
|
89
|
+
words += 1; // "million"
|
|
90
|
+
remaining %= 1000000;
|
|
91
|
+
}
|
|
92
|
+
if (remaining >= 1000) {
|
|
93
|
+
const thousands = Math.floor(remaining / 1000);
|
|
94
|
+
words += estimateNumberWordCount(String(thousands), thousands);
|
|
95
|
+
words += 1; // "thousand"
|
|
96
|
+
remaining %= 1000;
|
|
97
|
+
}
|
|
98
|
+
if (remaining >= 100) {
|
|
99
|
+
words += 2; // digit + "hundred"
|
|
100
|
+
remaining %= 100;
|
|
101
|
+
}
|
|
102
|
+
if (remaining >= 1) {
|
|
103
|
+
if (remaining >= 20) {
|
|
104
|
+
words += remaining % 10 === 0 ? 1 : 2;
|
|
105
|
+
}
|
|
106
|
+
else {
|
|
107
|
+
words += 1; // 1–19
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
return Math.max(words, 1);
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Count "spoken word equivalents" in a block of text,
|
|
114
|
+
* expanding numbers and adding comma pauses.
|
|
115
|
+
*/
|
|
116
|
+
export function countSpokenWords(text) {
|
|
117
|
+
const tokens = text.split(/\s+/).filter((w) => w.length > 0);
|
|
118
|
+
let count = 0;
|
|
119
|
+
for (const token of tokens) {
|
|
120
|
+
// Strip punctuation only at token boundaries so internal punctuation
|
|
121
|
+
// (e.g., decimals like "3.14" or digit-grouping commas "1,000") is preserved.
|
|
122
|
+
const stripped = token.replace(/^[.,!?;:'"()[\]{}]+|[.,!?;:'"()[\]{}]+$/g, '');
|
|
123
|
+
count += estimateSpokenWordCount(stripped);
|
|
124
|
+
// Count only punctuation commas for pauses: exclude digit-grouping commas
|
|
125
|
+
// (i.e., commas with digits on both sides, like in "1,234").
|
|
126
|
+
let punctuationCommaCount = 0;
|
|
127
|
+
for (let i = 0; i < token.length; i++) {
|
|
128
|
+
if (token[i] === ',') {
|
|
129
|
+
const prev = i > 0 ? token[i - 1] : '';
|
|
130
|
+
const next = i < token.length - 1 ? token[i + 1] : '';
|
|
131
|
+
const prevIsDigit = prev >= '0' && prev <= '9';
|
|
132
|
+
const nextIsDigit = next >= '0' && next <= '9';
|
|
133
|
+
if (!(prevIsDigit && nextIsDigit)) {
|
|
134
|
+
punctuationCommaCount++;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
count += punctuationCommaCount * COMMA_PAUSE_PENALTY;
|
|
139
|
+
}
|
|
140
|
+
return count;
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Estimate audio time at a character offset using word-proportion mapping.
|
|
144
|
+
*
|
|
145
|
+
* Given the full source text and a character position, returns the
|
|
146
|
+
* estimated time (in seconds) at which that position would be spoken.
|
|
147
|
+
*
|
|
148
|
+
* @param text - Full source text
|
|
149
|
+
* @param charOffset - Character offset to estimate timing for
|
|
150
|
+
* @param totalDuration - Total audio duration in seconds
|
|
151
|
+
* @returns Estimated time in seconds
|
|
152
|
+
*/
|
|
153
|
+
export function estimateTimeFromText(text, charOffset, totalDuration) {
|
|
154
|
+
const textBefore = text.slice(0, charOffset);
|
|
155
|
+
const spokenWordsBefore = countSpokenWords(textBefore);
|
|
156
|
+
const totalSpokenWords = countSpokenWords(text);
|
|
157
|
+
if (totalSpokenWords === 0)
|
|
158
|
+
return 0;
|
|
159
|
+
return (spokenWordsBefore / totalSpokenWords) * totalDuration;
|
|
160
|
+
}
|
|
161
|
+
/**
|
|
162
|
+
* Estimate how long a spoken prefix adds to audio duration.
|
|
163
|
+
*
|
|
164
|
+
* When audio includes a spoken title or header before the main content,
|
|
165
|
+
* this calculates the extra duration to offset timing calculations.
|
|
166
|
+
*
|
|
167
|
+
* @param prefix - Prefix text (e.g., an article title spoken before the body)
|
|
168
|
+
* @param wordsPerSecond - Speaking rate (default: 2.5)
|
|
169
|
+
* @returns Estimated duration in seconds
|
|
170
|
+
*/
|
|
171
|
+
export function calculatePrefixDuration(prefix, wordsPerSecond = DEFAULT_WORDS_PER_SECOND) {
|
|
172
|
+
if (!prefix)
|
|
173
|
+
return 0;
|
|
174
|
+
const words = prefix.split(/\s+/).filter((w) => w.length > 0);
|
|
175
|
+
const newlineCount = (prefix.match(/\n\n/g) || []).length;
|
|
176
|
+
const pauseTime = newlineCount * 0.5;
|
|
177
|
+
return words.length / wordsPerSecond + pauseTime;
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* Estimate narration duration for a block of text.
|
|
181
|
+
*
|
|
182
|
+
* @param text - The text to estimate
|
|
183
|
+
* @param wordsPerSecond - Speaking rate (default: 2.5, i.e. ~150 WPM)
|
|
184
|
+
* @returns Duration in seconds
|
|
185
|
+
*/
|
|
186
|
+
export function estimateNarrationDuration(text, wordsPerSecond = DEFAULT_WORDS_PER_SECOND) {
|
|
187
|
+
const spokenWords = countSpokenWords(text);
|
|
188
|
+
return spokenWords / wordsPerSecond;
|
|
189
|
+
}
|
|
190
|
+
//# sourceMappingURL=narrationTiming.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"narrationTiming.js","sourceRoot":"","sources":["../../src/timing/narrationTiming.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,2EAA2E;AAC3E,MAAM,0BAA0B,GAAG,GAAG,CAAC;AAEvC,+EAA+E;AAC/E,MAAM,mBAAmB,GAAG,GAAG,CAAC;AAEhC,4DAA4D;AAC5D,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,CAAC;AAE5C;;;GAGG;AACH,MAAM,UAAU,uBAAuB,CAAC,KAAa;IACnD,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;IACxC,MAAM,GAAG,GAAG,UAAU,CAAC,OAAO,CAAC,CAAC;IAEhC,IAAI,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QACjC,OAAO,CAAC,CAAC,CAAC,iCAAiC;IAC7C,CAAC;IAED,OAAO,uBAAuB,CAAC,OAAO,EAAE,GAAG,CAAC,GAAG,0BAA0B,CAAC;AAC5E,CAAC;AAED;;GAEG;AACH,SAAS,uBAAuB,CAAC,OAAe,EAAE,GAAW;IAC3D,4DAA4D;IAC5D,IAAI,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC1B,MAAM,CAAC,KAAK,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,KAAK,CAAC,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