@tiptap-pro/extension-convert-kit changelog

Changelog for @tiptap-pro/extension-convert-kit

0.4.0

Minor Changes

  • Improve OrderedListNumbering and multi-editor stylesheet handling:

    • Add a toggleOrderedListWithFormat command that starts an ordered list and applies a numbering format in one call — the one-call equivalent of toggleOrderedList followed by setOrderedListNumberingFormat, and the natural action for a "pick a format to start a numbered list" toolbar button. When the selection is already inside an ordered list, it toggles the list off, mirroring toggleOrderedList.
    • orderedListNumbering now accepts an options object: defaultFormat (the format new ordered lists start with) and formats (the same definitions passed to ExportDocx.configure({ numberingFormats }), from which the editor-preview CSS is generated and injected automatically). The injected stylesheet is keyed by its content, so editors configured with different formats each get their own correct stylesheet instead of the first one winning.
    • Enforce the outermost-only numbering invariant for content that bypasses parseHTML — JSON, collaborative sync, and programmatic edits — by clearing stale numberingFormat attributes from nested ordered lists.
    • Reference-count injected stylesheets (generic resets, contextual spacing, numbering preview) so the stylesheet shared by several editors is removed only when the last of them is destroyed, instead of when the first one unmounts.
    • generateNumberingFormatCss now emits width: 100% on each list item. Without it, the grid list item collapses to zero width in a shrink-to-fit context — e.g. when a paginating editor (extension-pages) splits a list across a page boundary — squeezing the item's text into a sliver in the page gutter.
    • generateNumberingFormatCss now maps locale baseStyle values (e.g. hebrew1, japaneseCounting, koreanDigital, chineseCounting, thaiNumbers, ideographDigital) onto the matching CSS Counter Styles Level 3 predefined styles, so those lists render their native glyph in the editor instead of falling back to decimal. Styles a browser doesn't support fall back to decimal on their own, and formats with no faithful CSS equivalent (e.g. ordinal, cardinalText, chicago) keep the decimal fallback.

0.3.0

Minor Changes

  • Add editor-side ordered-list numbering support to ConvertKit, pairing with the numberingFormats option already available on @tiptap-pro/extension-export-docx.

    @tiptap-pro/extension-convert-kit now ships everything the editor side needs for custom DOCX numbering:

    • OrderedListNumbering — a Tiptap extension that adds a numberingFormat attribute to the outermost <ol>, a setOrderedListNumberingFormat(id) command, and an editor.storage.orderedListNumbering.activeNumberingFormat value that tracks the format at the current selection (handy for highlighting a toolbar). Registered automatically by ConvertKit (opt in via orderedListNumbering: true).
    • generateNumberingFormatCss(formats, options?) and GenerateNumberingFormatCssOptions — a typed, dependency-free CSS generator for in-editor preview of numbering formats. The preview honours startAt and marker font sizes given as docx measure strings, matching the exported .docx.
    • NumberingFormatDefinition, NumberingLevelDefinition, NumberingBaseStyle, NumberingMarkerFont — the types you write your registry against. Structurally compatible with ExportDocx.configure({ numberingFormats }), so one array drives both editor preview and DOCX export.

0.2.0

Minor Changes

  • Bundle UndoRedo (from @tiptap/extensions) into ConvertKit. Undo/redo now works out of the box without an additional import, matching the parity of StarterKit-based setups. Disable with ConvertKit.configure({ undoRedo: false }) if you provide your own history implementation.

0.1.1

Patch Changes

  • Licensing

0.1.0

Minor Changes

  • Initial release of ConvertKit — a single-import Tiptap extension bundle for rendering DOCX-imported content

    Custom DOCX Extensions:

    • Paragraph and Heading with spacing (spacingBefore, spacingAfter, lineHeight), fontSize (from DOCX paragraph mark for spacer paragraphs), indentation (indent, hangingIndent), and contextualSpacing attributes
    • Image with crop attributes (cropTop, cropBottom, cropLeft, cropRight)
    • Table with left indentation, cellMinWidth: 1 for narrow DOCX spacer columns, and collapsed borders
    • TableRow with height and heightRule (exact/atLeast)
    • TableCell and TableHeader with background, verticalAlign, per-side border attributes (width, style, color), and a .cell-content wrapper div for height constraints
    • TableRow exposes height as a --tr-height CSS custom property for child cells

    CSS Resets:

    • Injects browser style resets on editor creation to normalize table rendering: line-height: 1 on cells and rows, vertical-align: top on cells, white-space: normal on cell paragraphs, and zero default margins/padding — ensuring DOCX spacing values delivered as inline styles render accurately
    • Enforces exact row heights (heightRule: "exact") by constraining the .cell-content wrapper div to the row's height with overflow: hidden — CSS height/max-height do not apply to display: table-cell elements, so the block-level wrapper is required

    Table rendering fixes:

    • Table extension accepts a new width attribute (parses/renders width: Npx; max-width: 100%) so DOCX-declared w:tblW values render accurately without overflowing the page container when the author drew the table wider than the content area
    • Table extension now clamps negative indent values to 0 at render time while preserving the raw value in attrs — negative w:tblInd values from DOCX (which rely on Word's paper gutter) no longer push tables past the page container's left edge; the original value is kept for export round-trip
    • TableRow extension height rendering now branches on heightRule: exact rows keep their hard-clipping behaviour via height + --tr-height; other rows (atLeast or unset) render as min-height so narrower columns can grow the row instead of clipping content

    Bundled OSS Extensions:

    • Includes 30+ standard Tiptap extensions (Document, Text, Bold, Italic, Underline, Strike, Code, Link, BulletList, OrderedList, ListItem, HardBreak, HorizontalRule, CodeBlock, TextStyleKit, TextAlign, Highlight, Superscript, Subscript, Dropcursor, Gapcursor, PageBreak) — all individually configurable or disableable via ConvertKit.configure()