AbstractProtected AbstractexportersExporter for every format. Subclasses spread ExportManager.localExporters and add the formats they can produce.
ProtectedlocalExporters that need only the local model and the renderer
ProtectedmodelProtectedbuildProtectedbuildRelease every object URL still held and cancel the pending revocations
Export the content and hand the resulting file to the browser.
Format to download; pdf opens the print flow instead of saving a file
Which symbols to export, plus the file name. The PDF settings
(format/orientation/mode/scale) are ignored by every other format.
Export the content in the given format.
Format to export to; the resolved type follows from it
Optionaloptions: TExportOptions
Which symbols to export
Promise resolving with the exported content
ProtectedexportOptionaloptions: TExportOptionsProtectedexportRasterize the rendered symbols to PNG.
Optionaloptions: TExportOptionsProtectedexportOptionaloptions: TExportOptionsProtectedgetBuild the download file name. The timestamp is a truncated ISO 8601 instant so the name is
locale-independent and free of / and :, which browsers mangle in file names.
Optionalfilename: stringProtectedresolveResolve which symbols an export covers. An explicit symbols list always wins over scope.
Optionaloptions: TExportOptionsProtectedtriggerProtectedloggerStatic ReadonlyOBJECT_Delay before an object URL handed to the browser is revoked. Revoking synchronously after the anchor click cancels the download in some browsers, so the URL outlives the click by a beat.
Shared implementation behind the two-function export API —
exportAsfor content,downloadfor files. Handles the formats that need nothing but the local model and the renderer (json,svg,png) plus thepdfprint flow, and leaves the recognition-derived formats to subclasses through ExportManager.exporters.Remarks
The canvas is typed as TInteractiveInkCanvas because every format needs symbol-level access (
model.symbols,getSymbolsBounds) thatInkCanvasdoes not expose. Wiring another variant later means widening this type, not reworking callers.