oasis-editor 0.0.134 → 0.0.136
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/{OasisEditorApp-B2f15Gpe.js → OasisEditorApp-DPrjPRTW.js} +772 -1033
- package/dist/app/controllers/EditorCommandsController.d.ts +2 -0
- package/dist/app/controllers/documentIO/DocumentImporter.d.ts +3 -1
- package/dist/app/controllers/documentIO/importProgress.d.ts +1 -1
- package/dist/app/controllers/useEditorDocumentIO.d.ts +3 -1
- package/dist/assets/{importDocxWorker-CCwhxVSR.js → importDocxWorker-B0cSSI12.js} +1 -1
- package/dist/core/commands/builtinCommands.d.ts +1 -1
- package/dist/core/commands/image.d.ts +15 -1
- package/dist/core/commands/publicCommandTypes.d.ts +4 -0
- package/dist/core/commands/table/tableCellStyleCommands.d.ts +7 -0
- package/dist/core/lineDash.d.ts +16 -0
- package/dist/core/model/index.d.ts +1 -1
- package/dist/core/model/types/primitives.d.ts +19 -0
- package/dist/core/smallCaps.d.ts +7 -0
- package/dist/core/tableStyleResolver.d.ts +5 -0
- package/dist/export/docx/docxTypes.d.ts +2 -1
- package/dist/export/docx/text/drawingContainerXml.d.ts +7 -1
- package/dist/export/pdf/draw/drawImageObject.d.ts +14 -0
- package/dist/export/pdf/fonts/PdfFontRegistry.d.ts +1 -0
- package/dist/export/pdf/fonts/officeFontAssets.d.ts +2 -0
- package/dist/export/pdf/writer/pdfTypes.d.ts +2 -0
- package/dist/i18n/locales/en.d.ts +19 -2
- package/dist/i18n/locales/pt-BR.d.ts +19 -2
- package/dist/{index-ogn0S9F3.js → index-Cbwb1bgI.js} +3771 -1616
- package/dist/oasis-editor.css +1 -1
- package/dist/oasis-editor.js +49 -49
- package/dist/oasis-editor.umd.cjs +4 -4
- package/dist/plugins/internal/essentialsCapabilities.d.ts +19 -1
- package/dist/text/fonts/FontMetricsProvider.d.ts +1 -1
- package/dist/text/fonts/core/types.d.ts +1 -1
- package/dist/text/fonts/decoders/WoffDecoder.d.ts +8 -0
- package/dist/text/fonts/preciseFontMetrics.d.ts +9 -0
- package/dist/text/fonts/remoteWebFonts.d.ts +16 -0
- package/dist/ui/OasisEditorAppProps.d.ts +4 -0
- package/dist/ui/OasisEditorEditorProps.d.ts +1 -0
- package/dist/ui/app/buildEditorViewProps.d.ts +1 -0
- package/dist/ui/app/createAppCommandsController.d.ts +2 -0
- package/dist/ui/app/createEditorCommandRuntime.d.ts +1 -0
- package/dist/ui/app/documentFontPreparation.d.ts +23 -0
- package/dist/ui/canvas/canvasFontResolution.d.ts +2 -2
- package/dist/ui/canvas/paragraph/canvasInlineImage.d.ts +1 -1
- package/dist/ui/canvas/paragraph/canvasTextEffects.d.ts +1 -0
- package/dist/ui/components/Toolbar/TableBordersMenu.d.ts +6 -0
- package/dist/ui/components/Toolbar/TableStyleGallery.d.ts +9 -0
- package/dist/ui/components/Toolbar/TableStyleOptions.d.ts +6 -0
- package/dist/ui/components/Toolbar/pictureBorderPresets.d.ts +19 -0
- package/dist/ui/components/Toolbar/presets/defaultToolbar/buttonSpecs.d.ts +1 -0
- package/dist/ui/components/Toolbar/primitives/ColorGrids.d.ts +20 -0
- package/dist/ui/components/Toolbar/primitives/PictureBorderPicker.d.ts +37 -0
- package/dist/ui/components/Toolbar/primitives/WideMenuButton.d.ts +27 -0
- package/dist/ui/components/Toolbar/schema/items.d.ts +23 -1
- package/dist/ui/editorUiTypes.d.ts +1 -0
- package/dist/ui/textMeasurement/fontMetrics.d.ts +3 -2
- package/package.json +1 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ImageBorderPatch } from '../../core/commands/image.js';
|
|
1
2
|
import { EditorParagraphListStyle, EditorParagraphStyle, EditorSection, EditorState, EditorTextStyle } from '../../core/model.js';
|
|
2
3
|
import { TextCaseMode } from '../../core/commands/text.js';
|
|
3
4
|
import { BooleanStyleKey, ParagraphStyleKey, ToolbarStyleState } from '../../ui/toolbarStyleState.js';
|
|
@@ -47,6 +48,7 @@ declare function createEditorCommandsControllerImpl(deps: EditorCommandsControll
|
|
|
47
48
|
applyImageWidthCmCommand: (cm: number) => void;
|
|
48
49
|
applyImageHeightCmCommand: (cm: number) => void;
|
|
49
50
|
applyImageCropAspectCommand: (preset: string) => void;
|
|
51
|
+
applyImageBorderCommand: (patch: ImageBorderPatch) => void;
|
|
50
52
|
handleListTab: (direction: "indent" | "outdent") => boolean;
|
|
51
53
|
handleListEnter: () => boolean;
|
|
52
54
|
handleListBoundaryBackspace: (event: KeyboardEvent & {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditorState } from '../../../core/model.js';
|
|
1
|
+
import { EditorState, getDocumentParagraphs } from '../../../core/model.js';
|
|
2
2
|
import { EditorLogger } from '../../../utils/logger.js';
|
|
3
3
|
import { ImportProgressPhase } from './importProgress.js';
|
|
4
4
|
|
|
@@ -7,6 +7,8 @@ export interface DocumentImporterDeps {
|
|
|
7
7
|
stabilizeLayoutAfterImport: () => Promise<void>;
|
|
8
8
|
resetEditorChromeState: () => void;
|
|
9
9
|
focusInput: () => void;
|
|
10
|
+
requestLocalFontAccess: () => Promise<boolean>;
|
|
11
|
+
prepareDocumentFonts: (document: Parameters<typeof getDocumentParagraphs>[0]) => Promise<void>;
|
|
10
12
|
setImportPhase: (phase: ImportProgressPhase, subProgress?: number) => void;
|
|
11
13
|
clearImportProgressSoon: () => void;
|
|
12
14
|
now: () => number;
|
|
@@ -6,7 +6,7 @@ import { ImportStage } from '../../../import/DocumentFormatImporter.js';
|
|
|
6
6
|
* reference the phase type without importing the hook (which imports the
|
|
7
7
|
* importer), avoiding a cycle.
|
|
8
8
|
*/
|
|
9
|
-
export type ImportProgressPhase = "reading-file" | ImportStage | "applying-editor-state" | "stabilizing-layout" | "done" | "error";
|
|
9
|
+
export type ImportProgressPhase = "reading-file" | ImportStage | "preparing-fonts" | "applying-editor-state" | "stabilizing-layout" | "done" | "error";
|
|
10
10
|
export interface ImportProgressState {
|
|
11
11
|
phase: ImportProgressPhase;
|
|
12
12
|
progress: number;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MergeKey } from '../../core/transactionMergeKeys.js';
|
|
2
|
-
import { EditorState, EditorPosition } from '../../core/model.js';
|
|
2
|
+
import { EditorState, EditorPosition, EditorDocument } from '../../core/model.js';
|
|
3
3
|
import { EditorLogger } from '../../utils/logger.js';
|
|
4
4
|
import { ImportProgressState } from './documentIO/importProgress.js';
|
|
5
5
|
|
|
@@ -15,6 +15,8 @@ export interface UseEditorDocumentIOProps {
|
|
|
15
15
|
stabilizeLayoutAfterImport: () => Promise<void>;
|
|
16
16
|
resetEditorChromeState: () => void;
|
|
17
17
|
focusInput: () => void;
|
|
18
|
+
requestLocalFontAccess: () => Promise<boolean>;
|
|
19
|
+
prepareDocumentFonts: (document: EditorDocument) => Promise<void>;
|
|
18
20
|
logger: EditorLogger;
|
|
19
21
|
}
|
|
20
22
|
export declare function createEditorDocumentIO(deps: UseEditorDocumentIOProps): ReturnType<typeof createEditorDocumentIOImpl>;
|