• Jodit
  • PRO
  • Builder
  • Getting Started
  • Playground
  • Examples
  • Documentation
  • Download
  • Overview
  • Issue tracker
  • Docs
  • Plugins
  • Demo
  • Pricing
  • File Browser Pro
  • Sign in
Get connected wth us on social networks!

Footer

Jodit Core

  • Jodit Home page
  • Documentation
  • Playground
  • Examples
  • Github
  • Issues

Integration

  • Jodit React
  • Jodit Angular
  • Jodit Vue
  • Jodit Yii2
  • Jodit Joomla

PRO/OEM plugins

  • AutoComplete
  • Backup Plugin
  • Button Generator
  • Change case
  • Custom Color Picker
  • Emoji
  • Finder
  • Google Search
  • Paste code
  • Show Blocks
  • Virtual Keyboard
  • Tune block
  • Highlight signature
  • Google Maps Editor
  • Export in PDF
  • Page Break
  • Iframe Editor
  • Paste from Word PRO
  • Mobile View
  • ToDo List
  • Translate

Links

  • Demo PRO/OEM
  • Demo FileBrowser PRO
  • Price
  • License
  • Support
  • For resellers

Versions

  • site v.0.1.823
  • Jodit PRO v.4.6.9
  • Jodit v.4.6.2
  • All versions
2025 © Copyright: XDSoft.net <support@xdsoft.net>
  • Getting started

    • Installation
    • Usage
    • Support
    • FAQs
    • Cloud
    • Examples
  • How to

    • Create plugin
    • Add custom button
    • Add custom font in the font list
    • How to create module
    • How to generate license key
    • How to make a backend finder
    • How to set up document view
  • Modes

    • Source mode
  • Customisation

    • Theme
    • Keyboard
  • API

    • License Rest API
    • JS API
  • Changelog

  • Plugins

    • AutoComplete
    • Backup Plugin
    • Button Generator
    • Change case
    • Custom Color Picker
    • Emoji
    • Finder
    • Google Search
    • Paste code
    • Show Blocks
    • Virtual Keyboard
    • Tune block
    • Highlight signature
    • Google Maps Editor
    • Export in PDF
    • Page Break
    • Iframe Editor
    • Paste from Word PRO
    • Mobile View
    • ToDo List
    • Translate

Todo List Plugin for Jodit

This plugin adds a button to the toolbar that allows you to insert and manage interactive task lists with checkboxes. Todo lists are perfect for creating checklists, task lists, or any content that requires user interaction.

Features

  • Adds a "To-do List" button to the toolbar in the "list" group
  • Creates interactive checklists with checkable items
  • Automatically adds checkboxes to list items
  • Supports customization of list appearance and checkbox behavior
  • Handles proper cursor navigation around checkboxes
  • Maintains list structure during editing operations

Installation

If you are using a fat build of the editor, then the plugin is already included in it. If you are using the slim build, then you need to enable it manually:

Jodit.make('#editor', { extraPlugins: ['todo-list'] });
Copy

HTML Structure

By default, the plugin generates the following HTML structure:

<ul class="todo-list"> <li> <label class="todo-list__label" contenteditable="false"> <input tabindex="-1" type="checkbox" /> </label> Task item text </li> </ul>
Copy

Options

todoList.className

  • Type: string
  • Default: 'todo-list'

The CSS class name applied to the <ul> element of the todo list.

Jodit.make('#editor', { todoList: { className: 'custom-todo-list' } });
Copy

todoList.labelClassName

  • Type: string
  • Default: 'todo-list__label'

The CSS class name applied to the <label> element that wraps the checkbox.

Jodit.make('#editor', { todoList: { labelClassName: 'custom-todo-list__checkbox-wrapper' } });
Copy

todoList.inputFactory

  • Type: (jodit: IJodit) => HTMLElement
  • Default: See below

A function that creates the checkbox element. By default, it creates an <input type="checkbox" tabindex="-1"> element.

Default implementation:

