UX: prosemirror rich editor nodes cleanup / slightly better UX (#32361)

We don't want "ghost" `content` within mention/hashtag, as they're
already rendering their non-editable content on `toDOM`.

`atom: true` is not necessary for content-less nodes

Re-use existing heading node spec instead of re-creating.

A UX improvement from these changes is a better Cmd-Left/Home navigation
when these nodes begin a paragraph and the caret is after them.
This commit is contained in:
Renato Atilio
2025-04-18 00:20:55 -03:00
committed by GitHub
parent 2b4521d0b3
commit f06175b72d
5 changed files with 7 additions and 25 deletions

View File

@ -5,7 +5,6 @@ const extension = {
local_date: {
attrs: { date: {}, time: {}, timezone: { default: null } },
group: "inline",
atom: true,
inline: true,
parseDOM: [
{
@ -42,7 +41,6 @@ const extension = {
timezone: { default: null },
},
group: "inline",
atom: true,
inline: true,
parseDOM: [
{