@bendyline/docblocks-react 2.6.2 → 2.7.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.
Files changed (57) hide show
  1. package/README.md +3 -10
  2. package/THIRD_PARTY_NOTICES.txt +4284 -3651
  3. package/dist/AiDiagrams-LFV4YU6W.js +13 -0
  4. package/dist/AiEditorAssistant-GN2KXKZD.js +786 -0
  5. package/dist/AudioExportDialog-F23QXNPB.js +253 -0
  6. package/dist/DocumentConflictDialog-5LRVIGXS.js +111 -0
  7. package/dist/ExportDialog-IMBVGRYG.js +9 -0
  8. package/dist/{ExportToolbarControls-QYLBRWM7.js → ExportToolbarControls-MUM6HM3K.js} +117 -49
  9. package/dist/{GitToolbarControl-O5AXBC6T.js → GitToolbarControl-B7KG4MFP.js} +6 -6
  10. package/dist/{GitUI-L5T3XHZG.js → GitUI-RCWUZVS6.js} +6 -6
  11. package/dist/PresentationMaker-W2JIBHRN.js +9 -0
  12. package/dist/QuickOpenDialog-2KK4SEBU.js +356 -0
  13. package/dist/Settings-DuXk6baH.d.ts +144 -0
  14. package/dist/ShareDialog-XUA2OVGI.js +292 -0
  15. package/dist/SpeechToolbarControl-OSQS7NVY.js +434 -0
  16. package/dist/TextFromNarration-XYRAB6O2.js +598 -0
  17. package/dist/WorkspaceSearchPanel-BKZJRPMY.js +334 -0
  18. package/dist/chunk-2IYBBFQX.js +201 -0
  19. package/dist/{chunk-LG6HAWCK.js → chunk-56KO2LYN.js} +35 -4
  20. package/dist/chunk-6B7G33D5.js +88 -0
  21. package/dist/chunk-ARATARVJ.js +40 -0
  22. package/dist/{chunk-ODYNOPC3.js → chunk-BCQZTWE5.js} +57 -17
  23. package/dist/{chunk-FMDLZ4ZG.js → chunk-BD54Z5XP.js} +12 -3
  24. package/dist/chunk-EA4BO6E4.js +73 -0
  25. package/dist/chunk-EPOLZNFD.js +518 -0
  26. package/dist/chunk-G4MFB3IO.js +208 -0
  27. package/dist/{chunk-MRUK56JS.js → chunk-GMA4KGGO.js} +7 -3
  28. package/dist/chunk-I44HKDQX.js +314 -0
  29. package/dist/chunk-K4I3NJFL.js +49 -0
  30. package/dist/chunk-KBDZDFPU.js +61 -0
  31. package/dist/{chunk-FNSRCCBC.js → chunk-KWG6UP5O.js} +0 -10
  32. package/dist/chunk-NAH52736.js +1884 -0
  33. package/dist/chunk-RP3DVNTI.js +62 -0
  34. package/dist/chunk-SPUPWCSI.js +111 -0
  35. package/dist/chunk-TBLZBNQF.js +25 -0
  36. package/dist/{chunk-M5Y5WO7Z.js → chunk-UG4G7PJ4.js} +1 -1
  37. package/dist/chunk-UONFWKJ7.js +22 -0
  38. package/dist/chunk-VO2JYYQZ.js +40 -0
  39. package/dist/chunk-W55E6TE2.js +1714 -0
  40. package/dist/chunk-X3DDTJKR.js +574 -0
  41. package/dist/{chunk-EBWYGTN7.js → chunk-X437UAF7.js} +6 -0
  42. package/dist/editor.d.ts +36 -1
  43. package/dist/editor.js +16 -1
  44. package/dist/export/index.d.ts +27 -11
  45. package/dist/export/index.js +11 -7
  46. package/dist/index.d.ts +100 -13
  47. package/dist/index.js +3927 -1638
  48. package/dist/proofing/index.js +11 -1
  49. package/dist/{run-export-I2XOVGG4.js → run-export-47X5FTYZ.js} +3 -3
  50. package/dist/settings/index.d.ts +32 -101
  51. package/dist/settings/index.js +14 -2
  52. package/package.json +9 -9
  53. package/src/styles/docblocks.css +2344 -657
  54. package/dist/ExportDialog-Q4VWI43H.js +0 -9
  55. package/dist/ShareDialog-4OX3UPJ4.js +0 -359
  56. package/dist/chunk-JDJVRDOP.js +0 -92
  57. package/dist/chunk-Q6XNIKDG.js +0 -669
