rn-grid-date-time-picker 1.0.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (384) hide show
  1. package/CHANGELOG.md +86 -0
  2. package/README.md +100 -638
  3. package/lib/commonjs/adapters/utcMidnight.js +15 -6
  4. package/lib/commonjs/adapters/utcMidnight.js.map +1 -1
  5. package/lib/commonjs/components/DateTimePicker.js +484 -85
  6. package/lib/commonjs/components/DateTimePicker.js.map +1 -1
  7. package/lib/commonjs/components/calendar/Calendar.js +21 -7
  8. package/lib/commonjs/components/calendar/Calendar.js.map +1 -1
  9. package/lib/commonjs/components/calendar/CalendarHeader.js +46 -6
  10. package/lib/commonjs/components/calendar/CalendarHeader.js.map +1 -1
  11. package/lib/commonjs/components/calendar/CalendarSwitch.js +150 -0
  12. package/lib/commonjs/components/calendar/CalendarSwitch.js.map +1 -0
  13. package/lib/commonjs/components/calendar/DayCell.js +8 -3
  14. package/lib/commonjs/components/calendar/DayCell.js.map +1 -1
  15. package/lib/commonjs/components/calendar/DayGrid.js +13 -2
  16. package/lib/commonjs/components/calendar/DayGrid.js.map +1 -1
  17. package/lib/commonjs/components/calendar/PeriodGrid.js +3 -1
  18. package/lib/commonjs/components/calendar/PeriodGrid.js.map +1 -1
  19. package/lib/commonjs/components/calendar/calendarStyles.js +3 -2
  20. package/lib/commonjs/components/calendar/calendarStyles.js.map +1 -1
  21. package/lib/commonjs/components/calendar/localeNames.js +46 -24
  22. package/lib/commonjs/components/calendar/localeNames.js.map +1 -1
  23. package/lib/commonjs/components/calendar/selection.js +9 -1
  24. package/lib/commonjs/components/calendar/selection.js.map +1 -1
  25. package/lib/commonjs/components/container/DefaultSheet.js +42 -11
  26. package/lib/commonjs/components/container/DefaultSheet.js.map +1 -1
  27. package/lib/commonjs/components/container/PickerContainer.js +4 -0
  28. package/lib/commonjs/components/container/PickerContainer.js.map +1 -1
  29. package/lib/commonjs/components/container/PickerLayout.js +1 -1
  30. package/lib/commonjs/components/container/PickerLayout.js.map +1 -1
  31. package/lib/commonjs/components/container/containerStyles.js +12 -4
  32. package/lib/commonjs/components/container/containerStyles.js.map +1 -1
  33. package/lib/commonjs/components/field/RangeFields.js +5 -1
  34. package/lib/commonjs/components/field/RangeFields.js.map +1 -1
  35. package/lib/commonjs/components/field/SegmentedInput.js +8 -3
  36. package/lib/commonjs/components/field/SegmentedInput.js.map +1 -1
  37. package/lib/commonjs/components/field/ValueField.js +64 -8
  38. package/lib/commonjs/components/field/ValueField.js.map +1 -1
  39. package/lib/commonjs/components/field/fieldStyles.js +17 -0
  40. package/lib/commonjs/components/field/fieldStyles.js.map +1 -1
  41. package/lib/commonjs/components/field/fieldText.js +29 -13
  42. package/lib/commonjs/components/field/fieldText.js.map +1 -1
  43. package/lib/commonjs/components/hooks/useBottomInset.js +32 -0
  44. package/lib/commonjs/components/hooks/useBottomInset.js.map +1 -0
  45. package/lib/commonjs/components/hooks/useKeyboardFold.js +36 -13
  46. package/lib/commonjs/components/hooks/useKeyboardFold.js.map +1 -1
  47. package/lib/commonjs/components/hooks/useOpenPicker.js +39 -17
  48. package/lib/commonjs/components/hooks/useOpenPicker.js.map +1 -1
  49. package/lib/commonjs/components/hooks/useTypedSegments.js +6 -2
  50. package/lib/commonjs/components/hooks/useTypedSegments.js.map +1 -1
  51. package/lib/commonjs/components/theme/defaultStrings.js +13 -3
  52. package/lib/commonjs/components/theme/defaultStrings.js.map +1 -1
  53. package/lib/commonjs/components/theme/direction.js +17 -0
  54. package/lib/commonjs/components/theme/direction.js.map +1 -0
  55. package/lib/commonjs/components/theme/numerals.js +16 -0
  56. package/lib/commonjs/components/theme/numerals.js.map +1 -0
  57. package/lib/commonjs/components/theme/styleKeys.js +10 -2
  58. package/lib/commonjs/components/theme/styleKeys.js.map +1 -1
  59. package/lib/commonjs/components/theme/tokens.js +4 -0
  60. package/lib/commonjs/components/theme/tokens.js.map +1 -1
  61. package/lib/commonjs/components/time/TimeRow.js +10 -2
  62. package/lib/commonjs/components/time/TimeRow.js.map +1 -1
  63. package/lib/commonjs/components/time/TypedTime.js +3 -1
  64. package/lib/commonjs/components/time/TypedTime.js.map +1 -1
  65. package/lib/commonjs/components/time/Wheel.js +20 -3
  66. package/lib/commonjs/components/time/Wheel.js.map +1 -1
  67. package/lib/commonjs/components/time/timeStyles.js +4 -5
  68. package/lib/commonjs/components/time/timeStyles.js.map +1 -1
  69. package/lib/commonjs/components/types.js +10 -0
  70. package/lib/commonjs/components/types.js.map +1 -1
  71. package/lib/commonjs/core/calendarSystem.js +123 -22
  72. package/lib/commonjs/core/calendarSystem.js.map +1 -1
  73. package/lib/commonjs/core/digits.js +25 -0
  74. package/lib/commonjs/core/digits.js.map +1 -0
  75. package/lib/commonjs/core/draft.js +31 -10
  76. package/lib/commonjs/core/draft.js.map +1 -1
  77. package/lib/commonjs/core/locale.js +20 -4
  78. package/lib/commonjs/core/locale.js.map +1 -1
  79. package/lib/commonjs/core/numerals.js +46 -0
  80. package/lib/commonjs/core/numerals.js.map +1 -0
  81. package/lib/commonjs/core/segmentEditor.js +9 -0
  82. package/lib/commonjs/core/segmentEditor.js.map +1 -1
  83. package/lib/commonjs/core/segments.js +2 -11
  84. package/lib/commonjs/core/segments.js.map +1 -1
  85. package/lib/commonjs/core/selectionRules.js +2 -1
  86. package/lib/commonjs/core/selectionRules.js.map +1 -1
  87. package/lib/commonjs/core/timeEntry.js +7 -91
  88. package/lib/commonjs/core/timeEntry.js.map +1 -1
  89. package/lib/commonjs/icons/index.js +5 -1
  90. package/lib/commonjs/icons/index.js.map +1 -1
  91. package/lib/commonjs/index.js +20 -0
  92. package/lib/commonjs/index.js.map +1 -1
  93. package/lib/module/adapters/utcMidnight.js +14 -5
  94. package/lib/module/adapters/utcMidnight.js.map +1 -1
  95. package/lib/module/components/DateTimePicker.js +490 -91
  96. package/lib/module/components/DateTimePicker.js.map +1 -1
  97. package/lib/module/components/calendar/Calendar.js +25 -11
  98. package/lib/module/components/calendar/Calendar.js.map +1 -1
  99. package/lib/module/components/calendar/CalendarHeader.js +47 -7
  100. package/lib/module/components/calendar/CalendarHeader.js.map +1 -1
  101. package/lib/module/components/calendar/CalendarSwitch.js +145 -0
  102. package/lib/module/components/calendar/CalendarSwitch.js.map +1 -0
  103. package/lib/module/components/calendar/DayCell.js +8 -3
  104. package/lib/module/components/calendar/DayCell.js.map +1 -1
  105. package/lib/module/components/calendar/DayGrid.js +14 -3
  106. package/lib/module/components/calendar/DayGrid.js.map +1 -1
  107. package/lib/module/components/calendar/PeriodGrid.js +3 -1
  108. package/lib/module/components/calendar/PeriodGrid.js.map +1 -1
  109. package/lib/module/components/calendar/calendarStyles.js +3 -2
  110. package/lib/module/components/calendar/calendarStyles.js.map +1 -1
  111. package/lib/module/components/calendar/localeNames.js +46 -24
  112. package/lib/module/components/calendar/localeNames.js.map +1 -1
  113. package/lib/module/components/calendar/selection.js +7 -0
  114. package/lib/module/components/calendar/selection.js.map +1 -1
  115. package/lib/module/components/container/DefaultSheet.js +42 -12
  116. package/lib/module/components/container/DefaultSheet.js.map +1 -1
  117. package/lib/module/components/container/PickerContainer.js +4 -0
  118. package/lib/module/components/container/PickerContainer.js.map +1 -1
  119. package/lib/module/components/container/PickerLayout.js +1 -1
  120. package/lib/module/components/container/PickerLayout.js.map +1 -1
  121. package/lib/module/components/container/containerStyles.js +11 -3
  122. package/lib/module/components/container/containerStyles.js.map +1 -1
  123. package/lib/module/components/field/RangeFields.js +5 -1
  124. package/lib/module/components/field/RangeFields.js.map +1 -1
  125. package/lib/module/components/field/SegmentedInput.js +8 -3
  126. package/lib/module/components/field/SegmentedInput.js.map +1 -1
  127. package/lib/module/components/field/ValueField.js +66 -10
  128. package/lib/module/components/field/ValueField.js.map +1 -1
  129. package/lib/module/components/field/fieldStyles.js +17 -0
  130. package/lib/module/components/field/fieldStyles.js.map +1 -1
  131. package/lib/module/components/field/fieldText.js +28 -11
  132. package/lib/module/components/field/fieldText.js.map +1 -1
  133. package/lib/module/components/hooks/useBottomInset.js +27 -0
  134. package/lib/module/components/hooks/useBottomInset.js.map +1 -0
  135. package/lib/module/components/hooks/useKeyboardFold.js +33 -12
  136. package/lib/module/components/hooks/useKeyboardFold.js.map +1 -1
  137. package/lib/module/components/hooks/useOpenPicker.js +39 -17
  138. package/lib/module/components/hooks/useOpenPicker.js.map +1 -1
  139. package/lib/module/components/hooks/useTypedSegments.js +6 -2
  140. package/lib/module/components/hooks/useTypedSegments.js.map +1 -1
  141. package/lib/module/components/theme/defaultStrings.js +11 -2
  142. package/lib/module/components/theme/defaultStrings.js.map +1 -1
  143. package/lib/module/components/theme/direction.js +13 -0
  144. package/lib/module/components/theme/direction.js.map +1 -0
  145. package/lib/module/components/theme/numerals.js +12 -0
  146. package/lib/module/components/theme/numerals.js.map +1 -0
  147. package/lib/module/components/theme/styleKeys.js +10 -2
  148. package/lib/module/components/theme/styleKeys.js.map +1 -1
  149. package/lib/module/components/theme/tokens.js +4 -0
  150. package/lib/module/components/theme/tokens.js.map +1 -1
  151. package/lib/module/components/time/TimeRow.js +11 -3
  152. package/lib/module/components/time/TimeRow.js.map +1 -1
  153. package/lib/module/components/time/TypedTime.js +3 -1
  154. package/lib/module/components/time/TypedTime.js.map +1 -1
  155. package/lib/module/components/time/Wheel.js +18 -2
  156. package/lib/module/components/time/Wheel.js.map +1 -1
  157. package/lib/module/components/time/timeStyles.js +4 -5
  158. package/lib/module/components/time/timeStyles.js.map +1 -1
  159. package/lib/module/components/types.js +10 -0
  160. package/lib/module/components/types.js.map +1 -1
  161. package/lib/module/core/calendarSystem.js +118 -19
  162. package/lib/module/core/calendarSystem.js.map +1 -1
  163. package/lib/module/core/digits.js +20 -0
  164. package/lib/module/core/digits.js.map +1 -0
  165. package/lib/module/core/draft.js +29 -9
  166. package/lib/module/core/draft.js.map +1 -1
  167. package/lib/module/core/locale.js +18 -3
  168. package/lib/module/core/locale.js.map +1 -1
  169. package/lib/module/core/numerals.js +39 -0
  170. package/lib/module/core/numerals.js.map +1 -0
  171. package/lib/module/core/segmentEditor.js +9 -0
  172. package/lib/module/core/segmentEditor.js.map +1 -1
  173. package/lib/module/core/segments.js +0 -8
  174. package/lib/module/core/segments.js.map +1 -1
  175. package/lib/module/core/selectionRules.js +2 -1
  176. package/lib/module/core/selectionRules.js.map +1 -1
  177. package/lib/module/core/timeEntry.js +7 -89
  178. package/lib/module/core/timeEntry.js.map +1 -1
  179. package/lib/module/icons/index.js +5 -1
  180. package/lib/module/icons/index.js.map +1 -1
  181. package/lib/module/index.js +2 -0
  182. package/lib/module/index.js.map +1 -1
  183. package/lib/typescript/commonjs/src/adapters/utcMidnight.d.ts.map +1 -1
  184. package/lib/typescript/commonjs/src/components/DateTimePicker.d.ts.map +1 -1
  185. package/lib/typescript/commonjs/src/components/calendar/Calendar.d.ts +8 -4
  186. package/lib/typescript/commonjs/src/components/calendar/Calendar.d.ts.map +1 -1
  187. package/lib/typescript/commonjs/src/components/calendar/CalendarHeader.d.ts.map +1 -1
  188. package/lib/typescript/commonjs/src/components/calendar/CalendarSwitch.d.ts +26 -0
  189. package/lib/typescript/commonjs/src/components/calendar/CalendarSwitch.d.ts.map +1 -0
  190. package/lib/typescript/commonjs/src/components/calendar/DayCell.d.ts +1 -1
  191. package/lib/typescript/commonjs/src/components/calendar/DayCell.d.ts.map +1 -1
  192. package/lib/typescript/commonjs/src/components/calendar/DayGrid.d.ts +2 -0
  193. package/lib/typescript/commonjs/src/components/calendar/DayGrid.d.ts.map +1 -1
  194. package/lib/typescript/commonjs/src/components/calendar/PeriodGrid.d.ts.map +1 -1
  195. package/lib/typescript/commonjs/src/components/calendar/calendarStyles.d.ts +1 -1
  196. package/lib/typescript/commonjs/src/components/calendar/calendarStyles.d.ts.map +1 -1
  197. package/lib/typescript/commonjs/src/components/calendar/localeNames.d.ts +8 -3
  198. package/lib/typescript/commonjs/src/components/calendar/localeNames.d.ts.map +1 -1
  199. package/lib/typescript/commonjs/src/components/calendar/selection.d.ts +2 -0
  200. package/lib/typescript/commonjs/src/components/calendar/selection.d.ts.map +1 -1
  201. package/lib/typescript/commonjs/src/components/container/DefaultSheet.d.ts +10 -2
  202. package/lib/typescript/commonjs/src/components/container/DefaultSheet.d.ts.map +1 -1
  203. package/lib/typescript/commonjs/src/components/container/PickerContainer.d.ts.map +1 -1
  204. package/lib/typescript/commonjs/src/components/container/containerStyles.d.ts +6 -0
  205. package/lib/typescript/commonjs/src/components/container/containerStyles.d.ts.map +1 -1
  206. package/lib/typescript/commonjs/src/components/field/RangeFields.d.ts +5 -0
  207. package/lib/typescript/commonjs/src/components/field/RangeFields.d.ts.map +1 -1
  208. package/lib/typescript/commonjs/src/components/field/SegmentedInput.d.ts.map +1 -1
  209. package/lib/typescript/commonjs/src/components/field/ValueField.d.ts +7 -0
  210. package/lib/typescript/commonjs/src/components/field/ValueField.d.ts.map +1 -1
  211. package/lib/typescript/commonjs/src/components/field/fieldStyles.d.ts +15 -0
  212. package/lib/typescript/commonjs/src/components/field/fieldStyles.d.ts.map +1 -1
  213. package/lib/typescript/commonjs/src/components/field/fieldText.d.ts +14 -5
  214. package/lib/typescript/commonjs/src/components/field/fieldText.d.ts.map +1 -1
  215. package/lib/typescript/commonjs/src/components/hooks/useBottomInset.d.ts +8 -0
  216. package/lib/typescript/commonjs/src/components/hooks/useBottomInset.d.ts.map +1 -0
  217. package/lib/typescript/commonjs/src/components/hooks/useKeyboardFold.d.ts +10 -2
  218. package/lib/typescript/commonjs/src/components/hooks/useKeyboardFold.d.ts.map +1 -1
  219. package/lib/typescript/commonjs/src/components/hooks/useOpenPicker.d.ts +2 -1
  220. package/lib/typescript/commonjs/src/components/hooks/useOpenPicker.d.ts.map +1 -1
  221. package/lib/typescript/commonjs/src/components/hooks/useTypedSegments.d.ts +3 -2
  222. package/lib/typescript/commonjs/src/components/hooks/useTypedSegments.d.ts.map +1 -1
  223. package/lib/typescript/commonjs/src/components/theme/defaultStrings.d.ts +13 -2
  224. package/lib/typescript/commonjs/src/components/theme/defaultStrings.d.ts.map +1 -1
  225. package/lib/typescript/commonjs/src/components/theme/direction.d.ts +8 -0
  226. package/lib/typescript/commonjs/src/components/theme/direction.d.ts.map +1 -0
  227. package/lib/typescript/commonjs/src/components/theme/numerals.d.ts +7 -0
  228. package/lib/typescript/commonjs/src/components/theme/numerals.d.ts.map +1 -0
  229. package/lib/typescript/commonjs/src/components/theme/styleKeys.d.ts +1 -1
  230. package/lib/typescript/commonjs/src/components/theme/styleKeys.d.ts.map +1 -1
  231. package/lib/typescript/commonjs/src/components/theme/tokens.d.ts +3 -1
  232. package/lib/typescript/commonjs/src/components/theme/tokens.d.ts.map +1 -1
  233. package/lib/typescript/commonjs/src/components/time/TimeRow.d.ts.map +1 -1
  234. package/lib/typescript/commonjs/src/components/time/TypedTime.d.ts.map +1 -1
  235. package/lib/typescript/commonjs/src/components/time/Wheel.d.ts +5 -0
  236. package/lib/typescript/commonjs/src/components/time/Wheel.d.ts.map +1 -1
  237. package/lib/typescript/commonjs/src/components/time/timeStyles.d.ts +0 -2
  238. package/lib/typescript/commonjs/src/components/time/timeStyles.d.ts.map +1 -1
  239. package/lib/typescript/commonjs/src/components/types.d.ts +84 -4
  240. package/lib/typescript/commonjs/src/components/types.d.ts.map +1 -1
  241. package/lib/typescript/commonjs/src/core/calendarSystem.d.ts +20 -5
  242. package/lib/typescript/commonjs/src/core/calendarSystem.d.ts.map +1 -1
  243. package/lib/typescript/commonjs/src/core/digits.d.ts +3 -0
  244. package/lib/typescript/commonjs/src/core/digits.d.ts.map +1 -0
  245. package/lib/typescript/commonjs/src/core/draft.d.ts +12 -1
  246. package/lib/typescript/commonjs/src/core/draft.d.ts.map +1 -1
  247. package/lib/typescript/commonjs/src/core/locale.d.ts +6 -0
  248. package/lib/typescript/commonjs/src/core/locale.d.ts.map +1 -1
  249. package/lib/typescript/commonjs/src/core/numerals.d.ts +15 -0
  250. package/lib/typescript/commonjs/src/core/numerals.d.ts.map +1 -0
  251. package/lib/typescript/commonjs/src/core/segmentEditor.d.ts.map +1 -1
  252. package/lib/typescript/commonjs/src/core/segments.d.ts +0 -2
  253. package/lib/typescript/commonjs/src/core/segments.d.ts.map +1 -1
  254. package/lib/typescript/commonjs/src/core/selectionRules.d.ts +3 -2
  255. package/lib/typescript/commonjs/src/core/selectionRules.d.ts.map +1 -1
  256. package/lib/typescript/commonjs/src/core/timeEntry.d.ts +4 -24
  257. package/lib/typescript/commonjs/src/core/timeEntry.d.ts.map +1 -1
  258. package/lib/typescript/commonjs/src/icons/index.d.ts.map +1 -1
  259. package/lib/typescript/commonjs/src/index.d.ts +7 -3
  260. package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
  261. package/lib/typescript/module/src/adapters/utcMidnight.d.ts.map +1 -1
  262. package/lib/typescript/module/src/components/DateTimePicker.d.ts.map +1 -1
  263. package/lib/typescript/module/src/components/calendar/Calendar.d.ts +8 -4
  264. package/lib/typescript/module/src/components/calendar/Calendar.d.ts.map +1 -1
  265. package/lib/typescript/module/src/components/calendar/CalendarHeader.d.ts.map +1 -1
  266. package/lib/typescript/module/src/components/calendar/CalendarSwitch.d.ts +26 -0
  267. package/lib/typescript/module/src/components/calendar/CalendarSwitch.d.ts.map +1 -0
  268. package/lib/typescript/module/src/components/calendar/DayCell.d.ts +1 -1
  269. package/lib/typescript/module/src/components/calendar/DayCell.d.ts.map +1 -1
  270. package/lib/typescript/module/src/components/calendar/DayGrid.d.ts +2 -0
  271. package/lib/typescript/module/src/components/calendar/DayGrid.d.ts.map +1 -1
  272. package/lib/typescript/module/src/components/calendar/PeriodGrid.d.ts.map +1 -1
  273. package/lib/typescript/module/src/components/calendar/calendarStyles.d.ts +1 -1
  274. package/lib/typescript/module/src/components/calendar/calendarStyles.d.ts.map +1 -1
  275. package/lib/typescript/module/src/components/calendar/localeNames.d.ts +8 -3
  276. package/lib/typescript/module/src/components/calendar/localeNames.d.ts.map +1 -1
  277. package/lib/typescript/module/src/components/calendar/selection.d.ts +2 -0
  278. package/lib/typescript/module/src/components/calendar/selection.d.ts.map +1 -1
  279. package/lib/typescript/module/src/components/container/DefaultSheet.d.ts +10 -2
  280. package/lib/typescript/module/src/components/container/DefaultSheet.d.ts.map +1 -1
  281. package/lib/typescript/module/src/components/container/PickerContainer.d.ts.map +1 -1
  282. package/lib/typescript/module/src/components/container/containerStyles.d.ts +6 -0
  283. package/lib/typescript/module/src/components/container/containerStyles.d.ts.map +1 -1
  284. package/lib/typescript/module/src/components/field/RangeFields.d.ts +5 -0
  285. package/lib/typescript/module/src/components/field/RangeFields.d.ts.map +1 -1
  286. package/lib/typescript/module/src/components/field/SegmentedInput.d.ts.map +1 -1
  287. package/lib/typescript/module/src/components/field/ValueField.d.ts +7 -0
  288. package/lib/typescript/module/src/components/field/ValueField.d.ts.map +1 -1
  289. package/lib/typescript/module/src/components/field/fieldStyles.d.ts +15 -0
  290. package/lib/typescript/module/src/components/field/fieldStyles.d.ts.map +1 -1
  291. package/lib/typescript/module/src/components/field/fieldText.d.ts +14 -5
  292. package/lib/typescript/module/src/components/field/fieldText.d.ts.map +1 -1
  293. package/lib/typescript/module/src/components/hooks/useBottomInset.d.ts +8 -0
  294. package/lib/typescript/module/src/components/hooks/useBottomInset.d.ts.map +1 -0
  295. package/lib/typescript/module/src/components/hooks/useKeyboardFold.d.ts +10 -2
  296. package/lib/typescript/module/src/components/hooks/useKeyboardFold.d.ts.map +1 -1
  297. package/lib/typescript/module/src/components/hooks/useOpenPicker.d.ts +2 -1
  298. package/lib/typescript/module/src/components/hooks/useOpenPicker.d.ts.map +1 -1
  299. package/lib/typescript/module/src/components/hooks/useTypedSegments.d.ts +3 -2
  300. package/lib/typescript/module/src/components/hooks/useTypedSegments.d.ts.map +1 -1
  301. package/lib/typescript/module/src/components/theme/defaultStrings.d.ts +13 -2
  302. package/lib/typescript/module/src/components/theme/defaultStrings.d.ts.map +1 -1
  303. package/lib/typescript/module/src/components/theme/direction.d.ts +8 -0
  304. package/lib/typescript/module/src/components/theme/direction.d.ts.map +1 -0
  305. package/lib/typescript/module/src/components/theme/numerals.d.ts +7 -0
  306. package/lib/typescript/module/src/components/theme/numerals.d.ts.map +1 -0
  307. package/lib/typescript/module/src/components/theme/styleKeys.d.ts +1 -1
  308. package/lib/typescript/module/src/components/theme/styleKeys.d.ts.map +1 -1
  309. package/lib/typescript/module/src/components/theme/tokens.d.ts +3 -1
  310. package/lib/typescript/module/src/components/theme/tokens.d.ts.map +1 -1
  311. package/lib/typescript/module/src/components/time/TimeRow.d.ts.map +1 -1
  312. package/lib/typescript/module/src/components/time/TypedTime.d.ts.map +1 -1
  313. package/lib/typescript/module/src/components/time/Wheel.d.ts +5 -0
  314. package/lib/typescript/module/src/components/time/Wheel.d.ts.map +1 -1
  315. package/lib/typescript/module/src/components/time/timeStyles.d.ts +0 -2
  316. package/lib/typescript/module/src/components/time/timeStyles.d.ts.map +1 -1
  317. package/lib/typescript/module/src/components/types.d.ts +84 -4
  318. package/lib/typescript/module/src/components/types.d.ts.map +1 -1
  319. package/lib/typescript/module/src/core/calendarSystem.d.ts +20 -5
  320. package/lib/typescript/module/src/core/calendarSystem.d.ts.map +1 -1
  321. package/lib/typescript/module/src/core/digits.d.ts +3 -0
  322. package/lib/typescript/module/src/core/digits.d.ts.map +1 -0
  323. package/lib/typescript/module/src/core/draft.d.ts +12 -1
  324. package/lib/typescript/module/src/core/draft.d.ts.map +1 -1
  325. package/lib/typescript/module/src/core/locale.d.ts +6 -0
  326. package/lib/typescript/module/src/core/locale.d.ts.map +1 -1
  327. package/lib/typescript/module/src/core/numerals.d.ts +15 -0
  328. package/lib/typescript/module/src/core/numerals.d.ts.map +1 -0
  329. package/lib/typescript/module/src/core/segmentEditor.d.ts.map +1 -1
  330. package/lib/typescript/module/src/core/segments.d.ts +0 -2
  331. package/lib/typescript/module/src/core/segments.d.ts.map +1 -1
  332. package/lib/typescript/module/src/core/selectionRules.d.ts +3 -2
  333. package/lib/typescript/module/src/core/selectionRules.d.ts.map +1 -1
  334. package/lib/typescript/module/src/core/timeEntry.d.ts +4 -24
  335. package/lib/typescript/module/src/core/timeEntry.d.ts.map +1 -1
  336. package/lib/typescript/module/src/icons/index.d.ts.map +1 -1
  337. package/lib/typescript/module/src/index.d.ts +7 -3
  338. package/lib/typescript/module/src/index.d.ts.map +1 -1
  339. package/package.json +22 -7
  340. package/src/adapters/utcMidnight.ts +14 -5
  341. package/src/components/DateTimePicker.tsx +607 -108
  342. package/src/components/calendar/Calendar.tsx +54 -16
  343. package/src/components/calendar/CalendarHeader.tsx +41 -9
  344. package/src/components/calendar/CalendarSwitch.tsx +170 -0
  345. package/src/components/calendar/DayCell.tsx +16 -4
  346. package/src/components/calendar/DayGrid.tsx +18 -3
  347. package/src/components/calendar/PeriodGrid.tsx +3 -1
  348. package/src/components/calendar/calendarStyles.ts +3 -2
  349. package/src/components/calendar/localeNames.ts +52 -22
  350. package/src/components/calendar/selection.ts +8 -0
  351. package/src/components/container/DefaultSheet.tsx +60 -14
  352. package/src/components/container/PickerContainer.tsx +4 -0
  353. package/src/components/container/PickerLayout.tsx +1 -1
  354. package/src/components/container/containerStyles.ts +12 -3
  355. package/src/components/field/RangeFields.tsx +12 -2
  356. package/src/components/field/SegmentedInput.tsx +8 -3
  357. package/src/components/field/ValueField.tsx +94 -18
  358. package/src/components/field/fieldStyles.ts +6 -0
  359. package/src/components/field/fieldText.ts +68 -15
  360. package/src/components/hooks/useBottomInset.ts +33 -0
  361. package/src/components/hooks/useKeyboardFold.ts +41 -13
  362. package/src/components/hooks/useOpenPicker.ts +41 -18
  363. package/src/components/hooks/useTypedSegments.ts +7 -3
  364. package/src/components/theme/defaultStrings.ts +29 -4
  365. package/src/components/theme/direction.ts +12 -0
  366. package/src/components/theme/numerals.ts +11 -0
  367. package/src/components/theme/styleKeys.ts +18 -1
  368. package/src/components/theme/tokens.ts +5 -1
  369. package/src/components/time/TimeRow.tsx +23 -3
  370. package/src/components/time/TypedTime.tsx +3 -1
  371. package/src/components/time/Wheel.tsx +19 -5
  372. package/src/components/time/timeStyles.ts +2 -3
  373. package/src/components/types.ts +86 -4
  374. package/src/core/calendarSystem.ts +145 -21
  375. package/src/core/digits.ts +21 -0
  376. package/src/core/draft.ts +41 -13
  377. package/src/core/locale.ts +20 -3
  378. package/src/core/numerals.ts +35 -0
  379. package/src/core/segmentEditor.ts +13 -0
  380. package/src/core/segments.ts +0 -8
  381. package/src/core/selectionRules.ts +3 -2
  382. package/src/core/timeEntry.ts +6 -96
  383. package/src/icons/index.tsx +3 -1
  384. package/src/index.tsx +12 -2
