[pull] main from ueberdosis:main - #163
Merged
Merged
Conversation
…ing a wrapper (#7950) (#8107) * fix(vue-3): use NodeViewContent element as contentDOM instead of nesting a wrapper (#7950) `<node-view-content as="tbody" />` nested a placeholder wrapper div inside the tbody, which is invalid HTML (tbody may only contain tr) and broke tables. The nodeViewContentRef callback now adopts the mounted <node-view-content> element as the real contentDOM instead of appending the placeholder inside it. * Update packages/vue-3/__tests__/VueNodeViewRenderer.spec.ts * Update packages/vue-3/src/VueNodeViewRenderer.ts * Update packages/vue-3/__tests__/VueNodeViewRenderer.spec.ts --------- Co-authored-by: Dominik Biedebach <6538827+bdbch@users.noreply.github.com>
…sable (#7493) (#8108) createDoc() now parses the stripped fallback document and seeds this.editorState with it before emitting contentError, so editor.commands can be safely called from the handler on initial load. The constructor only builds editorState from initialDoc when it wasn't already seeded by the content-error path.
* feat(extension-ruby-text): add RubyText extension Introduce @tiptap/extension-ruby-text for HTML ruby annotations (furigana). Store the annotation as a mark attribute on the base text, render a non-editable <rt> element, and allow click-to-edit. Include React and Vue demos, unit tests, and e2e tests. * fix(ruby-text): handle null and empty annotations consistently Use strict null checks for the rt attribute to preserve an empty annotation while skipping the rt element for null. Do not parse ruby elements without an rt child as a mark. Apply configured HTMLAttributes to the mark view onCreate. * test(demos): fix RubyText annotation submission Use the demo test selector and remove unreliable arrow navigation coverage. * fix(ruby-text): support non-editable editor mode Add editable state checks to ruby text plugin to prevent inline editing. Update tests and remove unused HTML attribute parsing. * feat(ruby-text): enhance RubyText extension with custom annotation editor support Add functionality to replace the default annotation editor with a custom element via the `renderAnnotationEditor` option. Update tests to cover new editor behaviors, including handling unchanged submissions and focusing on custom inputs.
) Empty <td>/<th> elements throw RangeError: Invalid content for node tableCell/tableHeader: <> when parsed via insertContent/insertContentAt, because the slice-parse path (DOMParser.parseSlice) does not backfill required content the way setContent's full-document parse does. Add a getContent-based parse rule (only matching empty elements, via getAttrs) to tableCell and tableHeader that backfills a single empty paragraph, sharing the logic through a new fillEmptyCellContent helper. Non-empty cells keep using the original, unmodified default parse rule.
* fix(markdown): recover blank lines absorbed into block token raw marked's heading, table and html-block tokenizers match a trailing `\n+`, so the blank lines that follow such a block are absorbed into the token's own `raw` and no standalone `space` token is emitted. Empty paragraphs were only reconstructed from `space` tokens, so those blank lines were dropped on parse — eroding one blank line per parse/serialize round-trip in editors that persist content as markdown. Normalize the marked token stream before parsing: `extractAbsorbedBlankLines` splits an absorbed trailing blank-line run back into an explicit `space` token, so the existing single reconstruction path handles every block uniformly. Adds a regression spec and a changeset. * test(markdown): cover html-block blank-line recovery * Update fix-markdown-block-token-blank-line-erosion.md * Update block-token-blank-line.spec.ts * Refactor comments for clarity in utils.ts * Update packages/markdown/src/MarkdownManager.ts Co-authored-by: Arnau Gómez Farell <agomez1f@gmail.com> * Update packages/markdown/src/MarkdownManager.ts * Update packages/markdown/src/utils.ts * test(markdown): fix paragraph round-trip assertion --------- Co-authored-by: bdbch <6538827+bdbch@users.noreply.github.com> Co-authored-by: Arnau Gómez Farell <agomez1f@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )