platejs 54.0.0-beta.2 → 54.0.0-beta.3
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/README.md +1 -1
- package/THIRD_PARTY_NOTICES.md +56 -0
- package/dist/{AIChatRequestContext-BMVWhfPV.d.ts → AIChatRequestContext-DY104TqL.d.ts} +2 -2
- package/dist/{BaseSuggestionPlugin-DBl3fqnm.d.ts → BaseSuggestionPlugin-Deo6n6Fs.d.ts} +7 -3
- package/dist/{PlateStatic-DhNv2ejp.d.ts → PlateStatic-CJX5bKuv.d.ts} +7 -7
- package/dist/ai/index.d.ts +1 -1
- package/dist/ai/react/AIChatPlugin.js +113 -78
- package/dist/ai/react/CopilotPlugin.js +1 -1
- package/dist/ai/react/index.d.ts +23 -16
- package/dist/authored/index.d.ts +4 -4
- package/dist/code-block/codemirror/createCodeMirrorAdapter.js +12 -9
- package/dist/code-block/codemirror/index.d.ts +1 -1
- package/dist/{combobox-DkBGgyd3.d.ts → combobox-DAOYWuvC.d.ts} +2 -2
- package/dist/{comparison-types-CYnJ35qU.d.ts → comparison-types-Dt-unJZY-DCddmbSD.d.ts} +10 -2
- package/dist/compiler/index.d.ts +2 -2
- package/dist/{core-BJG8l_mk.d.ts → core-ClHasORr.d.ts} +433 -95
- package/dist/diff/index.d.ts +2 -2
- package/dist/docs/ai.md +4 -3
- package/dist/docs/api/core/plate-components.md +0 -19
- package/dist/docs/api/core/plate-controller.md +4 -2
- package/dist/docs/api/core/plate-plugin.md +3 -0
- package/dist/docs/api/core/plate-store.md +3 -3
- package/dist/docs/api/dom.md +14 -4
- package/dist/docs/api/editor-transforms.md +2 -1
- package/dist/docs/api/react-hooks.md +25 -11
- package/dist/docs/authored-changes.md +5 -2
- package/dist/docs/basic-blocks.md +42 -29
- package/dist/docs/blockquote.md +5 -3
- package/dist/docs/board.md +63 -8
- package/dist/docs/code-block.md +47 -0
- package/dist/docs/discussion.md +1 -1
- package/dist/docs/docx.md +1 -1
- package/dist/docs/dom-coverage.md +5 -0
- package/dist/docs/examples/editable-voids.md +2 -3
- package/dist/docs/external-text.md +2 -0
- package/dist/docs/field.md +370 -0
- package/dist/docs/find.md +9 -6
- package/dist/docs/form.md +2 -0
- package/dist/docs/heading.md +6 -0
- package/dist/docs/installation/manual.md +0 -4
- package/dist/docs/link.md +3 -3
- package/dist/docs/llms.txt +4 -2
- package/dist/docs/markdown.md +176 -8
- package/dist/docs/plugin-components.md +13 -10
- package/dist/docs/plugin-input-rules.md +4 -12
- package/dist/docs/prompt-editor.md +205 -0
- package/dist/docs/roots.md +8 -6
- package/dist/docs/rtl.md +6 -4
- package/dist/docs/selection.md +7 -4
- package/dist/docs/suggestion.md +1 -1
- package/dist/docs/toolbar.md +26 -30
- package/dist/docs/upload.md +106 -17
- package/dist/docx/export/index.d.ts +3 -3
- package/dist/docx/export/lib/docxStaticComponents.js +12 -2
- package/dist/docx/export/lib/exportDocx.js +29 -5
- package/dist/docx/export/lib/reviewPart.js +1 -1
- package/dist/docx/export/lib/reviewProjection.js +10 -8
- package/dist/docx/import/index.d.ts +4 -4
- package/dist/docx/paste/index.d.ts +4 -4
- package/dist/dom/index.d.ts +1 -6
- package/dist/dom/plite-dom.internal.js +2 -2
- package/dist/excalidraw/index.d.ts +3 -2
- package/dist/excalidraw/react/index.d.ts +3 -2
- package/dist/facade.js +2 -2
- package/dist/features/basic-nodes/lib/BaseBlockPlugins.js +13 -5
- package/dist/features/basic-nodes/lib/BaseHeadingPlugins.js +32 -10
- package/dist/features/board/index.d.ts +2 -2
- package/dist/features/board/lib/BaseBoardPlugin.js +14 -1
- package/dist/features/board/lib/boardStroke.internal.js +13 -1
- package/dist/features/board/lib/boardTypes.internal.js +16 -0
- package/dist/features/callout/index.d.ts +3 -2
- package/dist/features/code-block/lib/BaseCodeBlockPlugin.js +14 -5
- package/dist/features/combobox/index.d.ts +2 -2
- package/dist/features/comments/index.d.ts +1 -1
- package/dist/features/date/index.d.ts +3 -2
- package/dist/features/details/index.d.ts +3 -2
- package/dist/features/details/lib/BaseDetailsPlugin.js +10 -10
- package/dist/features/field/index.d.ts +2 -0
- package/dist/features/field/index.js +2 -0
- package/dist/features/field/lib/BaseFieldPlugin.js +414 -0
- package/dist/features/field/lib/fieldRules.internal.js +42 -0
- package/dist/features/find/index.d.ts +3 -2
- package/dist/features/footnote/index.d.ts +1 -1
- package/dist/features/ink/index.d.ts +1 -1
- package/dist/features/ink/lib/BaseInkPlugin.js +126 -103
- package/dist/features/ink/lib/inkCodec.internal.js +130 -0
- package/dist/features/ink/lib/inkGone.internal.js +229 -48
- package/dist/features/ink/lib/inkPlaces.internal.js +533 -62
- package/dist/features/layout/index.d.ts +1 -1
- package/dist/features/link/lib/BaseLinkPlugin.js +6 -4
- package/dist/features/lint/index.d.ts +3 -2
- package/dist/features/media/index.d.ts +1 -1
- package/dist/features/media/lib/media/parseMediaUrl.js +11 -1
- package/dist/features/media/lib/media-embed/BaseMediaEmbedPlugin.js +6 -2
- package/dist/features/mention/index.d.ts +5 -4
- package/dist/features/suggestion/index.d.ts +1 -1
- package/dist/features/table/index.d.ts +1 -1
- package/dist/features/table/lib/BaseTablePlugin.js +14 -8
- package/dist/features/table/lib/internal/selection.js +4 -2
- package/dist/features/toc/index.d.ts +1 -1
- package/dist/features/upload/index.d.ts +2 -2
- package/dist/features/upload/lib/BaseUploadPlugin.js +464 -250
- package/dist/history/index.d.ts +2 -2
- package/dist/html/index.d.ts +3 -3
- package/dist/html/server/index.d.ts +1 -1
- package/dist/{htmlTypes-DjeFG3P8.d.ts → htmlTypes-cg_cWsaN.d.ts} +2 -31
- package/dist/hyperscript/index.d.ts +1 -1
- package/dist/{index-D1CFXA-i.d.ts → index-8WO2vI0U.d.ts} +475 -143
- package/dist/{index-DaM37gF6.d.ts → index-B5mYEawV.d.ts} +37 -21
- package/dist/{index-Bq3sdm3S.d.ts → index-BZWFoUXt.d.ts} +5 -4
- package/dist/{index-DdIRduDG.d.ts → index-C0POz7rg.d.ts} +3 -2
- package/dist/{index-Bxfvicyy.d.ts → index-C1_JIhL4.d.ts} +4 -3
- package/dist/{index-DC_MNGyu.d.ts → index-C35V_hj0.d.ts} +3 -3
- package/dist/{index-kLKMc-pI.d.ts → index-C6ql9pKw.d.ts} +2 -2
- package/dist/{index-hsC_sOn2.d.ts → index-C9DiGDVj.d.ts} +35 -5
- package/dist/{index-DTgaSxKr.d.ts → index-CLsEe3LY.d.ts} +40 -4
- package/dist/{index-CT7miqQN.d.ts → index-CdOLsPaW.d.ts} +29 -9
- package/dist/{index-DLA2DUR2.d.ts → index-CktYvOgk.d.ts} +4 -3
- package/dist/{index-BBKGrsG3.d.ts → index-Cmuluh6f.d.ts} +1 -1
- package/dist/{index-BiQerPJS.d.ts → index-CzLwBZpY.d.ts} +2 -2
- package/dist/{index-DzD6BIFJ.d.ts → index-D3-2iM1b.d.ts} +7 -5
- package/dist/{index-Cl77E9yr.d.ts → index-DKOFvteF.d.ts} +2 -2
- package/dist/{index-iaZOhA76.d.ts → index-DPWyk3lG-DOYwohXO.d.ts} +1 -1
- package/dist/index-DQnjqtQa.d.ts +678 -0
- package/dist/{index-CcZbqPqk.d.ts → index-Do9pj1GK.d.ts} +73 -39
- package/dist/{index-BU6k1Aev.d.ts → index-DpltOCot-A2b3p3Eb.d.ts} +4735 -4586
- package/dist/{index-Bc2Yg_2j.d.ts → index-HPYawTae-BCUQLEWF.d.ts} +2 -2
- package/dist/{index-BkR7-GLI.d.ts → index-baQOK89E.d.ts} +2 -2
- package/dist/{index-D5W-p9bS.d.ts → index-oIJAZxc2.d.ts} +49 -4
- package/dist/{index-xdmCBvlT.d.ts → index-r7yb77Wy.d.ts} +3 -2
- package/dist/index.d.ts +4 -4
- package/dist/{react/internal → internal}/penStroke.internal.js +1 -1
- package/dist/internal/plugin/OverridePlugin.js +101 -119
- package/dist/internal/plugin/collectPlateNodeMappings.js +5 -1
- package/dist/internal/plugin/pastedUploadFiles.js +4 -0
- package/dist/internal/plugin/resolvePlugin.js +1 -1
- package/dist/internal/plugin/resolvePlugins.js +3 -0
- package/dist/internal/plugin/uploadDrafts.js +6 -0
- package/dist/internal/utils/mergePlugins.js +1 -0
- package/dist/lib/plugins/element-id/ElementIdPlugin.js +8 -2
- package/dist/lib/plugins/html/HtmlPlugin.js +9 -0
- package/dist/lib/plugins/html/htmlSafety.js +1 -1
- package/dist/lib/plugins/input-rules/InputRulesPlugin.js +5 -15
- package/dist/lib/plugins/input-rules/inputRuleVeto.internal.js +16 -0
- package/dist/markdown/index.d.ts +2 -2
- package/dist/markdown/index.js +2 -1
- package/dist/markdown/lib/MarkdownPlugin.js +16 -9
- package/dist/markdown/lib/RawHtmlPlugin.js +24 -0
- package/dist/markdown/lib/deserializer/mdastToSlate.js +12 -2
- package/dist/markdown/lib/internal/markdownConversion.js +773 -74
- package/dist/markdown/lib/internal/markdownDiagnostics.js +18 -7
- package/dist/markdown/lib/internal/markdownFrontmatter.js +102 -0
- package/dist/markdown/lib/internal/markdownIntrinsics.js +125 -43
- package/dist/markdown/lib/internal/markdownLine.js +5 -3
- package/dist/markdown/lib/internal/markdownMappings.js +19 -7
- package/dist/markdown/lib/internal/markdownOpenTail.js +381 -0
- package/dist/markdown/lib/internal/markdownRawHtml.js +314 -0
- package/dist/markdown/lib/internal/markdownSegments.js +57 -48
- package/dist/markdown/lib/internal/markdownTags.js +22 -8
- package/dist/markdown/lib/serializer/convertNodesSerialize.js +10 -8
- package/dist/markdown/lib/serializer/convertPhrasingSerialize.js +226 -0
- package/dist/markdown/lib/serializer/listToMdastTree.js +2 -0
- package/dist/math/index.d.ts +3 -2
- package/dist/math/react/index.d.ts +4 -3
- package/dist/migrations/index.d.ts +3 -3
- package/dist/pagination/index.d.ts +1 -1
- package/dist/pagination/react/index.d.ts +4 -4
- package/dist/react/components/EditorContentView.internal.js +17 -8
- package/dist/react/components/EditorProvider.js +5 -5
- package/dist/react/components/Plate.js +103 -122
- package/dist/react/components/PlateContainer.js +40 -32
- package/dist/react/components/PlateController.js +28 -16
- package/dist/react/components/PlateRoot.internal.js +3 -2
- package/dist/react/core.js +4 -4
- package/dist/react/features/board/BoardSurface.js +116 -87
- package/dist/react/features/board/boardClipboard.internal.js +15 -5
- package/dist/react/features/board/boardGesture.internal.js +6 -3
- package/dist/react/features/board/boardIndex.internal.js +7 -18
- package/dist/react/features/board/boardPictures.internal.js +19 -13
- package/dist/react/features/board/boardView.internal.js +184 -49
- package/dist/react/features/board/boardVoice.internal.js +10 -11
- package/dist/react/features/board/index.d.ts +64 -18
- package/dist/react/features/callout/index.d.ts +3 -2
- package/dist/react/features/combobox/index.d.ts +8 -8
- package/dist/react/features/comments/index.d.ts +6 -5
- package/dist/react/features/date/index.d.ts +4 -3
- package/dist/react/features/details/index.d.ts +4 -3
- package/dist/react/features/field/FieldPlugin.js +34 -0
- package/dist/react/features/field/index.d.ts +312 -0
- package/dist/react/features/field/index.js +2 -0
- package/dist/react/features/footnote/index.d.ts +7 -6
- package/dist/react/features/format-painter/index.d.ts +4 -3
- package/dist/react/features/ink/InkContent.js +313 -0
- package/dist/react/features/ink/index.d.ts +57 -29
- package/dist/react/features/ink/index.js +2 -2
- package/dist/react/features/ink/inkCapture.internal.js +39 -17
- package/dist/react/features/ink/inkInput.internal.js +1 -1
- package/dist/react/features/ink/inkLayout.internal.js +6 -3
- package/dist/react/features/ink/inkPaint.internal.js +78 -2
- package/dist/react/features/ink/inkPlacement.internal.js +331 -104
- package/dist/react/features/ink/inkWatch.internal.js +7 -5
- package/dist/react/features/layout/index.d.ts +5 -4
- package/dist/react/features/media/index.d.ts +5 -4
- package/dist/react/features/mention/index.d.ts +6 -5
- package/dist/react/features/resizable/Resizable.js +4 -6
- package/dist/react/features/resizable/index.d.ts +5 -5
- package/dist/react/features/suggestion/index.d.ts +6 -5
- package/dist/react/features/table/TablePlugin.js +4 -11
- package/dist/react/features/table/index.d.ts +8 -7
- package/dist/react/features/toc/index.d.ts +2 -2
- package/dist/react/features/upload/index.d.ts +11 -6
- package/dist/react/index.d.ts +6 -6
- package/dist/react/index.js +4 -4
- package/dist/react/internal/plate-context.js +425 -188
- package/dist/react/plite-react.js +2 -2
- package/dist/react/plugins/navigation-feedback/NavigationFeedbackPlugin.js +12 -10
- package/dist/react/stores/plate/useEditor.js +32 -14
- package/dist/react/stores/plate/useEditorHistory.js +55 -0
- package/dist/react/stores/plate/useEditorSelector.js +66 -21
- package/dist/react/utils/pipeRenderElement.internal.js +1 -1
- package/dist/react/utils/pluginRenderElement.internal.js +1 -1
- package/dist/react/virtualized.d.ts +4 -4
- package/dist/{source-CNKy99Th.d.ts → source-aUwpNnAw.d.ts} +4 -4
- package/dist/static/index.d.ts +18 -18
- package/dist/static/internal/renderStaticHtmlWithOverrides.js +2 -2
- package/dist/static/internal/staticPresentation.js +4 -4
- package/dist/static/internal/writeStaticSelectionClipboardData.js +7 -2
- package/dist/tabbable/index.d.ts +1 -1
- package/dist/tabbable/react/index.d.ts +3 -3
- package/dist/testing/index.d.ts +3 -3
- package/dist/yjs/index.d.ts +1 -1
- package/dist/yjs/react/index.d.ts +6 -6
- package/package.json +20 -2
- package/dist/markdown/lib/serializer/convertTextsSerialize.js +0 -163
- package/dist/react/components/EditorSelectionView.js +0 -40
- package/dist/react/features/ink/InkLayer.js +0 -218
- package/dist/react/internal/createPlateTargetScope.js +0 -62
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Cl as TextSelection, H as Descendant, Mc as Selection, Si as Element, Y as Editor, Za as Path, cl as Text } from "./index-DpltOCot-A2b3p3Eb.js";
|
|
2
2
|
/**
|
|
3
3
|
* All tokens inherit from a single constructor for `instanceof` checking.
|
|
4
4
|
*/
|
|
@@ -108,4 +108,4 @@ declare const jsx: <S extends ("anchor" | "cursor" | "editor" | "element" | "foc
|
|
|
108
108
|
selection: typeof createSelection;
|
|
109
109
|
text: typeof createText;
|
|
110
110
|
} & {})[S]>;
|
|
111
|
-
export {
|
|
111
|
+
export { createEditorFixture as a, jsx as c, createEditor as i, HyperscriptEditorFixture as n, createHyperscript as o, HyperscriptShorthands as r, createText as s, HyperscriptCreators as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as CarriedRun, Et as EditorEffect, Io as PluginTypeProvider, J as DocumentChange, Mc as Selection, Mi as HistoryApi, Rn as EditorSchemaIdentity, Tu as encodeEditorSelection, Y as Editor, bs as RootFactsJson, eu as TxDeclaredMethod, nu as TxOnlyMethod, ro as Plugin, ru as Value, wu as encodeEditorEffect } from "./index-DpltOCot-A2b3p3Eb.js";
|
|
2
2
|
interface Batch<_V extends Value = Value> {
|
|
3
3
|
/** Canonical change to apply when this batch is consumed. */
|
|
4
4
|
readonly change: DocumentChange;
|
|
@@ -163,4 +163,4 @@ type HistoryPlugin<TEnabled extends boolean | undefined = undefined> = Plugin<Hi
|
|
|
163
163
|
type HistoryAction = 'redo' | 'undo';
|
|
164
164
|
/** Create the inverse-change history plugin. */
|
|
165
165
|
declare const history: <const TEnabled extends boolean | undefined = undefined>(options?: HistoryOptions<TEnabled>) => HistoryPlugin<TEnabled>;
|
|
166
|
-
export {
|
|
166
|
+
export { HistoryJSON as a, HistoryPluginTypeProvider as c, HistoryTxApi as d, history as f, HistoryControlTx as i, HistoryPluginTypes as l, History as n, HistoryOptions as o, HistoryBatchJSON as r, HistoryPlugin as s, Batch as t, HistoryStateApi as u };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "./htmlTypes-
|
|
3
|
-
import {
|
|
1
|
+
import { H as Descendant, Qo as PropertyJsonDescriptor, Si as Element, Vs as SchemaElementProperties, Vt as EditorJsonValue, Ws as SchemaElementPropertyDefinition, Zo as PropertyEnumDescriptor, _c as SchemaPropertyTypeChangePolicy, cs as PropertyValueOf, es as PropertyNumberDescriptor, eu as TxDeclaredMethod, gc as SchemaPropertySplitPolicy, hc as SchemaPropertyRole, is as PropertyStringDescriptor, j as ContentSlice, ki as ElementOf, ls as PropertyValueOptions, oc as SchemaPropertyCopyPolicy, os as PropertyValueDescriptor, pc as SchemaPropertyLandingPolicy, ri as EditorUniqueHolder, ss as PropertyValueKind, xa as NodeKey } from "./index-DpltOCot-A2b3p3Eb.js";
|
|
2
|
+
import "./htmlTypes-cg_cWsaN.js";
|
|
3
|
+
import { Ga as DefinitionOf, _ as BasePlugin, ct as BlockInsertOptions } from "./core-ClHasORr.js";
|
|
4
4
|
import { nanoid } from "nanoid";
|
|
5
5
|
declare const BOARD_DASHES: readonly ['dashed', 'dotted', 'solid'];
|
|
6
6
|
declare const BOARD_STYLE_SIZES: readonly ['l', 'm', 's', 'xl'];
|
|
@@ -953,6 +953,12 @@ type BoardNoteElement = ElementOf<typeof BaseBoardNotePlugin>;
|
|
|
953
953
|
* `BOARD_STROKE_REACH`, or by half a side shorter than twice that.
|
|
954
954
|
*/
|
|
955
955
|
type BoardStrokePoints = readonly number[];
|
|
956
|
+
/** Where a stroke draws: an SVG path over a box of `width` by `height`. */
|
|
957
|
+
type BoardStrokePath = Readonly<{
|
|
958
|
+
height: number;
|
|
959
|
+
path: string;
|
|
960
|
+
width: number;
|
|
961
|
+
}>;
|
|
956
962
|
/** A point of a pen line in board coordinates, with its pressure from 0 to 1. */
|
|
957
963
|
type BoardInkPoint = readonly [x: number, y: number, pressure: number];
|
|
958
964
|
declare const isBoardStrokePoints: (value: unknown) => value is BoardStrokePoints;
|
|
@@ -1120,12 +1126,34 @@ declare const BaseBoardPlugin: BasePlugin<Readonly<{
|
|
|
1120
1126
|
}>>, Readonly<{
|
|
1121
1127
|
kind: 'types';
|
|
1122
1128
|
types: string[];
|
|
1129
|
+
}>, Readonly<{
|
|
1130
|
+
key: string;
|
|
1131
|
+
map: (value: Readonly<{
|
|
1132
|
+
x: number;
|
|
1133
|
+
y: number;
|
|
1134
|
+
}> | Readonly<{
|
|
1135
|
+
frame: string;
|
|
1136
|
+
frameOrigin: BoardPlace;
|
|
1137
|
+
x: number;
|
|
1138
|
+
y: number;
|
|
1139
|
+
}>, renamed: (name: string) => string | undefined) => Readonly<{
|
|
1140
|
+
x: number;
|
|
1141
|
+
y: number;
|
|
1142
|
+
}> | Readonly<{
|
|
1143
|
+
frame: string;
|
|
1144
|
+
frameOrigin: BoardPlace;
|
|
1145
|
+
x: number;
|
|
1146
|
+
y: number;
|
|
1147
|
+
}>;
|
|
1123
1148
|
}>>;
|
|
1124
1149
|
readonly shapeId: SchemaElementPropertyDefinition<PropertyStringDescriptor<{
|
|
1125
1150
|
readonly generate: typeof nanoid;
|
|
1126
1151
|
}>, Readonly<{
|
|
1127
1152
|
kind: 'types';
|
|
1128
1153
|
types: readonly string[];
|
|
1154
|
+
}>, Readonly<{
|
|
1155
|
+
key: string;
|
|
1156
|
+
map: (value: string, renamed: (name: string) => string | undefined) => string;
|
|
1129
1157
|
}>>;
|
|
1130
1158
|
readonly size: SchemaElementPropertyDefinition<PropertyJsonDescriptor<Readonly<{
|
|
1131
1159
|
height: number;
|
|
@@ -1154,6 +1182,15 @@ declare const BaseBoardPlugin: BasePlugin<Readonly<{
|
|
|
1154
1182
|
}>>, Readonly<{
|
|
1155
1183
|
kind: 'types';
|
|
1156
1184
|
types: string[];
|
|
1185
|
+
}>, Readonly<{
|
|
1186
|
+
key: string;
|
|
1187
|
+
map: (value: Readonly<{
|
|
1188
|
+
height: number;
|
|
1189
|
+
width: number;
|
|
1190
|
+
}>, renamed: (name: string) => string | undefined) => Readonly<{
|
|
1191
|
+
height: number;
|
|
1192
|
+
width: number;
|
|
1193
|
+
}>;
|
|
1157
1194
|
}>>;
|
|
1158
1195
|
readonly zIndex: SchemaElementPropertyDefinition<PropertyStringDescriptor<{
|
|
1159
1196
|
readonly required: true;
|
|
@@ -1162,6 +1199,9 @@ declare const BaseBoardPlugin: BasePlugin<Readonly<{
|
|
|
1162
1199
|
}>, Readonly<{
|
|
1163
1200
|
kind: 'types';
|
|
1164
1201
|
types: readonly string[];
|
|
1202
|
+
}>, Readonly<{
|
|
1203
|
+
key: string;
|
|
1204
|
+
map: (value: string, renamed: (name: string) => string | undefined) => string;
|
|
1165
1205
|
}>>;
|
|
1166
1206
|
readonly framePlace?: Readonly<{
|
|
1167
1207
|
copy: SchemaPropertyCopyPolicy;
|
|
@@ -1941,6 +1981,11 @@ declare const BaseBoardPlugin: BasePlugin<Readonly<{
|
|
|
1941
1981
|
readonly slice: (ids: readonly string[]) => ContentSlice | null;
|
|
1942
1982
|
/** The members of the board block `board`, in stored order. */
|
|
1943
1983
|
readonly shapes: (board: NodeKey) => BoardMemberEntry[];
|
|
1984
|
+
/**
|
|
1985
|
+
* Where the pen line `id` draws its outline within its box, the
|
|
1986
|
+
* path the live board draws, or null when `id` names no pen line.
|
|
1987
|
+
*/
|
|
1988
|
+
readonly strokePath: (id: string) => BoardStrokePath | null;
|
|
1944
1989
|
};
|
|
1945
1990
|
readonly readMiddleware: true;
|
|
1946
1991
|
readonly update: {
|
|
@@ -2104,4 +2149,4 @@ declare const BaseBoardStrokePlugin: BasePlugin<Readonly<{}> & Readonly<{
|
|
|
2104
2149
|
};
|
|
2105
2150
|
}>>;
|
|
2106
2151
|
type BoardStrokeElement = ElementOf<typeof BaseBoardStrokePlugin>;
|
|
2107
|
-
export {
|
|
2152
|
+
export { BoardShapeEntry as A, isBoardSize as B, BoardArrowEnd as C, BoardArrowEntry as D, isBoardArrowEnd as E, BoardPlace as F, BoardStyles as G, BOARD_ARROW_STYLES as H, BoardRestackDirection as I, BoardShapeInsertProps as L, BoardShapePlace as M, isBoardFramePlace as N, BoardFrameEntry as O, isBoardShapePlace as P, BoardSize as R, BoardArrowAnchor as S, BoardArrowSide as T, BOARD_STROKE_STYLES as U, isStackingKey as V, BoardStyleProperties as W, BaseBoardFramePlugin as _, BoardElement as a, BoardArrowElement as b, BoardStrokePoints as c, BoardNoteElement as d, BaseBoardImagePlugin as f, BoardGeoElement as g, BoardGeo as h, BoardDefinition as i, BoardFramePlace as j, BoardMemberEntry as k, isBoardStrokePoints as l, BaseBoardGeoPlugin as m, BoardStrokeElement as n, BoardInkPoint as o, BoardImageElement as p, BaseBoardPlugin as r, BoardStrokePath as s, BaseBoardStrokePlugin as t, BaseBoardNotePlugin as u, BoardFrameElement as v, BoardArrowEnds as w, BoardArrowEndInput as x, BaseBoardArrowPlugin as y, defineBoardShape as z };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import { Pa as NodeSelection, Ps as SchemaContentRule, Qo as PropertyJsonDescriptor, Ra as NodeTarget, Vt as EditorJsonValue, Yo as PropertyBooleanDescriptor, es as PropertyNumberDescriptor, eu as TxDeclaredMethod, is as PropertyStringDescriptor, ki as ElementOf, ls as PropertyValueOptions, na as NamedRootKey, wi as ElementEntry, ws as SchemaContentDefault, xa as NodeKey } from "./index-DpltOCot-A2b3p3Eb.js";
|
|
2
|
+
import "./htmlTypes-cg_cWsaN.js";
|
|
3
|
+
import { Ga as DefinitionOf, _ as BasePlugin, ct as BlockInsertOptions, lt as BlockUpsertOptions, xo as PluginReference, yo as PluginDependency } from "./core-ClHasORr.js";
|
|
3
4
|
type TableCellBorder = Readonly<{
|
|
4
5
|
color?: string;
|
|
5
6
|
style?: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as TransferVeto, $a as TransactionSpec, $c as EditorSchemaOverride, $i as NodeKey, $l as SchemaElementTarget, $n as EditorLevelsOptions, $o as TxMethodDeclarations, $r as EditorTargetRuntime, $s as NodeNodesOptions, $t as AnchorDeletionPolicy, $u as EditorJsonValue, Ac as ElementInterface, Ai as EditorUpdate, Al as SchemaContentRoot, An as EditorCommitRuntimeChangeKind, Ao as NodeInsertSplitOptions, Ar as EditorSchemaPropertyReadOptions, As as DescendantEntryIn, Au as SchemaValue, B as TransferIntent, Ba as RootKey, Bc as EditorSchemaContent, Bl as SchemaElementFor, Bn as EditorEffectCollabEncodeContext, Bo as NodeUnwrapNodesOptions, Br as EditorStateNodesApi, Bs as NodeDescendantsOptions, Bt as EditorSchemaContract, Bu as RangeApi, C as NodeWriteVeto, Ca as PluginPoint, Cc as TextInterface, Ci as EditorTransactionSliceApi, Cl as PropertyValueOptions, Cn as EditorCommandResult, Co as SelectionCollapseOptions, Cr as EditorReadRegistration, Cs as AncestorEntryOf, Ct as definePluginPoint, Cu as SchemaTextBlockOptions, D as AuthoredVeto, Da as PluginReadFactoryContext, Dc as ElementApi, Di as EditorTransactionTopLevelRange, Dl as SchemaContentInput, Dn as EditorCommitContext, Do as BlockDuplicateOptions, Dr as EditorRootEntry, Ds as ChildOf, Dt as target, Du as SchemaTextPropertyKeys, E as AuthoredTouch, Ea as PluginReadFactory, Ec as Element, Ei as EditorTransactionTextApi, El as SchemaContentDefault, En as EditorCommitChanged, Eo as SelectionSetPointOptions, Er as EditorReplaceNodeOptions, Es as BaseNode, Et as schema, Eu as SchemaTextPropertyDefinition, F as TransferAdoptInput, Fa as PluginUpdateFactory, Fi as EditorUpdatePolicyFor, Fl as SchemaContentRootStructure, Fo as NodeRemoveNodesOptions, Fr as EditorSliceReadOptions, Fs as Node, Fu as Span, G as TransferPatchProperties, Ga as SnapshotInput, Gc as EditorSchemaDelta, Gi as EditorView, Gl as SchemaElementProperty, Gn as EditorElementBehavior, Go as RangeDirection, Gr as EditorStateSelectionApi, Gs as NodeFindTextRangesOptions, Gt as EditorSchemaContractDiff, Gu as PointApi, H as TransferLandingTarget, Ha as SerializedEditorSelection, Hc as EditorSchemaContribution, Hi as EditorValueFromPlugins, Hl as SchemaElementInput, Hn as EditorEffectCollabTransport, Ho as LeafEdge, Hr as EditorStateRangesApi, Hs as NodeEntry, Ht as EditorSchemaContractChangeKind, Hu as RangeInterface, I as TransferCheck, Ia as PluginUpdateFactoryContext, Ic as EditorSchemaSource, Ii as EditorUpdateTag, Il as SchemaContentRule, In as EditorDocumentRecords, Io as NodeReplaceChildrenOptions, Ir as EditorSnapshot, Is as NodeAncestorsOptions, Iu as SpanApi, J as TransferRelation, Ja as StateFieldHistoryPolicy, Jc as EditorSchemaElementOverride, Ji as HistoryOutcome, Jl as SchemaElementPropertyOptions, Jo as SelectionMode, Jr as EditorStateUniqueApi, Js as NodeInterface, Jt as diffEditorSchemaContracts, Ju as Path, K as TransferPayload, Ka as StateFieldCollabPolicy, Kc as EditorSchemaDerivedDefinition, Ki as EditorViewOptions, Kl as SchemaElementPropertyDefinition, Kn as EditorFragmentDeletionOptions, Ko as RangeMode, Kr as EditorStateSliceApi, Ks as NodeHasPropsOptions, Kt as EditorSchemaContractElement, Ku as PointEntry, L as TransferDiagnostic, Li as EditorUpdateTagInput, Ll as SchemaDescendant, Ln as EditorDocumentValue, Lo as NodeSetNodesOptions, Lr as EditorStateField, Ls as NodeApi, Lt as SliceLanding, Lu as SpanInterface, M as transfer, Ma as PluginTypeProvider, Mc as ElementOf, Mi as EditorUpdateContext, Ml as SchemaContentRootInput, Mn as EditorCoreUpdateMethods, Mo as NodeMergeNodesOptions, Mr as EditorSchemaVocabulary, Ms as DescendantIn, Mt as setEditorViewing, Mu as Location, N as transferVeto, Nc as ElementOrTextIn, Ni as EditorUpdateMethods, Nl as SchemaContentRootOwnership, Nn as EditorCoreUpdateTransaction, No as NodeMoveNodesOptions, Nr as EditorSelectionBlockOptions, Ns as DescendantOf, Nu as LocationApi, O as authoredVeto, Oa as PluginReadMiddlewareFactory, Oc as ElementEntry, Oi as EditorTransactionValueApi, Ol as SchemaContentOptions, On as EditorCommitHandler, Oo as NodeDuplicateOptions, Or as EditorRootOwner, Os as Descendant, Ot as documentReplacement, Ou as SchemaTextPropertyOptions, P as editorReads, Pa as PluginTypes, Pc as ElementOrTextOf, Pi as EditorUpdatePolicy, Pl as SchemaContentRootSlotsFor, Pn as EditorDirectCommandDispatch, Po as NodeMutationMethods, Pr as EditorSelectionTargetOptions, Ps as ElementEntryOf, Pt as getEditorRuntimeOwner, Pu as LocationInterface, Q as TransferTarget, Qa as TopLevelRuntimeRange, Qc as EditorSchemaNamedDefinition, Qi as NamedRootKey, Ql as SchemaElementStructure, Qn as EditorIsEditorOptions, Qo as TxDeclaredMethod, Qs as NodeMatchPredicate, Qt as AnchorAssociation, Qu as PathLevelsOptions, R as TransferEdge, Ra as PluginsOf, Ri as EditorUpdateTransaction, Rl as SchemaElement, Rn as EditorEffect, Ro as NodeSplitNodesOptions, Rr as EditorStateFragmentApi, Rs as NodeChildEntry, Rt as SliceLandingInput, Ru as BaseRange, Sa as PluginMigrationContext, Sc as TextIn, Si as EditorTransactionSelectionApi, Sl as PropertyValueOf, Sn as EditorCommandPlace, So as TextRemoveTextOptions, Sr as EditorReadMethods, Ss as AncestorEntry, St as defineEditorSchema, Su as SchemaText, T as nodeWriteVeto, Ta as PluginReadContext, Tc as BaseElement, Ti as EditorTransactionTagsApi, Tl as SchemaContent, Tn as EditorCommitChangeKind, To as SelectionMutationMethods, Tr as EditorReplaceChildrenOptions, Ts as AncestorOf, Tt as property, Tu as SchemaTextProperty, U as TransferOutcome, Ua as SerializedEditorValue, Uc as EditorSchemaDeclaration, Ui as EditorValuePersistence, Ul as SchemaElementProperties, Un as EditorEffectHistoryReplayResult, Uo as MaximizeMode, Ur as EditorStateRuntimeApi, Us as NodeEntryIn, Ut as EditorSchemaContractContentProgram, Uu as BasePoint, V as TransferLandingInput, Va as SerializedEditorEffect, Vc as EditorSchemaContentRoot, Vi as EditorUpdateValueFromPlugin, Vl as SchemaElementHandle, Vn as EditorEffectCollabReplay, Vo as NodeWrapNodesOptions, Vr as EditorStatePointsApi, Vs as NodeElementsOptions, Vt as EditorSchemaContractChange, Vu as RangeEdgesOptions, W as TransferPatch, Wa as SnapshotIndex, Wc as EditorSchemaDefinition, Wl as SchemaElementPropertiesFor, Wn as EditorEffectType, Wo as MoveUnit, Wr as EditorStateSchemaApi, Ws as NodeEntryOf, Wt as EditorSchemaContractContentRoot, Wu as Point, X as TransferSideInput, Xa as StateFieldValueInput, Xc as EditorSchemaElementStructure, Xi as HistorySettlement, Xl as SchemaElementShapeFor, Xn as EditorInstalledReadGroups, Xo as TextUnit, Xr as EditorStateView, Xs as NodeLevelsOptions, Xt as restoreEditorSchemaContract, Xu as PathApi, Y as TransferSide, Ya as StateFieldInitial, Yc as EditorSchemaElementOverrideInput, Yi as HistoryResult, Yl as SchemaElementPropertyValue, Yn as EditorInstalledApiGroups, Yo as TextDirection, Yr as EditorStateValueApi, Ys as NodeIsNodeOptions, Yt as readEditorSchemaContract, Yu as PathAncestorsOptions, Z as TransferSourceInput, Za as TargetFreshnessRequest, Zc as EditorSchemaIdentity, Zi as InitialValue, Zl as SchemaElementSlicePolicy, Zn as EditorInstalledUpdateGroups, Zo as TextUnitAdjustment, Zr as EditorStateViewApi, Zs as NodeMatch, Zt as Anchor, Zu as PathInterface, _ as PluginSlotValue, _c as MarksIn, _i as EditorTransactionNodesApi, _l as PropertySetOptions, _n as EditorCommandContinuation, _r as EditorReadContext, _s as SelectionApi, _t as SetSelectionCommand, _u as SchemaPropertySplitPolicy, aa as PluginApiFactoryContext, ac as NodeTextRangeRoot, ai as EditorTransactionAnchorApi, al as EditorSchemaPropertyQuery, ar as EditorNodeChangeContext, as as defineCommand, at as DeleteFragmentCommand, au as SchemaPluginsOf, b as AuthoredDocumentProjection, ba as PluginInput, bc as TextApi, bi as EditorTransactionRemoved, bl as PropertyValueDescriptor, bn as EditorCommandHandler, bo as TextInsertTextOptions, br as EditorReadMethodRecord, bs as TextSelection, bt as editorCommands, bu as SchemaRootNames, c as defineUpdateAnnotation, ca as PluginCapabilities, cc as NodeTypeSelector, ci as EditorTransactionBreakApi, cl as EditorSchemaUnknownPolicy, cr as EditorNodeGetOptions, cs as JsonNode, ct as InsertNodesCommand, cu as SchemaPropertyDefinition, d as decodeEditorEffect, da as PluginContributionInput, dc as TextEntryOf, di as EditorTransactionChanged, dl as PropertyEnumDescriptor, dn as EditorBlockOptions, dr as EditorNodesOptions, ds as DecorationRefresh, dt as MoveSelectionCommand, du as SchemaPropertyHandleValue, ea as NodeTarget, ec as NodeOf, ei as EditorTextChangeContext, el as EditorSchemaOverrideInput, en as AnchorOptions, eo as Value, er as EditorLifecycleError, es as TxOnlyMethod, et as TransferVetoInput, eu as SchemaElementTypes, f as encodeEditorEffect, fa as PluginDefinition, fc as BaseText, fi as EditorTransactionChangesApi, fl as PropertyJsonDescriptor, fn as EditorBlockToggleOptions, fo as isEditor, fr as EditorNodesReadOptions, fs as DecorationSource, ft as RemoveMarkCommand, fu as SchemaPropertyIds, g as PluginSlot, gc as MarkKeysOf, gi as EditorTransactionMarksApi, gl as PropertySetDescriptor, gn as EditorCommandAroundHandler, gr as EditorReadAroundHandler, gs as Selection, gt as SetNodesCommand, gu as SchemaPropertyRole, h as defineStateField, ha as PluginDependencyReference, hc as LeafPosition, hi as EditorTransactionFragmentApi, hl as PropertyOptionsOf, hn as EditorCommand, hr as EditorRead, hs as NodeSelectionMode, ht as SelectCommand, hu as SchemaPropertyReferences, ia as PluginApiFactory, ic as NodeTextRangeQuery, ii as EditorTransactionAnchor, il as EditorSchemaPropertyOverrideInput, ir as EditorNextOptions, is as txSelection, it as DeleteCommand, iu as SchemaKeyPrefix, j as TransferRead, ja as PluginSlotLike, jc as ElementIsElementOptions, ji as EditorUpdateAnnotation, jl as SchemaContentRootContribution, jn as EditorCoreStateView, jo as NodeLiftNodesOptions, jr as EditorSchemaReadProperty, js as DescendantEntryOf, jt as setEditorReadOnly, ju as SchemaValueFromPlugins, k as TransferApi, ka as PluginReconfigureOptions, kc as ElementIn, ki as EditorUniqueHolder, kl as SchemaContentPrefixSlot, kn as EditorCommitListener, ko as NodeInsertNodesOptions, kr as EditorSchemaGetProperty, ks as DescendantEntry, ku as SchemaTypesTarget, l as invertEffect, la as PluginCleanupContext, lc as TextEntry, li as EditorTransactionChangeContext, ll as NamedEditorSchemaIdentity, ls as Decoration, lt as InsertSoftBreakCommand, lu as SchemaPropertyExclusiveGroup, m as screenReaderAnnouncementEffect, mc as BooleanMarksOf, mi as EditorTransactionEffectsApi, ml as PropertyNumberDescriptor, mn as EditorCanonicalUpdateTag, mr as EditorPreviousOptions, ms as NodeSelection, mt as ReplaceSliceCommand, mu as SchemaPropertyLandingPolicy, n as PluginsFromOptions, nc as NodeTextRangeEntry, ni as EditorToggleBlockOptions, nl as EditorSchemaProperty, nn as EditorDocumentRange, nr as EditorMarks, ns as txLocate, nt as AddMarkCommand, nu as SchemaGroupNames, o as createEditorView, oa as PluginCandidateContext, oc as NodeTextRangeView, oi as EditorTransactionAnnotationsApi, ol as EditorSchemaRepairCode, on as CompatibleEditorCommand, or as EditorNodeChangeHandler, os as DocumentChange, ot as EditorCommands, ou as SchemaProperty, p as valueCodecs, pc as BooleanMarkKeysOf, pi as EditorTransactionDocumentChangeKind, pl as PropertyJsonOptions, pn as EditorBreakExitOptions, pr as EditorParentOptions, ps as EditorSelection, pt as RemoveNodesCommand, pu as SchemaPropertyKey, q as TransferRefusalReason, qa as StateFieldDescriptor, qc as EditorSchemaElement, qi as HistoryApi, ql as SchemaElementPropertyKeys, qn as EditorFragmentReadOptions, qo as SelectionEdge, qr as EditorStateTextApi, qs as NodeIn, qt as EditorSchemaContractRoot, qu as PointInterface, r as compileEditorSchemaContract, ra as PluginActivationContext, rc as NodeTextRangeMatch, ri as EditorToggleMarkOptions, rl as EditorSchemaPropertyOverride, rn as RangeAnchorAssociation, rr as EditorMarksOf, rs as txOnly, rt as CollapseSelectionCommand, ru as SchemaGroupOptions, s as defineEffect, sa as PluginCandidateEditor, sc as NodeTextsOptions, si as EditorTransactionBlocksApi, sl as EditorSchemaStructureProperty, so as getSelection, sr as EditorNodeChangeKind, ss as JsonEditorValue, st as InsertBreakCommand, su as SchemaPropertyCopyPolicy, t as EditorValueFromOptions, ta as PersistedDocumentInput, tc as NodeProps, ti as EditorTextChangeHandler, tl as EditorSchemaPlugin, tn as AnchorValue, to as ValueOf, tr as EditorLifecycleErrorSink, ts as locateAt, tt as TransferWrap, tu as SchemaGroup, u as mapEffect, ua as PluginContribution, uc as TextEntryIn, ui as EditorTransactionChangeHandler, ul as PropertyBooleanDescriptor, un as EditorAboveOptions, ur as EditorNodeUnsetOptions, us as DecorationAttributes, ut as InsertTextCommand, uu as SchemaPropertyHandle, v as definePluginSlot, vc as MarksOf, vi as EditorTransactionPluginsApi, vl as PropertyStringDescriptor, vn as EditorCommandDescriptor, vo as TextDeleteOptions, vr as EditorReadDescriptor, vs as SelectionAssociation, vt as ToggleBlockCommand, vu as SchemaPropertyTypeChangePolicy, w as NodeWriteVetoInput, wc as TextOf, wi as EditorTransactionSpecBuilder, wl as SchemaBuiltInGroupName, wn as EditorCommit, wo as SelectionMoveOptions, wr as EditorReadResult, ws as AncestorIn, wt as PropertyBuilderApi, wu as SchemaTextProperties, x as AuthoredProjectionDiagnostic, xc as TextEqualsOptions, xi as EditorTransactionRootsApi, xl as PropertyValueKind, xn as EditorCommandInput, xo as TextMutationMethods, xr as EditorReadMethodTree, xs as Ancestor, xt as PluginPublicationError, xu as SchemaTarget, y as ContentSlice, yc as Text, yi as EditorTransactionRecordsApi, yl as PropertyValidation, yn as EditorCommandDispatch, yo as TextInsertFragmentOptions, yr as EditorReadInput, ys as SelectionValue, yt as ToggleMarkCommand, yu as SchemaRecordSet, z as TransferInput, za as ProjectedRangeSegment, zc as DerivedEditorSchemaIdentity, zl as SchemaElementConstructionPropertiesFor, zn as EditorEffectCollabDecodeContext, zo as NodeUnsetNodesOptions, zr as EditorStateMarksApi, zs as NodeChildrenOptions, zt as SliceLandingTarget, zu as Range } from "./index-BU6k1Aev.js";
|
|
2
|
-
import {
|
|
3
|
-
import { $a as
|
|
4
|
-
export { type AddMarkCommand, AffinityDefinition, AffinityEdgeNodes, AffinityPlugin, AffinityPluginUpdate, Alignment, Ancestor, AncestorEntry, AncestorEntryOf, AncestorIn, AncestorOf, type Anchor, type AnchorAssociation, type AnchorDeletionPolicy, type AnchorOptions, type AnchorValue, type AnyObject, ApplyDeepToNodesOptions, type AuthoredDocumentProjection, type AuthoredProjectionDiagnostic, type AuthoredTouch, type AuthoredVeto, type AutoScrollApi, type AutoScrollChangeKind, type AutoScrollChangesMap, type AutoScrollOptions, type AutoScrollUpdate, BULLETED_LIST_STYLES, BaseBlockquotePlugin, BaseBoldPlugin, BaseCodeBlockPlugin, BaseCodeHighlightPlugin, BaseCodePlugin, BaseElement, BaseFontBackgroundColorPlugin, BaseFontColorPlugin, BaseFontFamilyPlugin, BaseFontSizePlugin, BaseFormattingPlugin, BaseHeadingPlugin, BaseHighlightPlugin, BaseHorizontalRulePlugin, BaseIndentPlugin, type BaseInjectProps, BaseInputRule, BaseItalicPlugin, BaseKbdPlugin, BaseLineHeightPlugin, BaseLinkDefinition, BaseLinkPlugin, BaseLinkPluginState, BaseListDefinition, BaseListPlugin, BaseNode, BaseParagraphDefinition, BaseParagraphPlugin, type BasePlugin, type BasePlugin as Plugin, type BasePluginConfiguration, type BasePluginContext, type BasePluginDefinition, type BasePluginDefinitionInput, type BasePluginDefinitionInput as PluginDefinitionInput, type BasePluginExtendInput, type BasePluginImplementationContext, type BasePluginInput, type BasePluginOn, type BasePluginOverride, type BasePluginPortal, type BasePluginPortal as PluginPortal, BasePoint, BaseRange, BaseScriptPlugin, BaseStrikethroughPlugin, BaseText, BaseTextAlignPlugin, BaseTextIndentPlugin, BaseUnderlinePlugin, type BlockDuplicateOptions, BlockFenceInputRuleConfig, BlockFenceInputRuleMatch, type BlockInsertOptions, BlockStartInputRuleConfig, BlockStartInputRuleMatch, type BlockUpsertOptions, BlockquoteRules, BoldRules, BooleanMarkKeysOf, BooleanMarksOf, type BreakRules, BulletedListRules, CapturedFormat, ChildOf, CodeBlockDefinition, CodeBlockElement, CodeBlockRules, CodeHighlightDefinition, CodeHighlightLowlight, CodeHighlightPluginState, CodeRules, type CollapseSelectionCommand, type CompatibleEditorCommand, type ConfiguredBasePlugin, ContentSlice, type CreateEditorOptions, CreateLinkNodeOptions, DebugApi, DebugDefinition, DebugErrorType, DebugPlugin, DebugPluginState, type DebugValueScrubber, type DeclaredPluginShortcutInput, type Decorate, type Decoration, type DecorationAttributes, type DecorationRefresh, type DecorationSource, type DefinitionOf, type DeleteCommand, type DeleteFragmentCommand, type DeleteRules, DelimitedInlineInputRuleMatch, type DerivedEditorSchemaIdentity, Descendant, DescendantEntry, DescendantEntryIn, DescendantEntryOf, DescendantIn, DescendantOf, DocumentChange, type DomApi, type DomPluginState, type DomPluginUpdate, type EditOnlyConfig, type EditableProps, type Editor, type EditorAboveOptions, type EditorApplicationSchema, type EditorBlockOptions, type EditorBlockToggleOptions, type EditorBreakExitOptions, type EditorCanonicalUpdateTag, type EditorCommand, type EditorCommandAroundHandler, type EditorCommandContinuation, type EditorCommandDescriptor, type EditorCommandDispatch, type EditorCommandHandler, type EditorCommandInput, type EditorCommandPlace, type EditorCommandResult, type EditorCommands, type EditorCommit, type EditorCommitChangeKind, type EditorCommitChanged, type EditorCommitContext, type EditorCommitHandler, type EditorCommitListener, type EditorCommitRuntimeChangeKind, type EditorCoreStateView, type EditorCoreUpdateMethods, type EditorCoreUpdateTransaction, type EditorDirectCommandDispatch, type EditorDocumentRange, type EditorDocumentRecords, type EditorDocumentValue, type EditorEffect, type EditorEffectCollabDecodeContext, type EditorEffectCollabEncodeContext, type EditorEffectCollabReplay, type EditorEffectCollabTransport, type EditorEffectHistoryReplayResult, type EditorEffectType, type EditorElementBehavior, EditorError, type EditorFragmentDeletionOptions, type EditorFragmentReadOptions, type EditorInstalledApiGroups, type EditorInstalledReadGroups, type EditorInstalledUpdateGroups, type EditorIsEditorOptions, type EditorJsonValue, type EditorLevelsOptions, type EditorLifecycleError, type EditorLifecycleErrorSink, type EditorMarks, type EditorMarksOf, type EditorNextOptions, type EditorNodeChangeContext, type EditorNodeChangeHandler, type EditorNodeChangeKind, type EditorNodeGetOptions, type EditorNodeUnsetOptions, type EditorNodesOptions, type EditorNodesReadOptions, type EditorParentOptions, type EditorPreviousOptions, type EditorRead, type EditorReadAroundHandler, type EditorReadContext, type EditorReadDescriptor, type EditorReadInput, type EditorReadMethodRecord, type EditorReadMethodTree, type EditorReadMethods, type EditorReadRegistration, type EditorReadResult, type EditorReplaceChildrenOptions, type EditorReplaceNodeOptions, type EditorRootEntry, type EditorRootOwner, type EditorSchemaContent, type EditorSchemaContentRoot, type EditorSchemaContract, type EditorSchemaContractChange, type EditorSchemaContractChangeKind, type EditorSchemaContractContentProgram, type EditorSchemaContractContentRoot, type EditorSchemaContractDiff, type EditorSchemaContractElement, type EditorSchemaContractRoot, type EditorSchemaContribution, type EditorSchemaDeclaration, type EditorSchemaDefinition, type EditorSchemaDelta, type EditorSchemaDerivedDefinition, type EditorSchemaElement, type EditorSchemaElementOverride, type EditorSchemaElementOverrideInput, type EditorSchemaElementStructure, type EditorSchemaGetProperty, type EditorSchemaIdentity, type EditorSchemaNamedDefinition, type EditorSchemaOverride, type EditorSchemaOverrideInput, type EditorSchemaPlugin, type EditorSchemaProperty, type EditorSchemaPropertyOverride, type EditorSchemaPropertyOverrideInput, type EditorSchemaPropertyQuery, type EditorSchemaPropertyReadOptions, type EditorSchemaReadProperty, type EditorSchemaRepairCode, type EditorSchemaSource, type EditorSchemaStructureProperty, type EditorSchemaUnknownPolicy, type EditorSchemaValidationCode, type EditorSchemaValidationDiagnostic, EditorSchemaValidationError, type EditorSchemaValidationPropertyContext, type EditorSchemaVocabulary, EditorSelection, type EditorSelectionBlockOptions, type EditorSelectionTargetOptions, type EditorShortcut, type EditorSliceReadOptions, type EditorSnapshot, type EditorStateField, type EditorStateFragmentApi, type EditorStateMarksApi, type EditorStateNodesApi, type EditorStatePointsApi, type EditorStateRangesApi, type EditorStateRuntimeApi, type EditorStateSchemaApi, type EditorStateSelectionApi, type EditorStateSliceApi, type EditorStateTextApi, type EditorStateUniqueApi, type EditorStateValueApi, type EditorStateView, type EditorStateViewApi, type EditorTargetRuntime, type EditorTextChangeContext, type EditorTextChangeHandler, type EditorToggleBlockOptions, type EditorToggleMarkOptions, type EditorTransactionAnchor, type EditorTransactionAnchorApi, type EditorTransactionAnnotationsApi, type EditorTransactionBlocksApi, type EditorTransactionBreakApi, type EditorTransactionChangeContext, type EditorTransactionChangeHandler, type EditorTransactionChanged, type EditorTransactionChangesApi, type EditorTransactionDocumentChangeKind, type EditorTransactionEffectsApi, type EditorTransactionFragmentApi, type EditorTransactionMarksApi, type EditorTransactionNodesApi, type EditorTransactionPluginsApi, type EditorTransactionRecordsApi, type EditorTransactionRemoved, type EditorTransactionRootsApi, type EditorTransactionSelectionApi, type EditorTransactionSliceApi, type EditorTransactionSpecBuilder, type EditorTransactionTagsApi, type EditorTransactionTextApi, type EditorTransactionTopLevelRange, type EditorTransactionValueApi, type EditorUniqueHolder, type EditorUpdate, type EditorUpdateAnnotation, type EditorUpdateContext, type EditorUpdateMethods, type EditorUpdatePolicy, type EditorUpdatePolicyFor, type EditorUpdateTag, type EditorUpdateTagInput, type EditorUpdateTransaction, type EditorUpdateValueFromPlugin, type EditorValueFromOptions, type EditorValueFromPlugins, type EditorValueInput, type EditorValuePersistence, type EditorView, type EditorViewOptions, Element, ElementApi, type ElementContentRootSlot, ElementEntry, ElementEntryOf, ElementIdEntry, ElementIdPlugin, ElementIdPluginState, ElementIn, ElementInterface, ElementIsElementOptions, ElementOf, ElementOrTextIn, ElementOrTextOf, ElementStateApi, ElementStateDefinition, ElementStatePlugin, type ElementWith, ExitBreakPlugin, FormattingBlockEntry, FormattingContribution, FragmentPropMode, GetFragmentPropOptions, type GetInjectNodePropsOptions, type GetInjectNodePropsReturnType, type HandlerReturnType, HeadingLevel, HeadingRules, HighlightNode, HighlightResult, HighlightRules, type HistoryApi, HistoryDefinition, type HistoryOutcome, HistoryPlugin, HistoryPluginState, type HistoryResult, type HistorySettlement, HorizontalRuleRules, Hotkeys, type HtmlAttributes, type HtmlContentToken, type HtmlElementPatch, type HtmlMappingDiagnosticInput, type HtmlMatchValue, type HtmlMatcher, type HtmlNodeSpec, HtmlPlugin, type HtmlPrepareDiagnosticInput, type HtmlWrapperSpec, IS_APPLE, IndentChangeOptions, IndentDefinition, IndentPluginState, type InferApi, type InferConflicts, type InferDependencies, type InferEnabled, type InferName, type InferOwnApi, type InferOwnRead, type InferOwnUpdate, type InferPluginReadGroups, type InferPluginStoreState, type InferPluginUpdateGroups, type InferRead, type InferSelectors, type InferTargetPlugins, type InferUpdate, type InitialValue, type InjectNodeProps, InputRule, InputRuleEditor, InputRuleInsertTextOptions, InputRuleTarget, InputRulesConfig, InputRulesDefinition, type InsertBreakCommand, InsertBreakInputRule, InsertBreakInputRuleContext, InsertBreakInputRuleReadContext, InsertDataInputRule, InsertDataInputRuleContext, InsertDataInputRuleReadContext, type InsertNodesCommand, type InsertSoftBreakCommand, type InsertTextCommand, InsertTextInputRule, InsertTextInputRuleContext, InsertTextInputRuleReadContext, ItalicRules, type JsonEditorValue, type JsonNode, type LeafEdge, LeafPosition, type LeafStaticProps, LineHeightDefinition, LinkAttributes, LinkElement, LinkRules, ListElement, ListStyle, ListType, Location, LocationApi, LocationInterface, LogLevel, MarkComboRules, MarkInputRuleConfig, MarkInputRuleMatch, MarkKeysOf, type MarkdownDecodeContext, type MarkdownEncodeContext, type MarkdownMarkWrapContext, type MarkdownMarkWrapper, type MarkdownMarks, type MarkdownNodeKind, type MarkdownNodeKinds, type MarkdownNodeMapping, type MarkdownNodeMappingInput, type MarkdownPluginRegistry, type MarkdownRefusal, type MarkdownTagAttributeView, type MarkdownTagNode, MarksIn, MarksOf, MatchBlockFenceOptions, MatchBlockStartOptions, MatchDelimitedInlineOptions, type MaximizeMode, type MergeRules, type MoveSelectionCommand, type MoveUnit, type NamedEditorSchemaIdentity, type NamedRootKey, Node, NodeAncestorsOptions, NodeApi, NodeChildEntry, NodeChildrenOptions, type NodeComponent, NodeDescendantsOptions, type NodeDuplicateOptions, NodeElementsOptions, NodeEntry, NodeEntryIn, NodeEntryOf, NodeFindTextRangesOptions, NodeHasPropsOptions, NodeIn, type NodeInsertNodesOptions, type NodeInsertOptions, type NodeInsertSplitOptions, NodeInterface, NodeIsNodeOptions, type NodeKey, NodeLevelsOptions, type NodeLiftNodesOptions, NodeMatch, NodeMatchPredicate, type NodeMergeNodesOptions, type NodeMoveNodesOptions, type NodeMutationMethods, NodeNodesOptions, NodeOf, NodeProps, type NodeRemoveNodesOptions, type NodeReplaceChildrenOptions, NodeSelection, NodeSelectionMode, type NodeSetNodesOptions, type NodeSplitNodesOptions, type NodeStaticProps, type NodeTarget, NodeTextRangeEntry, NodeTextRangeMatch, NodeTextRangeQuery, NodeTextRangeRoot, NodeTextRangeView, NodeTextsOptions, NodeTypeSelector, type NodeUnsetNodesOptions, type NodeUnwrapNodesOptions, type NodeWrapNodesOptions, type NodeWriteVeto, type NodeWriteVetoInput, type NormalizeRules, type Nullable, OrderedListRules, OutdentListOptions, PLUGINS, type PartialBasePlugin, Path, PathAncestorsOptions, PathApi, PathInterface, PathLevelsOptions, type PersistedDocumentInput, PlainTextDiagnostic, PlainTextDocumentOptions, PlainTextEditorOptions, type PlainTextEncodeContext, type PlainTextNodeMapping, type PlainTextNodeMappingInput, PlainTextSerializeResult, type PluginActivationContext, type PluginApiFactory, type PluginApiFactoryContext, type PluginBaseContext, type PluginCandidateContext, type PluginCandidateEditor, type PluginCapabilities, type PluginCleanupContext, type PluginContribution, type PluginContributionInput, type PluginDefinition, type PluginDependency, type PluginDependencyReference, type PluginFormatContext, type PluginFormatModelView, type PluginFormatNode, type PluginFormatRegistry, type PluginFormatSchemaView, type PluginInput, type PluginMigrationContext, PluginName, type PluginOwnUpdate, type PluginPoint, PluginPublicationError, type PluginReadContext, type PluginReadFactory, type PluginReadFactoryContext, type PluginReadMiddlewareFactory, type PluginReadState, type PluginReconfigureOptions, type PluginReference, type PluginSchema, type PluginSchemaContext, type PluginSchemaDeclaration, type PluginSchemaElement, type PluginSchemaMark, type PluginSchemaReferences, type PluginSelector, type PluginSelectorArgs, type PluginSelectorMethods, type PluginSelectorReturn, type PluginSelectors, type PluginShortcutInput, type PluginSlot, type PluginSlotLike, type PluginSlotValue, type PluginState, type PluginStore, type PluginTransaction, type PluginTypeProvider, type PluginTypes, type PluginUpdate, type PluginUpdateFactory, type PluginUpdateFactoryContext, type PluginsFromOptions, type PluginsOf, Point, PointApi, PointEntry, PointInterface, type ProjectedRangeSegment, type PropertyBooleanDescriptor, type PropertyBuilderApi, type PropertyEnumDescriptor, type PropertyJsonDescriptor, type PropertyJsonOptions, type PropertyNumberDescriptor, type PropertyOptionsOf, type PropertySetDescriptor, type PropertySetOptions, type PropertyStringDescriptor, type PropertyValidation, type PropertyValueDescriptor, type PropertyValueKind, type PropertyValueOf, type PropertyValueOptions, Range, type RangeAnchorAssociation, RangeApi, type RangeDirection, RangeEdgesOptions, RangeInterface, type RangeMode, type RemoveMarkCommand, type RemoveNodesCommand, type RenderElementFn, type RenderElementProps, type RenderElementSlots, type RenderLeafFn, type RenderLeafProps, type RenderStaticNodeWrapper, type RenderStaticNodeWrapperFunction, type RenderStaticNodeWrapperProps, type RenderTextFn, type RenderTextHostProps, type RenderTextPieceProps, type RenderTextProps, type ReplaceSliceCommand, ResolvedInputRule, ResolvedInputRulesMeta, type RootKey, type RuleDecision, type SchemaBuiltInGroupName, type SchemaContent, type SchemaContentDefault, type SchemaContentInput, type SchemaContentOptions, type SchemaContentPrefixSlot, type SchemaContentRoot, type SchemaContentRootContribution, type SchemaContentRootInput, type SchemaContentRootOwnership, type SchemaContentRootSlotsFor, type SchemaContentRootStructure, type SchemaContentRule, type SchemaDescendant, type SchemaElement, type SchemaElementConstructionPropertiesFor, type SchemaElementFor, type SchemaElementHandle, type SchemaElementInput, type SchemaElementProperties, type SchemaElementPropertiesFor, type SchemaElementProperty, type SchemaElementPropertyDefinition, type SchemaElementPropertyKeys, type SchemaElementPropertyOptions, type SchemaElementPropertyValue, type SchemaElementShapeFor, type SchemaElementSlicePolicy, type SchemaElementStructure, type SchemaElementTarget, type SchemaElementTypes, type SchemaGroup, type SchemaGroupNames, type SchemaGroupOptions, type SchemaKeyPrefix, type SchemaPluginsOf, type SchemaProperty, type SchemaPropertyCopyPolicy, type SchemaPropertyDefinition, type SchemaPropertyExclusiveGroup, type SchemaPropertyHandle, type SchemaPropertyHandleValue, type SchemaPropertyIds, type SchemaPropertyKey, type SchemaPropertyLandingPolicy, type SchemaPropertyReferences, type SchemaPropertyRole, type SchemaPropertySplitPolicy, type SchemaPropertyTypeChangePolicy, type SchemaRecordSet, type SchemaRootNames, type SchemaTarget, type SchemaText, type SchemaTextBlockOptions, type SchemaTextProperties, type SchemaTextProperty, type SchemaTextPropertyDefinition, type SchemaTextPropertyKeys, type SchemaTextPropertyOptions, type SchemaTypesTarget, type SchemaValue, type SchemaValueFromPlugins, ScriptRules, ScriptValue, type ScrollIntoViewTarget, type ScrollMode, type SelectCommand, Selection, SelectionApi, SelectionAssociation, type SelectionCollapseOptions, type SelectionEdge, SelectionInputRuleContext, type SelectionMode, type SelectionMoveOptions, type SelectionMutationMethods, type SelectionRules, type SelectionSetPointOptions, SelectionValue, type SerializedEditorEffect, type SerializedEditorSelection, type SerializedEditorValue, type SetNodesCommand, type SetSelectionCommand, SingleBlockPlugin, SingleLinePlugin, type SliceLanding, type SliceLandingInput, type SliceLandingTarget, type SnapshotIndex, type SnapshotInput, Span, SpanApi, SpanInterface, type StateFieldCollabPolicy, type StateFieldDescriptor, type StateFieldHistoryPolicy, type StateFieldInitial, type StateFieldValueInput, type StaticRenderLeafProps, StrikethroughRules, type StructuralRuleContext, type StructuralRuleEditor, type TargetFreshnessRequest, TaskListRules, Text, TextAlignDefinition, TextApi, type TextDeleteOptions, type TextDirection, TextEntry, TextEntryIn, TextEntryOf, TextEqualsOptions, TextIn, TextIndentDefinition, TextIndentPluginState, type TextInsertFragmentOptions, type TextInsertTextOptions, TextInterface, type TextMutationMethods, TextOf, type TextRemoveTextOptions, TextSelection, type TextStaticProps, TextSubstitutionInputRuleConfig, TextSubstitutionMatch, TextSubstitutionPattern, type TextUnit, type TextUnitAdjustment, type TextWith, type ToggleBlockCommand, ToggleHeadingOptions, ToggleListOptions, type ToggleMarkCommand, type TopLevelRuntimeRange, TrailingBlockDefinition, TrailingBlockPlugin, TrailingBlockPluginState, type TransactionSpec, type TransferAdoptInput, type TransferApi, type TransferCheck, type TransferDefinition, type TransferDiagnostic, type TransferEdge, type TransferInput, type TransferIntent, type TransferLandingInput, type TransferLandingTarget, type TransferOutcome, type TransferPatch, type TransferPatchProperties, type TransferPayload, TransferPlugin, type TransferRead, type TransferRefusalReason, type TransferRelation, type TransferSide, type TransferSideInput, type TransferSourceInput, type TransferTarget, type TransferVeto, type TransferVetoInput, type TransferWrap, TransformInputRuleContext, type TransformOptions, type TxDeclaredMethod, type TxMethodDeclarations, type TxOnlyMethod, UnderlineRules, type UnknownObject, UnwrapLinkOptions, UpsertLinkOptions, type Value, type ValueOf, type WithAnyName, type WithRequiredName, WrapLinkOptions, applyDeepToNodes, authoredVeto, compileEditorSchemaContract, createBlockFenceInputRule, createBlockStartInputRule, createEditor, createEditorView, createHotkey, createMarkInputRule, createTextSubstitutionInputRule, decodeEditorEffect, defaultsDeepToNodes, defineCommand, defineEditorSchema, defineEffect, defineInputRule, definePlugin, definePluginPoint, definePluginSlot, defineStateField, defineUpdateAnnotation, diffEditorSchemaContracts, documentReplacement, editorCommands, editorReads, encodeEditorEffect, formatting, getEditorRuntimeOwner, getFragmentProp, getInjectMatch, getLinkHref, getPluginNodeClass, inputRuleVeto, invertEffect, isDefined, isEditor, isHotkey, isNominalPluginDescriptor, isOrderedList, isPluginElementClass, isPluginNodeClass, isUrl, locateAt, mapEffect, matchBlockStart, matchDelimitedInline, mergeDeepToNodes, nanoid, nodeWriteVeto, property, readEditorSchemaContract, getSelection as readEditorSelection, restoreEditorSchemaContract, schema, screenReaderAnnouncementEffect, serializePlainText, setDebugValueScrubber, setEditorReadOnly, setEditorViewing, target, transfer, transferVeto, txLocate, txOnly, txSelection, valueCodecs };
|
|
1
|
+
import { $ as EditorBreakExitOptions, $a as PathApi, $c as SpanApi, $i as MoveSelectionCommand, $l as TransferWrap, $n as EditorSchemaStructureProperty, $o as PropertyJsonOptions, $r as EditorTransactionTagsApi, $s as SchemaGroup, $t as EditorNodeUnsetOptions, $u as transfer, A as CompatibleEditorCommand, Aa as NodeOf, Ac as SchemaValueFromPlugins, Ai as ElementOrTextIn, Al as TransferAdoptInput, An as EditorSchemaDefinition, Ao as PluginReadMiddlewareFactory, Ar as EditorToggleBlockOptions, As as SchemaContentRootInput, At as EditorEffectCollabTransport, B as DeleteFragmentCommand, Ba as NodeTextRangeMatch, Bc as SelectionSetPointOptions, Bi as InsertTextCommand, Bl as TransferPatch, Bn as EditorSchemaOverride, Bo as PluginUpdateFactoryContext, Br as EditorTransactionChangesApi, Bs as SchemaElementInput, Bt as EditorIsEditorOptions, C as BlockDuplicateOptions, Ca as NodeLiftNodesOptions, Cc as SchemaTextProperties, Ci as ElementApi, Cl as TextSelection, Cn as EditorSchemaContractContentProgram, Co as PluginMigrationContext, Cr as EditorStateValueApi, Cs as SchemaContent, Ct as EditorDocumentRange, Cu as editorReads, Da as NodeMoveNodesOptions, Dc as SchemaTextPropertyOptions, Di as ElementInterface, Dl as ToggleMarkCommand, Dn as EditorSchemaContractRoot, Do as PluginReadContext, Dr as EditorTargetRuntime, Ds as SchemaContentPrefixSlot, Dt as EditorEffectCollabDecodeContext, Du as getEditorRuntimeOwner, E as BooleanMarksOf, Ea as NodeMergeNodesOptions, Ec as SchemaTextPropertyKeys, Ei as ElementIn, El as ToggleBlockCommand, En as EditorSchemaContractElement, Eo as PluginPublicationError, Es as SchemaContentOptions, Et as EditorEffect, F as DecorationAttributes, Fa as NodeSelectionMode, Fc as SelectionCollapseOptions, Fi as HistorySettlement, Fl as TransferInput, Fn as EditorSchemaElementOverrideInput, Fo as PluginSlotValue, Fr as EditorTransactionBlocksApi, Fs as SchemaDescendant, Ft as EditorFragmentReadOptions, Fu as isEditor, G as DescendantEntryOf, Ga as NodeTypeSelector, Gc as SetNodesCommand, Gi as LeafPosition, Gl as TransferRefusalReason, Gn as EditorSchemaPropertyOverride, Go as PointApi, Gr as EditorTransactionNodesApi, Gs as SchemaElementPropertyKeys, Gt as EditorMarks, Gu as schema$1, H as Descendant, Ha as NodeTextRangeRoot, Hc as SerializedEditorEffect, Hi as JsonEditorValue, Hl as TransferPayload, Hn as EditorSchemaPlugin, Ho as PluginsFromOptions, Hr as EditorTransactionEffectsApi, Hs as SchemaElementPropertiesFor, Ht as EditorLevelsOptions, Hu as readEditorSchemaContract, I as DecorationRefresh, Ia as NodeSetNodesOptions, Ic as SelectionEdge, Ii as InitialValue, Il as TransferIntent, In as EditorSchemaElementStructure, Io as PluginTypeProvider, Ir as EditorTransactionBreakApi, Is as SchemaElement, Iu as locateAt, J as DocumentChange, Ja as NodeWrapNodesOptions, Jc as SliceLandingInput, Ji as LocationInterface, Jl as TransferSideInput, Jn as EditorSchemaPropertyReadOptions, Jo as ProjectedRangeSegment, Jr as EditorTransactionRemoved, Js as SchemaElementShapeFor, Jt as EditorNodeChangeContext, K as DescendantIn, Ka as NodeUnsetNodesOptions, Kc as SetSelectionCommand, Ki as Location, Kl as TransferRelation, Kn as EditorSchemaPropertyOverrideInput, Ko as PointEntry, Kr as EditorTransactionPluginsApi, Ks as SchemaElementPropertyOptions, Kt as EditorMarksOf, Ku as screenReaderAnnouncementEffect, L as DecorationSource, La as NodeSplitNodesOptions, Lc as SelectionMode, Li as InsertBreakCommand, Ll as TransferLandingInput, Ln as EditorSchemaGetProperty, Lr as EditorTransactionChangeContext, Ls as SchemaElementConstructionPropertiesFor, Lt as EditorInstalledApiGroups, Lu as mapEffect, Ma as NodeRemoveNodesOptions, Mc as Selection, Mi as HistoryApi, Ml as TransferCheck, Mn as EditorSchemaDerivedDefinition, Mr as EditorTransactionAnchor, Ms as SchemaContentRootSlotsFor, Mt as EditorEffectType, N as DebugValueScrubber, Na as NodeReplaceChildrenOptions, Nc as SelectionApi, Ni as HistoryOutcome, Nl as TransferDiagnostic, Nn as EditorSchemaElement, No as PluginSlot, Nr as EditorTransactionAnchorApi, Ns as SchemaContentRootStructure, Nt as EditorElementBehavior, Nu as invertEffect, O as ChildOf, Oa as NodeMutationMethods, Oc as SchemaTypesTarget, Oi as ElementIsElementOptions, Ol as TopLevelRuntimeRange, On as EditorSchemaContribution, Oo as PluginReadFactory, Or as EditorTextChangeContext, Os as SchemaContentRoot, Ot as EditorEffectCollabEncodeContext, P as Decoration, Pa as NodeSelection, Pc as SelectionAssociation, Pi as HistoryResult, Pl as TransferEdge, Pn as EditorSchemaElementOverride, Po as PluginSlotLike, Pr as EditorTransactionAnnotationsApi, Ps as SchemaContentRule, Pt as EditorFragmentDeletionOptions, Q as EditorBlockToggleOptions, Qa as PathAncestorsOptions, Qc as Span, Qi as MaximizeMode, Ql as TransferVetoInput, Qo as PropertyJsonDescriptor, Qr as EditorTransactionSpecBuilder, Qs as SchemaElementTypes, Qu as target, Ra as NodeTarget, Rc as SelectionMoveOptions, Ri as InsertNodesCommand, Rl as TransferLandingTarget, Rn as EditorSchemaIdentity, Ro as PluginTypes, Rr as EditorTransactionChangeHandler, Rs as SchemaElementFor, Rt as EditorInstalledReadGroups, S as BaseText, Sa as NodeLevelsOptions, Sc as SchemaTextBlockOptions, Si as Element, Sl as TextRemoveTextOptions, Sn as EditorSchemaContractChangeKind, Sr as EditorStateUniqueApi, Ss as SchemaBuiltInGroupName, Su as editorCommands, T as BooleanMarkKeysOf, Ta as NodeMatchPredicate, Tc as SchemaTextPropertyDefinition, Ti as ElementEntryOf, Tl as TextUnitAdjustment, Tn as EditorSchemaContractDiff, Tr as EditorStateViewApi, Ts as SchemaContentInput, Tt as EditorDocumentValue, U as DescendantEntry, Ua as NodeTextRangeView, Uc as SerializedEditorSelection, Ui as JsonNode, Uo as PluginsOf, Ur as EditorTransactionFragmentApi, Us as SchemaElementProperty, Ut as EditorLifecycleError, V as DerivedEditorSchemaIdentity, Va as NodeTextRangeQuery, Vc as SelectionValue, Vl as TransferPatchProperties, Vn as EditorSchemaOverrideInput, Vr as EditorTransactionDocumentChangeKind, Vs as SchemaElementProperties, Vt as EditorJsonValue, Vu as property, W as DescendantEntryIn, Wa as NodeTextsOptions, Wc as SerializedEditorValue, Wi as LeafEdge, Wl as TransferRead, Wn as EditorSchemaProperty, Wo as Point, Wr as EditorTransactionMarksApi, Ws as SchemaElementPropertyDefinition, Wt as EditorLifecycleErrorSink, Wu as restoreEditorSchemaContract, X as EditorAboveOptions, Xa as NodeWriteVetoInput, Xc as SnapshotIndex, Xi as MarksIn, Xl as TransferTarget, Xn as EditorSchemaRepairCode, Xo as PropertyBuilderApi, Xr as EditorTransactionSelectionApi, Xs as SchemaElementStructure, Xt as EditorNodeChangeKind, Xu as setEditorViewing, Ya as NodeWriteVeto, Yc as SliceLandingTarget, Yi as MarkKeysOf, Yl as TransferSourceInput, Yn as EditorSchemaReadProperty, Yo as PropertyBooleanDescriptor, Yr as EditorTransactionRootsApi, Ys as SchemaElementSlicePolicy, Yt as EditorNodeChangeHandler, Yu as setEditorReadOnly, Z as EditorBlockOptions, Za as Path, Zc as SnapshotInput, Zi as MarksOf, Zl as TransferVeto, Zn as EditorSchemaSource, Zo as PropertyEnumDescriptor, Zr as EditorTransactionSliceApi, Zs as SchemaElementTarget, Zt as EditorNodeGetOptions, _ as AuthoredVeto, _a as NodeInsertNodesOptions, _c as SchemaPropertyTypeChangePolicy, _i as EditorValueFromPlugins, _l as TextInsertFragmentOptions, _n as EditorRootOwner, _r as EditorStateRuntimeApi, _s as RemoveMarkCommand, _t as EditorCommitRuntimeChangeKind, _u as defineUpdateAnnotation, a as AncestorIn, aa as NodeApi, ac as SchemaProperty, ad as valueCodecs, ai as EditorUpdateAnnotation, al as StateFieldValueInput, an as EditorReadAroundHandler, ao as PluginApiFactory, ar as EditorSchemaVocabulary, as as PropertyValidation, at as EditorCommandDispatch, b as BasePoint, ba as NodeIsNodeOptions, bc as SchemaTarget, bi as EditorView, bl as TextMutationMethods, bn as EditorSchemaContract, br as EditorStateSliceApi, bt as EditorCoreUpdateTransaction, bu as diffEditorSchemaContracts, c as AnchorAssociation, ca as NodeDescendantsOptions, cc as SchemaPropertyExclusiveGroup, ci as EditorUpdatePolicy, cl as Text, cn as EditorReadInput, co as PluginCandidateEditor, cr as EditorSelectionTargetOptions, cs as PropertyValueOf, ct as EditorCommandPlace, cu as compileEditorSchemaContract, d as AnchorValue, da as NodeEntry, dc as SchemaPropertyIds, di as EditorUpdateTagInput, dl as TextDirection, dn as EditorReadMethods, do as PluginContribution, dr as EditorStateField, ds as RangeAnchorAssociation, dt as EditorCommit, du as defineCommand$1, ea as MoveUnit, ec as SchemaGroupNames, ed as transferVeto, ei as EditorTransactionTextApi, el as SpanInterface, en as EditorNodesOptions, eo as PathInterface, er as EditorSchemaUnknownPolicy, es as PropertyNumberDescriptor, et as EditorCanonicalUpdateTag, eu as TxDeclaredMethod, fa as NodeEntryIn, fc as SchemaPropertyKey, fi as EditorUpdateTransaction, fl as TextEntry, fn as EditorReadRegistration, fo as PluginContributionInput, fr as EditorStateFragmentApi, fs as RangeApi, ft as EditorCommitChangeKind, fu as defineEditorSchema, g as AuthoredTouch, ga as NodeIn, gc as SchemaPropertySplitPolicy, gi as EditorValueFromOptions, gl as TextIn, gn as EditorRootEntry, go as PluginDependencyReference, gr as EditorStateRangesApi, gs as RangeMode, gt as EditorCommitListener, gu as defineStateField, ha as NodeHasPropsOptions, hc as SchemaPropertyRole, hi as EditorUpdateValueFromPlugin, hl as TextEqualsOptions, hn as EditorReplaceNodeOptions, hr as EditorStatePointsApi, hs as RangeInterface, ht as EditorCommitHandler, hu as definePluginSlot, i as AncestorEntryOf, ia as NodeAncestorsOptions, ic as SchemaPluginsOf, ii as EditorUpdate, il as StateFieldInitial, in as EditorRead, io as PluginActivationContext, ir as EditorSchemaValidationPropertyContext, is as PropertyStringDescriptor, it as EditorCommandDescriptor, iu as ValueOf, j as ContentSlice, ja as NodeProps, jc as SelectCommand, ji as ElementOrTextOf, jl as TransferApi, jn as EditorSchemaDelta, jo as PluginReconfigureOptions, jr as EditorToggleMarkOptions, js as SchemaContentRootOwnership, jt as EditorEffectHistoryReplayResult, k as CollapseSelectionCommand, ka as NodeNodesOptions, kc as SchemaValue, ki as ElementOf, kl as TransactionSpec, kn as EditorSchemaDeclaration, ko as PluginReadFactoryContext, kr as EditorTextChangeHandler, ks as SchemaContentRootContribution, kt as EditorEffectCollabReplay, ku as getSelection, l as AnchorDeletionPolicy, la as NodeDuplicateOptions, lc as SchemaPropertyHandle, li as EditorUpdatePolicyFor, ll as TextApi, ln as EditorReadMethodRecord, lo as PluginCapabilities, lr as EditorSliceReadOptions, ls as PropertyValueOptions, lt as EditorCommandResult, lu as createEditorView, m as AuthoredProjectionDiagnostic, ma as NodeFindTextRangesOptions, mc as SchemaPropertyReferences, ml as TextEntryOf, mn as EditorReplaceChildrenOptions, mr as EditorStateNodesApi, ms as RangeEdgesOptions, mt as EditorCommitContext, mu as definePluginPoint, n as Ancestor, na as NamedRootKey, nc as SchemaKeyPrefix, nd as txOnly, ni as EditorTransactionValueApi, nl as StateFieldDescriptor, nn as EditorParentOptions, no as PersistedDocumentInput, nr as EditorSchemaValidationDiagnostic, ns as PropertySetDescriptor, nt as EditorCommandAroundHandler, nu as TxOnlyMethod, o as AncestorOf, oa as NodeChildEntry, oc as SchemaPropertyCopyPolicy, oi as EditorUpdateContext, on as EditorReadContext, oo as PluginApiFactoryContext, or as EditorSelection, os as PropertyValueDescriptor, ot as EditorCommandHandler, ou as authoredVeto, p as AuthoredDocumentProjection, pa as NodeEntryOf, pc as SchemaPropertyLandingPolicy, pl as TextEntryIn, pn as EditorReadResult, po as PluginDefinition, pr as EditorStateMarksApi, ps as RangeDirection, pt as EditorCommitChanged, pu as defineEffect, q as DescendantOf, qa as NodeUnwrapNodesOptions, qc as SliceLanding, qi as LocationApi, ql as TransferSide, qn as EditorSchemaPropertyQuery, qo as PointInterface, qr as EditorTransactionRecordsApi, qs as SchemaElementPropertyValue, qt as EditorNextOptions, qu as setDebugValueScrubber, r as AncestorEntry, ra as Node, rd as txSelection, ri as EditorUniqueHolder, rl as StateFieldHistoryPolicy, rn as EditorPreviousOptions, rr as EditorSchemaValidationError, rs as PropertySetOptions, rt as EditorCommandContinuation, ru as Value, s as Anchor, sa as NodeChildrenOptions, sc as SchemaPropertyDefinition, si as EditorUpdateMethods, sl as TargetFreshnessRequest, sn as EditorReadDescriptor, so as PluginCandidateContext, sr as EditorSelectionBlockOptions, ss as PropertyValueKind, st as EditorCommandInput, t as AddMarkCommand, ta as NamedEditorSchemaIdentity, tc as SchemaGroupOptions, td as txLocate, ti as EditorTransactionTopLevelRange, tl as StateFieldCollabPolicy, tn as EditorNodesReadOptions, to as PathLevelsOptions, tr as EditorSchemaValidationCode, ts as PropertyOptionsOf, tt as EditorCommand, tu as TxMethodDeclarations, u as AnchorOptions, ua as NodeElementsOptions, uc as SchemaPropertyHandleValue, ui as EditorUpdateTag, ul as TextDeleteOptions, un as EditorReadMethodTree, uo as PluginCleanupContext, ur as EditorSnapshot, us as Range, ut as EditorCommands, uu as decodeEditorEffect, v as BaseElement, va as NodeInsertSplitOptions, vc as SchemaRecordSet, vi as EditorValuePersistence, vl as TextInsertTextOptions, vn as EditorSchemaContent, vr as EditorStateSchemaApi, vs as RemoveNodesCommand, vt as EditorCoreStateView, wa as NodeMatch, wc as SchemaTextProperty, wi as ElementEntry, wl as TextUnit, wn as EditorSchemaContractContentRoot, wo as PluginPoint, wr as EditorStateView, ws as SchemaContentDefault, wt as EditorDocumentRecords, wu as encodeEditorEffect, x as BaseRange, xa as NodeKey, xc as SchemaText, xi as EditorViewOptions, xl as TextOf, xn as EditorSchemaContractChange, xo as PluginInput, xr as EditorStateTextApi, xs as RootKey, xt as EditorDirectCommandDispatch, xu as documentReplacement, y as BaseNode, ya as NodeInterface, yc as SchemaRootNames, yl as TextInterface, yn as EditorSchemaContentRoot, yr as EditorStateSelectionApi, ys as ReplaceSliceCommand, yt as EditorCoreUpdateMethods, z as DeleteCommand, za as NodeTextRangeEntry, zc as SelectionMutationMethods, zi as InsertSoftBreakCommand, zl as TransferOutcome, zn as EditorSchemaNamedDefinition, zo as PluginUpdateFactory, zr as EditorTransactionChanged, zs as SchemaElementHandle, zt as EditorInstalledUpdateGroups, zu as nodeWriteVeto } from "./index-DpltOCot-A2b3p3Eb.js";
|
|
2
|
+
import { h as EditorApplicationSchema } from "./htmlTypes-cg_cWsaN.js";
|
|
3
|
+
import { $a as InferEnabled, $i as definePlugin, $n as HeadingRules, $r as InputRulesDefinition, $t as UpsertLinkOptions, Aa as RenderElementFn, Ai as AutoScrollOptions, An as CapturedFormat, Ao as PluginSelectorMethods, Ar as BaseParagraphDefinition, At as PlainTextSerializeResult, B as InjectNodeProps, Bi as DebugPlugin, Bn as BaseStrikethroughPlugin, Bo as WithRequiredName, Br as HtmlPlugin, Bt as OutdentListOptions, C as BasePluginOn, Ca as MarkdownTagNode, Ci as ElementStatePlugin, Cn as BaseTextAlignPlugin, Co as PluginSchemaContext, Cr as RenderTextFn, Ct as PluginTransaction, Da as PluginFormatRegistry, Di as AutoScrollApi, Dn as TextIndentDefinition, Do as PluginSchemaReferences, Dr as RenderLeafFn, Dt as PlainTextDiagnostic, E as ConfiguredBasePlugin, Ea as PluginFormatModelView, Ei as ElementIdPluginState, En as TextAlignDefinition, Eo as PluginSchemaMark, Er as RenderTextProps, F as HtmlMatchValue, Fa as ElementWith, Fi as ScrollIntoViewTarget, Fn as BaseCodePlugin, Fo as RuleDecision, Fr as createBlockStartInputRule, Ft as BulletedListRules, G as PluginShortcutInput, Ga as DefinitionOf, Gi as AffinityEdgeNodes, Gn as ItalicRules, Go as AnyObject, Gr as BlockStartInputRuleConfig, Gt as BaseLinkDefinition, H as LeafStaticProps, Ha as BasePluginDefinition, Hi as EditorError, Hn as BoldRules, Hr as BaseInputRule, Ht as ToggleListOptions, I as HtmlMatcher, Ia as PluginFormatNode, Ii as ScrollMode, In as BaseHighlightPlugin, Io as SelectionRules, Ir as createMarkInputRule, It as ListElement, J as RenderStaticNodeWrapperProps, Ja as GetInjectNodePropsOptions, Ji as TransferDefinition, Jn as ScriptValue, Jr as InputRule, Jt as CreateLinkNodeOptions, K as RenderStaticNodeWrapper, Ka as DeleteRules, Ki as AffinityPlugin, Kn as MarkComboRules, Ko as UnknownObject, Kr as BlockStartInputRuleMatch, Kt as BaseLinkPlugin, L as HtmlNodeSpec, La as TextWith, Li as DebugApi, Ln as BaseItalicPlugin, Lo as StructuralRuleContext, Lr as createTextSubstitutionInputRule, Lt as ListStyle, M as HtmlAttributes, Ma as RenderElementSlots, Mi as DomApi, Mn as FormattingContribution, Mo as PluginSelectors, Mr as inputRuleVeto, Mt as BULLETED_LIST_STYLES, N as HtmlContentToken, Na as HandlerReturnType, Ni as DomPluginState, Nn as formatting, No as PluginStore, Nr as defineInputRule, Nt as BaseListDefinition, O as DeclaredPluginShortcutInput, Oa as PluginFormatSchemaView, Oi as AutoScrollChangeKind, On as TextIndentPluginState, Oo as PluginSelector, Or as RenderLeafProps, Ot as PlainTextDocumentOptions, P as HtmlElementPatch, Pa as DocxNodeMapping, Pi as DomPluginUpdate, Pn as BaseBoldPlugin, Pr as createBlockFenceInputRule, Pt as BaseListPlugin, Qa as InferDependencies, Qi as HistoryPluginState, Qn as HeadingLevel, Qr as InputRulesConfig, Qt as UnwrapLinkOptions, R as HtmlPrepareDiagnosticInput, Ra as nanoid, Ri as DebugDefinition, Rn as BaseKbdPlugin, Ro as StructuralRuleEditor, Rr as matchBlockStart, Rt as ListType, S as BasePluginImplementationContext, Sa as MarkdownTagAttributeView, Si as ElementStateDefinition, Sn as BaseLineHeightPlugin, So as PluginSchema, Sr as EditableProps, St as PluginState, T as BasePluginPortal, Ta as PluginFormatContext, Ti as ElementIdPlugin, Tn as LineHeightDefinition, To as PluginSchemaElement, Tr as RenderTextPieceProps, U as NodeStaticProps, Ui as LogLevel, Un as CodeRules, Ur as BlockFenceInputRuleConfig, Ut as isOrderedList, Va as BaseInjectProps, Vi as DebugPluginState, Vn as BaseUnderlinePlugin, Vt as TaskListRules, W as PartialBasePlugin, Wa as BreakRules, Wi as AffinityDefinition, Wn as HighlightRules, Wo as Nullable, Wr as BlockFenceInputRuleMatch, X as TransformOptions, Xa as InferApi, Xi as HistoryDefinition, Xn as UnderlineRules, Xr as InputRuleInsertTextOptions, Xt as LinkElement, Y as TextStaticProps, Ya as GetInjectNodePropsReturnType, Yi as TransferPlugin, Yn as StrikethroughRules, Yr as InputRuleEditor, Yt as LinkAttributes, Za as InferConflicts, Zi as HistoryPlugin, Zn as BaseHeadingPlugin, Zr as InputRuleTarget, Zt as LinkRules, _ as BasePlugin, _a as MarkdownNodeKinds, _i as TextSubstitutionInputRuleConfig, _n as Alignment, _o as PluginBaseContext, _r as getFragmentProp, _t as NodeInsertOptions, a as SingleLinePlugin, ai as InsertDataInputRuleReadContext, an as IndentPluginState, ao as InferPluginStoreState, ar as getPluginNodeClass, b as BasePluginDefinitionInput, ba as MarkdownPluginRegistry, bi as TransformInputRuleContext, bn as BaseFontFamilyPlugin, br as ApplyDeepToNodesOptions, c as PLUGINS, ca as PlainTextEncodeContext, ci as InsertTextInputRuleReadContext, cn as BaseCodeBlockPlugin, co as InferRead, cr as mergeDeepToNodes, ct as BlockInsertOptions, da as MarkdownDecodeContext, di as MatchBlockFenceOptions, dn as CodeBlockElement, do as InferUpdate, dr as Hotkeys, ei as InsertBreakInputRule, en as WrapLinkOptions, eo as InferName, er as ToggleHeadingOptions, et as CreateEditorOptions, fa as MarkdownEncodeContext, fi as MatchBlockStartOptions, fn as CodeHighlightDefinition, fo as MergeRules, fr as createHotkey, ga as MarkdownNodeKind, gi as SelectionInputRuleContext, gn as HighlightResult, go as NormalizeRules, gr as GetFragmentPropOptions, ha as MarkdownMarks, hi as ResolvedInputRulesMeta, hn as HighlightNode, hr as FragmentPropMode, i as TrailingBlockPluginState, ii as InsertDataInputRuleContext, in as IndentDefinition, io as InferPluginReadGroups, ir as HorizontalRuleRules, j as EditorShortcut, ja as RenderElementProps, ji as AutoScrollUpdate, jn as FormattingBlockEntry, jo as PluginSelectorReturn, jr as BaseParagraphPlugin, jt as serializePlainText, k as Decorate, ka as ElementContentRootSlot, ki as AutoScrollChangesMap, kn as BaseFormattingPlugin, ko as PluginSelectorArgs, kr as StaticRenderLeafProps, kt as PlainTextEditorOptions, l as PluginName, la as PlainTextNodeMapping, li as MarkInputRuleConfig, ln as BaseCodeHighlightPlugin, lo as InferSelectors, lr as isUrl, lt as BlockUpsertOptions, ma as MarkdownMarkWrapper, mi as ResolvedInputRule, mn as CodeHighlightPluginState, mr as getInjectMatch, n as TrailingBlockDefinition, ni as InsertBreakInputRuleReadContext, nn as BaseIndentPlugin, no as InferOwnRead, nr as BaseHorizontalRulePlugin, o as SingleBlockPlugin, oi as InsertTextInputRule, oo as InferPluginUpdateGroups, or as isPluginElementClass, ot as createEditor, pa as MarkdownMarkWrapContext, pi as MatchDelimitedInlineOptions, pn as CodeHighlightLowlight, po as NodeComponent, pr as isHotkey, q as RenderStaticNodeWrapperFunction, qa as EditOnlyConfig, qi as AffinityPluginUpdate, qn as ScriptRules, qr as DelimitedInlineInputRuleMatch, qt as BaseLinkPluginState, r as TrailingBlockPlugin, ri as InsertDataInputRule, rn as IndentChangeOptions, ro as InferOwnUpdate, rr as BlockquoteRules, rt as EditorValueInput, s as ExitBreakPlugin, si as InsertTextInputRuleContext, sn as CodeBlockRules, sr as isPluginNodeClass, st as BasePluginInput, t as isNominalPluginDescriptor, ti as InsertBreakInputRuleContext, tn as getLinkHref, to as InferOwnApi, tr as BaseBlockquotePlugin, u as Editor, ua as PlainTextNodeMappingInput, ui as MarkInputRuleMatch, un as CodeBlockDefinition, uo as InferTargetPlugins, ur as isDefined, v as BasePluginConfiguration, va as MarkdownNodeMapping, vi as TextSubstitutionMatch, vn as BaseFontBackgroundColorPlugin, vr as IS_APPLE, w as BasePluginOverride, wa as HtmlMappingDiagnosticInput, wi as ElementIdEntry, wn as BaseTextIndentPlugin, wo as PluginSchemaDeclaration, wr as RenderTextHostProps, wt as PluginUpdate, x as BasePluginExtendInput, xa as MarkdownRefusal, xi as ElementStateApi, xn as BaseFontSizePlugin, xo as PluginReference, xr as applyDeepToNodes, xt as PluginReadState, y as BasePluginContext, ya as MarkdownNodeMappingInput, yi as TextSubstitutionPattern, yn as BaseFontColorPlugin, yo as PluginDependency, yr as defaultsDeepToNodes, yt as PluginOwnUpdate, z as HtmlWrapperSpec, zi as DebugErrorType, zn as BaseScriptPlugin, zo as WithAnyName, zr as matchDelimitedInline, zt as OrderedListRules } from "./core-ClHasORr.js";
|
|
4
|
+
export { type AddMarkCommand, AffinityDefinition, AffinityEdgeNodes, AffinityPlugin, AffinityPluginUpdate, Alignment, Ancestor, AncestorEntry, AncestorEntryOf, AncestorIn, AncestorOf, type Anchor, type AnchorAssociation, type AnchorDeletionPolicy, type AnchorOptions, type AnchorValue, type AnyObject, ApplyDeepToNodesOptions, type AuthoredDocumentProjection, type AuthoredProjectionDiagnostic, type AuthoredTouch, type AuthoredVeto, type AutoScrollApi, type AutoScrollChangeKind, type AutoScrollChangesMap, type AutoScrollOptions, type AutoScrollUpdate, BULLETED_LIST_STYLES, BaseBlockquotePlugin, BaseBoldPlugin, BaseCodeBlockPlugin, BaseCodeHighlightPlugin, BaseCodePlugin, BaseElement, BaseFontBackgroundColorPlugin, BaseFontColorPlugin, BaseFontFamilyPlugin, BaseFontSizePlugin, BaseFormattingPlugin, BaseHeadingPlugin, BaseHighlightPlugin, BaseHorizontalRulePlugin, BaseIndentPlugin, type BaseInjectProps, BaseInputRule, BaseItalicPlugin, BaseKbdPlugin, BaseLineHeightPlugin, BaseLinkDefinition, BaseLinkPlugin, BaseLinkPluginState, BaseListDefinition, BaseListPlugin, BaseNode, BaseParagraphDefinition, BaseParagraphPlugin, type BasePlugin, type BasePlugin as Plugin, type BasePluginConfiguration, type BasePluginContext, type BasePluginDefinition, type BasePluginDefinitionInput, type BasePluginDefinitionInput as PluginDefinitionInput, type BasePluginExtendInput, type BasePluginImplementationContext, type BasePluginInput, type BasePluginOn, type BasePluginOverride, type BasePluginPortal, type BasePluginPortal as PluginPortal, BasePoint, BaseRange, BaseScriptPlugin, BaseStrikethroughPlugin, BaseText, BaseTextAlignPlugin, BaseTextIndentPlugin, BaseUnderlinePlugin, type BlockDuplicateOptions, BlockFenceInputRuleConfig, BlockFenceInputRuleMatch, type BlockInsertOptions, BlockStartInputRuleConfig, BlockStartInputRuleMatch, type BlockUpsertOptions, BlockquoteRules, BoldRules, BooleanMarkKeysOf, BooleanMarksOf, type BreakRules, BulletedListRules, CapturedFormat, ChildOf, CodeBlockDefinition, CodeBlockElement, CodeBlockRules, CodeHighlightDefinition, CodeHighlightLowlight, CodeHighlightPluginState, CodeRules, type CollapseSelectionCommand, type CompatibleEditorCommand, type ConfiguredBasePlugin, ContentSlice, type CreateEditorOptions, CreateLinkNodeOptions, DebugApi, DebugDefinition, DebugErrorType, DebugPlugin, DebugPluginState, type DebugValueScrubber, type DeclaredPluginShortcutInput, type Decorate, type Decoration, type DecorationAttributes, type DecorationRefresh, type DecorationSource, type DefinitionOf, type DeleteCommand, type DeleteFragmentCommand, type DeleteRules, DelimitedInlineInputRuleMatch, type DerivedEditorSchemaIdentity, Descendant, DescendantEntry, DescendantEntryIn, DescendantEntryOf, DescendantIn, DescendantOf, DocumentChange, type DocxNodeMapping, type DomApi, type DomPluginState, type DomPluginUpdate, type EditOnlyConfig, type EditableProps, type Editor, type EditorAboveOptions, type EditorApplicationSchema, type EditorBlockOptions, type EditorBlockToggleOptions, type EditorBreakExitOptions, type EditorCanonicalUpdateTag, type EditorCommand, type EditorCommandAroundHandler, type EditorCommandContinuation, type EditorCommandDescriptor, type EditorCommandDispatch, type EditorCommandHandler, type EditorCommandInput, type EditorCommandPlace, type EditorCommandResult, type EditorCommands, type EditorCommit, type EditorCommitChangeKind, type EditorCommitChanged, type EditorCommitContext, type EditorCommitHandler, type EditorCommitListener, type EditorCommitRuntimeChangeKind, type EditorCoreStateView, type EditorCoreUpdateMethods, type EditorCoreUpdateTransaction, type EditorDirectCommandDispatch, type EditorDocumentRange, type EditorDocumentRecords, type EditorDocumentValue, type EditorEffect, type EditorEffectCollabDecodeContext, type EditorEffectCollabEncodeContext, type EditorEffectCollabReplay, type EditorEffectCollabTransport, type EditorEffectHistoryReplayResult, type EditorEffectType, type EditorElementBehavior, EditorError, type EditorFragmentDeletionOptions, type EditorFragmentReadOptions, type EditorInstalledApiGroups, type EditorInstalledReadGroups, type EditorInstalledUpdateGroups, type EditorIsEditorOptions, type EditorJsonValue, type EditorLevelsOptions, type EditorLifecycleError, type EditorLifecycleErrorSink, type EditorMarks, type EditorMarksOf, type EditorNextOptions, type EditorNodeChangeContext, type EditorNodeChangeHandler, type EditorNodeChangeKind, type EditorNodeGetOptions, type EditorNodeUnsetOptions, type EditorNodesOptions, type EditorNodesReadOptions, type EditorParentOptions, type EditorPreviousOptions, type EditorRead, type EditorReadAroundHandler, type EditorReadContext, type EditorReadDescriptor, type EditorReadInput, type EditorReadMethodRecord, type EditorReadMethodTree, type EditorReadMethods, type EditorReadRegistration, type EditorReadResult, type EditorReplaceChildrenOptions, type EditorReplaceNodeOptions, type EditorRootEntry, type EditorRootOwner, type EditorSchemaContent, type EditorSchemaContentRoot, type EditorSchemaContract, type EditorSchemaContractChange, type EditorSchemaContractChangeKind, type EditorSchemaContractContentProgram, type EditorSchemaContractContentRoot, type EditorSchemaContractDiff, type EditorSchemaContractElement, type EditorSchemaContractRoot, type EditorSchemaContribution, type EditorSchemaDeclaration, type EditorSchemaDefinition, type EditorSchemaDelta, type EditorSchemaDerivedDefinition, type EditorSchemaElement, type EditorSchemaElementOverride, type EditorSchemaElementOverrideInput, type EditorSchemaElementStructure, type EditorSchemaGetProperty, type EditorSchemaIdentity, type EditorSchemaNamedDefinition, type EditorSchemaOverride, type EditorSchemaOverrideInput, type EditorSchemaPlugin, type EditorSchemaProperty, type EditorSchemaPropertyOverride, type EditorSchemaPropertyOverrideInput, type EditorSchemaPropertyQuery, type EditorSchemaPropertyReadOptions, type EditorSchemaReadProperty, type EditorSchemaRepairCode, type EditorSchemaSource, type EditorSchemaStructureProperty, type EditorSchemaUnknownPolicy, type EditorSchemaValidationCode, type EditorSchemaValidationDiagnostic, EditorSchemaValidationError, type EditorSchemaValidationPropertyContext, type EditorSchemaVocabulary, EditorSelection, type EditorSelectionBlockOptions, type EditorSelectionTargetOptions, type EditorShortcut, type EditorSliceReadOptions, type EditorSnapshot, type EditorStateField, type EditorStateFragmentApi, type EditorStateMarksApi, type EditorStateNodesApi, type EditorStatePointsApi, type EditorStateRangesApi, type EditorStateRuntimeApi, type EditorStateSchemaApi, type EditorStateSelectionApi, type EditorStateSliceApi, type EditorStateTextApi, type EditorStateUniqueApi, type EditorStateValueApi, type EditorStateView, type EditorStateViewApi, type EditorTargetRuntime, type EditorTextChangeContext, type EditorTextChangeHandler, type EditorToggleBlockOptions, type EditorToggleMarkOptions, type EditorTransactionAnchor, type EditorTransactionAnchorApi, type EditorTransactionAnnotationsApi, type EditorTransactionBlocksApi, type EditorTransactionBreakApi, type EditorTransactionChangeContext, type EditorTransactionChangeHandler, type EditorTransactionChanged, type EditorTransactionChangesApi, type EditorTransactionDocumentChangeKind, type EditorTransactionEffectsApi, type EditorTransactionFragmentApi, type EditorTransactionMarksApi, type EditorTransactionNodesApi, type EditorTransactionPluginsApi, type EditorTransactionRecordsApi, type EditorTransactionRemoved, type EditorTransactionRootsApi, type EditorTransactionSelectionApi, type EditorTransactionSliceApi, type EditorTransactionSpecBuilder, type EditorTransactionTagsApi, type EditorTransactionTextApi, type EditorTransactionTopLevelRange, type EditorTransactionValueApi, type EditorUniqueHolder, type EditorUpdate, type EditorUpdateAnnotation, type EditorUpdateContext, type EditorUpdateMethods, type EditorUpdatePolicy, type EditorUpdatePolicyFor, type EditorUpdateTag, type EditorUpdateTagInput, type EditorUpdateTransaction, type EditorUpdateValueFromPlugin, type EditorValueFromOptions, type EditorValueFromPlugins, type EditorValueInput, type EditorValuePersistence, type EditorView, type EditorViewOptions, Element, ElementApi, type ElementContentRootSlot, ElementEntry, ElementEntryOf, ElementIdEntry, ElementIdPlugin, ElementIdPluginState, ElementIn, ElementInterface, ElementIsElementOptions, ElementOf, ElementOrTextIn, ElementOrTextOf, ElementStateApi, ElementStateDefinition, ElementStatePlugin, type ElementWith, ExitBreakPlugin, FormattingBlockEntry, FormattingContribution, FragmentPropMode, GetFragmentPropOptions, type GetInjectNodePropsOptions, type GetInjectNodePropsReturnType, type HandlerReturnType, HeadingLevel, HeadingRules, HighlightNode, HighlightResult, HighlightRules, type HistoryApi, HistoryDefinition, type HistoryOutcome, HistoryPlugin, HistoryPluginState, type HistoryResult, type HistorySettlement, HorizontalRuleRules, Hotkeys, type HtmlAttributes, type HtmlContentToken, type HtmlElementPatch, type HtmlMappingDiagnosticInput, type HtmlMatchValue, type HtmlMatcher, type HtmlNodeSpec, HtmlPlugin, type HtmlPrepareDiagnosticInput, type HtmlWrapperSpec, IS_APPLE, IndentChangeOptions, IndentDefinition, IndentPluginState, type InferApi, type InferConflicts, type InferDependencies, type InferEnabled, type InferName, type InferOwnApi, type InferOwnRead, type InferOwnUpdate, type InferPluginReadGroups, type InferPluginStoreState, type InferPluginUpdateGroups, type InferRead, type InferSelectors, type InferTargetPlugins, type InferUpdate, type InitialValue, type InjectNodeProps, InputRule, InputRuleEditor, InputRuleInsertTextOptions, InputRuleTarget, InputRulesConfig, InputRulesDefinition, type InsertBreakCommand, InsertBreakInputRule, InsertBreakInputRuleContext, InsertBreakInputRuleReadContext, InsertDataInputRule, InsertDataInputRuleContext, InsertDataInputRuleReadContext, type InsertNodesCommand, type InsertSoftBreakCommand, type InsertTextCommand, InsertTextInputRule, InsertTextInputRuleContext, InsertTextInputRuleReadContext, ItalicRules, type JsonEditorValue, type JsonNode, type LeafEdge, LeafPosition, type LeafStaticProps, LineHeightDefinition, LinkAttributes, LinkElement, LinkRules, ListElement, ListStyle, ListType, Location, LocationApi, LocationInterface, LogLevel, MarkComboRules, MarkInputRuleConfig, MarkInputRuleMatch, MarkKeysOf, type MarkdownDecodeContext, type MarkdownEncodeContext, type MarkdownMarkWrapContext, type MarkdownMarkWrapper, type MarkdownMarks, type MarkdownNodeKind, type MarkdownNodeKinds, type MarkdownNodeMapping, type MarkdownNodeMappingInput, type MarkdownPluginRegistry, type MarkdownRefusal, type MarkdownTagAttributeView, type MarkdownTagNode, MarksIn, MarksOf, MatchBlockFenceOptions, MatchBlockStartOptions, MatchDelimitedInlineOptions, type MaximizeMode, type MergeRules, type MoveSelectionCommand, type MoveUnit, type NamedEditorSchemaIdentity, type NamedRootKey, Node, NodeAncestorsOptions, NodeApi, NodeChildEntry, NodeChildrenOptions, type NodeComponent, NodeDescendantsOptions, type NodeDuplicateOptions, NodeElementsOptions, NodeEntry, NodeEntryIn, NodeEntryOf, NodeFindTextRangesOptions, NodeHasPropsOptions, NodeIn, type NodeInsertNodesOptions, type NodeInsertOptions, type NodeInsertSplitOptions, NodeInterface, NodeIsNodeOptions, type NodeKey, NodeLevelsOptions, type NodeLiftNodesOptions, NodeMatch, NodeMatchPredicate, type NodeMergeNodesOptions, type NodeMoveNodesOptions, type NodeMutationMethods, NodeNodesOptions, NodeOf, NodeProps, type NodeRemoveNodesOptions, type NodeReplaceChildrenOptions, NodeSelection, NodeSelectionMode, type NodeSetNodesOptions, type NodeSplitNodesOptions, type NodeStaticProps, type NodeTarget, NodeTextRangeEntry, NodeTextRangeMatch, NodeTextRangeQuery, NodeTextRangeRoot, NodeTextRangeView, NodeTextsOptions, NodeTypeSelector, type NodeUnsetNodesOptions, type NodeUnwrapNodesOptions, type NodeWrapNodesOptions, type NodeWriteVeto, type NodeWriteVetoInput, type NormalizeRules, type Nullable, OrderedListRules, OutdentListOptions, PLUGINS, type PartialBasePlugin, Path, PathAncestorsOptions, PathApi, PathInterface, PathLevelsOptions, type PersistedDocumentInput, PlainTextDiagnostic, PlainTextDocumentOptions, PlainTextEditorOptions, type PlainTextEncodeContext, type PlainTextNodeMapping, type PlainTextNodeMappingInput, PlainTextSerializeResult, type PluginActivationContext, type PluginApiFactory, type PluginApiFactoryContext, type PluginBaseContext, type PluginCandidateContext, type PluginCandidateEditor, type PluginCapabilities, type PluginCleanupContext, type PluginContribution, type PluginContributionInput, type PluginDefinition, type PluginDependency, type PluginDependencyReference, type PluginFormatContext, type PluginFormatModelView, type PluginFormatNode, type PluginFormatRegistry, type PluginFormatSchemaView, type PluginInput, type PluginMigrationContext, PluginName, type PluginOwnUpdate, type PluginPoint, PluginPublicationError, type PluginReadContext, type PluginReadFactory, type PluginReadFactoryContext, type PluginReadMiddlewareFactory, type PluginReadState, type PluginReconfigureOptions, type PluginReference, type PluginSchema, type PluginSchemaContext, type PluginSchemaDeclaration, type PluginSchemaElement, type PluginSchemaMark, type PluginSchemaReferences, type PluginSelector, type PluginSelectorArgs, type PluginSelectorMethods, type PluginSelectorReturn, type PluginSelectors, type PluginShortcutInput, type PluginSlot, type PluginSlotLike, type PluginSlotValue, type PluginState, type PluginStore, type PluginTransaction, type PluginTypeProvider, type PluginTypes, type PluginUpdate, type PluginUpdateFactory, type PluginUpdateFactoryContext, type PluginsFromOptions, type PluginsOf, Point, PointApi, PointEntry, PointInterface, type ProjectedRangeSegment, type PropertyBooleanDescriptor, type PropertyBuilderApi, type PropertyEnumDescriptor, type PropertyJsonDescriptor, type PropertyJsonOptions, type PropertyNumberDescriptor, type PropertyOptionsOf, type PropertySetDescriptor, type PropertySetOptions, type PropertyStringDescriptor, type PropertyValidation, type PropertyValueDescriptor, type PropertyValueKind, type PropertyValueOf, type PropertyValueOptions, Range, type RangeAnchorAssociation, RangeApi, type RangeDirection, RangeEdgesOptions, RangeInterface, type RangeMode, type RemoveMarkCommand, type RemoveNodesCommand, type RenderElementFn, type RenderElementProps, type RenderElementSlots, type RenderLeafFn, type RenderLeafProps, type RenderStaticNodeWrapper, type RenderStaticNodeWrapperFunction, type RenderStaticNodeWrapperProps, type RenderTextFn, type RenderTextHostProps, type RenderTextPieceProps, type RenderTextProps, type ReplaceSliceCommand, ResolvedInputRule, ResolvedInputRulesMeta, type RootKey, type RuleDecision, type SchemaBuiltInGroupName, type SchemaContent, type SchemaContentDefault, type SchemaContentInput, type SchemaContentOptions, type SchemaContentPrefixSlot, type SchemaContentRoot, type SchemaContentRootContribution, type SchemaContentRootInput, type SchemaContentRootOwnership, type SchemaContentRootSlotsFor, type SchemaContentRootStructure, type SchemaContentRule, type SchemaDescendant, type SchemaElement, type SchemaElementConstructionPropertiesFor, type SchemaElementFor, type SchemaElementHandle, type SchemaElementInput, type SchemaElementProperties, type SchemaElementPropertiesFor, type SchemaElementProperty, type SchemaElementPropertyDefinition, type SchemaElementPropertyKeys, type SchemaElementPropertyOptions, type SchemaElementPropertyValue, type SchemaElementShapeFor, type SchemaElementSlicePolicy, type SchemaElementStructure, type SchemaElementTarget, type SchemaElementTypes, type SchemaGroup, type SchemaGroupNames, type SchemaGroupOptions, type SchemaKeyPrefix, type SchemaPluginsOf, type SchemaProperty, type SchemaPropertyCopyPolicy, type SchemaPropertyDefinition, type SchemaPropertyExclusiveGroup, type SchemaPropertyHandle, type SchemaPropertyHandleValue, type SchemaPropertyIds, type SchemaPropertyKey, type SchemaPropertyLandingPolicy, type SchemaPropertyReferences, type SchemaPropertyRole, type SchemaPropertySplitPolicy, type SchemaPropertyTypeChangePolicy, type SchemaRecordSet, type SchemaRootNames, type SchemaTarget, type SchemaText, type SchemaTextBlockOptions, type SchemaTextProperties, type SchemaTextProperty, type SchemaTextPropertyDefinition, type SchemaTextPropertyKeys, type SchemaTextPropertyOptions, type SchemaTypesTarget, type SchemaValue, type SchemaValueFromPlugins, ScriptRules, ScriptValue, type ScrollIntoViewTarget, type ScrollMode, type SelectCommand, Selection, SelectionApi, SelectionAssociation, type SelectionCollapseOptions, type SelectionEdge, SelectionInputRuleContext, type SelectionMode, type SelectionMoveOptions, type SelectionMutationMethods, type SelectionRules, type SelectionSetPointOptions, SelectionValue, type SerializedEditorEffect, type SerializedEditorSelection, type SerializedEditorValue, type SetNodesCommand, type SetSelectionCommand, SingleBlockPlugin, SingleLinePlugin, type SliceLanding, type SliceLandingInput, type SliceLandingTarget, type SnapshotIndex, type SnapshotInput, Span, SpanApi, SpanInterface, type StateFieldCollabPolicy, type StateFieldDescriptor, type StateFieldHistoryPolicy, type StateFieldInitial, type StateFieldValueInput, type StaticRenderLeafProps, StrikethroughRules, type StructuralRuleContext, type StructuralRuleEditor, type TargetFreshnessRequest, TaskListRules, Text, TextAlignDefinition, TextApi, type TextDeleteOptions, type TextDirection, TextEntry, TextEntryIn, TextEntryOf, TextEqualsOptions, TextIn, TextIndentDefinition, TextIndentPluginState, type TextInsertFragmentOptions, type TextInsertTextOptions, TextInterface, type TextMutationMethods, TextOf, type TextRemoveTextOptions, TextSelection, type TextStaticProps, TextSubstitutionInputRuleConfig, TextSubstitutionMatch, TextSubstitutionPattern, type TextUnit, type TextUnitAdjustment, type TextWith, type ToggleBlockCommand, ToggleHeadingOptions, ToggleListOptions, type ToggleMarkCommand, type TopLevelRuntimeRange, TrailingBlockDefinition, TrailingBlockPlugin, TrailingBlockPluginState, type TransactionSpec, type TransferAdoptInput, type TransferApi, type TransferCheck, type TransferDefinition, type TransferDiagnostic, type TransferEdge, type TransferInput, type TransferIntent, type TransferLandingInput, type TransferLandingTarget, type TransferOutcome, type TransferPatch, type TransferPatchProperties, type TransferPayload, TransferPlugin, type TransferRead, type TransferRefusalReason, type TransferRelation, type TransferSide, type TransferSideInput, type TransferSourceInput, type TransferTarget, type TransferVeto, type TransferVetoInput, type TransferWrap, TransformInputRuleContext, type TransformOptions, type TxDeclaredMethod, type TxMethodDeclarations, type TxOnlyMethod, UnderlineRules, type UnknownObject, UnwrapLinkOptions, UpsertLinkOptions, type Value, type ValueOf, type WithAnyName, type WithRequiredName, WrapLinkOptions, applyDeepToNodes, authoredVeto, compileEditorSchemaContract, createBlockFenceInputRule, createBlockStartInputRule, createEditor, createEditorView, createHotkey, createMarkInputRule, createTextSubstitutionInputRule, decodeEditorEffect, defaultsDeepToNodes, defineCommand$1 as defineCommand, defineEditorSchema, defineEffect, defineInputRule, definePlugin, definePluginPoint, definePluginSlot, defineStateField, defineUpdateAnnotation, diffEditorSchemaContracts, documentReplacement, editorCommands, editorReads, encodeEditorEffect, formatting, getEditorRuntimeOwner, getFragmentProp, getInjectMatch, getLinkHref, getPluginNodeClass, inputRuleVeto, invertEffect, isDefined, isEditor, isHotkey, isNominalPluginDescriptor, isOrderedList, isPluginElementClass, isPluginNodeClass, isUrl, locateAt, mapEffect, matchBlockStart, matchDelimitedInline, mergeDeepToNodes, nanoid, nodeWriteVeto, property, readEditorSchemaContract, getSelection as readEditorSelection, restoreEditorSchemaContract, schema$1 as schema, screenReaderAnnouncementEffect, serializePlainText, setDebugValueScrubber, setEditorReadOnly, setEditorViewing, target, transfer, transferVeto, txLocate, txOnly, txSelection, valueCodecs };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { getStroke, getStrokeOutlinePoints, getStrokePoints } from "perfect-freehand";
|
|
2
|
-
//#region src/
|
|
2
|
+
//#region src/internal/penStroke.internal.ts
|
|
3
3
|
const RATE_OF_PRESSURE_CHANGE = .275;
|
|
4
4
|
const round = (value) => Math.round(value * 100) / 100;
|
|
5
5
|
const curvedPathOf = (outline) => {
|
|
@@ -35,132 +35,114 @@ const OverridePlugin = definePlugin("override", {}).extend(({ editor }) => {
|
|
|
35
35
|
};
|
|
36
36
|
const shouldRemoveEmptyMergeTarget = (node, path) => resolveStructuralRule("merge.removeEmpty", node, path) === true;
|
|
37
37
|
return {
|
|
38
|
-
commands: ({ around, handle }) => [
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
const isAtStart = state.selection.isAtBlockStart();
|
|
92
|
-
const result = next();
|
|
93
|
-
if (result === false) return false;
|
|
94
|
-
return state.transaction.extend(result, (tx) => {
|
|
95
|
-
tx.blocks.reset({ at: isAtStart ? blockPath : PathApi.next(blockPath) });
|
|
96
|
-
});
|
|
97
|
-
}
|
|
98
|
-
return next();
|
|
99
|
-
}),
|
|
100
|
-
around(editorCommands.delete, ({ state, next }) => {
|
|
101
|
-
const selection = state.selection();
|
|
102
|
-
if (!selection || !state.selection.isCollapsed()) return next();
|
|
103
|
-
const block = state.nodes.block({ at: selection.focus });
|
|
104
|
-
if (!block) return next();
|
|
105
|
-
const [blockNode, blockPath] = block;
|
|
106
|
-
if (resolveStructuralRule("delete.empty", blockNode, blockPath) !== "reset") return next();
|
|
38
|
+
commands: ({ around, handle }) => [around(editorCommands.insertBreak, ({ next, state }) => {
|
|
39
|
+
const selection = state.selection();
|
|
40
|
+
const block = selection ? state.nodes.block({ at: selection.focus }) : void 0;
|
|
41
|
+
if (!selection || !block) return next();
|
|
42
|
+
const [blockNode, blockPath] = block;
|
|
43
|
+
const runAction = (action) => {
|
|
44
|
+
if (!action || ![
|
|
45
|
+
"none",
|
|
46
|
+
"reset",
|
|
47
|
+
"lineBreak",
|
|
48
|
+
"lift",
|
|
49
|
+
"exit",
|
|
50
|
+
"deleteExit"
|
|
51
|
+
].includes(action) || action === "lift" && blockPath.length === 0) return null;
|
|
52
|
+
if ((action === "exit" || action === "deleteExit") && !state.selection.isCollapsed()) return null;
|
|
53
|
+
let exitRefused = false;
|
|
54
|
+
let resetRefused = false;
|
|
55
|
+
const transaction = state.transaction((tx) => {
|
|
56
|
+
if (action === "none") return;
|
|
57
|
+
if (action === "reset") {
|
|
58
|
+
resetRefused = !tx.blocks.reset({ at: blockPath });
|
|
59
|
+
return;
|
|
60
|
+
}
|
|
61
|
+
if (action === "lineBreak") {
|
|
62
|
+
tx.break.insertSoft();
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
if (action === "lift") {
|
|
66
|
+
tx.nodes.lift({ at: blockPath });
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
if (action === "deleteExit") tx.text.deleteBackward({ unit: "character" });
|
|
70
|
+
exitRefused = !tx.break.exit();
|
|
71
|
+
});
|
|
72
|
+
if (resetRefused) return null;
|
|
73
|
+
return exitRefused ? false : transaction;
|
|
74
|
+
};
|
|
75
|
+
if (state.selection.isCollapsed() && state.nodes.isEmpty(blockNode)) {
|
|
76
|
+
const action = runAction(resolveStructuralRule("break.empty", blockNode, blockPath));
|
|
77
|
+
if (action !== null) return action;
|
|
78
|
+
}
|
|
79
|
+
if (state.selection.isCollapsed() && !state.nodes.isEmpty(blockNode) && state.points.isEnd(selection.anchor, blockPath) && (() => {
|
|
80
|
+
const before = state.points.before(selection, { unit: "character" });
|
|
81
|
+
const range = before ? state.ranges.get(before, selection) : void 0;
|
|
82
|
+
return range ? state.text.string(range) : "";
|
|
83
|
+
})() === "\n") {
|
|
84
|
+
const action = runAction(resolveStructuralRule("break.emptyLineEnd", blockNode, blockPath));
|
|
85
|
+
if (action !== null) return action;
|
|
86
|
+
}
|
|
87
|
+
const defaultAction = runAction(resolveStructuralRule("break.default", blockNode, blockPath));
|
|
88
|
+
if (defaultAction !== null) return defaultAction;
|
|
89
|
+
if (resolveStructuralRule("break.splitReset", blockNode, blockPath) === true && !state.selection.isAcrossBlocks()) {
|
|
90
|
+
const isAtStart = state.selection.isAtBlockStart();
|
|
107
91
|
const result = next();
|
|
108
92
|
if (result === false) return false;
|
|
109
93
|
return state.transaction.extend(result, (tx) => {
|
|
110
|
-
|
|
111
|
-
const nextBlock = nextSelection ? tx.nodes.block({ at: nextSelection.focus }) : void 0;
|
|
112
|
-
if (nextBlock && PathApi.equals(nextBlock[1], blockPath) && tx.nodes.isEmpty(nextBlock[0])) tx.blocks.reset({ at: blockPath });
|
|
94
|
+
tx.blocks.reset({ at: isAtStart ? blockPath : PathApi.next(blockPath) });
|
|
113
95
|
});
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
});
|
|
124
|
-
};
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
96
|
+
}
|
|
97
|
+
return next();
|
|
98
|
+
}), handle(editorCommands.delete, ({ input, state }) => {
|
|
99
|
+
const selectAdjacentBlockVoid = (adjacent, current) => {
|
|
100
|
+
if (!adjacent || !ElementApi.isElement(adjacent[0]) || !state.schema.isVoid(adjacent[0])) return null;
|
|
101
|
+
const start = state.points.start(adjacent[1]);
|
|
102
|
+
if (!start) return null;
|
|
103
|
+
return state.transaction((tx) => {
|
|
104
|
+
tx.selection.set(start);
|
|
105
|
+
if (tx.nodes.isEmpty(current[0])) tx.nodes.remove({ at: current[1] });
|
|
106
|
+
});
|
|
107
|
+
};
|
|
108
|
+
const runDeleteAction = (action, blockPath) => {
|
|
109
|
+
if (action !== "reset" && !(action === "lift" && blockPath.length > 0)) return null;
|
|
110
|
+
let applied = true;
|
|
111
|
+
const transaction = state.transaction((tx) => {
|
|
112
|
+
if (action === "reset") applied = tx.blocks.reset({ at: blockPath });
|
|
113
|
+
else tx.nodes.lift({ at: blockPath });
|
|
114
|
+
});
|
|
115
|
+
return applied ? transaction : null;
|
|
116
|
+
};
|
|
117
|
+
const selection = state.selection();
|
|
118
|
+
if (!selection || !state.selection.isCollapsed()) return false;
|
|
119
|
+
const block = state.nodes.block({ at: selection.focus });
|
|
120
|
+
if (input.direction === "forward") {
|
|
121
|
+
if (block && state.points.isEnd(selection.anchor, block[1])) {
|
|
122
|
+
const transaction = selectAdjacentBlockVoid(state.nodes.next({ at: block[1] }), block);
|
|
123
|
+
if (transaction) return transaction;
|
|
124
|
+
}
|
|
125
|
+
return false;
|
|
126
|
+
}
|
|
127
|
+
if (block) {
|
|
128
|
+
const [blockNode, blockPath] = block;
|
|
129
|
+
if (state.points.isStart(selection.anchor, blockPath)) {
|
|
130
|
+
const previous = state.nodes.previous({ at: blockPath });
|
|
131
|
+
if (previous && ElementApi.isElement(previous[0]) && !state.schema.isVoid(previous[0]) && !state.schema.isIsolating(previous[0]) && previous[0].children.length > 0 && NodeApi.string(previous[0]).length === 0 && (!shouldRemoveEmptyMergeTarget(previous[0], previous[1]) || state.nodes.isEmpty(previous[0]) && !shouldMergeNodesRemovePrevNode(editor, previous, block))) return state.transaction((tx) => {
|
|
132
|
+
tx.nodes.merge({ at: blockPath });
|
|
131
133
|
});
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
const block = state.nodes.block({ at: selection.focus });
|
|
137
|
-
if (input.direction === "forward") {
|
|
138
|
-
if (block && state.points.isEnd(selection.anchor, block[1])) {
|
|
139
|
-
const transaction = selectAdjacentBlockVoid(state.nodes.next({ at: block[1] }), block);
|
|
140
|
-
if (transaction) return transaction;
|
|
141
|
-
}
|
|
142
|
-
return false;
|
|
134
|
+
const selectAdjacent = selectAdjacentBlockVoid(previous, [blockNode, blockPath]);
|
|
135
|
+
if (selectAdjacent) return selectAdjacent;
|
|
136
|
+
const ruleTransaction = runDeleteAction(resolveStructuralRule("delete.start", blockNode, blockPath), blockPath);
|
|
137
|
+
if (ruleTransaction) return ruleTransaction;
|
|
143
138
|
}
|
|
144
|
-
if (
|
|
145
|
-
const
|
|
146
|
-
if (
|
|
147
|
-
const previous = state.nodes.previous({ at: blockPath });
|
|
148
|
-
if (previous && ElementApi.isElement(previous[0]) && !state.schema.isVoid(previous[0]) && !state.schema.isIsolating(previous[0]) && previous[0].children.length > 0 && NodeApi.string(previous[0]).length === 0 && (!shouldRemoveEmptyMergeTarget(previous[0], previous[1]) || state.nodes.isEmpty(previous[0]) && !shouldMergeNodesRemovePrevNode(editor, previous, block))) return state.transaction((tx) => {
|
|
149
|
-
tx.nodes.merge({ at: blockPath });
|
|
150
|
-
});
|
|
151
|
-
const selectAdjacent = selectAdjacentBlockVoid(previous, [blockNode, blockPath]);
|
|
152
|
-
if (selectAdjacent) return selectAdjacent;
|
|
153
|
-
const ruleTransaction = runDeleteAction(resolveStructuralRule("delete.start", blockNode, blockPath), blockPath);
|
|
154
|
-
if (ruleTransaction) return ruleTransaction;
|
|
155
|
-
}
|
|
156
|
-
if (ElementApi.isElement(blockNode) && state.nodes.isEmpty(blockNode)) {
|
|
157
|
-
const ruleTransaction = runDeleteAction(resolveStructuralRule("delete.empty", blockNode, blockPath), blockPath);
|
|
158
|
-
if (ruleTransaction) return ruleTransaction;
|
|
159
|
-
}
|
|
139
|
+
if (ElementApi.isElement(blockNode) && state.nodes.isEmpty(blockNode)) {
|
|
140
|
+
const ruleTransaction = runDeleteAction(resolveStructuralRule("delete.empty", blockNode, blockPath), blockPath);
|
|
141
|
+
if (ruleTransaction) return ruleTransaction;
|
|
160
142
|
}
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
],
|
|
143
|
+
}
|
|
144
|
+
return false;
|
|
145
|
+
})],
|
|
164
146
|
readMiddleware: ({ around }) => [around(editorReads.nodes.shouldMergeNodesRemovePrevNode, ({ input: { current, previous }, next, state }) => {
|
|
165
147
|
const [previousNode, previousPath] = previous;
|
|
166
148
|
const [, currentPath] = current;
|