@mui/x-date-pickers 7.0.0-alpha.8 → 7.0.0-beta.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 (453) hide show
  1. package/AdapterLuxon/AdapterLuxon.d.ts +1 -1
  2. package/AdapterLuxon/AdapterLuxon.js +4 -12
  3. package/CHANGELOG.md +508 -30
  4. package/DatePicker/DatePicker.js +0 -3
  5. package/DatePicker/DatePickerToolbar.js +0 -3
  6. package/DateTimePicker/DateTimePicker.js +0 -3
  7. package/DateTimePicker/DateTimePickerTabs.js +7 -4
  8. package/DateTimePicker/DateTimePickerToolbar.d.ts +6 -1
  9. package/DateTimePicker/DateTimePickerToolbar.js +33 -20
  10. package/DesktopDatePicker/DesktopDatePicker.js +0 -3
  11. package/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
  12. package/DesktopTimePicker/DesktopTimePicker.js +0 -3
  13. package/MobileDatePicker/MobileDatePicker.js +0 -3
  14. package/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
  15. package/MobileTimePicker/MobileTimePicker.js +0 -3
  16. package/MonthCalendar/MonthCalendar.js +0 -3
  17. package/MonthCalendar/MonthCalendar.types.d.ts +0 -3
  18. package/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
  19. package/PickersCalendarHeader/PickersCalendarHeader.types.d.ts +0 -3
  20. package/PickersLayout/PickersLayout.types.d.ts +6 -5
  21. package/PickersLayout/pickersLayoutClasses.js +3 -2
  22. package/PickersLayout/usePickerLayout.d.ts +2 -2
  23. package/PickersLayout/usePickerLayout.js +2 -1
  24. package/PickersSectionList/PickersSectionList.js +6 -1
  25. package/PickersTextField/PickersFilledInput/PickersFilledInput.d.ts +11 -0
  26. package/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +98 -25
  27. package/PickersTextField/PickersFilledInput/index.d.ts +4 -0
  28. package/PickersTextField/PickersFilledInput/index.js +2 -0
  29. package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.d.ts +23 -0
  30. package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
  31. package/PickersTextField/PickersInput/PickersInput.d.ts +10 -0
  32. package/PickersTextField/PickersInput/PickersInput.js +196 -0
  33. package/{internals/components → PickersTextField}/PickersInput/index.d.ts +2 -2
  34. package/PickersTextField/PickersInput/index.js +2 -0
  35. package/PickersTextField/PickersInput/pickersInputClasses.d.ts +22 -0
  36. package/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
  37. package/PickersTextField/PickersInputBase/PickersInputBase.d.ts +16 -0
  38. package/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
  39. package/{internals/components/PickersInput/PickersInput.types.d.ts → PickersTextField/PickersInputBase/PickersInputBase.types.d.ts} +3 -13
  40. package/PickersTextField/PickersInputBase/index.d.ts +4 -0
  41. package/PickersTextField/PickersInputBase/index.js +2 -0
  42. package/PickersTextField/PickersInputBase/pickersInputBaseClasses.d.ts +31 -0
  43. package/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
  44. package/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.d.ts +3 -0
  45. package/{modern/internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
  46. package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.d.ts +10 -0
  47. package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +190 -0
  48. package/PickersTextField/PickersOutlinedInput/index.d.ts +4 -0
  49. package/PickersTextField/PickersOutlinedInput/index.js +2 -0
  50. package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.d.ts +22 -0
  51. package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
  52. package/PickersTextField/PickersTextField.d.ts +3 -0
  53. package/PickersTextField/PickersTextField.js +258 -0
  54. package/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.d.ts +5 -2
  55. package/PickersTextField/index.d.ts +8 -0
  56. package/PickersTextField/index.js +6 -0
  57. package/PickersTextField/package.json +6 -0
  58. package/README.md +3 -3
  59. package/StaticDatePicker/StaticDatePicker.js +0 -3
  60. package/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
  61. package/StaticTimePicker/StaticTimePicker.js +0 -3
  62. package/TimeClock/TimeClock.js +3 -3
  63. package/TimePicker/TimePicker.js +0 -3
  64. package/TimePicker/TimePickerToolbar.js +0 -3
  65. package/YearCalendar/YearCalendar.js +0 -3
  66. package/YearCalendar/YearCalendar.types.d.ts +0 -3
  67. package/dateTimeViewRenderers/dateTimeViewRenderers.js +4 -4
  68. package/index.d.ts +2 -1
  69. package/index.js +3 -2
  70. package/internals/hooks/useField/useField.js +6 -4
  71. package/internals/hooks/useField/useField.types.d.ts +4 -2
  72. package/internals/hooks/useField/useField.utils.d.ts +19 -9
  73. package/internals/hooks/useField/useField.utils.js +68 -21
  74. package/internals/hooks/useField/useFieldCharacterEditing.d.ts +2 -1
  75. package/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
  76. package/internals/hooks/useField/useFieldState.d.ts +1 -0
  77. package/internals/hooks/useField/useFieldState.js +9 -7
  78. package/internals/hooks/usePicker/usePicker.d.ts +1 -1
  79. package/internals/hooks/usePicker/usePicker.js +4 -2
  80. package/internals/hooks/usePicker/usePicker.types.d.ts +1 -1
  81. package/internals/hooks/usePicker/usePickerViews.d.ts +11 -2
  82. package/internals/hooks/usePicker/usePickerViews.js +8 -3
  83. package/internals/index.d.ts +4 -4
  84. package/internals/index.js +2 -2
  85. package/internals/models/props/basePickerProps.d.ts +0 -3
  86. package/internals/models/props/tabs.d.ts +2 -1
  87. package/internals/models/props/toolbar.d.ts +0 -3
  88. package/internals/utils/valueManagers.js +2 -2
  89. package/legacy/AdapterLuxon/AdapterLuxon.js +4 -12
  90. package/legacy/DatePicker/DatePicker.js +0 -3
  91. package/legacy/DatePicker/DatePickerToolbar.js +0 -3
  92. package/legacy/DateTimePicker/DateTimePicker.js +0 -3
  93. package/legacy/DateTimePicker/DateTimePickerTabs.js +7 -4
  94. package/legacy/DateTimePicker/DateTimePickerToolbar.js +43 -32
  95. package/legacy/DesktopDatePicker/DesktopDatePicker.js +0 -3
  96. package/legacy/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
  97. package/legacy/DesktopTimePicker/DesktopTimePicker.js +0 -3
  98. package/legacy/MobileDatePicker/MobileDatePicker.js +0 -3
  99. package/legacy/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
  100. package/legacy/MobileTimePicker/MobileTimePicker.js +0 -3
  101. package/legacy/MonthCalendar/MonthCalendar.js +0 -3
  102. package/legacy/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
  103. package/legacy/PickersLayout/pickersLayoutClasses.js +3 -2
  104. package/legacy/PickersLayout/usePickerLayout.js +2 -1
  105. package/legacy/PickersSectionList/PickersSectionList.js +6 -1
  106. package/legacy/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +99 -26
  107. package/legacy/PickersTextField/PickersFilledInput/index.js +2 -0
  108. package/legacy/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
  109. package/legacy/PickersTextField/PickersInput/PickersInput.js +190 -0
  110. package/legacy/PickersTextField/PickersInput/index.js +2 -0
  111. package/legacy/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
  112. package/legacy/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
  113. package/legacy/PickersTextField/PickersInputBase/index.js +2 -0
  114. package/legacy/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
  115. package/legacy/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +7 -1
  116. package/legacy/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +183 -0
  117. package/legacy/PickersTextField/PickersOutlinedInput/index.js +2 -0
  118. package/legacy/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
  119. package/legacy/{internals/components/PickersTextField → PickersTextField}/PickersTextField.js +128 -8
  120. package/legacy/PickersTextField/index.js +6 -0
  121. package/legacy/StaticDatePicker/StaticDatePicker.js +0 -3
  122. package/legacy/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
  123. package/legacy/StaticTimePicker/StaticTimePicker.js +0 -3
  124. package/legacy/TimeClock/TimeClock.js +3 -3
  125. package/legacy/TimePicker/TimePicker.js +0 -3
  126. package/legacy/TimePicker/TimePickerToolbar.js +0 -3
  127. package/legacy/YearCalendar/YearCalendar.js +0 -3
  128. package/legacy/dateTimeViewRenderers/dateTimeViewRenderers.js +5 -4
  129. package/legacy/index.js +3 -2
  130. package/legacy/internals/hooks/useField/useField.js +6 -4
  131. package/legacy/internals/hooks/useField/useField.utils.js +71 -20
  132. package/legacy/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
  133. package/legacy/internals/hooks/useField/useFieldState.js +15 -11
  134. package/legacy/internals/hooks/usePicker/usePicker.js +4 -2
  135. package/legacy/internals/hooks/usePicker/usePickerViews.js +8 -3
  136. package/legacy/internals/index.js +2 -2
  137. package/legacy/internals/utils/valueManagers.js +2 -2
  138. package/legacy/locales/beBY.js +8 -3
  139. package/legacy/locales/caES.js +7 -2
  140. package/legacy/locales/csCZ.js +8 -3
  141. package/legacy/locales/daDK.js +8 -3
  142. package/legacy/locales/deDE.js +6 -1
  143. package/legacy/locales/elGR.js +8 -3
  144. package/legacy/locales/enUS.js +7 -3
  145. package/legacy/locales/esES.js +8 -3
  146. package/legacy/locales/eu.js +6 -1
  147. package/legacy/locales/faIR.js +6 -1
  148. package/legacy/locales/fiFI.js +8 -3
  149. package/legacy/locales/frFR.js +6 -1
  150. package/legacy/locales/heIL.js +6 -1
  151. package/legacy/locales/huHU.js +6 -1
  152. package/legacy/locales/isIS.js +8 -3
  153. package/legacy/locales/itIT.js +8 -3
  154. package/legacy/locales/jaJP.js +6 -1
  155. package/legacy/locales/koKR.js +6 -1
  156. package/legacy/locales/kzKZ.js +6 -1
  157. package/legacy/locales/mk.js +6 -1
  158. package/legacy/locales/nbNO.js +8 -3
  159. package/legacy/locales/nlNL.js +8 -3
  160. package/legacy/locales/plPL.js +8 -3
  161. package/legacy/locales/ptBR.js +6 -1
  162. package/legacy/locales/roRO.js +6 -1
  163. package/legacy/locales/ruRU.js +8 -3
  164. package/legacy/locales/skSK.js +8 -3
  165. package/legacy/locales/svSE.js +8 -3
  166. package/legacy/locales/trTR.js +8 -3
  167. package/legacy/locales/ukUA.js +8 -3
  168. package/legacy/locales/urPK.js +6 -1
  169. package/legacy/locales/viVN.js +8 -3
  170. package/legacy/locales/zhCN.js +6 -1
  171. package/legacy/locales/zhHK.js +6 -1
  172. package/locales/beBY.d.ts +4 -0
  173. package/locales/beBY.js +8 -3
  174. package/locales/caES.d.ts +4 -0
  175. package/locales/caES.js +7 -2
  176. package/locales/csCZ.d.ts +4 -0
  177. package/locales/csCZ.js +8 -3
  178. package/locales/daDK.d.ts +4 -0
  179. package/locales/daDK.js +8 -3
  180. package/locales/deDE.d.ts +4 -0
  181. package/locales/deDE.js +6 -1
  182. package/locales/elGR.d.ts +4 -0
  183. package/locales/elGR.js +8 -3
  184. package/locales/enUS.d.ts +4 -0
  185. package/locales/enUS.js +7 -3
  186. package/locales/esES.d.ts +4 -0
  187. package/locales/esES.js +8 -3
  188. package/locales/eu.d.ts +4 -0
  189. package/locales/eu.js +6 -1
  190. package/locales/faIR.d.ts +4 -0
  191. package/locales/faIR.js +6 -1
  192. package/locales/fiFI.d.ts +4 -0
  193. package/locales/fiFI.js +8 -3
  194. package/locales/frFR.d.ts +4 -0
  195. package/locales/frFR.js +6 -1
  196. package/locales/heIL.d.ts +4 -0
  197. package/locales/heIL.js +6 -1
  198. package/locales/huHU.d.ts +4 -0
  199. package/locales/huHU.js +6 -1
  200. package/locales/isIS.d.ts +4 -0
  201. package/locales/isIS.js +8 -3
  202. package/locales/itIT.d.ts +4 -0
  203. package/locales/itIT.js +8 -3
  204. package/locales/jaJP.d.ts +4 -0
  205. package/locales/jaJP.js +6 -1
  206. package/locales/koKR.d.ts +4 -0
  207. package/locales/koKR.js +6 -1
  208. package/locales/kzKZ.d.ts +4 -0
  209. package/locales/kzKZ.js +6 -1
  210. package/locales/mk.d.ts +4 -0
  211. package/locales/mk.js +6 -1
  212. package/locales/nbNO.d.ts +4 -0
  213. package/locales/nbNO.js +8 -3
  214. package/locales/nlNL.d.ts +4 -0
  215. package/locales/nlNL.js +8 -3
  216. package/locales/plPL.d.ts +4 -0
  217. package/locales/plPL.js +8 -3
  218. package/locales/ptBR.d.ts +4 -0
  219. package/locales/ptBR.js +6 -1
  220. package/locales/roRO.d.ts +4 -0
  221. package/locales/roRO.js +6 -1
  222. package/locales/ruRU.d.ts +4 -0
  223. package/locales/ruRU.js +8 -3
  224. package/locales/skSK.d.ts +4 -0
  225. package/locales/skSK.js +8 -3
  226. package/locales/svSE.d.ts +4 -0
  227. package/locales/svSE.js +8 -3
  228. package/locales/trTR.d.ts +4 -0
  229. package/locales/trTR.js +8 -3
  230. package/locales/ukUA.d.ts +4 -0
  231. package/locales/ukUA.js +8 -3
  232. package/locales/urPK.d.ts +4 -0
  233. package/locales/urPK.js +6 -1
  234. package/locales/utils/getPickersLocalization.d.ts +4 -0
  235. package/locales/utils/pickersLocaleTextApi.d.ts +4 -0
  236. package/locales/viVN.d.ts +4 -0
  237. package/locales/viVN.js +8 -3
  238. package/locales/zhCN.d.ts +4 -0
  239. package/locales/zhCN.js +6 -1
  240. package/locales/zhHK.d.ts +4 -0
  241. package/locales/zhHK.js +6 -1
  242. package/modern/AdapterLuxon/AdapterLuxon.js +3 -11
  243. package/modern/DatePicker/DatePicker.js +0 -3
  244. package/modern/DatePicker/DatePickerToolbar.js +0 -3
  245. package/modern/DateTimePicker/DateTimePicker.js +0 -3
  246. package/modern/DateTimePicker/DateTimePickerTabs.js +7 -4
  247. package/modern/DateTimePicker/DateTimePickerToolbar.js +33 -20
  248. package/modern/DesktopDatePicker/DesktopDatePicker.js +0 -3
  249. package/modern/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
  250. package/modern/DesktopTimePicker/DesktopTimePicker.js +0 -3
  251. package/modern/MobileDatePicker/MobileDatePicker.js +0 -3
  252. package/modern/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
  253. package/modern/MobileTimePicker/MobileTimePicker.js +0 -3
  254. package/modern/MonthCalendar/MonthCalendar.js +0 -3
  255. package/modern/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
  256. package/modern/PickersLayout/pickersLayoutClasses.js +3 -2
  257. package/modern/PickersLayout/usePickerLayout.js +2 -1
  258. package/modern/PickersSectionList/PickersSectionList.js +6 -1
  259. package/modern/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +98 -25
  260. package/modern/PickersTextField/PickersFilledInput/index.js +2 -0
  261. package/modern/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
  262. package/modern/PickersTextField/PickersInput/PickersInput.js +196 -0
  263. package/modern/PickersTextField/PickersInput/index.js +2 -0
  264. package/modern/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
  265. package/modern/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
  266. package/modern/PickersTextField/PickersInputBase/index.js +2 -0
  267. package/modern/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
  268. package/{internals/components/PickersInput → modern/PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
  269. package/modern/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +190 -0
  270. package/modern/PickersTextField/PickersOutlinedInput/index.js +2 -0
  271. package/modern/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
  272. package/modern/PickersTextField/PickersTextField.js +258 -0
  273. package/modern/PickersTextField/index.js +6 -0
  274. package/modern/StaticDatePicker/StaticDatePicker.js +0 -3
  275. package/modern/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
  276. package/modern/StaticTimePicker/StaticTimePicker.js +0 -3
  277. package/modern/TimeClock/TimeClock.js +3 -3
  278. package/modern/TimePicker/TimePicker.js +0 -3
  279. package/modern/TimePicker/TimePickerToolbar.js +0 -3
  280. package/modern/YearCalendar/YearCalendar.js +0 -3
  281. package/modern/dateTimeViewRenderers/dateTimeViewRenderers.js +4 -4
  282. package/modern/index.js +3 -2
  283. package/modern/internals/hooks/useField/useField.js +5 -3
  284. package/modern/internals/hooks/useField/useField.utils.js +68 -21
  285. package/modern/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
  286. package/modern/internals/hooks/useField/useFieldState.js +9 -7
  287. package/modern/internals/hooks/usePicker/usePicker.js +4 -2
  288. package/modern/internals/hooks/usePicker/usePickerViews.js +8 -3
  289. package/modern/internals/index.js +2 -2
  290. package/modern/internals/utils/valueManagers.js +2 -2
  291. package/modern/locales/beBY.js +8 -3
  292. package/modern/locales/caES.js +7 -2
  293. package/modern/locales/csCZ.js +8 -3
  294. package/modern/locales/daDK.js +8 -3
  295. package/modern/locales/deDE.js +6 -1
  296. package/modern/locales/elGR.js +8 -3
  297. package/modern/locales/enUS.js +7 -3
  298. package/modern/locales/esES.js +8 -3
  299. package/modern/locales/eu.js +6 -1
  300. package/modern/locales/faIR.js +6 -1
  301. package/modern/locales/fiFI.js +8 -3
  302. package/modern/locales/frFR.js +6 -1
  303. package/modern/locales/heIL.js +6 -1
  304. package/modern/locales/huHU.js +6 -1
  305. package/modern/locales/isIS.js +8 -3
  306. package/modern/locales/itIT.js +8 -3
  307. package/modern/locales/jaJP.js +6 -1
  308. package/modern/locales/koKR.js +6 -1
  309. package/modern/locales/kzKZ.js +6 -1
  310. package/modern/locales/mk.js +6 -1
  311. package/modern/locales/nbNO.js +8 -3
  312. package/modern/locales/nlNL.js +8 -3
  313. package/modern/locales/plPL.js +8 -3
  314. package/modern/locales/ptBR.js +6 -1
  315. package/modern/locales/roRO.js +6 -1
  316. package/modern/locales/ruRU.js +8 -3
  317. package/modern/locales/skSK.js +8 -3
  318. package/modern/locales/svSE.js +8 -3
  319. package/modern/locales/trTR.js +8 -3
  320. package/modern/locales/ukUA.js +8 -3
  321. package/modern/locales/urPK.js +6 -1
  322. package/modern/locales/viVN.js +8 -3
  323. package/modern/locales/zhCN.js +6 -1
  324. package/modern/locales/zhHK.js +6 -1
  325. package/node/AdapterLuxon/AdapterLuxon.js +3 -11
  326. package/node/DatePicker/DatePicker.js +0 -3
  327. package/node/DatePicker/DatePickerToolbar.js +0 -3
  328. package/node/DateTimePicker/DateTimePicker.js +0 -3
  329. package/node/DateTimePicker/DateTimePickerTabs.js +8 -5
  330. package/node/DateTimePicker/DateTimePickerToolbar.js +34 -21
  331. package/node/DesktopDatePicker/DesktopDatePicker.js +0 -3
  332. package/node/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
  333. package/node/DesktopTimePicker/DesktopTimePicker.js +0 -3
  334. package/node/MobileDatePicker/MobileDatePicker.js +0 -3
  335. package/node/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
  336. package/node/MobileTimePicker/MobileTimePicker.js +0 -3
  337. package/node/MonthCalendar/MonthCalendar.js +0 -3
  338. package/node/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
  339. package/node/PickersLayout/pickersLayoutClasses.js +5 -3
  340. package/node/PickersLayout/usePickerLayout.js +2 -1
  341. package/node/PickersSectionList/PickersSectionList.js +6 -1
  342. package/node/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +102 -30
  343. package/node/PickersTextField/PickersFilledInput/index.js +25 -0
  344. package/node/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +16 -0
  345. package/node/PickersTextField/PickersInput/PickersInput.js +204 -0
  346. package/node/{internals/components → PickersTextField}/PickersInput/index.js +0 -7
  347. package/node/PickersTextField/PickersInput/pickersInputClasses.js +16 -0
  348. package/node/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +105 -27
  349. package/node/PickersTextField/PickersInputBase/index.js +25 -0
  350. package/node/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +14 -0
  351. package/node/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
  352. package/node/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +197 -0
  353. package/node/PickersTextField/PickersOutlinedInput/index.js +25 -0
  354. package/node/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +16 -0
  355. package/node/{internals/components/PickersTextField → PickersTextField}/PickersTextField.js +128 -9
  356. package/node/PickersTextField/index.js +78 -0
  357. package/node/StaticDatePicker/StaticDatePicker.js +0 -3
  358. package/node/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
  359. package/node/StaticTimePicker/StaticTimePicker.js +0 -3
  360. package/node/TimeClock/TimeClock.js +3 -3
  361. package/node/TimePicker/TimePicker.js +0 -3
  362. package/node/TimePicker/TimePickerToolbar.js +0 -3
  363. package/node/YearCalendar/YearCalendar.js +0 -3
  364. package/node/dateTimeViewRenderers/dateTimeViewRenderers.js +4 -4
  365. package/node/index.js +17 -5
  366. package/node/internals/hooks/useField/useField.js +5 -3
  367. package/node/internals/hooks/useField/useField.utils.js +73 -22
  368. package/node/internals/hooks/useField/useFieldCharacterEditing.js +11 -7
  369. package/node/internals/hooks/useField/useFieldState.js +8 -6
  370. package/node/internals/hooks/usePicker/usePicker.js +4 -2
  371. package/node/internals/hooks/usePicker/usePickerViews.js +8 -3
  372. package/node/internals/index.js +12 -0
  373. package/node/internals/utils/valueManagers.js +2 -2
  374. package/node/locales/beBY.js +8 -3
  375. package/node/locales/caES.js +7 -2
  376. package/node/locales/csCZ.js +8 -3
  377. package/node/locales/daDK.js +8 -3
  378. package/node/locales/deDE.js +6 -1
  379. package/node/locales/elGR.js +8 -3
  380. package/node/locales/enUS.js +7 -3
  381. package/node/locales/esES.js +8 -3
  382. package/node/locales/eu.js +6 -1
  383. package/node/locales/faIR.js +6 -1
  384. package/node/locales/fiFI.js +8 -3
  385. package/node/locales/frFR.js +6 -1
  386. package/node/locales/heIL.js +6 -1
  387. package/node/locales/huHU.js +6 -1
  388. package/node/locales/isIS.js +8 -3
  389. package/node/locales/itIT.js +8 -3
  390. package/node/locales/jaJP.js +6 -1
  391. package/node/locales/koKR.js +6 -1
  392. package/node/locales/kzKZ.js +6 -1
  393. package/node/locales/mk.js +6 -1
  394. package/node/locales/nbNO.js +8 -3
  395. package/node/locales/nlNL.js +8 -3
  396. package/node/locales/plPL.js +8 -3
  397. package/node/locales/ptBR.js +6 -1
  398. package/node/locales/roRO.js +6 -1
  399. package/node/locales/ruRU.js +8 -3
  400. package/node/locales/skSK.js +8 -3
  401. package/node/locales/svSE.js +8 -3
  402. package/node/locales/trTR.js +8 -3
  403. package/node/locales/ukUA.js +8 -3
  404. package/node/locales/urPK.js +6 -1
  405. package/node/locales/viVN.js +8 -3
  406. package/node/locales/zhCN.js +6 -1
  407. package/node/locales/zhHK.js +6 -1
  408. package/package.json +7 -7
  409. package/themeAugmentation/components.d.ts +26 -0
  410. package/themeAugmentation/overrides.d.ts +16 -0
  411. package/themeAugmentation/props.d.ts +16 -0
  412. package/timeViewRenderers/timeViewRenderers.d.ts +1 -1
  413. package/internals/components/PickersInput/PickersFilledInput.d.ts +0 -3
  414. package/internals/components/PickersInput/PickersInput.d.ts +0 -13
  415. package/internals/components/PickersInput/PickersOutlinedInput.d.ts +0 -3
  416. package/internals/components/PickersInput/PickersOutlinedInput.js +0 -117
  417. package/internals/components/PickersInput/PickersStandardInput.d.ts +0 -3
  418. package/internals/components/PickersInput/PickersStandardInput.js +0 -123
  419. package/internals/components/PickersInput/index.js +0 -3
  420. package/internals/components/PickersInput/pickersInputClasses.d.ts +0 -84
  421. package/internals/components/PickersInput/pickersInputClasses.js +0 -18
  422. package/internals/components/PickersTextField/PickersTextField.d.ts +0 -2
  423. package/internals/components/PickersTextField/PickersTextField.js +0 -138
  424. package/internals/components/PickersTextField/index.d.ts +0 -1
  425. package/internals/components/PickersTextField/index.js +0 -1
  426. package/legacy/internals/components/PickersInput/PickersOutlinedInput.js +0 -110
  427. package/legacy/internals/components/PickersInput/PickersStandardInput.js +0 -117
  428. package/legacy/internals/components/PickersInput/index.js +0 -3
  429. package/legacy/internals/components/PickersInput/pickersInputClasses.js +0 -18
  430. package/legacy/internals/components/PickersTextField/index.js +0 -1
  431. package/modern/internals/components/PickersInput/PickersOutlinedInput.js +0 -117
  432. package/modern/internals/components/PickersInput/PickersStandardInput.js +0 -123
  433. package/modern/internals/components/PickersInput/index.js +0 -3
  434. package/modern/internals/components/PickersInput/pickersInputClasses.js +0 -18
  435. package/modern/internals/components/PickersTextField/PickersTextField.js +0 -138
  436. package/modern/internals/components/PickersTextField/index.js +0 -1
  437. package/node/internals/components/PickersInput/PickersOutlinedInput.js +0 -125
  438. package/node/internals/components/PickersInput/PickersStandardInput.js +0 -132
  439. package/node/internals/components/PickersInput/pickersInputClasses.js +0 -29
  440. package/node/internals/components/PickersTextField/index.js +0 -12
  441. /package/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
  442. /package/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
  443. /package/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.d.ts +0 -0
  444. /package/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
  445. /package/legacy/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
  446. /package/legacy/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
  447. /package/legacy/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
  448. /package/modern/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
  449. /package/modern/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
  450. /package/modern/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
  451. /package/node/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
  452. /package/node/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
  453. /package/node/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
@@ -0,0 +1,8 @@
1
+ import _extends from "@babel/runtime/helpers/esm/extends";
2
+ import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
+ import generateUtilityClass from '@mui/utils/generateUtilityClass';
4
+ import { pickersInputBaseClasses } from '../PickersInputBase';
5
+ export function getPickersFilledInputUtilityClass(slot) {
6
+ return generateUtilityClass('MuiPickersFilledInput', slot);
7
+ }
8
+ export const pickersFilledInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersFilledInput', ['root', 'underline', 'input']));
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ import { PickersInputBaseProps } from '../PickersInputBase';
3
+ export interface PickersInputProps extends PickersInputBaseProps {
4
+ disableUnderline?: boolean;
5
+ }
6
+ /**
7
+ * @ignore - internal component.
8
+ */
9
+ declare const PickersInput: React.ForwardRefExoticComponent<Omit<PickersInputProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
+ export { PickersInput };
@@ -0,0 +1,196 @@
1
+ import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
+ import _extends from "@babel/runtime/helpers/esm/extends";
3
+ const _excluded = ["label", "autoFocus", "ownerState"];
4
+ import * as React from 'react';
5
+ import PropTypes from 'prop-types';
6
+ import { useFormControl } from '@mui/material/FormControl';
7
+ import { styled, useThemeProps } from '@mui/material/styles';
8
+ import composeClasses from '@mui/utils/composeClasses';
9
+ import { pickersInputClasses, getPickersInputUtilityClass } from './pickersInputClasses';
10
+ import { PickersInputBase } from '../PickersInputBase';
11
+ import { PickersInputBaseRoot } from '../PickersInputBase/PickersInputBase';
12
+ import { jsx as _jsx } from "react/jsx-runtime";
13
+ const PickersInputRoot = styled(PickersInputBaseRoot, {
14
+ name: 'MuiPickersInput',
15
+ slot: 'Root',
16
+ overridesResolver: (props, styles) => styles.root
17
+ })(({
18
+ theme,
19
+ ownerState
20
+ }) => {
21
+ const light = theme.palette.mode === 'light';
22
+ let bottomLineColor = light ? 'rgba(0, 0, 0, 0.42)' : 'rgba(255, 255, 255, 0.7)';
23
+ if (theme.vars) {
24
+ bottomLineColor = `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.inputUnderline})`;
25
+ }
26
+ return _extends({
27
+ 'label + &': {
28
+ marginTop: 16
29
+ }
30
+ }, !ownerState.disableUnderline && {
31
+ '&::after': {
32
+ background: 'red',
33
+ // @ts-ignore
34
+ borderBottom: `2px solid ${(theme.vars || theme).palette[ownerState.color].main}`,
35
+ left: 0,
36
+ bottom: 0,
37
+ // Doing the other way around crash on IE11 "''" https://github.com/cssinjs/jss/issues/242
38
+ content: '""',
39
+ position: 'absolute',
40
+ right: 0,
41
+ transform: 'scaleX(0)',
42
+ transition: theme.transitions.create('transform', {
43
+ duration: theme.transitions.duration.shorter,
44
+ easing: theme.transitions.easing.easeOut
45
+ }),
46
+ pointerEvents: 'none' // Transparent to the hover style.
47
+ },
48
+ [`&.${pickersInputClasses.focused}:after`]: {
49
+ // translateX(0) is a workaround for Safari transform scale bug
50
+ // See https://github.com/mui/material-ui/issues/31766
51
+ transform: 'scaleX(1) translateX(0)'
52
+ },
53
+ [`&.${pickersInputClasses.error}`]: {
54
+ '&:before, &:after': {
55
+ borderBottomColor: (theme.vars || theme).palette.error.main
56
+ }
57
+ },
58
+ '&::before': {
59
+ borderBottom: `1px solid ${bottomLineColor}`,
60
+ left: 0,
61
+ bottom: 0,
62
+ // Doing the other way around crash on IE11 "''" https://github.com/cssinjs/jss/issues/242
63
+ content: '"\\00a0"',
64
+ position: 'absolute',
65
+ right: 0,
66
+ transition: theme.transitions.create('border-bottom-color', {
67
+ duration: theme.transitions.duration.shorter
68
+ }),
69
+ pointerEvents: 'none' // Transparent to the hover style.
70
+ },
71
+ [`&:hover:not(.${pickersInputClasses.disabled}, .${pickersInputClasses.error}):before`]: {
72
+ borderBottom: `2px solid ${(theme.vars || theme).palette.text.primary}`,
73
+ // Reset on touch devices, it doesn't add specificity
74
+ '@media (hover: none)': {
75
+ borderBottom: `1px solid ${bottomLineColor}`
76
+ }
77
+ },
78
+ [`&.${pickersInputClasses.disabled}:before`]: {
79
+ borderBottomStyle: 'dotted'
80
+ }
81
+ });
82
+ });
83
+ const useUtilityClasses = ownerState => {
84
+ const {
85
+ classes,
86
+ disableUnderline
87
+ } = ownerState;
88
+ const slots = {
89
+ root: ['root', !disableUnderline && 'underline'],
90
+ input: ['input']
91
+ };
92
+ const composedClasses = composeClasses(slots, getPickersInputUtilityClass, classes);
93
+ return _extends({}, classes, composedClasses);
94
+ };
95
+ /**
96
+ * @ignore - internal component.
97
+ */
98
+ const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(inProps, ref) {
99
+ const props = useThemeProps({
100
+ props: inProps,
101
+ name: 'MuiPickersInput'
102
+ });
103
+ const {
104
+ label,
105
+ ownerState: ownerStateProp
106
+ } = props,
107
+ other = _objectWithoutPropertiesLoose(props, _excluded);
108
+ const muiFormControl = useFormControl();
109
+ const ownerState = _extends({}, props, ownerStateProp, muiFormControl, {
110
+ color: (muiFormControl == null ? void 0 : muiFormControl.color) || 'primary'
111
+ });
112
+ const classes = useUtilityClasses(ownerState);
113
+ return /*#__PURE__*/_jsx(PickersInputBase, _extends({
114
+ slots: {
115
+ root: PickersInputRoot
116
+ }
117
+ }, other, {
118
+ label: label,
119
+ classes: classes,
120
+ ref: ref
121
+ }));
122
+ });
123
+ process.env.NODE_ENV !== "production" ? PickersInput.propTypes = {
124
+ // ----------------------------- Warning --------------------------------
125
+ // | These PropTypes are generated from the TypeScript type definitions |
126
+ // | To update them edit the TypeScript types and run "yarn proptypes" |
127
+ // ----------------------------------------------------------------------
128
+ /**
129
+ * Is `true` if the current values equals the empty value.
130
+ * For a single item value, it means that `value === null`
131
+ * For a range value, it means that `value === [null, null]`
132
+ */
133
+ areAllSectionsEmpty: PropTypes.bool.isRequired,
134
+ className: PropTypes.string,
135
+ /**
136
+ * The component used for the root node.
137
+ * Either a string to use a HTML element or a component.
138
+ */
139
+ component: PropTypes.elementType,
140
+ /**
141
+ * If true, the whole element is editable.
142
+ * Useful when all the sections are selected.
143
+ */
144
+ contentEditable: PropTypes.bool.isRequired,
145
+ disableUnderline: PropTypes.bool,
146
+ /**
147
+ * The elements to render.
148
+ * Each element contains the prop to edit a section of the value.
149
+ */
150
+ elements: PropTypes.arrayOf(PropTypes.shape({
151
+ after: PropTypes.object.isRequired,
152
+ before: PropTypes.object.isRequired,
153
+ container: PropTypes.object.isRequired,
154
+ content: PropTypes.object.isRequired
155
+ })).isRequired,
156
+ endAdornment: PropTypes.node,
157
+ fullWidth: PropTypes.bool,
158
+ id: PropTypes.string,
159
+ inputProps: PropTypes.object,
160
+ inputRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
161
+ current: PropTypes.object
162
+ })]),
163
+ label: PropTypes.node,
164
+ margin: PropTypes.oneOf(['dense', 'none', 'normal']),
165
+ onChange: PropTypes.func.isRequired,
166
+ onClick: PropTypes.func.isRequired,
167
+ onInput: PropTypes.func.isRequired,
168
+ onKeyDown: PropTypes.func.isRequired,
169
+ onPaste: PropTypes.func.isRequired,
170
+ ownerState: PropTypes.any,
171
+ readOnly: PropTypes.bool,
172
+ renderSuffix: PropTypes.func,
173
+ sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
174
+ current: PropTypes.shape({
175
+ getRoot: PropTypes.func.isRequired,
176
+ getSectionContainer: PropTypes.func.isRequired,
177
+ getSectionContent: PropTypes.func.isRequired,
178
+ getSectionIndexFromDOMElement: PropTypes.func.isRequired
179
+ })
180
+ })]),
181
+ /**
182
+ * The components used for each slot inside.
183
+ *
184
+ * @default {}
185
+ */
186
+ slots: PropTypes.object,
187
+ startAdornment: PropTypes.node,
188
+ style: PropTypes.object,
189
+ /**
190
+ * The system prop that allows defining system overrides as well as additional CSS styles.
191
+ */
192
+ sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
193
+ value: PropTypes.string.isRequired
194
+ } : void 0;
195
+ export { PickersInput };
196
+ PickersInput.muiName = 'Input';
@@ -1,4 +1,4 @@
1
1
  export { PickersInput } from './PickersInput';
