Theme

Start Here

Start from the smallest working snippet, then move to interactive examples and the full API contract below.

Styled quick start

Copy this entrypoint first. It includes the imports required to get the component on screen.

svelte
<script lang="ts">
  import '@dryui/ui/themes/default.css';
  import '@dryui/ui/themes/dark.css';
  import { Calendar } from '@dryui/ui';
</script>

<Calendar.Root>
  <Calendar.Header>...</Calendar.Header>
  <Calendar.Grid>...</Calendar.Grid>
  <Calendar.Prev>...</Calendar.Prev>
  <Calendar.Next>...</Calendar.Next>
  <Calendar.Heading>...</Calendar.Heading>
</Calendar.Root>

Import options

Root package

ts
import { Calendar } from '@dryui/ui'

Per-component subpath

ts
import { Calendar } from '@dryui/ui/calendar'

Customize

Use the interactive examples to see common variants, states, and composition patterns before building your own.

Default

March 2026
svelte
<script lang="ts">
  let date = $state(new Date());
</script>
<Calendar.Root bind:value={date}>
  <Calendar.Header>
    <Calendar.Prev />
    <Calendar.Heading />
    <Calendar.Next />
  </Calendar.Header>
  <Calendar.Grid />
</Calendar.Root>

Disabled

March 2026

Structure

Compound components always start with Calendar.Root. Use this structure block to understand required wrappers before you wire state or styling.

Calendar.Root
  Calendar.Header
  Calendar.Grid
  Calendar.Prev
  Calendar.Next
  Calendar.Heading
Calendar.Root Calendar.HeaderCalendar.GridCalendar.PrevCalendar.NextCalendar.Heading

Compose

The full API contract lives here: props, CSS variables, and the public data attributes you can target when styling.

Compound component. Start with Calendar.Root, then add only the parts you need.

Calendar.HeaderCalendar.GridCalendar.PrevCalendar.NextCalendar.Heading

Calendar.Root

Prop Type Default Required Bindable
value
Date | null
$bindable<Date | null>(null)
locale
string
min
Date | null
max
Date | null
disabled
boolean
children
Snippet

Forwards <div> attributes via rest props. Common examples: id, style, role.

Calendar.Header

Prop Type Default Required Bindable
children
Snippet

Forwards <div> attributes via rest props. Common examples: id, style, role.

Calendar.Grid

Prop Type Default Required Bindable

Forwards <div> attributes via rest props. Common examples: id, style, role.

Calendar.Prev

Prop Type Default Required Bindable
children
Snippet

Forwards <button> attributes via rest props. Common examples: type, disabled, name.

Calendar.Next

Prop Type Default Required Bindable
children
Snippet

Forwards <button> attributes via rest props. Common examples: type, disabled, name.

Calendar.Heading

Prop Type Default Required Bindable

Forwards <span> attributes via rest props. Common examples: id, style, aria-label.