Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
feat(editor): MUL-3557 add one-click task-list toggle to bubble menu (#4538)
Jiayuan Zhang343ace89a7df
diff --git a/packages/views/editor/bubble-menu.tsx b/packages/views/editor/bubble-menu.tsxindex a709d817e5..69f40334c8 100644--- a/packages/views/editor/bubble-menu.tsx+++ b/packages/views/editor/bubble-menu.tsx@@ -621,6 +621,19 @@ function EditorBubbleMenu({<Separator orientation="vertical" className="mx-0.5 h-5" /><HeadingDropdown editor={editor} onOpenChange={handleMenuOpenChange} activeLevel={fmt.heading1 ? 1 : fmt.heading2 ? 2 : fmt.heading3 ? 3 : undefined} /><ListDropdown editor={editor} onOpenChange={handleMenuOpenChange} isBullet={fmt.bulletList} isOrdered={fmt.orderedList} isTask={fmt.taskList} />+ {/* Dedicated one-click toggle for checkbox task lists — turns the+ current line(s) into a `- [ ]` task item or back to a paragraph.+ The same toggle also lives in the List dropdown, but a direct+ button keeps the common "make this a checklist" action one tap+ away instead of two. */}+ <Tooltip>+ <TooltipTrigger render={+ <Toggle size="sm" pressed={fmt.taskList} onPressedChange={() => editor.chain().focus().toggleTaskList().run()} onMouseDown={(e) => e.preventDefault()} />+ }>+ <ListTodo className="size-3.5" />+ </TooltipTrigger>+ <TooltipContent side="top" sideOffset={8}>{t(($) => $.bubble_menu.task_list)}</TooltipContent>+ </Tooltip><Tooltip><TooltipTrigger render={<Toggle size="sm" pressed={fmt.blockquote} onPressedChange={() => editor.chain().focus().toggleBlockquote().run()} onMouseDown={(e) => e.preventDefault()} />diff --git a/packages/views/locales/en/editor.json b/packages/views/locales/en/editor.jsonindex 8d84d1654f..814a387e6a 100644--- a/packages/views/locales/en/editor.json+++ b/packages/views/locales/en/editor.json@@ -7,6 +7,7 @@"highlight": "Highlight","link": "Link","list": "List",+ "task_list": "Task list","quote": "Quote","url_aria_label": "URL","heading_dropdown": {diff --git a/packages/views/locales/ja/editor.json b/packages/views/locales/ja/editor.jsonindex cc619f163a..54068f692a 100644--- a/packages/views/locales/ja/editor.json+++ b/packages/views/locales/ja/editor.json@@ -7,6 +7,7 @@"highlight": "ハイライト","link": "リンク","list": "リスト",+ "task_list": "タスクリスト","quote": "引用","url_aria_label": "URL","heading_dropdown": {diff --git a/packages/views/locales/ko/editor.json b/packages/views/locales/ko/editor.jsonindex 06155c1141..f474a51a0b 100644--- a/packages/views/locales/ko/editor.json+++ b/packages/views/locales/ko/editor.json@@ -7,6 +7,7 @@"highlight": "강조","link": "링크","list": "목록",+ "task_list": "체크리스트","quote": "인용","url_aria_label": "URL","heading_dropdown": {diff --git a/packages/views/locales/zh-Hans/editor.json b/packages/views/locales/zh-Hans/editor.jsonindex 368556e9c0..7f52892f7e 100644--- a/packages/views/locales/zh-Hans/editor.json+++ b/packages/views/locales/zh-Hans/editor.json@@ -7,6 +7,7 @@"highlight": "高亮","link": "链接","list": "列表",+ "task_list": "任务列表","quote": "引用","url_aria_label": "URL","heading_dropdown": {