2
- export { PickersInputProps } from './PickersInput.types';
3
- export { pickersInputClasses, getPickersInputUtilityClass } from './pickersInputClasses';
2
+ export type { PickersInputProps } from './PickersInput';
4
3
  export type { PickersInputClasses, PickersInputClassKey } from './pickersInputClasses';
4
+ export { getPickersInputUtilityClass, pickersInputClasses } from './pickersInputClasses';
@@ -0,0 +1,2 @@
1
+ export { PickersInput } from './PickersInput';
2
+ export { getPickersInputUtilityClass, pickersInputClasses } from './pickersInputClasses';
@@ -0,0 +1,22 @@
1
+ import { PickersInputBaseClasses } from '../PickersInputBase';
2
+ export interface PickersInputClasses extends PickersInputBaseClasses {
3
+ /** Styles applied to the root element unless `disableUnderline={true}`. */
4
+ underline: string;
5
+ }
6
+ export type PickersInputClassKey = keyof PickersInputClasses;
7
+ export declare function getPickersInputUtilityClass(slot: string): string;
8
+ export declare const pickersInputClasses: {
9
+ disabled: string;
10
+ input: string;
11
+ readOnly: string;
12
+ error: string;
13
+ focused: string;
14
+ root: string;
15
+ adornedStart: string;
16
+ adornedEnd: string;
17
+ notchedOutline: string;
18
+ sectionsContainer: string;
19
+ sectionContent: string;
20
+ sectionBefore: string;
21
+ sectionAfter: string;
22
+ };
@@ -0,0 +1,8 @@
1
+ import _extends from "@babel/runtime/helpers/esm/extends";
2
+ import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
+ import generateUtilityClass from '@mui/utils/generateUtilityClass';
4
+ import { pickersInputBaseClasses } from '../PickersInputBase';
5
+ export function getPickersInputUtilityClass(slot) {
6
+ return generateUtilityClass('MuiPickersFilledInput', slot);
7
+ }
8
+ export const pickersInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersInput', ['root', 'input']));
@@ -0,0 +1,16 @@
1
+ import * as React from 'react';
2
+ import { FormControlState } from '@mui/material/FormControl';
3
+ import { PickersInputBaseProps } from './PickersInputBase.types';
4
+ export declare const PickersInputBaseRoot: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
5
+ ownerState: OwnerStateType;
6
+ }, Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof React.ClassAttributes<HTMLDivElement> | keyof React.HTMLAttributes<HTMLDivElement>>, {}>;
7
+ export declare const PickersInputBaseSectionsContainer: import("@emotion/styled").StyledComponent<Pick<import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof React.ClassAttributes<HTMLDivElement> | keyof React.HTMLAttributes<HTMLDivElement>>, keyof React.ClassAttributes<HTMLDivElement> | keyof React.HTMLAttributes<HTMLDivElement> | keyof import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme>> & import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
8
+ ownerState: OwnerStateType;
9
+ }, {}, {}>;
10
+ interface OwnerStateType extends FormControlState, Omit<PickersInputBaseProps, keyof FormControlState> {
11
+ }
12
+ /**
13
+ * @ignore - internal component.
14
+ */
15
+ declare const PickersInputBase: React.ForwardRefExoticComponent<Omit<PickersInputBaseProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
16
+ export { PickersInputBase };
@@ -2,19 +2,20 @@ import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWith
2
2
  import _extends from "@babel/runtime/helpers/esm/extends";
