@elliemae/ds-form-date-time-picker 3.53.0-alpha.1 → 3.53.0-alpha.3
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.
- package/dist/cjs/ControlledDateTimePicker.js +4 -4
- package/dist/cjs/ControlledDateTimePicker.js.map +2 -2
- package/dist/cjs/config/useChangeHandlers.js +19 -19
- package/dist/cjs/config/useChangeHandlers.js.map +2 -2
- package/dist/cjs/config/useGetFlags.js +1 -1
- package/dist/cjs/config/useGetFlags.js.map +2 -2
- package/dist/cjs/config/useGetReferences.js.map +2 -2
- package/dist/cjs/config/useRelevantValueFromProps.js +21 -15
- package/dist/cjs/config/useRelevantValueFromProps.js.map +2 -2
- package/dist/cjs/config/useValidateProps.js.map +1 -1
- package/dist/cjs/{ControlledDateTimePickerTypes.js.map → constants/ControlledDateTimePickerTypes.js.map} +1 -1
- package/dist/cjs/constants/index.js +239 -0
- package/dist/cjs/constants/index.js.map +7 -0
- package/dist/cjs/index.js +11 -13
- package/dist/cjs/index.js.map +3 -3
- package/dist/cjs/parts/ClearButton/ClearButton.js +5 -5
- package/dist/cjs/parts/ClearButton/ClearButton.js.map +2 -2
- package/dist/cjs/parts/ControlledDateTimePickerContent.js +6 -6
- package/dist/cjs/parts/ControlledDateTimePickerContent.js.map +2 -2
- package/dist/cjs/parts/DateInputs/DDInput.js +2 -2
- package/dist/cjs/parts/DateInputs/DDInput.js.map +2 -2
- package/dist/cjs/parts/DateInputs/MMInput.js +3 -3
- package/dist/cjs/parts/DateInputs/MMInput.js.map +2 -2
- package/dist/cjs/parts/DateInputs/YYYYInput.js +2 -2
- package/dist/cjs/parts/DateInputs/YYYYInput.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarBody.js +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarBody.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarContent.js +5 -5
- package/dist/cjs/parts/Pickers/Calendar/CalendarContent.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarFooter.js +3 -3
- package/dist/cjs/parts/Pickers/Calendar/CalendarFooter.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarHead.js +9 -9
- package/dist/cjs/parts/Pickers/Calendar/CalendarHead.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarIconTrigger.js +3 -3
- package/dist/cjs/parts/Pickers/Calendar/CalendarIconTrigger.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/CalendarWrapper.js +5 -6
- package/dist/cjs/parts/Pickers/Calendar/CalendarWrapper.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/Day.js +13 -13
- package/dist/cjs/parts/Pickers/Calendar/Day.js.map +3 -3
- package/dist/cjs/parts/Pickers/Calendar/Styleds.js +17 -17
- package/dist/cjs/parts/Pickers/Calendar/Styleds.js.map +2 -2
- package/dist/cjs/parts/Pickers/Calendar/useKeyboardHandlers.js +8 -2
- package/dist/cjs/parts/Pickers/Calendar/useKeyboardHandlers.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js +5 -5
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js +3 -3
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js +4 -4
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js +6 -7
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/Styleds.js +11 -9
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/Styleds.js.map +2 -2
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js +1 -1
- package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/HoursList.js +13 -10
- package/dist/cjs/parts/Pickers/TimeWheel/HoursList.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/MeridiemList.js +15 -12
- package/dist/cjs/parts/Pickers/TimeWheel/MeridiemList.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/MinutesList.js +12 -9
- package/dist/cjs/parts/Pickers/TimeWheel/MinutesList.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/Styleds.js +20 -16
- package/dist/cjs/parts/Pickers/TimeWheel/Styleds.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContent.js +5 -5
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContent.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelFooter.js +3 -3
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelFooter.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js.map +2 -2
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelWrapper.js +7 -8
- package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelWrapper.js.map +3 -3
- package/dist/cjs/parts/Styleds.js +19 -19
- package/dist/cjs/parts/Styleds.js.map +2 -2
- package/dist/cjs/parts/TimeInputs/HHInput.js +2 -2
- package/dist/cjs/parts/TimeInputs/HHInput.js.map +2 -2
- package/dist/cjs/parts/TimeInputs/MeridiemInput.js +2 -2
- package/dist/cjs/parts/TimeInputs/MeridiemInput.js.map +2 -2
- package/dist/cjs/parts/TimeInputs/MinutesInput.js +2 -2
- package/dist/cjs/parts/TimeInputs/MinutesInput.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +3 -4
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/typescript-testing/slot-props.js +84 -0
- package/dist/cjs/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/ControlledDateTimePicker.js +3 -3
- package/dist/esm/ControlledDateTimePicker.js.map +2 -2
- package/dist/esm/config/useChangeHandlers.js +19 -19
- package/dist/esm/config/useChangeHandlers.js.map +2 -2
- package/dist/esm/config/useGetFlags.js +2 -2
- package/dist/esm/config/useGetFlags.js.map +2 -2
- package/dist/esm/config/useGetReferences.js.map +2 -2
- package/dist/esm/config/useRelevantValueFromProps.js +22 -16
- package/dist/esm/config/useRelevantValueFromProps.js.map +2 -2
- package/dist/esm/config/useValidateProps.js.map +1 -1
- package/dist/esm/{ControlledDateTimePickerTypes.js.map → constants/ControlledDateTimePickerTypes.js.map} +1 -1
- package/dist/esm/constants/index.js +209 -0
- package/dist/esm/constants/index.js.map +7 -0
- package/dist/esm/index.js +16 -14
- package/dist/esm/index.js.map +2 -2
- package/dist/esm/parts/ClearButton/ClearButton.js +4 -4
- package/dist/esm/parts/ClearButton/ClearButton.js.map +2 -2
- package/dist/esm/parts/ControlledDateTimePickerContent.js +5 -5
- package/dist/esm/parts/ControlledDateTimePickerContent.js.map +2 -2
- package/dist/esm/parts/DateInputs/DDInput.js +1 -1
- package/dist/esm/parts/DateInputs/DDInput.js.map +2 -2
- package/dist/esm/parts/DateInputs/MMInput.js +2 -2
- package/dist/esm/parts/DateInputs/MMInput.js.map +2 -2
- package/dist/esm/parts/DateInputs/YYYYInput.js +1 -1
- package/dist/esm/parts/DateInputs/YYYYInput.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarBody.js +1 -1
- package/dist/esm/parts/Pickers/Calendar/CalendarBody.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarContent.js +5 -5
- package/dist/esm/parts/Pickers/Calendar/CalendarContent.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarFooter.js +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarFooter.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarHead.js +5 -5
- package/dist/esm/parts/Pickers/Calendar/CalendarHead.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarIconTrigger.js +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarIconTrigger.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/CalendarWrapper.js +6 -6
- package/dist/esm/parts/Pickers/Calendar/CalendarWrapper.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/Day.js +7 -7
- package/dist/esm/parts/Pickers/Calendar/Day.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/Styleds.js +3 -6
- package/dist/esm/parts/Pickers/Calendar/Styleds.js.map +2 -2
- package/dist/esm/parts/Pickers/Calendar/useKeyboardHandlers.js +8 -2
- package/dist/esm/parts/Pickers/Calendar/useKeyboardHandlers.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js +4 -4
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js +3 -3
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js +5 -5
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/Styleds.js +5 -6
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/Styleds.js.map +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js +2 -2
- package/dist/esm/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/HoursList.js +12 -9
- package/dist/esm/parts/Pickers/TimeWheel/HoursList.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/MeridiemList.js +13 -10
- package/dist/esm/parts/Pickers/TimeWheel/MeridiemList.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/MinutesList.js +11 -8
- package/dist/esm/parts/Pickers/TimeWheel/MinutesList.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/Styleds.js +8 -7
- package/dist/esm/parts/Pickers/TimeWheel/Styleds.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelContent.js +4 -4
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelContent.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelFooter.js +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelFooter.js.map +2 -2
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js +1 -1
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js.map +1 -1
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelWrapper.js +8 -8
- package/dist/esm/parts/Pickers/TimeWheel/TimeWheelWrapper.js.map +3 -3
- package/dist/esm/parts/Styleds.js +3 -6
- package/dist/esm/parts/Styleds.js.map +2 -2
- package/dist/esm/parts/TimeInputs/HHInput.js +1 -1
- package/dist/esm/parts/TimeInputs/HHInput.js.map +2 -2
- package/dist/esm/parts/TimeInputs/MeridiemInput.js +1 -1
- package/dist/esm/parts/TimeInputs/MeridiemInput.js.map +2 -2
- package/dist/esm/parts/TimeInputs/MinutesInput.js +1 -1
- package/dist/esm/parts/TimeInputs/MinutesInput.js.map +2 -2
- package/dist/esm/react-desc-prop-types.js +5 -5
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/typescript-testing/slot-props.js +61 -0
- package/dist/esm/typescript-testing/slot-props.js.map +7 -0
- package/dist/types/ControlledDateTimePicker.d.ts +1 -2
- package/dist/types/ControlledDateTimePickerCTX.d.ts +0 -1
- package/dist/types/config/useFocusTracker.d.ts +0 -1
- package/dist/types/config/useGetFlags.d.ts +0 -1
- package/dist/types/config/useGetReferences.d.ts +3 -4
- package/dist/types/config/useRelevantValueFromProps.d.ts +2 -5
- package/dist/types/constants/index.d.ts +274 -0
- package/dist/types/index.d.ts +6 -8
- package/dist/types/parts/ClearButton/ClearButton.d.ts +0 -1
- package/dist/types/parts/ClearButton/useClearButton.d.ts +0 -1
- package/dist/types/parts/ControlledDateTimePickerContent.d.ts +0 -1
- package/dist/types/parts/DateInputs/DDInput.d.ts +2 -2
- package/dist/types/parts/DateInputs/DateInputs.d.ts +0 -1
- package/dist/types/parts/DateInputs/MMInput.d.ts +2 -2
- package/dist/types/parts/DateInputs/YYYYInput.d.ts +2 -2
- package/dist/types/parts/Pickers/Calendar/Calendar.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarContent.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarContext.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarHead.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarIconTrigger.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarMonthDays.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/CalendarWrapper.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/Day.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/Styleds.d.ts +4 -5
- package/dist/types/parts/Pickers/Calendar/useConfigCalendarCTX.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.d.ts +0 -1
- package/dist/types/parts/Pickers/Calendar/useKeyboardHandlers.d.ts +0 -1
- package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.d.ts +0 -1
- package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContext.d.ts +0 -1
- package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.d.ts +0 -1
- package/dist/types/parts/Pickers/CalendarWithTimeWheel/Styleds.d.ts +4 -5
- package/dist/types/parts/Pickers/PickersIcons.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/HoursList.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/MeridiemList.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/MinutesList.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/Styleds.d.ts +6 -8
- package/dist/types/parts/Pickers/TimeWheel/TimeWheel.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/TimeWheelContext.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/TimeWheelIconTrigger.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/useKeyboardHandlers.d.ts +0 -1
- package/dist/types/parts/Pickers/TimeWheel/usePopperTriggerLogic.d.ts +0 -1
- package/dist/types/parts/Styleds.d.ts +1 -2
- package/dist/types/parts/TimeInputs/HHInput.d.ts +2 -2
- package/dist/types/parts/TimeInputs/MeridiemInput.d.ts +2 -2
- package/dist/types/parts/TimeInputs/MinutesInput.d.ts +2 -2
- package/dist/types/parts/TimeInputs/TimeInputs.d.ts +0 -1
- package/dist/types/react-desc-prop-types.d.ts +36 -8
- package/dist/types/typescript-testing/slot-props.d.ts +1 -0
- package/package.json +14 -13
- package/dist/cjs/ControlledDateTimePickerDatatestid.js +0 -148
- package/dist/cjs/ControlledDateTimePickerDatatestid.js.map +0 -7
- package/dist/cjs/ControlledDateTimePickerDefinitions.js +0 -112
- package/dist/cjs/ControlledDateTimePickerDefinitions.js.map +0 -7
- package/dist/cjs/tests/custom-props/customProps.js +0 -237
- package/dist/cjs/tests/custom-props/customProps.js.map +0 -7
- package/dist/esm/ControlledDateTimePickerDatatestid.js +0 -118
- package/dist/esm/ControlledDateTimePickerDatatestid.js.map +0 -7
- package/dist/esm/ControlledDateTimePickerDefinitions.js +0 -82
- package/dist/esm/ControlledDateTimePickerDefinitions.js.map +0 -7
- package/dist/esm/tests/custom-props/customProps.js +0 -207
- package/dist/esm/tests/custom-props/customProps.js.map +0 -7
- package/dist/types/ControlledDateTimePickerDatatestid.d.ts +0 -112
- package/dist/types/ControlledDateTimePickerDefinitions.d.ts +0 -75
- /package/dist/cjs/{ControlledDateTimePickerTypes.js → constants/ControlledDateTimePickerTypes.js} +0 -0
- /package/dist/esm/{ControlledDateTimePickerTypes.js → constants/ControlledDateTimePickerTypes.js} +0 -0
- /package/dist/types/{ControlledDateTimePickerTypes.d.ts → constants/ControlledDateTimePickerTypes.d.ts} +0 -0
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import React2, { useContext } from "react";
|
|
4
|
-
import { ControlledDateTimePickerDatatestid } from "../../../
|
|
4
|
+
import { ControlledDateTimePickerDatatestid } from "../../../constants/index.js";
|
|
5
5
|
import { ControlledDateTimePickerContext } from "../../../ControlledDateTimePickerCTX.js";
|
|
6
|
+
import { HoursList } from "./HoursList.js";
|
|
7
|
+
import { MeridiemList } from "./MeridiemList.js";
|
|
8
|
+
import { MinutesList } from "./MinutesList.js";
|
|
6
9
|
import {
|
|
7
10
|
StyledTimePickerContainer,
|
|
8
11
|
StyledTimePickerHead,
|
|
9
12
|
StyledTimePickerWheelsLegend,
|
|
10
13
|
StyledTimePickerWheelWrapper
|
|
11
14
|
} from "./Styleds.js";
|
|
12
|
-
import { HoursList } from "./HoursList.js";
|
|
13
|
-
import { MinutesList } from "./MinutesList.js";
|
|
14
|
-
import { MeridiemList } from "./MeridiemList.js";
|
|
15
15
|
import { TimeWheelFooter } from "./TimeWheelFooter.js";
|
|
16
16
|
const TimeWheelContent = React2.memo(() => {
|
|
17
17
|
const {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/Pickers/TimeWheel/TimeWheelContent.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useContext } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../../
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACgCjB,cAIA,YAJA;AAhCN,OAAOA,UAAS,kBAAkB;AAClC,SAAS,0CAA0C;AACnD,SAAS,uCAAuC;AAChD;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useContext } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../../constants/index.js';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { HoursList } from './HoursList.js';\nimport { MeridiemList } from './MeridiemList.js';\nimport { MinutesList } from './MinutesList.js';\nimport {\n StyledTimePickerContainer,\n StyledTimePickerHead,\n StyledTimePickerWheelsLegend,\n StyledTimePickerWheelWrapper,\n} from './Styleds.js';\nimport { TimeWheelFooter } from './TimeWheelFooter.js';\n\nexport const TimeWheelContent = React.memo(() => {\n const {\n isControllerOnly,\n hours,\n minutes,\n meridiem,\n getProps,\n props: { readOnly, applyAriaDisabled },\n } = useContext(ControlledDateTimePickerContext);\n\n return (\n <StyledTimePickerContainer\n isControllerOnly={isControllerOnly}\n data-testid={ControlledDateTimePickerDatatestid.CONTROLLER_COMPONENT.TIMEWHEEL}\n getOwnerProps={getProps}\n role=\"region\"\n aria-label=\"timewheel\"\n >\n <StyledTimePickerHead\n data-testid={ControlledDateTimePickerDatatestid.TIMEWHEEL.HEADER_LABEL}\n getOwnerProps={getProps}\n >{`${hours || '__'}:${minutes || '__'} ${meridiem || '__'}`}</StyledTimePickerHead>\n <StyledTimePickerWheelsLegend>\n <div>H</div>\n <div>M</div>\n <div>A</div>\n </StyledTimePickerWheelsLegend>\n <StyledTimePickerWheelWrapper readOnlyStyles={readOnly || applyAriaDisabled}>\n <HoursList />\n <MinutesList />\n <MeridiemList />\n </StyledTimePickerWheelWrapper>\n <TimeWheelFooter />\n </StyledTimePickerContainer>\n );\n});\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACgCjB,cAIA,YAJA;AAhCN,OAAOA,UAAS,kBAAkB;AAClC,SAAS,0CAA0C;AACnD,SAAS,uCAAuC;AAChD,SAAS,iBAAiB;AAC1B,SAAS,oBAAoB;AAC7B,SAAS,mBAAmB;AAC5B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,uBAAuB;AAEzB,MAAM,mBAAmBA,OAAM,KAAK,MAAM;AAC/C,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,OAAO,EAAE,UAAU,kBAAkB;AAAA,EACvC,IAAI,WAAW,+BAA+B;AAE9C,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,eAAa,mCAAmC,qBAAqB;AAAA,MACrE,eAAe;AAAA,MACf,MAAK;AAAA,MACL,cAAW;AAAA,MAEX;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,mCAAmC,UAAU;AAAA,YAC1D,eAAe;AAAA,YACf,aAAG,SAAS,IAAI,IAAI,WAAW,IAAI,IAAI,YAAY,IAAI;AAAA;AAAA,QAAG;AAAA,QAC5D,qBAAC,gCACC;AAAA,8BAAC,SAAI,eAAC;AAAA,UACN,oBAAC,SAAI,eAAC;AAAA,UACN,oBAAC,SAAI,eAAC;AAAA,WACR;AAAA,QACA,qBAAC,gCAA6B,gBAAgB,YAAY,mBACxD;AAAA,8BAAC,aAAU;AAAA,UACX,oBAAC,eAAY;AAAA,UACb,oBAAC,gBAAa;AAAA,WAChB;AAAA,QACA,oBAAC,mBAAgB;AAAA;AAAA;AAAA,EACnB;AAEJ,CAAC;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useContext } from "react";
|
|
4
3
|
import { AlertsSmallFill } from "@elliemae/ds-icons";
|
|
5
|
-
import {
|
|
4
|
+
import { useContext } from "react";
|
|
5
|
+
import { ControlledDateTimePickerDatatestid } from "../../../constants/index.js";
|
|
6
6
|
import { ControlledDateTimePickerContext } from "../../../ControlledDateTimePickerCTX.js";
|
|
7
7
|
import { TimeWheelFooterMessage } from "./Styleds.js";
|
|
8
8
|
const TimeWheelFooter = () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/Pickers/TimeWheel/TimeWheelFooter.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACcjB,SAME,KANF;AAdN,SAAgB,kBAAkB;AAClC,SAAS,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { AlertsSmallFill } from '@elliemae/ds-icons';\nimport React, { useContext } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../../constants/index.js';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { TimeWheelFooterMessage } from './Styleds.js';\n\nexport const TimeWheelFooter: React.ComponentType = () => {\n const {\n props: { pickerFooterMsg, hasError, readOnly, applyAriaDisabled },\n getProps,\n isWithCalendarToo,\n } = useContext(ControlledDateTimePickerContext);\n if (!isWithCalendarToo && pickerFooterMsg !== undefined && hasError)\n return (\n <TimeWheelFooterMessage\n role=\"alert\"\n data-testid={ControlledDateTimePickerDatatestid.FOOTERS.TIMEWHEEL}\n getOwnerProps={getProps}\n readOnlyStyles={readOnly || applyAriaDisabled}\n >\n <AlertsSmallFill\n width={8}\n height={8}\n color={['danger', '900']}\n style={{ marginRight: '0.5rem', marginBottom: '2px' }}\n />\n {pickerFooterMsg}\n </TimeWheelFooterMessage>\n );\n return null;\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACcjB,SAME,KANF;AAdN,SAAS,uBAAuB;AAChC,SAAgB,kBAAkB;AAClC,SAAS,0CAA0C;AACnD,SAAS,uCAAuC;AAChD,SAAS,8BAA8B;AAEhC,MAAM,kBAAuC,MAAM;AACxD,QAAM;AAAA,IACJ,OAAO,EAAE,iBAAiB,UAAU,UAAU,kBAAkB;AAAA,IAChE;AAAA,IACA;AAAA,EACF,IAAI,WAAW,+BAA+B;AAC9C,MAAI,CAAC,qBAAqB,oBAAoB,UAAa;AACzD,WACE;AAAA,MAAC;AAAA;AAAA,QACC,MAAK;AAAA,QACL,eAAa,mCAAmC,QAAQ;AAAA,QACxD,eAAe;AAAA,QACf,gBAAgB,YAAY;AAAA,QAE5B;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,QAAQ;AAAA,cACR,OAAO,CAAC,UAAU,KAAK;AAAA,cACvB,OAAO,EAAE,aAAa,UAAU,cAAc,MAAM;AAAA;AAAA,UACtD;AAAA,UACC;AAAA;AAAA;AAAA,IACH;AAEJ,SAAO;AACT;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -4,7 +4,7 @@ import { BUTTON_SIZES } from "@elliemae/ds-button-v2";
|
|
|
4
4
|
import { RecentDocuments } from "@elliemae/ds-icons";
|
|
5
5
|
import { useContext, useMemo } from "react";
|
|
6
6
|
import { ControlledDateTimePickerContext } from "../../../ControlledDateTimePickerCTX.js";
|
|
7
|
-
import { ControlledDateTimePickerDatatestid } from "../../../
|
|
7
|
+
import { ControlledDateTimePickerDatatestid } from "../../../constants/index.js";
|
|
8
8
|
import { StyledIconTriggerButton } from "./Styleds.js";
|
|
9
9
|
import { TimeWheelContext } from "./TimeWheelContext.js";
|
|
10
10
|
const TimeWheelIconTrigger = () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/Pickers/TimeWheel/TimeWheelIconTrigger.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { BUTTON_SIZES } from '@elliemae/ds-button-v2';\nimport { RecentDocuments } from '@elliemae/ds-icons';\nimport { useContext, useMemo } from 'react';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { ControlledDateTimePickerDatatestid } from '../../../
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { BUTTON_SIZES } from '@elliemae/ds-button-v2';\nimport { RecentDocuments } from '@elliemae/ds-icons';\nimport { useContext, useMemo } from 'react';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { ControlledDateTimePickerDatatestid } from '../../../constants/index.js';\nimport { StyledIconTriggerButton } from './Styleds.js';\nimport { TimeWheelContext } from './TimeWheelContext.js';\n\n// we memoize the Icon for maximum optimization\n// this is particularly useful due to how usePopper needs to check the references\n// since references are saved in a immutable way, we make sure to shortcircuit useless-re-renders\nexport const TimeWheelIconTrigger = (): JSX.Element => {\n const { handleSetTriggerRef, handleToggleTimePicker, handlePickerIconKeyDown } = useContext(TimeWheelContext);\n const {\n props: { disabled, tabIndex },\n getProps,\n ariaCurrentValueForInputs,\n } = useContext(ControlledDateTimePickerContext);\n return useMemo(\n () => (\n <StyledIconTriggerButton\n aria-label={`time picker context menu trigger, ${ariaCurrentValueForInputs}`}\n buttonType=\"icon\"\n size={BUTTON_SIZES.M}\n innerRef={handleSetTriggerRef}\n tabIndex={tabIndex}\n onClick={handleToggleTimePicker}\n onKeyDown={handlePickerIconKeyDown}\n data-testid={ControlledDateTimePickerDatatestid.PICKER_ICONS.TIMEWHEEL}\n disabled={disabled}\n type=\"button\"\n getOwnerProps={getProps}\n >\n <RecentDocuments color={disabled ? ['neutral', '500'] : ['brand-primary', '800']} />\n </StyledIconTriggerButton>\n ),\n [\n ariaCurrentValueForInputs,\n disabled,\n getProps,\n handlePickerIconKeyDown,\n handleSetTriggerRef,\n handleToggleTimePicker,\n tabIndex,\n ],\n );\n};\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACiCf;AAjCR,SAAS,oBAAoB;AAC7B,SAAS,uBAAuB;AAChC,SAAS,YAAY,eAAe;AACpC,SAAS,uCAAuC;AAChD,SAAS,0CAA0C;AACnD,SAAS,+BAA+B;AACxC,SAAS,wBAAwB;AAK1B,MAAM,uBAAuB,MAAmB;AACrD,QAAM,EAAE,qBAAqB,wBAAwB,wBAAwB,IAAI,WAAW,gBAAgB;AAC5G,QAAM;AAAA,IACJ,OAAO,EAAE,UAAU,SAAS;AAAA,IAC5B;AAAA,IACA;AAAA,EACF,IAAI,WAAW,+BAA+B;AAC9C,SAAO;AAAA,IACL,MACE;AAAA,MAAC;AAAA;AAAA,QACC,cAAY,qCAAqC,yBAAyB;AAAA,QAC1E,YAAW;AAAA,QACX,MAAM,aAAa;AAAA,QACnB,UAAU;AAAA,QACV;AAAA,QACA,SAAS;AAAA,QACT,WAAW;AAAA,QACX,eAAa,mCAAmC,aAAa;AAAA,QAC7D;AAAA,QACA,MAAK;AAAA,QACL,eAAe;AAAA,QAEf,8BAAC,mBAAgB,OAAO,WAAW,CAAC,WAAW,KAAK,IAAI,CAAC,iBAAiB,KAAK,GAAG;AAAA;AAAA,IACpF;AAAA,IAEF;AAAA,MACE;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,EACF;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { useContext } from "react";
|
|
4
3
|
import { DSPopperJS } from "@elliemae/ds-popperjs";
|
|
5
4
|
import { styled } from "@elliemae/ds-system";
|
|
6
|
-
import
|
|
7
|
-
import { ControlledDateTimePickerContext } from "../../../ControlledDateTimePickerCTX.js";
|
|
8
|
-
import { TimeWheelContent } from "./TimeWheelContent.js";
|
|
9
|
-
import { TimeWheelContext } from "./TimeWheelContext.js";
|
|
5
|
+
import React2 from "react";
|
|
10
6
|
import {
|
|
7
|
+
ControlledDateTimePickerDatatestid,
|
|
11
8
|
DSControlledDateTimePickerName,
|
|
12
9
|
DSControlledDateTimePickerSlots
|
|
13
|
-
} from "../../../
|
|
10
|
+
} from "../../../constants/index.js";
|
|
11
|
+
import { ControlledDateTimePickerContext } from "../../../ControlledDateTimePickerCTX.js";
|
|
12
|
+
import { TimeWheelContent } from "./TimeWheelContent.js";
|
|
13
|
+
import { TimeWheelContext } from "./TimeWheelContext.js";
|
|
14
14
|
const StyledPopper = styled(DSPopperJS, {
|
|
15
15
|
name: DSControlledDateTimePickerName,
|
|
16
16
|
slot: DSControlledDateTimePickerSlots.CONTEXTUAL_MENU.TIMEWHEEL
|
|
17
17
|
})``;
|
|
18
18
|
const TimeWheelWrapper = () => {
|
|
19
|
-
const { referenceElement, closeTimePicker } = useContext(TimeWheelContext);
|
|
20
|
-
const { isControllerOnly, getProps } = useContext(ControlledDateTimePickerContext);
|
|
19
|
+
const { referenceElement, closeTimePicker } = React2.useContext(TimeWheelContext);
|
|
20
|
+
const { isControllerOnly, getProps } = React2.useContext(ControlledDateTimePickerContext);
|
|
21
21
|
if (isControllerOnly) return /* @__PURE__ */ jsx(TimeWheelContent, {});
|
|
22
22
|
if (!referenceElement) return null;
|
|
23
23
|
return /* @__PURE__ */ jsx(
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/Pickers/TimeWheel/TimeWheelWrapper.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACoBQ;AApB/B,
|
|
6
|
-
"names": []
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { DSPopperJS } from '@elliemae/ds-popperjs';\nimport { styled } from '@elliemae/ds-system';\nimport React from 'react';\nimport {\n ControlledDateTimePickerDatatestid,\n DSControlledDateTimePickerName,\n DSControlledDateTimePickerSlots,\n} from '../../../constants/index.js';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { TimeWheelContent } from './TimeWheelContent.js';\nimport { TimeWheelContext } from './TimeWheelContext.js';\n\nconst StyledPopper = styled(DSPopperJS, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.CONTEXTUAL_MENU.TIMEWHEEL,\n})``;\n\nexport const TimeWheelWrapper = () => {\n const { referenceElement, closeTimePicker } = React.useContext(TimeWheelContext);\n const { isControllerOnly, getProps } = React.useContext(ControlledDateTimePickerContext);\n if (isControllerOnly) return <TimeWheelContent />;\n if (!referenceElement) return null;\n return (\n <StyledPopper\n showPopover\n data-testid={ControlledDateTimePickerDatatestid.CONTEXTUAL_MENU.TIMEWHEEL}\n referenceElement={referenceElement}\n withoutArrow\n onClickOutside={closeTimePicker}\n getOwnerProps={getProps}\n aria-label=\"time wheel header\"\n role=\"dialog\"\n >\n <TimeWheelContent />\n </StyledPopper>\n );\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACoBQ;AApB/B,SAAS,kBAAkB;AAC3B,SAAS,cAAc;AACvB,OAAOA,YAAW;AAClB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,uCAAuC;AAChD,SAAS,wBAAwB;AACjC,SAAS,wBAAwB;AAEjC,MAAM,eAAe,OAAO,YAAY;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,gCAAgC,gBAAgB;AACxD,CAAC;AAEM,MAAM,mBAAmB,MAAM;AACpC,QAAM,EAAE,kBAAkB,gBAAgB,IAAIA,OAAM,WAAW,gBAAgB;AAC/E,QAAM,EAAE,kBAAkB,SAAS,IAAIA,OAAM,WAAW,+BAA+B;AACvF,MAAI,iBAAkB,QAAO,oBAAC,oBAAiB;AAC/C,MAAI,CAAC,iBAAkB,QAAO;AAC9B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAW;AAAA,MACX,eAAa,mCAAmC,gBAAgB;AAAA,MAChE;AAAA,MACA,cAAY;AAAA,MACZ,gBAAgB;AAAA,MAChB,eAAe;AAAA,MACf,cAAW;AAAA,MACX,MAAK;AAAA,MAEL,8BAAC,oBAAiB;AAAA;AAAA,EACpB;AAEJ;",
|
|
6
|
+
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import { styled, th } from "@elliemae/ds-system";
|
|
3
|
-
import { Grid } from "@elliemae/ds-grid";
|
|
4
2
|
import { DSButtonV2 } from "@elliemae/ds-button-v2";
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
} from "../ControlledDateTimePickerDefinitions.js";
|
|
3
|
+
import { Grid } from "@elliemae/ds-grid";
|
|
4
|
+
import { styled, th } from "@elliemae/ds-system";
|
|
5
|
+
import { DSControlledDateTimePickerName, DSControlledDateTimePickerSlots } from "../constants/index.js";
|
|
9
6
|
const ResettedInput = styled("input")`
|
|
10
7
|
border: none;
|
|
11
8
|
box-shadow: none;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/parts/Styleds.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\nimport {
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACCvB,SAAS,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\nimport { DSButtonV2 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { styled, th } from '@elliemae/ds-system';\nimport { DSControlledDateTimePickerName, DSControlledDateTimePickerSlots } from '../constants/index.js';\n\nconst ResettedInput = styled('input')`\n border: none;\n box-shadow: none;\n background: none;\n text-align: center;\n height: 100%;\n display: flex;\n align-items: center;\n :focus {\n outline: none;\n }\n padding-top: 2px;\n\n color: ${th.color('neutral-700')};\n\n ::placeholder {\n font-weight: ${th.fontWeight('regular')};\n color: ${th.color('neutral-500')};\n }\n`;\n\nexport const StyledSeparator = styled(Grid)`\n padding-top: 2px;\n margin: auto;\n color: neutral-500;\n`;\n\nexport const StyledColonSeparator = styled(Grid)`\n padding-bottom: 1px;\n margin: auto;\n`;\n\nexport const Styled2DigitsInput = styled(ResettedInput)`\n width: 100%;\n height: 100%;\n ${({ disabled }) => (disabled ? `color: #616b7f;` : ``)}\n`;\n\nexport const StyledDateInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.DATE_INPUTS.DAY,\n})``;\n\nexport const StyledMonthInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.DATE_INPUTS.MONTH,\n})``;\n\nexport const StyledYearInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.DATE_INPUTS.YEAR,\n})``;\n\nexport const StyledHourInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.TIME_INPUTS.HOUR,\n})``;\n\nexport const StyledMinuteInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.TIME_INPUTS.MINUTE,\n})``;\n\nexport const StyledMeridiemInput = styled(Styled2DigitsInput, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.TIME_INPUTS.MERIDIEM,\n})``;\n\nexport const StyledMin4DigitsInput = styled(ResettedInput)`\n width: 100%;\n height: 100%;\n ${({ disabled }) => (disabled ? `color: #616b7f;` : ``)}\n`;\n\nexport const StyledInputsWrapperGrid = styled(Grid, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.CONTAINER,\n})<{\n isControllerOnly: boolean;\n onlyPicker: boolean;\n hasError: boolean;\n justPicker: boolean;\n disabled: boolean;\n readOnlyStyles?: boolean;\n}>`\n width: max-content;\n align-items: center;\n background-color: white;\n ${({ isControllerOnly }) =>\n isControllerOnly\n ? ``\n : `\n height: 2.153rem; \n border-width: 1px;\n border-style: solid;\n `}\n\n border-color: ${({ theme, hasError }) => {\n if (hasError) return theme.colors.danger[900];\n return theme.colors.neutral[400];\n }};\n\n border-radius: 2px;\n padding-left: ${({ justPicker }) => (justPicker ? '0' : '2px')};\n\n position: relative;\n ${({ theme, disabled }) => (disabled ? `background-color: ${theme.colors.neutral[100]};` : ``)}\n ${({ readOnlyStyles, hasError, onlyPicker, theme }) =>\n readOnlyStyles &&\n !hasError &&\n !onlyPicker &&\n `\n border-left: 1px solid ${theme.colors.neutral['080']};\n border-top: 1px solid ${theme.colors.neutral['080']};\n border-right: 1px solid ${theme.colors.neutral['080']};\n\n `}\n ${({ readOnlyStyles, hasError, theme }) =>\n readOnlyStyles &&\n !hasError &&\n `\n background-color: ${theme.colors.neutral['050']};\n `}\n`;\n\nexport const StyledDateInputsWrapperGrid = styled.div`\n display: grid;\n grid-template-columns: 24px min-content 24px min-content 48px;\n grid-template-rows: min-content;\n padding: 6px 0;\n gap: 0px 0px;\n align-items: center;\n input,\n p {\n margin: 0;\n }\n`;\n\nexport const StyledTimeInputsWrapperGrid = styled.div`\n display: grid;\n grid-template-columns: 24px min-content 24px min-content 24px min-content 24px;\n grid-template-rows: min-content;\n padding: 6px 0;\n gap: 0px 0px;\n align-items: center;\n input,\n p {\n margin: 0;\n }\n`;\n\nexport const StyledPickersIconsWrapperGrid = styled(Grid)<{ isControllerOnly: boolean; hasError: boolean }>`\n position: relative;\n ${({ isControllerOnly }) => (isControllerOnly ? `` : `height: 2rem;`)}\n :before {\n content: '';\n position: absolute;\n top: 0px;\n left: -1px;\n width: 100%;\n height: 100%;\n // this shoudnt be rounded as specified in the design\n /* border-radius: 2px; */\n ${({ theme, isControllerOnly, hasError }) =>\n isControllerOnly\n ? ``\n : `\n border-left: 1px solid ${hasError ? theme.colors.danger[900] : theme.colors.neutral[400]}\n `}\n }\n`;\n\nexport const StyledFocusWithIn = styled(Grid)`\n position: relative;\n &:focus-within {\n &:after {\n display: block;\n content: ' ';\n position: absolute;\n top: -5px;\n left: -2px;\n width: calc(100% + 4px);\n height: calc(100% + 10px);\n border: 2px solid ${({ theme }) => theme.colors.brand[700]};\n border-radius: 2px;\n pointer-events: none;\n }\n }\n`;\n\nexport const StyledClearButton = styled(DSButtonV2, {\n name: DSControlledDateTimePickerName,\n slot: DSControlledDateTimePickerSlots.CLEAR_BUTTON,\n})<{ shouldDisplay: boolean }>`\n height: 26px;\n position: relative;\n visibility: ${({ shouldDisplay }) => (shouldDisplay ? 'visible' : 'hidden')};\n &:focus {\n &:after {\n z-index: 1;\n }\n }\n`;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACCvB,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AACrB,SAAS,QAAQ,UAAU;AAC3B,SAAS,gCAAgC,uCAAuC;AAEhF,MAAM,gBA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IAAI,MAAM,OAAO,QAAQ,GAAG,CAAC;AAAA,KACvF;AAAA;AAAA;AAIE,MAAM,oBAAoB,OAAO,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,0BAWlB,CAAC,EAAE,MAAM,MAAM,MAAM,OAAO,MAAM,GAAG,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAOzD,MAAM,oBAAoB,OAAO,YAAY;AAAA,EAClD,MAAM;AAAA,EACN,MAAM,gCAAgC;AACxC,CAAC;AAAA;AAAA;AAAA,gBAGe,CAAC,EAAE,cAAc,MAAO,gBAAgB,YAAY,QAAS;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import React2, { useCallback } from "react";
|
|
4
|
+
import { ControlledDateTimePickerDatatestid } from "../../constants/index.js";
|
|
4
5
|
import { StyledHourInput } from "../Styleds.js";
|
|
5
|
-
import { ControlledDateTimePickerDatatestid } from "../../ControlledDateTimePickerDatatestid.js";
|
|
6
6
|
const regExpNumbers = /^[0-9]+$/;
|
|
7
7
|
const isInvalidHour = (hours) => {
|
|
8
8
|
if (hours === "") return false;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/TimeInputs/HHInput.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;AC0DjB;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport React, { useCallback } from 'react';\nimport type { ControlledDateTimePickerContextT } from '../../config/useControlledDateTimePicker.js';\nimport { ControlledDateTimePickerDatatestid } from '../../constants/index.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\nimport { StyledHourInput } from '../Styleds.js';\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidHour = (hours: string) => {\n if (hours === '') return false;\n const numberOnly = regExpNumbers.test(hours);\n return hours.length > 2 || hours === '00' || !numberOnly || Number.parseInt(hours, 10) > 12;\n};\ninterface HHInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n applyAriaDisabled?: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n autoFocusHourInput: boolean;\n isFocused: boolean;\n getProps: ControlledDateTimePickerContextT['getProps'];\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n readOnly: boolean;\n}\nexport const HHInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n applyAriaDisabled,\n placeholder,\n ariaCurrentValueForInputs,\n contextRef,\n autoFocusHourInput,\n isFocused,\n getProps,\n tabIndex,\n readOnly,\n }: HHInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (readOnly || applyAriaDisabled || disabled || isInvalidHour(e.target.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [applyAriaDisabled, disabled, onChange, readOnly],\n );\n return (\n <StyledHourInput\n autoFocus={autoFocusHourInput}\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n innerRef={(DomElem: HTMLInputElement) => {\n contextRef.current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n tabIndex={tabIndex}\n placeholder={placeholder}\n data-testid={ControlledDateTimePickerDatatestid.TIME_INPUTS.HOUR}\n aria-label={`hours input field ${ariaCurrentValueForInputs}`}\n disabled={disabled}\n aria-disabled={applyAriaDisabled}\n getOwnerProps={getProps}\n readOnly={readOnly}\n />\n );\n },\n);\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;AC0DjB;AAzDN,OAAOA,UAAS,mBAAmB;AAEnC,SAAS,0CAA0C;AAEnD,SAAS,uBAAuB;AAChC,MAAM,gBAAgB;AACtB,MAAM,gBAAgB,CAAC,UAAkB;AACvC,MAAI,UAAU,GAAI,QAAO;AACzB,QAAM,aAAa,cAAc,KAAK,KAAK;AAC3C,SAAO,MAAM,SAAS,KAAK,UAAU,QAAQ,CAAC,cAAc,OAAO,SAAS,OAAO,EAAE,IAAI;AAC3F;AAkBO,MAAM,UAAUA,OAAM;AAAA,EAC3B,CAAC;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,MAAmC;AACjC,UAAM,mBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,YAAY,qBAAqB,YAAY,cAAc,EAAE,OAAO,KAAK,GAAG;AAC9E,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,mBAAmB,UAAU,UAAU,QAAQ;AAAA,IAClD;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,WAAW;AAAA,QACX,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,UAAU,CAAC,YAA8B;AACvC,qBAAW,UAAU;AACrB,cAAI,UAAW,UAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA;AAAA,QACA,eAAa,mCAAmC,YAAY;AAAA,QAC5D,cAAY,qBAAqB,yBAAyB;AAAA,QAC1D;AAAA,QACA,iBAAe;AAAA,QACf,eAAe;AAAA,QACf;AAAA;AAAA,IACF;AAAA,EAEJ;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import React2, { useCallback } from "react";
|
|
4
|
+
import { ControlledDateTimePickerDatatestid } from "../../constants/index.js";
|
|
4
5
|
import { StyledMeridiemInput } from "../Styleds.js";
|
|
5
|
-
import { ControlledDateTimePickerDatatestid } from "../../ControlledDateTimePickerDatatestid.js";
|
|
6
6
|
const validFirstDigits = ["a", "A", "p", "P"];
|
|
7
7
|
const validSecondDigits = ["m", "M"];
|
|
8
8
|
const isInvalidMeridiem = (meridiem) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/TimeInputs/MeridiemInput.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;AC6DjB;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport React, { useCallback } from 'react';\nimport type { ControlledDateTimePickerContextT } from '../../config/useControlledDateTimePicker.js';\nimport { ControlledDateTimePickerDatatestid } from '../../constants/index.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\nimport { StyledMeridiemInput } from '../Styleds.js';\n\nconst validFirstDigits = ['a', 'A', 'p', 'P'];\nconst validSecondDigits = ['m', 'M'];\nconst isInvalidMeridiem = (meridiem: string) => {\n if (meridiem === '') return false;\n const [firstDigit, secondDigit] = meridiem.split('');\n const isValidFirstDigit = (meridiem.length < 1 && !firstDigit) || validFirstDigits.includes(firstDigit);\n const isValidSecondDigit = !secondDigit || validSecondDigits.includes(secondDigit);\n return meridiem.length > 2 || !isValidFirstDigit || !isValidSecondDigit;\n};\n\ninterface MeridiemInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n applyAriaDisabled?: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n getProps: ControlledDateTimePickerContextT['getProps'];\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n readOnly: boolean;\n}\nexport const MeridiemInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n applyAriaDisabled,\n placeholder,\n ariaCurrentValueForInputs,\n contextRef,\n isFocused,\n getProps,\n tabIndex,\n readOnly,\n }: MeridiemInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (readOnly || applyAriaDisabled || disabled || isInvalidMeridiem(e?.target?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [applyAriaDisabled, disabled, onChange, readOnly],\n );\n return (\n <StyledMeridiemInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n innerRef={(DomElem: HTMLInputElement) => {\n contextRef.current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n tabIndex={tabIndex}\n data-testid={ControlledDateTimePickerDatatestid.TIME_INPUTS.MERIDIEM}\n placeholder={placeholder}\n aria-label={`meridiem input field ${ariaCurrentValueForInputs}`}\n disabled={disabled}\n aria-disabled={applyAriaDisabled}\n getOwnerProps={getProps}\n readOnly={readOnly}\n />\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AAwB,yBAAyB;AAAA,QAC7D;AAAA,QACA,iBAAe;AAAA,QACf,eAAe;AAAA,QACf;AAAA;AAAA,IACF;AAAA,EAEJ;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import React2, { useCallback } from "react";
|
|
4
|
+
import { ControlledDateTimePickerDatatestid } from "../../constants/index.js";
|
|
4
5
|
import { StyledMinuteInput } from "../Styleds.js";
|
|
5
|
-
import { ControlledDateTimePickerDatatestid } from "../../ControlledDateTimePickerDatatestid.js";
|
|
6
6
|
const regExpNumbers = /^[0-9]+$/;
|
|
7
7
|
const isInvalidMinute = (minutes) => {
|
|
8
8
|
if (minutes === "") return false;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/TimeInputs/MinutesInput.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACwDjB;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport React, { useCallback } from 'react';\nimport type { ControlledDateTimePickerContextT } from '../../config/useControlledDateTimePicker.js';\nimport { ControlledDateTimePickerDatatestid } from '../../constants/index.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\nimport { StyledMinuteInput } from '../Styleds.js';\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidMinute = (minutes: string) => {\n if (minutes === '') return false;\n const numberOnly = regExpNumbers.test(minutes);\n return minutes.length > 2 || !numberOnly || Number.parseInt(minutes, 10) > 60;\n};\ninterface MinutesInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n applyAriaDisabled?: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n getProps: ControlledDateTimePickerContextT['getProps'];\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n readOnly: boolean;\n}\nexport const MinutesInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n applyAriaDisabled,\n placeholder,\n ariaCurrentValueForInputs,\n contextRef,\n isFocused,\n getProps,\n tabIndex,\n readOnly,\n }: MinutesInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (readOnly || applyAriaDisabled || disabled || isInvalidMinute(e?.target?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [applyAriaDisabled, disabled, onChange, readOnly],\n );\n return (\n <StyledMinuteInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n innerRef={(DomElem: HTMLInputElement) => {\n contextRef.current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n tabIndex={tabIndex}\n data-testid={ControlledDateTimePickerDatatestid.TIME_INPUTS.MINUTE}\n placeholder={placeholder}\n aria-label={`minutes input field ${ariaCurrentValueForInputs}`}\n disabled={disabled}\n aria-disabled={applyAriaDisabled}\n getOwnerProps={getProps}\n readOnly={readOnly}\n />\n );\n },\n);\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACwDjB;AAvDN,OAAOA,UAAS,mBAAmB;AAEnC,SAAS,0CAA0C;AAEnD,SAAS,yBAAyB;AAClC,MAAM,gBAAgB;AACtB,MAAM,kBAAkB,CAAC,YAAoB;AAC3C,MAAI,YAAY,GAAI,QAAO;AAC3B,QAAM,aAAa,cAAc,KAAK,OAAO;AAC7C,SAAO,QAAQ,SAAS,KAAK,CAAC,cAAc,OAAO,SAAS,SAAS,EAAE,IAAI;AAC7E;AAiBO,MAAM,eAAeA,OAAM;AAAA,EAChC,CAAC;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,MAAwC;AACtC,UAAM,mBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,YAAY,qBAAqB,YAAY,gBAAgB,GAAG,QAAQ,KAAK,GAAG;AAClF,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,mBAAmB,UAAU,UAAU,QAAQ;AAAA,IAClD;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,UAAU,CAAC,YAA8B;AACvC,qBAAW,UAAU;AACrB,cAAI,UAAW,UAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA,eAAa,mCAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,cAAY,uBAAuB,yBAAyB;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACf,eAAe;AAAA,QACf;AAAA;AAAA,IACF;AAAA,EAEJ;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import {
|
|
3
3
|
PropTypes,
|
|
4
|
-
globalAttributesPropTypes,
|
|
5
|
-
xstyledPropTypes,
|
|
6
4
|
getPropsPerDatatestIdPropTypes,
|
|
7
|
-
getPropsPerSlotPropTypes
|
|
5
|
+
getPropsPerSlotPropTypes,
|
|
6
|
+
globalAttributesPropTypes,
|
|
7
|
+
xstyledPropTypes
|
|
8
8
|
} from "@elliemae/ds-props-helpers";
|
|
9
|
-
import { ControlledDateTimePickerDatatestid } from "./ControlledDateTimePickerDatatestid.js";
|
|
10
9
|
import {
|
|
10
|
+
ControlledDateTimePickerDatatestid,
|
|
11
11
|
DSControlledDateTimePickerName,
|
|
12
12
|
DSControlledDateTimePickerSlotsFlatten
|
|
13
|
-
} from "./
|
|
13
|
+
} from "./constants/index.js";
|
|
14
14
|
const noop = () => {
|
|
15
15
|
};
|
|
16
16
|
const defaultReturnFalse = () => false;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/react-desc-prop-types.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\nimport type React from 'react';\nimport {\n PropTypes,\n globalAttributesPropTypes,\n xstyledPropTypes,\n getPropsPerDatatestIdPropTypes,\n getPropsPerSlotPropTypes,\n type GlobalAttributesT,\n type XstyledProps,\n type ValidationMap,\n} from '@elliemae/ds-props-helpers';\nimport type { TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport { ControlledDateTimePickerDatatestid } from './ControlledDateTimePickerDatatestid.js';\nimport {\n DSControlledDateTimePickerName,\n DSControlledDateTimePickerSlotsFlatten,\n} from './ControlledDateTimePickerDefinitions.js';\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nconst noop = (): void => {};\nconst defaultReturnFalse = (): false => false;\n\nexport declare namespace DSControlledDateTimePickerT {\n type PropsT<D, R, O, E> = Partial<D> &\n R &\n O &\n Omit<GlobalAttributesT<E>, keyof D | keyof R | keyof O> &\n Omit<XstyledProps, keyof D | keyof R | keyof O>;\n\n type InternalPropsT<D, R, O, E> = D &\n R &\n O &\n Omit<GlobalAttributesT<E>, keyof D | keyof R | keyof O> &\n Omit<XstyledProps, keyof D | keyof R | keyof O>;\n type DataTestIdType = typeof ControlledDateTimePickerDatatestid;\n // typescript type that rapresents the union of all the values for ControlledDateTimePickerDatatestid\n export type FlatDataTestIdValues = {\n [K in keyof DataTestIdType]: DataTestIdType[K] extends Record<string, unknown>\n ? DataTestIdType[K][keyof DataTestIdType[K]] // this is only 1 level deep, but it's enough for our needs right now\n : // can be extended to more levels if needed as follows:\n // ? DataTestIdType[K][keyof DataTestIdType[K]] extends Record<string, unknown>\n // ? DataTestIdType[K][keyof DataTestIdType[K]][keyof DataTestIdType[K][keyof DataTestIdType[K]]]\n // : DataTestIdType[K][keyof DataTestIdType[K]]\n DataTestIdType[K];\n }[keyof DataTestIdType];\n\n export type OnInternalValuesChangeEvent =\n | React.ChangeEvent<HTMLInputElement>\n | React.KeyboardEvent<HTMLInputElement>\n | React.KeyboardEvent<HTMLButtonElement>\n | React.KeyboardEvent\n | React.MouseEvent<HTMLInputElement>\n | React.MouseEvent<HTMLButtonElement>;\n export type ControlTypes =\n | 'full-date-time'\n | 'date-time-inputs'\n | 'date-time-picker'\n | 'date-time-picker-controller-only'\n | 'full-date'\n | 'date-inputs'\n | 'date-picker'\n | 'date-picker-controller-only'\n | 'full-time'\n | 'time-inputs'\n | 'time-picker'\n | 'time-picker-controller-only';\n export interface InternalInputsChangeMetaInfo {\n isAutomaticFillTrigger?: boolean;\n isDayPresentInMonth?: boolean;\n isOutOfRangeDay?: boolean;\n isDisabledDay?: boolean;\n isDisabledTime?: boolean;\n suggestedErrorMsg?: string;\n newDateTimeString?: string;\n newDateString?: string;\n newTimeString?: string;\n }\n\n export type OnDateChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnTimeChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnDateTimeChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnInternalInputsChange = (\n val: string,\n e: OnInternalValuesChangeEvent,\n metaInfo?: InternalInputsChangeMetaInfo,\n ) => void;\n export type AppOnInputChange = (\n val: string,\n e: OnInternalValuesChangeEvent,\n metaInfo: InternalInputsChangeMetaInfo,\n ) => void;\n\n /* ------------------------ ------------------ ------------------------*/\n /* ------------------------ DATE CONFIGURATION ------------------------*/\n /* ------------------------ ------------------ ------------------------*/\n export interface DefaultDateProps {\n onMonthChange: AppOnInputChange;\n onDayChange: AppOnInputChange;\n onYearChange: AppOnInputChange;\n onPickerOpen: TypescriptHelpersT.VoidGenericFunc;\n onPickerClose: TypescriptHelpersT.VoidGenericFunc;\n getIsDisabledDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsOutOfRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsStartRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsDayInRange: TypescriptHelpersT.BooleanGetter<string>;\n getIsEndRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n isClearable: boolean;\n disabled: boolean;\n readOnly: boolean;\n hasError: boolean;\n autoFocus: boolean;\n preventCloseOnSelection: boolean;\n }\n export interface OptionalDatePickerProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n > {\n applyAriaDisabled?: boolean;\n emptyPickerStartingMonth?: string;\n onCalendarOpenFocusedDay?: string;\n pickerFooterMsg?: string;\n innerRef?:\n | React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>\n | ((ref: HTMLInputElement | HTMLButtonElement | null) => void);\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n fromDate?: string;\n toDate?: string;\n }\n export interface RequiredDatePickerProps {\n type: 'full-date' | 'date-inputs' | 'date-picker' | 'date-picker-controller-only';\n date: string;\n onDateChange: OnDateChange;\n }\n export type DatePickerProps = PropsT<\n Partial<DefaultDateProps>,\n RequiredDatePickerProps,\n OptionalDatePickerProps,\n HTMLDivElement\n >;\n\n export type InternalDatePickerProps = InternalPropsT<\n DefaultDateProps,\n RequiredDatePickerProps,\n OptionalDatePickerProps,\n HTMLDivElement\n >;\n\n /* ------------------------ ------------------ ------------------------*/\n /* ------------------------ TIME CONFIGURATION ------------------------*/\n /* ------------------------ ------------------ ------------------------*/\n\n export interface DefaultTimeProps {\n onHourChange: AppOnInputChange;\n onMinuteChange: AppOnInputChange;\n onMeridiemChange: AppOnInputChange;\n onPickerOpen: TypescriptHelpersT.VoidGenericFunc;\n onPickerClose: TypescriptHelpersT.VoidGenericFunc;\n getIsDisabledTime: TypescriptHelpersT.BooleanGetter<string>;\n minutesInterval: number;\n isClearable: boolean;\n disabled: boolean;\n readOnly: boolean;\n hasError: boolean;\n autoFocus: boolean;\n preventCloseOnSelection: boolean;\n }\n export interface OptionalTimePickerProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n > {\n applyAriaDisabled?: boolean;\n pickerFooterMsg?: string;\n onTimeWheelOpenStartingTime?: string;\n innerRef?:\n | React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>\n | ((ref: HTMLInputElement | HTMLButtonElement | null) => void);\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n }\n export interface RequiredTimePickerProps {\n type: 'full-time' | 'time-inputs' | 'time-picker' | 'time-picker-controller-only';\n time: string;\n onTimeChange: OnTimeChange;\n }\n export type TimePickerProps = PropsT<\n Partial<DefaultTimeProps>,\n RequiredTimePickerProps,\n OptionalTimePickerProps,\n HTMLDivElement\n >;\n\n export type InternalTimePickerProps = InternalPropsT<\n DefaultTimeProps,\n RequiredTimePickerProps,\n OptionalTimePickerProps,\n HTMLDivElement\n >;\n\n /* -------------------- ---------------------- ------------------------*/\n /* -------------------- DATETIME CONFIGURATION ------------------------*/\n /* -------------------- ---------------------- ------------------------*/\n\n export type DefaultDateTimeProps = DefaultTimeProps &\n DefaultDateProps & {\n onDateChange: OnDateChange;\n onTimeChange: OnTimeChange;\n };\n export type OptionalDateTimeProps = OptionalTimePickerProps &\n OptionalDatePickerProps &\n TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n >;\n export interface RequiredDateTimeProps {\n type: 'full-date-time' | 'date-time-inputs' | 'date-time-picker' | 'date-time-picker-controller-only';\n dateTime: string;\n onDateTimeChange: OnDateTimeChange;\n }\n\n export type DateTimePickerProps = PropsT<\n Partial<DefaultDateTimeProps>,\n RequiredDateTimeProps,\n OptionalDateTimeProps,\n HTMLDivElement\n >;\n export type InternalDateTimePickerProps = InternalPropsT<\n DefaultDateTimeProps,\n RequiredDateTimeProps,\n OptionalDateTimeProps,\n HTMLDivElement\n >;\n\n /* ---------------------- ------------------- -------------------------*/\n /* ---------------------- FINAL CONFIGURATION -------------------------*/\n /* ---------------------- ------------------- -------------------------*/\n export type DefaultProps = DefaultDateTimeProps & { type: 'full-date-time' };\n\n export type Props = DateTimePickerProps | DatePickerProps | TimePickerProps;\n export type InternalProps = InternalDateTimePickerProps | InternalDatePickerProps | InternalTimePickerProps;\n}\n\nexport const defaultProps: DSControlledDateTimePickerT.DefaultProps = {\n type: 'full-date-time',\n onDateChange: noop,\n onMonthChange: noop,\n onDayChange: noop,\n onYearChange: noop,\n onTimeChange: noop,\n onHourChange: noop,\n onMinuteChange: noop,\n onMeridiemChange: noop,\n onPickerOpen: noop,\n onPickerClose: noop,\n getIsDisabledDay: defaultReturnFalse,\n getIsOutOfRangeDay: defaultReturnFalse,\n getIsStartRangeDay: defaultReturnFalse,\n getIsDayInRange: defaultReturnFalse,\n getIsEndRangeDay: defaultReturnFalse,\n getIsDisabledTime: defaultReturnFalse,\n minutesInterval: 1,\n isClearable: false,\n disabled: false,\n readOnly: false,\n hasError: false,\n autoFocus: false,\n preventCloseOnSelection: false,\n};\n\nexport const propTypes = {\n ...getPropsPerSlotPropTypes(DSControlledDateTimePickerName, DSControlledDateTimePickerSlotsFlatten),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n type: PropTypes.oneOf([\n 'full-date-time',\n 'date-time-inputs',\n 'date-time-picker',\n 'date-time-picker-controller-only',\n 'full-date',\n 'date-inputs',\n 'date-picker',\n 'date-picker-controller-only',\n 'full-time',\n 'time-inputs',\n 'time-picker',\n 'time-picker-controller-only',\n ])\n .description('Type of time form control to use')\n .defaultValue('full-date-time'),\n disabled: PropTypes.bool.description('wheter or not the input is disabled').defaultValue(false),\n applyAriaDisabled: PropTypes.bool.description(\n 'Whether to apply disabled styling and announce as disabled in SR. CAN STILL RECEIVE FOCUS. PREVENTS ONLY MAIN ACTION.',\n ),\n readOnly: PropTypes.bool\n .description('Makes the component non-editable while remaining accessible')\n .defaultValue(false),\n isClearable: PropTypes.bool.description('with or without clearable button').defaultValue(false),\n dateTime: PropTypes.string.description('when using date-time types, this is the value of the controller'),\n date: PropTypes.string.description('when using date types, this is the value of the controller'),\n time: PropTypes.string.description('when using time types, this is the value of the controller'),\n onDateChange: PropTypes.func.description('(newDateString, metaInformations) => void'),\n onTimeChange: PropTypes.func.description('(newTimeString, metaInformations) => void'),\n onDateTimeChange: PropTypes.func.description('(newDateTimeString, metaInformations) => void'),\n onMonthChange: PropTypes.func.description('(newMonthString, event, metaInformations) => void'),\n onDayChange: PropTypes.func.description('(newDayString, event, metaInformations) => void'),\n onYearChange: PropTypes.func.description('(newYearString, event, metaInformations) => void'),\n onHourChange: PropTypes.func.description('(newHourString, event, metaInformations) => void'),\n onMinuteChange: PropTypes.func.description('(newMinuteString, event, metaInformations) => void'),\n onMeridiemChange: PropTypes.func.description('(newMeridiemString, event, metaInformations) => void'),\n getIsDisabledDay: PropTypes.func.description(\n '(dayAsString) => true for marking as disabled, false for marking as valid',\n ),\n getIsOutOfRangeDay: PropTypes.func.description(\n '(dayAsString) => true for marking as disabled, false for marking as valid',\n ),\n getIsDisabledTime: PropTypes.func.description(\n '(timeAsString) => true for marking as disabled, false for marking as valid',\n ),\n emptyPickerStartingMonth: PropTypes.string.description(\n 'which month to start the calendar on open, when value is empty, string following the \"MM/__/YYYY\" pattern',\n ),\n onCalendarOpenFocusedDay: PropTypes.string\n .description('which day to focus on calendar open when value is empty, string following the \"MM/DD/YYYY\" pattern')\n .defaultValue('if value is empty current month, else current month'),\n onTimeWheelOpenStartingTime: PropTypes.string\n .description(\n 'which day to start the timewheel on picker open when value is empty, string following the HH:MM AA\" pattern',\n )\n .defaultValue('01:00 AM'),\n minutesInterval: PropTypes.number\n .description('increments/decrements of minutes in time related controllers interactions')\n .defaultValue('1'),\n 'data-testid': PropTypes.string.description('Unique id for tests.').defaultValue(''),\n ...getPropsPerDatatestIdPropTypes(ControlledDateTimePickerDatatestid),\n innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).description('inner ref for the month input'),\n fromDate: PropTypes.string.description(\n `Strictly formatted string representing user's selected \"from\" date, this prop comes from the DateRangePicker and it's used internally for the range selection announcement`,\n ),\n toDate: PropTypes.string.description(\n `Strictly formatted string representing user's selected \"to\" date, this prop comes from the DateRangePicker and it's used internally for the range selection announcement`,\n ),\n hasError: PropTypes.bool.description('whether the input has error or not').defaultValue(false),\n} as unknown as ValidationMap<DSControlledDateTimePickerT.Props>;\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\nimport {\n PropTypes,\n getPropsPerDatatestIdPropTypes,\n getPropsPerSlotPropTypes,\n globalAttributesPropTypes,\n xstyledPropTypes,\n type GlobalAttributesT,\n type ValidationMap,\n type XstyledProps,\n} from '@elliemae/ds-props-helpers';\nimport type { TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type React from 'react';\nimport type { FORM_DATE_TIME_PICKER_SLOTS } from './constants/index.js';\nimport {\n ControlledDateTimePickerDatatestid,\n DSControlledDateTimePickerName,\n DSControlledDateTimePickerSlotsFlatten,\n} from './constants/index.js';\n\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nconst noop = (): void => {};\nconst defaultReturnFalse = (): false => false;\n\nexport declare namespace DSControlledDateTimePickerT {\n export type SlotFunctionArguments = {\n dsControlleddatetimepickerRoot: () => object;\n dsControlleddatetimepickerTimePickerMonthInput: () => object;\n dsControlleddatetimepickerTimePickerDayInput: () => object;\n dsControlleddatetimepickerTimePickerYearInput: () => object;\n dsControlleddatetimepickerTimePickerHourInput: () => object;\n dsControlleddatetimepickerTimePickerMinuteInput: () => object;\n dsControlleddatetimepickerTimePickerMeridiemInput: () => object;\n dsControlleddatetimepickerCalendarTriggerIcon: () => object;\n dsControlleddatetimepickerTimewheelTriggerIcon: () => object;\n dsControlleddatetimepickerCalendarTimewheelTriggerIcon: () => object;\n dsControlleddatetimepickerCalendarDay: () => object;\n dsControlleddatetimepickerCalendarHeaderLabel: () => object;\n dsControlleddatetimepickerCalendarHeaderButtons: () => object;\n dsControlleddatetimepickerCalendarHeaderWeeklyDayList: () => object;\n dsControlleddatetimepickerTimewheelTimeButton: () => object;\n dsControlleddatetimepickerTimewheelTimeChangeButton: () => object;\n dsControlleddatetimepickerTimewheelHeaderLabel: () => object;\n dsControlleddatetimepickerCalendarContextContentWrapper: () => object;\n dsControlleddatetimepickerTimewheelContextContentWrapper: () => object;\n dsControlleddatetimepickerCalendarTimewheelContextContentWrapper: () => object;\n dsControlleddatetimepickerCalendarContextFooter: () => object;\n dsControlleddatetimepickerTimewheelContextFooter: () => object;\n dsControlleddatetimepickerCalendarTimewheelContextFooter: () => object;\n dsControlleddatetimepickerCalendarControllerWrapper: () => object;\n dsControlleddatetimepickerTimewheelControllerWrapper: () => object;\n dsControlleddatetimepickerCalendarTimewheelControllerWrapper: () => object;\n dsControlleddatetimepickerClearBtn: () => object;\n };\n\n type PropsT<Default, Required, Optional, SpecificHTMLElement> = Partial<Default> &\n Required &\n Optional &\n TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof FORM_DATE_TIME_PICKER_SLOTS\n > &\n Omit<GlobalAttributesT<SpecificHTMLElement>, keyof Default | keyof Required | keyof Optional> &\n Omit<XstyledProps, keyof Default | keyof Required | keyof Optional>;\n\n type InternalPropsT<Default, Required, Optional, SpecificHTMLElement> = Default &\n Required &\n Optional &\n TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof FORM_DATE_TIME_PICKER_SLOTS\n > &\n Omit<GlobalAttributesT<SpecificHTMLElement>, keyof Default | keyof Required | keyof Optional> &\n Omit<XstyledProps, keyof Default | keyof Required | keyof Optional>;\n type DataTestIdType = typeof ControlledDateTimePickerDatatestid;\n // typescript type that rapresents the union of all the values for ControlledDateTimePickerDatatestid\n export type FlatDataTestIdValues = {\n [K in keyof DataTestIdType]: DataTestIdType[K] extends Record<string, unknown>\n ? DataTestIdType[K][keyof DataTestIdType[K]] // this is only 1 level deep, but it's enough for our needs right now\n : // can be extended to more levels if needed as follows:\n // ? DataTestIdType[K][keyof DataTestIdType[K]] extends Record<string, unknown>\n // ? DataTestIdType[K][keyof DataTestIdType[K]][keyof DataTestIdType[K][keyof DataTestIdType[K]]]\n // : DataTestIdType[K][keyof DataTestIdType[K]]\n DataTestIdType[K];\n }[keyof DataTestIdType];\n\n export type OnInternalValuesChangeEvent =\n | React.ChangeEvent<HTMLInputElement>\n | React.KeyboardEvent<HTMLInputElement>\n | React.KeyboardEvent<HTMLButtonElement>\n | React.KeyboardEvent\n | React.MouseEvent<HTMLInputElement>\n | React.MouseEvent<HTMLButtonElement>\n | React.MouseEvent<HTMLDivElement>;\n\n export type ControlTypes =\n | 'full-date-time'\n | 'date-time-inputs'\n | 'date-time-picker'\n | 'date-time-picker-controller-only'\n | 'full-date'\n | 'date-inputs'\n | 'date-picker'\n | 'date-picker-controller-only'\n | 'full-time'\n | 'time-inputs'\n | 'time-picker'\n | 'time-picker-controller-only';\n export interface InternalInputsChangeMetaInfo {\n isAutomaticFillTrigger?: boolean;\n isDayPresentInMonth?: boolean;\n isOutOfRangeDay?: boolean;\n isDisabledDay?: boolean;\n isDisabledTime?: boolean;\n suggestedErrorMsg?: string;\n newDateTimeString?: string;\n newDateString?: string;\n newTimeString?: string;\n }\n\n export type OnDateChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnTimeChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnDateTimeChange = (val: string, metaInfo: InternalInputsChangeMetaInfo) => void;\n export type OnInternalInputsChange = (\n val: string,\n e: OnInternalValuesChangeEvent,\n metaInfo?: InternalInputsChangeMetaInfo,\n ) => void;\n export type AppOnInputChange = (\n val: string,\n e: OnInternalValuesChangeEvent,\n metaInfo: InternalInputsChangeMetaInfo,\n ) => void;\n\n /* ------------------------ ------------------ ------------------------*/\n /* ------------------------ DATE CONFIGURATION ------------------------*/\n /* ------------------------ ------------------ ------------------------*/\n export interface DefaultDateProps {\n onMonthChange: AppOnInputChange;\n onDayChange: AppOnInputChange;\n onYearChange: AppOnInputChange;\n onPickerOpen: TypescriptHelpersT.VoidGenericFunc;\n onPickerClose: TypescriptHelpersT.VoidGenericFunc;\n getIsDisabledDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsOutOfRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsStartRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n getIsDayInRange: TypescriptHelpersT.BooleanGetter<string>;\n getIsEndRangeDay: TypescriptHelpersT.BooleanGetter<string>;\n isClearable: boolean;\n disabled: boolean;\n readOnly: boolean;\n hasError: boolean;\n autoFocus: boolean;\n preventCloseOnSelection: boolean;\n }\n export interface OptionalDatePickerProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n > {\n applyAriaDisabled?: boolean;\n emptyPickerStartingMonth?: string;\n onCalendarOpenFocusedDay?: string;\n pickerFooterMsg?: string;\n innerRef?:\n | React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>\n | ((ref: HTMLInputElement | HTMLButtonElement | null) => void);\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n fromDate?: string;\n toDate?: string;\n }\n export interface RequiredDatePickerProps {\n type: 'full-date' | 'date-inputs' | 'date-picker' | 'date-picker-controller-only';\n date: string;\n onDateChange: OnDateChange;\n }\n export type DatePickerProps = PropsT<\n Partial<DefaultDateProps>,\n RequiredDatePickerProps,\n OptionalDatePickerProps,\n HTMLDivElement\n >;\n\n export type InternalDatePickerProps = InternalPropsT<\n DefaultDateProps,\n RequiredDatePickerProps,\n OptionalDatePickerProps,\n HTMLDivElement\n >;\n\n /* ------------------------ ------------------ ------------------------*/\n /* ------------------------ TIME CONFIGURATION ------------------------*/\n /* ------------------------ ------------------ ------------------------*/\n\n export interface DefaultTimeProps {\n onHourChange: AppOnInputChange;\n onMinuteChange: AppOnInputChange;\n onMeridiemChange: AppOnInputChange;\n onPickerOpen: TypescriptHelpersT.VoidGenericFunc;\n onPickerClose: TypescriptHelpersT.VoidGenericFunc;\n getIsDisabledTime: TypescriptHelpersT.BooleanGetter<string>;\n minutesInterval: number;\n isClearable: boolean;\n disabled: boolean;\n readOnly: boolean;\n hasError: boolean;\n autoFocus: boolean;\n preventCloseOnSelection: boolean;\n }\n export interface OptionalTimePickerProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n > {\n applyAriaDisabled?: boolean;\n pickerFooterMsg?: string;\n onTimeWheelOpenStartingTime?: string;\n innerRef?:\n | React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>\n | ((ref: HTMLInputElement | HTMLButtonElement | null) => void);\n tabIndex?: TypescriptHelpersT.WCAGTabIndex;\n }\n export interface RequiredTimePickerProps {\n type: 'full-time' | 'time-inputs' | 'time-picker' | 'time-picker-controller-only';\n time: string;\n onTimeChange: OnTimeChange;\n }\n export type TimePickerProps = PropsT<\n Partial<DefaultTimeProps>,\n RequiredTimePickerProps,\n OptionalTimePickerProps,\n HTMLDivElement\n >;\n\n export type InternalTimePickerProps = InternalPropsT<\n DefaultTimeProps,\n RequiredTimePickerProps,\n OptionalTimePickerProps,\n HTMLDivElement\n >;\n\n /* -------------------- ---------------------- ------------------------*/\n /* -------------------- DATETIME CONFIGURATION ------------------------*/\n /* -------------------- ---------------------- ------------------------*/\n\n export type DefaultDateTimeProps = DefaultTimeProps &\n DefaultDateProps & {\n onDateChange: OnDateChange;\n onTimeChange: OnTimeChange;\n };\n export type OptionalDateTimeProps = OptionalTimePickerProps &\n OptionalDatePickerProps &\n TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSControlledDateTimePickerName,\n typeof DSControlledDateTimePickerSlotsFlatten\n >;\n export interface RequiredDateTimeProps {\n type: 'full-date-time' | 'date-time-inputs' | 'date-time-picker' | 'date-time-picker-controller-only';\n dateTime: string;\n onDateTimeChange: OnDateTimeChange;\n }\n\n export type DateTimePickerProps = PropsT<\n Partial<DefaultDateTimeProps>,\n RequiredDateTimeProps,\n OptionalDateTimeProps,\n HTMLDivElement\n >;\n export type InternalDateTimePickerProps = InternalPropsT<\n DefaultDateTimeProps,\n RequiredDateTimeProps,\n OptionalDateTimeProps,\n HTMLDivElement\n >;\n\n /* ---------------------- ------------------- -------------------------*/\n /* ---------------------- FINAL CONFIGURATION -------------------------*/\n /* ---------------------- ------------------- -------------------------*/\n export type DefaultProps = DefaultDateTimeProps & { type: 'full-date-time' };\n\n export type Props = DateTimePickerProps | DatePickerProps | TimePickerProps;\n export type InternalProps = InternalDateTimePickerProps | InternalDatePickerProps | InternalTimePickerProps;\n}\n\nexport const defaultProps: DSControlledDateTimePickerT.DefaultProps = {\n type: 'full-date-time',\n onDateChange: noop,\n onMonthChange: noop,\n onDayChange: noop,\n onYearChange: noop,\n onTimeChange: noop,\n onHourChange: noop,\n onMinuteChange: noop,\n onMeridiemChange: noop,\n onPickerOpen: noop,\n onPickerClose: noop,\n getIsDisabledDay: defaultReturnFalse,\n getIsOutOfRangeDay: defaultReturnFalse,\n getIsStartRangeDay: defaultReturnFalse,\n getIsDayInRange: defaultReturnFalse,\n getIsEndRangeDay: defaultReturnFalse,\n getIsDisabledTime: defaultReturnFalse,\n minutesInterval: 1,\n isClearable: false,\n disabled: false,\n readOnly: false,\n hasError: false,\n autoFocus: false,\n preventCloseOnSelection: false,\n};\n\nexport const propTypes = {\n ...getPropsPerSlotPropTypes(DSControlledDateTimePickerName, DSControlledDateTimePickerSlotsFlatten),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n type: PropTypes.oneOf([\n 'full-date-time',\n 'date-time-inputs',\n 'date-time-picker',\n 'date-time-picker-controller-only',\n 'full-date',\n 'date-inputs',\n 'date-picker',\n 'date-picker-controller-only',\n 'full-time',\n 'time-inputs',\n 'time-picker',\n 'time-picker-controller-only',\n ])\n .description('Type of time form control to use')\n .defaultValue('full-date-time'),\n disabled: PropTypes.bool.description('wheter or not the input is disabled').defaultValue(false),\n applyAriaDisabled: PropTypes.bool.description(\n 'Whether to apply disabled styling and announce as disabled in SR. CAN STILL RECEIVE FOCUS. PREVENTS ONLY MAIN ACTION.',\n ),\n readOnly: PropTypes.bool\n .description('Makes the component non-editable while remaining accessible')\n .defaultValue(false),\n isClearable: PropTypes.bool.description('with or without clearable button').defaultValue(false),\n dateTime: PropTypes.string.description('when using date-time types, this is the value of the controller'),\n date: PropTypes.string.description('when using date types, this is the value of the controller'),\n time: PropTypes.string.description('when using time types, this is the value of the controller'),\n onDateChange: PropTypes.func.description('(newDateString, metaInformations) => void'),\n onTimeChange: PropTypes.func.description('(newTimeString, metaInformations) => void'),\n onDateTimeChange: PropTypes.func.description('(newDateTimeString, metaInformations) => void'),\n onMonthChange: PropTypes.func.description('(newMonthString, event, metaInformations) => void'),\n onDayChange: PropTypes.func.description('(newDayString, event, metaInformations) => void'),\n onYearChange: PropTypes.func.description('(newYearString, event, metaInformations) => void'),\n onHourChange: PropTypes.func.description('(newHourString, event, metaInformations) => void'),\n onMinuteChange: PropTypes.func.description('(newMinuteString, event, metaInformations) => void'),\n onMeridiemChange: PropTypes.func.description('(newMeridiemString, event, metaInformations) => void'),\n getIsDisabledDay: PropTypes.func.description(\n '(dayAsString) => true for marking as disabled, false for marking as valid',\n ),\n getIsOutOfRangeDay: PropTypes.func.description(\n '(dayAsString) => true for marking as disabled, false for marking as valid',\n ),\n getIsDisabledTime: PropTypes.func.description(\n '(timeAsString) => true for marking as disabled, false for marking as valid',\n ),\n emptyPickerStartingMonth: PropTypes.string.description(\n 'which month to start the calendar on open, when value is empty, string following the \"MM/__/YYYY\" pattern',\n ),\n onCalendarOpenFocusedDay: PropTypes.string\n .description('which day to focus on calendar open when value is empty, string following the \"MM/DD/YYYY\" pattern')\n .defaultValue('if value is empty current month, else current month'),\n onTimeWheelOpenStartingTime: PropTypes.string\n .description(\n 'which day to start the timewheel on picker open when value is empty, string following the HH:MM AA\" pattern',\n )\n .defaultValue('01:00 AM'),\n minutesInterval: PropTypes.number\n .description('increments/decrements of minutes in time related controllers interactions')\n .defaultValue('1'),\n 'data-testid': PropTypes.string.description('Unique id for tests.').defaultValue(''),\n ...getPropsPerDatatestIdPropTypes(ControlledDateTimePickerDatatestid),\n innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).description('inner ref for the month input'),\n fromDate: PropTypes.string.description(\n `Strictly formatted string representing user's selected \"from\" date, this prop comes from the DateRangePicker and it's used internally for the range selection announcement`,\n ),\n toDate: PropTypes.string.description(\n `Strictly formatted string representing user's selected \"to\" date, this prop comes from the DateRangePicker and it's used internally for the range selection announcement`,\n ),\n hasError: PropTypes.bool.description('whether the input has error or not').defaultValue(false),\n} as unknown as ValidationMap<DSControlledDateTimePickerT.Props>;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACCvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIK;AAIP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAGP,MAAM,OAAO,MAAY;AAAC;AAC1B,MAAM,qBAAqB,MAAa;AA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Object = {
|
|
3
|
+
dsControlleddatetimepickerRoot: { "aria-label": "just a typescript test" },
|
|
4
|
+
dsControlleddatetimepickerTimePickerMonthInput: { "aria-label": "just a typescript test" },
|
|
5
|
+
dsControlleddatetimepickerTimePickerDayInput: { "aria-label": "just a typescript test" },
|
|
6
|
+
dsControlleddatetimepickerTimePickerYearInput: { "aria-label": "just a typescript test" },
|
|
7
|
+
dsControlleddatetimepickerTimePickerHourInput: { "aria-label": "just a typescript test" },
|
|
8
|
+
dsControlleddatetimepickerTimePickerMinuteInput: { "aria-label": "just a typescript test" },
|
|
9
|
+
dsControlleddatetimepickerTimePickerMeridiemInput: { "aria-label": "just a typescript test" },
|
|
10
|
+
dsControlleddatetimepickerCalendarTriggerIcon: { "aria-label": "just a typescript test" },
|
|
11
|
+
dsControlleddatetimepickerTimewheelTriggerIcon: { "aria-label": "just a typescript test" },
|
|
12
|
+
dsControlleddatetimepickerCalendarTimewheelTriggerIcon: { "aria-label": "just a typescript test" },
|
|
13
|
+
dsControlleddatetimepickerCalendarDay: { "aria-label": "just a typescript test" },
|
|
14
|
+
dsControlleddatetimepickerCalendarHeaderLabel: { "aria-label": "just a typescript test" },
|
|
15
|
+
dsControlleddatetimepickerCalendarHeaderButtons: { "aria-label": "just a typescript test" },
|
|
16
|
+
dsControlleddatetimepickerCalendarHeaderWeeklyDayList: { "aria-label": "just a typescript test" },
|
|
17
|
+
dsControlleddatetimepickerTimewheelTimeButton: { "aria-label": "just a typescript test" },
|
|
18
|
+
dsControlleddatetimepickerTimewheelTimeChangeButton: { "aria-label": "just a typescript test" },
|
|
19
|
+
dsControlleddatetimepickerTimewheelHeaderLabel: { "aria-label": "just a typescript test" },
|
|
20
|
+
dsControlleddatetimepickerCalendarContextContentWrapper: { "aria-label": "just a typescript test" },
|
|
21
|
+
dsControlleddatetimepickerTimewheelContextContentWrapper: { "aria-label": "just a typescript test" },
|
|
22
|
+
dsControlleddatetimepickerCalendarTimewheelContextContentWrapper: { "aria-label": "just a typescript test" },
|
|
23
|
+
dsControlleddatetimepickerCalendarContextFooter: { "aria-label": "just a typescript test" },
|
|
24
|
+
dsControlleddatetimepickerTimewheelContextFooter: { "aria-label": "just a typescript test" },
|
|
25
|
+
dsControlleddatetimepickerCalendarTimewheelContextFooter: { "aria-label": "just a typescript test" },
|
|
26
|
+
dsControlleddatetimepickerCalendarControllerWrapper: { "aria-label": "just a typescript test" },
|
|
27
|
+
dsControlleddatetimepickerTimewheelControllerWrapper: { "aria-label": "just a typescript test" },
|
|
28
|
+
dsControlleddatetimepickerCalendarTimewheelControllerWrapper: { "aria-label": "just a typescript test" },
|
|
29
|
+
dsControlleddatetimepickerClearBtn: { "aria-label": "just a typescript test" }
|
|
30
|
+
};
|
|
31
|
+
const SlotPropsAsFunctions = {
|
|
32
|
+
dsControlleddatetimepickerRoot: () => ({ "aria-label": "just a typescript test" }),
|
|
33
|
+
dsControlleddatetimepickerTimePickerMonthInput: () => ({ "aria-label": "just a typescript test" }),
|
|
34
|
+
dsControlleddatetimepickerTimePickerDayInput: () => ({ "aria-label": "just a typescript test" }),
|
|
35
|
+
dsControlleddatetimepickerTimePickerYearInput: () => ({ "aria-label": "just a typescript test" }),
|
|
36
|
+
dsControlleddatetimepickerTimePickerHourInput: () => ({ "aria-label": "just a typescript test" }),
|
|
37
|
+
dsControlleddatetimepickerTimePickerMinuteInput: () => ({ "aria-label": "just a typescript test" }),
|
|
38
|
+
dsControlleddatetimepickerTimePickerMeridiemInput: () => ({ "aria-label": "just a typescript test" }),
|
|
39
|
+
dsControlleddatetimepickerCalendarTriggerIcon: () => ({ "aria-label": "just a typescript test" }),
|
|
40
|
+
dsControlleddatetimepickerTimewheelTriggerIcon: () => ({ "aria-label": "just a typescript test" }),
|
|
41
|
+
dsControlleddatetimepickerCalendarTimewheelTriggerIcon: () => ({ "aria-label": "just a typescript test" }),
|
|
42
|
+
dsControlleddatetimepickerCalendarDay: () => ({ "aria-label": "just a typescript test" }),
|
|
43
|
+
dsControlleddatetimepickerCalendarHeaderLabel: () => ({ "aria-label": "just a typescript test" }),
|
|
44
|
+
dsControlleddatetimepickerCalendarHeaderButtons: () => ({ "aria-label": "just a typescript test" }),
|
|
45
|
+
dsControlleddatetimepickerCalendarHeaderWeeklyDayList: () => ({ "aria-label": "just a typescript test" }),
|
|
46
|
+
dsControlleddatetimepickerTimewheelTimeButton: () => ({ "aria-label": "just a typescript test" }),
|
|
47
|
+
dsControlleddatetimepickerTimewheelTimeChangeButton: () => ({ "aria-label": "just a typescript test" }),
|
|
48
|
+
dsControlleddatetimepickerTimewheelHeaderLabel: () => ({ "aria-label": "just a typescript test" }),
|
|
49
|
+
dsControlleddatetimepickerCalendarContextContentWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
50
|
+
dsControlleddatetimepickerTimewheelContextContentWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
51
|
+
dsControlleddatetimepickerCalendarTimewheelContextContentWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
52
|
+
dsControlleddatetimepickerCalendarContextFooter: () => ({ "aria-label": "just a typescript test" }),
|
|
53
|
+
dsControlleddatetimepickerTimewheelContextFooter: () => ({ "aria-label": "just a typescript test" }),
|
|
54
|
+
dsControlleddatetimepickerCalendarTimewheelContextFooter: () => ({ "aria-label": "just a typescript test" }),
|
|
55
|
+
dsControlleddatetimepickerCalendarControllerWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
56
|
+
dsControlleddatetimepickerTimewheelControllerWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
57
|
+
dsControlleddatetimepickerCalendarTimewheelControllerWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
58
|
+
dsControlleddatetimepickerClearBtn: () => ({ "aria-label": "just a typescript test" })
|
|
59
|
+
};
|
|
60
|
+
const EnsureAllSlotsExistInSlotFunctionArguments = SlotPropsAsFunctions;
|
|
61
|
+
//# sourceMappingURL=slot-props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/typescript-testing/slot-props.ts"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-unused-vars, no-unused-vars */\nimport type { TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { DSControlledDateTimePickerName, FORM_DATE_TIME_PICKER_SLOTS } from '../constants/index.js';\nimport type { DSControlledDateTimePickerT } from '../index.js';\n\nconst SlotPropsAsObject: Partial<DSControlledDateTimePickerT.Props> = {\n dsControlleddatetimepickerRoot: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerMonthInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerDayInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerYearInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerHourInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerMinuteInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimePickerMeridiemInput: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarTriggerIcon: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelTriggerIcon: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarTimewheelTriggerIcon: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarDay: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarHeaderLabel: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarHeaderButtons: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarHeaderWeeklyDayList: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelTimeButton: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelTimeChangeButton: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelHeaderLabel: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarContextContentWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelContextContentWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarTimewheelContextContentWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarContextFooter: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelContextFooter: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarTimewheelContextFooter: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarControllerWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerTimewheelControllerWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerCalendarTimewheelControllerWrapper: { 'aria-label': 'just a typescript test' },\n dsControlleddatetimepickerClearBtn: { 'aria-label': 'just a typescript test' },\n};\nconst SlotPropsAsFunctions: DSControlledDateTimePickerT.SlotFunctionArguments = {\n dsControlleddatetimepickerRoot: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerMonthInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerDayInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerYearInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerHourInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerMinuteInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimePickerMeridiemInput: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarTriggerIcon: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelTriggerIcon: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarTimewheelTriggerIcon: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarDay: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarHeaderLabel: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarHeaderButtons: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarHeaderWeeklyDayList: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelTimeButton: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelTimeChangeButton: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelHeaderLabel: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarContextContentWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelContextContentWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarTimewheelContextContentWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarContextFooter: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelContextFooter: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarTimewheelContextFooter: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarControllerWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerTimewheelControllerWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerCalendarTimewheelControllerWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsControlleddatetimepickerClearBtn: () => ({ 'aria-label': 'just a typescript test' }),\n};\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSControlledDateTimePickerName, typeof FORM_DATE_TIME_PICKER_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACKvB,MAAM,oBAAgE;AAAA,EACpE,gCAAgC,EAAE,cAAc,yBAAyB;AAAA,EACz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
-
/// <reference types="react" />
|
|
2
1
|
import type { DSControlledDateTimePickerT } from './react-desc-prop-types.js';
|
|
3
2
|
declare const DSControlledDateTimePicker: {
|
|
4
3
|
(props: DSControlledDateTimePickerT.Props): JSX.Element;
|
|
5
4
|
displayName: string;
|
|
6
5
|
};
|
|
7
6
|
declare const DSControlledDateTimePickerWithSchema: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").DocumentedReactComponent<DSControlledDateTimePickerT.Props>;
|
|
8
|
-
export {
|
|
7
|
+
export { DSControlledDateTimePicker, DSControlledDateTimePickerWithSchema };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import type { ControlledDateTimePickerContextT } from './config/useControlledDateTimePicker.js';
|
|
3
2
|
/** Context for cross component communication */
|
|
4
3
|
export declare const ControlledDateTimePickerContext: import("react").Context<ControlledDateTimePickerContextT>;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import type { useGetReferences } from './useGetReferences.js';
|
|
3
2
|
import type { useGetFlags } from './useGetFlags.js';
|
|
4
3
|
type LatestInteractionRegion = 'calendar-days' | 'calendar-head' | 'timewheel' | 'date-inputs' | 'time-inputs' | 'clear-btn' | 'picker-icon' | '';
|