{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "dependencies": [
    "react-aria-components",
    "@internationalized/date"
  ],
  "files": [
    {
      "content": "export * from \"./calendar\";\nexport * as Calendar from \"./namespace\";\nexport * from \"./styles\";\n",
      "path": "src/registry/ui/calendar/index.ts",
      "type": "registry:ui"
    },
    {
      "content": "\"use client\";\n\nimport { getLocalTimeZone, isToday } from \"@internationalized/date\";\nimport type { VariantProps } from \"cva\";\nimport {\n  Calendar,\n  composeRenderProps,\n  type DateValue,\n  Heading,\n  CalendarCell as RACCalendarCell,\n  CalendarGrid as RACCalendarGrid,\n  CalendarGridBody as RACCalendarGridBody,\n  CalendarGridHeader as RACCalendarGridHeader,\n  CalendarHeaderCell as RACCalendarHeaderCell,\n  RangeCalendar,\n} from \"react-aria-components\";\nimport { CalendarStyles } from \"./styles\";\n\nexport interface CalendarRootProps<T extends DateValue>\n  extends React.ComponentProps<typeof Calendar<T>>,\n    VariantProps<typeof CalendarStyles.Root> {}\n\nexport function CalendarRoot<T extends DateValue>({\n  className,\n  variant,\n  ...props\n}: CalendarRootProps<T>) {\n  return (\n    <Calendar\n      className={composeRenderProps(className, (className) =>\n        CalendarStyles.Root({\n          className,\n          variant,\n        })\n      )}\n      data-slot=\"calendar-root\"\n      {...props}\n    />\n  );\n}\n\nexport interface RangeCalendarRootProps<T extends DateValue>\n  extends React.ComponentProps<typeof RangeCalendar<T>>,\n    VariantProps<typeof CalendarStyles.Root> {}\n\nexport function RangeCalendarRoot<T extends DateValue>({\n  className,\n  variant,\n  ...props\n}: RangeCalendarRootProps<T>) {\n  return (\n    <RangeCalendar\n      className={composeRenderProps(className, (className) =>\n        CalendarStyles.Root({\n          className,\n          variant,\n        })\n      )}\n      data-slot=\"range-calendar-root\"\n      {...props}\n    />\n  );\n}\n\nexport interface CalendarHeaderProps extends React.ComponentProps<\"header\"> {}\n\nexport function CalendarHeader({ className, ...props }: CalendarHeaderProps) {\n  return (\n    <header\n      className={CalendarStyles.Header({ className })}\n      data-slot=\"calendar-header\"\n      {...props}\n    />\n  );\n}\n\nexport interface CalendarMonthProps\n  extends React.ComponentProps<typeof Heading> {}\n\nexport function CalendarMonth({ className, ...props }: CalendarMonthProps) {\n  return (\n    <Heading\n      {...props}\n      className={CalendarStyles.Heading({ className })}\n      data-slot=\"calendar-month\"\n    />\n  );\n}\n\nexport interface CalendarNavProps extends React.ComponentProps<\"nav\"> {}\n\nexport function CalendarNav({ className, ...props }: CalendarNavProps) {\n  return (\n    <nav\n      {...props}\n      className={CalendarStyles.Nav({ className })}\n      data-slot=\"calendar-nav\"\n    />\n  );\n}\n\nexport interface CalendarGridProps\n  extends React.ComponentProps<typeof RACCalendarGrid> {}\nexport function CalendarGrid({ className, ...props }: CalendarGridProps) {\n  return (\n    <RACCalendarGrid\n      {...props}\n      className={CalendarStyles.Grid({ className })}\n      data-slot=\"calendar-grid\"\n    />\n  );\n}\n\nexport interface CalendarGridHeaderProps\n  extends React.ComponentProps<typeof RACCalendarGridHeader> {}\nexport function CalendarGridHeader(props: CalendarGridHeaderProps) {\n  return <RACCalendarGridHeader {...props} data-slot=\"calendar-grid-header\" />;\n}\n\nexport interface CalendarHeaderCellProps\n  extends React.ComponentProps<typeof RACCalendarHeaderCell> {}\n\nexport function CalendarHeaderCell({\n  className,\n  ...props\n}: CalendarHeaderCellProps) {\n  return (\n    <RACCalendarHeaderCell\n      {...props}\n      className={CalendarStyles.HeaderCell({ className })}\n      data-slot=\"calendar-header-cell\"\n    />\n  );\n}\n\nexport interface CalendarGridBodyProps\n  extends React.ComponentProps<typeof RACCalendarGridBody> {}\nexport function CalendarGridBody(props: CalendarGridBodyProps) {\n  return <RACCalendarGridBody {...props} data-slot=\"calendar-grid-body\" />;\n}\n\nexport interface CalendarCellProps\n  extends React.ComponentProps<typeof RACCalendarCell>,\n    Omit<VariantProps<(typeof CalendarStyles)[\"Cell\"]>, \"isToday\"> {}\n\nexport function CalendarCell({\n  className,\n  shape,\n  ...props\n}: CalendarCellProps) {\n  return (\n    <RACCalendarCell\n      {...props}\n      className={composeRenderProps(className, (className, values) =>\n        CalendarStyles.Cell({\n          className,\n          isToday: isToday(values.date, getLocalTimeZone()),\n          shape,\n        })\n      )}\n      data-shape={shape}\n      data-slot=\"calendar-cell\"\n    />\n  );\n}\n",
      "path": "src/registry/ui/calendar/calendar.tsx",
      "type": "registry:ui"
    },
    {
      "content": "import { cva } from \"~/registry/lib/cva\";\n\nexport const CalendarStyles = {\n  Cell: cva({\n    base: [\n      \"relative grid size-8 select-none place-content-center whitespace-nowrap text-accent-foreground text-sm outline-hidden transition\",\n      \"hover:bg-accent hover:text-accent-foreground\",\n      \"disabled:cursor-not-allowed disabled:opacity-50\",\n      \"aria-disabled:cursor-not-allowed aria-disabled:opacity-50\",\n      \"focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50\",\n\n      \"selected:bg-primary selected:text-primary-foreground\",\n      \"group-data-[slot=range-calendar-root]:selected:bg-accent group-data-[slot=range-calendar-root]:selected:text-accent-foreground\",\n      \"group-data-[slot=range-calendar-root]:selection-start:bg-primary group-data-[slot=range-calendar-root]:selection-start:text-primary-foreground\",\n      \"group-data-[slot=range-calendar-root]:selection-end:bg-primary group-data-[slot=range-calendar-root]:selection-end:text-primary-foreground\",\n    ],\n    defaultVariants: {\n      shape: \"default\",\n    },\n    variants: {\n      isToday: {\n        true: [\n          \"after:absolute after:start-1/2 after:bottom-1 after:z-10 after:-translate-x-1/2\",\n          \"after:size-[3px] after:rounded-full after:bg-current\",\n        ],\n      },\n      shape: {\n        default: [\n          \"rounded-md group-data-[slot=range-calendar-root]:not-selection-start:not-selection-end:selected:rounded-none\",\n        ],\n        rounded: \"rounded-full\",\n      },\n    },\n  }),\n  Grid: cva({\n    base: [\n      \"w-full\",\n      \"[&_tr]:mt-2 [&_tr]:flex [&_tr]:w-full [&_tr]:justify-between\",\n\n      \"[&_tr_td[aria-selected=true]]:bg-accent\",\n      \"[&_tr_td[aria-selected=true]:has([data-selection-start])]:rounded-l-md\",\n      \"[&_tr_td[aria-selected=true]:has([data-selection-end])]:rounded-r-md\",\n      \"group-data-[slot=calendar-root]:[&_tr_td[aria-selected=true]]:rounded-md\",\n\n      \"[&_tr_td[aria-selected=true]:has([data-selection-start][data-shape=rounded])]:rounded-l-full\",\n      \"[&_tr_td[aria-selected=true]:has([data-selection-end][data-shape=rounded])]:rounded-r-full\",\n      \"group-data-[slot=calendar-root]:[&_tr_td:has([data-shape=rounded])[aria-selected=true]]:rounded-full\",\n    ],\n  }),\n  Header: cva({\n    base: [\"flex w-full justify-center gap-1 px-1 pb-5 sm:pb-4\"],\n  }),\n  HeaderCell: cva({\n    base: [\"w-8 rounded-md font-normal text-[0.8rem] text-muted-foreground\"],\n  }),\n  Heading: cva({\n    base: [\"font-medium text-sm\"],\n  }),\n  Nav: cva({\n    base: [\"flex w-full items-center justify-between gap-1\"],\n  }),\n  Root: cva({\n    base: [\"group\"],\n    variants: {\n      variant: {\n        outline: \"rounded-md border p-3 shadow-sm\",\n      },\n    },\n  }),\n};\n",
      "path": "src/registry/ui/calendar/styles.ts",
      "type": "registry:ui"
    },
    {
      "content": "export {\n  CalendarCell as Cell,\n  CalendarGrid as Grid,\n  CalendarGridBody as GridBody,\n  CalendarGridHeader as GridHeader,\n  CalendarHeader as Header,\n  CalendarHeaderCell as HeaderCell,\n  CalendarMonth as Month,\n  CalendarNav as Nav,\n  CalendarRoot as Root,\n  RangeCalendarRoot as Range,\n} from \"./calendar\";\n",
      "path": "src/registry/ui/calendar/namespace.ts",
      "type": "registry:ui"
    }
  ],
  "name": "calendar",
  "registryDependencies": [
    "@kanpeki/cva",
    "@kanpeki/custom-plugin"
  ],
  "type": "registry:ui"
}