3
3
  const _excluded = ["elements", "areAllSectionsEmpty", "defaultValue", "label", "value", "onChange", "id", "autoFocus", "endAdornment", "startAdornment", "renderSuffix", "slots", "contentEditable", "tabIndex", "onInput", "onPaste", "onKeyDown", "fullWidth", "inputProps", "inputRef", "sectionListRef"];
4
4
  import * as React from 'react';
5
+ import PropTypes from 'prop-types';
5
6
  import { useFormControl } from '@mui/material/FormControl';
6
- import { styled } from '@mui/material/styles';
7
+ import { styled, useThemeProps } from '@mui/material/styles';
7
8
  import useForkRef from '@mui/utils/useForkRef';
8
9
  import composeClasses from '@mui/utils/composeClasses';
9
10
  import capitalize from '@mui/utils/capitalize';
10
11
  import visuallyHidden from '@mui/utils/visuallyHidden';
11
- import { pickersInputClasses, getPickersInputUtilityClass } from './pickersInputClasses';
12
- import { Unstable_PickersSectionList as PickersSectionList, Unstable_PickersSectionListRoot as PickersSectionListRoot, Unstable_PickersSectionListSection as PickersSectionListSection, Unstable_PickersSectionListSectionSeparator as PickersSectionListSectionSeparator, Unstable_PickersSectionListSectionContent as PickersSectionListSectionContent } from '../../../PickersSectionList';
12
+ import { pickersInputBaseClasses, getPickersInputBaseUtilityClass } from './pickersInputBaseClasses';
13
+ import { Unstable_PickersSectionList as PickersSectionList, Unstable_PickersSectionListRoot as PickersSectionListRoot, Unstable_PickersSectionListSection as PickersSectionListSection, Unstable_PickersSectionListSectionSeparator as PickersSectionListSectionSeparator, Unstable_PickersSectionListSectionContent as PickersSectionListSectionContent } from '../../PickersSectionList';
13
14
  import { jsx as _jsx } from "react/jsx-runtime";
