Checkbox Todo Strikethrough

A to-do list where ticking an item draws a line through its text from left to right, then the finished item sinks to the bottom with a layout spring.

checkboxtodostrikethroughlistlayout

Installation

Run the shadcn CLI in a project with Tailwind CSS. The component lands in components/pixelpapa/checkbox-todo-strikethrough.tsx.

$pnpm dlx shadcn@latest add "https://pixelpapa.com/r/checkbox-todo-strikethrough.json"
Manual install+

1. Install the dependencies.

$pnpm add motion

2. Copy the code from the Code tab above into your project. It imports the cn helper from @/lib/utils, which every shadcn project already has.

Build it with AI

Prefer to let an agent do the wiring? Copy this prompt, describe where the component should go, and paste.

AI prompt

Add the "Checkbox Todo Strikethrough" component from PixelPapa UI to this project.

What it is: A to-do list where ticking an item draws a line through its text from left to right, then the finished item sinks to the bottom with a layout spring.
Category: Checkboxes & Radios. Depends on: motion.

1. Install it with the shadcn CLI:
   npx shadcn@latest add "https://pixelpapa.com/r/checkbox-todo-strikethrough.json"
   (If the CLI is unavailable, fetch that URL, write files[0].content to components/pixelpapa/checkbox-todo-strikethrough.tsx and install the listed dependencies.)
2. Import it from "@/components/pixelpapa/checkbox-todo-strikethrough" and place it where I describe below.
3. Keep its animation timings and accessibility attributes. Replace the demo copy and data with content that fits my product, and use my existing theme tokens (bg-background, text-foreground, bg-primary, border-border) rather than hard-coded colours.

Where to use it: <describe the page and position here>

More checkboxes & radios

All 6 checkboxes & radios →