@@ -1,6 +1,7 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as _bendyline_squisq_formats_pptx from '@bendyline/squisq-formats/pptx';
3
3
  import { ContentContainer } from '@bendyline/squisq/storage';
4
+ import { DiagramRasterizer } from '@bendyline/squisq-formats/diagrams';
4
5
 
5
6
  /**
6
7
  * Export option types and localStorage persistence for quick-export.
@@ -52,6 +53,14 @@ interface ExportOptions {
52
53
  declare const FORMAT_LABELS: Record<ExportFormat, string>;
53
54
  declare const FORMAT_EXTENSIONS: Record<ExportFormat, string>;
54
55
  declare const DEFAULT_OPTIONS: ExportOptions;
56
+ /**
57
+ * Options that populate the export dialog. Layered: built-in defaults → the
58
+ * user's last-chosen options → the workspace default theme → the document's
59
+ * own theme (wins). "Set a theme, then export" therefore pre-selects that
60
+ * theme instead of whatever was picked for an unrelated previous document,
61
+ * and documents without a theme export in their folder's default.
62
+ */
63
+ declare function resolveExportDialogInitial(lastOptions: ExportOptions | null, docThemeId: string | null | undefined, workspaceThemeId?: string | null): ExportOptions;
55
64
  declare function loadLastExportOptions(): ExportOptions | null;
56
65
  declare function saveExportOptions(options: ExportOptions): void;
57
66
 
@@ -61,6 +70,11 @@ type ExportBlobSaver = (blob: Blob, filename: string) => Promise<void> | void;
61
70
  /** Host-provided converters that must be loaded before an export begins. */
62
71
  interface ExportConverterOverrides {
63
72
  docToPptx?: (typeof _bendyline_squisq_formats_pptx)['docToPptx'];
73
+ /**
74
+ * Draws diagrams as pictures. Defaults to Squisq's browser renderer; tests
75
+ * pass a stand-in because drawing needs a real canvas.
76
+ */
77
+ diagramRenderer?: DiagramRasterizer;
64
78
  }
65
79
  /** Run the export and trigger a download. */
66
80
  declare function runExport(markdown: string, selectedFile: string | null, options: ExportOptions, mediaContainer?: ContentContainer | null, saveBlob?: ExportBlobSaver, converterOverrides?: ExportConverterOverrides): Promise<void>;