function inputFactory(jodit) { return jodit.createInside.element('input', { type: 'checkbox', tabindex: -1 }); }
Copy

You can customize this to create any element you want to use as a checkbox:

Jodit.make('#editor', { todoList: { inputFactory: (jodit) => { // Create a custom checkbox using a span with a custom class return jodit.createInside.element('span', { class: 'custom-checkbox', tabindex: -1 }); } } });
Copy

Usage Examples

Basic Usage

const editor = Jodit.make('#editor', { buttons: ['todoList'], extraPlugins: ['todo-list'] }); // You can also trigger the todo list programmatically editor.execCommand('todoList');
Copy

Custom Styling

const editor = Jodit.make('#editor', { buttons: ['todoList'], todoList: { className: 'task-list', labelClassName: 'task-checkbox' } });
Copy

Custom Checkbox Implementation

const editor = Jodit.make('#editor', { buttons: ['todoList'], todoList: { inputFactory: (jodit) => { const checkbox = jodit.createInside.element('div', { class: 'custom-checkbox', tabindex: -1 }); // Add a checkmark icon inside const icon = jodit.createInside.element('i', { class: 'checkmark-icon' }); checkbox.appendChild(icon); return checkbox; } } });
Copy

CSS Customization

You can customize the appearance of todo lists using CSS variables:

<style> :root { --jd-todo-color-checkbox-border: #333; --jd-todo-color-checkbox-border-checked: #25ab33; --jd-todo-color-checkbox-bg-checked: #25ab33; --jd-todo-color-checkbox-mark-checked: #fff; --jd-todo-size-checkbox: 18px; } </style>
Copy

These variables control:

  • --jd-todo-color-checkbox-border: Border color of the unchecked checkbox
  • --jd-todo-color-checkbox-border-checked: Border color of the checked checkbox
  • --jd-todo-color-checkbox-bg-checked: Background color of the checked checkbox
  • --jd-todo-color-checkbox-mark-checked: Color of the checkmark
  • --jd-todo-size-checkbox: Size of the checkbox

How It Works

  1. When the "To-do List" button is clicked, the plugin creates a new list or converts the selected content into a todo list
  2. Each list item is automatically given a checkbox inside a label element
  3. The plugin handles special cases for cursor navigation, ensuring that users can't place the cursor inside the checkbox label
  4. When a checkbox is clicked, its checked state is toggled
  5. The plugin maintains the proper structure during editing operations like Enter, Backspace, and Tab

This implementation ensures a smooth user experience when working with interactive task lists in the editor.

Demo

Take a walk through the forest: it works wonders

Wonderful forest

The earth holds many mysteries, and one of the wonders of nature is the forest. Dense jungle, ethereal green bamboo, majestic cedars, rows of evergreen pines , rainforests - forests are completely different, and they are some of the best location to escape the stresses of everyday life.

Have you ever felt drained and weary after spending an entire day in a stuffy room, only to instantly feel rejuvenated once you step outside into the fresh air? This is due to our inherent attraction to the natural environment, a phenomenon known as Biophilia. Nature has the power not only to uplift our spirits but also to facilitate healing.

4 main reasons to go to the wonderful forest:

  1. Spending time in forest improves mental health

Exposure to forests can actually reduce human stress levels, help recover from attentional fatigue and generally improve overall mood.

  • The forest can benefit physical health
  • And also mental health

Studies investigating the effect of forest therapy on physiological well-being have also demonstrated a positive impact on cognitive function, glucose levels in diabetic patients, cardiovascular disease, immune system.

  1. Forests provide oxygen for lungs

Trees provide person with the oxygen he breathe.

  1. Nature as a place of power

The forest aids in forging a connection with one's soul. Sometimes, it's crucial to be alone with oneself, setting aside worries and problems. Those who love the forest know this feeling well - amidst the trees, meadows, and streams, all concerns seem to dissipate, replaced by renewed energy and strength.

«Look deep into nature, and then you will understand everything better.»
Albert Einstein