@portone/docx-editor 0.6.8 → 0.6.9
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/CHANGELOG.md +8 -0
- package/CONTRIBUTING.md +2 -2
- package/dist/DocxEditor.d.ts +9 -9
- package/dist/core.d.ts +27 -27
- package/dist/docx/commentOnlyChange.d.ts +3 -3
- package/dist/docx/comments/durable.d.ts +4 -4
- package/dist/docx/comments/grammar.d.ts +2 -2
- package/dist/docx/comments/model.d.ts +1 -1
- package/dist/docx/comments/parts.d.ts +6 -6
- package/dist/docx/comments/people.d.ts +4 -4
- package/dist/docx/comments/policy.d.ts +1 -1
- package/dist/docx/comments/reading.d.ts +1 -1
- package/dist/docx/comments/writing.d.ts +3 -3
- package/dist/docx/comments.d.ts +3 -3
- package/dist/docx/compareDocx.d.ts +3 -3
- package/dist/docx/exportDocx.d.ts +4 -4
- package/dist/docx/exportRefs.d.ts +4 -4
- package/dist/docx/formatting/attrs.d.ts +8 -8
- package/dist/docx/formatting/context.d.ts +6 -6
- package/dist/docx/formatting/direct.d.ts +3 -3
- package/dist/docx/formatting/resolve.d.ts +5 -5
- package/dist/docx/formatting/runProperties.d.ts +3 -3
- package/dist/docx/formatting/styles.d.ts +5 -5
- package/dist/docx/formatting/tabStops.d.ts +2 -2
- package/dist/docx/formatting.d.ts +7 -7
- package/dist/docx/headersFooters.d.ts +6 -6
- package/dist/docx/hyperlink.d.ts +1 -1
- package/dist/docx/identities.d.ts +1 -1
- package/dist/docx/importDocx.d.ts +3 -3
- package/dist/docx/importParagraph.d.ts +4 -4
- package/dist/docx/importPolicy.d.ts +1 -1
- package/dist/docx/importPreserved.d.ts +1 -1
- package/dist/docx/importTable.d.ts +2 -2
- package/dist/docx/invariants.d.ts +4 -4
- package/dist/docx/media.d.ts +2 -2
- package/dist/docx/newLists.d.ts +2 -2
- package/dist/docx/notes/newNote.d.ts +3 -3
- package/dist/docx/notes/numbering.d.ts +2 -2
- package/dist/docx/notes/reading.d.ts +3 -3
- package/dist/docx/notes/references.d.ts +1 -1
- package/dist/docx/notes/writing.d.ts +2 -2
- package/dist/docx/numberingPlanner.d.ts +2 -2
- package/dist/docx/paraProps.d.ts +2 -2
- package/dist/docx/partPlan.d.ts +4 -4
- package/dist/docx/partPlanners.d.ts +2 -2
- package/dist/docx/protectionPolicy.d.ts +5 -5
- package/dist/docx/runProps.d.ts +4 -4
- package/dist/docx/scan.d.ts +1 -1
- package/dist/docx/sdt.d.ts +1 -1
- package/dist/docx/sections.d.ts +2 -2
- package/dist/docx/serializeBlock.d.ts +1 -1
- package/dist/docx/serializeParagraph.d.ts +1 -1
- package/dist/docx/serializePreserved.d.ts +3 -3
- package/dist/docx/serializeSdtBlock.d.ts +1 -1
- package/dist/docx/serializeStory.d.ts +2 -2
- package/dist/docx/serializeTable.d.ts +2 -2
- package/dist/docx/session.d.ts +9 -9
- package/dist/docx/story.d.ts +6 -6
- package/dist/docx/storyParts.d.ts +7 -7
- package/dist/docx/storyProjection.d.ts +1 -1
- package/dist/docx/tableFormatting/conditions.d.ts +2 -2
- package/dist/docx/tableFormatting/editing.d.ts +2 -2
- package/dist/docx/tableFormatting/reading.d.ts +5 -5
- package/dist/docx/tableFormatting.d.ts +3 -3
- package/dist/docx/tableTemplate.d.ts +2 -2
- package/dist/docx/wrappers.d.ts +2 -2
- package/dist/download.d.ts +2 -2
- package/dist/editor/clipboard/blockReaders.d.ts +3 -3
- package/dist/editor/clipboard/htmlReader.d.ts +4 -4
- package/dist/editor/clipboard/images.d.ts +1 -1
- package/dist/editor/clipboard/internalChannel.d.ts +3 -3
- package/dist/editor/clipboard/normalizers.d.ts +4 -4
- package/dist/editor/clipboard/parser.d.ts +2 -2
- package/dist/editor/clipboard/plugin.d.ts +2 -2
- package/dist/editor/clipboard/readContext.d.ts +4 -4
- package/dist/editor/clipboard/readers.d.ts +2 -2
- package/dist/editor/commands/commentCommands.d.ts +3 -3
- package/dist/editor/commands/comments/editing.d.ts +1 -1
- package/dist/editor/commands/comments/model.d.ts +1 -1
- package/dist/editor/commands/comments/reading.d.ts +1 -1
- package/dist/editor/commands/exportQueries.d.ts +2 -2
- package/dist/editor/commands/fidelityQueries.d.ts +2 -2
- package/dist/editor/commands/formatting/propertyCommands.d.ts +1 -1
- package/dist/editor/commands/formatting/reading.d.ts +2 -2
- package/dist/editor/commands/formatting/shared.d.ts +1 -1
- package/dist/editor/commands/formattingCommands.d.ts +2 -2
- package/dist/editor/commands/index.d.ts +39 -39
- package/dist/editor/commands/listCommands.d.ts +4 -4
- package/dist/editor/commands/noteCommands.d.ts +1 -1
- package/dist/editor/commands/noteQueries.d.ts +3 -3
- package/dist/editor/commands/paragraphCommands.d.ts +1 -1
- package/dist/editor/commands/spacingCommands.d.ts +1 -1
- package/dist/editor/createEditor.d.ts +6 -6
- package/dist/editor/documentStyles.d.ts +3 -3
- package/dist/editor/editorDocument.d.ts +6 -6
- package/dist/editor/formatSource.d.ts +1 -1
- package/dist/editor/imageFiles.d.ts +2 -2
- package/dist/editor/insertImage.d.ts +1 -1
- package/dist/editor/notes/noteSurface.d.ts +4 -4
- package/dist/editor/paragraphEdits.d.ts +2 -2
- package/dist/editor/paragraphPlacement.d.ts +1 -1
- package/dist/editor/plugins/commentComposer.d.ts +1 -1
- package/dist/editor/plugins/commentDecorations.d.ts +2 -2
- package/dist/editor/plugins/displayDerivation.d.ts +2 -2
- package/dist/editor/plugins/documentProtection.d.ts +2 -2
- package/dist/editor/plugins/keymap.d.ts +1 -1
- package/dist/editor/plugins/noteLifecycle.d.ts +1 -1
- package/dist/editor/plugins/noteNavigation.d.ts +1 -1
- package/dist/editor/plugins/noteNumbering.d.ts +1 -1
- package/dist/editor/plugins/numberingDecorations.d.ts +2 -2
- package/dist/editor/plugins/paragraphDisplay.d.ts +1 -1
- package/dist/editor/plugins/tabLayout.d.ts +1 -1
- package/dist/editor/plugins/tableDisplay.d.ts +1 -1
- package/dist/editor/stories/storyMarkup.d.ts +1 -1
- package/dist/editor/stories/storyState.d.ts +4 -4
- package/dist/editor/stories/storyView.d.ts +4 -4
- package/dist/editor/views/runMarkView.d.ts +1 -1
- package/dist/index.d.ts +26 -26
- package/dist/model/format.d.ts +1 -1
- package/dist/numbering/listRegistry.d.ts +1 -1
- package/dist/numbering/listTemplate.d.ts +1 -1
- package/dist/numbering/markers.d.ts +2 -2
- package/dist/numbering/parseNumbering.d.ts +5 -5
- package/dist/numbering/writeNumbering.d.ts +1 -1
- package/dist/ooxml/element.d.ts +1 -1
- package/dist/ooxml/partSplice.d.ts +2 -2
- package/dist/ooxml/precedence.d.ts +1 -1
- package/dist/ooxml/props.d.ts +1 -1
- package/dist/ooxml/simpleTypes.d.ts +1 -1
- package/dist/ooxml/tabStops.d.ts +1 -1
- package/dist/ooxml/tagScan.d.ts +1 -1
- package/dist/ooxml/units.d.ts +2 -2
- package/dist/ooxml/xml.d.ts +1 -1
- package/dist/page/PageGuides.d.ts +2 -2
- package/dist/page/blockKinds.d.ts +1 -1
- package/dist/page/demands/footnoteDemands.d.ts +1 -1
- package/dist/page/demands/index.d.ts +1 -1
- package/dist/page/kinds/index.d.ts +1 -1
- package/dist/page/kinds/paragraphKind.d.ts +1 -1
- package/dist/page/kinds/sdtBlockKind.d.ts +1 -1
- package/dist/page/kinds/tableKind.d.ts +1 -1
- package/dist/page/measureBlocks.d.ts +1 -1
- package/dist/page/pageDecorations.d.ts +3 -3
- package/dist/page/pageLayout.d.ts +4 -4
- package/dist/page/usePageLayout.d.ts +2 -2
- package/dist/schema/clipboard.d.ts +1 -1
- package/dist/schema/controlEdges.d.ts +1 -1
- package/dist/schema/displayDerivation.d.ts +1 -1
- package/dist/schema/docxSchema.d.ts +1 -1
- package/dist/schema/guards.d.ts +4 -4
- package/dist/schema/index.d.ts +5 -5
- package/dist/schema/locks.d.ts +1 -1
- package/dist/schema/preservedGuards.d.ts +1 -1
- package/dist/schema/protectionState.d.ts +1 -1
- package/dist/schema/rendering.d.ts +1 -1
- package/dist/styles/inlineStyle.d.ts +3 -3
- package/dist/styles/lineSpacings.d.ts +1 -1
- package/dist/table/cellBorders.d.ts +1 -1
- package/dist/table/cellFormatting.d.ts +3 -3
- package/dist/table/format.d.ts +1 -1
- package/dist/table/gridBorders.d.ts +2 -2
- package/dist/table/index.d.ts +5 -5
- package/dist/table/resize.d.ts +1 -1
- package/dist/table/widths.d.ts +1 -1
- package/dist/ui/AlignMenu.d.ts +2 -2
- package/dist/ui/CellStyleGroup.d.ts +3 -3
- package/dist/ui/ColorPicker.d.ts +1 -1
- package/dist/ui/CommentsPanel.d.ts +1 -1
- package/dist/ui/FontFamilySelect.d.ts +3 -3
- package/dist/ui/FontSizeSelect.d.ts +2 -2
- package/dist/ui/LinkCard.d.ts +1 -1
- package/dist/ui/ParagraphStyleSelect.d.ts +3 -3
- package/dist/ui/SpacingMenu.d.ts +2 -2
- package/dist/ui/TableMenu.d.ts +2 -2
- package/dist/ui/TableSizePicker.d.ts +1 -1
- package/dist/ui/TextMenu.d.ts +2 -2
- package/dist/ui/Toolbar.d.ts +4 -4
- package/dist/ui/ZoomSelect.d.ts +1 -1
- package/dist/ui/comments/CommentComposer.d.ts +1 -1
- package/dist/ui/comments/useCommentRailLayout.d.ts +1 -1
- package/dist/ui/noteItems.d.ts +1 -1
- package/dist/ui/notes/NoteAreas.d.ts +5 -5
- package/dist/ui/notes/NoteList.d.ts +3 -3
- package/dist/ui/notes/StoryRow.d.ts +5 -5
- package/dist/ui/notes/noteBands.d.ts +7 -7
- package/dist/ui/notes/noteHeights.d.ts +2 -2
- package/dist/ui/notes/useStorySurface.d.ts +5 -5
- package/dist/ui/presets.d.ts +3 -3
- package/package.json +5 -3
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
* A pure computation that never touches the document model: the same paragraphs with the
|
|
5
5
|
* same numbering definitions always yield the same numbers.
|
|
6
6
|
*/
|
|
7
|
-
import type { NumberingRef, RunFormat } from "../model/format";
|
|
8
|
-
import { type LevelAlign, type LevelIndentPt, type LevelSuffix, type Numbering } from "./parseNumbering";
|
|
7
|
+
import type { NumberingRef, RunFormat } from "../model/format.js";
|
|
8
|
+
import { type LevelAlign, type LevelIndentPt, type LevelSuffix, type Numbering } from "./parseNumbering.js";
|
|
9
9
|
/** The number to draw in front of one paragraph */
|
|
10
10
|
export interface ListMarker {
|
|
11
11
|
/**
|
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
* numbering.xml itself goes out as the original bytes on export, so this reading never
|
|
6
6
|
* disturbs the file.
|
|
7
7
|
*/
|
|
8
|
-
import type { RunFormat } from "../model/format";
|
|
9
|
-
import type { TabStopDirective } from "../model/tabStops";
|
|
10
|
-
import { type XmlParser } from "../ooxml/xml";
|
|
11
|
-
import { type NumberFormat } from "./spellers";
|
|
12
|
-
export type { NumberFormat } from "./spellers";
|
|
8
|
+
import type { RunFormat } from "../model/format.js";
|
|
9
|
+
import type { TabStopDirective } from "../model/tabStops.js";
|
|
10
|
+
import { type XmlParser } from "../ooxml/xml.js";
|
|
11
|
+
import { type NumberFormat } from "./spellers.js";
|
|
12
|
+
export type { NumberFormat } from "./spellers.js";
|
|
13
13
|
/**
|
|
14
14
|
* The indent a level defines. The unit is twips (1/20 of a point), and a slot that is
|
|
15
15
|
* not recorded is null
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* OOXML requires the definitions (`abstractNum`) to come before the numbers (`num`), and
|
|
7
7
|
* `CHILD_ORDER.numbering` is what places each where it belongs among what the part holds.
|
|
8
8
|
*/
|
|
9
|
-
import type { NewList } from "./parseNumbering";
|
|
9
|
+
import type { NewList } from "./parseNumbering.js";
|
|
10
10
|
/**
|
|
11
11
|
* numbering.xml with the definition each of these lists was started with added under its number.
|
|
12
12
|
* When there is nothing to add, the original string is returned unchanged.
|
package/dist/ooxml/element.d.ts
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* formatting value nor written over when it happens to share the local name (`x:val` beside
|
|
13
13
|
* `w:val`). The two readers below are named for which of those they answer.
|
|
14
14
|
*/
|
|
15
|
-
import { type KnownPrefix } from "./names";
|
|
15
|
+
import { type KnownPrefix } from "./names.js";
|
|
16
16
|
/** One attribute as it is written: the whole name, prefix included, and the value before escaping */
|
|
17
17
|
export type XmlAttr = readonly [name: string, value: string];
|
|
18
18
|
/** `a="b" c="d"`. Empty for no attributes, so an opening tag needs no separator of its own */
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
* comment for the end of the part, and miss the root altogether when it is written under a
|
|
9
9
|
* prefix or closes on itself.
|
|
10
10
|
*/
|
|
11
|
-
import { type XmlAttr } from "./element";
|
|
12
|
-
import { type KnownPrefix } from "./names";
|
|
11
|
+
import { type XmlAttr } from "./element.js";
|
|
12
|
+
import { type KnownPrefix } from "./names.js";
|
|
13
13
|
/** One child to put into a part, named by the local part of its tag so the child order can place it */
|
|
14
14
|
export interface PartChild {
|
|
15
15
|
name: string;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* neither is enough on its own: `color` is an attribute of `w:shd` but an element of its own whose
|
|
11
11
|
* value sits in `w:val`, and `left` is an attribute of `w:ind` but an element of `w:tcMar`.
|
|
12
12
|
*/
|
|
13
|
-
import { type XmlAttr } from "./element";
|
|
13
|
+
import { type XmlAttr } from "./element.js";
|
|
14
14
|
/**
|
|
15
15
|
* The attributes that override the named one when both are there, so writing the named one drops
|
|
16
16
|
* them (§17.3.1.12 ind, §17.3.2.26 rFonts, §17.3.2.6 color, §17.3.5 shd, §17.3.1.33 spacing).
|
package/dist/ooxml/props.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* rest (borders, shading, margins) stays as the original text wrote it. OOXML lays down the order
|
|
6
6
|
* of the children, so the spot to insert a child that was not there is found by that same order.
|
|
7
7
|
*/
|
|
8
|
-
import { type XmlAttr } from "./element";
|
|
8
|
+
import { type XmlAttr } from "./element.js";
|
|
9
9
|
export interface PropsChild {
|
|
10
10
|
/** The name with its namespace prefix stripped off (e.g. `gridSpan`) */
|
|
11
11
|
name: string;
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* Readers accept the decimal counts some producers write in integer slots. `format` answers null
|
|
12
12
|
* for a value it cannot record; a caller that intends to round must do so before formatting.
|
|
13
13
|
*/
|
|
14
|
-
import { type TabAlignment, type TabLeader } from "../model/tabStops";
|
|
14
|
+
import { type TabAlignment, type TabLeader } from "../model/tabStops.js";
|
|
15
15
|
export interface SimpleType<T> {
|
|
16
16
|
/** null for an absent or unreadable value; see the type's producer compatibility rules */
|
|
17
17
|
parse(value: string | null): T | null;
|
package/dist/ooxml/tabStops.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { TabStopDirective } from "../model/tabStops";
|
|
1
|
+
import type { TabStopDirective } from "../model/tabStops.js";
|
|
2
2
|
/** Reads one `w:tabs` property without resolving the paragraph-property hierarchy. */
|
|
3
3
|
export declare function readTabStopDirectives(pPr: Element | null): TabStopDirective[];
|
package/dist/ooxml/tagScan.d.ts
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* inside an attribute value and a `<` inside a comment, which is why a tag is read construct by
|
|
7
7
|
* construct rather than searched for.
|
|
8
8
|
*/
|
|
9
|
-
import type { XmlAttr } from "./element";
|
|
9
|
+
import type { XmlAttr } from "./element.js";
|
|
10
10
|
export type TagKind = "open" | "close" | "empty" | "other";
|
|
11
11
|
export interface Tag {
|
|
12
12
|
kind: TagKind;
|
package/dist/ooxml/units.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type ParagraphAlign } from "../model/format";
|
|
2
|
-
import { type HexColor } from "./simpleTypes";
|
|
1
|
+
import { type ParagraphAlign } from "../model/format.js";
|
|
2
|
+
import { type HexColor } from "./simpleTypes.js";
|
|
3
3
|
/** The alignment `w:jc` writes down, both for a paragraph and for a table */
|
|
4
4
|
export declare const ALIGN_BY_JC: Record<string, ParagraphAlign>;
|
|
5
5
|
/** A color as the document writes it, six hex digits and no `#`. Null for anything else */
|
package/dist/ooxml/xml.d.ts
CHANGED
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
* headers section by section (`docx/headersFooters`).
|
|
12
12
|
*/
|
|
13
13
|
import type { ReactElement } from "react";
|
|
14
|
-
import { type HeadersFooters } from "../docx/headersFooters";
|
|
15
|
-
import type { PageFace, PageOverlay } from "./usePageLayout";
|
|
14
|
+
import { type HeadersFooters } from "../docx/headersFooters.js";
|
|
15
|
+
import type { PageFace, PageOverlay } from "./usePageLayout.js";
|
|
16
16
|
export declare function PageGuides({ overlay, headersFootersFor, }: {
|
|
17
17
|
overlay: PageOverlay;
|
|
18
18
|
/** The stories the section this page belongs to shows. Left out while no document is open */
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import type { Node as PMNode } from "prosemirror-model";
|
|
12
12
|
import type { Decoration, EditorView } from "prosemirror-view";
|
|
13
|
-
import type { PageDemand } from "./demands";
|
|
13
|
+
import type { PageDemand } from "./demands/index.js";
|
|
14
14
|
/** A place inside a block where the next page may, or must, start */
|
|
15
15
|
export interface BreakCandidate {
|
|
16
16
|
/**
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* did not touch is the same node afterwards, so a pass reads nothing off the page for a block with
|
|
8
8
|
* no reference and walks only the blocks an edit rebuilt.
|
|
9
9
|
*/
|
|
10
|
-
import type { DemandSource } from "./index";
|
|
10
|
+
import type { DemandSource } from "./index.js";
|
|
11
11
|
/** The band footnotes are kept in, which the layout's caller hands the heights of */
|
|
12
12
|
export declare const FOOTNOTE_BAND = "footnote";
|
|
13
13
|
/**
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* and every registered source is asked about every block whatever its kind. The layout
|
|
7
7
|
* (`page/pageLayout`) knows a demand by its band alone, never by what put it there.
|
|
8
8
|
*/
|
|
9
|
-
import type { MeasureTarget } from "../blockKinds";
|
|
9
|
+
import type { MeasureTarget } from "../blockKinds.js";
|
|
10
10
|
/** Room one place in a block asks the page it lands on to keep at the foot */
|
|
11
11
|
export interface PageDemand {
|
|
12
12
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { BlockKind } from "../blockKinds";
|
|
1
|
+
import type { BlockKind } from "../blockKinds.js";
|
|
2
2
|
/**
|
|
3
3
|
* The block shapes the editor pages, in the order they are asked. A new kind goes ahead of the
|
|
4
4
|
* kinds it is narrower than, and the last one claims every block none of the others did.
|
|
@@ -6,5 +6,5 @@
|
|
|
6
6
|
* anything is measured. A break standing where no space can be opened - inside a table cell,
|
|
7
7
|
* where it would grow the cell rather than the page - is answered by the whole block instead.
|
|
8
8
|
*/
|
|
9
|
-
import type { BlockKind } from "../blockKinds";
|
|
9
|
+
import type { BlockKind } from "../blockKinds.js";
|
|
10
10
|
export declare const paragraphKind: BlockKind;
|
|
@@ -10,5 +10,5 @@
|
|
|
10
10
|
* holds, so it runs down both pieces and closes under the last of them, and only the background a
|
|
11
11
|
* shut control paints has to be broken, which the space opened at the cut does.
|
|
12
12
|
*/
|
|
13
|
-
import { type BlockKind } from "../blockKinds";
|
|
13
|
+
import { type BlockKind } from "../blockKinds.js";
|
|
14
14
|
export declare const sdtBlockKind: BlockKind;
|
|
@@ -6,5 +6,5 @@
|
|
|
6
6
|
* drew as content: the measurement takes their heights back off, and the projection is derived
|
|
7
7
|
* again from the document, so an edit to a header row redraws it with nothing measured anew.
|
|
8
8
|
*/
|
|
9
|
-
import type { BlockKind } from "../blockKinds";
|
|
9
|
+
import type { BlockKind } from "../blockKinds.js";
|
|
10
10
|
export declare const tableKind: BlockKind;
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* Where there is no layout (in tests) everything is 0, so the result is a single page.
|
|
13
13
|
*/
|
|
14
14
|
import type { EditorView } from "prosemirror-view";
|
|
15
|
-
import { type MeasuredBlock } from "./blockKinds";
|
|
15
|
+
import { type MeasuredBlock } from "./blockKinds.js";
|
|
16
16
|
/**
|
|
17
17
|
* The measurements taken in order to draw the page overlay. Positions are relative to
|
|
18
18
|
* the overlay box
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import { type EditorState, Plugin } from "prosemirror-state";
|
|
12
12
|
import { DecorationSet, type EditorView } from "prosemirror-view";
|
|
13
|
-
import { type BlockKind, type PageCut } from "./blockKinds";
|
|
14
|
-
import { type DemandSource } from "./demands";
|
|
15
|
-
import type { BlockPush } from "./pageLayout";
|
|
13
|
+
import { type BlockKind, type PageCut } from "./blockKinds.js";
|
|
14
|
+
import { type DemandSource } from "./demands/index.js";
|
|
15
|
+
import type { BlockPush } from "./pageLayout.js";
|
|
16
16
|
/** Everything one measurement has to say about the page (`page/pageLayout`) */
|
|
17
17
|
export interface PageMarksInput {
|
|
18
18
|
pushes: readonly BlockPush[];
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
* first section's, so a section on wider paper is paginated on its own height but drawn on the
|
|
19
19
|
* paper the sheet holds.
|
|
20
20
|
*/
|
|
21
|
-
import { type PageGeometry } from "../docx/pageGeometry";
|
|
22
|
-
import type { DocumentSection, SectionProperties } from "../docx/sections";
|
|
23
|
-
import type { MeasuredBlock, PageCut } from "./blockKinds";
|
|
24
|
-
import type { DemandBand } from "./demands";
|
|
21
|
+
import { type PageGeometry } from "../docx/pageGeometry.js";
|
|
22
|
+
import type { DocumentSection, SectionProperties } from "../docx/sections.js";
|
|
23
|
+
import type { MeasuredBlock, PageCut } from "./blockKinds.js";
|
|
24
|
+
import type { DemandBand } from "./demands/index.js";
|
|
25
25
|
export type { MeasuredBlock };
|
|
26
26
|
/** The paper measured in the pixels the sheet is drawn with */
|
|
27
27
|
export interface PagePixels {
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import type { EditorView } from "prosemirror-view";
|
|
12
12
|
import { type RefObject } from "react";
|
|
13
|
-
import type { DemandBand } from "./demands";
|
|
14
|
-
import { type SectionPixels, type TrailingRows } from "./pageLayout";
|
|
13
|
+
import type { DemandBand } from "./demands/index.js";
|
|
14
|
+
import { type SectionPixels, type TrailingRows } from "./pageLayout.js";
|
|
15
15
|
/** One place where a page parts from the next. The position is measured on the sheet */
|
|
16
16
|
export interface PageMark {
|
|
17
17
|
page: number;
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* itself the same question at runtime.
|
|
14
14
|
*/
|
|
15
15
|
import { type DOMOutputSpec, DOMSerializer, type Mark, type Node as PMNode, type Schema, type Slice } from "prosemirror-model";
|
|
16
|
-
import { type docxSchema } from "./docxSchema";
|
|
16
|
+
import { type docxSchema } from "./docxSchema.js";
|
|
17
17
|
/**
|
|
18
18
|
* The paragraph style a copy carries, which is the one thing a paste needs that the drawing does
|
|
19
19
|
* not already say. It is the style's id alone, where the editor draws the whole `w:pPr`.
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* control away whole carries nothing across at all, and `./locks` answers that under the deletion
|
|
12
12
|
* clause.
|
|
13
13
|
*/
|
|
14
|
-
import type { StepGuard } from "./editGuard";
|
|
14
|
+
import type { StepGuard } from "./editGuard.js";
|
|
15
15
|
/**
|
|
16
16
|
* The edges of the document's block controls, as `./guards` registers them.
|
|
17
17
|
*
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
import { type Attrs, type MarkType, type Node as PMNode, type Schema } from "prosemirror-model";
|
|
27
27
|
import { PluginKey } from "prosemirror-state";
|
|
28
28
|
import { type Step, type Transform } from "prosemirror-transform";
|
|
29
|
-
import type { docxSchema } from "./docxSchema";
|
|
29
|
+
import type { docxSchema } from "./docxSchema.js";
|
|
30
30
|
/** The name of a node type of the document schema, which is what a deriver answers for by */
|
|
31
31
|
export type NodeName = typeof docxSchema extends Schema<infer Nodes, string> ? Nodes : never;
|
|
32
32
|
/** The display attrs one node should carry, by the position the node stands at in the document handed to the deriver */
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* checks coverage. The plugin guide defines the supported public surface.
|
|
13
13
|
*/
|
|
14
14
|
import { Schema } from "prosemirror-model";
|
|
15
|
-
export { imageNodeSpec, runMarkSpec } from "./rendering";
|
|
15
|
+
export { imageNodeSpec, runMarkSpec } from "./rendering.js";
|
|
16
16
|
/** Whether this is a page-splitting break (`<w:br w:type="page"/>`). Read straight from the original attribute text */
|
|
17
17
|
export declare function isPageBreak(brAttrs: unknown): boolean;
|
|
18
18
|
/**
|
package/dist/schema/guards.d.ts
CHANGED
|
@@ -22,10 +22,10 @@
|
|
|
22
22
|
* is open at all, which is a question about the editor rather than about an edit.
|
|
23
23
|
*/
|
|
24
24
|
import type { Command, EditorState, Selection, Transaction } from "prosemirror-state";
|
|
25
|
-
import { type EditGuard, type EditGuardName, type EditIntent } from "./editGuard";
|
|
26
|
-
import { type ProtectionState } from "./protection";
|
|
27
|
-
export type { EditGuard, EditGuardName, EditIntent } from "./editGuard";
|
|
28
|
-
export { stepReaches } from "./editGuard";
|
|
25
|
+
import { type EditGuard, type EditGuardName, type EditIntent } from "./editGuard.js";
|
|
26
|
+
import { type ProtectionState } from "./protection.js";
|
|
27
|
+
export type { EditGuard, EditGuardName, EditIntent } from "./editGuard.js";
|
|
28
|
+
export { stepReaches } from "./editGuard.js";
|
|
29
29
|
/**
|
|
30
30
|
* Whether the transaction reaches a comment node, which is how a body, a reply and a resolution
|
|
31
31
|
* change. Every comment lives in its three nodes, so a change that reaches none of them cannot
|
package/dist/schema/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export type { AttrClass } from "./attrRoles";
|
|
2
|
-
export { attrsOfClass } from "./attrRoles";
|
|
3
|
-
export type { PreservedDisplay } from "./docxSchema";
|
|
4
|
-
export { docxSchema, isPageBreak } from "./docxSchema";
|
|
5
|
-
export { imageNodeSpec, runMarkSpec } from "./rendering";
|
|
1
|
+
export type { AttrClass } from "./attrRoles.js";
|
|
2
|
+
export { attrsOfClass } from "./attrRoles.js";
|
|
3
|
+
export type { PreservedDisplay } from "./docxSchema.js";
|
|
4
|
+
export { docxSchema, isPageBreak } from "./docxSchema.js";
|
|
5
|
+
export { imageNodeSpec, runMarkSpec } from "./rendering.js";
|
package/dist/schema/locks.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import type { Mark, Node as PMNode } from "prosemirror-model";
|
|
12
12
|
import { PluginKey, type Selection } from "prosemirror-state";
|
|
13
|
-
import type { StepGuard } from "./editGuard";
|
|
13
|
+
import type { StepGuard } from "./editGuard.js";
|
|
14
14
|
/**
|
|
15
15
|
* The pass that lets a transaction through the guard, which is how a lock can be lifted at all.
|
|
16
16
|
* A plugin key is used as the name so that it cannot collide with a consumer's own metadata.
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* legitimately move from one paragraph to another, is held by its number instead.
|
|
12
12
|
*/
|
|
13
13
|
import type { Node as PMNode } from "prosemirror-model";
|
|
14
|
-
import { type ChangeGuard, type EditGuardName } from "./editGuard";
|
|
14
|
+
import { type ChangeGuard, type EditGuardName } from "./editGuard.js";
|
|
15
15
|
/** Everything about one preserved node that has to read the same after a change as before it */
|
|
16
16
|
type Signature = (node: PMNode) => string;
|
|
17
17
|
/**
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* entry.
|
|
5
5
|
*/
|
|
6
6
|
import { type EditorState, PluginKey } from "prosemirror-state";
|
|
7
|
-
import type { EditingProtection, ProtectionState } from "./protection";
|
|
7
|
+
import type { EditingProtection, ProtectionState } from "./protection.js";
|
|
8
8
|
/** What a state built without the protection plugin runs under, which is what every consumer had before it existed */
|
|
9
9
|
export declare const UNPROTECTED: ProtectionState;
|
|
10
10
|
export declare const protectionKey: PluginKey<ProtectionState>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Attrs, DOMOutputSpec } from "prosemirror-model";
|
|
2
|
-
import type { FontFallbacks } from "../styles/fontStack";
|
|
2
|
+
import type { FontFallbacks } from "../styles/fontStack.js";
|
|
3
3
|
/**
|
|
4
4
|
* What a run says to anyone reading it, the page and a copy of it alike.
|
|
5
5
|
*
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type CellFormat, type DocumentDefaults, type HighlightName, type LineSpacing, type ParagraphFormat, type RowFormat, type RunFormat, type TableFormat, type TableWidth } from "../model/format";
|
|
2
|
-
import { editorCssVariables } from "./classNames";
|
|
3
|
-
import { type FontFallbacks } from "./fontStack";
|
|
1
|
+
import { type CellFormat, type DocumentDefaults, type HighlightName, type LineSpacing, type ParagraphFormat, type RowFormat, type RunFormat, type TableFormat, type TableWidth } from "../model/format.js";
|
|
2
|
+
import { editorCssVariables } from "./classNames.js";
|
|
3
|
+
import { type FontFallbacks } from "./fontStack.js";
|
|
4
4
|
/**
|
|
5
5
|
* The value used on screen only, when nowhere in the document declares a default
|
|
6
6
|
* font size.
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Each carries the value `setLineSpacing` takes, so a menu of your own runs the same command
|
|
4
4
|
* off the same list.
|
|
5
5
|
*/
|
|
6
|
-
import type { LineSpacing } from "../model/format";
|
|
6
|
+
import type { LineSpacing } from "../model/format.js";
|
|
7
7
|
export interface LineSpacingOption {
|
|
8
8
|
label: string;
|
|
9
9
|
spacing: LineSpacing;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* A menu of your own takes the list from the root entry and hands the preset it picked to
|
|
4
4
|
* `setCellBorders`.
|
|
5
5
|
*/
|
|
6
|
-
import type { CellBorderPreset } from "./cellFormatting";
|
|
6
|
+
import type { CellBorderPreset } from "./cellFormatting.js";
|
|
7
7
|
export interface CellBorderOption {
|
|
8
8
|
/** What the row is called on screen */
|
|
9
9
|
label: string;
|
|
@@ -8,9 +8,9 @@
|
|
|
8
8
|
* convention, calling a command without `dispatch` only reports whether it would change something.
|
|
9
9
|
*/
|
|
10
10
|
import type { EditorState } from "prosemirror-state";
|
|
11
|
-
import { type CellSide } from "../docx/tableFormatting";
|
|
12
|
-
import { type CellVerticalAlign } from "../model/format";
|
|
13
|
-
import type { TableCommand } from "./commands";
|
|
11
|
+
import { type CellSide } from "../docx/tableFormatting.js";
|
|
12
|
+
import { type CellVerticalAlign } from "../model/format.js";
|
|
13
|
+
import type { TableCommand } from "./commands.js";
|
|
14
14
|
/**
|
|
15
15
|
* Which sides of the selected block a preset writes.
|
|
16
16
|
* `all` and `none` speak for every side of every selected cell, while `outer` writes only the sides
|
package/dist/table/format.d.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* paragraph an edit makes out of another paragraph.
|
|
8
8
|
*/
|
|
9
9
|
import type { Node as PMNode } from "prosemirror-model";
|
|
10
|
-
import type { GridRect } from "../docx/tableFormatting";
|
|
10
|
+
import type { GridRect } from "../docx/tableFormatting.js";
|
|
11
11
|
export type NodeAttrs = Record<string, unknown>;
|
|
12
12
|
export type { GridRect };
|
|
13
13
|
/** Only the parts of what `selectedRect()` returns that are actually used here */
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
* deriver that runs them after an edit is `editor/plugins/tableDisplay`.
|
|
16
16
|
*/
|
|
17
17
|
import type { Node as PMNode } from "prosemirror-model";
|
|
18
|
-
import { type CellDefaults, type TableCellSources } from "../docx/tableFormatting";
|
|
19
|
-
import type { NodeAttrs, TableGridMap } from "./format";
|
|
18
|
+
import { type CellDefaults, type TableCellSources } from "../docx/tableFormatting.js";
|
|
19
|
+
import type { NodeAttrs, TableGridMap } from "./format.js";
|
|
20
20
|
/**
|
|
21
21
|
* What this table lays down for its cells to draw.
|
|
22
22
|
* The values a table style laid down are not in the `tblPr`, so the table carries them separately.
|
package/dist/table/index.d.ts
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
* Everything here works on a table already in the document; putting a new one into the body is
|
|
10
10
|
* `insertTable` in `./commands`, which reads the page geometry the editor holds.
|
|
11
11
|
*/
|
|
12
|
-
export type { ActiveCellPadding, CellBorderPreset, MixedCellValue, } from "./cellFormatting";
|
|
13
|
-
export { activeCellBackground, activeCellBorderColor, activeCellPadding, activeCellVerticalAlign, canSetCellBorderColor, canSetCellFormatting, setCellBackground, setCellBorderColor, setCellBorders, setCellPadding, setCellVerticalAlign, } from "./cellFormatting";
|
|
14
|
-
export type { TableCommand } from "./commands";
|
|
15
|
-
export { addColumnAfter, addColumnBefore, addRowAfter, addRowBefore, deleteColumn, deleteRow, deleteTable, isInTable, mergeCells, splitCell, } from "./commands";
|
|
16
|
-
export { canMergeCells, canSplitCell } from "./merge";
|
|
12
|
+
export type { ActiveCellPadding, CellBorderPreset, MixedCellValue, } from "./cellFormatting.js";
|
|
13
|
+
export { activeCellBackground, activeCellBorderColor, activeCellPadding, activeCellVerticalAlign, canSetCellBorderColor, canSetCellFormatting, setCellBackground, setCellBorderColor, setCellBorders, setCellPadding, setCellVerticalAlign, } from "./cellFormatting.js";
|
|
14
|
+
export type { TableCommand } from "./commands.js";
|
|
15
|
+
export { addColumnAfter, addColumnBefore, addRowAfter, addRowBefore, deleteColumn, deleteRow, deleteTable, isInTable, mergeCells, splitCell, } from "./commands.js";
|
|
16
|
+
export { canMergeCells, canSplitCell } from "./merge.js";
|
package/dist/table/resize.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import type { Node as PMNode } from "prosemirror-model";
|
|
6
6
|
import type { EditorState, Transaction } from "prosemirror-state";
|
|
7
|
-
import { type PageGeometry } from "../docx/pageGeometry";
|
|
7
|
+
import { type PageGeometry } from "../docx/pageGeometry.js";
|
|
8
8
|
/**
|
|
9
9
|
* The floor a column can be narrowed to (dxa).
|
|
10
10
|
*
|
package/dist/table/widths.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import type { Node as PMNode } from "prosemirror-model";
|
|
7
7
|
import type { Transaction } from "prosemirror-state";
|
|
8
|
-
import { type TableWidth, type TableWidthType } from "../model/format";
|
|
8
|
+
import { type TableWidth, type TableWidthType } from "../model/format.js";
|
|
9
9
|
/**
|
|
10
10
|
* The grid column widths the table remembers, read from docx `w:gridCol`.
|
|
11
11
|
* An empty list means the grid is unknown, so it is treated the same as an absent one
|
package/dist/ui/AlignMenu.d.ts
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { type LucideIcon } from "lucide-react";
|
|
3
3
|
import type { EditorState } from "prosemirror-state";
|
|
4
4
|
import { type ReactElement } from "react";
|
|
5
|
-
import { type ActiveParagraphAlign } from "../editor/commands/paragraphCommands";
|
|
6
|
-
import type { RunCommand } from "./runCommand";
|
|
5
|
+
import { type ActiveParagraphAlign } from "../editor/commands/paragraphCommands.js";
|
|
6
|
+
import type { RunCommand } from "./runCommand.js";
|
|
7
7
|
/** Uses the left-align icon when the selection has no shared alignment. */
|
|
8
8
|
export declare function alignIcon(current: ActiveParagraphAlign): LucideIcon;
|
|
9
9
|
export interface AlignMenuProps {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/** Toolbar controls for formatting the current table cell selection. */
|
|
2
2
|
import type { EditorState } from "prosemirror-state";
|
|
3
3
|
import { type ReactElement } from "react";
|
|
4
|
-
import type { ColorRow } from "../styles/colors";
|
|
5
|
-
import { type CellBorderOption } from "../table/cellBorders";
|
|
6
|
-
import type { RunCommand } from "./runCommand";
|
|
4
|
+
import type { ColorRow } from "../styles/colors.js";
|
|
5
|
+
import { type CellBorderOption } from "../table/cellBorders.js";
|
|
6
|
+
import type { RunCommand } from "./runCommand.js";
|
|
7
7
|
export interface CellStyleGroupProps {
|
|
8
8
|
state: EditorState;
|
|
9
9
|
/** The border choices the menu offers. The built-in list when none is given */
|
package/dist/ui/ColorPicker.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** Preset and custom colors shared by text, background, border, and cell formatting. */
|
|
2
2
|
import { type ReactElement } from "react";
|
|
3
|
-
import { type ColorRow } from "../styles/colors";
|
|
3
|
+
import { type ColorRow } from "../styles/colors.js";
|
|
4
4
|
export interface ColorPickerProps {
|
|
5
5
|
current: string | null;
|
|
6
6
|
colors?: readonly ColorRow[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { EditorState } from "prosemirror-state";
|
|
2
2
|
import type { EditorView } from "prosemirror-view";
|
|
3
3
|
import { type ReactElement } from "react";
|
|
4
|
-
import { type CommentAuthor, type DocumentComment } from "../editor/commands/commentCommands";
|
|
4
|
+
import { type CommentAuthor, type DocumentComment } from "../editor/commands/commentCommands.js";
|
|
5
5
|
/**
|
|
6
6
|
* Whether the rail beside the page carries this comment: the thread is unsettled, and the text it
|
|
7
7
|
* was written for is still there to draw it next to.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/** Shows the resolved font, leaves mixed selections blank, and clears explicit fonts via Default. */
|
|
2
2
|
import type { ReactElement } from "react";
|
|
3
|
-
import { type ActiveFontFamily } from "../editor/commands/formattingCommands";
|
|
4
|
-
import { type FontFallbacks } from "../styles/fontStack";
|
|
5
|
-
import type { RunCommand } from "./runCommand";
|
|
3
|
+
import { type ActiveFontFamily } from "../editor/commands/formattingCommands.js";
|
|
4
|
+
import { type FontFallbacks } from "../styles/fontStack.js";
|
|
5
|
+
import type { RunCommand } from "./runCommand.js";
|
|
6
6
|
export interface FontFamilySelectProps {
|
|
7
7
|
current: ActiveFontFamily;
|
|
8
8
|
documentFonts: readonly string[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/** Shows the resolved size, leaves mixed selections blank, and clears explicit sizes via Default. */
|
|
2
2
|
import type { ReactElement } from "react";
|
|
3
|
-
import { type ActiveFontSize } from "../editor/commands/formattingCommands";
|
|
4
|
-
import type { RunCommand } from "./runCommand";
|
|
3
|
+
import { type ActiveFontSize } from "../editor/commands/formattingCommands.js";
|
|
4
|
+
import type { RunCommand } from "./runCommand.js";
|
|
5
5
|
export interface FontSizeSelectProps {
|
|
6
6
|
current: ActiveFontSize;
|
|
7
7
|
fontSizes?: readonly number[];
|
package/dist/ui/LinkCard.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import type { EditorState } from "prosemirror-state";
|
|
3
3
|
import type { EditorView } from "prosemirror-view";
|
|
4
4
|
import { type ReactElement } from "react";
|
|
5
|
-
import { type ActiveLinkSpan } from "../editor/commands/linkCommands";
|
|
5
|
+
import { type ActiveLinkSpan } from "../editor/commands/linkCommands.js";
|
|
6
6
|
export interface LinkCardProps {
|
|
7
7
|
view: EditorView;
|
|
8
8
|
state: EditorState;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/** Selects document-defined paragraph styles and clears explicit styles through the default entry. */
|
|
2
2
|
import type { ReactElement } from "react";
|
|
3
|
-
import type { ParagraphStyleOption } from "../docx/formatting";
|
|
4
|
-
import { type ActiveParagraphStyle } from "../editor/commands/paragraphCommands";
|
|
5
|
-
import type { RunCommand } from "./runCommand";
|
|
3
|
+
import type { ParagraphStyleOption } from "../docx/formatting.js";
|
|
4
|
+
import { type ActiveParagraphStyle } from "../editor/commands/paragraphCommands.js";
|
|
5
|
+
import type { RunCommand } from "./runCommand.js";
|
|
6
6
|
export interface ParagraphStyleSelectProps {
|
|
7
7
|
current: ActiveParagraphStyle;
|
|
8
8
|
styles: readonly ParagraphStyleOption[];
|
package/dist/ui/SpacingMenu.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { EditorState } from "prosemirror-state";
|
|
2
2
|
import { type ReactElement } from "react";
|
|
3
|
-
import { type LineSpacingOption } from "../styles/lineSpacings";
|
|
4
|
-
import type { RunCommand } from "./runCommand";
|
|
3
|
+
import { type LineSpacingOption } from "../styles/lineSpacings.js";
|
|
4
|
+
import type { RunCommand } from "./runCommand.js";
|
|
5
5
|
export interface SpacingMenuProps {
|
|
6
6
|
state: EditorState;
|
|
7
7
|
lineSpacings?: readonly LineSpacingOption[];
|
package/dist/ui/TableMenu.d.ts
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import type { EditorState } from "prosemirror-state";
|
|
3
3
|
import type { EditorView } from "prosemirror-view";
|
|
4
4
|
import { type ReactElement } from "react";
|
|
5
|
-
import { type TableMenuAnchor } from "../editor/plugins/tableContextMenu";
|
|
6
|
-
import type { SurfaceCapabilities } from "../editor/stories/storyView";
|
|
5
|
+
import { type TableMenuAnchor } from "../editor/plugins/tableContextMenu.js";
|
|
6
|
+
import type { SurfaceCapabilities } from "../editor/stories/storyView.js";
|
|
7
7
|
export interface TableMenuProps {
|
|
8
8
|
view: EditorView;
|
|
9
9
|
state: EditorState;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** Grid for choosing the dimensions of a table to insert. */
|
|
2
2
|
import { type ReactElement } from "react";
|
|
3
|
-
import type { RunCommand } from "./runCommand";
|
|
3
|
+
import type { RunCommand } from "./runCommand.js";
|
|
4
4
|
export interface TableSizePickerProps {
|
|
5
5
|
run: RunCommand;
|
|
6
6
|
close: () => void;
|
package/dist/ui/TextMenu.d.ts
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import type { EditorState } from "prosemirror-state";
|
|
3
3
|
import type { EditorView } from "prosemirror-view";
|
|
4
4
|
import { type ReactElement } from "react";
|
|
5
|
-
import { type TextMenuAnchor } from "../editor/plugins/textContextMenu";
|
|
6
|
-
import type { SurfaceCapabilities } from "../editor/stories/storyView";
|
|
5
|
+
import { type TextMenuAnchor } from "../editor/plugins/textContextMenu.js";
|
|
6
|
+
import type { SurfaceCapabilities } from "../editor/stories/storyView.js";
|
|
7
7
|
export interface TextMenuProps {
|
|
8
8
|
view: EditorView;
|
|
9
9
|
state: EditorState;
|