@elliemae/ds-form-date-time-picker 3.16.0 → 3.16.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (427) hide show
  1. package/dist/cjs/ControlledDateTimePicker.js +9 -5
  2. package/dist/cjs/ControlledDateTimePicker.js.map +2 -2
  3. package/dist/cjs/ControlledDateTimePickerCTX.js +4 -0
  4. package/dist/cjs/ControlledDateTimePickerCTX.js.map +2 -2
  5. package/dist/cjs/ControlledDateTimePickerDatatestid.js +4 -0
  6. package/dist/cjs/ControlledDateTimePickerDatatestid.js.map +1 -1
  7. package/dist/cjs/ControlledDateTimePickerTypes.js +4 -0
  8. package/dist/cjs/ControlledDateTimePickerTypes.js.map +1 -1
  9. package/dist/cjs/config/useChangeHandlers.js +9 -4
  10. package/dist/cjs/config/useChangeHandlers.js.map +2 -2
  11. package/dist/cjs/config/useControlledDateTimePicker.js +15 -10
  12. package/dist/cjs/config/useControlledDateTimePicker.js.map +2 -2
  13. package/dist/cjs/config/useFocusTracker.js +4 -0
  14. package/dist/cjs/config/useFocusTracker.js.map +2 -2
  15. package/dist/cjs/config/useGetDestructuredValues.js +11 -4
  16. package/dist/cjs/config/useGetDestructuredValues.js.map +2 -2
  17. package/dist/cjs/config/useGetFlags.js +6 -2
  18. package/dist/cjs/config/useGetFlags.js.map +2 -2
  19. package/dist/cjs/config/useGetPropsBasedOnType.js +6 -2
  20. package/dist/cjs/config/useGetPropsBasedOnType.js.map +2 -2
  21. package/dist/cjs/config/useGetPropsWithDefault.js +5 -1
  22. package/dist/cjs/config/useGetPropsWithDefault.js.map +2 -2
  23. package/dist/cjs/config/useGetReferences.js +4 -0
  24. package/dist/cjs/config/useGetReferences.js.map +2 -2
  25. package/dist/cjs/config/useGlobalKeyHandlers.js +8 -4
  26. package/dist/cjs/config/useGlobalKeyHandlers.js.map +2 -2
  27. package/dist/cjs/config/useRelevantValueFromProps.js +6 -2
  28. package/dist/cjs/config/useRelevantValueFromProps.js.map +2 -2
  29. package/dist/cjs/config/useValidateProps.js +7 -3
  30. package/dist/cjs/config/useValidateProps.js.map +2 -2
  31. package/dist/cjs/exported-related/theming.js +4 -0
  32. package/dist/cjs/exported-related/theming.js.map +1 -1
  33. package/dist/cjs/index.js +13 -9
  34. package/dist/cjs/index.js.map +2 -2
  35. package/dist/cjs/package.json +7 -0
  36. package/dist/cjs/parts/ClearButton/ClearButton.js +8 -4
  37. package/dist/cjs/parts/ClearButton/ClearButton.js.map +2 -2
  38. package/dist/cjs/parts/ClearButton/useClearButton.js +5 -1
  39. package/dist/cjs/parts/ClearButton/useClearButton.js.map +2 -2
  40. package/dist/cjs/parts/ControlledDateTimePickerContent.js +11 -7
  41. package/dist/cjs/parts/ControlledDateTimePickerContent.js.map +2 -2
  42. package/dist/cjs/parts/DateInputs/DDInput.js +6 -2
  43. package/dist/cjs/parts/DateInputs/DDInput.js.map +2 -2
  44. package/dist/cjs/parts/DateInputs/DateInputs.js +12 -8
  45. package/dist/cjs/parts/DateInputs/DateInputs.js.map +2 -2
  46. package/dist/cjs/parts/DateInputs/MMInput.js +6 -2
  47. package/dist/cjs/parts/DateInputs/MMInput.js.map +2 -2
  48. package/dist/cjs/parts/DateInputs/YYYYInput.js +6 -2
  49. package/dist/cjs/parts/DateInputs/YYYYInput.js.map +2 -2
  50. package/dist/cjs/parts/DateInputs/useDateInputs.js +8 -4
  51. package/dist/cjs/parts/DateInputs/useDateInputs.js.map +2 -2
  52. package/dist/cjs/parts/Pickers/Calendar/Calendar.js +9 -5
  53. package/dist/cjs/parts/Pickers/Calendar/Calendar.js.map +2 -2
  54. package/dist/cjs/parts/Pickers/Calendar/CalendarBody.js +7 -3
  55. package/dist/cjs/parts/Pickers/Calendar/CalendarBody.js.map +2 -2
  56. package/dist/cjs/parts/Pickers/Calendar/CalendarContent.js +11 -7
  57. package/dist/cjs/parts/Pickers/Calendar/CalendarContent.js.map +2 -2
  58. package/dist/cjs/parts/Pickers/Calendar/CalendarContext.js +4 -0
  59. package/dist/cjs/parts/Pickers/Calendar/CalendarContext.js.map +2 -2
  60. package/dist/cjs/parts/Pickers/Calendar/CalendarDaysList.js +6 -2
  61. package/dist/cjs/parts/Pickers/Calendar/CalendarDaysList.js.map +2 -2
  62. package/dist/cjs/parts/Pickers/Calendar/CalendarFooter.js +7 -3
  63. package/dist/cjs/parts/Pickers/Calendar/CalendarFooter.js.map +2 -2
  64. package/dist/cjs/parts/Pickers/Calendar/CalendarHead.js +9 -5
  65. package/dist/cjs/parts/Pickers/Calendar/CalendarHead.js.map +2 -2
  66. package/dist/cjs/parts/Pickers/Calendar/CalendarIconTrigger.js +8 -4
  67. package/dist/cjs/parts/Pickers/Calendar/CalendarIconTrigger.js.map +2 -2
  68. package/dist/cjs/parts/Pickers/Calendar/CalendarMonthDays.js +7 -3
  69. package/dist/cjs/parts/Pickers/Calendar/CalendarMonthDays.js.map +2 -2
  70. package/dist/cjs/parts/Pickers/Calendar/CalendarWeekDays.js +5 -1
  71. package/dist/cjs/parts/Pickers/Calendar/CalendarWeekDays.js.map +2 -2
  72. package/dist/cjs/parts/Pickers/Calendar/CalendarWrapper.js +8 -4
  73. package/dist/cjs/parts/Pickers/Calendar/CalendarWrapper.js.map +2 -2
  74. package/dist/cjs/parts/Pickers/Calendar/Day.js +11 -7
  75. package/dist/cjs/parts/Pickers/Calendar/Day.js.map +2 -2
  76. package/dist/cjs/parts/Pickers/Calendar/Styleds.js +5 -1
  77. package/dist/cjs/parts/Pickers/Calendar/Styleds.js.map +2 -2
  78. package/dist/cjs/parts/Pickers/Calendar/useConfigCalendarCTX.js +9 -5
  79. package/dist/cjs/parts/Pickers/Calendar/useConfigCalendarCTX.js.map +2 -2
  80. package/dist/cjs/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.js +6 -2
  81. package/dist/cjs/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.js.map +2 -2
  82. package/dist/cjs/parts/Pickers/Calendar/useFocusLogic.js +6 -2
  83. package/dist/cjs/parts/Pickers/Calendar/useFocusLogic.js.map +2 -2
  84. package/dist/cjs/parts/Pickers/Calendar/useKeyboardHandlers.js +7 -2
  85. package/dist/cjs/parts/Pickers/Calendar/useKeyboardHandlers.js.map +2 -2
  86. package/dist/cjs/parts/Pickers/Calendar/usePopperTriggerLogic.js +5 -1
  87. package/dist/cjs/parts/Pickers/Calendar/usePopperTriggerLogic.js.map +2 -2
  88. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheel.js +10 -6
  89. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheel.js.map +2 -2
  90. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js +9 -5
  91. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js.map +2 -2
  92. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContext.js +4 -0
  93. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContext.js.map +2 -2
  94. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js +7 -3
  95. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js.map +2 -2
  96. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js +8 -4
  97. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js.map +2 -2
  98. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js +8 -4
  99. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js.map +2 -2
  100. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/Styleds.js +6 -2
  101. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/Styleds.js.map +2 -2
  102. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js +8 -4
  103. package/dist/cjs/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js.map +2 -2
  104. package/dist/cjs/parts/Pickers/PickersIcons.js +9 -5
  105. package/dist/cjs/parts/Pickers/PickersIcons.js.map +2 -2
  106. package/dist/cjs/parts/Pickers/TimeWheel/HoursList.js +9 -5
  107. package/dist/cjs/parts/Pickers/TimeWheel/HoursList.js.map +2 -2
  108. package/dist/cjs/parts/Pickers/TimeWheel/MeridiemList.js +8 -4
  109. package/dist/cjs/parts/Pickers/TimeWheel/MeridiemList.js.map +2 -2
  110. package/dist/cjs/parts/Pickers/TimeWheel/MinutesList.js +9 -5
  111. package/dist/cjs/parts/Pickers/TimeWheel/MinutesList.js.map +2 -2
  112. package/dist/cjs/parts/Pickers/TimeWheel/Styleds.js +5 -1
  113. package/dist/cjs/parts/Pickers/TimeWheel/Styleds.js.map +2 -2
  114. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheel.js +9 -5
  115. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheel.js.map +2 -2
  116. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContent.js +11 -7
  117. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContent.js.map +2 -2
  118. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContext.js +4 -0
  119. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelContext.js.map +2 -2
  120. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelFooter.js +7 -3
  121. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelFooter.js.map +2 -2
  122. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js +8 -4
  123. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js.map +2 -2
  124. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelWrapper.js +8 -4
  125. package/dist/cjs/parts/Pickers/TimeWheel/TimeWheelWrapper.js.map +2 -2
  126. package/dist/cjs/parts/Pickers/TimeWheel/useConfigTimePickerCTX.js +7 -3
  127. package/dist/cjs/parts/Pickers/TimeWheel/useConfigTimePickerCTX.js.map +2 -2
  128. package/dist/cjs/parts/Pickers/TimeWheel/useCurrentDisplayedWheelsLogic.js +8 -4
  129. package/dist/cjs/parts/Pickers/TimeWheel/useCurrentDisplayedWheelsLogic.js.map +2 -2
  130. package/dist/cjs/parts/Pickers/TimeWheel/useKeyboardHandlers.js +5 -1
  131. package/dist/cjs/parts/Pickers/TimeWheel/useKeyboardHandlers.js.map +2 -2
  132. package/dist/cjs/parts/Pickers/TimeWheel/usePopperTriggerLogic.js +5 -1
  133. package/dist/cjs/parts/Pickers/TimeWheel/usePopperTriggerLogic.js.map +2 -2
  134. package/dist/cjs/parts/Styleds.js +5 -1
  135. package/dist/cjs/parts/Styleds.js.map +2 -2
  136. package/dist/cjs/parts/TimeInputs/HHInput.js +6 -2
  137. package/dist/cjs/parts/TimeInputs/HHInput.js.map +2 -2
  138. package/dist/cjs/parts/TimeInputs/MeridiemInput.js +6 -2
  139. package/dist/cjs/parts/TimeInputs/MeridiemInput.js.map +2 -2
  140. package/dist/cjs/parts/TimeInputs/MinutesInput.js +6 -2
  141. package/dist/cjs/parts/TimeInputs/MinutesInput.js.map +2 -2
  142. package/dist/cjs/parts/TimeInputs/TimeInputs.js +12 -8
  143. package/dist/cjs/parts/TimeInputs/TimeInputs.js.map +2 -2
  144. package/dist/cjs/parts/TimeInputs/useTimeInputs.js +6 -2
  145. package/dist/cjs/parts/TimeInputs/useTimeInputs.js.map +2 -2
  146. package/dist/cjs/parts/config.js +4 -0
  147. package/dist/cjs/parts/config.js.map +1 -1
  148. package/dist/cjs/propTypes.js +5 -1
  149. package/dist/cjs/propTypes.js.map +2 -2
  150. package/dist/cjs/sharedTypes.js +4 -0
  151. package/dist/cjs/sharedTypes.js.map +2 -2
  152. package/dist/cjs/tests/custom-props/customProps.js +4 -0
  153. package/dist/cjs/tests/custom-props/customProps.js.map +1 -1
  154. package/dist/cjs/utils/constants.js +4 -0
  155. package/dist/cjs/utils/constants.js.map +1 -1
  156. package/dist/cjs/utils/dateHelpers.js +7 -3
  157. package/dist/cjs/utils/dateHelpers.js.map +2 -2
  158. package/dist/cjs/utils/dateTimeHelpers.js +6 -2
  159. package/dist/cjs/utils/dateTimeHelpers.js.map +2 -2
  160. package/dist/cjs/utils/hooks/useGetDayFromDateString.js +6 -2
  161. package/dist/cjs/utils/hooks/useGetDayFromDateString.js.map +2 -2
  162. package/dist/cjs/utils/hooks/useGetMonthYearFromDateStringOrEmptyStartingMonth.js +6 -2
  163. package/dist/cjs/utils/hooks/useGetMonthYearFromDateStringOrEmptyStartingMonth.js.map +2 -2
  164. package/dist/cjs/utils/hooks/useGetStartingFocusedDay.js +9 -5
  165. package/dist/cjs/utils/hooks/useGetStartingFocusedDay.js.map +2 -2
  166. package/dist/cjs/utils/hooks/useOnClickOutside.js +4 -0
  167. package/dist/cjs/utils/hooks/useOnClickOutside.js.map +1 -1
  168. package/dist/cjs/utils/numberHelpers.js +4 -0
  169. package/dist/cjs/utils/numberHelpers.js.map +1 -1
  170. package/dist/cjs/utils/stringHelpers.js +9 -2
  171. package/dist/cjs/utils/stringHelpers.js.map +2 -2
  172. package/dist/cjs/utils/timeHelpers.js +5 -1
  173. package/dist/cjs/utils/timeHelpers.js.map +2 -2
  174. package/dist/cjs/utils/typeGuards.js +4 -0
  175. package/dist/cjs/utils/typeGuards.js.map +2 -2
  176. package/dist/esm/ControlledDateTimePicker.js +5 -5
  177. package/dist/esm/ControlledDateTimePicker.js.map +1 -1
  178. package/dist/esm/ControlledDateTimePickerCTX.js.map +1 -1
  179. package/dist/esm/config/useChangeHandlers.js +5 -4
  180. package/dist/esm/config/useChangeHandlers.js.map +2 -2
  181. package/dist/esm/config/useControlledDateTimePicker.js +11 -10
  182. package/dist/esm/config/useControlledDateTimePicker.js.map +2 -2
  183. package/dist/esm/config/useFocusTracker.js.map +1 -1
  184. package/dist/esm/config/useGetDestructuredValues.js +7 -4
  185. package/dist/esm/config/useGetDestructuredValues.js.map +2 -2
  186. package/dist/esm/config/useGetFlags.js +2 -2
  187. package/dist/esm/config/useGetFlags.js.map +1 -1
  188. package/dist/esm/config/useGetPropsBasedOnType.js +2 -2
  189. package/dist/esm/config/useGetPropsBasedOnType.js.map +2 -2
  190. package/dist/esm/config/useGetPropsWithDefault.js +1 -1
  191. package/dist/esm/config/useGetPropsWithDefault.js.map +1 -1
  192. package/dist/esm/config/useGetReferences.js.map +1 -1
  193. package/dist/esm/config/useGlobalKeyHandlers.js +4 -4
  194. package/dist/esm/config/useGlobalKeyHandlers.js.map +2 -2
  195. package/dist/esm/config/useRelevantValueFromProps.js +2 -2
  196. package/dist/esm/config/useRelevantValueFromProps.js.map +1 -1
  197. package/dist/esm/config/useValidateProps.js +3 -3
  198. package/dist/esm/config/useValidateProps.js.map +1 -1
  199. package/dist/esm/index.js +9 -9
  200. package/dist/esm/index.js.map +1 -1
  201. package/dist/esm/package.json +7 -0
  202. package/dist/esm/parts/ClearButton/ClearButton.js +4 -4
  203. package/dist/esm/parts/ClearButton/ClearButton.js.map +2 -2
  204. package/dist/esm/parts/ClearButton/useClearButton.js +1 -1
  205. package/dist/esm/parts/ClearButton/useClearButton.js.map +1 -1
  206. package/dist/esm/parts/ControlledDateTimePickerContent.js +7 -7
  207. package/dist/esm/parts/ControlledDateTimePickerContent.js.map +2 -2
  208. package/dist/esm/parts/DateInputs/DDInput.js +2 -2
  209. package/dist/esm/parts/DateInputs/DDInput.js.map +1 -1
  210. package/dist/esm/parts/DateInputs/DateInputs.js +8 -8
  211. package/dist/esm/parts/DateInputs/DateInputs.js.map +2 -2
  212. package/dist/esm/parts/DateInputs/MMInput.js +2 -2
  213. package/dist/esm/parts/DateInputs/MMInput.js.map +1 -1
  214. package/dist/esm/parts/DateInputs/YYYYInput.js +2 -2
  215. package/dist/esm/parts/DateInputs/YYYYInput.js.map +1 -1
  216. package/dist/esm/parts/DateInputs/useDateInputs.js +4 -4
  217. package/dist/esm/parts/DateInputs/useDateInputs.js.map +1 -1
  218. package/dist/esm/parts/Pickers/Calendar/Calendar.js +5 -5
  219. package/dist/esm/parts/Pickers/Calendar/Calendar.js.map +1 -1
  220. package/dist/esm/parts/Pickers/Calendar/CalendarBody.js +3 -3
  221. package/dist/esm/parts/Pickers/Calendar/CalendarBody.js.map +1 -1
  222. package/dist/esm/parts/Pickers/Calendar/CalendarContent.js +7 -7
  223. package/dist/esm/parts/Pickers/Calendar/CalendarContent.js.map +2 -2
  224. package/dist/esm/parts/Pickers/Calendar/CalendarContext.js.map +1 -1
  225. package/dist/esm/parts/Pickers/Calendar/CalendarDaysList.js +2 -2
  226. package/dist/esm/parts/Pickers/Calendar/CalendarDaysList.js.map +2 -2
  227. package/dist/esm/parts/Pickers/Calendar/CalendarFooter.js +3 -3
  228. package/dist/esm/parts/Pickers/Calendar/CalendarFooter.js.map +2 -2
  229. package/dist/esm/parts/Pickers/Calendar/CalendarHead.js +5 -5
  230. package/dist/esm/parts/Pickers/Calendar/CalendarHead.js.map +2 -2
  231. package/dist/esm/parts/Pickers/Calendar/CalendarIconTrigger.js +4 -4
  232. package/dist/esm/parts/Pickers/Calendar/CalendarIconTrigger.js.map +2 -2
  233. package/dist/esm/parts/Pickers/Calendar/CalendarMonthDays.js +3 -3
  234. package/dist/esm/parts/Pickers/Calendar/CalendarMonthDays.js.map +1 -1
  235. package/dist/esm/parts/Pickers/Calendar/CalendarWeekDays.js +1 -1
  236. package/dist/esm/parts/Pickers/Calendar/CalendarWeekDays.js.map +1 -1
  237. package/dist/esm/parts/Pickers/Calendar/CalendarWrapper.js +4 -4
  238. package/dist/esm/parts/Pickers/Calendar/CalendarWrapper.js.map +2 -2
  239. package/dist/esm/parts/Pickers/Calendar/Day.js +7 -7
  240. package/dist/esm/parts/Pickers/Calendar/Day.js.map +2 -2
  241. package/dist/esm/parts/Pickers/Calendar/Styleds.js +1 -1
  242. package/dist/esm/parts/Pickers/Calendar/Styleds.js.map +2 -2
  243. package/dist/esm/parts/Pickers/Calendar/useConfigCalendarCTX.js +5 -5
  244. package/dist/esm/parts/Pickers/Calendar/useConfigCalendarCTX.js.map +1 -1
  245. package/dist/esm/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.js +2 -2
  246. package/dist/esm/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.js.map +2 -2
  247. package/dist/esm/parts/Pickers/Calendar/useFocusLogic.js +2 -2
  248. package/dist/esm/parts/Pickers/Calendar/useFocusLogic.js.map +1 -1
  249. package/dist/esm/parts/Pickers/Calendar/useKeyboardHandlers.js +3 -2
  250. package/dist/esm/parts/Pickers/Calendar/useKeyboardHandlers.js.map +2 -2
  251. package/dist/esm/parts/Pickers/Calendar/usePopperTriggerLogic.js +1 -1
  252. package/dist/esm/parts/Pickers/Calendar/usePopperTriggerLogic.js.map +1 -1
  253. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheel.js +6 -6
  254. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheel.js.map +1 -1
  255. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js +5 -5
  256. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.js.map +2 -2
  257. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContext.js.map +1 -1
  258. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js +3 -3
  259. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.js.map +2 -2
  260. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js +4 -4
  261. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.js.map +2 -2
  262. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js +4 -4
  263. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.js.map +2 -2
  264. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/Styleds.js +2 -2
  265. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/Styleds.js.map +2 -2
  266. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js +4 -4
  267. package/dist/esm/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.js.map +1 -1
  268. package/dist/esm/parts/Pickers/PickersIcons.js +5 -5
  269. package/dist/esm/parts/Pickers/PickersIcons.js.map +1 -1
  270. package/dist/esm/parts/Pickers/TimeWheel/HoursList.js +5 -5
  271. package/dist/esm/parts/Pickers/TimeWheel/HoursList.js.map +2 -2
  272. package/dist/esm/parts/Pickers/TimeWheel/MeridiemList.js +4 -4
  273. package/dist/esm/parts/Pickers/TimeWheel/MeridiemList.js.map +2 -2
  274. package/dist/esm/parts/Pickers/TimeWheel/MinutesList.js +5 -5
  275. package/dist/esm/parts/Pickers/TimeWheel/MinutesList.js.map +2 -2
  276. package/dist/esm/parts/Pickers/TimeWheel/Styleds.js +1 -1
  277. package/dist/esm/parts/Pickers/TimeWheel/Styleds.js.map +2 -2
  278. package/dist/esm/parts/Pickers/TimeWheel/TimeWheel.js +5 -5
  279. package/dist/esm/parts/Pickers/TimeWheel/TimeWheel.js.map +1 -1
  280. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelContent.js +7 -7
  281. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelContent.js.map +2 -2
  282. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelContext.js.map +1 -1
  283. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelFooter.js +3 -3
  284. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelFooter.js.map +2 -2
  285. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js +4 -4
  286. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelIconTrigger.js.map +2 -2
  287. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelWrapper.js +4 -4
  288. package/dist/esm/parts/Pickers/TimeWheel/TimeWheelWrapper.js.map +2 -2
  289. package/dist/esm/parts/Pickers/TimeWheel/useConfigTimePickerCTX.js +3 -3
  290. package/dist/esm/parts/Pickers/TimeWheel/useConfigTimePickerCTX.js.map +1 -1
  291. package/dist/esm/parts/Pickers/TimeWheel/useCurrentDisplayedWheelsLogic.js +4 -4
  292. package/dist/esm/parts/Pickers/TimeWheel/useCurrentDisplayedWheelsLogic.js.map +2 -2
  293. package/dist/esm/parts/Pickers/TimeWheel/useKeyboardHandlers.js +1 -1
  294. package/dist/esm/parts/Pickers/TimeWheel/useKeyboardHandlers.js.map +1 -1
  295. package/dist/esm/parts/Pickers/TimeWheel/usePopperTriggerLogic.js +1 -1
  296. package/dist/esm/parts/Pickers/TimeWheel/usePopperTriggerLogic.js.map +1 -1
  297. package/dist/esm/parts/Styleds.js +1 -1
  298. package/dist/esm/parts/Styleds.js.map +2 -2
  299. package/dist/esm/parts/TimeInputs/HHInput.js +2 -2
  300. package/dist/esm/parts/TimeInputs/HHInput.js.map +1 -1
  301. package/dist/esm/parts/TimeInputs/MeridiemInput.js +2 -2
  302. package/dist/esm/parts/TimeInputs/MeridiemInput.js.map +1 -1
  303. package/dist/esm/parts/TimeInputs/MinutesInput.js +2 -2
  304. package/dist/esm/parts/TimeInputs/MinutesInput.js.map +1 -1
  305. package/dist/esm/parts/TimeInputs/TimeInputs.js +8 -8
  306. package/dist/esm/parts/TimeInputs/TimeInputs.js.map +2 -2
  307. package/dist/esm/parts/TimeInputs/useTimeInputs.js +2 -2
  308. package/dist/esm/parts/TimeInputs/useTimeInputs.js.map +1 -1
  309. package/dist/esm/propTypes.js +1 -1
  310. package/dist/esm/propTypes.js.map +1 -1
  311. package/dist/esm/tests/custom-props/customProps.js.map +1 -1
  312. package/dist/esm/utils/dateHelpers.js +3 -3
  313. package/dist/esm/utils/dateHelpers.js.map +2 -2
  314. package/dist/esm/utils/dateTimeHelpers.js +2 -2
  315. package/dist/esm/utils/dateTimeHelpers.js.map +1 -1
  316. package/dist/esm/utils/hooks/useGetDayFromDateString.js +2 -2
  317. package/dist/esm/utils/hooks/useGetDayFromDateString.js.map +1 -1
  318. package/dist/esm/utils/hooks/useGetMonthYearFromDateStringOrEmptyStartingMonth.js +2 -2
  319. package/dist/esm/utils/hooks/useGetMonthYearFromDateStringOrEmptyStartingMonth.js.map +1 -1
  320. package/dist/esm/utils/hooks/useGetStartingFocusedDay.js +5 -5
  321. package/dist/esm/utils/hooks/useGetStartingFocusedDay.js.map +1 -1
  322. package/dist/esm/utils/stringHelpers.js +5 -2
  323. package/dist/esm/utils/stringHelpers.js.map +2 -2
  324. package/dist/esm/utils/timeHelpers.js +1 -1
  325. package/dist/esm/utils/timeHelpers.js.map +1 -1
  326. package/dist/esm/utils/typeGuards.js.map +1 -1
  327. package/package.json +13 -13
  328. package/dist/types/ControlledDateTimePicker.d.ts +0 -7
  329. package/dist/types/ControlledDateTimePickerCTX.d.ts +0 -5
  330. package/dist/types/ControlledDateTimePickerDatatestid.d.ts +0 -63
  331. package/dist/types/ControlledDateTimePickerTypes.d.ts +0 -20
  332. package/dist/types/config/useChangeHandlers.d.ts +0 -27
  333. package/dist/types/config/useControlledDateTimePicker.d.ts +0 -16
  334. package/dist/types/config/useFocusTracker.d.ts +0 -38
  335. package/dist/types/config/useGetDestructuredValues.d.ts +0 -30
  336. package/dist/types/config/useGetFlags.d.ts +0 -30
  337. package/dist/types/config/useGetPropsBasedOnType.d.ts +0 -28
  338. package/dist/types/config/useGetPropsWithDefault.d.ts +0 -2
  339. package/dist/types/config/useGetReferences.d.ts +0 -33
  340. package/dist/types/config/useGlobalKeyHandlers.d.ts +0 -18
  341. package/dist/types/config/useRelevantValueFromProps.d.ts +0 -10
  342. package/dist/types/config/useValidateProps.d.ts +0 -2
  343. package/dist/types/exported-related/theming.d.ts +0 -37
  344. package/dist/types/index.d.ts +0 -9
  345. package/dist/types/parts/ClearButton/ClearButton.d.ts +0 -1
  346. package/dist/types/parts/ClearButton/useClearButton.d.ts +0 -11
  347. package/dist/types/parts/ControlledDateTimePickerContent.d.ts +0 -1
  348. package/dist/types/parts/DateInputs/DDInput.d.ts +0 -17
  349. package/dist/types/parts/DateInputs/DateInputs.d.ts +0 -1
  350. package/dist/types/parts/DateInputs/MMInput.d.ts +0 -19
  351. package/dist/types/parts/DateInputs/YYYYInput.d.ts +0 -17
  352. package/dist/types/parts/DateInputs/useDateInputs.d.ts +0 -2
  353. package/dist/types/parts/Pickers/Calendar/Calendar.d.ts +0 -4
  354. package/dist/types/parts/Pickers/Calendar/CalendarBody.d.ts +0 -6
  355. package/dist/types/parts/Pickers/Calendar/CalendarContent.d.ts +0 -3
  356. package/dist/types/parts/Pickers/Calendar/CalendarContext.d.ts +0 -6
  357. package/dist/types/parts/Pickers/Calendar/CalendarDaysList.d.ts +0 -9
  358. package/dist/types/parts/Pickers/Calendar/CalendarFooter.d.ts +0 -2
  359. package/dist/types/parts/Pickers/Calendar/CalendarHead.d.ts +0 -1
  360. package/dist/types/parts/Pickers/Calendar/CalendarIconTrigger.d.ts +0 -1
  361. package/dist/types/parts/Pickers/Calendar/CalendarMonthDays.d.ts +0 -1
  362. package/dist/types/parts/Pickers/Calendar/CalendarWeekDays.d.ts +0 -2
  363. package/dist/types/parts/Pickers/Calendar/CalendarWrapper.d.ts +0 -1
  364. package/dist/types/parts/Pickers/Calendar/Day.d.ts +0 -8
  365. package/dist/types/parts/Pickers/Calendar/Styleds.d.ts +0 -21
  366. package/dist/types/parts/Pickers/Calendar/useConfigCalendarCTX.d.ts +0 -14
  367. package/dist/types/parts/Pickers/Calendar/useCurrentDisplayedMonthYearLogic.d.ts +0 -15
  368. package/dist/types/parts/Pickers/Calendar/useFocusLogic.d.ts +0 -14
  369. package/dist/types/parts/Pickers/Calendar/useKeyboardHandlers.d.ts +0 -19
  370. package/dist/types/parts/Pickers/Calendar/usePopperTriggerLogic.d.ts +0 -16
  371. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheel.d.ts +0 -1
  372. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContent.d.ts +0 -1
  373. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelContext.d.ts +0 -6
  374. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelFooter.d.ts +0 -2
  375. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelIconTrigger.d.ts +0 -1
  376. package/dist/types/parts/Pickers/CalendarWithTimeWheel/CalendarWithTimeWheelWrapper.d.ts +0 -1
  377. package/dist/types/parts/Pickers/CalendarWithTimeWheel/Styleds.d.ts +0 -7
  378. package/dist/types/parts/Pickers/CalendarWithTimeWheel/useConfigCalendarWithTimeWheelCTX.d.ts +0 -14
  379. package/dist/types/parts/Pickers/PickersIcons.d.ts +0 -1
  380. package/dist/types/parts/Pickers/TimeWheel/HoursList.d.ts +0 -1
  381. package/dist/types/parts/Pickers/TimeWheel/MeridiemList.d.ts +0 -2
  382. package/dist/types/parts/Pickers/TimeWheel/MinutesList.d.ts +0 -2
  383. package/dist/types/parts/Pickers/TimeWheel/TimeWheel.d.ts +0 -4
  384. package/dist/types/parts/Pickers/TimeWheel/TimeWheelContent.d.ts +0 -2
  385. package/dist/types/parts/Pickers/TimeWheel/TimeWheelContext.d.ts +0 -6
  386. package/dist/types/parts/Pickers/TimeWheel/TimeWheelFooter.d.ts +0 -2
  387. package/dist/types/parts/Pickers/TimeWheel/TimeWheelIconTrigger.d.ts +0 -1
  388. package/dist/types/parts/Pickers/TimeWheel/TimeWheelWrapper.d.ts +0 -1
  389. package/dist/types/parts/Pickers/TimeWheel/useConfigTimePickerCTX.d.ts +0 -5
  390. package/dist/types/parts/Pickers/TimeWheel/useCurrentDisplayedWheelsLogic.d.ts +0 -17
  391. package/dist/types/parts/Pickers/TimeWheel/useKeyboardHandlers.d.ts +0 -13
  392. package/dist/types/parts/Pickers/TimeWheel/usePopperTriggerLogic.d.ts +0 -12
  393. package/dist/types/parts/Styleds.d.ts +0 -13
  394. package/dist/types/parts/TimeInputs/HHInput.d.ts +0 -18
  395. package/dist/types/parts/TimeInputs/MeridiemInput.d.ts +0 -17
  396. package/dist/types/parts/TimeInputs/MinutesInput.d.ts +0 -17
  397. package/dist/types/parts/TimeInputs/TimeInputs.d.ts +0 -1
  398. package/dist/types/parts/TimeInputs/useTimeInputs.d.ts +0 -22
  399. package/dist/types/parts/config.d.ts +0 -5
  400. package/dist/types/propTypes.d.ts +0 -105
  401. package/dist/types/sharedTypes.d.ts +0 -95
  402. package/dist/types/tests/custom-props/customProps.d.ts +0 -397
  403. package/dist/types/tests/custom-props/date-time-picker.date-custom-props.test.d.ts +0 -1
  404. package/dist/types/tests/custom-props/date-time-picker.date-time-custom-props.test.d.ts +0 -1
  405. package/dist/types/tests/custom-props/date-time-picker.time-custom-props.test.d.ts +0 -1
  406. package/dist/types/tests/date-time-picker.auto-advance.test.d.ts +0 -1
  407. package/dist/types/tests/date-time-picker.clear-button.test.d.ts +0 -1
  408. package/dist/types/tests/date-time-picker.keyboard-focus.test.d.ts +0 -1
  409. package/dist/types/tests/date-time-picker.keyboard.data-entry-typing.test.d.ts +0 -1
  410. package/dist/types/tests/date-time-picker.keyboard.fill-with-now.test.d.ts +0 -1
  411. package/dist/types/tests/date-time-picker.keyboard.regressive-backspace.test.d.ts +0 -1
  412. package/dist/types/tests/date-time-picker.keyboard.shortcut-clear.test.d.ts +0 -1
  413. package/dist/types/tests/date-time-picker.manual-delete-values.test.d.ts +0 -1
  414. package/dist/types/tests/date-time-picker.onChange-meta-info.test.d.ts +0 -1
  415. package/dist/types/tests/date-time-picker.types-button.test.d.ts +0 -1
  416. package/dist/types/tests/date-time-picker.types-dom.test.d.ts +0 -1
  417. package/dist/types/utils/constants.d.ts +0 -38
  418. package/dist/types/utils/dateHelpers.d.ts +0 -40
  419. package/dist/types/utils/dateTimeHelpers.d.ts +0 -8
  420. package/dist/types/utils/hooks/useGetDayFromDateString.d.ts +0 -1
  421. package/dist/types/utils/hooks/useGetMonthYearFromDateStringOrEmptyStartingMonth.d.ts +0 -5
  422. package/dist/types/utils/hooks/useGetStartingFocusedDay.d.ts +0 -8
  423. package/dist/types/utils/hooks/useOnClickOutside.d.ts +0 -1
  424. package/dist/types/utils/numberHelpers.d.ts +0 -1
  425. package/dist/types/utils/stringHelpers.d.ts +0 -36
  426. package/dist/types/utils/timeHelpers.d.ts +0 -2
  427. package/dist/types/utils/typeGuards.d.ts +0 -4
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/parts/ControlledDateTimePickerContent.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable complexity */\nimport React, { useContext } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerContext } from '../ControlledDateTimePickerCTX';\nimport { StyledInputsWrapperGrid } from './Styleds';\nimport { DateInputs } from './DateInputs/DateInputs';\nimport { TimeInputs } from './TimeInputs/TimeInputs';\nimport { PickersIcons } from './Pickers/PickersIcons';\nimport { ClearButton } from './ClearButton/ClearButton';\nimport { ControlledDateTimePickerDatatestid } from '../ControlledDateTimePickerDatatestid';\n\nexport const ControlledDateTimePickerContent = (): JSX.Element => {\n const {\n props,\n props: { hasError, disabled },\n hideDate,\n hideTime,\n withAnyPicker,\n withAnyRightController,\n shouldPreserveClearableSpace,\n isControllerOnly,\n globalAttrs,\n xstyledAttrs,\n onGlobalKeyDown,\n trackFocusResetter,\n } = useContext(ControlledDateTimePickerContext);\n const ariaAndDataProps = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.CONTAINER]),\n [props],\n );\n\n const styledsAttrs = {\n justPicker: hideDate && hideTime,\n withAnyPicker,\n hasError,\n isControllerOnly,\n };\n\n const mainCols = [];\n if (!hideDate) mainCols.push('auto');\n if (!hideTime) mainCols.push('auto');\n if (withAnyRightController) mainCols.push('auto');\n\n const rightControlCols = [];\n if (shouldPreserveClearableSpace) rightControlCols.push('28px');\n if (withAnyPicker) rightControlCols.push('auto');\n\n return (\n <>\n {/* The <div> element is catching the component-wise global hotkeys, there is no valid aria role for this */}\n {/* eslint-disable-next-line max-len */}\n {/* https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/no-static-element-interactions.md#case-the-event-handler-is-only-being-used-to-capture-bubbled-events */}\n {/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}\n <StyledInputsWrapperGrid\n cols={mainCols}\n gutter=\"xxs\"\n pr={!withAnyRightController ? '2px' : '0px'}\n onKeyDown={onGlobalKeyDown}\n disabled={disabled}\n onBlur={trackFocusResetter}\n data-testid={ControlledDateTimePickerDatatestid.CONTAINER}\n {...styledsAttrs}\n {...ariaAndDataProps}\n {...globalAttrs}\n {...xstyledAttrs}\n >\n {hideDate ? null : <DateInputs />}\n {hideTime ? null : <TimeInputs />}\n {withAnyRightController ? (\n <Grid cols={rightControlCols}>\n {shouldPreserveClearableSpace ? <ClearButton /> : null}\n {withAnyPicker ? <PickersIcons /> : null}\n </Grid>\n ) : null}\n </StyledInputsWrapperGrid>\n </>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADiDnB;AAhDJ,mBAAkC;AAClC,qBAAqB;AACrB,8BAAsC;AACtC,yCAAgD;AAChD,qBAAwC;AACxC,wBAA2B;AAC3B,wBAA2B;AAC3B,0BAA6B;AAC7B,yBAA4B;AAC5B,gDAAmD;AAE5C,MAAM,kCAAkC,MAAmB;AAChE,QAAM;AAAA,IACJ;AAAA,IACA,OAAO,EAAE,UAAU,SAAS;AAAA,IAC5B;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,yBAAW,kEAA+B;AAC9C,QAAM,mBAAmB,aAAAA,QAAM;AAAA,IAC7B,UAAM,+CAAsB,MAAM,6EAAmC,UAAU;AAAA,IAC/E,CAAC,KAAK;AAAA,EACR;AAEA,QAAM,eAAe;AAAA,IACnB,YAAY,YAAY;AAAA,IACxB;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,WAAW,CAAC;AAClB,MAAI,CAAC;AAAU,aAAS,KAAK,MAAM;AACnC,MAAI,CAAC;AAAU,aAAS,KAAK,MAAM;AACnC,MAAI;AAAwB,aAAS,KAAK,MAAM;AAEhD,QAAM,mBAAmB,CAAC;AAC1B,MAAI;AAA8B,qBAAiB,KAAK,MAAM;AAC9D,MAAI;AAAe,qBAAiB,KAAK,MAAM;AAE/C,SACE,2EAKE;AAAA,IAAC;AAAA;AAAA,MACC,MAAM;AAAA,MACN,QAAO;AAAA,MACP,IAAI,CAAC,yBAAyB,QAAQ;AAAA,MACtC,WAAW;AAAA,MACX;AAAA,MACA,QAAQ;AAAA,MACR,eAAa,6EAAmC;AAAA,MAC/C,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MAEH;AAAA,mBAAW,OAAO,4CAAC,gCAAW;AAAA,QAC9B,WAAW,OAAO,4CAAC,gCAAW;AAAA,QAC9B,yBACC,6CAAC,uBAAK,MAAM,kBACT;AAAA,yCAA+B,4CAAC,kCAAY,IAAK;AAAA,UACjD,gBAAgB,4CAAC,oCAAa,IAAK;AAAA,WACtC,IACE;AAAA;AAAA;AAAA,EACN,GACF;AAEJ;",
4
+ "sourcesContent": ["/* eslint-disable complexity */\nimport React, { useContext } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerContext } from '../ControlledDateTimePickerCTX.js';\nimport { StyledInputsWrapperGrid } from './Styleds.js';\nimport { DateInputs } from './DateInputs/DateInputs.js';\nimport { TimeInputs } from './TimeInputs/TimeInputs.js';\nimport { PickersIcons } from './Pickers/PickersIcons.js';\nimport { ClearButton } from './ClearButton/ClearButton.js';\nimport { ControlledDateTimePickerDatatestid } from '../ControlledDateTimePickerDatatestid.js';\n\nexport const ControlledDateTimePickerContent = (): JSX.Element => {\n const {\n props,\n props: { hasError, disabled },\n hideDate,\n hideTime,\n withAnyPicker,\n withAnyRightController,\n shouldPreserveClearableSpace,\n isControllerOnly,\n globalAttrs,\n xstyledAttrs,\n onGlobalKeyDown,\n trackFocusResetter,\n } = useContext(ControlledDateTimePickerContext);\n const ariaAndDataProps = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.CONTAINER]),\n [props],\n );\n\n const styledsAttrs = {\n justPicker: hideDate && hideTime,\n withAnyPicker,\n hasError,\n isControllerOnly,\n };\n\n const mainCols = [];\n if (!hideDate) mainCols.push('auto');\n if (!hideTime) mainCols.push('auto');\n if (withAnyRightController) mainCols.push('auto');\n\n const rightControlCols = [];\n if (shouldPreserveClearableSpace) rightControlCols.push('28px');\n if (withAnyPicker) rightControlCols.push('auto');\n\n return (\n <>\n {/* The <div> element is catching the component-wise global hotkeys, there is no valid aria role for this */}\n {/* eslint-disable-next-line max-len */}\n {/* https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/no-static-element-interactions.md#case-the-event-handler-is-only-being-used-to-capture-bubbled-events */}\n {/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}\n <StyledInputsWrapperGrid\n cols={mainCols}\n gutter=\"xxs\"\n pr={!withAnyRightController ? '2px' : '0px'}\n onKeyDown={onGlobalKeyDown}\n disabled={disabled}\n onBlur={trackFocusResetter}\n data-testid={ControlledDateTimePickerDatatestid.CONTAINER}\n {...styledsAttrs}\n {...ariaAndDataProps}\n {...globalAttrs}\n {...xstyledAttrs}\n >\n {hideDate ? null : <DateInputs />}\n {hideTime ? null : <TimeInputs />}\n {withAnyRightController ? (\n <Grid cols={rightControlCols}>\n {shouldPreserveClearableSpace ? <ClearButton /> : null}\n {withAnyPicker ? <PickersIcons /> : null}\n </Grid>\n ) : null}\n </StyledInputsWrapperGrid>\n </>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADiDnB;AAhDJ,mBAAkC;AAClC,qBAAqB;AACrB,8BAAsC;AACtC,yCAAgD;AAChD,qBAAwC;AACxC,wBAA2B;AAC3B,wBAA2B;AAC3B,0BAA6B;AAC7B,yBAA4B;AAC5B,gDAAmD;AAE5C,MAAM,kCAAkC,MAAmB;AAChE,QAAM;AAAA,IACJ;AAAA,IACA,OAAO,EAAE,UAAU,SAAS;AAAA,IAC5B;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,yBAAW,kEAA+B;AAC9C,QAAM,mBAAmB,aAAAA,QAAM;AAAA,IAC7B,UAAM,+CAAsB,MAAM,6EAAmC,SAAS,CAAC;AAAA,IAC/E,CAAC,KAAK;AAAA,EACR;AAEA,QAAM,eAAe;AAAA,IACnB,YAAY,YAAY;AAAA,IACxB;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,WAAW,CAAC;AAClB,MAAI,CAAC;AAAU,aAAS,KAAK,MAAM;AACnC,MAAI,CAAC;AAAU,aAAS,KAAK,MAAM;AACnC,MAAI;AAAwB,aAAS,KAAK,MAAM;AAEhD,QAAM,mBAAmB,CAAC;AAC1B,MAAI;AAA8B,qBAAiB,KAAK,MAAM;AAC9D,MAAI;AAAe,qBAAiB,KAAK,MAAM;AAE/C,SACE,2EAKE;AAAA,IAAC;AAAA;AAAA,MACC,MAAM;AAAA,MACN,QAAO;AAAA,MACP,IAAI,CAAC,yBAAyB,QAAQ;AAAA,MACtC,WAAW;AAAA,MACX;AAAA,MACA,QAAQ;AAAA,MACR,eAAa,6EAAmC;AAAA,MAC/C,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MAEH;AAAA,mBAAW,OAAO,4CAAC,gCAAW;AAAA,QAC9B,WAAW,OAAO,4CAAC,gCAAW;AAAA,QAC9B,yBACC,6CAAC,uBAAK,MAAM,kBACT;AAAA,yCAA+B,4CAAC,kCAAY,IAAK;AAAA,UACjD,gBAAgB,4CAAC,oCAAa,IAAK;AAAA,WACtC,IACE;AAAA;AAAA;AAAA,EACN,GACF;AAEJ;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -30,8 +34,8 @@ module.exports = __toCommonJS(DDInput_exports);
30
34
  var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
- var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid");
34
- var import_Styleds = require("../Styleds");
37
+ var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid.js");
38
+ var import_Styleds = require("../Styleds.js");
35
39
  const regExpNumbers = /^[0-9]+$/;
36
40
  const isInvalidDay = (day) => {
37
41
  if (day === "")
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/DateInputs/DDInput.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React, { useCallback } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid';\nimport { Styled2DigitsInput } from '../Styleds';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidDay = (day: string) => {\n if (day === '') return false;\n const numberOnly = regExpNumbers.test(day);\n return day.length > 2 || day === '00' || !numberOnly || Number.parseInt(day, 10) > 31;\n};\n\ninterface DDInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n isFocused: boolean;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const DDInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n contextRef,\n placeholder,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: DDInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidDay(e?.currentTarget?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n return (\n <Styled2DigitsInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={(DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n placeholder={placeholder}\n aria-label={`day input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.DAY}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkDjB;AAlDN,mBAAmC;AACnC,gDAAmD;AACnD,qBAAmC;AAGnC,MAAM,gBAAgB;AACtB,MAAM,eAAe,CAAC,QAAgB;AACpC,MAAI,QAAQ;AAAI,WAAO;AACvB,QAAM,aAAa,cAAc,KAAK,GAAG;AACzC,SAAO,IAAI,SAAS,KAAK,QAAQ,QAAQ,CAAC,cAAc,OAAO,SAAS,KAAK,EAAE,IAAI;AACrF;AAeO,MAAM,UAAU,aAAAA,QAAM;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,EACF,MAAmC;AACjC,UAAM,uBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,aAAa,GAAG,eAAe,KAAK,GAAG;AACzC,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK,CAAC,YAA8B;AAClC,UAAC,WAAwD,UAAU;AACnE,cAAI;AAAW,qBAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA,cAAY,oBAAoB;AAAA,QAChC,eAAa,6EAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACd,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;",
4
+ "sourcesContent": ["import React, { useCallback } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid.js';\nimport { Styled2DigitsInput } from '../Styleds.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidDay = (day: string) => {\n if (day === '') return false;\n const numberOnly = regExpNumbers.test(day);\n return day.length > 2 || day === '00' || !numberOnly || Number.parseInt(day, 10) > 31;\n};\n\ninterface DDInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n isFocused: boolean;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const DDInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n contextRef,\n placeholder,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: DDInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidDay(e?.currentTarget?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n return (\n <Styled2DigitsInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={(DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n placeholder={placeholder}\n aria-label={`day input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.DAY}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkDjB;AAlDN,mBAAmC;AACnC,gDAAmD;AACnD,qBAAmC;AAGnC,MAAM,gBAAgB;AACtB,MAAM,eAAe,CAAC,QAAgB;AACpC,MAAI,QAAQ;AAAI,WAAO;AACvB,QAAM,aAAa,cAAc,KAAK,GAAG;AACzC,SAAO,IAAI,SAAS,KAAK,QAAQ,QAAQ,CAAC,cAAc,OAAO,SAAS,KAAK,EAAE,IAAI;AACrF;AAeO,MAAM,UAAU,aAAAA,QAAM;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,EACF,MAAmC;AACjC,UAAM,uBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,aAAa,GAAG,eAAe,KAAK,GAAG;AACzC,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK,CAAC,YAA8B;AAClC,UAAC,WAAwD,UAAU;AACnE,cAAI;AAAW,qBAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA,cAAY,oBAAoB;AAAA,QAChC,eAAa,6EAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACd,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -32,14 +36,14 @@ var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
37
  var import_ds_grid = require("@elliemae/ds-grid");
34
38
  var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
35
- var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid");
36
- var import_ControlledDateTimePickerCTX = require("../../ControlledDateTimePickerCTX");
37
- var import_MMInput = require("./MMInput");
38
- var import_DDInput = require("./DDInput");
39
- var import_YYYYInput = require("./YYYYInput");
40
- var import_Styleds = require("../Styleds");
41
- var import_useDateInputs = require("./useDateInputs");
42
- var import_config = require("../config");
39
+ var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid.js");
40
+ var import_ControlledDateTimePickerCTX = require("../../ControlledDateTimePickerCTX.js");
41
+ var import_MMInput = require("./MMInput.js");
42
+ var import_DDInput = require("./DDInput.js");
43
+ var import_YYYYInput = require("./YYYYInput.js");
44
+ var import_Styleds = require("../Styleds.js");
45
+ var import_useDateInputs = require("./useDateInputs.js");
46
+ var import_config = require("../config.js");
43
47
  const DateInputs = () => {
44
48
  const {
45
49
  month,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/DateInputs/DateInputs.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React, { useContext } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid';\nimport { ControlledDateTimePickerContext } from '../../ControlledDateTimePickerCTX';\nimport { MMInput } from './MMInput';\nimport { DDInput } from './DDInput';\nimport { YYYYInput } from './YYYYInput';\nimport { StyledFocusWithIn, StyledSeparator } from '../Styleds';\nimport { useDateInputs } from './useDateInputs';\nimport { fixedValues } from '../config';\n\nexport const DateInputs = (): JSX.Element => {\n const {\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n onMonthChange,\n onDayChange,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthFocus,\n onDayFocus,\n onYearFocus,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n disabled,\n } = useDateInputs();\n // we do this here so MMInput,DDInput,YYYYInput can be pure component memoized via React.memo\n const {\n monthInputRef,\n dayInputRef,\n yearInputRef,\n ariaCurrentValueForInputs,\n latestInteractionRegion,\n currFocusDescriber,\n props,\n } = useContext(ControlledDateTimePickerContext);\n const ariaAndDataPropsMonth = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.MONTH]),\n [props],\n );\n const ariaAndDataPropsDay = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.DAY]),\n [props],\n );\n const ariaAndDataPropsYear = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.YEAR]),\n [props],\n );\n\n return (\n <Grid\n cols={[\n fixedValues.smallInputWidth,\n fixedValues.separatorWidth,\n fixedValues.smallInputWidth,\n fixedValues.separatorWidth,\n fixedValues.largeInputWidth,\n ]}\n >\n <StyledFocusWithIn>\n <MMInput\n onChange={onMonthChange}\n onBlur={onMonthBlur}\n onFocus={onMonthFocus}\n onKeyDown={onMonthKeyDown}\n value={month}\n contextRef={monthInputRef}\n innerRef={innerRefMonthInput}\n autoFocusMonthInput={autoFocusMonthInput}\n placeholder=\"MM\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'month-input'}\n ariaAndDataProps={ariaAndDataPropsMonth}\n />\n </StyledFocusWithIn>\n <StyledSeparator alignItems=\"center\">/</StyledSeparator>\n <StyledFocusWithIn>\n <DDInput\n onChange={onDayChange}\n onBlur={onDayBlur}\n onFocus={onDayFocus}\n onKeyDown={onDayKeyDown}\n value={day}\n contextRef={dayInputRef}\n placeholder=\"DD\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'day-input'}\n ariaAndDataProps={ariaAndDataPropsDay}\n />\n </StyledFocusWithIn>\n <StyledSeparator alignItems=\"center\">/</StyledSeparator>\n <StyledFocusWithIn>\n <YYYYInput\n onChange={onYearChange}\n onBlur={onYearBlur}\n onFocus={onYearFocus}\n onKeyDown={onYearKeyDown}\n value={year}\n contextRef={yearInputRef}\n placeholder=\"YYYY\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'year-input'}\n ariaAndDataProps={ariaAndDataPropsYear}\n />\n </StyledFocusWithIn>\n </Grid>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADyDnB;AAzDJ,mBAAkC;AAClC,qBAAqB;AACrB,8BAAsC;AACtC,gDAAmD;AACnD,yCAAgD;AAChD,qBAAwB;AACxB,qBAAwB;AACxB,uBAA0B;AAC1B,qBAAmD;AACnD,2BAA8B;AAC9B,oBAA4B;AAErB,MAAM,aAAa,MAAmB;AAC3C,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA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AAAA,YACZ;AAAA,YACA;AAAA,YACA,WAAW,4BAA4B,iBAAiB,uBAAuB;AAAA,YAC/E,kBAAkB;AAAA;AAAA,QACpB,GACF;AAAA,QACA,4CAAC,kCAAgB,YAAW,UAAS,eAAC;AAAA,QACtC,4CAAC,oCACC;AAAA,UAAC;AAAA;AAAA,YACC,UAAU;AAAA,YACV,QAAQ;AAAA,YACR,SAAS;AAAA,YACT,WAAW;AAAA,YACX,OAAO;AAAA,YACP,YAAY;AAAA,YACZ,aAAY;AAAA,YACZ;AAAA,YACA;AAAA,YACA,WAAW,4BAA4B,iBAAiB,uBAAuB;AAAA,YAC/E,kBAAkB;AAAA;AAAA,QACpB,GACF;AAAA;AAAA;AAAA,EACF;AAEJ;",
4
+ "sourcesContent": ["import React, { useContext } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid.js';\nimport { ControlledDateTimePickerContext } from '../../ControlledDateTimePickerCTX.js';\nimport { MMInput } from './MMInput.js';\nimport { DDInput } from './DDInput.js';\nimport { YYYYInput } from './YYYYInput.js';\nimport { StyledFocusWithIn, StyledSeparator } from '../Styleds.js';\nimport { useDateInputs } from './useDateInputs.js';\nimport { fixedValues } from '../config.js';\n\nexport const DateInputs = (): JSX.Element => {\n const {\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n onMonthChange,\n onDayChange,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthFocus,\n onDayFocus,\n onYearFocus,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n disabled,\n } = useDateInputs();\n // we do this here so MMInput,DDInput,YYYYInput can be pure component memoized via React.memo\n const {\n monthInputRef,\n dayInputRef,\n yearInputRef,\n ariaCurrentValueForInputs,\n latestInteractionRegion,\n currFocusDescriber,\n props,\n } = useContext(ControlledDateTimePickerContext);\n const ariaAndDataPropsMonth = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.MONTH]),\n [props],\n );\n const ariaAndDataPropsDay = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.DAY]),\n [props],\n );\n const ariaAndDataPropsYear = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.DATE_INPUTS.YEAR]),\n [props],\n );\n\n return (\n <Grid\n cols={[\n fixedValues.smallInputWidth,\n fixedValues.separatorWidth,\n fixedValues.smallInputWidth,\n fixedValues.separatorWidth,\n fixedValues.largeInputWidth,\n ]}\n >\n <StyledFocusWithIn>\n <MMInput\n onChange={onMonthChange}\n onBlur={onMonthBlur}\n onFocus={onMonthFocus}\n onKeyDown={onMonthKeyDown}\n value={month}\n contextRef={monthInputRef}\n innerRef={innerRefMonthInput}\n autoFocusMonthInput={autoFocusMonthInput}\n placeholder=\"MM\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'month-input'}\n ariaAndDataProps={ariaAndDataPropsMonth}\n />\n </StyledFocusWithIn>\n <StyledSeparator alignItems=\"center\">/</StyledSeparator>\n <StyledFocusWithIn>\n <DDInput\n onChange={onDayChange}\n onBlur={onDayBlur}\n onFocus={onDayFocus}\n onKeyDown={onDayKeyDown}\n value={day}\n contextRef={dayInputRef}\n placeholder=\"DD\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'day-input'}\n ariaAndDataProps={ariaAndDataPropsDay}\n />\n </StyledFocusWithIn>\n <StyledSeparator alignItems=\"center\">/</StyledSeparator>\n <StyledFocusWithIn>\n <YYYYInput\n onChange={onYearChange}\n onBlur={onYearBlur}\n onFocus={onYearFocus}\n onKeyDown={onYearKeyDown}\n value={year}\n contextRef={yearInputRef}\n placeholder=\"YYYY\"\n ariaCurrentValueForInputs={ariaCurrentValueForInputs}\n disabled={disabled}\n isFocused={latestInteractionRegion === 'date-inputs' && currFocusDescriber === 'year-input'}\n ariaAndDataProps={ariaAndDataPropsYear}\n />\n </StyledFocusWithIn>\n </Grid>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADyDnB;AAzDJ,mBAAkC;AAClC,qBAAqB;AACrB,8BAAsC;AACtC,gDAAmD;AACnD,yCAAgD;AAChD,qBAAwB;AACxB,qBAAwB;AACxB,uBAA0B;AAC1B,qBAAmD;AACnD,2BAA8B;AAC9B,oBAA4B;AAErB,MAAM,aAAa,MAAmB;AAC3C,QAAM;AAAA,IACJ;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,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,oCAAc;AAElB,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,yBAAW,kEAA+B;AAC9C,QAAM,wBAAwB,aAAAA,QAAM;AAAA,IAClC,UAAM,+CAAsB,MAAM,6EAAmC,YAAY,KAAK,CAAC;AAAA,IACvF,CAAC,KAAK;AAAA,EACR;AACA,QAAM,sBAAsB,aAAAA,QAAM;AAAA,IAChC,UAAM,+CAAsB,MAAM,6EAAmC,YAAY,GAAG,CAAC;AAAA,IACrF,CAAC,KAAK;AAAA,EACR;AACA,QAAM,uBAAuB,aAAAA,QAAM;AAAA,IACjC,UAAM,+CAAsB,MAAM,6EAAmC,YAAY,IAAI,CAAC;AAAA,IACtF,CAAC,KAAK;AAAA,EACR;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACC,MAAM;AAAA,QACJ,0BAAY;AAAA,QACZ,0BAAY;AAAA,QACZ,0BAAY;AAAA,QACZ,0BAAY;AAAA,QACZ,0BAAY;AAAA,MACd;AAAA,MAEA;AAAA,oDAAC,oCACC;AAAA,UAAC;AAAA;AAAA,YACC,UAAU;AAAA,YACV,QAAQ;AAAA,YACR,SAAS;AAAA,YACT,WAAW;AAAA,YACX,OAAO;AAAA,YACP,YAAY;AAAA,YACZ,UAAU;AAAA,YACV;AAAA,YACA,aAAY;AAAA,YACZ;AAAA,YACA;AAAA,YACA,WAAW,4BAA4B,iBAAiB,uBAAuB;AAAA,YAC/E,kBAAkB;AAAA;AAAA,QACpB,GACF;AAAA,QACA,4CAAC,kCAAgB,YAAW,UAAS,eAAC;AAAA,QACtC,4CAAC,oCACC;AAAA,UAAC;AAAA;AAAA,YACC,UAAU;AAAA,YACV,QAAQ;AAAA,YACR,SAAS;AAAA,YACT,WAAW;AAAA,YACX,OAAO;AAAA,YACP,YAAY;AAAA,YACZ,aAAY;AAAA,YACZ;AAAA,YACA;AAAA,YACA,WAAW,4BAA4B,iBAAiB,uBAAuB;AAAA,YAC/E,kBAAkB;AAAA;AAAA,QACpB,GACF;AAAA,QACA,4CAAC,kCAAgB,YAAW,UAAS,eAAC;AAAA,QACtC,4CAAC,oCACC;AAAA,UAAC;AAAA;AAAA,YACC,UAAU;AAAA,YACV,QAAQ;AAAA,YACR,SAAS;AAAA,YACT,WAAW;AAAA,YACX,OAAO;AAAA,YACP,YAAY;AAAA,YACZ,aAAY;AAAA,YACZ;AAAA,YACA;AAAA,YACA,WAAW,4BAA4B,iBAAiB,uBAAuB;AAAA,YAC/E,kBAAkB;AAAA;AAAA,QACpB,GACF;AAAA;AAAA;AAAA,EACF;AAEJ;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -31,8 +35,8 @@ var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
37
  var import_ds_utilities = require("@elliemae/ds-utilities");
34
- var import_Styleds = require("../Styleds");
35
- var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid");
38
+ var import_Styleds = require("../Styleds.js");
39
+ var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid.js");
36
40
  const regExpNumbers = /^[0-9]+$/;
37
41
  const isInvalidMonth = (month) => {
38
42
  if (month === "")
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/DateInputs/MMInput.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React, { useCallback, useMemo } from 'react';\nimport { setMultipleRefs } from '@elliemae/ds-utilities';\nimport { Styled2DigitsInput } from '../Styleds';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidMonth = (month: string) => {\n if (month === '') return false;\n const numberOnly = regExpNumbers.test(month);\n return month.length > 2 || month === '00' || !numberOnly || Number.parseInt(month, 10) > 12;\n};\ninterface MMInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n autoFocusMonthInput: boolean;\n value: string;\n disabled: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n innerRef?: React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const MMInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n placeholder,\n contextRef,\n innerRef,\n autoFocusMonthInput,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: MMInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidMonth(e?.target?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n\n const handleRef = useCallback(\n (DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n },\n [contextRef, isFocused],\n );\n\n const currentRef = useMemo(() => {\n if (innerRef) {\n return setMultipleRefs([handleRef, innerRef]);\n }\n return handleRef;\n }, [handleRef, innerRef]);\n\n return (\n <Styled2DigitsInput\n autoFocus={autoFocusMonthInput}\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={currentRef}\n placeholder={placeholder}\n aria-label={`month input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.MONTH}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADsEjB;AAtEN,mBAA4C;AAC5C,0BAAgC;AAChC,qBAAmC;AACnC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ourcesContent": ["import React, { useCallback, useMemo } from 'react';\nimport { setMultipleRefs } from '@elliemae/ds-utilities';\nimport { Styled2DigitsInput } from '../Styleds.js';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidMonth = (month: string) => {\n if (month === '') return false;\n const numberOnly = regExpNumbers.test(month);\n return month.length > 2 || month === '00' || !numberOnly || Number.parseInt(month, 10) > 12;\n};\ninterface MMInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n autoFocusMonthInput: boolean;\n value: string;\n disabled: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n innerRef?: React.MutableRefObject<HTMLInputElement | HTMLButtonElement | null>;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const MMInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n placeholder,\n contextRef,\n innerRef,\n autoFocusMonthInput,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: MMInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidMonth(e?.target?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n\n const handleRef = useCallback(\n (DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n },\n [contextRef, isFocused],\n );\n\n const currentRef = useMemo(() => {\n if (innerRef) {\n return setMultipleRefs([handleRef, innerRef]);\n }\n return handleRef;\n }, [handleRef, innerRef]);\n\n return (\n <Styled2DigitsInput\n autoFocus={autoFocusMonthInput}\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={currentRef}\n placeholder={placeholder}\n aria-label={`month input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.MONTH}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADsEjB;AAtEN,mBAA4C;AAC5C,0BAAgC;AAChC,qBAAmC;AACnC,gDAAmD;AAGnD,MAAM,gBAAgB;AACtB,MAAM,iBAAiB,CAAC,UAAkB;AACxC,MAAI,UAAU;AAAI,WAAO;AACzB,QAAM,aAAa,cAAc,KAAK,KAAK;AAC3C,SAAO,MAAM,SAAS,KAAK,UAAU,QAAQ,CAAC,cAAc,OAAO,SAAS,OAAO,EAAE,IAAI;AAC3F;AAgBO,MAAM,UAAU,aAAAA,QAAM;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,EACF,MAAmC;AACjC,UAAM,uBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,eAAe,GAAG,QAAQ,KAAK,GAAG;AACpC,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AAEA,UAAM,gBAAY;AAAA,MAChB,CAAC,YAA8B;AAC7B,QAAC,WAAwD,UAAU;AACnE,YAAI;AAAW,mBAAS,QAAQ;AAAA,MAClC;AAAA,MACA,CAAC,YAAY,SAAS;AAAA,IACxB;AAEA,UAAM,iBAAa,sBAAQ,MAAM;AAC/B,UAAI,UAAU;AACZ,mBAAO,qCAAgB,CAAC,WAAW,QAAQ,CAAC;AAAA,MAC9C;AACA,aAAO;AAAA,IACT,GAAG,CAAC,WAAW,QAAQ,CAAC;AAExB,WACE;AAAA,MAAC;AAAA;AAAA,QACC,WAAW;AAAA,QACX,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK;AAAA,QACL;AAAA,QACA,cAAY,sBAAsB;AAAA,QAClC,eAAa,6EAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACd,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -30,8 +34,8 @@ module.exports = __toCommonJS(YYYYInput_exports);
30
34
  var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
- var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid");
34
- var import_Styleds = require("../Styleds");
37
+ var import_ControlledDateTimePickerDatatestid = require("../../ControlledDateTimePickerDatatestid.js");
38
+ var import_Styleds = require("../Styleds.js");
35
39
  const regExpNumbers = /^[0-9]+$/;
36
40
  const isInvalidYear = (year) => {
37
41
  if (year === "")
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/DateInputs/YYYYInput.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React, { useCallback } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid';\nimport { StyledMin4DigitsInput } from '../Styleds';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidYear = (year: string) => {\n if (year === '') return false;\n const numberOnly = regExpNumbers.test(year);\n return year.length > 4 || !numberOnly || Number.parseInt(year, 10) > 9999;\n};\n\ninterface YYYYInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const YYYYInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n placeholder,\n contextRef,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: YYYYInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidYear(e?.currentTarget?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n return (\n <StyledMin4DigitsInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={(DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n placeholder={placeholder}\n aria-label={`year input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.YEAR}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkDjB;AAlDN,mBAAmC;AACnC,gDAAmD;AACnD,qBAAsC;AAGtC,MAAM,gBAAgB;AACtB,MAAM,gBAAgB,CAAC,SAAiB;AACtC,MAAI,SAAS;AAAI,WAAO;AACxB,QAAM,aAAa,cAAc,KAAK,IAAI;AAC1C,SAAO,KAAK,SAAS,KAAK,CAAC,cAAc,OAAO,SAAS,MAAM,EAAE,IAAI;AACvE;AAeO,MAAM,YAAY,aAAAA,QAAM;AAAA,EAC7B,CAAC;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,MAAqC;AACnC,UAAM,uBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,cAAc,GAAG,eAAe,KAAK,GAAG;AAC1C,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK,CAAC,YAA8B;AAClC,UAAC,WAAwD,UAAU;AACnE,cAAI;AAAW,qBAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA,cAAY,qBAAqB;AAAA,QACjC,eAAa,6EAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACd,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;",
4
+ "sourcesContent": ["import React, { useCallback } from 'react';\nimport { ControlledDateTimePickerDatatestid } from '../../ControlledDateTimePickerDatatestid.js';\nimport { StyledMin4DigitsInput } from '../Styleds.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\n\nconst regExpNumbers = /^[0-9]+$/;\nconst isInvalidYear = (year: string) => {\n if (year === '') return false;\n const numberOnly = regExpNumbers.test(year);\n return year.length > 4 || !numberOnly || Number.parseInt(year, 10) > 9999;\n};\n\ninterface YYYYInputsPropsT {\n onChange: DSControlledDateTimePickerInternalsT.OnChangeFunc;\n onBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc;\n onFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc;\n onKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown;\n value: string;\n disabled: boolean;\n contextRef: React.MutableRefObject<HTMLInputElement | null>;\n placeholder: string;\n ariaCurrentValueForInputs: string;\n isFocused: boolean;\n ariaAndDataProps?: AriaAndDataProps;\n}\nexport const YYYYInput = React.memo(\n ({\n onChange,\n onBlur,\n onFocus,\n onKeyDown,\n value,\n disabled,\n placeholder,\n contextRef,\n ariaCurrentValueForInputs,\n isFocused,\n ariaAndDataProps,\n }: YYYYInputsPropsT): JSX.Element => {\n const validateOnChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n if (isInvalidYear(e?.currentTarget?.value)) {\n e.preventDefault();\n return;\n }\n onChange(e);\n },\n [onChange],\n );\n return (\n <StyledMin4DigitsInput\n onChange={validateOnChange}\n onBlur={onBlur}\n onFocus={onFocus}\n onKeyDown={onKeyDown}\n value={value}\n ref={(DomElem: HTMLInputElement) => {\n (contextRef as React.MutableRefObject<HTMLInputElement>).current = DomElem;\n if (isFocused) DomElem?.focus?.();\n }}\n placeholder={placeholder}\n aria-label={`year input field, ${ariaCurrentValueForInputs}`}\n data-testid={ControlledDateTimePickerDatatestid.DATE_INPUTS.YEAR}\n disabled={disabled}\n aria-disabled={disabled}\n {...ariaAndDataProps}\n />\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkDjB;AAlDN,mBAAmC;AACnC,gDAAmD;AACnD,qBAAsC;AAGtC,MAAM,gBAAgB;AACtB,MAAM,gBAAgB,CAAC,SAAiB;AACtC,MAAI,SAAS;AAAI,WAAO;AACxB,QAAM,aAAa,cAAc,KAAK,IAAI;AAC1C,SAAO,KAAK,SAAS,KAAK,CAAC,cAAc,OAAO,SAAS,MAAM,EAAE,IAAI;AACvE;AAeO,MAAM,YAAY,aAAAA,QAAM;AAAA,EAC7B,CAAC;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,MAAqC;AACnC,UAAM,uBAAmB;AAAA,MACvB,CAAC,MAA2C;AAC1C,YAAI,cAAc,GAAG,eAAe,KAAK,GAAG;AAC1C,YAAE,eAAe;AACjB;AAAA,QACF;AACA,iBAAS,CAAC;AAAA,MACZ;AAAA,MACA,CAAC,QAAQ;AAAA,IACX;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,UAAU;AAAA,QACV;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK,CAAC,YAA8B;AAClC,UAAC,WAAwD,UAAU;AACnE,cAAI;AAAW,qBAAS,QAAQ;AAAA,QAClC;AAAA,QACA;AAAA,QACA,cAAY,qBAAqB;AAAA,QACjC,eAAa,6EAAmC,YAAY;AAAA,QAC5D;AAAA,QACA,iBAAe;AAAA,QACd,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -29,10 +33,10 @@ __export(useDateInputs_exports, {
29
33
  module.exports = __toCommonJS(useDateInputs_exports);
30
34
  var React = __toESM(require("react"));
31
35
  var import_react = require("react");
32
- var import_ControlledDateTimePickerCTX = require("../../ControlledDateTimePickerCTX");
33
- var import_stringHelpers = require("../../utils/stringHelpers");
34
- var import_dateHelpers = require("../../utils/dateHelpers");
35
- var import_constants = require("../../utils/constants");
36
+ var import_ControlledDateTimePickerCTX = require("../../ControlledDateTimePickerCTX.js");
37
+ var import_stringHelpers = require("../../utils/stringHelpers.js");
38
+ var import_dateHelpers = require("../../utils/dateHelpers.js");
39
+ var import_constants = require("../../utils/constants.js");
36
40
  const useDateInputs = () => {
37
41
  const {
38
42
  props: { disabled },
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/DateInputs/useDateInputs.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable complexity */\n/* eslint-disable max-statements */\n/* eslint-disable max-lines */\nimport { useCallback, useMemo, useContext } from 'react';\nimport { ControlledDateTimePickerContext } from '../../ControlledDateTimePickerCTX';\nimport {\n getFormattedDateString,\n prependStringWithPlaceHolders,\n fillStringWithPlaceHolders,\n} from '../../utils/stringHelpers';\nimport { getValidationDateStringMetaInfo } from '../../utils/dateHelpers';\nimport { defaultMetaInfo } from '../../utils/constants';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes';\nimport type { DSControlledDateTimePickerT } from '../../propTypes';\n\nexport const useDateInputs = (): DSControlledDateTimePickerInternalsT.UseDateInputsR => {\n const {\n props: { disabled },\n appOnMonthChange,\n appOnDayChange,\n appOnYearChange,\n getIsDisabledDay,\n getIsOutOfRangeDay,\n month,\n day,\n year,\n hideTime,\n handleChangeComposedDateString,\n withClearBtn,\n withAnyPicker,\n withAnyRightController,\n autoFocusMonthInput,\n innerRefMonthInput,\n trackFocusResetter,\n trackFocusFirstSegment,\n trackFocusLastSegment,\n trackFocusDayInput,\n trackFocusMonthInput,\n trackFocusYearInput,\n trackFocusHourInput,\n trackFocusClearBtn,\n trackFocusPicker,\n } = useContext(ControlledDateTimePickerContext);\n\n const onHomeKeyDown = useCallback(() => {\n trackFocusFirstSegment();\n }, [trackFocusFirstSegment]);\n const onEndKeyDown = useCallback(() => {\n trackFocusLastSegment();\n }, [trackFocusLastSegment]);\n\n const handleChangeMonth = useCallback(\n (\n newMonth: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month: newMonth,\n day,\n year,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnMonthChange(newMonth, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [day, year, getIsOutOfRangeDay, getIsDisabledDay, appOnMonthChange, handleChangeComposedDateString],\n );\n const onMonthFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusMonthInput();\n }, [trackFocusMonthInput]);\n const onMonthChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n let newMonth = e?.target?.value;\n // converts months 2~9 to 02~09\n if (Number.parseInt(newMonth, 10) > 1) newMonth = prependStringWithPlaceHolders(newMonth, 2);\n handleChangeMonth(newMonth, e);\n // auto-advance functionality:\n if (newMonth.length === 2) trackFocusDayInput();\n },\n [handleChangeMonth, trackFocusDayInput],\n );\n const onMonthKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey } = e;\n const monthStringConvertedToInteger = Number.parseInt(month, 10);\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.stopPropagation();\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n const monthInteger = Number.isNaN(monthStringConvertedToInteger) ? 0 : monthStringConvertedToInteger;\n let newMonth;\n if (key === 'ArrowUp') newMonth = monthInteger + 1 <= 12 ? monthInteger + 1 : monthInteger;\n else newMonth = monthInteger - 1 > 0 ? monthInteger - 1 : 1;\n newMonth = prependStringWithPlaceHolders(`${newMonth}`, 2);\n handleChangeMonth(newMonth, e);\n }\n if (!Number.isNaN(monthStringConvertedToInteger) && (key === '-' || key === '/' || key === '\\\\')) {\n const newMonth = prependStringWithPlaceHolders(`${monthStringConvertedToInteger}`, 2);\n handleChangeMonth(newMonth, e);\n // auto-advance functionality:\n if (newMonth.length === 2) trackFocusDayInput();\n }\n\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [month, onHomeKeyDown, onEndKeyDown, trackFocusLastSegment, trackFocusDayInput, handleChangeMonth],\n );\n const onMonthBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(\n (e) => {\n const newMonth = e?.target?.value;\n if (newMonth === '0') handleChangeMonth('01', e, { isAutomaticFillTrigger: true });\n else if (newMonth.length > 0 && newMonth.length < 2)\n handleChangeMonth(prependStringWithPlaceHolders(newMonth, 2), e, {\n isAutomaticFillTrigger: true,\n });\n },\n [handleChangeMonth],\n );\n\n const handleChangeDay = useCallback(\n (\n newDay: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month,\n day: newDay,\n year,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnDayChange(newDay, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [month, year, getIsOutOfRangeDay, getIsDisabledDay, appOnDayChange, handleChangeComposedDateString],\n );\n const onDayFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusDayInput();\n }, [trackFocusDayInput]);\n const onDayChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n let newDay = e?.target?.value;\n // converts days 4~9 to 04~09\n if (Number.parseInt(newDay, 10) > 3) newDay = prependStringWithPlaceHolders(newDay, 2);\n handleChangeDay(newDay, e);\n // auto-advance functionality:\n if (newDay.length === 2) trackFocusYearInput();\n },\n [handleChangeDay, trackFocusYearInput],\n );\n const onDayKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey, target, currentTarget } = e;\n const dayStringConvertedToInteger = Number.parseInt(day, 10);\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.stopPropagation();\n\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n const dayInteger = Number.isNaN(dayStringConvertedToInteger) ? 0 : dayStringConvertedToInteger;\n let newDay;\n if (key === 'ArrowUp') newDay = dayInteger + 1 <= 31 ? dayInteger + 1 : dayInteger;\n else newDay = dayInteger - 1 > 0 ? dayInteger - 1 : 1;\n newDay = prependStringWithPlaceHolders(`${newDay}`, 2);\n handleChangeDay(newDay, e);\n }\n if (!Number.isNaN(dayStringConvertedToInteger) && (key === '-' || key === '/' || key === '\\\\')) {\n const newDay = prependStringWithPlaceHolders(`${dayStringConvertedToInteger}`, 2);\n handleChangeDay(newDay, e);\n // auto-advance functionality:\n if (newDay.length === 2) trackFocusYearInput();\n }\n // regressive backspace functionality\n if (\n key === 'Backspace' &&\n target === currentTarget &&\n (target as HTMLInputElement).selectionStart === 0 &&\n (target as HTMLInputElement).selectionEnd === 0\n ) {\n e.preventDefault();\n trackFocusMonthInput();\n }\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [\n day,\n onHomeKeyDown,\n onEndKeyDown,\n trackFocusLastSegment,\n handleChangeDay,\n trackFocusYearInput,\n trackFocusMonthInput,\n ],\n );\n const onDayBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(\n (e) => {\n const newDay = e?.target?.value;\n if (newDay === '0') handleChangeDay('01', e, { isAutomaticFillTrigger: true });\n else if (newDay.length > 0 && newDay.length < 2)\n handleChangeDay(prependStringWithPlaceHolders(newDay, 2), e, {\n isAutomaticFillTrigger: true,\n });\n },\n [handleChangeDay],\n );\n\n const handleChangeYear = useCallback(\n (\n newYear: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month,\n day,\n year: newYear,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnYearChange(newYear, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [month, day, getIsOutOfRangeDay, getIsDisabledDay, appOnYearChange, handleChangeComposedDateString],\n );\n const onYearFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusYearInput();\n }, [trackFocusYearInput]);\n const onYearChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n const newYear = e?.target?.value;\n handleChangeYear(newYear, e);\n // auto-advance functionality:\n if (newYear.length === 4) {\n if (!hideTime) trackFocusHourInput();\n else if (withAnyRightController) {\n if (withClearBtn) trackFocusClearBtn();\n else if (withAnyPicker) trackFocusPicker();\n // pending approval from Seda, check which one should be focused first...\n }\n }\n },\n [\n handleChangeYear,\n hideTime,\n trackFocusHourInput,\n withAnyRightController,\n withClearBtn,\n trackFocusClearBtn,\n withAnyPicker,\n trackFocusPicker,\n ],\n );\n const onYearKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey, target, currentTarget } = e;\n\n /* ****** New year value calculator logic ********* */\n const yearStringConvertedToInteger = Number.parseInt(year, 10);\n const yearInteger = Number.isNaN(yearStringConvertedToInteger) ? 0 : yearStringConvertedToInteger;\n let newYear = yearInteger !== 0 ? fillStringWithPlaceHolders(`${yearInteger}`, 4, '0') : '';\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n let newYearInteger;\n if (key === 'ArrowUp') newYearInteger = yearInteger + 1 <= 9999 ? yearInteger + 1 : yearInteger;\n else newYearInteger = yearInteger - 1 > 0 ? yearInteger - 1 : 1;\n newYear = prependStringWithPlaceHolders(`${newYearInteger}`, 4);\n }\n const isAutomaticFillTrigger = newYear !== year && ['Tab', ' '].includes(key);\n const metainfo = { isAutomaticFillTrigger };\n\n /* ************* new year apply logic ************* */\n // tab/spacebar applies auto-fill\n // arrows up/down applies increment/decrement\n if (key === 'ArrowUp' || key === 'ArrowDown' || isAutomaticFillTrigger) {\n handleChangeYear(newYear, e, metainfo);\n }\n\n /* ************* focus tracking logic ************* */\n let trackNextFocus = trackFocusResetter; // if nothing after, we reset internal focus tracker to avoid re-render unexpected focus shift\n if (!hideTime) trackNextFocus = trackFocusHourInput;\n else if (withClearBtn) trackNextFocus = trackFocusClearBtn;\n else if (withAnyPicker) trackNextFocus = trackFocusPicker;\n\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', ' '].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', ' '].includes(key)) e.stopPropagation();\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n\n /* ************** auto-advance logic ************** */\n if (key === ' ') {\n // auto-advance functionality:\n trackNextFocus();\n }\n /* ********** regressive backspace logic ********** */\n if (\n key === 'Backspace' &&\n target === currentTarget &&\n (target as HTMLInputElement).selectionStart === 0 &&\n (target as HTMLInputElement).selectionEnd === 0\n ) {\n e.preventDefault();\n trackFocusDayInput();\n }\n\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [\n year,\n trackFocusResetter,\n hideTime,\n trackFocusHourInput,\n withClearBtn,\n trackFocusClearBtn,\n withAnyPicker,\n trackFocusPicker,\n onHomeKeyDown,\n onEndKeyDown,\n trackFocusLastSegment,\n trackFocusDayInput,\n handleChangeYear,\n ],\n );\n const onYearBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(() => {\n // this was used before, now that we have a wrapping onBlur resetting the focus tracker, this is unused;\n }, []);\n\n return useMemo(\n () => ({\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n disabled,\n onMonthFocus,\n onMonthChange,\n onDayFocus,\n onDayChange,\n onYearFocus,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n }),\n [\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n disabled,\n onMonthFocus,\n onMonthChange,\n onDayFocus,\n onDayChange,\n onYearFocus,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n ],\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADGvB,mBAAiD;AACjD,yCAAgD;AAChD,2BAIO;AACP,yBAAgD;AAChD,uBAAgC;AAIzB,MAAM,gBAAgB,MAA2D;AACtF,QAAM;AAAA,IACJ,OAAO,EAAE,SAAS;AAAA,IAClB;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,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,yBAAW,kEAA+B;AAE9C,QAAM,oBAAgB,0BAAY,MAAM;AACtC,2BAAuB;AAAA,EACzB,GAAG,CAAC,sBAAsB,CAAC;AAC3B,QAAM,mBAAe,0BAAY,MAAM;AACrC,0BAAsB;AAAA,EACxB,GAAG,CAAC,qBAAqB,CAAC;AAE1B,QAAM,wBAAoB;AAAA,IACxB,CACE,UACA,GACA,WAA8E,qCAC3E;AACH,YAAM,oBAAgB,6CAAuB;AAAA,QAC3C,OAAO;AAAA,QACP;AAAA,QACA;AAAA,MACF,CAAC;AACD,YAAM,gBAA0E;AAAA,QAC9E,GAAG;AAAA,QACH,OAAG,oDAAgC,eAAe,oBAAoB,gBAAgB;AAAA,QACtF;AAAA,MACF;AACA,uBAAiB,UAAU,GAAG,aAAa;AAC3C,qCAA+B,eAAe,aAAa;AAAA,IAC7D;AAAA,IACA,CAAC,KAAK,MAAM,oBAAoB,kBAAkB,kBAAkB,8BAA8B;AAAA,EACpG;AACA,QAAM,mBAAiE,0BAAY,MAAM;AACvF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A;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,EACF;AACA,QAAM,iBAA8D,0BAAY,MAAM;AAAA,EAEtF,GAAG,CAAC,CAAC;AAEL,aAAO;AAAA,IACL,OAAO;AAAA,MACL;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,IACA;AAAA,MACE;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,EACF;AACF;",
4
+ "sourcesContent": ["/* eslint-disable complexity */\n/* eslint-disable max-statements */\n/* eslint-disable max-lines */\nimport { useCallback, useMemo, useContext } from 'react';\nimport { ControlledDateTimePickerContext } from '../../ControlledDateTimePickerCTX.js';\nimport {\n getFormattedDateString,\n prependStringWithPlaceHolders,\n fillStringWithPlaceHolders,\n} from '../../utils/stringHelpers.js';\nimport { getValidationDateStringMetaInfo } from '../../utils/dateHelpers.js';\nimport { defaultMetaInfo } from '../../utils/constants.js';\nimport type { DSControlledDateTimePickerInternalsT } from '../../sharedTypes.js';\nimport type { DSControlledDateTimePickerT } from '../../propTypes.js';\n\nexport const useDateInputs = (): DSControlledDateTimePickerInternalsT.UseDateInputsR => {\n const {\n props: { disabled },\n appOnMonthChange,\n appOnDayChange,\n appOnYearChange,\n getIsDisabledDay,\n getIsOutOfRangeDay,\n month,\n day,\n year,\n hideTime,\n handleChangeComposedDateString,\n withClearBtn,\n withAnyPicker,\n withAnyRightController,\n autoFocusMonthInput,\n innerRefMonthInput,\n trackFocusResetter,\n trackFocusFirstSegment,\n trackFocusLastSegment,\n trackFocusDayInput,\n trackFocusMonthInput,\n trackFocusYearInput,\n trackFocusHourInput,\n trackFocusClearBtn,\n trackFocusPicker,\n } = useContext(ControlledDateTimePickerContext);\n\n const onHomeKeyDown = useCallback(() => {\n trackFocusFirstSegment();\n }, [trackFocusFirstSegment]);\n const onEndKeyDown = useCallback(() => {\n trackFocusLastSegment();\n }, [trackFocusLastSegment]);\n\n const handleChangeMonth = useCallback(\n (\n newMonth: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month: newMonth,\n day,\n year,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnMonthChange(newMonth, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [day, year, getIsOutOfRangeDay, getIsDisabledDay, appOnMonthChange, handleChangeComposedDateString],\n );\n const onMonthFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusMonthInput();\n }, [trackFocusMonthInput]);\n const onMonthChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n let newMonth = e?.target?.value;\n // converts months 2~9 to 02~09\n if (Number.parseInt(newMonth, 10) > 1) newMonth = prependStringWithPlaceHolders(newMonth, 2);\n handleChangeMonth(newMonth, e);\n // auto-advance functionality:\n if (newMonth.length === 2) trackFocusDayInput();\n },\n [handleChangeMonth, trackFocusDayInput],\n );\n const onMonthKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey } = e;\n const monthStringConvertedToInteger = Number.parseInt(month, 10);\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.stopPropagation();\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n const monthInteger = Number.isNaN(monthStringConvertedToInteger) ? 0 : monthStringConvertedToInteger;\n let newMonth;\n if (key === 'ArrowUp') newMonth = monthInteger + 1 <= 12 ? monthInteger + 1 : monthInteger;\n else newMonth = monthInteger - 1 > 0 ? monthInteger - 1 : 1;\n newMonth = prependStringWithPlaceHolders(`${newMonth}`, 2);\n handleChangeMonth(newMonth, e);\n }\n if (!Number.isNaN(monthStringConvertedToInteger) && (key === '-' || key === '/' || key === '\\\\')) {\n const newMonth = prependStringWithPlaceHolders(`${monthStringConvertedToInteger}`, 2);\n handleChangeMonth(newMonth, e);\n // auto-advance functionality:\n if (newMonth.length === 2) trackFocusDayInput();\n }\n\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [month, onHomeKeyDown, onEndKeyDown, trackFocusLastSegment, trackFocusDayInput, handleChangeMonth],\n );\n const onMonthBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(\n (e) => {\n const newMonth = e?.target?.value;\n if (newMonth === '0') handleChangeMonth('01', e, { isAutomaticFillTrigger: true });\n else if (newMonth.length > 0 && newMonth.length < 2)\n handleChangeMonth(prependStringWithPlaceHolders(newMonth, 2), e, {\n isAutomaticFillTrigger: true,\n });\n },\n [handleChangeMonth],\n );\n\n const handleChangeDay = useCallback(\n (\n newDay: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month,\n day: newDay,\n year,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnDayChange(newDay, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [month, year, getIsOutOfRangeDay, getIsDisabledDay, appOnDayChange, handleChangeComposedDateString],\n );\n const onDayFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusDayInput();\n }, [trackFocusDayInput]);\n const onDayChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n let newDay = e?.target?.value;\n // converts days 4~9 to 04~09\n if (Number.parseInt(newDay, 10) > 3) newDay = prependStringWithPlaceHolders(newDay, 2);\n handleChangeDay(newDay, e);\n // auto-advance functionality:\n if (newDay.length === 2) trackFocusYearInput();\n },\n [handleChangeDay, trackFocusYearInput],\n );\n const onDayKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey, target, currentTarget } = e;\n const dayStringConvertedToInteger = Number.parseInt(day, 10);\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', '-', '/', '\\\\'].includes(key)) e.stopPropagation();\n\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n const dayInteger = Number.isNaN(dayStringConvertedToInteger) ? 0 : dayStringConvertedToInteger;\n let newDay;\n if (key === 'ArrowUp') newDay = dayInteger + 1 <= 31 ? dayInteger + 1 : dayInteger;\n else newDay = dayInteger - 1 > 0 ? dayInteger - 1 : 1;\n newDay = prependStringWithPlaceHolders(`${newDay}`, 2);\n handleChangeDay(newDay, e);\n }\n if (!Number.isNaN(dayStringConvertedToInteger) && (key === '-' || key === '/' || key === '\\\\')) {\n const newDay = prependStringWithPlaceHolders(`${dayStringConvertedToInteger}`, 2);\n handleChangeDay(newDay, e);\n // auto-advance functionality:\n if (newDay.length === 2) trackFocusYearInput();\n }\n // regressive backspace functionality\n if (\n key === 'Backspace' &&\n target === currentTarget &&\n (target as HTMLInputElement).selectionStart === 0 &&\n (target as HTMLInputElement).selectionEnd === 0\n ) {\n e.preventDefault();\n trackFocusMonthInput();\n }\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [\n day,\n onHomeKeyDown,\n onEndKeyDown,\n trackFocusLastSegment,\n handleChangeDay,\n trackFocusYearInput,\n trackFocusMonthInput,\n ],\n );\n const onDayBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(\n (e) => {\n const newDay = e?.target?.value;\n if (newDay === '0') handleChangeDay('01', e, { isAutomaticFillTrigger: true });\n else if (newDay.length > 0 && newDay.length < 2)\n handleChangeDay(prependStringWithPlaceHolders(newDay, 2), e, {\n isAutomaticFillTrigger: true,\n });\n },\n [handleChangeDay],\n );\n\n const handleChangeYear = useCallback(\n (\n newYear: string,\n e: DSControlledDateTimePickerT.OnInternalValuesChangeEvent,\n metaInfo: Partial<DSControlledDateTimePickerT.InternalInputsChangeMetaInfo> = defaultMetaInfo,\n ) => {\n const newDateString = getFormattedDateString({\n month,\n day,\n year: newYear,\n });\n const finalMetaInfo: DSControlledDateTimePickerT.InternalInputsChangeMetaInfo = {\n ...metaInfo,\n ...getValidationDateStringMetaInfo(newDateString, getIsOutOfRangeDay, getIsDisabledDay),\n newDateString,\n };\n appOnYearChange(newYear, e, finalMetaInfo);\n handleChangeComposedDateString(newDateString, finalMetaInfo);\n },\n [month, day, getIsOutOfRangeDay, getIsDisabledDay, appOnYearChange, handleChangeComposedDateString],\n );\n const onYearFocus: DSControlledDateTimePickerInternalsT.OnFocusFunc = useCallback(() => {\n trackFocusYearInput();\n }, [trackFocusYearInput]);\n const onYearChange: DSControlledDateTimePickerInternalsT.OnChangeFunc = useCallback(\n (e) => {\n const newYear = e?.target?.value;\n handleChangeYear(newYear, e);\n // auto-advance functionality:\n if (newYear.length === 4) {\n if (!hideTime) trackFocusHourInput();\n else if (withAnyRightController) {\n if (withClearBtn) trackFocusClearBtn();\n else if (withAnyPicker) trackFocusPicker();\n // pending approval from Seda, check which one should be focused first...\n }\n }\n },\n [\n handleChangeYear,\n hideTime,\n trackFocusHourInput,\n withAnyRightController,\n withClearBtn,\n trackFocusClearBtn,\n withAnyPicker,\n trackFocusPicker,\n ],\n );\n const onYearKeyDown: DSControlledDateTimePickerInternalsT.OnKeyDown = useCallback(\n (e) => {\n const { key, ctrlKey, metaKey, target, currentTarget } = e;\n\n /* ****** New year value calculator logic ********* */\n const yearStringConvertedToInteger = Number.parseInt(year, 10);\n const yearInteger = Number.isNaN(yearStringConvertedToInteger) ? 0 : yearStringConvertedToInteger;\n let newYear = yearInteger !== 0 ? fillStringWithPlaceHolders(`${yearInteger}`, 4, '0') : '';\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n let newYearInteger;\n if (key === 'ArrowUp') newYearInteger = yearInteger + 1 <= 9999 ? yearInteger + 1 : yearInteger;\n else newYearInteger = yearInteger - 1 > 0 ? yearInteger - 1 : 1;\n newYear = prependStringWithPlaceHolders(`${newYearInteger}`, 4);\n }\n const isAutomaticFillTrigger = newYear !== year && ['Tab', ' '].includes(key);\n const metainfo = { isAutomaticFillTrigger };\n\n /* ************* new year apply logic ************* */\n // tab/spacebar applies auto-fill\n // arrows up/down applies increment/decrement\n if (key === 'ArrowUp' || key === 'ArrowDown' || isAutomaticFillTrigger) {\n handleChangeYear(newYear, e, metainfo);\n }\n\n /* ************* focus tracking logic ************* */\n let trackNextFocus = trackFocusResetter; // if nothing after, we reset internal focus tracker to avoid re-render unexpected focus shift\n if (!hideTime) trackNextFocus = trackFocusHourInput;\n else if (withClearBtn) trackNextFocus = trackFocusClearBtn;\n else if (withAnyPicker) trackNextFocus = trackFocusPicker;\n\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', ' '].includes(key)) e.preventDefault();\n if (['Home', 'End', 'ArrowUp', 'ArrowDown', ' '].includes(key)) e.stopPropagation();\n if (key === 'Home') onHomeKeyDown();\n if (key === 'End') onEndKeyDown();\n\n /* ************** auto-advance logic ************** */\n if (key === ' ') {\n // auto-advance functionality:\n trackNextFocus();\n }\n /* ********** regressive backspace logic ********** */\n if (\n key === 'Backspace' &&\n target === currentTarget &&\n (target as HTMLInputElement).selectionStart === 0 &&\n (target as HTMLInputElement).selectionEnd === 0\n ) {\n e.preventDefault();\n trackFocusDayInput();\n }\n\n // focus last fragment on fill with now\n if ((ctrlKey || metaKey) && key === ';') trackFocusLastSegment();\n },\n [\n year,\n trackFocusResetter,\n hideTime,\n trackFocusHourInput,\n withClearBtn,\n trackFocusClearBtn,\n withAnyPicker,\n trackFocusPicker,\n onHomeKeyDown,\n onEndKeyDown,\n trackFocusLastSegment,\n trackFocusDayInput,\n handleChangeYear,\n ],\n );\n const onYearBlur: DSControlledDateTimePickerInternalsT.OnBlurFunc = useCallback(() => {\n // this was used before, now that we have a wrapping onBlur resetting the focus tracker, this is unused;\n }, []);\n\n return useMemo(\n () => ({\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n disabled,\n onMonthFocus,\n onMonthChange,\n onDayFocus,\n onDayChange,\n onYearFocus,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n }),\n [\n month,\n day,\n year,\n autoFocusMonthInput,\n innerRefMonthInput,\n disabled,\n onMonthFocus,\n onMonthChange,\n onDayFocus,\n onDayChange,\n onYearFocus,\n onYearChange,\n onMonthBlur,\n onDayBlur,\n onYearBlur,\n onMonthKeyDown,\n onDayKeyDown,\n onYearKeyDown,\n ],\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;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AA,MACA;AAAA,IACF;AAAA,EACF;AACA,QAAM,iBAA8D,0BAAY,MAAM;AAAA,EAEtF,GAAG,CAAC,CAAC;AAEL,aAAO;AAAA,IACL,OAAO;AAAA,MACL;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,IACA;AAAA,MACE;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,EACF;AACF;",
6
6
  "names": []
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -31,11 +35,11 @@ module.exports = __toCommonJS(Calendar_exports);
31
35
  var React = __toESM(require("react"));
32
36
  var import_jsx_runtime = require("react/jsx-runtime");
33
37
  var import_react = require("react");
34
- var import_ControlledDateTimePickerCTX = require("../../../ControlledDateTimePickerCTX");
35
- var import_CalendarIconTrigger = require("./CalendarIconTrigger");
36
- var import_CalendarWrapper = require("./CalendarWrapper");
37
- var import_CalendarContext = require("./CalendarContext");
38
- var import_useConfigCalendarCTX = require("./useConfigCalendarCTX");
38
+ var import_ControlledDateTimePickerCTX = require("../../../ControlledDateTimePickerCTX.js");
39
+ var import_CalendarIconTrigger = require("./CalendarIconTrigger.js");
40
+ var import_CalendarWrapper = require("./CalendarWrapper.js");
41
+ var import_CalendarContext = require("./CalendarContext.js");
42
+ var import_useConfigCalendarCTX = require("./useConfigCalendarCTX.js");
39
43
  const WrappedCalendarContext = ({ children }) => {
40
44
  const ctx = (0, import_useConfigCalendarCTX.useConfigCalendarCTX)();
41
45
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_CalendarContext.CalendarContext.Provider, { value: ctx, children });
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/parts/Pickers/Calendar/Calendar.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-len */\nimport React, { useContext } from 'react';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX';\nimport { CalendarIconTrigger } from './CalendarIconTrigger';\nimport { CalendarWrapper } from './CalendarWrapper';\nimport { CalendarContext } from './CalendarContext';\nimport { useConfigCalendarCTX } from './useConfigCalendarCTX';\n\nexport const WrappedCalendarContext = ({ children }: { children: JSX.Element }) => {\n const ctx = useConfigCalendarCTX();\n return <CalendarContext.Provider value={ctx}>{children}</CalendarContext.Provider>;\n};\n\nconst CalendarContent = () => {\n const { showCalendar, handleMenuWrapperKeyDown } = useContext(CalendarContext);\n const { isControllerOnly } = useContext(ControlledDateTimePickerContext);\n return (\n <>\n {isControllerOnly ? null : <CalendarIconTrigger />}\n {isControllerOnly || showCalendar ? (\n <>\n {/* The <div> element is catching the \"ESC\" key to close the calendar, there is no valid aria role for this */}\n {/* https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/no-static-element-interactions.md#case-the-event-handler-is-only-being-used-to-capture-bubbled-events */}\n {/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}\n <div onKeyDown={handleMenuWrapperKeyDown}>\n <CalendarWrapper />\n </div>\n </>\n ) : null}\n </>\n );\n};\n\n// we wrap in context in a separate statement so we can use the useContext and be sure it's correctly initialized\nexport const Calendar = () => (\n <WrappedCalendarContext>\n <CalendarContent />\n </WrappedCalendarContext>\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADUd;AATT,mBAAkC;AAClC,yCAAgD;AAChD,iCAAoC;AACpC,6BAAgC;AAChC,6BAAgC;AAChC,kCAAqC;AAE9B,MAAM,yBAAyB,CAAC,EAAE,SAAS,MAAiC;AACjF,QAAM,UAAM,kDAAqB;AACjC,SAAO,4CAAC,uCAAgB,UAAhB,EAAyB,OAAO,KAAM,UAAS;AACzD;AAEA,MAAM,kBAAkB,MAAM;AAC5B,QAAM,EAAE,cAAc,yBAAyB,QAAI,yBAAW,sCAAe;AAC7E,QAAM,EAAE,iBAAiB,QAAI,yBAAW,kEAA+B;AACvE,SACE,4EACG;AAAA,uBAAmB,OAAO,4CAAC,kDAAoB;AAAA,IAC/C,oBAAoB,eACnB,2EAIE,sDAAC,SAAI,WAAW,0BACd,sDAAC,0CAAgB,GACnB,GACF,IACE;AAAA,KACN;AAEJ;AAGO,MAAM,WAAW,MACtB,4CAAC,0BACC,sDAAC,mBAAgB,GACnB;",
4
+ "sourcesContent": ["/* eslint-disable max-len */\nimport React, { useContext } from 'react';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { CalendarIconTrigger } from './CalendarIconTrigger.js';\nimport { CalendarWrapper } from './CalendarWrapper.js';\nimport { CalendarContext } from './CalendarContext.js';\nimport { useConfigCalendarCTX } from './useConfigCalendarCTX.js';\n\nexport const WrappedCalendarContext = ({ children }: { children: JSX.Element }) => {\n const ctx = useConfigCalendarCTX();\n return <CalendarContext.Provider value={ctx}>{children}</CalendarContext.Provider>;\n};\n\nconst CalendarContent = () => {\n const { showCalendar, handleMenuWrapperKeyDown } = useContext(CalendarContext);\n const { isControllerOnly } = useContext(ControlledDateTimePickerContext);\n return (\n <>\n {isControllerOnly ? null : <CalendarIconTrigger />}\n {isControllerOnly || showCalendar ? (\n <>\n {/* The <div> element is catching the \"ESC\" key to close the calendar, there is no valid aria role for this */}\n {/* https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/no-static-element-interactions.md#case-the-event-handler-is-only-being-used-to-capture-bubbled-events */}\n {/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}\n <div onKeyDown={handleMenuWrapperKeyDown}>\n <CalendarWrapper />\n </div>\n </>\n ) : null}\n </>\n );\n};\n\n// we wrap in context in a separate statement so we can use the useContext and be sure it's correctly initialized\nexport const Calendar = () => (\n <WrappedCalendarContext>\n <CalendarContent />\n </WrappedCalendarContext>\n);\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADUd;AATT,mBAAkC;AAClC,yCAAgD;AAChD,iCAAoC;AACpC,6BAAgC;AAChC,6BAAgC;AAChC,kCAAqC;AAE9B,MAAM,yBAAyB,CAAC,EAAE,SAAS,MAAiC;AACjF,QAAM,UAAM,kDAAqB;AACjC,SAAO,4CAAC,uCAAgB,UAAhB,EAAyB,OAAO,KAAM,UAAS;AACzD;AAEA,MAAM,kBAAkB,MAAM;AAC5B,QAAM,EAAE,cAAc,yBAAyB,QAAI,yBAAW,sCAAe;AAC7E,QAAM,EAAE,iBAAiB,QAAI,yBAAW,kEAA+B;AACvE,SACE,4EACG;AAAA,uBAAmB,OAAO,4CAAC,kDAAoB;AAAA,IAC/C,oBAAoB,eACnB,2EAIE,sDAAC,SAAI,WAAW,0BACd,sDAAC,0CAAgB,GACnB,GACF,IACE;AAAA,KACN;AAEJ;AAGO,MAAM,WAAW,MACtB,4CAAC,0BACC,sDAAC,mBAAgB,GACnB;",
6
6
  "names": []
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -30,9 +34,9 @@ module.exports = __toCommonJS(CalendarBody_exports);
30
34
  var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
- var import_CalendarMonthDays = require("./CalendarMonthDays");
34
- var import_CalendarWeekDays = require("./CalendarWeekDays");
35
- var import_Styleds = require("./Styleds");
37
+ var import_CalendarMonthDays = require("./CalendarMonthDays.js");
38
+ var import_CalendarWeekDays = require("./CalendarWeekDays.js");
39
+ var import_Styleds = require("./Styleds.js");
36
40
  const CalendarBody = import_react.default.memo(({ weekRowsNum }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { role: "grid", "aria-colcount": 7, "aria-rowcount": weekRowsNum, children: [
37
41
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_CalendarWeekDays.CalendarWeekDays, {}),
38
42
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Styleds.StyledBody, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_CalendarMonthDays.CalendarMonthDays, {}) })
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/parts/Pickers/Calendar/CalendarBody.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React from 'react';\nimport { CalendarMonthDays } from './CalendarMonthDays';\nimport { CalendarWeekDays } from './CalendarWeekDays';\nimport { StyledBody } from './Styleds';\ninterface CalendarBodyPropsT {\n weekRowsNum: number;\n}\nexport const CalendarBody = React.memo(({ weekRowsNum }: CalendarBodyPropsT) => (\n <span role=\"grid\" aria-colcount={7} aria-rowcount={weekRowsNum}>\n <CalendarWeekDays />\n <StyledBody>\n <CalendarMonthDays />\n </StyledBody>\n </span>\n));\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADQrB;AARF,mBAAkB;AAClB,+BAAkC;AAClC,8BAAiC;AACjC,qBAA2B;AAIpB,MAAM,eAAe,aAAAA,QAAM,KAAK,CAAC,EAAE,YAAY,MACpD,6CAAC,UAAK,MAAK,QAAO,iBAAe,GAAG,iBAAe,aACjD;AAAA,8CAAC,4CAAiB;AAAA,EAClB,4CAAC,6BACC,sDAAC,8CAAkB,GACrB;AAAA,GACF,CACD;",
4
+ "sourcesContent": ["import React from 'react';\nimport { CalendarMonthDays } from './CalendarMonthDays.js';\nimport { CalendarWeekDays } from './CalendarWeekDays.js';\nimport { StyledBody } from './Styleds.js';\ninterface CalendarBodyPropsT {\n weekRowsNum: number;\n}\nexport const CalendarBody = React.memo(({ weekRowsNum }: CalendarBodyPropsT) => (\n <span role=\"grid\" aria-colcount={7} aria-rowcount={weekRowsNum}>\n <CalendarWeekDays />\n <StyledBody>\n <CalendarMonthDays />\n </StyledBody>\n </span>\n));\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADQrB;AARF,mBAAkB;AAClB,+BAAkC;AAClC,8BAAiC;AACjC,qBAA2B;AAIpB,MAAM,eAAe,aAAAA,QAAM,KAAK,CAAC,EAAE,YAAY,MACpD,6CAAC,UAAK,MAAK,QAAO,iBAAe,GAAG,iBAAe,aACjD;AAAA,8CAAC,4CAAiB;AAAA,EAClB,4CAAC,6BACC,sDAAC,8CAAkB,GACrB;AAAA,GACF,CACD;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -31,13 +35,13 @@ var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
37
  var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
34
- var import_ControlledDateTimePickerDatatestid = require("../../../ControlledDateTimePickerDatatestid");
35
- var import_CalendarBody = require("./CalendarBody");
36
- var import_CalendarHead = require("./CalendarHead");
37
- var import_CalendarFooter = require("./CalendarFooter");
38
- var import_ControlledDateTimePickerCTX = require("../../../ControlledDateTimePickerCTX");
39
- var import_CalendarContext = require("./CalendarContext");
40
- var import_Styleds = require("./Styleds");
38
+ var import_ControlledDateTimePickerDatatestid = require("../../../ControlledDateTimePickerDatatestid.js");
39
+ var import_CalendarBody = require("./CalendarBody.js");
40
+ var import_CalendarHead = require("./CalendarHead.js");
41
+ var import_CalendarFooter = require("./CalendarFooter.js");
42
+ var import_ControlledDateTimePickerCTX = require("../../../ControlledDateTimePickerCTX.js");
43
+ var import_CalendarContext = require("./CalendarContext.js");
44
+ var import_Styleds = require("./Styleds.js");
41
45
  const CalendarContent = ({ className = "" }) => {
42
46
  const { props } = (0, import_react.useContext)(import_ControlledDateTimePickerCTX.ControlledDateTimePickerContext);
43
47
  const { daysMatrixByWeekday } = (0, import_react.useContext)(import_CalendarContext.CalendarContext);
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/parts/Pickers/Calendar/CalendarContent.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-len */\nimport React, { useContext } from 'react';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerDatatestid } from '../../../ControlledDateTimePickerDatatestid';\nimport { CalendarBody } from './CalendarBody';\nimport { CalendarHead } from './CalendarHead';\nimport { CalendarFooter } from './CalendarFooter';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX';\nimport { CalendarContext } from './CalendarContext';\nimport { StyledShadowWrapper, StyledCalendarWrapper } from './Styleds';\n\n// ({ className = '' }: { className?: string })\n// <StyledShadowWrapper className={className}>\n// is required for styled-components, without this we can't styled(CalendarContent)...\n// https://stackoverflow.com/questions/52542817/styled-components-not-applying-style-to-custom-functional-react-component\nexport const CalendarContent = ({ className = '' }: { className?: string }): JSX.Element => {\n const { props } = useContext(ControlledDateTimePickerContext);\n const { daysMatrixByWeekday } = useContext(CalendarContext);\n const ariaAndDataProps = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.CONTROLLER_COMPONENT.CALENDAR]),\n [props],\n );\n\n return (\n <StyledShadowWrapper\n className={className}\n data-testid={ControlledDateTimePickerDatatestid.CONTROLLER_COMPONENT.CALENDAR}\n {...ariaAndDataProps}\n >\n <StyledCalendarWrapper>\n <CalendarHead />\n <CalendarBody weekRowsNum={daysMatrixByWeekday.length} />\n <CalendarFooter />\n </StyledCalendarWrapper>\n </StyledShadowWrapper>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD6BjB;AA5BN,mBAAkC;AAClC,8BAAsC;AACtC,gDAAmD;AACnD,0BAA6B;AAC7B,0BAA6B;AAC7B,4BAA+B;AAC/B,yCAAgD;AAChD,6BAAgC;AAChC,qBAA2D;AAMpD,MAAM,kBAAkB,CAAC,EAAE,YAAY,GAAG,MAA2C;AAC1F,QAAM,EAAE,MAAM,QAAI,yBAAW,kEAA+B;AAC5D,QAAM,EAAE,oBAAoB,QAAI,yBAAW,sCAAe;AAC1D,QAAM,mBAAmB,aAAAA,QAAM;AAAA,IAC7B,UAAM,+CAAsB,MAAM,6EAAmC,qBAAqB,SAAS;AAAA,IACnG,CAAC,KAAK;AAAA,EACR;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,eAAa,6EAAmC,qBAAqB;AAAA,MACpE,GAAG;AAAA,MAEJ,uDAAC,wCACC;AAAA,oDAAC,oCAAa;AAAA,QACd,4CAAC,oCAAa,aAAa,oBAAoB,QAAQ;AAAA,QACvD,4CAAC,wCAAe;AAAA,SAClB;AAAA;AAAA,EACF;AAEJ;",
4
+ "sourcesContent": ["/* eslint-disable max-len */\nimport React, { useContext } from 'react';\nimport { getPropsPerDatatestid } from '@elliemae/ds-props-helpers';\nimport { ControlledDateTimePickerDatatestid } from '../../../ControlledDateTimePickerDatatestid.js';\nimport { CalendarBody } from './CalendarBody.js';\nimport { CalendarHead } from './CalendarHead.js';\nimport { CalendarFooter } from './CalendarFooter.js';\nimport { ControlledDateTimePickerContext } from '../../../ControlledDateTimePickerCTX.js';\nimport { CalendarContext } from './CalendarContext.js';\nimport { StyledShadowWrapper, StyledCalendarWrapper } from './Styleds.js';\n\n// ({ className = '' }: { className?: string })\n// <StyledShadowWrapper className={className}>\n// is required for styled-components, without this we can't styled(CalendarContent)...\n// https://stackoverflow.com/questions/52542817/styled-components-not-applying-style-to-custom-functional-react-component\nexport const CalendarContent = ({ className = '' }: { className?: string }): JSX.Element => {\n const { props } = useContext(ControlledDateTimePickerContext);\n const { daysMatrixByWeekday } = useContext(CalendarContext);\n const ariaAndDataProps = React.useMemo(\n () => getPropsPerDatatestid(props[ControlledDateTimePickerDatatestid.CONTROLLER_COMPONENT.CALENDAR]),\n [props],\n );\n\n return (\n <StyledShadowWrapper\n className={className}\n data-testid={ControlledDateTimePickerDatatestid.CONTROLLER_COMPONENT.CALENDAR}\n {...ariaAndDataProps}\n >\n <StyledCalendarWrapper>\n <CalendarHead />\n <CalendarBody weekRowsNum={daysMatrixByWeekday.length} />\n <CalendarFooter />\n </StyledCalendarWrapper>\n </StyledShadowWrapper>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD6BjB;AA5BN,mBAAkC;AAClC,8BAAsC;AACtC,gDAAmD;AACnD,0BAA6B;AAC7B,0BAA6B;AAC7B,4BAA+B;AAC/B,yCAAgD;AAChD,6BAAgC;AAChC,qBAA2D;AAMpD,MAAM,kBAAkB,CAAC,EAAE,YAAY,GAAG,MAA2C;AAC1F,QAAM,EAAE,MAAM,QAAI,yBAAW,kEAA+B;AAC5D,QAAM,EAAE,oBAAoB,QAAI,yBAAW,sCAAe;AAC1D,QAAM,mBAAmB,aAAAA,QAAM;AAAA,IAC7B,UAAM,+CAAsB,MAAM,6EAAmC,qBAAqB,QAAQ,CAAC;AAAA,IACnG,CAAC,KAAK;AAAA,EACR;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,eAAa,6EAAmC,qBAAqB;AAAA,MACpE,GAAG;AAAA,MAEJ,uDAAC,wCACC;AAAA,oDAAC,oCAAa;AAAA,QACd,4CAAC,oCAAa,aAAa,oBAAoB,QAAQ;AAAA,QACvD,4CAAC,wCAAe;AAAA,SAClB;AAAA;AAAA,EACF;AAEJ;",
6
6
  "names": ["React"]
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/parts/Pickers/Calendar/CalendarContext.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { createContext } from 'react';\nimport type { CalendarContextT } from './useConfigCalendarCTX';\n\nexport const defaultCalendarContext = {} as CalendarContextT;\n\n/** Context for cross component communication */\nexport const CalendarContext = createContext<CalendarContextT>(defaultCalendarContext);\n\nexport default CalendarContext;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAA8B;AAGvB,MAAM,yBAAyB,CAAC;AAGhC,MAAM,sBAAkB,4BAAgC,sBAAsB;AAErF,IAAO,0BAAQ;",
4
+ "sourcesContent": ["import { createContext } from 'react';\nimport type { CalendarContextT } from './useConfigCalendarCTX.js';\n\nexport const defaultCalendarContext = {} as CalendarContextT;\n\n/** Context for cross component communication */\nexport const CalendarContext = createContext<CalendarContextT>(defaultCalendarContext);\n\nexport default CalendarContext;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAA8B;AAGvB,MAAM,yBAAyB,CAAC;AAGhC,MAAM,sBAAkB,4BAAgC,sBAAsB;AAErF,IAAO,0BAAQ;",
6
6
  "names": []
7
7
  }
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  return to;
19
19
  };
20
20
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
21
25
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
22
26
  mod
23
27
  ));
@@ -30,8 +34,8 @@ module.exports = __toCommonJS(CalendarDaysList_exports);
30
34
  var React = __toESM(require("react"));
31
35
  var import_jsx_runtime = require("react/jsx-runtime");
32
36
  var import_react = __toESM(require("react"));
33
- var import_Day = require("./Day");
34
- var import_Styleds = require("./Styleds");
37
+ var import_Day = require("./Day.js");
38
+ var import_Styleds = require("./Styleds.js");
35
39
  const CalendarDaysList = import_react.default.memo(
36
40
  ({ invisibleFirstDay, daysMatrixByWeekday, invisibleLastDay, innerRef }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { ref: innerRef, role: "rowgroup", children: [
37
41
  invisibleFirstDay ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Day.Day, { metaDay: invisibleFirstDay, isInvisible: true }, `ds-calendar-${invisibleFirstDay.day.toString()}`) : null,