@carbon/react 1.113.0 → 1.114.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/.playwright/INTERNAL_AVT_REPORT_DO_NOT_USE.json +901 -901
  2. package/es/components/DatePicker/DatePicker.d.ts +10 -0
  3. package/es/components/DatePicker/DatePicker.js +6 -5
  4. package/es/components/DatePicker/next/components/Calendar.d.ts +40 -0
  5. package/es/components/DatePicker/next/components/Calendar.js +181 -0
  6. package/es/components/DatePicker/next/components/DatePicker.d.ts +86 -0
  7. package/es/components/DatePicker/next/components/DatePicker.js +147 -0
  8. package/es/components/DatePicker/next/components/DatePickerInput.d.ts +143 -0
  9. package/es/components/DatePicker/next/components/DatePickerInput.js +124 -0
  10. package/es/components/DatePicker/next/components/DatePickerSkeleton.d.ts +22 -0
  11. package/es/components/DatePicker/next/components/DatePickerSkeleton.js +32 -0
  12. package/es/components/DatePicker/next/hooks/useDatePicker.d.ts +144 -0
  13. package/es/components/DatePicker/next/hooks/useDatePicker.js +286 -0
  14. package/es/components/DatePicker/next/index.d.ts +12 -0
  15. package/es/components/DatePicker/next/index.js +19 -0
  16. package/es/index.d.ts +1 -0
  17. package/es/index.js +2 -1
  18. package/es/internal/checkForOverflow.d.ts +5 -0
  19. package/es/internal/useFocus.d.ts +23 -0
  20. package/es/internal/usePrefersReducedMotion.d.ts +11 -0
  21. package/es/internal/useSidePanelPresence.d.ts +21 -0
  22. package/lib/components/DatePicker/DatePicker.d.ts +10 -0
  23. package/lib/components/DatePicker/DatePicker.js +6 -5
  24. package/lib/components/DatePicker/next/components/Calendar.d.ts +40 -0
  25. package/lib/components/DatePicker/next/components/Calendar.js +184 -0
  26. package/lib/components/DatePicker/next/components/DatePicker.d.ts +86 -0
  27. package/lib/components/DatePicker/next/components/DatePicker.js +150 -0
  28. package/lib/components/DatePicker/next/components/DatePickerInput.d.ts +143 -0
  29. package/lib/components/DatePicker/next/components/DatePickerInput.js +127 -0
  30. package/lib/components/DatePicker/next/components/DatePickerSkeleton.d.ts +22 -0
  31. package/lib/components/DatePicker/next/components/DatePickerSkeleton.js +41 -0
  32. package/lib/components/DatePicker/next/hooks/useDatePicker.d.ts +144 -0
  33. package/lib/components/DatePicker/next/hooks/useDatePicker.js +286 -0
  34. package/lib/components/DatePicker/next/index.d.ts +12 -0
  35. package/lib/components/DatePicker/next/index.js +27 -0
  36. package/lib/index.d.ts +1 -0
  37. package/lib/index.js +29 -22
  38. package/lib/internal/checkForOverflow.d.ts +5 -0
  39. package/lib/internal/useFocus.d.ts +23 -0
  40. package/lib/internal/usePrefersReducedMotion.d.ts +11 -0
  41. package/lib/internal/useSidePanelPresence.d.ts +21 -0
  42. package/package.json +11 -11
  43. package/scss/components/action-set/_action-set.scss +9 -0
  44. package/scss/components/action-set/_index.scss +9 -0
  45. package/scss/components/resizer/_index.scss +9 -0
  46. package/scss/components/resizer/_resizer.scss +9 -0
  47. package/scss/components/side-panel/_index.scss +9 -0
  48. package/scss/components/side-panel/_side-panel.scss +9 -0
  49. package/scss/components/truncated-text/_index.scss +9 -0
  50. package/scss/components/truncated-text/_truncated-text.scss +9 -0
  51. package/telemetry.yml +41 -1
package/es/index.js CHANGED
@@ -98,6 +98,7 @@ import DataTableSkeleton from "./components/DataTableSkeleton/DataTableSkeleton.
98
98
  import DatePickerInput from "./components/DatePickerInput/DatePickerInput.js";
99
99
  import DatePicker from "./components/DatePicker/DatePicker.js";
100
100
  import { DatePickerSkeleton } from "./components/DatePicker/DatePicker.Skeleton.js";
101
+ import { next_exports } from "./components/DatePicker/next/index.js";
101
102
  import Dropdown from "./components/Dropdown/Dropdown.js";
102
103
  import { DropdownSkeleton } from "./components/Dropdown/Dropdown.Skeleton.js";
103
104
  import { ErrorBoundaryContext } from "./components/ErrorBoundary/ErrorBoundaryContext.js";
@@ -250,4 +251,4 @@ import { GlobalTheme, Theme, ThemeContext, usePrefersDarkScheme, useTheme } from
250
251
  * LICENSE file in the root directory of this source tree.
251
252
  */
252
253
  //#endregion
