sheengemologic ui
All components

DateRangePicker

A two-ended date picker that keeps its incomplete range draft while accepted state refreshes.@gemologic/sheen-date · date and time

Playground

This example has no scalar controls. Its validated source remains interactive below.
<DateRangePicker label="Report window" name="window" defaultValue={createDateRange(createCalendarDate(2026, 9, 1), createCalendarDate(2026, 9, 8))} />

Variant matrix

Report window

Anatomy

Package
@gemologic/sheen-date
Source
packages/date/src/DatePicker.tsx
Tokens
  • --sheen-color-bg-raised
  • --sheen-color-border-control
  • --sheen-color-focus-ring

Accessibility

Role: two textboxes and calendar dialogKeyboard: Tab, Enter, Space, Escape, Arrow keys, PageUp, PageDown, Home, End

Do

  • Treat a one-ended calendar interaction as a draft, not an accepted range.

Do not

  • Do not infer missing endpoints or submit two unrelated fields.

Generated props

NameTypeDefaultDescription
valueDateRange | nullApp-owned ordered Sheen DateRange, or null.
defaultValueDateRange | nullInitial uncontrolled accepted range.
onValueChange(value: DateRange | null) => voidReceives only complete ordered ranges or explicit clearing.
presetsreadonly DateRangePreset[]Deterministic labeled Sheen range shortcuts.
endLabelstringAccessible label for the second endpoint, defaulting to the range label plus end.
label *stringRequired visible range label.
minValueCalendarDateEarliest selectable endpoint.
maxValueCalendarDateLatest selectable endpoint.
isDateUnavailable(value: CalendarDate) => booleanMarks endpoint dates unavailable.
defaultVisibleDateCalendarDateDeterministic initially visible month.
localestringExplicit BCP 47 locale, defaulting to theme context.
calendarstringOptional presentation calendar identifier.
namestringNative form name for the start/end ISO interval.
formstringOptional external form owner.
descriptionstringAssociated instructions.
errorstringAssociated app validation error.
placeholderstringEmpty endpoint placeholder.
requiredbooleanfalseMarks both endpoints required.
disabledbooleanfalseDisables interaction and projection.
readOnlybooleanfalseAllows inspection while rejecting changes.
Native Solid/HTML attributes remain available and are omitted from this authored-prop view.