@@ -1 +1 @@
1
- {"version":3,"file":"segments.d.ts","sourceRoot":"","sources":["../../../../../src/core/segments.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,YAAY,EACZ,aAAa,EACb,UAAU,EAEV,UAAU,EACX,MAAM,YAAS,CAAC;AAEjB;;;;GAIG;AAEH,MAAM,MAAM,UAAU,GACpB,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAC1D,MAAM,MAAM,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;AAEjC,MAAM,WAAW,WAAW;IAC1B,GAAG,EAAE,UAAU,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,WAAW,EAAE,CAAC;IACxB,sFAAsF;IACtF,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,MAAM,aAAa,GAAG,OAAO,CAAC,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC;AAEhE,MAAM,MAAM,gBAAgB,GAC1B,UAAU,GAAG,cAAc,GAAG,cAAc,GAAG,YAAY,CAAC;AAE9D,MAAM,WAAW,YAAY;IAC3B,GAAG,EAAE,UAAU,GAAG,MAAM,CAAC;IACzB,IAAI,EAAE,gBAAgB,CAAC;CACxB;AAED,MAAM,WAAW,cAAc;IAC7B,KAAK,EAA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AAM,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAKvE,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,QAAQ,MAAM,EAAE,QAAQ,MAAM,KAAG,MAChB,CAAC;AAK7C,8CAA8C;AAC9C,eAAO,MAAM,cAAc,GACzB,OAAO,aAAa,GAAG,IAAI,EAC3B,MAAM,UAAU,EAChB,YAAY,UAAU,KACrB,aAkBF,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,UAAU,GACrB,SAAS,MAAM,EACf,OAAO,MAAM,EACb,MAAM,WAAW,KAChB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,OAAO,CAAA;CAQlC,CAAC;AAEF,8FAA8F;AAC9F,eAAO,MAAM,UAAU,GAAI,MAAM,MAAM,EAAE,MAAM,WAAW,KAAG,MAS5D,CAAC;AAKF;;;;GAIG;AACH,eAAO,MAAM,aAAa,GACxB,QAAQ,aAAa,EACrB,SAAS;IACP,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC;CAC7C,KACA,cAsEF,CAAC"}
@@ -5,7 +5,8 @@ import type { CalendarDate } from './types.js';
5
5
  * - range: once a start is picked and the end is being chosen, days closer than
6
6
  * `minDays` or further than `maxDays` are greyed (lengths count calendar
7
7
  * days with both ends included, so a same-day range is 1 day); in the From/To layout, days
8
- * before the start are greyed too (in the single field a tap there restarts);
8
+ * before the start are greyed too once the To field is tapped (otherwise a tap
9
+ * there moves the start);
9
10
  * - multiple: once `maxSelections` is reached, only selected days can be tapped.
10
11
  * Validation on Confirm (validateDraft) still checks the same rules.
11
12
  */
@@ -14,7 +15,7 @@ export interface SelectionRules {
14
15
  rangeStart?: CalendarDate | null;
15
16
  minDays?: number;
16
17
  maxDays?: number;
17
- /** From/To layout editing the end: days before the start can't be the end. */
18
+ /** From/To layout, the To field tapped: days before the start can't be the end. */
18
19
  blockBeforeStart?: boolean;
19
20
  /** Multiple mode with the cap reached. */
20
21
  maxReached?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"selectionRules.d.ts","sourceRoot":"","sources":["../../../../../src/core/selectionRules.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAa,MAAM,kBAAe,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAS,CAAC;AAE5C;;;;;;;;GAQG;AACH,MAAM,WAAW,cAAc;IAC7B,gDAAgD;IAChD,UAAU,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;IACjC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,8EAA8E;IAC9E,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,0CAA0C;IAC1C,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE,YAAY,KAAK,OAAO,CAAC;CAC7C;AAED,eAAO,MAAM,iBAAiB,GAC5B,OAAO,YAAY,EACnB,KAAK,YAAY,EACjB,OAAO,IAAI,CAAC,cAAc,EAAE,SAAS,GAAG,SAAS,GAAG,kBAAkB,CAAC,KACtE,OAOF,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAC7B,MAAM,WAAW,EACjB,OAAO,cAAc,KACpB,WA8BF,CAAC"}
1
+ {"version":3,"file":"selectionRules.d.ts","sourceRoot":"","sources":["../../../../../src/core/selectionRules.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAa,MAAM,kBAAe,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAS,CAAC;AAE5C;;;;;;;;;GASG;AACH,MAAM,WAAW,cAAc;IAC7B,gDAAgD;IAChD,UAAU,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;IACjC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,mFAAmF;IACnF,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,0CAA0C;IAC1C,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE,YAAY,KAAK,OAAO,CAAC;CAC7C;AAED,eAAO,MAAM,iBAAiB,GAC5B,OAAO,YAAY,EACnB,KAAK,YAAY,EACjB,OAAO,IAAI,CAAC,cAAc,EAAE,SAAS,GAAG,SAAS,GAAG,kBAAkB,CAAC,KACtE,OAOF,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAC7B,MAAM,WAAW,EACjB,OAAO,cAAc,KACpB,WA8BF,CAAC"}
@@ -12,27 +12,6 @@ export interface TimeEntryValues {
12
12
  minute?: string;
13
13
  period?: Period;
14
14
  }
15
- export interface TimeEntryState {
16
- values: TimeEntryValues;
17
- focused: TimeKey | null;
18
- }
19
- export type TimeEntryAction = {
20
- type: 'focus';
21
- key: TimeKey;
22
- } | {
23
- type: 'digit';
24
- digit: string;
25
- } | {
26
- type: 'backspace';
27
- } | {
28
- type: 'period';
29
- period: Period;
30
- } | {
31
- type: 'blur';
32
- } | {
33
- type: 'reset';
34
- time: Time | null;
35
- };
36
15
  export type TimeEntryIssue = 'INCOMPLETE' | 'INVALID' | 'OFF_STEP' | 'BEFORE_MIN' | 'AFTER_MAX';
37
16
  export interface ParsedTime {
38
17
  time: Time | null;
@@ -44,8 +23,6 @@ export interface ParsedTime {
44
23
  export declare const timeSpecs: (timeFormat: TimeFormat) => Record<TimeKey, SegmentSpec>;
45
24
  /** Time → what the boxes show. An empty 12-hour row starts on AM (12:00 AM is the fallback time). */
46
25
  export declare const formatTimeEntry: (time: Time | null, timeFormat: TimeFormat) => TimeEntryValues;
47
- export declare const createTimeEntry: (time: Time | null, timeFormat: TimeFormat) => TimeEntryState;
48
- export declare const timeEntryReducer: (state: TimeEntryState, action: TimeEntryAction, timeFormat: TimeFormat) => TimeEntryState;
49
26
  export declare const parseTimeEntry: (values: TimeEntryValues, timeFormat: TimeFormat) => ParsedTime;
50
27
  /**
51
28
  * Why a complete time can't be confirmed: off the minute step (never rounded
@@ -57,7 +34,10 @@ export declare const checkTime: (time: Time, options: {
57
34
  }) => TimeEntryIssue | null;
58
35
  /** Whether any time in that half of the day (AM 00:00–11:59, PM 12:00–23:59) fits the limits. */
59
36
  export declare const isPeriodAllowed: (period: Period, bounds?: TimeBounds | null) => boolean;
60
- /** Digits only, at most two (what a time box accepts while typing). */
37
+ /**
38
+ * Digits only, at most two (what a time box accepts while typing). Digits
39
+ * typed in another script count too ('٠٩' → '09').
40
+ */
61
41
  export declare const cleanBoxText: (raw: string) => string;
62
42
  /**
63
43
  * The boxes as they are saved when focus leaves them: a one-digit entry gets a
@@ -1 +1 @@
1
- {"version":3,"file":"timeEntry.d.ts","sourceRoot":"","sources":["../../../../../src/core/timeEntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAe,CAAC;AAChD,OAAO,EAKL,KAAK,MAAM,EACX,KAAK,WAAW,EACjB,MAAM,eAAY,CAAC;AACpB,OAAO,KAAK,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,YAAS,CAAC;AAEhD;;;;GAIG;AAEH,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG,QAAQ,CAAC;AAExC,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,cAAc;IAC7B,MAAM,EAAE,eAAe,CAAC;IACxB,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;CACzB;AAED,MAAM,MAAM,eAAe,GACvB;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,GAAG,EAAE,OAAO,CAAA;CAAE,GAC/B;IAAE,I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,IAAI,EAC1B,MAAM;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EACzD,UAAU,WAAW,KACpB,KAAK,CAAC,SAcR,CAAC"}
@@ -8,13 +8,17 @@ export { DEFAULT_TOKENS, INTER_FONTS, SYSTEM_FONTS, } from './components/theme/t
8
8
  export { DEFAULT_YEAR_RANGE } from './components/types.js';
9
9
  export { CalendarIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ClearIcon, } from './icons/index.js';
10
10
  export { addDays, compareCalendarDates, daysBetween, daysInMonth, fromDateKey, isSameDay, toDateKey, todayIn, weekdayOf, } from './core/calendarDate.js';
11
+ export { hijriDateText, hijriPeriods } from './core/calendarSystem.js';
12
+ export { arabicDigits } from './core/numerals.js';
11
13
  export type { AdapterContext, CalendarDate, DateTimeValue, PickerType, PickerValue, RangeValue, SelectionMode, Time, TimeFormat, ValueAdapter, ValueFormat, Weekday, } from './core/types.js';
12
14
  export type { Constraints, CreateConstraintsOptions, DayStatus, DisabledReason, RangeBound, TimeBounds, } from './core/constraints.js';
13
- export type { ConstraintContext, DateTimePickerProps, InstructionRenderProps, LabelRenderProps, PickerErrorCode, PickerState, SheetOptions, SheetRenderProps, SheetSize, Slot, } from './components/types.js';
15
+ export type { CalendarSwitchRenderProps, ChangeInfo, ConstraintContext, DateTimePickerProps, InstructionRenderProps, LabelRenderProps, PickerErrorCode, PickerState, SheetOptions, SheetRenderProps, SheetSize, Slot, } from './components/types.js';
16
+ export type { CalendarSystem, Periods } from './core/calendarSystem.js';
17
+ export type { Numerals } from './core/numerals.js';
14
18
  export type { PickerStrings } from './components/theme/defaultStrings.js';
15
- export type { PickerStyles } from './components/theme/styleKeys.js';
19
+ export type { PickerStyles, PickerStyleValue, StyleKey, } from './components/theme/styleKeys.js';
16
20
  export type { ThemeTokens } from './components/theme/tokens.js';
17
- export type { DayCellState } from './components/calendar/DayCell.js';
21
+ export type { DayCellState, RangeRole } from './components/calendar/DayCell.js';
18
22
  export type { PeriodItem } from './components/calendar/PeriodGrid.js';
19
23
  export type { IconComponent, IconName, IconOptions, IconRenderProps, IconSet, } from './icons/index.js';
20
24
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,MAAM,gCAA6B,CAAC;AAEzD,eAAe,cAAc,CAAC;AAC9B,OAAO,EAAE,cAAc,EAAE,CAAC;AAG1B,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAoB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,qBAAY,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAmC,CAAC;AACpE,OAAO,EACL,cAAc,EACd,WAAW,EACX,YAAY,GACb,MAAM,8BAA2B,CAAC;AACnC,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAoB,CAAC;AACxD,OAAO,EACL,YAAY,EACZ,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,SAAS,GACV,MAAM,kBAAS,CAAC;AACjB,OAAO,EACL,OAAO,EACP,oBAAoB,EACpB,WAAW,EACX,WAAW,EACX,WAAW,EACX,SAAS,EACT,SAAS,EACT,OAAO,EACP,SAAS,GACV,MAAM,wBAAqB,CAAC;AAG7B,YAAY,EACV,cAAc,EACd,YAAY,EACZ,aAAa,EACb,UAAU,EACV,WAAW,EACX,UAAU,EACV,aAAa,EACb,IAAI,EACJ,UAAU,EACV,YAAY,EACZ,WAAW,EACX,OAAO,GACR,MAAM,iBAAc,CAAC;AACtB,YAAY,EACV,WAAW,EACX,wBAAwB,EACxB,SAAS,EACT,cAAc,EACd,UAAU,EACV,UAAU,GACX,MAAM,uBAAoB,CAAC;AAC5B,YAAY,EACV,iBAAiB,EACjB,mBAAmB,EACnB,sBAAsB,EACtB,gBAAgB,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AE,MAAM,oBAAiB,CAAC;AAG/C,YAAY,EACV,cAAc,EACd,YAAY,EACZ,aAAa,EACb,UAAU,EACV,WAAW,EACX,UAAU,EACV,aAAa,EACb,IAAI,EACJ,UAAU,EACV,YAAY,EACZ,WAAW,EACX,OAAO,GACR,MAAM,iBAAc,CAAC;AACtB,YAAY,EACV,WAAW,EACX,wBAAwB,EACxB,SAAS,EACT,cAAc,EACd,UAAU,EACV,UAAU,GACX,MAAM,uBAAoB,CAAC;AAC5B,YAAY,EACV,yBAAyB,EACzB,UAAU,EACV,iBAAiB,EACjB,mBAAmB,EACnB,sBAAsB,EACtB,gBAAgB,EAChB,eAAe,EACf,WAAW,EACX,YAAY,EACZ,gBAAgB,EAChB,SAAS,EACT,IAAI,GACL,MAAM,uBAAoB,CAAC;AAC5B,YAAY,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,0BAAuB,CAAC;AACrE,YAAY,EAAE,QAAQ,EAAE,MAAM,oBAAiB,CAAC;AAChD,YAAY,EAAE,aAAa,EAAE,MAAM,sCAAmC,CAAC;AACvE,YAAY,EACV,YAAY,EACZ,gBAAgB,EAChB,QAAQ,GACT,MAAM,iCAA8B,CAAC;AACtC,YAAY,EAAE,WAAW,EAAE,MAAM,8BAA2B,CAAC;AAC7D,YAAY,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,kCAA+B,CAAC;AAC7E,YAAY,EAAE,UAAU,EAAE,MAAM,qCAAkC,CAAC;AACnE,YAAY,EACV,aAAa,EACb,QAAQ,EACR,WAAW,EACX,eAAe,EACf,OAAO,GACR,MAAM,kBAAS,CAAC"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "rn-grid-date-time-picker",
3
- "version": "1.0.0",
4
- "description": "A flexible, themeable date & time picker for React Native: single, multiple and range selection, typed or wheel time entry, limits and holidays, Hijri support. Runs on iOS and Android; pure JS, so it also works in Expo Go and bare React Native apps.",
3
+ "version": "1.2.0",
4
+ "description": "React Native date, time and date range picker with a Hijri (Islamic, Umm al-Qura) calendar, Arabic digits and RTL. Bottom sheet or inline, fully themeable, TypeScript. Runs on iOS, Android and Expo Go.",
5
5
  "main": "./lib/commonjs/index.js",
6
6
  "module": "./lib/module/index.js",
7
7
  "types": "./lib/typescript/commonjs/src/index.d.ts",
@@ -40,19 +40,27 @@
40
40
  "keywords": [
41
41
  "react-native",
42
42
  "expo",
43
+ "react-native-date-picker",
44
+ "react-native-datepicker",
45
+ "react-native-calendar",
46
+ "react-native-time-picker",
47
+ "react-native-datetime-picker",
48
+ "react-native-date-range-picker",
43
49
  "date-picker",
44
50
  "datepicker",
45
51
  "time-picker",
46
- "timepicker",
47
52
  "datetime-picker",
48
53
  "date-range-picker",
49
- "range-picker",
54
+ "daterange",
50
55
  "calendar",
51
- "calendar-picker",
52
56
  "multiple-dates",
57
+ "bottom-sheet",
53
58
  "hijri",
59
+ "hijri-calendar",
60
+ "islamic-calendar",
61
+ "umm-al-qura",
62
+ "arabic",
54
63
  "rtl",
55
- "accessibility",
56
64
  "typescript",
57
65
  "ios",
58
66
  "android"
@@ -91,6 +99,7 @@
91
99
  "react": "19.3.0",
92
100
  "react-native": "0.88.0",
93
101
  "react-native-builder-bob": "^0.44.1",
102
+ "react-native-safe-area-context": "~5.10.1",
94
103
  "react-test-renderer": "19.3.0",
95
104
  "turbo": "^2.11.10",
96
105
  "typescript": "^6.0.3"
@@ -100,7 +109,13 @@
100
109
  },
101
110
  "peerDependencies": {
102
111
  "react": ">=18",
103
- "react-native": ">=0.71"
112
+ "react-native": ">=0.71",
113
+ "react-native-safe-area-context": ">=3"
114
+ },
115
+ "peerDependenciesMeta": {
116
+ "react-native-safe-area-context": {
117
+ "optional": true
118
+ }
104
119
  },
105
120
  "workspaces": [
106
121
  "example"
@@ -29,6 +29,12 @@ const isValidTime = (t: Time | null | undefined): t is Time =>
29
29
  export const isWritableYear = (year: number): boolean =>
30
30
  year >= 1 && year <= 9999;
31
31
 
32
+ /**
33
+ * A stored value must start with a full day: Luxon also reads '10:30' (today),
34
+ * '2026' or week and ordinal dates, which aren't dates the picker saved.
35
+ */
36
+ const STARTS_WITH_DAY = /^\d{4}-\d{2}-\d{2}(?:T|$)/;
37
+
32
38
  /**
33
39
  * A stored instant → its day and wall-clock time in `zone`, or null when it
34
40
  * can't be parsed. Shared by every built-in format for date-time values.
@@ -37,11 +43,11 @@ export const parseInstant = (
37
43
  value: string | null | undefined,
38
44
  zone: string
39
45
  ): DateTimeValue | null => {
40
- if (!value) return null;
46
+ if (!value || !STARTS_WITH_DAY.test(value)) return null;
41
47
  const utc = DateTime.fromISO(value, { zone: 'utc' });
42
48
  if (!utc.isValid) return null;
43
49
  const local = utc.setZone(zone);
44
- if (!local.isValid) return null;
50
+ if (!local.isValid || !isWritableYear(local.year)) return null;
45
51
  return {
46
52
  date: calendarDateOf(local),
47
53
  time: { hour: local.hour, minute: local.minute },
@@ -58,8 +64,9 @@ export const formatInstant = (
58
64
  ): string => {
59
65
  if (!value || !isValidCalendarDate(value.date)) return '';
60
66
  if (!isValidTime(value.time)) return '';
61
- const zoned = toZonedDateTime(value, zone);
62
- return zoned.isValid ? (zoned.toUTC().toISO() ?? '') : '';
67
+ const utc = toZonedDateTime(value, zone).toUTC();
68
+ // A day near year 1 or 9999 can fall in year 0 or 10000 in UTC.
69
+ return utc.isValid && isWritableYear(utc.year) ? (utc.toISO() ?? '') : '';
63
70
  };
64
71
 
65
72
  /** Saved string → picker value. Returns null for '' or an unparsable string. */
@@ -70,10 +77,11 @@ const fromWire = (
70
77
  ): DateTimeValue | null => {
71
78
  if (!value) return null;
72
79
  if (type !== 'date') return parseInstant(value, zone);
80
+ if (!STARTS_WITH_DAY.test(value)) return null;
73
81
  // The calendar day as written: an offset in the string ('+05:30') is kept,
74
82
  // not converted to UTC, so the day never moves.
75
83
  const written = DateTime.fromISO(value, { setZone: true });
76
- if (!written.isValid) return null;
84
+ if (!written.isValid || !isWritableYear(written.year)) return null;
77
85
  return { date: calendarDateOf(written), time: null };
78
86
  };
79
87
 
@@ -109,6 +117,7 @@ const unchangedWire = (
109
117
  ): string => {
110
118
  if (!value) return '';
111
119
  if (type === 'datetime') {
120
+ if (!STARTS_WITH_DAY.test(value)) return '';
112
121
  const dt = DateTime.fromISO(value, { zone: 'utc' });
113
122
  return dt.isValid ? (dt.toUTC().toISO() ?? '') : '';
114
123
  }