Repository navigation
feat(react-headless-components-preview): implement DatePicker (blocked) - #36919
Closed
Dmytro Kirpa (dmytrokirpa) wants to merge 2 commits into
Closed
Dmytro Kirpa (dmytrokirpa) wants to merge 2 commits into
Dmytro Kirpa (dmytrokirpa) wants to merge 2 commits into
Conversation
…ntegration Record verified DatePicker base exports, existing headless Input support, the missing headless Calendar dependency, and requirements for the final headless DatePicker layer. Explicitly defer executable API, stories and packaging changes until the public headless Calendar contract is available. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Dmytro Kirpa (dmytrokirpa)
added this pull request to stack #36921
October 18, 2026 07:57
Compose shared date state with headless Input, pending Calendar, and native modal popup behavior. Keep Calendar prerequisite patches outside the DatePicker stack. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previous Behavior
There is no headless DatePicker. The DatePicker base hook supplies date state and popup requests,
but the styled renderer cannot provide an unstyled Input/Calendar integration.
New Behavior
DatePicker,useDatePicker,renderDatePicker, and related props/slots/stateand event types through
@fluentui/react-headless-components-preview/date-picker.text, required/boundary/restricted-date validation, formatting/parsing, and callback semantics.
Field associations, consumer cancellation/slot refs, keyboard navigation, and month/year switching.
top-layer rendering, inert outside content, dismissal, and focus restoration. No styled fallback,
default icons, Griffel styles, Portal, or new Tabster behavior is introduced.
data-open,data-disabled, anddata-invalid.Native dialog state and DatePicker-owned selection/boundaries cannot be overridden by slot props.
public export map/API report, focused/all-components bundle fixtures, and a minor Beachball entry.
'' | undefined, without changingits runtime behavior.
Dependencies and intentional exclusions
Blocked draft: this is now an implementation, not the former documentation-only placeholder.
It was developed and validated against pending headless Calendar
#36752 (
4a32a0ca54dd2709e84ee2cc6343612e64ddfeac) and standalone Calendar#36917 (
ba6a0e9db7).Those prerequisite sources, stories, exports, generated Calendar API report, and change files are
not committed in this PR. A clean checkout of this stack is not expected to build until the
prerequisites merge and the stack is rebased. Calendar remains outside the DatePicker GitHub stack.
This PR follows public-preview publication #36918; it does not duplicate that PR.
The native dialog intentionally excludes
mountNodeandinlinePopup. Native dialog/CSS-anchorsupport and native focusgroup support (or an application-supplied focusgroup polyfill) are required.
For editable inputs,
openOnClick={false}permits typing without opening a modal; the trigger andEnter/ArrowDown remain available. Callers own styling and visual accessibility.
Validation
All runtime/build evidence below was collected with the exact temporary prerequisites present.
They were removed before committing this PR.
NX_DAEMON=false yarn nx run react-headless-components-preview:test --runInBand --runTestsByPath src/components/DatePicker/DatePicker.test.tsx --skipNxCache— passed: 26 tests, including conformance/axe, selection, validation, canceled keyboard/pointer events, controlled requests, disabled state, refs, Field, and server rendering.NX_DAEMON=false yarn nx run react-headless-components-preview:e2e --excludeTaskDependencies --browser chrome --config retries=0 --spec src/components/DatePicker/DatePicker.cy.tsx --skipNxCache— passed: 10 Chrome tests, including focus return/no reopening, native modal inertness, backdrop/Escape, rejected controlled closes, iframe ownership, view switching, month-only selection, editable validation, and RTL.NX_DAEMON=false yarn nx run-many -t type-check -p react-headless-components-preview react-headless-components-preview-stories --excludeTaskDependencies --skipNxCache— passed.NX_DAEMON=false yarn nx run react-headless-components-preview:lint --command='yarn run -T eslint src/components/DatePicker src/date-picker.ts src/utils/toDataAttributeValue.ts' --skipNxCache— passed.NX_DAEMON=false yarn nx run react-headless-components-preview-stories:lint --command='yarn run -T eslint src/DatePicker' --skipNxCache— passed.NX_DAEMON=false yarn nx run react-headless-components-preview:build --excludeTaskDependencies --skipNxCache— passed: ESM/CommonJS, declarations, API extraction, and CJS declaration generation.NX_DAEMON=false yarn nx run react-headless-components-preview-stories:build-storybook --excludeTaskDependencies --skipNxCache— passed; existing Storybook asset-size warnings remain.NX_DAEMON=false yarn nx run react-headless-components-preview-stories:test-ssr --command='yarn run -T test-ssr ./src/DatePicker/**/*.stories.tsx' --skipNxCache— passed: all five stories, including an initially open native dialog, SSR and Chrome hydration.NX_DAEMON=false yarn nx run react-headless-components-preview:bundle-size --excludeTaskDependencies --command='yarn run -T monosize measure --fixtures DatePicker.fixture.js --debug' --skipNxCache— passed: 71.616 kB minified, 22.5 kB gzip. Debug bundle inspection found no Griffel/icons/Tabster runtime or styled Calendar/Input implementation.yarn workspace @fluentui/react-headless-components-preview pack --out /Users/dmytrokirpa/.copilot/session-state/c4c94c91-a3cc-4e00-b996-2ff82c856e61/files/react-headless-components-preview.tgz— passed; packed export targets, rewritten workspace ranges, and ESM/CommonJS APIs passed the session smoke script.yarn beachball change --package @fluentui/react-headless-components-preview --scope packages/react-components/react-headless-components-preview/library --since HEAD --no-fetch --no-commit --type minor --message 'Add an unstyled DatePicker with shared date validation, headless Calendar composition, and native modal-dialog behavior.'— passed; package-scoped change file included.Manual VoiceOver/NVDA/JAWS checks, full browser/zoom acceptance, and CI visual approval remain
pending. Headless React 17/18 integration runs have not been performed in this change. Nothing
has been merged or published to npm.
Related Issue(s)