14
15
  import { jsxs as _jsxs } from "react/jsx-runtime";
15
16
  const round = value => Math.round(value * 1e5) / 1e5;
16
- export const PickersInputRoot = styled('div', {
17
- name: 'MuiPickersInput',
17
+ export const PickersInputBaseRoot = styled('div', {
18
+ name: 'MuiPickersInputBase',
18
19
  slot: 'Root',
19
20
  overridesResolver: (props, styles) => styles.root
20
21
  })(({
@@ -34,8 +35,8 @@ export const PickersInputRoot = styled('div', {
34
35
  }, ownerState.fullWidth && {
35
36
  width: '100%'
36
37
  }));
37
- export const PickersInputSectionsContainer = styled(PickersSectionListRoot, {
38
- name: 'MuiPickersInput',
38
+ export const PickersInputBaseSectionsContainer = styled(PickersSectionListRoot, {
39
+ name: 'MuiPickersInputBase',
39
40
  slot: 'SectionsContainer',
40
41
  overridesResolver: (props, styles) => styles.sectionsContainer
41
42
  })(({
@@ -68,8 +69,8 @@ export const PickersInputSectionsContainer = styled(PickersSectionListRoot, {
68
69
  }), ownerState.label != null && {
69
70
  opacity: 0
70
71
  })));
71
- const PickersInputSection = styled(PickersSectionListSection, {
72
- name: 'MuiPickersInput',
72
+ const PickersInputBaseSection = styled(PickersSectionListSection, {
73
+ name: 'MuiPickersInputBase',
73
74
  slot: 'Section',
74
75
  overridesResolver: (props, styles) => styles.section
75
76
  })(({
@@ -82,8 +83,8 @@ const PickersInputSection = styled(PickersSectionListSection, {
82
83
  // 23px
83
84
  display: 'flex'
84
85
  }));
85
- const PickersInputSectionContent = styled(PickersSectionListSectionContent, {
86
- name: 'MuiPickersInput',
86
+ const PickersInputBaseSectionContent = styled(PickersSectionListSectionContent, {
87
+ name: 'MuiPickersInputBase',
87
88
  slot: 'SectionContent',
88
89
  overridesResolver: (props, styles) => styles.content
89
90
  })(({
@@ -96,16 +97,16 @@ const PickersInputSectionContent = styled(PickersSectionListSectionContent, {
96
97
  width: 'fit-content',
97
98
  outline: 'none'
98
99
  }));
99
- const PickersInputSeparator = styled(PickersSectionListSectionSeparator, {
100
- name: 'MuiPickersInput',
100
+ const PickersInputBaseSectionSeparator = styled(PickersSectionListSectionSeparator, {
101
+ name: 'MuiPickersInputBase',
101
102
  slot: 'Separator',
102
103
  overridesResolver: (props, styles) => styles.separator
103
104
  })(() => ({
104
105
  whiteSpace: 'pre',
105
106
  letterSpacing: 'inherit'
106
107
  }));
107
- const PickersInputInput = styled('input', {
108
- name: 'MuiPickersInput',
108
+ const PickersInputBaseInput = styled('input', {
109
+ name: 'MuiPickersInputBase',
109
110
  slot: 'Input',
110
111
  overridesResolver: (props, styles) => styles.hiddenInput
111
112
  })(_extends({}, visuallyHidden));
@@ -131,9 +132,16 @@ const useUtilityClasses = ownerState => {
131
132
  sectionBefore: ['sectionBefore'],
132
133
  sectionAfter: ['sectionAfter']
133
134
  };
134
- return composeClasses(slots, getPickersInputUtilityClass, classes);
135
+ return composeClasses(slots, getPickersInputBaseUtilityClass, classes);
135
136
  };
136
- export const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(props, ref) {
137
+ /**
138
+ * @ignore - internal component.
139
+ */
140
+ const PickersInputBase = /*#__PURE__*/React.forwardRef(function PickersInputBase(inProps, ref) {
141
+ const props = useThemeProps({
142
+ props: inProps,
143
+ name: 'MuiPickersInputBase'
144
+ });
137
145
  const {
138
146
  elements,
139
147
  areAllSectionsEmpty,
@@ -159,7 +167,7 @@ export const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(
159
167
  const handleInputRef = useForkRef(inputProps == null ? void 0 : inputProps.ref, inputRef);
160
168
  const muiFormControl = useFormControl();
161
169
  if (!muiFormControl) {
162
- throw new Error('MUI X: PickersInput should always be used inside a PickersTextField component');
170
+ throw new Error('MUI X: PickersInputBase should always be used inside a PickersTextField component');
163
171
  }
164
172
  const handleInputFocus = event => {
165
173
  var _muiFormControl$onFoc;
@@ -188,8 +196,8 @@ export const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(
188
196
  }, [muiFormControl, areAllSectionsEmpty]);
189
197
  const ownerState = _extends({}, props, muiFormControl);
190
198
  const classes = useUtilityClasses(ownerState);
191
- const InputRoot = (slots == null ? void 0 : slots.root) || PickersInputRoot;
192
- const InputSectionsContainer = (slots == null ? void 0 : slots.input) || PickersInputSectionsContainer;
199
+ const InputRoot = (slots == null ? void 0 : slots.root) || PickersInputBaseRoot;
200
+ const InputSectionsContainer = (slots == null ? void 0 : slots.input) || PickersInputBaseSectionsContainer;
193
201
  return /*#__PURE__*/_jsxs(InputRoot, _extends({}, other, {
194
202
  className: classes.root,
195
203
  ownerState: ownerState,
@@ -208,24 +216,24 @@ export const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(
208
216
  onKeyDown: onKeyDown,
209
217
  slots: {
210
218
  root: InputSectionsContainer,
211
- section: PickersInputSection,
212
- sectionContent: PickersInputSectionContent,
213
- sectionSeparator: PickersInputSeparator
219
+ section: PickersInputBaseSection,
220
+ sectionContent: PickersInputBaseSectionContent,
221
+ sectionSeparator: PickersInputBaseSectionSeparator
214
222
  },
215
223
  slotProps: {
216
224
  root: {
217
225
  ownerState
218
226
  },
219
227
  sectionContent: {
220
- className: pickersInputClasses.sectionContent
228
+ className: pickersInputBaseClasses.sectionContent
221
229
  },
222
230
  sectionSeparator: ({
223
231
  position
224
232
  }) => ({
225
- className: position === 'before' ? pickersInputClasses.sectionBefore : pickersInputClasses.sectionAfter
233
+ className: position === 'before' ? pickersInputBaseClasses.sectionBefore : pickersInputBaseClasses.sectionAfter
226
234
  })
227
235
  }
228
- }), endAdornment, renderSuffix ? renderSuffix(_extends({}, muiFormControl)) : null, /*#__PURE__*/_jsx(PickersInputInput, _extends({
236
+ }), endAdornment, renderSuffix ? renderSuffix(_extends({}, muiFormControl)) : null, /*#__PURE__*/_jsx(PickersInputBaseInput, _extends({
229
237
  className: classes.input,
230
238
  value: value,
231
239
  onChange: onChange,
@@ -237,4 +245,75 @@ export const PickersInput = /*#__PURE__*/React.forwardRef(function PickersInput(
237
245
  }))]
238
246
  }));
239
247
  });
240
- PickersInput.muiName = 'Input';
248
+ process.env.NODE_ENV !== "production" ? PickersInputBase.propTypes = {
249
+ // ----------------------------- Warning --------------------------------
250
+ // | These PropTypes are generated from the TypeScript type definitions |
251
+ // | To update them edit the TypeScript types and run "yarn proptypes" |
252
+ // ----------------------------------------------------------------------
253
+ /**
254
+ * Is `true` if the current values equals the empty value.
255
+ * For a single item value, it means that `value === null`
256
+ * For a range value, it means that `value === [null, null]`
257
+ */
258
+ areAllSectionsEmpty: PropTypes.bool.isRequired,
259
+ className: PropTypes.string,
260
+ /**
261
+ * The component used for the root node.
262
+ * Either a string to use a HTML element or a component.
263
+ */
264
+ component: PropTypes.elementType,
265
+ /**
266
+ * If true, the whole element is editable.
267
+ * Useful when all the sections are selected.
268
+ */
269
+ contentEditable: PropTypes.bool.isRequired,
270
+ /**
271
+ * The elements to render.
272
+ * Each element contains the prop to edit a section of the value.
273
+ */
274
+ elements: PropTypes.arrayOf(PropTypes.shape({
275
+ after: PropTypes.object.isRequired,
276
+ before: PropTypes.object.isRequired,
277
+ container: PropTypes.object.isRequired,
278
+ content: PropTypes.object.isRequired
279
+ })).isRequired,
280
+ endAdornment: PropTypes.node,
281
+ fullWidth: PropTypes.bool,
282
+ id: PropTypes.string,
283
+ inputProps: PropTypes.object,
284
+ inputRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
285
+ current: PropTypes.object
286
+ })]),
287
+ label: PropTypes.node,
288
+ margin: PropTypes.oneOf(['dense', 'none', 'normal']),
289
+ onChange: PropTypes.func.isRequired,
290
+ onClick: PropTypes.func.isRequired,
291
+ onInput: PropTypes.func.isRequired,
292
+ onKeyDown: PropTypes.func.isRequired,
293
+ onPaste: PropTypes.func.isRequired,
294
+ ownerState: PropTypes.any,
295
+ readOnly: PropTypes.bool,
296
+ renderSuffix: PropTypes.func,
297
+ sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
298
+ current: PropTypes.shape({
299
+ getRoot: PropTypes.func.isRequired,
300
+ getSectionContainer: PropTypes.func.isRequired,
301
+ getSectionContent: PropTypes.func.isRequired,
302
+ getSectionIndexFromDOMElement: PropTypes.func.isRequired
303
+ })
304
+ })]),
305
+ /**
306
+ * The components used for each slot inside.
307
+ *
308
+ * @default {}
309
+ */
310
+ slots: PropTypes.object,
311
+ startAdornment: PropTypes.node,
312
+ style: PropTypes.object,
313
+ /**
314
+ * The system prop that allows defining system overrides as well as additional CSS styles.
315
+ */
316
+ sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
317
+ value: PropTypes.string.isRequired
318
+ } : void 0;
319
+ export { PickersInputBase };
@@ -1,6 +1,6 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { BoxProps } from '@mui/material/Box';
3
- import { PickersSectionListProps } from '../../../PickersSectionList';
3
+ import { PickersSectionListProps } from '../../PickersSectionList';
4
4
  export interface PickersInputPropsUsedByField extends Pick<PickersSectionListProps, 'elements' | 'sectionListRef' | 'contentEditable' | 'tabIndex'> {
5
5
  /**
6
6
  * Is `true` if the current values equals the empty value.
@@ -25,7 +25,7 @@ export interface PickersInputPropsUsedByField extends Pick<PickersSectionListPro
25
25
  };
26
26
  inputRef?: React.Ref<HTMLInputElement>;
27
27
  }
28
- export interface PickersInputProps extends Omit<BoxProps, keyof PickersInputPropsUsedByField>, PickersInputPropsUsedByField {
28
+ export interface PickersInputBaseProps extends Omit<BoxProps, keyof PickersInputPropsUsedByField>, PickersInputPropsUsedByField {
29
29
  ownerState?: any;
30
30
  margin?: 'dense' | 'none' | 'normal';
31
31
  renderSuffix?: (state: {
@@ -48,13 +48,3 @@ export interface PickersInputProps extends Omit<BoxProps, keyof PickersInputProp
48
48
  input?: React.ElementType;
49
49
  };
50
50
  }
51
- export interface PickersOutlinedInputProps extends PickersInputProps {
52
- notched?: boolean;
53
- }
54
- export interface PickersStandardInputProps extends PickersInputProps {
55
- disableUnderline?: boolean;
56
- }
57
- export interface PickersFilledInputProps extends PickersInputProps {
58
- disableUnderline?: boolean;
59
- hiddenLabel?: boolean;
60
- }
@@ -0,0 +1,4 @@
1
+ export { PickersInputBase } from './PickersInputBase';
2
+ export type { PickersInputBaseProps } from './PickersInputBase.types';
3
+ export { pickersInputBaseClasses, getPickersInputBaseUtilityClass, } from './pickersInputBaseClasses';
4
+ export type { PickersInputBaseClasses, PickersInputBaseClassKey } from './pickersInputBaseClasses';
@@ -0,0 +1,2 @@
1
+ export { PickersInputBase } from './PickersInputBase';
2
+ export { pickersInputBaseClasses, getPickersInputBaseUtilityClass } from './pickersInputBaseClasses';
@@ -0,0 +1,31 @@
1
+ export interface PickersInputBaseClasses {
2
+ /** Styles applied to the root element. */
3
+ root: string;
4
+ /** Styles applied to the root element if focused. */
5
+ focused: string;
6
+ /** State class applied to the root element if `disabled=true`. */
7
+ disabled: string;
8
+ /** State class applied to the root element if `readOnly=true`. */
9
+ readOnly: string;
10
+ /** State class applied to the root element if `error=true`. */
11
+ error: string;
12
+ /** Styles applied to the NotchedOutline element. */
13
+ notchedOutline: string;
14
+ /** Styles applied to the real hidden input element. */
15
+ input: string;
16
+ /** Styles applied to the container of the sections. */
17
+ sectionsContainer: string;
18
+ /** Styles applied to the content of a section. */
19
+ sectionContent: string;
20
+ /** Styles applied to the separator before a section */
21
+ sectionBefore: string;
22
+ /** Styles applied to the separator after a section */
23
+ sectionAfter: string;
24
+ /** Styles applied to the root if there is a startAdornment present */
25
+ adornedStart: string;
26
+ /** Styles applied to the root if there is an endAdornment present */
27
+ adornedEnd: string;
28
+ }
29
+ export type PickersInputBaseClassKey = keyof PickersInputBaseClasses;
30
+ export declare function getPickersInputBaseUtilityClass(slot: string): string;
31
+ export declare const pickersInputBaseClasses: Record<keyof PickersInputBaseClasses, string>;
@@ -0,0 +1,6 @@
1
+ import generateUtilityClass from '@mui/utils/generateUtilityClass';
2
+ import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
+ export function getPickersInputBaseUtilityClass(slot) {
4
+ return generateUtilityClass('MuiPickersInputBase', slot);
5
+ }
6
+ export const pickersInputBaseClasses = generateUtilityClasses('MuiPickersInputBase', ['root', 'focused', 'disabled', 'error', 'notchedOutline', 'sectionContent', 'sectionBefore', 'sectionAfter', 'adornedStart', 'adornedEnd', 'input']);
@@ -5,5 +5,8 @@ interface OutlineProps extends React.HTMLAttributes<HTMLFieldSetElement> {
5
5
  label: React.ReactNode;
6
6
  ownerState: any;
7
7
  }
8
+ /**
9
+ * @ignore - internal component.
10
+ */
8
11
  export default function Outline(props: OutlineProps): React.JSX.Element;
9
12
  export {};
@@ -1,6 +1,6 @@
1
1
  import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
2
  import _extends from "@babel/runtime/helpers/esm/extends";
3
- const _excluded = ["children", "className", "label"];
3
+ const _excluded = ["children", "className", "label", "notched", "shrink"];
4
4
  import * as React from 'react';
5
5
  import { styled } from '@mui/material/styles';
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -82,6 +82,10 @@ const OutlineLegend = styled('legend')(({
82
82
  delay: 50
83
83
  })
84
84
  })));
85
+
86
+ /**
87
+ * @ignore - internal component.
88
+ */
85
89
  export default function Outline(props) {
86
90
  const {
87
91
  className,
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ import { PickersInputBaseProps } from '../PickersInputBase';
3
+ export interface PickersOutlinedInputProps extends PickersInputBaseProps {
4
+ notched?: boolean;
5
+ }
6
+ /**
7
+ * @ignore - internal component.
8
+ */
9
+ declare const PickersOutlinedInput: React.ForwardRefExoticComponent<Omit<PickersOutlinedInputProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
+ export { PickersOutlinedInput };