@bendyline/squisq 2.8.0 → 2.10.0

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.
Files changed (30) hide show
  1. package/dist/{Doc-DBadkoP4.d.ts → Doc-DTyeaFuW.d.ts} +1 -1
  2. package/dist/{ImageEditDoc-Cq2a3c30.d.ts → ImageEditDoc-dFEclQ9l.d.ts} +1 -1
  3. package/dist/{annotationCoercion-CPHEggo3.d.ts → annotationCoercion-Ckqpu33y.d.ts} +1 -1
  4. package/dist/{chunk-V6NV4GDE.js → chunk-DRFJU4MK.js} +1948 -1832
  5. package/dist/{chunk-HXMV7WQB.js → chunk-IO5XO6XH.js} +1 -1
  6. package/dist/{chunk-6MVWWZHL.js → chunk-MIKKUKOD.js} +88 -2
  7. package/dist/{chunk-KEAU5NEM.js → chunk-NFHMHYUV.js} +107 -2
  8. package/dist/chunk-T3B4WJBR.js +167 -0
  9. package/dist/{chunk-PTK2SW2V.js → chunk-XSW4QTMB.js} +272 -4
  10. package/dist/doc/index.d.ts +88 -10
  11. package/dist/doc/index.js +11 -3
  12. package/dist/fence/index.d.ts +2 -2
  13. package/dist/generate/index.d.ts +2 -2
  14. package/dist/imageEdit/index.d.ts +4 -4
  15. package/dist/index.d.ts +9 -8
  16. package/dist/index.js +51 -5
  17. package/dist/jsonForm/index.d.ts +2 -2
  18. package/dist/markdown/index.d.ts +3 -3
  19. package/dist/markdown/index.js +2 -2
  20. package/dist/{materializePageSection-Rss5thAj.d.ts → materializePageSection-BRNIINlU.d.ts} +2 -2
  21. package/dist/narration/index.d.ts +109 -4
  22. package/dist/narration/index.js +10 -2
  23. package/dist/proof/index.d.ts +179 -0
  24. package/dist/proof/index.js +32 -0
  25. package/dist/recommend/index.d.ts +1 -1
  26. package/dist/schemas/index.d.ts +5 -5
  27. package/dist/{themeLibrary-8BQMY2HV.d.ts → themeLibrary-xaxN5UYu.d.ts} +1 -1
  28. package/dist/transform/index.d.ts +3 -3
  29. package/dist/{types-CcrDFdWH.d.ts → types-Be6sBUBx.d.ts} +28 -2
  30. package/package.json +6 -1
@@ -0,0 +1,179 @@
1
+ /**
2
+ * Plain-data types for the proofing (grammar + spellcheck) pipeline.
3
+ *
4
+ * These types are engine-agnostic: an editor host adapts a concrete
5
+ * engine (harper.js, a service, a test fake) to produce `ProofFinding`s,
6
+ * while this module stays pure and dependency-free so the mapping and
7
+ * masking helpers can run in Node tests and any consumer bundle.
8
+ */
9
+ /** Severity/color tier of a finding: red, green, or blue squiggle. */
10
+ type ProofCategory = 'spelling' | 'grammar' | 'style';
11
+ /** How a suggestion is applied relative to the finding's span. */
12
+ type ProofSuggestionKind = 'replace' | 'remove' | 'insertAfter';
13
+ /** One candidate fix for a finding. */
14
+ interface ProofSuggestion {
15
+ /** Replacement/insertion text (empty for `remove`). */
16
+ text: string;
17
+ kind: ProofSuggestionKind;
18
+ }
19
+ /** A half-open `[start, end)` range in UTF-16 code units. */
20
+ interface ProofRange {
21
+ start: number;
22
+ end: number;
23
+ }
24
+ /**
25
+ * One issue found in a linted text. Offsets index into the exact string
26
+ * that was linted (UTF-16 code units — the same coordinate space as
27
+ * ProseMirror, Monaco, and DOM Range).
28
+ */
29
+ interface ProofFinding extends ProofRange {
30
+ /** Stable within one lint pass; the provider maps id → engine handle. */
31
+ id: string;
32
+ category: ProofCategory;
33
+ /** Raw engine kind (e.g. `Typo`), for diagnostics and future filtering. */
34
+ kind: string;
35
+ /** Human-readable description of the issue. */
36
+ message: string;
37
+ /** Text at `[start, end)` when linted — staleness check before applying. */
38
+ originalText: string;
39
+ suggestions: ProofSuggestion[];
40
+ }
41
+ /** English dialects supported by the proofing engine. */
42
+ type ProofDialect = 'American' | 'British' | 'Australian' | 'Canadian' | 'Indian';
43
+ /** All supported dialects, in display order. */
44
+ declare const PROOF_DIALECTS: readonly ProofDialect[];
45
+
46
+ /**
47
+ * Mapping from harper's `LintKind` vocabulary to squisq's three proofing
48
+ * tiers. The keys pin the full 21-kind union of harper.js 2.7.0; a unit
49
+ * test asserts the map stays in sync with the installed engine so an
50
+ * upgrade that adds a kind is caught at review time rather than falling
51
+ * through silently. Unknown kinds degrade to `style` (the least alarming
52
+ * tier) instead of throwing.
53
+ */
54
+
55
+ /** harper `LintKind` → squisq tier. Spelling = red, grammar = green, style = blue. */
56
+ declare const LINT_KIND_CATEGORIES: Readonly<Record<string, ProofCategory>>;
57
+ /**
58
+ * Categorize a raw engine kind. Kinds this build doesn't know (added by a
59
+ * future harper release) fall back to `style` so they render as the least
60
+ * alarming squiggle rather than breaking the pass.
61
+ */
62
+ declare function categorizeLintKind(kind: string): ProofCategory;
63
+
64
+ /**
65
+ * Protected-span masking for proofing.
66
+ *
67
+ * Squisq markdown carries `{[…]}` annotations (block templates, inline
68
+ * icons, media directives) whose contents are machine vocabulary, not
69
+ * prose — a grammar engine flags `src`/`webm`/template ids as spelling
70
+ * errors. The engine's own masking option is unusable (inclusion-mask
71
+ * semantics and silent failure on an invalid pattern), so we blank the
72
+ * spans ourselves: replace each annotation with an equal-length run of
73
+ * spaces — every surrounding offset stays byte-identical — and afterwards
74
+ * drop any finding that intersects a blanked range (which also swallows
75
+ * the whitespace-formatting lints the blank runs themselves can induce).
76
+ */
77
+
78
+ interface BlankedText {
79
+ /** Input with every protected span replaced by spaces; same length. */
80
+ text: string;
81
+ /** The replaced ranges, in ascending order. */
82
+ blanked: ProofRange[];
83
+ }
84
+ /** Blank `{[…]}` annotation spans to equal-length spaces. */
85
+ declare function blankProtectedSpans(text: string): BlankedText;
86
+ /** Keep only findings whose span does not intersect any blanked range. */
87
+ declare function dropMaskedFindings<T extends ProofRange>(findings: readonly T[], blanked: readonly ProofRange[]): T[];
88
+
89
+ /**
90
+ * Joined-segment linting.
91
+ *
92
+ * The Write view lints many textblocks (paragraphs, headings, list
93
+ * items, table cells) in ONE engine call by joining their texts with a
94
+ * blank-line separator: one RPC per pass instead of one per block, and —
95
+ * measured — the engine treats each segment as its own paragraph while
96
+ * still using sentence context (`Its` → `It's` fires only with context).
97
+ * Findings come back in the joined coordinate space and are mapped back
98
+ * to their segment; a span that touches a separator or crosses segments
99
+ * is dropped rather than guessed at.
100
+ */
101
+
102
+ /** Separator between joined segments — a paragraph boundary to the engine. */
103
+ declare const PROOF_JOIN_SEPARATOR = "\n\n";
104
+ interface JoinedSegments {
105
+ /** All segments joined with {@link PROOF_JOIN_SEPARATOR}. */
106
+ text: string;
107
+ /** Start offset of each segment within `text`, ascending. */
108
+ starts: number[];
109
+ /** Length of each segment. */
110
+ lengths: number[];
111
+ }
112
+ /** Join segment texts, recording where each lands in the joined string. */
113
+ declare function buildJoinedText(segments: readonly string[]): JoinedSegments;
114
+ interface SegmentSpan extends ProofRange {
115
+ /** Index into the segment list handed to {@link buildJoinedText}. */
116
+ segmentIndex: number;
117
+ }
118
+ /**
119
+ * Map a `[start, end)` span in the joined text back to segment-local
120
+ * coordinates. Returns `null` for an empty span, a span outside every
121
+ * segment, or one that touches a separator / crosses segments.
122
+ */
123
+ declare function mapJoinedSpanToSegment(joined: JoinedSegments, start: number, end: number): SegmentSpan | null;
124
+
125
+ /**
126
+ * Doc-level proofing settings, persisted in frontmatter — the proofing
127
+ * analog of `coverSlideSettings`. Three keys:
128
+ *
129
+ * - `squisq-proofing` — per-doc enable override (boolean)
130
+ * - `squisq-proof-dialect` — English dialect for this doc
131
+ * - `squisq-proof-dictionary` — comma-separated accepted words
132
+ *
133
+ * Deliberately NOT here: ignored findings. Dismissing a finding is a
134
+ * personal preference about one person's editing session, not document
135
+ * content — it would otherwise land in everyone's copy through git. The
136
+ * editor hands that state to the host instead, scoped per document
137
+ * (`ProofingIgnoreStore` in `@bendyline/squisq-editor-react/proofing`).
138
+ */
139
+
140
+ /** Frontmatter keys (canonical `squisq-*` plus tolerated bare spellings). */
141
+ declare const PROOF_FRONTMATTER_KEYS: Readonly<{
142
+ enabled: {
143
+ canonical: string;
144
+ legacy: string;
145
+ };
146
+ dialect: {
147
+ canonical: string;
148
+ legacy: string;
149
+ };
150
+ dictionary: {
151
+ canonical: string;
152
+ legacy: string;
153
+ };
154
+ }>;
155
+ interface ProofingSettings {
156
+ /** Per-doc enable override; `undefined` = defer to the host default. */
157
+ enabled?: boolean;
158
+ /** Dialect override; `undefined` = provider/config default. */
159
+ dialect?: ProofDialect;
160
+ /** Doc-local accepted words (always an array; empty when unset). */
161
+ dictionary: string[];
162
+ }
163
+ declare const DEFAULT_PROOF_SETTINGS: Readonly<{
164
+ enabled: true;
165
+ dialect: ProofDialect;
166
+ }>;
167
+ /** Resolve a dialect value case-insensitively; `undefined` when unrecognized. */
168
+ declare function resolveProofDialect(value: unknown): ProofDialect | undefined;
169
+ /**
170
+ * Parse a dictionary value into a word list. Accepts the canonical
171
+ * comma-separated string plus (defensively) a parsed YAML list.
172
+ */
173
+ declare function parseProofDictionary(value: unknown): string[];
174
+ /** Encode a dictionary for frontmatter; `null` (remove the key) when empty. */
175
+ declare function formatProofDictionary(words: readonly string[]): string | null;
176
+ /** Read all proofing settings from a parsed frontmatter record. */
177
+ declare function readProofingSettings(frontmatter: Record<string, unknown> | undefined): ProofingSettings;
178
+
179
+ export { type BlankedText, DEFAULT_PROOF_SETTINGS, type JoinedSegments, LINT_KIND_CATEGORIES, PROOF_DIALECTS, PROOF_FRONTMATTER_KEYS, PROOF_JOIN_SEPARATOR, type ProofCategory, type ProofDialect, type ProofFinding, type ProofRange, type ProofSuggestion, type ProofSuggestionKind, type ProofingSettings, type SegmentSpan, blankProtectedSpans, buildJoinedText, categorizeLintKind, dropMaskedFindings, formatProofDictionary, mapJoinedSpanToSegment, parseProofDictionary, readProofingSettings, resolveProofDialect };
@@ -0,0 +1,32 @@
1
+ import {
2
+ DEFAULT_PROOF_SETTINGS,
3
+ LINT_KIND_CATEGORIES,
4
+ PROOF_DIALECTS,
5
+ PROOF_FRONTMATTER_KEYS,
6
+ PROOF_JOIN_SEPARATOR,
7
+ blankProtectedSpans,
8
+ buildJoinedText,
9
+ categorizeLintKind,
10
+ dropMaskedFindings,
11
+ formatProofDictionary,
12
+ mapJoinedSpanToSegment,
13
+ parseProofDictionary,
14
+ readProofingSettings,
15
+ resolveProofDialect
16
+ } from "../chunk-T3B4WJBR.js";
17
+ export {
18
+ DEFAULT_PROOF_SETTINGS,
19
+ LINT_KIND_CATEGORIES,
20
+ PROOF_DIALECTS,
21
+ PROOF_FRONTMATTER_KEYS,
22
+ PROOF_JOIN_SEPARATOR,
23
+ blankProtectedSpans,
24
+ buildJoinedText,
25
+ categorizeLintKind,
26
+ dropMaskedFindings,
27
+ formatProofDictionary,
28
+ mapJoinedSpanToSegment,
29
+ parseProofDictionary,
30
+ readProofingSettings,
31
+ resolveProofDialect
32
+ };
@@ -1,4 +1,4 @@
1
- import { M as MarkdownBlockNode } from '../types-CcrDFdWH.js';
1
+ import { M as MarkdownBlockNode } from '../types-Be6sBUBx.js';
2
2
 
