shadcn

Calendar with time picker inline

Cards 64

About

Here is shadcn calendar time picker component

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

Code

How Calendar with time picker inline 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 { Calendar } from "@/components/ui/calendar"
import { Card, CardContent, CardFooter } from "@/components/ui/card"
import { Input } from "@/components/ui/input"
import { Label } from "@/components/ui/label"

export function Calendar17() {
  const [date, setDate] = React.useState<Date | undefined>(
    new Date(2025, 5, 12)
  )

  return (
    <Card className="w-fit py-4">
      <CardContent className="px-4">
        <Calendar
          mode="single"
          selected={date}
          onSelect={setDate}
          className="bg-transparent p-0 [--cell-size:--spacing(10.5)]"
        />
      </CardContent>
      <CardFooter className="flex gap-2 border-t px-4 !pt-4 *:[div]:w-full">
        <div>
          <Label htmlFor="time-from" className="sr-only">
            Start Time
          </Label>
          <Input
            id="time-from"
            type="time"
            step="1"
            defaultValue="10:30:00"
            className="appearance-none [&::-webkit-calendar-picker-indicator]:hidden [&::-webkit-calendar-picker-indicator]:appearance-none"
          />
        </div>
        <span>-</span>
        <div>
          <Label htmlFor="time-to" className="sr-only">
            End Time
          </Label>
          <Input
            id="time-to"
            type="time"
            step="1"
            defaultValue="12:30:00"
            className="appearance-none [&::-webkit-calendar-picker-indicator]:hidden [&::-webkit-calendar-picker-indicator]:appearance-none"
          />
        </div>
      </CardFooter>
    </Card>
  )
}

More by shadcn

View all
  • Navigation menu

    Navigation menu

    803
  • Calendar with time pressets

    Calendar with time pressets

    526
  • Sidebar

    Sidebar

    357
  • Sonner

    Sonner

    247
  • Chart

    Chart

    227
  • Icons

    Icons

    207
  • Dropdown Menu

    Dropdown Menu

    158
  • Calendar with event slots

    Calendar with event slots

    124

More in Cards

View all
  • Course Design Cards

    Course Design Cards

    1.3K
  • Card Studio

    Card Studio

    11
  • Statistics Card 2

    Statistics Card 2

    304
  • Interactive Tech Stack Bento Grid with Hover Effects

    Interactive Tech Stack Bento Grid with Hover Effects

    602
  • Statistics Card 7

    Statistics Card 7

    326
  • Card

    Card

    59
  • Card

    Card

    18
  • Stats cards with links

    Stats cards with links

    95