Command Palette

Search for a command to run...

GitHub
ComponentsDate Picker

Date Picker

A clean, popover-based calendar component that allows users to select a single date, complete with localization and dropdown select styling.

React
Calendar Popover

Interactive Demo

Try selecting a date below to see how the component behaves and formats the output value.

Choose the official implementation date for the department policy.

Installation

pnpm dlx shadcn@latest add https://micto-ui-kit.misangono.net/r/micto/date-picker.json

Usage

How to integrate the Date Picker into your form components.

import { useState } from "react"
import { DatePicker } from "@/components/micto/date-picker"

export default function Page() {
  const [date, setDate] = useState("")

  return (
    <div className="max-w-xs">
      <DatePicker 
        value={date} 
        onChange={setDate} 
        placeholder="Pick a date"
      />
    </div>
  )
}

API Reference

Configuration attributes available for the Date Picker component.

PropTypeDefaultDescription
valuestring | DateundefinedThe selected date value. Can be a Date object or an ISO/parsed string representation.
onChange(dateString: string) => voidundefinedCallback triggered when a date is selected. Returns the formatted date string in local timezone (YYYY-MM-DD HH:mm).
placeholderstring'Pick a date'Placeholder text displayed in the input field when no date is selected.
classNamestringundefinedCustom classes applied to the date picker trigger button.