3
3
  /**
4
4
  * Block template recommendations.
@@ -1,10 +1,10 @@
1
1
  export { B as BoundingBox, C as Coordinates } from '../Types-sh2VRxfo.js';
2
- import { O as Doc, bh as Theme, bk as ThemePageStyle, bj as ThemeColorScheme, I as DeepPartial, bn as ThemeSeedColors, bi as ThemeColorPalette, X as FontFamilyKind, W as FontFamily } from '../Doc-DBadkoP4.js';
3
- export { A as AccentImage, a as AccentPosition, b as AmbientGradientConfig, c as Animation, d as AnimationType, e as AreaChartInput, f as AudioBookmark, g as AudioSegment, h as AudioTimingData, i as AudioTrack, B as BarChartInput, j as BigTextInput, k as Block, l as BlockConnection, m as BorderStyle, C as CaptionPhrase, n as CaptionTrack, o as CaptionWord, p as ChartBaseFields, q as ChartTemplateInput, r as ColorScheme, s as ColumnChartInput, t as ComparisonBarInput, u as ContentBlockInput, v as CornerBrandingConfig, w as CustomTemplateDefinition, x as CustomTemplateLayer, y as CustomTemplateValidationError, z as CustomTemplateValidationResult, D as DARK_SURFACE, E as DEFAULT_DOC_FONT, F as DEFAULT_TITLE_FONT, G as DataTableInput, H as DateEventInput, J as DefinitionCardInput, K as DiagramBlockInput, L as DiagramEdgeAnchor, M as DiagramTemplateEdge, N as DiagramTemplateNode, P as DocBlock, Q as DocDiagnostic, R as DonutChartInput, S as DrawingBlockInput, T as FRONTMATTER_CUSTOM_TEMPLATES_KEY, U as FRONTMATTER_CUSTOM_THEMES_KEY, V as FactCardInput, Y as FullBleedQuoteInput, Z as GradientBackgroundConfig, _ as ImageBackgroundConfig, $ as ImageLayer, a0 as ImageTreatment, a1 as ImageWithCaptionInput, a2 as LIGHT_SURFACE, a3 as Layer, a4 as LayerRepeat, a5 as LayoutHints, a6 as LeftFeatureInput, a7 as LineChartInput, a8 as LinearGradient, a9 as ListBlockInput, aa as MapBlockInput, ab as MapLayer, ac as MapMarker, ad as MapTileStyle, ae as MarkerStyle, af as MediaClip, ag as MediaScheduleOptions, ah as MermaidLayer, ai as PAGE_ACCENT_STRATEGIES, aj as PAGE_BACKGROUNDS, ak as PAGE_BACKGROUND_RHYTHMS, al as PAGE_DESIGN_FAMILIES, am as PAGE_DIVIDERS, an as PAGE_EMPHASES, ao as PAGE_EYEBROWS, ap as PAGE_HEADING_CASES, aq as PAGE_HEADING_SCALES, ar as PAGE_HEADING_UNDERLINES, as as PAGE_HERO_STYLES, at as PAGE_IMAGE_FRAMINGS, au as PAGE_NUMERAL_STYLES, av as PAGE_PATTERNS, aw as PAGE_QUOTE_MARKS, ax as PAGE_SECTION_KINDS, ay as PAGE_SECTION_SPACINGS, az as PAGE_SHADOWS, aA as PageAccentRotation, aB as PageBackground, aC as PageDesignFamily, aD as PageEmphasis, aE as PageHeadingTreatment, aF as PageSectionKind, aG as PageSectionOverride, aH as PageTokens, aI as PathLayer, aJ as PatternBackgroundConfig, aK as PersistentLayer, aL as PersistentLayerConfig, aM as PersistentLayerTemplate, aN as PersistentLayerTemplateConfig, aO as PersistentLayerTemplateType, aP as PhotoGridInput, aQ as PieChartInput, aR as PipStyle, aS as Position, aT as ProgressIndicatorConfig, aU as PromotedBodyAnnotation, aV as PullQuoteInput, aW as QuoteBlockInput, aX as RawLayersInput, aY as RenderStyle, aZ as RightFeatureInput, a_ as ScatterChartInput, a$ as ScheduledClip, b0 as SectionHeaderInput, b1 as ShapeFilter, b2 as ShapeLayer, b3 as ShapePattern, b4 as SolidBackgroundConfig, b5 as StartBlockConfig, b6 as StatHighlightInput, b7 as SurfaceScheme, b8 as THEME_SCHEMA_VERSION, b9 as TableLayer, ba as TableLayerStyle, bb as TemplateBlock, bc as TemplateContext, bd as TemplateFunction, be as TemplateRegistry, bf as TextLayer, bg as TextStyle, bl as ThemeRegistry, bm as ThemeSchemaVersion, bo as ThemeStyle, bp as ThemeTypography, bq as TimelineBlockInput, br as TimelineTemplateEvent, bs as TimelineTemplateLink, bt as TimelineTemplateTrack, bu as TitleBlockInput, bv as TitleCaptionConfig, bw as TreeBlockInput, bx as TreeLayer, by as TreeLayerItem, bz as TreeLayerStyle, bA as TreeTemplateItem, bB as TwoColumnInput, bC as VIEWPORT_PRESETS, bD as VideoLayer, bE as VideoPipPosition, bF as VideoPipShape, bG as VideoPipSize, bH as VideoPlacement, bI as VideoPresentation, bJ as VideoPullQuoteInput, bK as VideoWithCaptionInput, bL as ViewportConfig, bM as ViewportOrientation, bN as ViewportPreset, bO as VignetteConfig, bP as applySurface, bQ as calculateDuration, bR as calculateFontScale, bS as createTemplateContext, bT as createTheme, bU as createThemeRegistry, bV as getAspectRatioString, bW as getBlockAtTime, bX as getCaptionAtTime, bY as getDocPlaybackDuration, bZ as getLayoutHints, b_ as getSafeTextBounds, b$ as getSegmentAtTime, c0 as getTwoColumnPositions, c1 as getViewport, c2 as getViewportOrientation, c3 as isCustomTemplateDefinition, c4 as isPersistentLayerTemplate, c5 as isTemplateBlock, c6 as layoutScaledFontSize, c7 as resolveMediaSchedule, c8 as scaledFontSize, c9 as validateCustomTemplateDefinition } from '../Doc-DBadkoP4.js';
4
- export { a as DEFAULT_TRANSITION_DURATION_SECONDS, $ as TRANSITION_DIRECTIONS, a0 as TRANSITION_TYPES, a1 as Transition, a2 as TransitionDirection, a3 as TransitionType, a6 as isTransitionType, a7 as normalizeTransitionDirection, a8 as normalizeTransitionType, a9 as resolveBlockTransition, ab as resolveTransitionDuration } from '../types-CcrDFdWH.js';
5
- export { D as DEFAULT_THEME, a as DEFAULT_THEME_ID, T as THEMES, g as getAvailableThemes, b as getThemeSummaries, r as resolveTheme } from '../themeLibrary-8BQMY2HV.js';
2
+ import { O as Doc, bh as Theme, bk as ThemePageStyle, bj as ThemeColorScheme, I as DeepPartial, bn as ThemeSeedColors, bi as ThemeColorPalette, X as FontFamilyKind, W as FontFamily } from '../Doc-DTyeaFuW.js';
3
+ export { A as AccentImage, a as AccentPosition, b as AmbientGradientConfig, c as Animation, d as AnimationType, e as AreaChartInput, f as AudioBookmark, g as AudioSegment, h as AudioTimingData, i as AudioTrack, B as BarChartInput, j as BigTextInput, k as Block, l as BlockConnection, m as BorderStyle, C as CaptionPhrase, n as CaptionTrack, o as CaptionWord, p as ChartBaseFields, q as ChartTemplateInput, r as ColorScheme, s as ColumnChartInput, t as ComparisonBarInput, u as ContentBlockInput, v as CornerBrandingConfig, w as CustomTemplateDefinition, x as CustomTemplateLayer, y as CustomTemplateValidationError, z as CustomTemplateValidationResult, D as DARK_SURFACE, E as DEFAULT_DOC_FONT, F as DEFAULT_TITLE_FONT, G as DataTableInput, H as DateEventInput, J as DefinitionCardInput, K as DiagramBlockInput, L as DiagramEdgeAnchor, M as DiagramTemplateEdge, N as DiagramTemplateNode, P as DocBlock, Q as DocDiagnostic, R as DonutChartInput, S as DrawingBlockInput, T as FRONTMATTER_CUSTOM_TEMPLATES_KEY, U as FRONTMATTER_CUSTOM_THEMES_KEY, V as FactCardInput, Y as FullBleedQuoteInput, Z as GradientBackgroundConfig, _ as ImageBackgroundConfig, $ as ImageLayer, a0 as ImageTreatment, a1 as ImageWithCaptionInput, a2 as LIGHT_SURFACE, a3 as Layer, a4 as LayerRepeat, a5 as LayoutHints, a6 as LeftFeatureInput, a7 as LineChartInput, a8 as LinearGradient, a9 as ListBlockInput, aa as MapBlockInput, ab as MapLayer, ac as MapMarker, ad as MapTileStyle, ae as MarkerStyle, af as MediaClip, ag as MediaScheduleOptions, ah as MermaidLayer, ai as PAGE_ACCENT_STRATEGIES, aj as PAGE_BACKGROUNDS, ak as PAGE_BACKGROUND_RHYTHMS, al as PAGE_DESIGN_FAMILIES, am as PAGE_DIVIDERS, an as PAGE_EMPHASES, ao as PAGE_EYEBROWS, ap as PAGE_HEADING_CASES, aq as PAGE_HEADING_SCALES, ar as PAGE_HEADING_UNDERLINES, as as PAGE_HERO_STYLES, at as PAGE_IMAGE_FRAMINGS, au as PAGE_NUMERAL_STYLES, av as PAGE_PATTERNS, aw as PAGE_QUOTE_MARKS, ax as PAGE_SECTION_KINDS, ay as PAGE_SECTION_SPACINGS, az as PAGE_SHADOWS, aA as PageAccentRotation, aB as PageBackground, aC as PageDesignFamily, aD as PageEmphasis, aE as PageHeadingTreatment, aF as PageSectionKind, aG as PageSectionOverride, aH as PageTokens, aI as PathLayer, aJ as PatternBackgroundConfig, aK as PersistentLayer, aL as PersistentLayerConfig, aM as PersistentLayerTemplate, aN as PersistentLayerTemplateConfig, aO as PersistentLayerTemplateType, aP as PhotoGridInput, aQ as PieChartInput, aR as PipStyle, aS as Position, aT as ProgressIndicatorConfig, aU as PromotedBodyAnnotation, aV as PullQuoteInput, aW as QuoteBlockInput, aX as RawLayersInput, aY as RenderStyle, aZ as RightFeatureInput, a_ as ScatterChartInput, a$ as ScheduledClip, b0 as SectionHeaderInput, b1 as ShapeFilter, b2 as ShapeLayer, b3 as ShapePattern, b4 as SolidBackgroundConfig, b5 as StartBlockConfig, b6 as StatHighlightInput, b7 as SurfaceScheme, b8 as THEME_SCHEMA_VERSION, b9 as TableLayer, ba as TableLayerStyle, bb as TemplateBlock, bc as TemplateContext, bd as TemplateFunction, be as TemplateRegistry, bf as TextLayer, bg as TextStyle, bl as ThemeRegistry, bm as ThemeSchemaVersion, bo as ThemeStyle, bp as ThemeTypography, bq as TimelineBlockInput, br as TimelineTemplateEvent, bs as TimelineTemplateLink, bt as TimelineTemplateTrack, bu as TitleBlockInput, bv as TitleCaptionConfig, bw as TreeBlockInput, bx as TreeLayer, by as TreeLayerItem, bz as TreeLayerStyle, bA as TreeTemplateItem, bB as TwoColumnInput, bC as VIEWPORT_PRESETS, bD as VideoLayer, bE as VideoPipPosition, bF as VideoPipShape, bG as VideoPipSize, bH as VideoPlacement, bI as VideoPresentation, bJ as VideoPullQuoteInput, bK as VideoWithCaptionInput, bL as ViewportConfig, bM as ViewportOrientation, bN as ViewportPreset, bO as VignetteConfig, bP as applySurface, bQ as calculateDuration, bR as calculateFontScale, bS as createTemplateContext, bT as createTheme, bU as createThemeRegistry, bV as getAspectRatioString, bW as getBlockAtTime, bX as getCaptionAtTime, bY as getDocPlaybackDuration, bZ as getLayoutHints, b_ as getSafeTextBounds, b$ as getSegmentAtTime, c0 as getTwoColumnPositions, c1 as getViewport, c2 as getViewportOrientation, c3 as isCustomTemplateDefinition, c4 as isPersistentLayerTemplate, c5 as isTemplateBlock, c6 as layoutScaledFontSize, c7 as resolveMediaSchedule, c8 as scaledFontSize, c9 as validateCustomTemplateDefinition } from '../Doc-DTyeaFuW.js';
4
+ export { a as DEFAULT_TRANSITION_DURATION_SECONDS, a1 as TRANSITION_DIRECTIONS, a2 as TRANSITION_TYPES, a3 as Transition, a4 as TransitionDirection, a5 as TransitionType, a8 as isTransitionType, a9 as normalizeTransitionDirection, aa as normalizeTransitionType, ab as resolveBlockTransition, ad as resolveTransitionDuration } from '../types-Be6sBUBx.js';
5
+ export { D as DEFAULT_THEME, a as DEFAULT_THEME_ID, T as THEMES, g as getAvailableThemes, b as getThemeSummaries, r as resolveTheme } from '../themeLibrary-xaxN5UYu.js';
6
6
  export { M as MediaEntry, a as MediaProvider } from '../MediaProvider-wpSe21B3.js';
7
- export { E as EditorLayerMeta, I as ImageEditCanvas, a as ImageEditDoc, b as ImageEditLayer, c as ImageEditLayerKind, d as ImageEditMeta } from '../ImageEditDoc-Cq2a3c30.js';
7
+ export { E as EditorLayerMeta, I as ImageEditCanvas, a as ImageEditDoc, b as ImageEditLayer, c as ImageEditLayerKind, d as ImageEditMeta } from '../ImageEditDoc-dFEclQ9l.js';
8
8
 
9
9
  /**
10
10
  * Runtime validation for the canonical {@link Doc} JSON shape.
@@ -1,4 +1,4 @@
1
- import { bh as Theme, bl as ThemeRegistry } from './Doc-DBadkoP4.js';
1
+ import { bh as Theme, bl as ThemeRegistry } from './Doc-DTyeaFuW.js';
2
2
 
3
3
  /**
4
4
  * Built-in Theme Library
@@ -1,7 +1,7 @@
1
- import { r as ColorScheme, O as Doc, k as Block } from '../Doc-DBadkoP4.js';
2
- import { i as PageTransformHints } from '../materializePageSection-Rss5thAj.js';
1
+ import { r as ColorScheme, O as Doc, k as Block } from '../Doc-DTyeaFuW.js';
2
+ import { i as PageTransformHints } from '../materializePageSection-BRNIINlU.js';
3
3
  import { d as ExtractionType, E as ExtractedElement, b as ExtractionOptions } from '../contentExtractor-BNfVJV2U.js';
4
- import '../types-CcrDFdWH.js';
4
+ import '../types-Be6sBUBx.js';
5
5
 
6
6
  /** Identifier for a built-in or caller-registered transform style. */
