Home / Function/ DatePickerDemo() — ui Function Reference

DatePickerDemo() — ui Function Reference

Architecture documentation for the DatePickerDemo() function in date-picker-demo.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  872d8adf_9ffc_06e5_d65f_64b4c1af56ab["DatePickerDemo()"]
  5a7080ee_be5a_c097_5da4_a22e9ae9c2ef["date-picker-demo.tsx"]
  872d8adf_9ffc_06e5_d65f_64b4c1af56ab -->|defined in| 5a7080ee_be5a_c097_5da4_a22e9ae9c2ef
  style 872d8adf_9ffc_06e5_d65f_64b4c1af56ab fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/examples/base/date-picker-demo.tsx lines 14–41

export function DatePickerDemo() {
  const [date, setDate] = React.useState<Date>()

  return (
    <Popover>
      <PopoverTrigger
        render={
          <Button
            variant={"outline"}
            data-empty={!date}
            className="data-[empty=true]:text-muted-foreground w-[212px] justify-between text-left font-normal"
          />
        }
      >
        {date ? format(date, "PPP") : <span>Pick a date</span>}
        <ChevronDownIcon data-icon="inline-end" />
      </PopoverTrigger>
      <PopoverContent className="w-auto p-0" align="start">
        <Calendar
          mode="single"
          selected={date}
          onSelect={setDate}
          defaultMonth={date}
        />
      </PopoverContent>
    </Popover>
  )
}

Subdomains

Frequently Asked Questions

What does DatePickerDemo() do?
DatePickerDemo() is a function in the ui codebase, defined in apps/v4/examples/base/date-picker-demo.tsx.
Where is DatePickerDemo() defined?
DatePickerDemo() is defined in apps/v4/examples/base/date-picker-demo.tsx at line 14.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free