"use client" import * as React from "react" import { ChevronLeft, ChevronRight } from "lucide-react" import { DayPicker, getDefaultClassNames } from "react-day-picker" import { cn } from "@/lib/utils" import { buttonVariants } from "@/components/ui/button" import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue, } from "@/components/ui/select" export type CalendarProps = React.ComponentProps & { buttonVariant?: "ghost" | "outline" } function Calendar({ className, classNames, showOutsideDays = true, captionLayout = "label", buttonVariant = "ghost", ...props }: CalendarProps) { const defaultClassNames = getDefaultClassNames() return ( { const Icon = orientation === "left" ? ChevronLeft : ChevronRight return }, Dropdown: (props) => { const { value, onChange, options } = props const selected = options?.find((option) => option.value === value) const handleChange = (newValue: string) => { const changeEvent = { target: { value: newValue }, } as React.ChangeEvent onChange?.(changeEvent) } return ( ) }, }} {...props} /> ) } Calendar.displayName = "Calendar" export { Calendar }