@@ -102,25 +116,27 @@ declare function ExportDialog({ initial, exporting, error, destination, onExport
102
116
  declare function updateExportTargetExtension(targetPath: string, suggestedFilename: string): string;
103
117
 
104
118
  /**
105
- * Host persistence for the editor's raster-image exporters.
119
+ * Host persistence for Squisq's rendered-output exporters.
106
120
  *
107
- * Squisq renders both the cover image and the Dashboard image in the
108
- * browser and hands the host a finished blob; DocBlocks owns where that
109
- * blob lands. The two exporters share one contract upstream
110
- * (`DashboardImageSaveOutput` is an alias of `CoverImageSaveOutput`), so
111
- * they share one adapter here rather than two identical copies.
121
+ * Squisq renders the cover image, the Dashboard image, and exported video in
122
+ * the browser and hands the host a finished blob; DocBlocks owns where that
123
+ * blob lands. The exporters share one save-output contract upstream
124
+ * (`DashboardImageSaveOutput` is an alias of `CoverImageSaveOutput`, and the
125
+ * video dialog's `saveOutput` has the same shape), so they share one adapter
126
+ * here rather than identical copies.
112
127
  */
113
- /** Host persistence shape required by the editor's image exporters. */
128
+ /** Host persistence shape required by the editor's rendered-output exporters. */
114
129
  interface ImageSaveAdapter<TTarget> {
115
130
  pickTarget(filename: string, currentTarget?: TTarget | null): Promise<TTarget | null>;
116
131
  saveBlob(blob: Blob, filename: string, target?: TTarget | null): Promise<TTarget | null>;
117
132
  }
118
133
  type ImageSaveOutput = (blob: Blob, filename: string) => Promise<boolean | void>;
119
134
  /**
120
- * Adapt DocBlocks' two-step host destination flow to Squisq's rendered image
121
- * output callback. The picker stays host-owned, and cancellation is reported
122
- * as `false` so the export dialog remains open without showing an error.
135
+ * Adapt DocBlocks' two-step host destination flow to Squisq's rendered output
136
+ * callback. The picker stays host-owned, and cancellation is reported as
137
+ * `false` so the export dialog remains open without showing an error. Squisq
138
+ * shows a failure's message verbatim, so it arrives without IPC internals.
123
139
  */
124
140
  declare function createImageSaveOutput<TTarget>(adapter: ImageSaveAdapter<TTarget>): ImageSaveOutput;
125
141
 
126
- export { type ImageSaveAdapter as CoverImageSaveAdapter, type ImageSaveOutput as CoverImageSaveOutput, DEFAULT_OPTIONS, type ImageSaveAdapter as DashboardImageSaveAdapter, type ImageSaveOutput as DashboardImageSaveOutput, type ExportBlobSaver, type ExportConverterOverrides, type ExportDestinationControl, ExportDialog, type ExportDialogProps, type ExportFormat, type ExportOptions, FORMAT_EXTENSIONS, FORMAT_LABELS, type HtmlBundle, type HtmlStyle, type ImageSaveAdapter, type ImageSaveOutput, buildExportFilename, createImageSaveOutput as createCoverImageSaveOutput, createImageSaveOutput as createDashboardImageSaveOutput, createImageSaveOutput, loadLastExportOptions, runExport, saveExportOptions, updateExportTargetExtension };
142
+ export { type ImageSaveAdapter as CoverImageSaveAdapter, type ImageSaveOutput as CoverImageSaveOutput, DEFAULT_OPTIONS, type ImageSaveAdapter as DashboardImageSaveAdapter, type ImageSaveOutput as DashboardImageSaveOutput, type ExportBlobSaver, type ExportConverterOverrides, type ExportDestinationControl, ExportDialog, type ExportDialogProps, type ExportFormat, type ExportOptions, FORMAT_EXTENSIONS, FORMAT_LABELS, type HtmlBundle, type HtmlStyle, type ImageSaveAdapter, type ImageSaveOutput, buildExportFilename, createImageSaveOutput as createCoverImageSaveOutput, createImageSaveOutput as createDashboardImageSaveOutput, createImageSaveOutput, loadLastExportOptions, resolveExportDialogInitial, runExport, saveExportOptions, updateExportTargetExtension };
@@ -1,25 +1,28 @@
1
1
  import {
2
- createImageSaveOutput,
3
2
  updateExportTargetExtension
4
- } from "../chunk-FNSRCCBC.js";
3
+ } from "../chunk-KWG6UP5O.js";
5
4
  import {
6
5
  runExport
7
- } from "../chunk-ODYNOPC3.js";
6
+ } from "../chunk-BCQZTWE5.js";
7
+ import {
8
+ createImageSaveOutput
9
+ } from "../chunk-UONFWKJ7.js";
8
10
  import {
9
11
  buildExportFilename
10
- } from "../chunk-M5Y5WO7Z.js";
12
+ } from "../chunk-UG4G7PJ4.js";
11
13
  import {
12
14
  ExportDialog
13
- } from "../chunk-FMDLZ4ZG.js";
15
+ } from "../chunk-BD54Z5XP.js";
14
16
  import "../chunk-YBEYTVU2.js";
