f0rextasy

Checkbox

Forms 5

About

A toggleable checkbox button with a dashed border when unchecked and a solid filled state when checked, for forms and settings lists.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Checkbox to your project and fits it to your theme.

Code

How Checkbox is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import * as React from "react";
import Checkbox from "@/components/ui/checkbox";

export default function CheckboxDemo() {
  const [checked, setChecked] = React.useState(true);

  return (
    <div className="flex min-h-[200px] w-full items-center justify-center bg-background p-10">
      <label className="flex items-center gap-3 text-sm font-medium text-foreground">
        <Checkbox
          checked={checked}
          onCheckedChange={setChecked}
          aria-label="Accept admission terms"
        />
        Accept Admission Terms
      </label>
    </div>
  );
}

More by f0rextasy

View all
  • Newsletter Signup Card

    Newsletter Signup Card

    16
  • Board Checklist

    Board Checklist

    15
  • Network Graph

    Network Graph

    13
  • Stamp Seal

    Stamp Seal

    12
  • Navbar

    Navbar

    9
  • Milestone Chart

    Milestone Chart

    9
  • Running Order Timeline

    Running Order Timeline

    8
  • Empty State Card

    Empty State Card

    6

More in Forms

View all
  • Authentication Card

    Authentication Card

    51
  • Contact Card

    Contact Card

    1.1K
  • Premium Auth

    Premium Auth

    560
  • Book A Demo 1

    Book A Demo 1

    88
  • Modern & Stunning sign in

    Modern & Stunning sign in

    1.7K
  • Card Studio

    Card Studio

    46
  • SignInPage

    SignInPage

    741
  • Form

    Form

    139