7
7
  type TransformStyleId = string;
@@ -463,6 +463,32 @@ interface MarkdownStrikethrough extends MarkdownNodeBase {
463
463
  type: 'delete';
464
464
  children: MarkdownInlineNode[];
465
465
  }
466
+ /**
467
+ * Superscript text (`<sup>text</sup>`).
468
+ *
469
+ * Markdown has no native syntax for vertical alignment, so the source form is
470
+ * inline HTML — which is exactly what every importer that carries the
471
+ * information (DOCX `w:vertAlign`, SpreadsheetML `vertAlign`, HTML `<sup>`)
472
+ * can round-trip. The parser folds the `<sup>` … `</sup>` tag pair into this
473
+ * node so consumers treat it like {@link MarkdownStrong} rather than having to
474
+ * pair up two unrelated `htmlInline` nodes themselves; the serializer expands
475
+ * it back to the same three tokens, byte for byte.
476
+ *
477
+ * Only a BARE tag pair folds. `<sup class="fn">` keeps its attributes and stays
478
+ * `htmlInline`, because this node has nowhere to put them.
479
+ */
480
+ interface MarkdownSuperscript extends MarkdownNodeBase {
481
+ type: 'superscript';
482
+ children: MarkdownInlineNode[];
483
+ }
484
+ /**
485
+ * Subscript text (`<sub>text</sub>`). The vertical-alignment sibling of
486
+ * {@link MarkdownSuperscript}; see there for how the source form round-trips.
487
+ */
488
+ interface MarkdownSubscript extends MarkdownNodeBase {
489
+ type: 'subscript';
490
+ children: MarkdownInlineNode[];
491
+ }
466
492
  /**
467
493
  * Inline code (`code`).
468
494
  */
@@ -609,7 +635,7 @@ interface MarkdownMention extends MarkdownNodeBase {
609
635
  /** Block-level content that can appear as direct children of the document root, blockquotes, list items, etc. */
610
636
  type MarkdownBlockNode = MarkdownHeading | MarkdownParagraph | MarkdownBlockquote | MarkdownList | MarkdownCodeBlock | MarkdownThematicBreak | MarkdownTable | MarkdownHtmlBlock | MarkdownMathBlock | MarkdownLinkDefinition | MarkdownFootnoteDefinition | MarkdownContainerDirective | MarkdownLeafDirective | MarkdownDefinitionList;
611
637
  /** Inline/phrasing content that appears inside paragraphs, headings, links, etc. */
612
- type MarkdownInlineNode = MarkdownText | MarkdownEmphasis | MarkdownStrong | MarkdownStrikethrough | MarkdownInlineCode | MarkdownLink | MarkdownImage | MarkdownBreak | MarkdownInlineHtml | MarkdownInlineMath | MarkdownFootnoteReference | MarkdownLinkReference | MarkdownImageReference | MarkdownTextDirective | MarkdownMention | MarkdownInlineIcon;
638
+ type MarkdownInlineNode = MarkdownText | MarkdownEmphasis | MarkdownStrong | MarkdownStrikethrough | MarkdownSuperscript | MarkdownSubscript | MarkdownInlineCode | MarkdownLink | MarkdownImage | MarkdownBreak | MarkdownInlineHtml | MarkdownInlineMath | MarkdownFootnoteReference | MarkdownLinkReference | MarkdownImageReference | MarkdownTextDirective | MarkdownMention | MarkdownInlineIcon;
613
639
  /**
614
640
  * Any node in the markdown tree. Includes structural nodes (listItem,
615
641
  * tableRow, tableCell, etc.) that only appear as children of specific parents.
@@ -665,4 +691,4 @@ interface StringifyOptions {
665
691
  setext?: boolean;
666
692
  }
667
693
 
668
- export { TRANSITION_DIRECTIONS as $, type MarkdownLeafDirective as A, MarkdownLimitError as B, type MarkdownLink as C, DEFAULT_MARKDOWN_SAFETY_LIMITS as D, type MarkdownLinkDefinition as E, type MarkdownLinkReference as F, type MarkdownList as G, type HeadingAttributes as H, type MarkdownListItem as I, type MarkdownMathBlock as J, type MarkdownMention as K, type MarkdownNode as L, type MarkdownBlockNode as M, type MarkdownParagraph as N, type MarkdownPoint as O, type MarkdownSafetyLimits as P, type MarkdownSourcePosition as Q, type MarkdownStrikethrough as R, type MarkdownStrong as S, type MarkdownTable as T, type MarkdownTableCell as U, type MarkdownTableRow as V, type MarkdownText as W, type MarkdownTextDirective as X, type MarkdownThematicBreak as Y, type ParseOptions as Z, type StringifyOptions as _, DEFAULT_TRANSITION_DURATION_SECONDS as a, TRANSITION_TYPES as a0, type Transition as a1, type TransitionDirection as a2, type TransitionType as a3, assertMarkdownDocumentWithinLimits as a4, assertMarkdownSourceWithinLimits as a5, isTransitionType as a6, normalizeTransitionDirection as a7, normalizeTransitionType as a8, resolveBlockTransition as a9, resolveMarkdownSafetyLimits as aa, resolveTransitionDuration as ab, type BlockConnection as ac, type HeadingTemplateAnnotation as b, type HtmlComment as c, type HtmlElement as d, type HtmlNode as e, type HtmlText as f, type MarkdownBlockquote as g, type MarkdownBreak as h, type MarkdownCodeBlock as i, type MarkdownContainerDirective as j, type MarkdownDefinitionDescription as k, type MarkdownDefinitionList as l, type MarkdownDefinitionTerm as m, type MarkdownDocument as n, type MarkdownEmphasis as o, type MarkdownFootnoteDefinition as p, type MarkdownFootnoteReference as q, type MarkdownHeading as r, type MarkdownHtmlBlock as s, type MarkdownImage as t, type MarkdownImageReference as u, type MarkdownInlineCode as v, type MarkdownInlineHtml as w, type MarkdownInlineIcon as x, type MarkdownInlineMath as y, type MarkdownInlineNode as z };
694
+ export { type ParseOptions as $, type MarkdownLeafDirective as A, MarkdownLimitError as B, type MarkdownLink as C, DEFAULT_MARKDOWN_SAFETY_LIMITS as D, type MarkdownLinkDefinition as E, type MarkdownLinkReference as F, type MarkdownList as G, type HeadingAttributes as H, type MarkdownListItem as I, type MarkdownMathBlock as J, type MarkdownMention as K, type MarkdownNode as L, type MarkdownBlockNode as M, type MarkdownParagraph as N, type MarkdownPoint as O, type MarkdownSafetyLimits as P, type MarkdownSourcePosition as Q, type MarkdownStrikethrough as R, type MarkdownStrong as S, type MarkdownSubscript as T, type MarkdownSuperscript as U, type MarkdownTable as V, type MarkdownTableCell as W, type MarkdownTableRow as X, type MarkdownText as Y, type MarkdownTextDirective as Z, type MarkdownThematicBreak as _, DEFAULT_TRANSITION_DURATION_SECONDS as a, type StringifyOptions as a0, TRANSITION_DIRECTIONS as a1, TRANSITION_TYPES as a2, type Transition as a3, type TransitionDirection as a4, type TransitionType as a5, assertMarkdownDocumentWithinLimits as a6, assertMarkdownSourceWithinLimits as a7, isTransitionType as a8, normalizeTransitionDirection as a9, normalizeTransitionType as aa, resolveBlockTransition as ab, resolveMarkdownSafetyLimits as ac, resolveTransitionDuration as ad, type BlockConnection as ae, type HeadingTemplateAnnotation as b, type HtmlComment as c, type HtmlElement as d, type HtmlNode as e, type HtmlText as f, type MarkdownBlockquote as g, type MarkdownBreak as h, type MarkdownCodeBlock as i, type MarkdownContainerDirective as j, type MarkdownDefinitionDescription as k, type MarkdownDefinitionList as l, type MarkdownDefinitionTerm as m, type MarkdownDocument as n, type MarkdownEmphasis as o, type MarkdownFootnoteDefinition as p, type MarkdownFootnoteReference as q, type MarkdownHeading as r, type MarkdownHtmlBlock as s, type MarkdownImage as t, type MarkdownImageReference as u, type MarkdownInlineCode as v, type MarkdownInlineHtml as w, type MarkdownInlineIcon as x, type MarkdownInlineMath as y, type MarkdownInlineNode as z };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bendyline/squisq",
3
- "version": "2.8.0",
3
+ "version": "2.10.0",
4
4
  "description": "Headless utilities for doc/block rendering, spatial math, Markdown, and storage",
5
5
  "license": "MIT",
6
6
  "author": "Bendyline",
@@ -126,6 +126,11 @@
126
126
  "types": "./dist/fence/index.d.ts",
127
127
  "import": "./dist/fence/index.js",
128
128
  "default": "./dist/fence/index.js"
129
+ },
130
+ "./proof": {
131
+ "types": "./dist/proof/index.d.ts",
132
+ "import": "./dist/proof/index.js",
133
+ "default": "./dist/proof/index.js"
129
134
  }
130
135
  },
131
136
  "scripts": {