ueberdosis / tiptap

The headless rich text editor framework for web artisans.
https://tiptap.dev
MIT License
27.66k stars 2.3k forks source link

[Bug]: TaskLists and TaskItems un-clickable and continually rerendering #5643

Open pomarie opened 2 months ago

pomarie commented 2 months ago

Affected Packages

TaskList, TaskItem

Version(s)

2.6.6

Bug Description

TaskLists and TaskItems are continually re-rendering?

(Video link: https://cln.sh/s75C7vQ8)

https://github.com/user-attachments/assets/859ecfaf-3c4d-46f4-9842-7077569ffdee

The configuration I have for them is really vanilla, so I'm not doing anything special:

const editor = useEditor(
    {
      extensions: [
        StarterKit.configure({
          bulletList: {
            HTMLAttributes: { class: "tiptap-bullet-list" },
          },
          orderedList: {
            HTMLAttributes: { class: "tiptap-ordered-list" },
          },
          heading: { HTMLAttributes: { class: "tiptap-heading" } },
          blockquote: {
            HTMLAttributes: { class: "tiptap-blockquote" },
          },
          horizontalRule: {
            HTMLAttributes: { class: "tiptap-horizontal-rule" },
          },
        }),
        Typography,
        TaskList.configure({}),
        TaskItem.configure({
          // nested: true,
        }),
        Underline,
..

Browser Used

Chrome

Code Example URL

No response

Expected Behavior

The taskitems and tasklist items should behave like all the other elements, and not continually re-render

Additional Context (Optional)

No response

Dependency Updates

Nantris commented 2 months ago

For debugging purposes, if you remove these lines, does it still occur?

 bulletList: {
            HTMLAttributes: { class: "tiptap-bullet-list" },
          },
          orderedList: {
            HTMLAttributes: { class: "tiptap-ordered-list" },
          },

And replace these lines with just the extensions without using configure:

        TaskList.configure({}),
        TaskItem.configure({
          // nested: true,
        }),
pomarie commented 2 months ago

Thanks @Nantris ! Yes unfortunately it still happens with those changes

nperez0111 commented 2 months ago

Given that we cannot reproduce this, I think you've got to make a codesandbox