15
17
  import {
16
18
  DEFAULT_OPTIONS,
17
19
  FORMAT_EXTENSIONS,
18
20
  FORMAT_LABELS,
19
21
  loadLastExportOptions,
22
+ resolveExportDialogInitial,
20
23
  saveExportOptions
21
- } from "../chunk-EBWYGTN7.js";
22
- import "../chunk-LG6HAWCK.js";
24
+ } from "../chunk-X437UAF7.js";
25
+ import "../chunk-56KO2LYN.js";
23
26
  export {
24
27
  DEFAULT_OPTIONS,
25
28
  ExportDialog,
@@ -30,6 +33,7 @@ export {
30
33
  createImageSaveOutput as createDashboardImageSaveOutput,
31
34
  createImageSaveOutput,
32
35
  loadLastExportOptions,
36
+ resolveExportDialogInitial,
33
37
  runExport,
34
38
  saveExportOptions,
35
39
  updateExportTargetExtension
package/dist/index.d.ts CHANGED
@@ -1,21 +1,24 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { FileSystemEntry, FileSystemProvider, FsErrorCode } from '@bendyline/docblocks/filesystem';
2
+ import { FileSystemEntry, FileSystemProvider, FileSystemEntryMoveOptions, FsErrorCode } from '@bendyline/docblocks/filesystem';
3
3
  import { WorkspaceDescriptor } from '@bendyline/docblocks/workspace';
4
4
  import { EditorColorScheme, CalcEngineFactory, ProofingCapability, ProofingIgnoreStore } from '@bendyline/squisq-editor-react';
5
5
  import { CodeBlockCopyHandler } from '@bendyline/squisq-react';
6
6
  import { FfmpegWasmLoadConfig } from '@bendyline/squisq-video';
7
7
  import { PrunePolicy, SaveVersionResult, DocumentVersionManager } from '@bendyline/squisq/versions';
8
- import { ThemePreference, AccentColor, WriteCanvasPreferences, ProofingPreferences } from './settings/index.js';
9
- export { AccentColorSettings, AccentColorSettingsProps, DEFAULT_PROOFING_PREFERENCES, DEFAULT_WRITE_CANVAS_FONT_SCHEME, ProofingSettingsControls, ProofingSettingsControlsProps, SettingsDialog, SettingsDialogProps, ThemeSettings, ThemeSettingsProps, WRITE_CANVAS_FONT_SCHEMES, WriteCanvasFontScheme, WriteCanvasFontSchemeGroup, WriteCanvasFontSchemeOption, WriteCanvasSettingsControls, WriteCanvasSettingsControlsProps, loadProofingPreferences, resolveWriteCanvasFonts, saveProofingPreferences } from './settings/index.js';
8
+ import { DocBlocksHostAiAPI, DocBlocksHostSpeechAPI } from '@bendyline/docblocks/host';
9
+ import { T as ThemePreference, A as AccentColor, I as InterfaceFontPreference, q as WriteCanvasPreferences, P as ProofingPreferences } from './Settings-DuXk6baH.js';
10
+ export { a as AccentColorSettings, b as AccentColorSettingsProps, c as AiSettingsControls, d as AiSettingsControlsProps, D as DEFAULT_INTERFACE_FONT, e as DEFAULT_PROOFING_PREFERENCES, f as DEFAULT_WRITE_CANVAS_FONT_SCHEME, g as InterfaceFontSettings, h as InterfaceFontSettingsProps, i as ProofingSettingsControls, j as ProofingSettingsControlsProps, S as SettingsDialog, k as SettingsDialogProps, l as ThemeSettings, m as ThemeSettingsProps, W as WRITE_CANVAS_FONT_SCHEMES, n as WriteCanvasFontScheme, o as WriteCanvasFontSchemeGroup, p as WriteCanvasFontSchemeOption, r as WriteCanvasSettingsControls, s as WriteCanvasSettingsControlsProps, t as loadInterfaceFont, u as loadProofingPreferences, v as resolveWriteCanvasFonts, w as saveInterfaceFont, x as saveProofingPreferences } from './Settings-DuXk6baH.js';
10
11
  import { SharedDocumentMode } from '@bendyline/docblocks/share';
11
12
  import { MediaProvider } from '@bendyline/squisq/schemas';
12
13
  import { ContentContainer } from '@bendyline/squisq/storage';
13
14
  import { VideoExportModalProps } from '@bendyline/squisq-video-react';
15
+ import { MediaEditRenderManager } from '@bendyline/squisq-video-react/media-edit';
14
16
  import { ExportBlobSaver } from './export/index.js';
15
17
  export { CoverImageSaveAdapter, CoverImageSaveOutput, DEFAULT_OPTIONS, CoverImageSaveAdapter as DashboardImageSaveAdapter, CoverImageSaveOutput as DashboardImageSaveOutput, ExportDestinationControl, ExportDialog, ExportDialogProps, ExportFormat, ExportOptions, HtmlBundle, HtmlStyle, CoverImageSaveAdapter as ImageSaveAdapter, CoverImageSaveOutput as ImageSaveOutput, buildExportFilename, createCoverImageSaveOutput, createCoverImageSaveOutput as createDashboardImageSaveOutput, createCoverImageSaveOutput as createImageSaveOutput, loadLastExportOptions, runExport, updateExportTargetExtension } from './export/index.js';
16
18
  import { DocumentSession, DocumentSessionSnapshot } from '@bendyline/docblocks/document';
17
19
  import 'react';
18
20
  import '@bendyline/squisq-formats/pptx';
21
+ import '@bendyline/squisq-formats/diagrams';
19
22
 
20
23
  /** Git decoration for a row — precomputed by FileExplorer so this node stays context-free. */
21
24
  interface FileTreeNodeBadge {
@@ -98,7 +101,24 @@ interface PinnedDocumentListItem extends PinnedDocument {
98
101
 
99
102
  type FileExplorerSortMode = 'name' | 'last-modified';
100
103
 
104
+ /** Host-supplied rendering context for regenerated outside-in files. */
105
+ interface OutsideInRenderOptions {
106
+ /**
107
+ * The workspace default theme, read at render time. Applied only to
108
+ * documents whose frontmatter names no theme of their own: every Squisq
109
+ * exporter lets an explicit theme beat the document's frontmatter.
110
+ */
111
+ defaultThemeId?: () => string | undefined;
112
+ }
113
+
114
+ /**
115
+ * The types a new document can be created as. Shared by the explorer's inline
116
+ * new-file form and the shell's New document dialog so both name the result
117
+ * the same way; `NewFileFormatOptions` renders the matching choices.
118
+ */
119
+
101
120
  type NewFileFormat = 'markdown' | 'docx' | 'xlsx' | 'pdf' | 'web-interactive' | 'web-static';
121
+
102
122
  type FileTreeChange = {
103
123
  type: 'create';
104
124
  path: string;
@@ -113,7 +133,7 @@ type FileTreeChange = {
113
133
  newPath: string;
114
134
  kind: 'file' | 'directory';
115
135
  };
116
- type FileTreeMutationHandler = (change: FileTreeChange, mutate: () => Promise<void>) => Promise<void>;
136
+ type FileTreeMutationHandler = (change: FileTreeChange, mutate: (options?: FileSystemEntryMoveOptions) => Promise<void>) => Promise<void>;
117
137
  interface WorkspaceMoveDestination {
118
138
  id: string;
119
139
  name: string;
@@ -170,10 +190,20 @@ interface FileExplorerProps {
170
190
  moveDestinations?: readonly WorkspaceMoveDestination[];
171
191
  /** When provided, shows the transient-workspace move action above the tree. */
172
192
  onMoveToWorkspace?: (workspaceId: string) => Promise<void>;
193
+ /** Rendering context (e.g. the workspace default theme) for new rendered documents. */
194
+ outsideInRender?: OutsideInRenderOptions;
195
+ /** The type the New File form preselects. Defaults to Markdown. */
196
+ defaultNewFileFormat?: NewFileFormat;
197
+ /** Called with the type of each file the New File form creates. */
198
+ onNewFileFormatUsed?: (format: NewFileFormat) => void;
199
+ /** Shows a Search button that switches the sidebar to workspace search. */
200
+ onShowSearch?: () => void;
201
+ /** Tooltip shortcut for the Search button, e.g. `Ctrl+Shift+F`. */
202
+ searchShortcutLabel?: string;
173
203
  /** Optional className for the root element. */
174
204
  className?: string;
175
205
  }
176
- declare function FileExplorer({ provider, metadataRefreshKey, activeFilePath, sortMode, onSortModeChange, activeWorkspaceId, pinnedDocuments, pinnedPaths, onPinnedDocumentSelect, onPinnedDocumentUnpin, onPinnedDocumentRename, onPinnedDocumentDelete, onTogglePin, onSelect, onOpenWorkspaceFolder, actionsForEntry, onTreeMutation, onTreeChange, onImportFiles, confirmDelete, moveDestinations, onMoveToWorkspace, className, }: FileExplorerProps): react_jsx_runtime.JSX.Element;
206
+ declare function FileExplorer({ provider, metadataRefreshKey, activeFilePath, sortMode, onSortModeChange, activeWorkspaceId, pinnedDocuments, pinnedPaths, onPinnedDocumentSelect, onPinnedDocumentUnpin, onPinnedDocumentRename, onPinnedDocumentDelete, onTogglePin, onSelect, onOpenWorkspaceFolder, actionsForEntry, onTreeMutation, onTreeChange, onImportFiles, confirmDelete, moveDestinations, onMoveToWorkspace, outsideInRender, defaultNewFileFormat, onNewFileFormatUsed, onShowSearch, searchShortcutLabel, className, }: FileExplorerProps): react_jsx_runtime.JSX.Element;
177
207
 
178
208
  /**
179
209
  * useFileTree — hook that reads from a FileSystemProvider,
@@ -224,7 +254,7 @@ interface FileTreeActions {
224
254
  /** Delete a file or directory. */
225
255
  deleteEntry: (path: string) => Promise<void>;
226
256
  /** Rename or move a file or directory, including a markdown companion folder. */
227
- renameEntry: (oldPath: string, newPath: string, kind?: 'file' | 'directory') => Promise<void>;
257
+ renameEntry: (oldPath: string, newPath: string, kind?: 'file' | 'directory', options?: FileSystemEntryMoveOptions) => Promise<void>;
228
258
  /** Force refresh the tree. */
229
259
  refresh: () => Promise<void>;
230
260
  /** Retry one failed directory without treating it as a workspace-root failure. */
@@ -244,12 +274,33 @@ interface WorkspacePickerProps {
244
274
  * the desktop when git is available — omitted, the item is hidden.
245
275
  */
246
276
  onCloneRepository?: () => void;
277
+ /**
278
+ * Called when the user chooses "Remove workspace" from a row's actions menu
279
+ * (its ⋯ button, a right-click, or Shift+F10). The host confirms and does
280
+ * the removal. Omitted, rows have no actions menu.
281
+ */
282
+ onRemoveWorkspace?: (descriptor: WorkspaceDescriptor) => void;
247
283
  /** Forces a list refresh after an external workspace-registry mutation. */
248
284
  refreshKey?: number;
249
285
  /** Optional className. */
250
286
  className?: string;
251
287
  }
252
- declare function WorkspacePicker({ activeWorkspaceId, onSelect, onOpenFolder, onCloneRepository, refreshKey, className, }: WorkspacePickerProps): react_jsx_runtime.JSX.Element;
288
+ declare function WorkspacePicker({ activeWorkspaceId, onSelect, onOpenFolder, onCloneRepository, onRemoveWorkspace, refreshKey, className, }: WorkspacePickerProps): react_jsx_runtime.JSX.Element;
289
+
290
+ /**
291
+ * Owns the active workspace's index: one per provider instance, disposed
292
+ * (cancelling any in-flight walk) when the workspace changes.
293
+ *
294
+ * The index module is loaded on demand so it stays out of the startup bundle,
295
+ * and indexing starts once the browser is idle so it never competes with the
296
+ * explorer's first listing.
297
+ */
298
+
299
+ /**
300
+ * `eager` indexes once the browser is idle; `on-demand` waits until a feature
301
+ * needs it (quick-open, search); `off` never indexes.
302
+ */
303
+ type WorkspaceIndexMode = 'eager' | 'on-demand' | 'off';
253
304
 
254
305
  interface DocBlocksShellProps {
255
306
  /**
@@ -329,6 +380,12 @@ interface DocBlocksShellProps {
329
380
  onApplyUpdate?: () => void;
330
381
  /** Host-supplied content rendered at the right edge of the editor status bar. */
331
382
  statusBarSlotRight?: React.ReactNode;
383
+ /**
384
+ * When the shared workspace index (link picker, quick-open, search) reads
385
+ * the workspace: `eager` once the app is idle (default), `on-demand` when a
386
+ * feature first needs it (hosts whose listings are expensive), `off` never.
387
+ */
388
+ workspaceIndex?: WorkspaceIndexMode;
332
389
  /** Show Copy controls on ordinary fenced code blocks (default: true). */
333
390
  showCodeCopyButton?: boolean;
334
391
  /**
@@ -348,7 +405,7 @@ interface DocBlocksShellProps {
348
405
  */
349
406
  offlineReady?: boolean;
350
407
  }
351
- declare function DocBlocksShell({ theme: hostTheme, logoUrl, issueReportVersion, appBuildDate, ffmpegWasm, calcEngineFactory, proofing, proofingDefaultEnabled, proofingIgnoreStore, homeDocumentTitle, homeDocumentPath, allowVersioning, versionBasename, versioningPrunePolicy, versioningAutoSaveIdleMs, onSaveVersion, versioningRef, updateAvailable, onApplyUpdate, statusBarSlotRight, showCodeCopyButton, onCopyCode, allowRecording, allowPresentationWindow, allowPresentationFullscreen, offlineReady, }: DocBlocksShellProps): react_jsx_runtime.JSX.Element;
408
+ declare function DocBlocksShell({ theme: hostTheme, logoUrl, issueReportVersion, appBuildDate, ffmpegWasm, calcEngineFactory, proofing, proofingDefaultEnabled, proofingIgnoreStore, homeDocumentTitle, homeDocumentPath, allowVersioning, versionBasename, versioningPrunePolicy, versioningAutoSaveIdleMs, onSaveVersion, versioningRef, updateAvailable, onApplyUpdate, statusBarSlotRight, workspaceIndex: workspaceIndexMode, showCodeCopyButton, onCopyCode, allowRecording, allowPresentationWindow, allowPresentationFullscreen, offlineReady, }: DocBlocksShellProps): react_jsx_runtime.JSX.Element;
352
409
 
353
410
  /**
354
411
  * Versioning preferences — global default + per-workspace resolution.
@@ -358,9 +415,12 @@ declare function DocBlocksShell({ theme: hostTheme, logoUrl, issueReportVersion,
358
415
  * default is `'browser-only'` so local-folder workspaces stay clean by
359
416
  * default and only IndexedDB workspaces accumulate version history.
360
417
  *
361
- * Each workspace can override the global default with its own setting
362
- * stored on the WorkspaceDescriptor. `'inherit'` (or absent) defers to
363
- * the global preference; `'on'` / `'off'` force the behavior regardless.
418
+ * Each workspace can override the global default. The override lives in
419
+ * the folder's `.docblocks/workspace.json` (`versionHistory.enabled`) so it
420
+ * travels with the folder; an older override stored on the
421
+ * WorkspaceDescriptor is still honored until the next workspace-settings
422
+ * save moves it into the file. Absent (or `'inherit'`) defers to the global
423
+ * preference; `'on'` / `'off'` force the behavior regardless.
364
424
  */
365
425
 
366
426
  type VersioningPreference = 'on' | 'browser-only' | 'off';
@@ -374,8 +434,11 @@ interface AppMenuProps {
374
434
  onThemeChange?: (theme: ThemePreference) => void;
375
435
  /** Current accent color. */
376
436
  accentColor?: AccentColor;
437
+ /** Chrome typeface: follow the OS, or use the bundled face. */
438
+ interfaceFont?: InterfaceFontPreference;
377
439
  /** Called when the user changes the accent color. */
378
440
  onAccentColorChange?: (color: AccentColor) => void;
441
+ onInterfaceFontChange?: (font: InterfaceFontPreference) => void;
379
442
  /** Current typography preferences for the editor's Write canvas. */
380
443
  writeCanvasSettings?: WriteCanvasPreferences;
381
444
  /** Called when the user changes the Write canvas typography. */
@@ -388,6 +451,8 @@ interface AppMenuProps {
388
451
  versioningPreference?: VersioningPreference;
389
452
  /** Called when the user changes the global versioning preference. */
390
453
  onVersioningPreferenceChange?: (pref: VersioningPreference) => void;
454
+ /** Opens the active workspace's own settings (`.docblocks/workspace.json`). */
455
+ onOpenWorkspaceSettings?: () => void;
391
456
  /**
392
457
  * Called when the user clicks "Download all workspaces". When omitted,
393
458
  * the menu item is hidden.
@@ -419,8 +484,20 @@ interface AppMenuProps {
419
484
  appVersion?: string;
420
485
  /** ISO build date shown in About. */
421
486
  appBuildDate?: string;
487
+ /**
488
+ * The host's AI API. When present, Settings offers an AI section; when
489
+ * omitted — a host without AI — the section is hidden.
490
+ */
491
+ ai?: DocBlocksHostAiAPI;
492
+ /**
493
+ * The host's speech API. When present, Settings offers a Speech section for
494
+ * dictation and narration models; when omitted the section is hidden.
495
+ */
496
+ speech?: DocBlocksHostSpeechAPI;
497
+ /** Opens Settings whenever it changes to a new non-zero value. */
498
+ settingsRequest?: number;
422
499
  }
423
- declare function AppMenu({ logoUrl, themePreference, onThemeChange, accentColor, onAccentColorChange, writeCanvasSettings, onWriteCanvasSettingsChange, proofingPreferences, onProofingPreferencesChange, versioningPreference, onVersioningPreferenceChange, onDownloadAllWorkspaces, onKeepBrowserData, onInstallApp, getStorageEstimate, storagePersistent, appVersion, appBuildDate, }: AppMenuProps): react_jsx_runtime.JSX.Element;
500
+ declare function AppMenu({ logoUrl, themePreference, onThemeChange, accentColor, onAccentColorChange, interfaceFont, onInterfaceFontChange, writeCanvasSettings, onWriteCanvasSettingsChange, proofingPreferences, onProofingPreferencesChange, versioningPreference, onVersioningPreferenceChange, onOpenWorkspaceSettings, onDownloadAllWorkspaces, onKeepBrowserData, onInstallApp, getStorageEstimate, storagePersistent, appVersion, appBuildDate, ai, speech, settingsRequest, }: AppMenuProps): react_jsx_runtime.JSX.Element;
424
501
 
425
502
  interface ExportToolbarControlsProps {
426
503
  /** Currently selected file path — used to derive the download filename. */
@@ -435,6 +512,15 @@ interface ExportToolbarControlsProps {
435
512
  workspaceContainer?: ContentContainer | null;
436
513
  /** Active document media provider used to preload audio and video export assets. */
437
514
  mediaProvider?: MediaProvider | null;
515
+ /**
516
+ * Processed-audio renders for media-edit recipes. Video export waits for
517
+ * pending renders and mixes the processed audio in place of the original.
518
+ */
519
+ mediaEditRenders?: MediaEditRenderManager | null;
520
+ /** The host's speech API; when present the menu offers "Export audio…". */
521
+ speech?: DocBlocksHostSpeechAPI;
522
+ /** Workspace default theme, pre-selected for documents without their own. */
523
+ defaultThemeId?: string;
438
524
  /** Override the default browser download behavior for host-provided save flows. */
439
525
  saveBlob?: ExportBlobSaver;
440
526
  /** Optional host adapter for displaying, picking, and saving to a native target path. */
@@ -460,6 +546,7 @@ interface ExportDestinationTarget {
460
546
  displayPath: string;
461
547
  }
462
548
  interface ExportDestinationAdapter {
549
+ shareBlob?: (blob: Blob, filename: string) => Promise<'shared' | 'presented' | 'cancelled'>;
463
550
  resolveTarget: (filename: string) => Promise<ExportDestinationTarget>;
464
551
  pickTarget: (filename: string, currentTarget?: ExportDestinationTarget | null) => Promise<ExportDestinationTarget | null>;
465
552
  saveBlob: (blob: Blob, filename: string, target?: ExportDestinationTarget | null) => Promise<ExportDestinationTarget | null>;
@@ -488,4 +575,4 @@ interface UseDocumentSessionResult {
488
575
  */
489
576
  declare function useDocumentSession(autoSaveDelayMs?: number): UseDocumentSessionResult;
490
577
 
491
- export { AccentColor, AppMenu, type AppMenuProps, DocBlocksShell, type DocBlocksShellProps, ExportBlobSaver, type ExportDestinationAdapter, type ExportDestinationTarget, ExportToolbarControls, type ExportToolbarControlsProps, FileExplorer, type FileExplorerProps, type FileExplorerSortMode, type FileTreeActions, type FileTreeChange, type FileTreeMutationHandler, FileTreeNode, type FileTreeNodeProps, type FileTreeReadIssue, type FileTreeState, type NewFileFormat, ProofingPreferences, ThemePreference, type UseDocumentSessionResult, WorkspacePicker, type WorkspacePickerProps, WriteCanvasPreferences, useDocumentSession, useFileTree };
578
+ export { AccentColor, AppMenu, type AppMenuProps, DocBlocksShell, type DocBlocksShellProps, ExportBlobSaver, type ExportDestinationAdapter, type ExportDestinationTarget, ExportToolbarControls, type ExportToolbarControlsProps, FileExplorer, type FileExplorerProps, type FileExplorerSortMode, type FileTreeActions, type FileTreeChange, type FileTreeMutationHandler, FileTreeNode, type FileTreeNodeProps, type FileTreeReadIssue, type FileTreeState, InterfaceFontPreference, type NewFileFormat, ProofingPreferences, ThemePreference, type UseDocumentSessionResult, WorkspacePicker, type WorkspacePickerProps, WriteCanvasPreferences, useDocumentSession, useFileTree };