FeaturesRich Content
Task List
Create interactive checklists with `toggleTaskList`.
Type: Node · Category: Rich Content
Task List creates a checklist with interactive checkboxes. Each item can be checked or unchecked.
Demo
Installation
import { TaskList } from "@arkpad/extension-task-list";
// Note: TaskItem is loaded automatically by TaskListCommands
// Toggles the current block between a task list and a paragraph
editor.runCommand("toggleTaskList");
// Toggles the checkbox state of the current active task item
editor.runCommand("toggleTaskItem");Keyboard Shortcuts & Navigation
| Key | Action |
|---|---|
Mod-Shift-9 | Toggles checklist |
Enter | Splits task item / exits checklist if empty |
Tab | Indents current task item |
Shift-Tab | Outdents current task item |
Markdown Input Rules
Type these patterns at the beginning of a line followed by a space to build checklists:
| Pattern | Result |
|---|---|
[ ] | Empty Task List item |
[x] | Checked Task List item |
Active State
const isTaskList = editor.isActive("taskList");
// Check if a task item is checked
const isChecked = editor.isActive("taskItem", { checked: true });