253
- export { AILabel, AILabelActions, AILabelContent, AISkeletonIcon, AISkeletonPlaceholder, AISkeletonText, Accordion, AccordionItem, AccordionSkeleton, ActionableNotification, AspectRatio, Breadcrumb, BreadcrumbItem, BreadcrumbSkeleton, Button, ButtonKinds, ButtonSet, ButtonSizes, ButtonSkeleton, ButtonTooltipAlignments, ButtonTooltipPositions, Callout, Checkbox, CheckboxGroup, CheckboxSkeleton, ClassPrefix, ClickableTile, CodeSnippet, CodeSnippetSkeleton, Column, ColumnHangComponent as ColumnHang, ComboBox, ComboButton, ComposedModal, ComposedModalPresence, ContainedList, ContainedListItem_default as ContainedListItem, Content, ContentSwitcher, ControlledPasswordInput, Copy, CopyButton, DangerButton, DataTable, DataTableSkeleton, DatePicker, DatePickerInput, DatePickerSkeleton, DefinitionTooltip, DismissibleTag, Dropdown, DropdownSkeleton, ErrorBoundary, ErrorBoundaryContext, ExpandableSearch, ExpandableTile, FeatureFlags, FileUploader, FileUploaderButton, FileUploaderDropContainer, FileUploaderItem, FileUploaderSkeleton, Filename, FilterableMultiSelect, FlexGridComponent as FlexGrid, FluidComboBox, FluidComboBoxSkeleton, FluidDatePicker, FluidDatePickerInput, FluidDatePickerSkeleton, FluidDropdown, FluidDropdownSkeleton, FluidForm, FluidMultiSelect, FluidMultiSelectSkeleton, FluidNumberInput, FluidNumberInputSkeleton, FluidPasswordInput, FluidSearch, FluidSearchSkeleton, FluidSelect, FluidSelectSkeleton, FluidTextArea, FluidTextAreaSkeleton, FluidTextInput, FluidTextInputSkeleton, FluidTimePicker, FluidTimePickerSelect, FluidTimePickerSkeleton, Form, FormContext, FormGroup, FormItem, FormLabel, GlobalTheme, GridAsGridComponent as Grid, GridSettings, HStack, Header, HeaderContainer, HeaderGlobalAction, HeaderGlobalBar, HeaderMenu, HeaderMenuButton, HeaderMenuItem, HeaderName, HeaderNavigation, HeaderPanel, HeaderSideNavItems, Heading, IconButton, IconButtonKinds, IconSkeleton, IconSwitch, IconTab, IdPrefix, InlineCheckbox, InlineLoading, InlineNotification, Layer, Link, ListItem, Loading, Menu, MenuButton, MenuItem, MenuItemDivider, MenuItemGroup, MenuItemRadioGroup, MenuItemSelectable, Modal, ModalBody, ModalFooter, ModalHeader, ModalPresence, ModalWrapper, MultiSelect, NotificationActionButton, NotificationButton, NumberInput, NumberInputSkeleton, OperationalTag, OrderedList, OverflowMenu, OverflowMenuItem, Pagination, PaginationNav, PaginationSkeleton, PasswordInput, Popover, PopoverContent, PrefixContext, PrimaryButton, ProgressBar, ProgressIndicator, ProgressIndicatorSkeleton, ProgressStep, RadioButton, RadioButtonGroup, RadioButtonSkeleton, RadioTile, Row, Search, SearchSkeleton, SecondaryButton, Section, Select, SelectItem, SelectItemGroup, SelectSkeleton, SelectableTag, SelectableTile, SideNav, SideNavDetails, SideNavDivider, SideNavFooter, SideNavHeader, SideNavIcon, SideNavItem, SideNavItems, SideNavLink, SideNavLinkText, SideNavMenu, SideNavMenuItem, SideNavSwitcher, SkeletonIcon, SkeletonPlaceholder, SkeletonText, SkipToContent, Slider, SliderSkeleton, Stack, StaticNotification, StructuredListBody, StructuredListCell, StructuredListHead, StructuredListInput, StructuredListRow, StructuredListSkeleton, StructuredListWrapper, Switch, Switcher, SwitcherDivider, SwitcherItem, Tab, TabContent, TabList, TabListVertical, TabPanel, TabPanels, Table, TableActionList, TableBatchAction, TableBatchActions, TableBody, TableCell, TableContainer, TableDecoratorRow, TableExpandHeader, TableExpandRow, TableExpandedRow, TableHead, TableHeader, TableRow, TableSelectAll, TableSelectRow, TableSlugRow, TableToolbar, TableToolbarAction, TableToolbarContent, TableToolbarMenu, TableToolbarSearch, Tabs, TabsSkeleton, TabsVertical, Tag, TagSkeleton, TextArea, TextAreaSkeleton, TextInput, TextInputSkeleton, Theme, ThemeContext, Tile, TileAboveTheFoldContent, TileBelowTheFoldContent, TileGroup, TimePicker, TimePickerSelect, ToastNotification, Toggle, ToggleSkeleton, ToggleSmallSkeleton, Toggletip, ToggletipActions, ToggletipButton, ToggletipContent, ToggletipLabel, Tooltip, TreeNode, TreeView, UnorderedList, VStack, FeatureFlags as preview_FeatureFlags, Layout as preview_Layout, LayoutDirection as preview_LayoutDirection, OverflowMenuV2 as preview_OverflowMenuV2, PageSelector as preview_PageSelector, Pagination$1 as preview_Pagination, Text as preview_Text, TextDirection as preview_TextDirection, AISkeletonIcon as preview__AiSkeletonIcon, AISkeletonPlaceholder as preview__AiSkeletonPlaceholder, AISkeletonText as preview__AiSkeletonText, ChatButton as preview__ChatButton, ChatButtonSkeleton as preview__ChatButtonSkeleton, Dialog_exports as preview__Dialog, FluidComboBox as preview__FluidComboBox, FluidComboBoxSkeleton as preview__FluidComboBoxSkeleton, FluidDatePicker as preview__FluidDatePicker, FluidDatePickerInput as preview__FluidDatePickerInput, FluidDatePickerSkeleton as preview__FluidDatePickerSkeleton, FluidDropdown as preview__FluidDropdown, FluidDropdownSkeleton as preview__FluidDropdownSkeleton, FluidMultiSelect as preview__FluidMultiSelect, FluidMultiSelectSkeleton as preview__FluidMultiSelectSkeleton, FluidNumberInput as preview__FluidNumberInput, FluidNumberInputSkeleton as preview__FluidNumberInputSkeleton, FluidSearch as preview__FluidSearch, FluidSearchSkeleton as preview__FluidSearchSkeleton, FluidSelect as preview__FluidSelect, FluidSelectSkeleton as preview__FluidSelectSkeleton, FluidTextArea as preview__FluidTextArea, FluidTextAreaSkeleton as preview__FluidTextAreaSkeleton, FluidTextInput as preview__FluidTextInput, FluidTextInputSkeleton as preview__FluidTextInputSkeleton, FluidTimePicker as preview__FluidTimePicker, FluidTimePickerSelect as preview__FluidTimePickerSelect, FluidTimePickerSkeleton as preview__FluidTimePickerSkeleton, IconIndicator as preview__IconIndicator, PageHeader_exports as preview__PageHeader, ShapeIndicator as preview__ShapeIndicator, AILabel as preview__Slug, AILabelActions as preview__SlugActions, AILabelContent as preview__SlugContent, useFeatureFlag as preview_useFeatureFlag, useFeatureFlags as preview_useFeatureFlags, useLayoutDirection as preview_useLayoutDirection, FeatureFlags as unstable_FeatureFlags, Layout as unstable_Layout, LayoutDirection as unstable_LayoutDirection, OverflowMenuV2 as unstable_OverflowMenuV2, PageSelector as unstable_PageSelector, Pagination$1 as unstable_Pagination, Text as unstable_Text, TextDirection as unstable_TextDirection, AISkeletonIcon as unstable__AiSkeletonIcon, AISkeletonPlaceholder as unstable__AiSkeletonPlaceholder, AISkeletonText as unstable__AiSkeletonText, ChatButton as unstable__ChatButton, ChatButtonSkeleton as unstable__ChatButtonSkeleton, FluidComboBox as unstable__FluidComboBox, FluidComboBoxSkeleton as unstable__FluidComboBoxSkeleton, FluidDatePicker as unstable__FluidDatePicker, FluidDatePickerInput as unstable__FluidDatePickerInput, FluidDatePickerSkeleton as unstable__FluidDatePickerSkeleton, FluidDropdown as unstable__FluidDropdown, FluidDropdownSkeleton as unstable__FluidDropdownSkeleton, FluidMultiSelect as unstable__FluidMultiSelect, FluidMultiSelectSkeleton as unstable__FluidMultiSelectSkeleton, FluidNumberInput as unstable__FluidNumberInput, FluidNumberInputSkeleton as unstable__FluidNumberInputSkeleton, FluidSearch as unstable__FluidSearch, FluidSearchSkeleton as unstable__FluidSearchSkeleton, FluidSelect as unstable__FluidSelect, FluidSelectSkeleton as unstable__FluidSelectSkeleton, FluidTextArea as unstable__FluidTextArea, FluidTextAreaSkeleton as unstable__FluidTextAreaSkeleton, FluidTextInput as unstable__FluidTextInput, FluidTextInputSkeleton as unstable__FluidTextInputSkeleton, FluidTimePicker as unstable__FluidTimePicker, FluidTimePickerSelect as unstable__FluidTimePickerSelect, FluidTimePickerSkeleton as unstable__FluidTimePickerSkeleton, IconIndicator as unstable__IconIndicator, PageHeader_exports as unstable__PageHeader, ShapeIndicator as unstable__ShapeIndicator, AILabel as unstable__Slug, AILabelActions as unstable__SlugActions, AILabelContent as unstable__SlugContent, useFeatureFlag as unstable_useFeatureFlag, useFeatureFlags as unstable_useFeatureFlags, useLayoutDirection as unstable_useLayoutDirection, useContextMenu, useFeatureFlag, useFeatureFlags, useIdPrefix, useLayer, usePrefersDarkScheme, usePrefix, useTheme, validateNumberSeparators, withComposedModalPresence, withModalPresence };
254
+ export { AILabel, AILabelActions, AILabelContent, AISkeletonIcon, AISkeletonPlaceholder, AISkeletonText, Accordion, AccordionItem, AccordionSkeleton, ActionableNotification, AspectRatio, Breadcrumb, BreadcrumbItem, BreadcrumbSkeleton, Button, ButtonKinds, ButtonSet, ButtonSizes, ButtonSkeleton, ButtonTooltipAlignments, ButtonTooltipPositions, Callout, Checkbox, CheckboxGroup, CheckboxSkeleton, ClassPrefix, ClickableTile, CodeSnippet, CodeSnippetSkeleton, Column, ColumnHangComponent as ColumnHang, ComboBox, ComboButton, ComposedModal, ComposedModalPresence, ContainedList, ContainedListItem_default as ContainedListItem, Content, ContentSwitcher, ControlledPasswordInput, Copy, CopyButton, DangerButton, DataTable, DataTableSkeleton, DatePicker, DatePickerInput, DatePickerSkeleton, DefinitionTooltip, DismissibleTag, Dropdown, DropdownSkeleton, ErrorBoundary, ErrorBoundaryContext, ExpandableSearch, ExpandableTile, FeatureFlags, FileUploader, FileUploaderButton, FileUploaderDropContainer, FileUploaderItem, FileUploaderSkeleton, Filename, FilterableMultiSelect, FlexGridComponent as FlexGrid, FluidComboBox, FluidComboBoxSkeleton, FluidDatePicker, FluidDatePickerInput, FluidDatePickerSkeleton, FluidDropdown, FluidDropdownSkeleton, FluidForm, FluidMultiSelect, FluidMultiSelectSkeleton, FluidNumberInput, FluidNumberInputSkeleton, FluidPasswordInput, FluidSearch, FluidSearchSkeleton, FluidSelect, FluidSelectSkeleton, FluidTextArea, FluidTextAreaSkeleton, FluidTextInput, FluidTextInputSkeleton, FluidTimePicker, FluidTimePickerSelect, FluidTimePickerSkeleton, Form, FormContext, FormGroup, FormItem, FormLabel, GlobalTheme, GridAsGridComponent as Grid, GridSettings, HStack, Header, HeaderContainer, HeaderGlobalAction, HeaderGlobalBar, HeaderMenu, HeaderMenuButton, HeaderMenuItem, HeaderName, HeaderNavigation, HeaderPanel, HeaderSideNavItems, Heading, IconButton, IconButtonKinds, IconSkeleton, IconSwitch, IconTab, IdPrefix, InlineCheckbox, InlineLoading, InlineNotification, Layer, Link, ListItem, Loading, Menu, MenuButton, MenuItem, MenuItemDivider, MenuItemGroup, MenuItemRadioGroup, MenuItemSelectable, Modal, ModalBody, ModalFooter, ModalHeader, ModalPresence, ModalWrapper, MultiSelect, NotificationActionButton, NotificationButton, NumberInput, NumberInputSkeleton, OperationalTag, OrderedList, OverflowMenu, OverflowMenuItem, Pagination, PaginationNav, PaginationSkeleton, PasswordInput, Popover, PopoverContent, PrefixContext, PrimaryButton, ProgressBar, ProgressIndicator, ProgressIndicatorSkeleton, ProgressStep, RadioButton, RadioButtonGroup, RadioButtonSkeleton, RadioTile, Row, Search, SearchSkeleton, SecondaryButton, Section, Select, SelectItem, SelectItemGroup, SelectSkeleton, SelectableTag, SelectableTile, SideNav, SideNavDetails, SideNavDivider, SideNavFooter, SideNavHeader, SideNavIcon, SideNavItem, SideNavItems, SideNavLink, SideNavLinkText, SideNavMenu, SideNavMenuItem, SideNavSwitcher, SkeletonIcon, SkeletonPlaceholder, SkeletonText, SkipToContent, Slider, SliderSkeleton, Stack, StaticNotification, StructuredListBody, StructuredListCell, StructuredListHead, StructuredListInput, StructuredListRow, StructuredListSkeleton, StructuredListWrapper, Switch, Switcher, SwitcherDivider, SwitcherItem, Tab, TabContent, TabList, TabListVertical, TabPanel, TabPanels, Table, TableActionList, TableBatchAction, TableBatchActions, TableBody, TableCell, TableContainer, TableDecoratorRow, TableExpandHeader, TableExpandRow, TableExpandedRow, TableHead, TableHeader, TableRow, TableSelectAll, TableSelectRow, TableSlugRow, TableToolbar, TableToolbarAction, TableToolbarContent, TableToolbarMenu, TableToolbarSearch, Tabs, TabsSkeleton, TabsVertical, Tag, TagSkeleton, TextArea, TextAreaSkeleton, TextInput, TextInputSkeleton, Theme, ThemeContext, Tile, TileAboveTheFoldContent, TileBelowTheFoldContent, TileGroup, TimePicker, TimePickerSelect, ToastNotification, Toggle, ToggleSkeleton, ToggleSmallSkeleton, Toggletip, ToggletipActions, ToggletipButton, ToggletipContent, ToggletipLabel, Tooltip, TreeNode, TreeView, UnorderedList, VStack, FeatureFlags as preview_FeatureFlags, Layout as preview_Layout, LayoutDirection as preview_LayoutDirection, OverflowMenuV2 as preview_OverflowMenuV2, PageSelector as preview_PageSelector, Pagination$1 as preview_Pagination, Text as preview_Text, TextDirection as preview_TextDirection, AISkeletonIcon as preview__AiSkeletonIcon, AISkeletonPlaceholder as preview__AiSkeletonPlaceholder, AISkeletonText as preview__AiSkeletonText, ChatButton as preview__ChatButton, ChatButtonSkeleton as preview__ChatButtonSkeleton, next_exports as preview__DatePicker, Dialog_exports as preview__Dialog, FluidComboBox as preview__FluidComboBox, FluidComboBoxSkeleton as preview__FluidComboBoxSkeleton, FluidDatePicker as preview__FluidDatePicker, FluidDatePickerInput as preview__FluidDatePickerInput, FluidDatePickerSkeleton as preview__FluidDatePickerSkeleton, FluidDropdown as preview__FluidDropdown, FluidDropdownSkeleton as preview__FluidDropdownSkeleton, FluidMultiSelect as preview__FluidMultiSelect, FluidMultiSelectSkeleton as preview__FluidMultiSelectSkeleton, FluidNumberInput as preview__FluidNumberInput, FluidNumberInputSkeleton as preview__FluidNumberInputSkeleton, FluidSearch as preview__FluidSearch, FluidSearchSkeleton as preview__FluidSearchSkeleton, FluidSelect as preview__FluidSelect, FluidSelectSkeleton as preview__FluidSelectSkeleton, FluidTextArea as preview__FluidTextArea, FluidTextAreaSkeleton as preview__FluidTextAreaSkeleton, FluidTextInput as preview__FluidTextInput, FluidTextInputSkeleton as preview__FluidTextInputSkeleton, FluidTimePicker as preview__FluidTimePicker, FluidTimePickerSelect as preview__FluidTimePickerSelect, FluidTimePickerSkeleton as preview__FluidTimePickerSkeleton, IconIndicator as preview__IconIndicator, PageHeader_exports as preview__PageHeader, ShapeIndicator as preview__ShapeIndicator, AILabel as preview__Slug, AILabelActions as preview__SlugActions, AILabelContent as preview__SlugContent, useFeatureFlag as preview_useFeatureFlag, useFeatureFlags as preview_useFeatureFlags, useLayoutDirection as preview_useLayoutDirection, FeatureFlags as unstable_FeatureFlags, Layout as unstable_Layout, LayoutDirection as unstable_LayoutDirection, OverflowMenuV2 as unstable_OverflowMenuV2, PageSelector as unstable_PageSelector, Pagination$1 as unstable_Pagination, Text as unstable_Text, TextDirection as unstable_TextDirection, AISkeletonIcon as unstable__AiSkeletonIcon, AISkeletonPlaceholder as unstable__AiSkeletonPlaceholder, AISkeletonText as unstable__AiSkeletonText, ChatButton as unstable__ChatButton, ChatButtonSkeleton as unstable__ChatButtonSkeleton, FluidComboBox as unstable__FluidComboBox, FluidComboBoxSkeleton as unstable__FluidComboBoxSkeleton, FluidDatePicker as unstable__FluidDatePicker, FluidDatePickerInput as unstable__FluidDatePickerInput, FluidDatePickerSkeleton as unstable__FluidDatePickerSkeleton, FluidDropdown as unstable__FluidDropdown, FluidDropdownSkeleton as unstable__FluidDropdownSkeleton, FluidMultiSelect as unstable__FluidMultiSelect, FluidMultiSelectSkeleton as unstable__FluidMultiSelectSkeleton, FluidNumberInput as unstable__FluidNumberInput, FluidNumberInputSkeleton as unstable__FluidNumberInputSkeleton, FluidSearch as unstable__FluidSearch, FluidSearchSkeleton as unstable__FluidSearchSkeleton, FluidSelect as unstable__FluidSelect, FluidSelectSkeleton as unstable__FluidSelectSkeleton, FluidTextArea as unstable__FluidTextArea, FluidTextAreaSkeleton as unstable__FluidTextAreaSkeleton, FluidTextInput as unstable__FluidTextInput, FluidTextInputSkeleton as unstable__FluidTextInputSkeleton, FluidTimePicker as unstable__FluidTimePicker, FluidTimePickerSelect as unstable__FluidTimePickerSelect, FluidTimePickerSkeleton as unstable__FluidTimePickerSkeleton, IconIndicator as unstable__IconIndicator, PageHeader_exports as unstable__PageHeader, ShapeIndicator as unstable__ShapeIndicator, AILabel as unstable__Slug, AILabelActions as unstable__SlugActions, AILabelContent as unstable__SlugContent, useFeatureFlag as unstable_useFeatureFlag, useFeatureFlags as unstable_useFeatureFlags, useLayoutDirection as unstable_useLayoutDirection, useContextMenu, useFeatureFlag, useFeatureFlags, useIdPrefix, useLayer, usePrefersDarkScheme, usePrefix, useTheme, validateNumberSeparators, withComposedModalPresence, withModalPresence };
@@ -0,0 +1,5 @@
1
+ /**
2
+ * used to calculate if a element is overflowing the width or height of an area
3
+ */
4
+ export declare const checkWidthOverflow: (el: HTMLElement | null) => boolean;
5
+ export declare const checkHeightOverflow: (el: HTMLElement | null) => boolean;
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Copyright IBM Corp. 2021, 2025
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import { RefObject } from 'react';
8
+ /**
9
+ * Returns the first element matching `selector` within `container`, or null.
10
+ TO DO: This hook will be removed https://github.com/carbon-design-system/ibm-products/issues/7731
11
+ */
12
+ export declare const getSpecificElement: (container: HTMLElement | null, selector: string) => HTMLElement | null;
13
+ /**
14
+ * Provides focus-trap helpers for a panel/modal container.
15
+ *
16
+ * - `firstElement` – the first tabbable element inside the container.
17
+ * - `keyDownListener` – an `onKeyDown` handler that cycles focus between the
18
+ * first and last tabbable elements (Tab / Shift+Tab wrap-around).
19
+ */
20
+ export declare const useFocus: (ref: RefObject<HTMLElement | null>) => {
21
+ firstElement: HTMLElement | null;
22
+ keyDownListener: (event: React.KeyboardEvent | KeyboardEvent) => void;
23
+ };
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Copyright IBM Corp. 2021, 2025
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /**
8
+ * Returns `true` when the user has requested reduced motion via the
9
+ * `prefers-reduced-motion: reduce` media query.
10
+ */
11
+ export declare const usePrefersReducedMotion: () => boolean;
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Copyright IBM Corp. 2021, 2025
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import { RefObject } from 'react';
8
+ /**
9
+ * Controls the presence (mount/unmount) of a panel element, waiting for a
10
+ * named CSS exit animation to finish before removing it from the DOM.
11
+ *
12
+ * Signature mirrors the `usePresence` hook from `@carbon/ibm-products`:
13
+ * `usePresence(open, ref, exitAnimationName)` → `{ shouldRender }`
14
+ *
15
+ * @param open - Whether the panel is currently open.
16
+ * @param ref - Ref to the panel's root DOM element.
17
+ * @param exitAnimationName - The CSS `animation-name` value used on exit.
18
+ */
19
+ export declare const useSidePanelPresence: (open: boolean, ref: RefObject<HTMLElement | null>, exitAnimationName: string) => {
20
+ shouldRender: boolean;
21
+ };
@@ -19,6 +19,8 @@ export interface DatePickerProps {
19
19
  allowInput?: boolean;
20
20
  /**
21
21
  * The DOM element the flatpickr should be inserted into `<body>` by default.
22
+ *
23
+ * @deprecated This prop will be removed in the next major release, please see `preview__DatePicker` which does not flatpickr.
22
24
  */
23
25
  appendTo?: HTMLElement;
24
26
  /**
@@ -47,14 +49,20 @@ export interface DatePickerProps {
47
49
  datePickerType?: DatePickerTypes;
48
50
  /**
49
51
  * The flatpickr `disable` option that allows a user to disable certain dates.
52
+ *
53
+ * @deprecated This prop will be removed in the next major release, please see `preview__DatePicker` which does not flatpickr
50
54
  */
51
55
  disable?: DateLimit<DateOption>[];
52
56
  /**
53
57
  * The flatpickr `enable` option that allows a user to enable certain dates.
58
+ *
59
+ * @deprecated This prop will be removed in the next major release, please see `preview__DatePicker` which does not flatpickr
54
60
  */
55
61
  enable?: DateLimit<DateOption>[];
56
62
  /**
57
63
  * The flatpickr `inline` option.
64
+ *
65
+ * @deprecated This prop will be removed in the next major release, please see `preview__DatePicker` which does not flatpickr
58
66
  */
59
67
  inline?: boolean;
60
68
  /**
@@ -91,6 +99,8 @@ export interface DatePickerProps {
91
99
  onOpen?: flatpickr.Options.Hook;
92
100
  /**
93
101
  * flatpickr prop passthrough. Controls how dates are parsed.
102
+ *
103
+ * @deprecated This prop will be removed in the next major release, please see `preview__DatePicker` which does not flatpickr
94
104
  */
95
105
  parseDate?: (date: string) => Date | false;
96
106
  /**
@@ -46,6 +46,7 @@ function initializeWeekdayShorthand() {
46
46
  }
47
47
  const forEach = Array.prototype.forEach;
48
48
  const defaultAriaDateFormat = "l, F j, Y";
49
+ const flatpickrDeprecation = (prop) => `The \`${prop}\` prop is deprecated and will be removed in the next major release. Please use the new \`preview__DatePicker\` component which doesn't use it — if that blocks you, tell us why: https://github.com/carbon-design-system/carbon/issues.`;
49
50
  /**
50
51
  * @param {number} monthNumber The month number.
51
52
  * @param {boolean} shorthand `true` to use shorthand month.
@@ -461,7 +462,7 @@ DatePicker.propTypes = {
461
462
  /**
462
463
  * The DOM element the Flatpicker should be inserted into. `<body>` by default.
463
464
  */
464
- appendTo: prop_types.default.object,
465
+ appendTo: require_deprecate.deprecate(prop_types.default.object, flatpickrDeprecation("appendTo")),
465
466
  /**
466
467
  * The child nodes.
467
468
  */
@@ -493,15 +494,15 @@ DatePicker.propTypes = {
493
494
  /**
494
495
  * The flatpickr `disable` option that allows a user to disable certain dates.
495
496
  */
496
- disable: prop_types.default.array,
497
+ disable: require_deprecate.deprecate(prop_types.default.array, flatpickrDeprecation("disable")),
497
498
  /**
498
499
  * The flatpickr `enable` option that allows a user to enable certain dates.
499
500
  */
500
- enable: prop_types.default.array,
501
+ enable: require_deprecate.deprecate(prop_types.default.array, flatpickrDeprecation("enable")),
501
502
  /**
502
503
  * The flatpickr `inline` option.
503
504
  */
504
- inline: prop_types.default.bool,
505
+ inline: require_deprecate.deprecate(prop_types.default.bool, flatpickrDeprecation("inline")),
505
506
  /**
506
507
  * Specify whether or not the control is invalid (Fluid only)
507
508
  */
@@ -540,7 +541,7 @@ DatePicker.propTypes = {
540
541
  /**
541
542
  * flatpickr prop passthrough. Controls how dates are parsed.
542
543
  */
543
- parseDate: prop_types.default.func,
544
+ parseDate: require_deprecate.deprecate(prop_types.default.func, flatpickrDeprecation("parseDate")),
544
545
  /**
545
546
  * whether the DatePicker is to be readOnly
546
547
  * if boolean applies to all inputs
@@ -0,0 +1,40 @@
1
+ /**
2
+ * Copyright IBM Corp. 2026
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import type { DatePickerContext } from '@carbon/utilities/date-picker';
8
+ /**
9
+ * Calendar component props
10
+ */
11
+ export interface CalendarProps {
12
+ /**
13
+ * State machine context
14
+ */
15
+ context: DatePickerContext;
16
+ /**
17
+ * Date selection handler
18
+ */
19
+ onDateSelect: (date: Temporal.PlainDate) => void;
20
+ /**
21
+ * Navigation handler
22
+ */
23
+ onNavigate: (eventType: string) => void;
24
+ /**
25
+ * Additional CSS class names
26
+ */
27
+ className?: string;
28
+ /**
29
+ * BCP 47 locale tag used to localize month and weekday labels
30
+ */
31
+ locale?: string;
32
+ }
33
+ /**
34
+ * Calendar component
35
+ * Renders a calendar grid for date selection
36
+ */
37
+ export declare function Calendar({ context, onDateSelect, onNavigate, className, locale, }: CalendarProps): import("react/jsx-runtime").JSX.Element | null;
38
+ export declare namespace Calendar {
39
+ var displayName: string;
40
+ }
@@ -0,0 +1,184 @@
1
+ /**
2
+ * Copyright IBM Corp. 2016, 2026
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+ const require_runtime = require("../../../../_virtual/_rolldown/runtime.js");
9
+ const require_usePrefix = require("../../../../internal/usePrefix.js");
10
+ let react = require("react");
11
+ react = require_runtime.__toESM(react);
12
+ let classnames = require("classnames");
13
+ classnames = require_runtime.__toESM(classnames);
14
+ let react_jsx_runtime = require("react/jsx-runtime");
15
+ let _carbon_utilities_date_picker = require("@carbon/utilities/date-picker");
16
+ //#region src/components/DatePicker/next/components/Calendar.tsx
17
+ /**
18
+ * Copyright IBM Corp. 2026
19
+ *
20
+ * This source code is licensed under the Apache-2.0 license found in the
21
+ * LICENSE file in the root directory of this source tree.
22
+ */
23
+ /**
24
+ * Calendar component
25
+ * Renders a calendar grid for date selection
26
+ */
27
+ function Calendar({ context, onDateSelect, onNavigate, className, locale = "en" }) {
28
+ const prefix = require_usePrefix.usePrefix();
29
+ const { viewDate, startDate, endDate, minDate, maxDate, focusedDate, mode } = context;
30
+ const [hoveredDate, setHoveredDate] = (0, react.useState)(null);
31
+ const calendarGrid = (0, react.useMemo)(() => {
32
+ if (!viewDate) return [];
33
+ return (0, _carbon_utilities_date_picker.generateCalendarGrid)(viewDate, minDate, maxDate);
34
+ }, [
35
+ viewDate,
36
+ minDate,
37
+ maxDate
38
+ ]);
39
+ const handlePrevMonth = (0, react.useCallback)(() => {
40
+ onNavigate("PREV_MONTH");
41
+ }, [onNavigate]);
42
+ const handleNextMonth = (0, react.useCallback)(() => {
43
+ onNavigate("NEXT_MONTH");
44
+ }, [onNavigate]);
45
+ const handleDateClick = (0, react.useCallback)((date, isDisabled) => {
46
+ if (!isDisabled) onDateSelect(date);
47
+ }, [onDateSelect]);
48
+ const isDateSelected = (0, react.useCallback)((date) => {
49
+ if (!startDate) return false;
50
+ if (Temporal.PlainDate.compare(date, startDate) === 0) return true;
51
+ if (endDate && Temporal.PlainDate.compare(date, endDate) === 0) return true;
52
+ return false;
53
+ }, [startDate, endDate]);
54
+ const isDateInRange = (0, react.useCallback)((date) => {
55
+ if (mode !== "range" || !startDate) return false;
56
+ if (endDate) return Temporal.PlainDate.compare(date, startDate) > 0 && Temporal.PlainDate.compare(date, endDate) < 0;
57
+ const previewDate = hoveredDate || focusedDate;
58
+ if (previewDate) {
59
+ if (minDate && Temporal.PlainDate.compare(previewDate, minDate) < 0 || maxDate && Temporal.PlainDate.compare(previewDate, maxDate) > 0) return false;
60
+ const earlierDate = Temporal.PlainDate.compare(startDate, previewDate) < 0 ? startDate : previewDate;
61
+ const laterDate = Temporal.PlainDate.compare(startDate, previewDate) < 0 ? previewDate : startDate;
62
+ return Temporal.PlainDate.compare(date, earlierDate) > 0 && Temporal.PlainDate.compare(date, laterDate) < 0;
63
+ }
64
+ return false;
65
+ }, [
66
+ mode,
67
+ startDate,
68
+ endDate,
69
+ hoveredDate,
70
+ focusedDate,
71
+ minDate,
72
+ maxDate
73
+ ]);
74
+ const isDateFocused = (0, react.useCallback)((date) => {
75
+ if (!focusedDate) return false;
76
+ return Temporal.PlainDate.compare(date, focusedDate) === 0;
77
+ }, [focusedDate]);
78
+ if (!viewDate) return null;
79
+ const calendarClasses = (0, classnames.default)(`${prefix}--date-picker__calendar`, className);
80
+ const monthYear = (0, _carbon_utilities_date_picker.getMonthYearLabel)(viewDate, locale);
81
+ const weekdayLabels = (0, _carbon_utilities_date_picker.getWeekdayLabels)(locale);
82
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
83
+ className: calendarClasses,
84
+ role: "grid",
85
+ "aria-label": "Calendar",
86
+ tabIndex: 0,
87
+ children: [
88
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
89
+ className: `${prefix}--date-picker__month`,
90
+ children: [
91
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
92
+ type: "button",
93
+ className: `${prefix}--date-picker__month-nav`,
94
+ onClick: handlePrevMonth,
95
+ "aria-label": "Previous month",
96
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
97
+ focusable: "false",
98
+ preserveAspectRatio: "xMidYMid meet",
99
+ xmlns: "http://www.w3.org/2000/svg",
100
+ fill: "currentColor",
101
+ width: "16",
102
+ height: "16",
103
+ viewBox: "0 0 16 16",
104
+ "aria-hidden": "true",
105
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
106
+ d: "M11 8l-5 5-.7-.7L9.6 8 5.3 3.7 6 3z",
107
+ transform: "rotate(180 8 8)"
108
+ })
109
+ })
110
+ }),
111
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
112
+ className: `${prefix}--date-picker__current-month`,
113
+ children: monthYear
114
+ }),
115
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
116
+ type: "button",
117
+ className: `${prefix}--date-picker__month-nav`,
118
+ onClick: handleNextMonth,
119
+ "aria-label": "Next month",
120
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
121
+ focusable: "false",
122
+ preserveAspectRatio: "xMidYMid meet",
123
+ xmlns: "http://www.w3.org/2000/svg",
124
+ fill: "currentColor",
125
+ width: "16",
126
+ height: "16",
127
+ viewBox: "0 0 16 16",
128
+ "aria-hidden": "true",
129
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", { d: "M11 8l-5 5-.7-.7L9.6 8 5.3 3.7 6 3z" })
130
+ })
131
+ })
132
+ ]
133
+ }),
134
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
135
+ className: `${prefix}--date-picker__weekdays`,
136
+ children: weekdayLabels.map((day, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
137
+ className: `${prefix}--date-picker__weekday`,
138
+ title: day,
139
+ children: day
140
+ }, index))
141
+ }),
142
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
143
+ className: `${prefix}--date-picker__days`,
144
+ children: calendarGrid.flat().map((dayCell, index) => {
145
+ const { date, isCurrentMonth, isDisabled, isToday } = dayCell;
146
+ const selected = isDateSelected(date);
147
+ const inRange = isDateInRange(date);
148
+ const focused = isDateFocused(date);
149
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
150
+ type: "button",
151
+ className: (0, classnames.default)(`${prefix}--date-picker__day`, {
152
+ today: isToday,
153
+ selected,
154
+ inRange,
155
+ prevMonthDay: !isCurrentMonth && date.month < viewDate.month,
156
+ nextMonthDay: !isCurrentMonth && date.month > viewDate.month,
157
+ disabled: isDisabled,
158
+ focused
159
+ }),
160
+ onMouseDown: (event) => {
161
+ event.preventDefault();
162
+ },
163
+ onMouseEnter: () => {
164
+ if (mode === "range" && startDate && !endDate) setHoveredDate(date);
165
+ },
166
+ onMouseLeave: () => {
167
+ setHoveredDate(null);
168
+ },
169
+ onClick: () => handleDateClick(date, isDisabled),
170
+ disabled: isDisabled,
171
+ "aria-label": (0, _carbon_utilities_date_picker.getFullDateLabel)(date, locale),
172
+ "aria-pressed": selected || void 0,
173
+ "aria-current": isToday ? "date" : void 0,
174
+ tabIndex: focused ? 0 : -1,
175
+ children: date.day
176
+ }, index);
177
+ })
178
+ })
179
+ ]
180
+ });
181
+ }
182
+ Calendar.displayName = "Calendar";
183
+ //#endregion
184
+ exports.Calendar = Calendar;
@@ -0,0 +1,86 @@
1
+ /**
2
+ * Copyright IBM Corp. 2026
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import React from 'react';
8
+ /**
9
+ * DatePicker component props
10
+ * Maintains 100% backwards compatibility with Carbon React v11 API
11
+ */
12
+ export interface DatePickerProps {
13
+ /**
14
+ * The type of date picker
15
+ */
16
+ datePickerType?: 'simple' | 'single' | 'range';
17
+ /**
18
+ * The date format string
19
+ */
20
+ dateFormat?: string;
21
+ /**
22
+ * Minimum selectable date (mm/dd/yyyy format)
23
+ */
24
+ minDate?: string;
25
+ /**
26
+ * Maximum selectable date (mm/dd/yyyy format)
27
+ */
28
+ maxDate?: string;
29
+ /**
30
+ * Locale for date formatting
31
+ */
32
+ locale?: string;
33
+ /**
34
+ * Whether the picker is read-only
35
+ */
36
+ readOnly?: boolean;
37
+ /**
38
+ * Whether to use the light variant
39
+ */
40
+ light?: boolean;
41
+ /**
42
+ * Whether to use the short variant
43
+ */
44
+ short?: boolean;
45
+ /**
46
+ * Whether to allow manual input
47
+ */
48
+ allowInput?: boolean;
49
+ /**
50
+ * Whether to close calendar on date selection
51
+ */
52
+ closeOnSelect?: boolean;
53
+ /**
54
+ * Change handler - receives array of Date objects
55
+ */
56
+ onChange?: (dates: Date[]) => void;
57
+ /**
58
+ * Close handler
59
+ */
60
+ onClose?: () => void;
61
+ /**
62
+ * Open handler
63
+ */
64
+ onOpen?: () => void;
65
+ /**
66
+ * Additional CSS class names
67
+ */
68
+ className?: string;
69
+ /**
70
+ * Children (DatePickerInput components)
71
+ */
72
+ children?: React.ReactNode;
73
+ /**
74
+ * Initial value
75
+ */
76
+ value?: string;
77
+ }
78
+ /**
79
+ * DatePicker component
80
+ * Main wrapper component that orchestrates date picker functionality
81
+ * Maintains 100% backwards compatibility with Carbon React v11
82
+ */
83
+ export declare function DatePicker({ datePickerType, dateFormat, minDate, maxDate, locale, readOnly, light, short, allowInput, closeOnSelect, onChange, onClose, onOpen, className, children, value, }: DatePickerProps): import("react/jsx-runtime").JSX.Element;
84
+ export declare namespace DatePicker {
85
+ var displayName: string;
86
+ }
@@ -0,0 +1,150 @@
1
+ /**
2
+ * Copyright IBM Corp. 2016, 2026
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+ const require_runtime = require("../../../../_virtual/_rolldown/runtime.js");
9
+ const require_usePrefix = require("../../../../internal/usePrefix.js");
10
+ const require_useDatePicker = require("../hooks/useDatePicker.js");
11
+ const require_Calendar = require("./Calendar.js");
12
+ let react = require("react");
13
+ react = require_runtime.__toESM(react);
14
+ let classnames = require("classnames");
15
+ classnames = require_runtime.__toESM(classnames);
16
+ let react_jsx_runtime = require("react/jsx-runtime");
17
+ let _carbon_utilities_date_picker = require("@carbon/utilities/date-picker");
18
+ //#region src/components/DatePicker/next/components/DatePicker.tsx
19
+ /**
20
+ * Copyright IBM Corp. 2026
21
+ *
22
+ * This source code is licensed under the Apache-2.0 license found in the
23
+ * LICENSE file in the root directory of this source tree.
24
+ */
25
+ /**
26
+ * DatePicker component
27
+ * Main wrapper component that orchestrates date picker functionality
28
+ * Maintains 100% backwards compatibility with Carbon React v11
29
+ */
30
+ function DatePicker({ datePickerType = "single", dateFormat = "m/d/Y", minDate, maxDate, locale = "en", readOnly = false, light = false, short = false, allowInput = true, closeOnSelect = true, onChange, onClose, onOpen, className, children, value }) {
31
+ const containerRef = (0, react.useRef)(null);
32
+ const prefix = require_usePrefix.usePrefix();
33
+ const { context, isOpen, selectDate, openCalendar, closeCalendar, handleInputFocus, handleInputBlur, handleInputChange, send, startInputRef, endInputRef, calendarRef, exitSentinelRef, handleExitSentinelFocus } = require_useDatePicker.useDatePicker({
34
+ datePickerType,
35
+ value,
36
+ minDate,
37
+ maxDate,
38
+ dateFormat,
39
+ allowInput,
40
+ closeOnSelect,
41
+ readOnly,
42
+ locale,
43
+ onChange,
44
+ onOpen,
45
+ onClose
46
+ });
47
+ const handleNavigate = (eventType) => {
48
+ send(eventType);
49
+ };
50
+ const handleIconClick = () => {
51
+ if (isOpen) closeCalendar();
52
+ else openCalendar();
53
+ };
54
+ const enhancedChildren = react.Children.toArray(children).map((child, index) => {
55
+ if (!(0, react.isValidElement)(child)) return child;
56
+ const isStartInput = index === 0;
57
+ const isEndInput = index === 1 && datePickerType === "range";
58
+ const inputRef = isStartInput ? startInputRef : isEndInput ? endInputRef : void 0;
59
+ let inputValue = child.props.value ?? "";
60
+ if (inputValue === "") {
61
+ if (isStartInput && context.startDate) inputValue = (0, _carbon_utilities_date_picker.formatPlainDate)(context.startDate, context.dateFormat);
62
+ else if (isEndInput && context.endDate) inputValue = (0, _carbon_utilities_date_picker.formatPlainDate)(context.endDate, context.dateFormat);
63
+ }
64
+ const enhancedProps = {
65
+ ...child.props,
66
+ value: inputValue,
67
+ disabled: child.props.disabled || context.isDisabled,
68
+ readOnly: child.props.readOnly || readOnly,
69
+ onFocus: (e) => {
70
+ child.props.onFocus?.(e);
71
+ handleInputFocus(isEndInput ? "to" : "from");
72
+ },
73
+ onBlur: (e) => {
74
+ child.props.onBlur?.(e);
75
+ handleInputBlur();
76
+ },
77
+ onChange: (e) => {
78
+ child.props.onChange?.(e);
79
+ handleInputChange(e.target.value, isEndInput ? "to" : "from");
80
+ },
81
+ onClick: (e) => {
82
+ child.props.onClick?.(e);
83
+ if (!isOpen) openCalendar();
84
+ },
85
+ onKeyDown: (e) => {
86
+ child.props.onKeyDown?.(e);
87
+ if (!e.defaultPrevented && e.key === "Tab" && !e.shiftKey && !isOpen) {
88
+ e.preventDefault();
89
+ openCalendar();
90
+ }
91
+ },
92
+ onIconClick: () => {
93
+ child.props.onIconClick?.();
94
+ handleIconClick();
95
+ },
96
+ hideIcon: datePickerType === "simple" || child.props.hideIcon
97
+ };
98
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
99
+ className: (0, classnames.default)(`${prefix}--date-picker-container`, {
100
+ [`${prefix}--date-picker-container--single`]: datePickerType === "single",
101
+ [`${prefix}--date-picker-container--from`]: isStartInput && datePickerType === "range",
102
+ [`${prefix}--date-picker-container--to`]: isEndInput && datePickerType === "range"
103
+ }),
104
+ children: react.default.createElement(child.type, {
105
+ ...child.props,
106
+ ...enhancedProps,
107
+ ref: inputRef
108
+ })
109
+ }, child.props.id);
110
+ });
111
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
112
+ ref: containerRef,
113
+ className: (0, classnames.default)(`${prefix}--date-picker`, `${prefix}--date-picker--next`, {
114
+ [`${prefix}--date-picker--simple`]: datePickerType === "simple",
115
+ [`${prefix}--date-picker--single`]: datePickerType === "single",
116
+ [`${prefix}--date-picker--range`]: datePickerType === "range",
117
+ [`${prefix}--date-picker--light`]: light,
118
+ [`${prefix}--date-picker--short`]: short,
119
+ [`${prefix}--date-picker--open`]: isOpen
120
+ }, className),
121
+ children: [
122
+ enhancedChildren,
123
+ datePickerType !== "simple" && isOpen && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
124
+ ref: calendarRef,
125
+ className: `${prefix}--date-picker__calendar-container`,
126
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Calendar.Calendar, {
127
+ context,
128
+ onDateSelect: selectDate,
129
+ onNavigate: handleNavigate,
130
+ locale
131
+ })
132
+ }),
133
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
134
+ ref: exitSentinelRef,
135
+ tabIndex: -1,
136
+ "aria-hidden": true,
137
+ onFocus: handleExitSentinelFocus,
138
+ style: {
139
+ position: "absolute",
140
+ width: 0,
141
+ height: 0,
142
+ overflow: "hidden"
143
+ }
144
+ })
145
+ ]
146
+ });
147
+ }
148
+ DatePicker.displayName = "DatePicker";
149
+ //#endregion
150
+ exports.DatePicker = DatePicker;