Releases
Changelog
From CHANGELOG.md in the repo.
2.1.3
Docs and npm listing only. No runtime or API behavior changes.
Changed
- README trimmed for npm: short install, React / vanilla / CDN quick starts, and links to the docs site for props and per-framework guides.
- npm
descriptionrepositioned as framework-agnostic (React, vanilla, Web Components, Vue, Svelte, Angular, CDN) instead of React-first.
2.1.2
Added
- JSDoc on the public API so editors show docs for components, props, controllers, and framework helpers.
Changed
- Docs only. No runtime or API behavior changes.
2.1.1
Month/year navigation flicker fix for vanilla, CDN, and Web Component integrations.
Fixed
- Month/year flicker: vanilla
paint()reuses the open picker root instead of tearing down and remounting on every navigation emit (CDN, WC, Vue, Svelte, Angular). Enter animation runs only on first open (.ctp-entering). - Web Component remount thrashing: attribute/
valueupdates callhandle.update()when a handle already exists instead of destroy + recreate.
2.1.0
UX and API improvements for single and range pickers.
Changed
asStringdefault is now objects: omittingasStringreturnsDate/TimeValue/{ start, end: Date | null }. SetasString={true}for formatted strings. The one-time deprecation warning is removed.- Commit on selection: date-only overlays commit and close when a day is picked (no OK). Datetime and time overlays keep an OK button and commit on confirm. Clear and Close remain.
- Initial month respects bounds: when today is outside
minDate/maxDate(or past/future disables), the picker opens on the first or last selectable day. - Month/year drill-down resets on close: reopening always returns to the day grid at the committed value's month.
- Website landing page and SEO metadata updated for react date picker / date time picker discoverability.
- npm
descriptionandkeywordstuned for searches like “react date picker”, “datetime picker”, and “react date time picker”.
Added
DateTimeInputcalendar icon at the end of the field (override withicon, hide withicon={null}).DateTimeInputcustomInput: pass your own trigger element; ref/value/onClick are injected.DateTimeInputnoStyle: skip default input classes so you style viaclassName/inputClassName/style.
Fixed
- No day is pre-selected when the initial value is null, empty, or invalid on first open.
- Default calendar icon uses higher-contrast foreground color for better visibility.
- Month/year navigation (arrows and month/year grids) cannot move outside
minDate/maxDate/ past/future disable bounds. - Calendar month grid always renders 6 weeks so height stays stable when changing months.
Removed
- OK button from date-only and range overlay footers (selection commits immediately). Datetime and time overlays still show OK.
2.0.0
Framework-agnostic release: headless core, vanilla renderer, Web Components, CDN IIFE, and multi-framework entry points.
Breaking
- Package renamed from
react-calendar-timetouniversal-datetime-picker. Update install commands and import specifiers. - React peer dependencies are now
>= 18(React 17 no longer supported). - Custom elements renamed to
<datetime-picker>,<datetime-picker-input>, and<datetime-picker-range>(never published under the old tag names in a stable release).
Added
- Subpath exports:
./core,./vanilla,./wc,./vue,./svelte,./angular. - CDN / unpkg / jsDelivr IIFE bundle with auto-registration.
defineCustomElements({ prefix })for collision-safe tag names.- Angular helper
registerDateTimePickerElements()(registerCalendarTimeElementsremains as deprecated alias).
Changed
- React components use shared
PickerController/RangeControllerviauseSyncExternalStore. - React peers are optional when using vanilla, Web Components, or CDN only.
- Inline pickers no longer show the overlay Close button.
Migrating
See README section Migrating from react-calendar-time.
1.1.0
Hardening and UI modernization for the post-v1 feature set.
Layout
- Default
layout="combined"shows date and time together (no Date/Time tabs) layout="tabs"restores the classic Date | Time switcher- Date-only / time-only modes never show the mode badges
Popover
- Position with
position: fixedviewport coordinates - Live reposition on scroll / resize; measure real picker size
- Close on outside click (in addition to Escape)
- Stable live
anchorElfromDateTimeInput
Accessibility & correctness
- Calendar Home/End honor
weekStartsOn DateTimeRangekeyboard grid navigation, hover range preview, and live region hints- Controlled
value={null}clears draft state for single and range pickers - Optional
labelsprop for chrome strings
Locales
- Apply locale per instance without mutating global dayjs locale
- Localized month titles and day
aria-labels
UI
- Modern floating panel chrome (softer elevation, thinner borders)
- Expanded CSS tokens (
--ctp-fg,--ctp-focus,--ctp-z-index, …) - Dark theme via
[data-ctp-theme="dark"](portaled pickers inherit from input ancestors orthemeprop) :focus-visiblerings and reduced-motion-aware open animation- Neutral input border with primary focus ring
- Default combined date+time layout; optional
layout="tabs"separate view
Docs / demos
- README coverage for labels, layout, 12h format pairing, popover, dark theme
- Expanded Storybook stories and website examples
1.0.0
Breaking rewrite of the library for production use.
Packaging
- Ship compiled ESM + CJS + TypeScript declarations via
tsup - Publish only
dist/with a properexportsmap - Move
react/react-domto peer dependencies - Replace Moment with
dayjs - Ship plain CSS (
react-calendar-time/style.css): consumers no longer need Sass - Package renamed from
react-datetime-picker-componenttoreact-calendar-time
API
- Replace
onClickwithonChange - Add controlled / uncontrolled
valueandopen - Replace
onlyDate/onlyTimewithmode: "datetime" | "date" | "time" - Replace
notFixedPositionwithinline - Rename
disableFuturedate/disablePastdate→disableFutureDates/disablePastDates - Add
minDate,maxDate,format,className,weekStartsOn,use12Hours,locale - Add
DateTime.Input/DateTimeInputwith popover positioning - Add
DateTime.Range/DateTimeRangefor range selection
Correctness
- Fix last day of month not selectable
- Fix selection highlight matching day-of-month only
- Fix past/future disable ignoring year
- Remove self-updating
useEffecton the selected value - Parse/format dates with dayjs (no unreliable
new Date(string)) - Remove duplicate DOM ids, debug
console.logs, and unstable keys
Accessibility
- Dialog semantics, Escape / backdrop dismiss, focus trap
- Calendar grid with arrow-key navigation
- Accessible names on controls and day cells
Tooling
- Vitest + Testing Library
- ESLint + Prettier
- GitHub Actions CI
- Storybook + Vite playground