- GRID =
[].freeze
- DAYS_OF_WEEK =
%w[
grid grid-cols-7 text-center text-(length:--sp-text-xs)
font-medium text-(--sp-color-muted-fg) mb-(--sp-space-1)
].freeze
- DAYS_OF_MONTH =
%w[grid grid-cols-7 justify-items-center].freeze
- DAY =
%w[
size-(--sp-calendar-day-size) rounded-(--sp-radius-md)
flex items-center justify-center text-(length:--sp-text-sm)
[&:is(button)]:hover:bg-(--sp-color-muted) [&:is(button)]:cursor-pointer
aria-[current=date]:font-bold
aria-selected:bg-(--sp-color-primary)
aria-selected:text-(--sp-color-primary-fg)
aria-selected:hover:bg-(--sp-color-primary)/90
aria-[hidden=true]:pointer-events-none
aria-[disabled=true]:text-(--sp-color-muted-fg)
aria-[disabled=true]:opacity-40
aria-[disabled=true]:pointer-events-none
disabled:text-(--sp-color-muted-fg)
disabled:opacity-40
disabled:pointer-events-none
].freeze
- QUARTER_GRID =
%w[grid grid-cols-4 gap-(--sp-space-1)].freeze
- MONTHS_OF_YEAR =
"contents"
- MONTH =
%w[
rounded-(--sp-radius-md) flex items-center justify-center
text-(length:--sp-text-sm) h-10 flex-1 px-(--sp-space-2)
hover:bg-(--sp-color-muted) cursor-pointer
aria-selected:bg-(--sp-color-primary)
aria-selected:text-(--sp-color-primary-fg)
aria-selected:hover:bg-(--sp-color-primary)/90
aria-[current=month]:font-bold
aria-[disabled=true]:text-(--sp-color-muted-fg)
aria-[disabled=true]:opacity-40
aria-[disabled=true]:pointer-events-none
aria-[disabled=true]:hover:bg-transparent
].freeze
- YEARS_OF_DECADE =
"contents"
- YEAR =
%w[
rounded-(--sp-radius-md) flex items-center justify-center
text-(length:--sp-text-sm) h-10 flex-1 px-(--sp-space-2)
hover:bg-(--sp-color-muted) cursor-pointer
aria-selected:bg-(--sp-color-primary)
aria-selected:text-(--sp-color-primary-fg)
aria-selected:hover:bg-(--sp-color-primary)/90
aria-[current=year]:font-bold
aria-[disabled=true]:text-(--sp-color-muted-fg)
aria-[disabled=true]:opacity-40
aria-[disabled=true]:pointer-events-none
aria-[disabled=true]:hover:bg-transparent
].freeze