@react-md/core 1.0.0-next.15 → 1.0.0-next.16

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 (815) hide show
  1. package/dist/RootHtml.d.ts +0 -2
  2. package/dist/RootHtml.js +0 -2
  3. package/dist/RootHtml.js.map +1 -1
  4. package/dist/app-bar/AppBar.d.ts +0 -2
  5. package/dist/app-bar/AppBar.js +0 -2
  6. package/dist/app-bar/AppBar.js.map +1 -1
  7. package/dist/app-bar/AppBarTitle.d.ts +0 -3
  8. package/dist/app-bar/AppBarTitle.js +0 -2
  9. package/dist/app-bar/AppBarTitle.js.map +1 -1
  10. package/dist/avatar/Avatar.d.ts +0 -2
  11. package/dist/avatar/Avatar.js +0 -2
  12. package/dist/avatar/Avatar.js.map +1 -1
  13. package/dist/badge/Badge.d.ts +1 -3
  14. package/dist/badge/Badge.js +0 -2
  15. package/dist/badge/Badge.js.map +1 -1
  16. package/dist/box/Box.d.ts +0 -2
  17. package/dist/box/Box.js +0 -2
  18. package/dist/box/Box.js.map +1 -1
  19. package/dist/button/ButtonUnstyled.d.ts +0 -2
  20. package/dist/button/ButtonUnstyled.js +0 -2
  21. package/dist/button/ButtonUnstyled.js.map +1 -1
  22. package/dist/card/Card.d.ts +0 -2
  23. package/dist/card/Card.js +0 -2
  24. package/dist/card/Card.js.map +1 -1
  25. package/dist/card/CardContent.d.ts +0 -2
  26. package/dist/card/CardContent.js +0 -2
  27. package/dist/card/CardContent.js.map +1 -1
  28. package/dist/card/CardFooter.d.ts +0 -3
  29. package/dist/card/CardFooter.js +0 -2
  30. package/dist/card/CardFooter.js.map +1 -1
  31. package/dist/card/CardHeader.d.ts +0 -2
  32. package/dist/card/CardHeader.js +0 -2
  33. package/dist/card/CardHeader.js.map +1 -1
  34. package/dist/card/CardSubtitle.d.ts +0 -3
  35. package/dist/card/CardSubtitle.js +0 -2
  36. package/dist/card/CardSubtitle.js.map +1 -1
  37. package/dist/card/CardTitle.d.ts +0 -3
  38. package/dist/card/CardTitle.js +0 -2
  39. package/dist/card/CardTitle.js.map +1 -1
  40. package/dist/chip/Chip.d.ts +0 -2
  41. package/dist/chip/Chip.js +0 -2
  42. package/dist/chip/Chip.js.map +1 -1
  43. package/dist/dialog/DialogContainer.d.ts +0 -2
  44. package/dist/dialog/DialogContainer.js +0 -2
  45. package/dist/dialog/DialogContainer.js.map +1 -1
  46. package/dist/dialog/DialogContent.d.ts +3 -3
  47. package/dist/dialog/DialogContent.js +3 -3
  48. package/dist/dialog/DialogContent.js.map +1 -1
  49. package/dist/dialog/DialogFooter.d.ts +2 -3
  50. package/dist/dialog/DialogFooter.js +2 -3
  51. package/dist/dialog/DialogFooter.js.map +1 -1
  52. package/dist/dialog/DialogHeader.d.ts +3 -3
  53. package/dist/dialog/DialogHeader.js +3 -3
  54. package/dist/dialog/DialogHeader.js.map +1 -1
  55. package/dist/dialog/DialogTitle.d.ts +3 -4
  56. package/dist/dialog/DialogTitle.js +3 -3
  57. package/dist/dialog/DialogTitle.js.map +1 -1
  58. package/dist/dialog/NestedDialogProvider.d.ts +0 -1
  59. package/dist/divider/Divider.d.ts +0 -2
  60. package/dist/divider/Divider.js +0 -2
  61. package/dist/divider/Divider.js.map +1 -1
  62. package/dist/expansion-panel/ExpansionList.d.ts +1 -1
  63. package/dist/expansion-panel/ExpansionList.js +1 -1
  64. package/dist/expansion-panel/ExpansionList.js.map +1 -1
  65. package/dist/expansion-panel/ExpansionPanel.d.ts +8 -24
  66. package/dist/expansion-panel/ExpansionPanel.js +1 -12
  67. package/dist/expansion-panel/ExpansionPanel.js.map +1 -1
  68. package/dist/expansion-panel/ExpansionPanelHeader.d.ts +0 -1
  69. package/dist/expansion-panel/ExpansionPanelHeader.js +0 -1
  70. package/dist/expansion-panel/ExpansionPanelHeader.js.map +1 -1
  71. package/dist/expansion-panel/expansionPanelStyles.d.ts +19 -0
  72. package/dist/expansion-panel/expansionPanelStyles.js +14 -0
  73. package/dist/expansion-panel/expansionPanelStyles.js.map +1 -0
  74. package/dist/form/Checkbox.d.ts +0 -1
  75. package/dist/form/Fieldset.d.ts +0 -2
  76. package/dist/form/Fieldset.js.map +1 -1
  77. package/dist/form/FormMessage.d.ts +0 -3
  78. package/dist/form/FormMessage.js +0 -2
  79. package/dist/form/FormMessage.js.map +1 -1
  80. package/dist/form/FormMessageContainer.d.ts +0 -1
  81. package/dist/form/FormMessageContainer.js +0 -1
  82. package/dist/form/FormMessageContainer.js.map +1 -1
  83. package/dist/form/FormMessageCounter.d.ts +0 -2
  84. package/dist/form/FormMessageCounter.js +0 -2
  85. package/dist/form/FormMessageCounter.js.map +1 -1
  86. package/dist/form/InputToggle.js.map +1 -1
  87. package/dist/form/InputToggleIcon.d.ts +0 -2
  88. package/dist/form/InputToggleIcon.js +0 -2
  89. package/dist/form/InputToggleIcon.js.map +1 -1
  90. package/dist/form/Label.d.ts +0 -3
  91. package/dist/form/Label.js +0 -2
  92. package/dist/form/Label.js.map +1 -1
  93. package/dist/form/Legend.d.ts +0 -3
  94. package/dist/form/Legend.js +0 -2
  95. package/dist/form/Legend.js.map +1 -1
  96. package/dist/form/MenuItemCheckbox.d.ts +0 -1
  97. package/dist/form/MenuItemRadio.d.ts +0 -1
  98. package/dist/form/MenuItemSwitch.d.ts +0 -1
  99. package/dist/form/NativeSelect.d.ts +0 -2
  100. package/dist/form/NativeSelect.js +0 -2
  101. package/dist/form/NativeSelect.js.map +1 -1
  102. package/dist/form/Option.js.map +1 -1
  103. package/dist/form/Radio.d.ts +0 -1
  104. package/dist/form/SelectedOption.d.ts +0 -2
  105. package/dist/form/SelectedOption.js +0 -2
  106. package/dist/form/SelectedOption.js.map +1 -1
  107. package/dist/form/SliderContainer.d.ts +0 -2
  108. package/dist/form/SliderContainer.js +0 -2
  109. package/dist/form/SliderContainer.js.map +1 -1
  110. package/dist/form/SliderMark.d.ts +0 -2
  111. package/dist/form/SliderMark.js +0 -2
  112. package/dist/form/SliderMark.js.map +1 -1
  113. package/dist/form/SliderMarkLabel.d.ts +0 -2
  114. package/dist/form/SliderMarkLabel.js +0 -2
  115. package/dist/form/SliderMarkLabel.js.map +1 -1
  116. package/dist/form/SliderTrack.d.ts +0 -2
  117. package/dist/form/SliderTrack.js +0 -2
  118. package/dist/form/SliderTrack.js.map +1 -1
  119. package/dist/form/SliderValueMarks.d.ts +0 -2
  120. package/dist/form/SliderValueMarks.js +0 -2
  121. package/dist/form/SliderValueMarks.js.map +1 -1
  122. package/dist/form/Switch.d.ts +0 -2
  123. package/dist/form/Switch.js +0 -2
  124. package/dist/form/Switch.js.map +1 -1
  125. package/dist/form/SwitchTrack.d.ts +2 -1
  126. package/dist/form/SwitchTrack.js +2 -1
  127. package/dist/form/SwitchTrack.js.map +1 -1
  128. package/dist/form/TextField.d.ts +0 -2
  129. package/dist/form/TextField.js +0 -2
  130. package/dist/form/TextField.js.map +1 -1
  131. package/dist/form/TextFieldAddon.d.ts +1 -4
  132. package/dist/form/TextFieldAddon.js +1 -3
  133. package/dist/form/TextFieldAddon.js.map +1 -1
  134. package/dist/icon/FontIcon.d.ts +0 -2
  135. package/dist/icon/FontIcon.js +0 -2
  136. package/dist/icon/FontIcon.js.map +1 -1
  137. package/dist/icon/IconRotator.d.ts +0 -2
  138. package/dist/icon/IconRotator.js +0 -2
  139. package/dist/icon/IconRotator.js.map +1 -1
  140. package/dist/icon/MaterialIcon.d.ts +0 -2
  141. package/dist/icon/MaterialIcon.js +0 -2
  142. package/dist/icon/MaterialIcon.js.map +1 -1
  143. package/dist/icon/MaterialSymbol.d.ts +0 -1
  144. package/dist/icon/MaterialSymbol.js +0 -1
  145. package/dist/icon/MaterialSymbol.js.map +1 -1
  146. package/dist/icon/SVGIcon.d.ts +0 -2
  147. package/dist/icon/SVGIcon.js +0 -2
  148. package/dist/icon/SVGIcon.js.map +1 -1
  149. package/dist/icon/TextIconSpacing.d.ts +0 -2
  150. package/dist/icon/TextIconSpacing.js +0 -2
  151. package/dist/icon/TextIconSpacing.js.map +1 -1
  152. package/dist/icon/_icon.scss +2 -2
  153. package/dist/icon/styles.js +1 -1
  154. package/dist/icon/styles.js.map +1 -1
  155. package/dist/interaction/RippleContainer.d.ts +0 -2
  156. package/dist/interaction/RippleContainer.js +0 -2
  157. package/dist/interaction/RippleContainer.js.map +1 -1
  158. package/dist/layout/LayoutAppBar.d.ts +0 -1
  159. package/dist/layout/LayoutNav.js +1 -2
  160. package/dist/layout/LayoutNav.js.map +1 -1
  161. package/dist/layout/LayoutWindowSplitter.d.ts +0 -1
  162. package/dist/layout/useHorizontalLayoutTransition.js +1 -1
  163. package/dist/layout/useHorizontalLayoutTransition.js.map +1 -1
  164. package/dist/layout/useLayoutTree.d.ts +2 -2
  165. package/dist/layout/useLayoutTree.js.map +1 -1
  166. package/dist/link/Link.d.ts +0 -2
  167. package/dist/link/Link.js +0 -2
  168. package/dist/link/Link.js.map +1 -1
  169. package/dist/list/List.d.ts +0 -20
  170. package/dist/list/List.js +1 -14
  171. package/dist/list/List.js.map +1 -1
  172. package/dist/list/ListItem.d.ts +0 -16
  173. package/dist/list/ListItem.js.map +1 -1
  174. package/dist/list/ListItemAddon.d.ts +0 -2
  175. package/dist/list/ListItemAddon.js +0 -2
  176. package/dist/list/ListItemAddon.js.map +1 -1
  177. package/dist/list/ListItemChildren.d.ts +0 -2
  178. package/dist/list/ListItemChildren.js +0 -2
  179. package/dist/list/ListItemChildren.js.map +1 -1
  180. package/dist/list/ListItemText.d.ts +0 -2
  181. package/dist/list/ListItemText.js +0 -2
  182. package/dist/list/ListItemText.js.map +1 -1
  183. package/dist/list/ListSubheader.d.ts +3 -2
  184. package/dist/list/ListSubheader.js +0 -2
  185. package/dist/list/ListSubheader.js.map +1 -1
  186. package/dist/list/getListItemHeight.d.ts +2 -2
  187. package/dist/list/getListItemHeight.js +2 -2
  188. package/dist/list/getListItemHeight.js.map +1 -1
  189. package/dist/list/listItemStyles.d.ts +17 -1
  190. package/dist/list/listItemStyles.js.map +1 -1
  191. package/dist/list/listStyles.d.ts +18 -0
  192. package/dist/list/listStyles.js +14 -0
  193. package/dist/list/listStyles.js.map +1 -0
  194. package/dist/list/types.d.ts +9 -3
  195. package/dist/list/types.js +6 -1
  196. package/dist/list/types.js.map +1 -1
  197. package/dist/media-queries/AppSizeProvider.d.ts +8 -0
  198. package/dist/media-queries/AppSizeProvider.js +2 -0
  199. package/dist/media-queries/AppSizeProvider.js.map +1 -1
  200. package/dist/media-queries/appSize.d.ts +5 -5
  201. package/dist/media-queries/useMediaQuery.d.ts +1 -1
  202. package/dist/media-queries/useMediaQuery.js +1 -1
  203. package/dist/media-queries/useMediaQuery.js.map +1 -1
  204. package/dist/menu/MenuBar.d.ts +0 -1
  205. package/dist/menu/MenuButton.d.ts +0 -1
  206. package/dist/menu/MenuConfigurationProvider.js.map +1 -1
  207. package/dist/menu/MenuItem.d.ts +0 -1
  208. package/dist/menu/MenuItemButton.d.ts +0 -1
  209. package/dist/menu/useMenuBarProvider.d.ts +0 -1
  210. package/dist/movement/useKeyboardMovementProvider.d.ts +0 -1
  211. package/dist/navigation/NavGroup.d.ts +0 -2
  212. package/dist/navigation/NavGroup.js +0 -2
  213. package/dist/navigation/NavGroup.js.map +1 -1
  214. package/dist/navigation/NavItem.d.ts +0 -2
  215. package/dist/navigation/NavItem.js +0 -2
  216. package/dist/navigation/NavItem.js.map +1 -1
  217. package/dist/navigation/NavSubheader.d.ts +0 -3
  218. package/dist/navigation/NavSubheader.js +0 -2
  219. package/dist/navigation/NavSubheader.js.map +1 -1
  220. package/dist/progress/CircularProgress.d.ts +0 -2
  221. package/dist/progress/CircularProgress.js +0 -2
  222. package/dist/progress/CircularProgress.js.map +1 -1
  223. package/dist/progress/LinearProgress.d.ts +0 -2
  224. package/dist/progress/LinearProgress.js +0 -2
  225. package/dist/progress/LinearProgress.js.map +1 -1
  226. package/dist/responsive-item/ResponsiveItemContainer.d.ts +0 -2
  227. package/dist/responsive-item/ResponsiveItemContainer.js +0 -2
  228. package/dist/responsive-item/ResponsiveItemContainer.js.map +1 -1
  229. package/dist/responsive-item/ResponsiveItemOverlay.d.ts +0 -2
  230. package/dist/responsive-item/ResponsiveItemOverlay.js +0 -2
  231. package/dist/responsive-item/ResponsiveItemOverlay.js.map +1 -1
  232. package/dist/segmented-button/SegmentedButtonContainer.d.ts +0 -2
  233. package/dist/segmented-button/SegmentedButtonContainer.js +0 -2
  234. package/dist/segmented-button/SegmentedButtonContainer.js.map +1 -1
  235. package/dist/sheet/Sheet.d.ts +30 -16
  236. package/dist/sheet/Sheet.js +24 -14
  237. package/dist/sheet/Sheet.js.map +1 -1
  238. package/dist/sheet/styles.d.ts +29 -0
  239. package/dist/sheet/styles.js +13 -0
  240. package/dist/sheet/styles.js.map +1 -1
  241. package/dist/snackbar/ToastActionButton.d.ts +0 -1
  242. package/dist/snackbar/ToastCloseButton.d.ts +0 -1
  243. package/dist/snackbar/ToastManager.js.map +1 -1
  244. package/dist/snackbar/useCurrentToastActions.d.ts +0 -1
  245. package/dist/suspense/CircularProgressSuspense.d.ts +0 -2
  246. package/dist/suspense/CircularProgressSuspense.js +0 -2
  247. package/dist/suspense/CircularProgressSuspense.js.map +1 -1
  248. package/dist/suspense/NullSuspense.d.ts +0 -2
  249. package/dist/suspense/NullSuspense.js +0 -2
  250. package/dist/suspense/NullSuspense.js.map +1 -1
  251. package/dist/table/TableCellContent.d.ts +0 -3
  252. package/dist/table/TableCellContent.js +0 -3
  253. package/dist/table/TableCellContent.js.map +1 -1
  254. package/dist/table/TableConfigurationProvider.d.ts +0 -1
  255. package/dist/tabs/Tab.d.ts +3 -0
  256. package/dist/tabs/Tab.js.map +1 -1
  257. package/dist/tabs/TabListScrollButton.js +5 -1
  258. package/dist/tabs/TabListScrollButton.js.map +1 -1
  259. package/dist/tabs/_tabs.scss +21 -3
  260. package/dist/tabs/tabListScrollButtonStyles.d.ts +2 -0
  261. package/dist/tabs/tabListScrollButtonStyles.js +9 -5
  262. package/dist/tabs/tabListScrollButtonStyles.js.map +1 -1
  263. package/dist/tabs/useTabList.d.ts +2 -0
  264. package/dist/tabs/useTabList.js +4 -2
  265. package/dist/tabs/useTabList.js.map +1 -1
  266. package/dist/tabs/useTabs.d.ts +33 -11
  267. package/dist/tabs/useTabs.js +9 -3
  268. package/dist/tabs/useTabs.js.map +1 -1
  269. package/dist/test-utils/IntersectionObserver.js.map +1 -1
  270. package/dist/test-utils/data-testid.d.ts +0 -1
  271. package/dist/theme/useColorScheme.d.ts +0 -1
  272. package/dist/transition/SlideContainer.d.ts +2 -48
  273. package/dist/transition/SlideContainer.js +2 -48
  274. package/dist/transition/SlideContainer.js.map +1 -1
  275. package/dist/tree/DefaultTreeItemRenderer.d.ts +2 -3
  276. package/dist/tree/DefaultTreeItemRenderer.js +1 -1
  277. package/dist/tree/DefaultTreeItemRenderer.js.map +1 -1
  278. package/dist/tree/Tree.d.ts +3 -4
  279. package/dist/tree/Tree.js.map +1 -1
  280. package/dist/tree/TreeItem.d.ts +10 -3
  281. package/dist/tree/TreeItem.js +5 -2
  282. package/dist/tree/TreeItem.js.map +1 -1
  283. package/dist/tree/types.d.ts +11 -6
  284. package/dist/tree/types.js +1 -26
  285. package/dist/tree/types.js.map +1 -1
  286. package/dist/tree/useTree.d.ts +3 -3
  287. package/dist/tree/useTree.js.map +1 -1
  288. package/dist/tree/useTreeExpansion.d.ts +3 -3
  289. package/dist/tree/useTreeExpansion.js.map +1 -1
  290. package/dist/tree/useTreeSelection.d.ts +3 -3
  291. package/dist/tree/useTreeSelection.js.map +1 -1
  292. package/dist/typography/SrOnly.d.ts +2 -1
  293. package/dist/typography/SrOnly.js +2 -1
  294. package/dist/typography/SrOnly.js.map +1 -1
  295. package/dist/typography/TextContainer.d.ts +0 -2
  296. package/dist/typography/TextContainer.js +0 -2
  297. package/dist/typography/TextContainer.js.map +1 -1
  298. package/dist/typography/Typography.d.ts +0 -2
  299. package/dist/typography/Typography.js +0 -2
  300. package/dist/typography/Typography.js.map +1 -1
  301. package/dist/typography/WritingDirectionProvider.d.ts +2 -2
  302. package/dist/typography/WritingDirectionProvider.js +2 -2
  303. package/dist/typography/WritingDirectionProvider.js.map +1 -1
  304. package/dist/useResizeListener.d.ts +7 -1
  305. package/dist/useResizeListener.js.map +1 -1
  306. package/dist/useResizeObserver.d.ts +3 -3
  307. package/dist/useResizeObserver.js.map +1 -1
  308. package/dist/useToggle.d.ts +4 -4
  309. package/dist/useToggle.js +1 -1
  310. package/dist/useToggle.js.map +1 -1
  311. package/dist/window-splitter/WindowSplitter.d.ts +2 -2
  312. package/dist/window-splitter/WindowSplitter.js +2 -2
  313. package/dist/window-splitter/WindowSplitter.js.map +1 -1
  314. package/package.json +15 -15
  315. package/src/RootHtml.tsx +0 -2
  316. package/src/app-bar/AppBar.tsx +0 -2
  317. package/src/app-bar/AppBarTitle.tsx +0 -2
  318. package/src/avatar/Avatar.tsx +0 -2
  319. package/src/badge/Badge.tsx +1 -3
  320. package/src/box/Box.tsx +0 -2
  321. package/src/button/ButtonUnstyled.tsx +0 -2
  322. package/src/card/Card.tsx +0 -2
  323. package/src/card/CardContent.tsx +0 -2
  324. package/src/card/CardFooter.tsx +0 -2
  325. package/src/card/CardHeader.tsx +0 -2
  326. package/src/card/CardSubtitle.tsx +0 -2
  327. package/src/card/CardTitle.tsx +0 -2
  328. package/src/chip/Chip.tsx +0 -2
  329. package/src/dialog/DialogContainer.tsx +0 -2
  330. package/src/dialog/DialogContent.tsx +3 -3
  331. package/src/dialog/DialogFooter.tsx +2 -3
  332. package/src/dialog/DialogHeader.tsx +3 -3
  333. package/src/dialog/DialogTitle.tsx +3 -3
  334. package/src/divider/Divider.tsx +0 -2
  335. package/src/expansion-panel/ExpansionList.tsx +1 -1
  336. package/src/expansion-panel/ExpansionPanel.tsx +9 -38
  337. package/src/expansion-panel/ExpansionPanelHeader.tsx +0 -1
  338. package/src/expansion-panel/expansionPanelStyles.ts +33 -0
  339. package/src/form/Fieldset.tsx +0 -2
  340. package/src/form/FormMessage.tsx +0 -2
  341. package/src/form/FormMessageContainer.tsx +0 -1
  342. package/src/form/FormMessageCounter.tsx +0 -2
  343. package/src/form/InputToggle.tsx +1 -1
  344. package/src/form/InputToggleIcon.tsx +0 -2
  345. package/src/form/Label.tsx +0 -2
  346. package/src/form/Legend.tsx +0 -2
  347. package/src/form/NativeSelect.tsx +0 -2
  348. package/src/form/Option.tsx +1 -1
  349. package/src/form/SelectedOption.tsx +0 -2
  350. package/src/form/SliderContainer.tsx +0 -2
  351. package/src/form/SliderMark.tsx +0 -2
  352. package/src/form/SliderMarkLabel.tsx +0 -2
  353. package/src/form/SliderTrack.tsx +0 -2
  354. package/src/form/SliderValueMarks.tsx +0 -2
  355. package/src/form/Switch.tsx +0 -2
  356. package/src/form/SwitchTrack.tsx +2 -1
  357. package/src/form/TextField.tsx +0 -2
  358. package/src/form/TextFieldAddon.tsx +1 -3
  359. package/src/icon/FontIcon.tsx +0 -2
  360. package/src/icon/IconRotator.tsx +0 -2
  361. package/src/icon/MaterialIcon.tsx +0 -2
  362. package/src/icon/MaterialSymbol.tsx +0 -1
  363. package/src/icon/SVGIcon.tsx +0 -2
  364. package/src/icon/TextIconSpacing.tsx +0 -2
  365. package/src/icon/styles.ts +1 -1
  366. package/src/interaction/RippleContainer.tsx +0 -2
  367. package/src/layout/LayoutNav.tsx +3 -2
  368. package/src/layout/useHorizontalLayoutTransition.ts +1 -1
  369. package/src/layout/useLayoutTree.ts +2 -2
  370. package/src/link/Link.tsx +0 -2
  371. package/src/list/List.tsx +1 -33
  372. package/src/list/ListItem.tsx +0 -17
  373. package/src/list/ListItemAddon.tsx +0 -2
  374. package/src/list/ListItemChildren.tsx +0 -2
  375. package/src/list/ListItemText.tsx +0 -2
  376. package/src/list/ListSubheader.tsx +3 -2
  377. package/src/list/getListItemHeight.ts +2 -2
  378. package/src/list/listItemStyles.ts +21 -4
  379. package/src/list/listStyles.ts +31 -0
  380. package/src/list/types.ts +9 -3
  381. package/src/media-queries/AppSizeProvider.tsx +8 -0
  382. package/src/media-queries/useMediaQuery.ts +1 -1
  383. package/src/menu/MenuConfigurationProvider.tsx +2 -2
  384. package/src/navigation/NavGroup.tsx +0 -2
  385. package/src/navigation/NavItem.tsx +0 -2
  386. package/src/navigation/NavSubheader.tsx +0 -2
  387. package/src/progress/CircularProgress.tsx +0 -2
  388. package/src/progress/LinearProgress.tsx +0 -2
  389. package/src/responsive-item/ResponsiveItemContainer.tsx +0 -2
  390. package/src/responsive-item/ResponsiveItemOverlay.tsx +0 -2
  391. package/src/segmented-button/SegmentedButtonContainer.tsx +0 -2
  392. package/src/sheet/Sheet.tsx +36 -33
  393. package/src/sheet/styles.ts +50 -0
  394. package/src/suspense/CircularProgressSuspense.tsx +0 -2
  395. package/src/suspense/NullSuspense.tsx +0 -2
  396. package/src/table/TableCellContent.tsx +0 -3
  397. package/src/tabs/Tab.tsx +3 -0
  398. package/src/tabs/TabListScrollButton.tsx +9 -2
  399. package/src/tabs/tabListScrollButtonStyles.ts +9 -5
  400. package/src/tabs/useTabList.ts +4 -0
  401. package/src/tabs/useTabs.ts +61 -14
  402. package/src/test-utils/IntersectionObserver.ts +1 -1
  403. package/src/transition/SlideContainer.tsx +2 -48
  404. package/src/tree/DefaultTreeItemRenderer.tsx +3 -4
  405. package/src/tree/Tree.tsx +4 -6
  406. package/src/tree/TreeItem.tsx +11 -4
  407. package/src/tree/types.ts +16 -6
  408. package/src/tree/useTree.ts +3 -3
  409. package/src/tree/useTreeExpansion.ts +3 -3
  410. package/src/tree/useTreeSelection.ts +3 -3
  411. package/src/typography/SrOnly.tsx +2 -1
  412. package/src/typography/TextContainer.tsx +0 -2
  413. package/src/typography/Typography.tsx +0 -2
  414. package/src/typography/WritingDirectionProvider.tsx +2 -2
  415. package/src/useResizeListener.ts +7 -1
  416. package/src/useResizeObserver.ts +3 -3
  417. package/src/useToggle.ts +4 -4
  418. package/src/window-splitter/WindowSplitter.tsx +2 -2
  419. package/.eslintrc.cjs +0 -34
  420. package/.stylelintrc.json +0 -14
  421. package/.swcrc +0 -17
  422. package/.turbo/turbo-build.log +0 -22
  423. package/.turbo/turbo-lint.log +0 -12
  424. package/.turbo/turbo-test.log +0 -5516
  425. package/.turbo/turbo-typecheck.log +0 -4
  426. package/CHANGELOG.md +0 -323
  427. package/coverage/clover.xml +0 -842
  428. package/coverage/coverage-final.json +0 -6
  429. package/coverage/lcov-report/autocomplete/Autocomplete.tsx.html +0 -1033
  430. package/coverage/lcov-report/autocomplete/AutocompleteClearButton.tsx.html +0 -262
  431. package/coverage/lcov-report/autocomplete/FilterAutocompleteOptions.tsx.html +0 -364
  432. package/coverage/lcov-report/autocomplete/index.html +0 -146
  433. package/coverage/lcov-report/base.css +0 -224
  434. package/coverage/lcov-report/block-navigation.js +0 -87
  435. package/coverage/lcov-report/button/Button.tsx.html +0 -676
  436. package/coverage/lcov-report/button/index.html +0 -116
  437. package/coverage/lcov-report/card/Card.tsx.html +0 -349
  438. package/coverage/lcov-report/card/CardSubtitle.tsx.html +0 -265
  439. package/coverage/lcov-report/card/index.html +0 -146
  440. package/coverage/lcov-report/card/styles.ts.html +0 -682
  441. package/coverage/lcov-report/createHorizontalPosition.ts.html +0 -1075
  442. package/coverage/lcov-report/createVerticalPosition.ts.html +0 -997
  443. package/coverage/lcov-report/favicon.png +0 -0
  444. package/coverage/lcov-report/form/Option.tsx.html +0 -727
  445. package/coverage/lcov-report/form/index.html +0 -131
  446. package/coverage/lcov-report/form/useListboxProvider.ts.html +0 -253
  447. package/coverage/lcov-report/index.html +0 -146
  448. package/coverage/lcov-report/prettify.css +0 -1
  449. package/coverage/lcov-report/prettify.js +0 -2
  450. package/coverage/lcov-report/searching/fuzzy.ts.html +0 -607
  451. package/coverage/lcov-report/searching/index.html +0 -116
  452. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  453. package/coverage/lcov-report/sorter.js +0 -196
  454. package/coverage/lcov-report/src/card/Card.tsx.html +0 -349
  455. package/coverage/lcov-report/src/card/CardSubtitle.tsx.html +0 -277
  456. package/coverage/lcov-report/src/card/index.html +0 -146
  457. package/coverage/lcov-report/src/card/styles.ts.html +0 -682
  458. package/coverage/lcov-report/src/cssUtils.ts.html +0 -787
  459. package/coverage/lcov-report/src/index.html +0 -116
  460. package/coverage/lcov-report/src/transition/index.html +0 -116
  461. package/coverage/lcov-report/src/transition/useCSSTransition.ts.html +0 -766
  462. package/coverage/lcov-report/transition/index.html +0 -116
  463. package/coverage/lcov-report/transition/useCSSTransition.ts.html +0 -766
  464. package/coverage/lcov-report/typography/SrOnly.tsx.html +0 -325
  465. package/coverage/lcov-report/typography/index.html +0 -116
  466. package/coverage/lcov-report/utils.ts.html +0 -1225
  467. package/coverage/lcov.info +0 -952
  468. package/jest.config.ts +0 -68
  469. package/jest.setup.ts +0 -3
  470. package/scripts/copySassFiles.ts +0 -70
  471. package/scripts/getExportMap.ts +0 -66
  472. package/scripts/tsconfig.json +0 -18
  473. package/src/__tests__/NoSsr.node.tsx +0 -26
  474. package/src/__tests__/NoSsr.tsx +0 -89
  475. package/src/__tests__/RootHtml.node.tsx +0 -46
  476. package/src/__tests__/__snapshots__/RootHtml.node.tsx.snap +0 -19
  477. package/src/__tests__/useAsyncFunction.tsx +0 -124
  478. package/src/__tests__/useDebouncedFunction.tsx +0 -108
  479. package/src/__tests__/useDropzone.tsx +0 -131
  480. package/src/__tests__/useElementSize.tsx +0 -181
  481. package/src/__tests__/useEnsuredId.tsx +0 -25
  482. package/src/__tests__/useEnsuredState.tsx +0 -74
  483. package/src/__tests__/useHtmlClassName.tsx +0 -54
  484. package/src/__tests__/useLocalStorage.tsx +0 -377
  485. package/src/__tests__/useOrientation.node.tsx +0 -20
  486. package/src/__tests__/useOrientation.tsx +0 -63
  487. package/src/__tests__/useResizeObserver.tsx +0 -258
  488. package/src/__tests__/useThrottledFunction.tsx +0 -226
  489. package/src/__tests__/useToggle.tsx +0 -78
  490. package/src/__tests__/useWindowSize.node.tsx +0 -56
  491. package/src/__tests__/useWindowSize.tsx +0 -155
  492. package/src/_box-shadows.scss +0 -219
  493. package/src/_core.scss +0 -432
  494. package/src/_utils.scss +0 -348
  495. package/src/app-bar/__tests__/AppBar.tsx +0 -121
  496. package/src/app-bar/__tests__/AppBarTitle.tsx +0 -39
  497. package/src/app-bar/__tests__/__snapshots__/AppBar.tsx.snap +0 -186
  498. package/src/app-bar/__tests__/__snapshots__/AppBarTitle.tsx.snap +0 -47
  499. package/src/app-bar/_app-bar.scss +0 -248
  500. package/src/autocomplete/__tests__/Autocomplete.tsx +0 -458
  501. package/src/autocomplete/__tests__/__snapshots__/Autocomplete.tsx.snap +0 -144
  502. package/src/autocomplete/_autocomplete.scss +0 -75
  503. package/src/avatar/__tests__/Avatar.tsx +0 -75
  504. package/src/avatar/__tests__/__snapshots__/Avatar.tsx.snap +0 -73
  505. package/src/avatar/_avatar.scss +0 -157
  506. package/src/badge/__tests__/Badge.tsx +0 -42
  507. package/src/badge/__tests__/__snapshots__/Badge.tsx.snap +0 -54
  508. package/src/badge/_badge.scss +0 -145
  509. package/src/box/__tests__/Box.tsx +0 -158
  510. package/src/box/__tests__/__snapshots__/Box.tsx.snap +0 -544
  511. package/src/box/_box.scss +0 -168
  512. package/src/button/__tests__/AsyncButton.tsx +0 -211
  513. package/src/button/__tests__/Button.tsx +0 -198
  514. package/src/button/__tests__/ButtonUnstyled.tsx +0 -37
  515. package/src/button/__tests__/TooltippedButton.tsx +0 -60
  516. package/src/button/__tests__/__snapshots__/AsyncButton.tsx.snap +0 -418
  517. package/src/button/__tests__/__snapshots__/Button.tsx.snap +0 -573
  518. package/src/button/__tests__/__snapshots__/ButtonUnstyled.tsx.snap +0 -22
  519. package/src/button/__tests__/__snapshots__/TooltippedButton.tsx.snap +0 -26
  520. package/src/button/__tests__/__snapshots__/buttonStyles.ts.snap +0 -11
  521. package/src/button/__tests__/buttonStyles.ts +0 -15
  522. package/src/button/_button.scss +0 -330
  523. package/src/card/__tests__/Card.tsx +0 -37
  524. package/src/card/__tests__/CardContent.tsx +0 -40
  525. package/src/card/__tests__/CardFooter.tsx +0 -34
  526. package/src/card/__tests__/CardHeader.tsx +0 -66
  527. package/src/card/__tests__/CardSubtitle.tsx +0 -30
  528. package/src/card/__tests__/CardTitle.tsx +0 -30
  529. package/src/card/__tests__/ClickableCard.tsx +0 -66
  530. package/src/card/__tests__/__snapshots__/Card.tsx.snap +0 -40
  531. package/src/card/__tests__/__snapshots__/CardContent.tsx.snap +0 -50
  532. package/src/card/__tests__/__snapshots__/CardFooter.tsx.snap +0 -30
  533. package/src/card/__tests__/__snapshots__/CardHeader.tsx.snap +0 -74
  534. package/src/card/__tests__/__snapshots__/CardSubtitle.tsx.snap +0 -18
  535. package/src/card/__tests__/__snapshots__/CardTitle.tsx.snap +0 -18
  536. package/src/card/__tests__/__snapshots__/ClickableCard.tsx.snap +0 -20
  537. package/src/card/__tests__/__snapshots__/styles.ts.snap +0 -13
  538. package/src/card/__tests__/styles.ts +0 -45
  539. package/src/card/_card.scss +0 -189
  540. package/src/chip/__tests__/Chip.tsx +0 -327
  541. package/src/chip/__tests__/__snapshots__/Chip.tsx.snap +0 -597
  542. package/src/chip/__tests__/__snapshots__/styles.ts.snap +0 -5
  543. package/src/chip/__tests__/styles.ts +0 -14
  544. package/src/chip/_chip.scss +0 -324
  545. package/src/dialog/__tests__/Dialog.tsx +0 -316
  546. package/src/dialog/__tests__/DialogContent.tsx +0 -53
  547. package/src/dialog/__tests__/DialogFooter.tsx +0 -70
  548. package/src/dialog/__tests__/DialogHeader.tsx +0 -37
  549. package/src/dialog/__tests__/DialogTitle.tsx +0 -41
  550. package/src/dialog/__tests__/__snapshots__/Dialog.tsx.snap +0 -84
  551. package/src/dialog/__tests__/__snapshots__/DialogContent.tsx.snap +0 -36
  552. package/src/dialog/__tests__/__snapshots__/DialogFooter.tsx.snap +0 -186
  553. package/src/dialog/__tests__/__snapshots__/DialogHeader.tsx.snap +0 -18
  554. package/src/dialog/__tests__/__snapshots__/DialogTitle.tsx.snap +0 -26
  555. package/src/dialog/_dialog.scss +0 -273
  556. package/src/divider/__tests__/Divider.tsx +0 -36
  557. package/src/divider/__tests__/__snapshots__/Divider.tsx.snap +0 -26
  558. package/src/divider/_divider.scss +0 -124
  559. package/src/draggable/__tests__/__snapshots__/useDraggable.tsx.snap +0 -49
  560. package/src/draggable/__tests__/useDraggable.tsx +0 -540
  561. package/src/draggable/_draggable.scss +0 -29
  562. package/src/expansion-panel/__tests__/ExpansionPanel.tsx +0 -290
  563. package/src/expansion-panel/__tests__/__snapshots__/ExpansionPanel.tsx.snap +0 -197
  564. package/src/expansion-panel/_expansion-panel.scss +0 -107
  565. package/src/focus/__tests__/useFocusContainer.tsx +0 -280
  566. package/src/form/__tests__/Checkbox.tsx +0 -42
  567. package/src/form/__tests__/Fieldset.tsx +0 -44
  568. package/src/form/__tests__/FileInput.tsx +0 -120
  569. package/src/form/__tests__/Label.tsx +0 -69
  570. package/src/form/__tests__/Legend.tsx +0 -34
  571. package/src/form/__tests__/MenuItemCheckbox.tsx +0 -53
  572. package/src/form/__tests__/MenuItemRadio.tsx +0 -53
  573. package/src/form/__tests__/Radio.tsx +0 -35
  574. package/src/form/__tests__/Select.tsx +0 -439
  575. package/src/form/__tests__/Switch.tsx +0 -152
  576. package/src/form/__tests__/TextArea.tsx +0 -433
  577. package/src/form/__tests__/TextField.tsx +0 -195
  578. package/src/form/__tests__/__snapshots__/Checkbox.tsx.snap +0 -99
  579. package/src/form/__tests__/__snapshots__/Fieldset.tsx.snap +0 -58
  580. package/src/form/__tests__/__snapshots__/FileInput.tsx.snap +0 -612
  581. package/src/form/__tests__/__snapshots__/Label.tsx.snap +0 -140
  582. package/src/form/__tests__/__snapshots__/Legend.tsx.snap +0 -30
  583. package/src/form/__tests__/__snapshots__/MenuItemCheckbox.tsx.snap +0 -96
  584. package/src/form/__tests__/__snapshots__/MenuItemRadio.tsx.snap +0 -96
  585. package/src/form/__tests__/__snapshots__/Radio.tsx.snap +0 -99
  586. package/src/form/__tests__/__snapshots__/Select.tsx.snap +0 -492
  587. package/src/form/__tests__/__snapshots__/Switch.tsx.snap +0 -428
  588. package/src/form/__tests__/__snapshots__/TextArea.tsx.snap +0 -548
  589. package/src/form/__tests__/__snapshots__/TextField.tsx.snap +0 -279
  590. package/src/form/__tests__/__snapshots__/useCheckboxGroup.tsx.snap +0 -481
  591. package/src/form/__tests__/__snapshots__/useRadioGroup.tsx.snap +0 -704
  592. package/src/form/__tests__/useCheckboxGroup.tsx +0 -292
  593. package/src/form/__tests__/useFileUpload.tsx +0 -289
  594. package/src/form/__tests__/useFormReset.tsx +0 -194
  595. package/src/form/__tests__/useRadioGroup.tsx +0 -227
  596. package/src/form/__tests__/utils.ts +0 -247
  597. package/src/form/_form.scss +0 -2190
  598. package/src/icon/__tests__/FontIcon.tsx +0 -45
  599. package/src/icon/__tests__/IconRotator.tsx +0 -120
  600. package/src/icon/__tests__/MaterialIcon.tsx +0 -79
  601. package/src/icon/__tests__/MaterialSymbol.tsx +0 -100
  602. package/src/icon/__tests__/SVGIcon.tsx +0 -40
  603. package/src/icon/__tests__/TextIconSpacing.tsx +0 -108
  604. package/src/icon/__tests__/__snapshots__/FontIcon.tsx.snap +0 -35
  605. package/src/icon/__tests__/__snapshots__/IconRotator.tsx.snap +0 -165
  606. package/src/icon/__tests__/__snapshots__/MaterialIcon.tsx.snap +0 -82
  607. package/src/icon/__tests__/__snapshots__/MaterialSymbol.tsx.snap +0 -42
  608. package/src/icon/__tests__/__snapshots__/SVGIcon.tsx.snap +0 -47
  609. package/src/icon/__tests__/__snapshots__/TextIconSpacing.tsx.snap +0 -101
  610. package/src/icon/__tests__/__snapshots__/styles.ts.snap +0 -29
  611. package/src/icon/__tests__/styles.ts +0 -28
  612. package/src/icon/_icon.scss +0 -213
  613. package/src/interaction/__tests__/UserInteractionModeProvider.tsx +0 -121
  614. package/src/interaction/__tests__/__snapshots__/useHigherContrastChildren.tsx.snap +0 -79
  615. package/src/interaction/__tests__/useHigherContrastChildren.tsx +0 -97
  616. package/src/interaction/_interaction.scss +0 -436
  617. package/src/layout/__tests__/LayoutAppBar.tsx +0 -117
  618. package/src/layout/__tests__/LayoutNav.tsx +0 -78
  619. package/src/layout/__tests__/LayoutWindowSplitter.tsx +0 -63
  620. package/src/layout/__tests__/Main.tsx +0 -51
  621. package/src/layout/__tests__/__snapshots__/LayoutAppBar.tsx.snap +0 -78
  622. package/src/layout/__tests__/__snapshots__/LayoutNav.tsx.snap +0 -31
  623. package/src/layout/__tests__/__snapshots__/LayoutWindowSplitter.tsx.snap +0 -60
  624. package/src/layout/__tests__/__snapshots__/Main.tsx.snap +0 -32
  625. package/src/layout/__tests__/__snapshots__/useExpandableLayout.tsx.snap +0 -116
  626. package/src/layout/__tests__/__snapshots__/useLayoutTree.tsx.snap +0 -676
  627. package/src/layout/__tests__/__snapshots__/useResizableLayout.tsx.snap +0 -95
  628. package/src/layout/__tests__/__snapshots__/useTemporaryLayout.tsx.snap +0 -141
  629. package/src/layout/__tests__/useExpandableLayout.tsx +0 -279
  630. package/src/layout/__tests__/useLayoutTree.tsx +0 -212
  631. package/src/layout/__tests__/useResizableLayout.tsx +0 -170
  632. package/src/layout/__tests__/useTemporaryLayout.tsx +0 -109
  633. package/src/layout/_layout.scss +0 -163
  634. package/src/link/__tests__/Link.tsx +0 -31
  635. package/src/link/__tests__/SkipToMainContent.tsx +0 -125
  636. package/src/link/__tests__/__snapshots__/Link.tsx.snap +0 -20
  637. package/src/link/__tests__/__snapshots__/SkipToMainContent.tsx.snap +0 -22
  638. package/src/link/_link.scss +0 -149
  639. package/src/list/__tests__/List.tsx +0 -58
  640. package/src/list/__tests__/ListItem.tsx +0 -280
  641. package/src/list/__tests__/ListItemLink.tsx +0 -89
  642. package/src/list/__tests__/ListSubheader.tsx +0 -81
  643. package/src/list/__tests__/__snapshots__/List.tsx.snap +0 -41
  644. package/src/list/__tests__/__snapshots__/ListItem.tsx.snap +0 -414
  645. package/src/list/__tests__/__snapshots__/ListItemLink.tsx.snap +0 -73
  646. package/src/list/__tests__/__snapshots__/ListSubheader.tsx.snap +0 -99
  647. package/src/list/__tests__/getListItemHeight.ts +0 -176
  648. package/src/list/_list.scss +0 -322
  649. package/src/media-queries/__tests__/AppSizeProvider.node.tsx +0 -37
  650. package/src/media-queries/__tests__/AppSizeProvider.tsx +0 -119
  651. package/src/media-queries/__tests__/useMediaQuery.node.tsx +0 -20
  652. package/src/media-queries/__tests__/useMediaQuery.tsx +0 -59
  653. package/src/media-queries/_media-queries.scss +0 -63
  654. package/src/menu/__tests__/DropdownMenu.tsx +0 -627
  655. package/src/menu/__tests__/MenuBar.tsx +0 -354
  656. package/src/menu/__tests__/MenuItemCircularProgress.tsx +0 -39
  657. package/src/menu/__tests__/MenuVisibilityProvider.tsx +0 -34
  658. package/src/menu/__tests__/__snapshots__/DropdownMenu.tsx.snap +0 -292
  659. package/src/menu/__tests__/__snapshots__/MenuBar.tsx.snap +0 -87
  660. package/src/menu/__tests__/__snapshots__/MenuItemCircularProgress.tsx.snap +0 -68
  661. package/src/menu/__tests__/__snapshots__/useContextMenu.tsx.snap +0 -54
  662. package/src/menu/__tests__/useContextMenu.tsx +0 -41
  663. package/src/menu/__tests__/utils.ts +0 -121
  664. package/src/menu/_menu.scss +0 -116
  665. package/src/movement/__tests__/findMatchIndex.ts +0 -244
  666. package/src/movement/__tests__/utils.ts +0 -710
  667. package/src/navigation/__tests__/Navigation.tsx +0 -97
  668. package/src/navigation/__tests__/__snapshots__/Navigation.tsx.snap +0 -165
  669. package/src/navigation/_navigation.scss +0 -99
  670. package/src/overlay/__tests__/Overlay.tsx +0 -198
  671. package/src/overlay/__tests__/__snapshots__/Overlay.tsx.snap +0 -77
  672. package/src/overlay/_overlay.scss +0 -74
  673. package/src/portal/__tests__/PortalContainerProvider.node.tsx +0 -26
  674. package/src/portal/__tests__/PortalContainerProvider.tsx +0 -84
  675. package/src/positioning/__tests__/__snapshots__/useFixedPositioning.tsx.snap +0 -87
  676. package/src/positioning/__tests__/createHorizontalPosition.ts +0 -777
  677. package/src/positioning/__tests__/createVerticalPosition.ts +0 -464
  678. package/src/positioning/__tests__/useFixedPositioning.tsx +0 -205
  679. package/src/positioning/__tests__/utils.ts +0 -1311
  680. package/src/progress/__tests__/CircularProgress.tsx +0 -153
  681. package/src/progress/__tests__/LinearProgress.tsx +0 -131
  682. package/src/progress/__tests__/__snapshots__/CircularProgress.tsx.snap +0 -499
  683. package/src/progress/__tests__/__snapshots__/LinearProgress.tsx.snap +0 -321
  684. package/src/progress/__tests__/getProgressA11y.ts +0 -16
  685. package/src/progress/_progress.scss +0 -577
  686. package/src/responsive-item/__tests__/ResponsiveItemContainer.tsx +0 -56
  687. package/src/responsive-item/__tests__/ResponsiveItemOverlay.tsx +0 -66
  688. package/src/responsive-item/__tests__/__snapshots__/ResponsiveItemContainer.tsx.snap +0 -85
  689. package/src/responsive-item/__tests__/__snapshots__/ResponsiveItemOverlay.tsx.snap +0 -151
  690. package/src/responsive-item/__tests__/__snapshots__/styles.ts.snap +0 -9
  691. package/src/responsive-item/__tests__/styles.ts +0 -32
  692. package/src/responsive-item/_responsive-item.scss +0 -199
  693. package/src/searching/__tests__/caseInsensitive.ts +0 -165
  694. package/src/searching/__tests__/fuzzy.ts +0 -169
  695. package/src/searching/__tests__/toSearchQuery.ts +0 -21
  696. package/src/searching/__tests__/useFuzzyMatch.tsx +0 -200
  697. package/src/segmented-button/__tests__/SegmentedButton.tsx +0 -61
  698. package/src/segmented-button/__tests__/SegmentedButtonContainer.tsx +0 -38
  699. package/src/segmented-button/__tests__/__snapshots__/SegmentedButton.tsx.snap +0 -116
  700. package/src/segmented-button/__tests__/__snapshots__/SegmentedButtonContainer.tsx.snap +0 -22
  701. package/src/segmented-button/_segmented-button.scss +0 -208
  702. package/src/sheet/_sheet.scss +0 -189
  703. package/src/snackbar/__tests__/Snackbar.tsx +0 -85
  704. package/src/snackbar/__tests__/Toast.tsx +0 -105
  705. package/src/snackbar/__tests__/ToastActionButton.tsx +0 -112
  706. package/src/snackbar/__tests__/ToastCloseButton.tsx +0 -140
  707. package/src/snackbar/__tests__/ToastContent.tsx +0 -88
  708. package/src/snackbar/__tests__/ToastManagerProvider.tsx +0 -852
  709. package/src/snackbar/__tests__/__snapshots__/Snackbar.tsx.snap +0 -176
  710. package/src/snackbar/__tests__/__snapshots__/Toast.tsx.snap +0 -52
  711. package/src/snackbar/__tests__/__snapshots__/ToastActionButton.tsx.snap +0 -36
  712. package/src/snackbar/__tests__/__snapshots__/ToastCloseButton.tsx.snap +0 -104
  713. package/src/snackbar/__tests__/__snapshots__/ToastContent.tsx.snap +0 -26
  714. package/src/snackbar/__tests__/__snapshots__/ToastManagerProvider.tsx.snap +0 -290
  715. package/src/snackbar/_snackbar.scss +0 -266
  716. package/src/suspense/__tests__/CircularProgressSuspense.tsx +0 -90
  717. package/src/suspense/__tests__/NullSuspense.tsx +0 -46
  718. package/src/suspense/__tests__/__snapshots__/CircularProgressSuspense.tsx.snap +0 -24
  719. package/src/table/__tests__/Table.tsx +0 -315
  720. package/src/table/__tests__/TableBody.tsx +0 -52
  721. package/src/table/__tests__/TableCheckbox.tsx +0 -89
  722. package/src/table/__tests__/TableContainer.tsx +0 -31
  723. package/src/table/__tests__/TableRadio.tsx +0 -112
  724. package/src/table/__tests__/TableRow.tsx +0 -63
  725. package/src/table/__tests__/__snapshots__/Table.tsx.snap +0 -2426
  726. package/src/table/__tests__/__snapshots__/TableBody.tsx.snap +0 -54
  727. package/src/table/__tests__/__snapshots__/TableCheckbox.tsx.snap +0 -142
  728. package/src/table/__tests__/__snapshots__/TableContainer.tsx.snap +0 -16
  729. package/src/table/__tests__/__snapshots__/TableRadio.tsx.snap +0 -138
  730. package/src/table/__tests__/__snapshots__/TableRow.tsx.snap +0 -56
  731. package/src/table/__tests__/__snapshots__/tableContainerStyles.ts.snap +0 -3
  732. package/src/table/__tests__/__snapshots__/tableRowStyles.ts.snap +0 -3
  733. package/src/table/__tests__/__snapshots__/tableStyles.ts.snap +0 -3
  734. package/src/table/__tests__/tableContainerStyles.ts +0 -8
  735. package/src/table/__tests__/tableRowStyles.ts +0 -8
  736. package/src/table/__tests__/tableStyles.ts +0 -8
  737. package/src/table/_table.scss +0 -447
  738. package/src/tabs/__tests__/Tab.tsx +0 -51
  739. package/src/tabs/__tests__/TabList.tsx +0 -640
  740. package/src/tabs/__tests__/__snapshots__/Tab.tsx.snap +0 -85
  741. package/src/tabs/__tests__/__snapshots__/TabList.tsx.snap +0 -51
  742. package/src/tabs/__tests__/useTabs.tsx +0 -212
  743. package/src/tabs/_tabs.scss +0 -273
  744. package/src/test-utils/__tests__/ResizeObserver.ts +0 -171
  745. package/src/theme/__tests__/LocalStorageColorSchemeProvider.tsx +0 -162
  746. package/src/theme/__tests__/ThemeProvider.tsx +0 -90
  747. package/src/theme/__tests__/__snapshots__/useCSSVariables.tsx.snap +0 -27
  748. package/src/theme/__tests__/__snapshots__/useColorSchemeMetaTag.tsx.snap +0 -15
  749. package/src/theme/__tests__/useCSSVariables.tsx +0 -177
  750. package/src/theme/__tests__/useColorSchemeMetaTag.tsx +0 -36
  751. package/src/theme/__tests__/utils.ts +0 -67
  752. package/src/theme/_a11y.scss +0 -114
  753. package/src/theme/_colors.scss +0 -1057
  754. package/src/theme/_theme.scss +0 -520
  755. package/src/tooltip/__tests__/Tooltip.tsx +0 -501
  756. package/src/tooltip/__tests__/TooltipHoverModeProvider.tsx +0 -94
  757. package/src/tooltip/__tests__/__snapshots__/Tooltip.tsx.snap +0 -34
  758. package/src/tooltip/__tests__/utils.ts +0 -94
  759. package/src/tooltip/_tooltip.scss +0 -155
  760. package/src/transition/__tests__/CSSTransition.tsx +0 -182
  761. package/src/transition/__tests__/Collapse.tsx +0 -209
  762. package/src/transition/__tests__/CrossFade.tsx +0 -227
  763. package/src/transition/__tests__/ScaleTransition.tsx +0 -204
  764. package/src/transition/__tests__/SkeletonPlaceholder.tsx +0 -72
  765. package/src/transition/__tests__/__snapshots__/CSSTransition.tsx.snap +0 -145
  766. package/src/transition/__tests__/__snapshots__/Collapse.tsx.snap +0 -224
  767. package/src/transition/__tests__/__snapshots__/CrossFade.tsx.snap +0 -240
  768. package/src/transition/__tests__/__snapshots__/ScaleTransition.tsx.snap +0 -239
  769. package/src/transition/__tests__/__snapshots__/SkeletonPlaceholder.tsx.snap +0 -24
  770. package/src/transition/__tests__/__snapshots__/useCollapseTransition.tsx.snap +0 -361
  771. package/src/transition/__tests__/__snapshots__/useCrossFadeTransition.tsx.snap +0 -258
  772. package/src/transition/__tests__/__snapshots__/useMaxWidthTransition.tsx.snap +0 -68
  773. package/src/transition/__tests__/__snapshots__/useScaleTransition.tsx.snap +0 -209
  774. package/src/transition/__tests__/useCSSTransition.tsx +0 -190
  775. package/src/transition/__tests__/useCollapseTransition.tsx +0 -316
  776. package/src/transition/__tests__/useCrossFadeTransition.tsx +0 -229
  777. package/src/transition/__tests__/useMaxWidthTransition.tsx +0 -123
  778. package/src/transition/__tests__/useScaleTransition.tsx +0 -212
  779. package/src/transition/__tests__/useTransition.tsx +0 -569
  780. package/src/transition/__tests__/utils.ts +0 -620
  781. package/src/transition/_transition.scss +0 -365
  782. package/src/tree/__tests__/Tree.tsx +0 -735
  783. package/src/tree/__tests__/TreeGroup.tsx +0 -76
  784. package/src/tree/__tests__/TreeItemExpander.tsx +0 -74
  785. package/src/tree/__tests__/__snapshots__/Tree.tsx.snap +0 -3618
  786. package/src/tree/__tests__/__snapshots__/TreeItemExpander.tsx.snap +0 -11
  787. package/src/tree/__tests__/utils.ts +0 -98
  788. package/src/tree/_tree.scss +0 -176
  789. package/src/typography/__tests__/SrOnly.tsx +0 -43
  790. package/src/typography/__tests__/TextContainer.tsx +0 -45
  791. package/src/typography/__tests__/Typography.tsx +0 -87
  792. package/src/typography/__tests__/WritingDirectionProvider.node.tsx +0 -27
  793. package/src/typography/__tests__/WritingDirectionProvider.tsx +0 -119
  794. package/src/typography/__tests__/__snapshots__/SrOnly.tsx.snap +0 -56
  795. package/src/typography/__tests__/__snapshots__/TextContainer.tsx.snap +0 -29
  796. package/src/typography/__tests__/__snapshots__/Typography.tsx.snap +0 -112
  797. package/src/typography/_typography.scss +0 -399
  798. package/src/utils/__tests__/RenderRecursively.tsx +0 -87
  799. package/src/utils/__tests__/__snapshots__/RenderRecursively.tsx.snap +0 -80
  800. package/src/utils/__tests__/applyRef.ts +0 -30
  801. package/src/utils/__tests__/bem.ts +0 -54
  802. package/src/utils/__tests__/getMiddleOfRange.ts +0 -12
  803. package/src/utils/__tests__/getPercentage.ts +0 -104
  804. package/src/utils/__tests__/getRangeDefaultValue.ts +0 -47
  805. package/src/utils/__tests__/getRangeSteps.ts +0 -14
  806. package/src/utils/__tests__/loop.ts +0 -50
  807. package/src/utils/__tests__/nearest.ts +0 -83
  808. package/src/utils/__tests__/parseCssLengthUnit.node.ts +0 -28
  809. package/src/utils/__tests__/parseCssLengthUnit.ts +0 -47
  810. package/src/utils/__tests__/wait.ts +0 -12
  811. package/src/utils/__tests__/withinRange.ts +0 -24
  812. package/src/window-splitter/_window-splitter.scss +0 -143
  813. package/tsconfig.json +0 -19
  814. package/tsconfig.types.json +0 -12
  815. package/tsdoc.json +0 -14
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/SliderMarkLabel.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { type ReactElement } from \"react\";\nimport {\n Typography,\n type CustomTypographyComponent,\n type TypographyProps,\n} from \"../typography/Typography.js\";\nimport { type TypographyType } from \"../typography/typographyStyles.js\";\nimport { bem } from \"../utils/bem.js\";\n\nconst styles = bem(\"rmd-slider-mark-label\");\n\n/**\n * @since 6.0.0\n */\nexport interface CustomizableSliderMarkLabelProps extends TypographyProps {\n /** @defaultValue `\"span\"` */\n as?: CustomTypographyComponent;\n\n /** @defaultValue `\"body-2\"` */\n type?: TypographyType;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport interface SliderMarkLabelProps extends CustomizableSliderMarkLabelProps {\n offset: string;\n vertical: boolean;\n}\n\n/**\n * **Server Component**\n *\n * @internal\n * @since 6.0.0\n */\nexport function SliderMarkLabel(props: SliderMarkLabelProps): ReactElement {\n const {\n as = \"span\",\n type = \"body-2\",\n offset,\n vertical,\n style,\n className,\n children,\n ...remaining\n } = props;\n\n return (\n <Typography\n {...remaining}\n as={as}\n type={type}\n style={{ ...style, \"--rmd-slider-mark-offset\": offset }}\n className={cnb(styles({ h: !vertical, v: vertical }), className)}\n >\n {children}\n </Typography>\n );\n}\n"],"names":["cnb","Typography","bem","styles","SliderMarkLabel","props","as","type","offset","vertical","style","className","children","remaining","h","v"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAEhC,SACEC,UAAU,QAGL,8BAA8B;AAErC,SAASC,GAAG,QAAQ,kBAAkB;AAEtC,MAAMC,SAASD,IAAI;AAsBnB;;;;;CAKC,GACD,OAAO,SAASE,gBAAgBC,KAA2B;IACzD,MAAM,EACJC,KAAK,MAAM,EACXC,OAAO,QAAQ,EACfC,MAAM,EACNC,QAAQ,EACRC,KAAK,EACLC,SAAS,EACTC,QAAQ,EACR,GAAGC,WACJ,GAAGR;IAEJ,qBACE,KAACJ;QACE,GAAGY,SAAS;QACbP,IAAIA;QACJC,MAAMA;QACNG,OAAO;YAAE,GAAGA,KAAK;YAAE,4BAA4BF;QAAO;QACtDG,WAAWX,IAAIG,OAAO;YAAEW,GAAG,CAACL;YAAUM,GAAGN;QAAS,IAAIE;kBAErDC;;AAGP"}
1
+ {"version":3,"sources":["../../src/form/SliderMarkLabel.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { type ReactElement } from \"react\";\nimport {\n Typography,\n type CustomTypographyComponent,\n type TypographyProps,\n} from \"../typography/Typography.js\";\nimport { type TypographyType } from \"../typography/typographyStyles.js\";\nimport { bem } from \"../utils/bem.js\";\n\nconst styles = bem(\"rmd-slider-mark-label\");\n\n/**\n * @since 6.0.0\n */\nexport interface CustomizableSliderMarkLabelProps extends TypographyProps {\n /** @defaultValue `\"span\"` */\n as?: CustomTypographyComponent;\n\n /** @defaultValue `\"body-2\"` */\n type?: TypographyType;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport interface SliderMarkLabelProps extends CustomizableSliderMarkLabelProps {\n offset: string;\n vertical: boolean;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport function SliderMarkLabel(props: SliderMarkLabelProps): ReactElement {\n const {\n as = \"span\",\n type = \"body-2\",\n offset,\n vertical,\n style,\n className,\n children,\n ...remaining\n } = props;\n\n return (\n <Typography\n {...remaining}\n as={as}\n type={type}\n style={{ ...style, \"--rmd-slider-mark-offset\": offset }}\n className={cnb(styles({ h: !vertical, v: vertical }), className)}\n >\n {children}\n </Typography>\n );\n}\n"],"names":["cnb","Typography","bem","styles","SliderMarkLabel","props","as","type","offset","vertical","style","className","children","remaining","h","v"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAEhC,SACEC,UAAU,QAGL,8BAA8B;AAErC,SAASC,GAAG,QAAQ,kBAAkB;AAEtC,MAAMC,SAASD,IAAI;AAsBnB;;;CAGC,GACD,OAAO,SAASE,gBAAgBC,KAA2B;IACzD,MAAM,EACJC,KAAK,MAAM,EACXC,OAAO,QAAQ,EACfC,MAAM,EACNC,QAAQ,EACRC,KAAK,EACLC,SAAS,EACTC,QAAQ,EACR,GAAGC,WACJ,GAAGR;IAEJ,qBACE,KAACJ;QACE,GAAGY,SAAS;QACbP,IAAIA;QACJC,MAAMA;QACNG,OAAO;YAAE,GAAGA,KAAK;YAAE,4BAA4BF;QAAO;QACtDG,WAAWX,IAAIG,OAAO;YAAEW,GAAG,CAACL;YAAUM,GAAGN;QAAS,IAAIE;kBAErDC;;AAGP"}
@@ -10,8 +10,6 @@ export interface SliderTrackProps extends HTMLAttributes<HTMLSpanElement>, Close
10
10
  disabled: boolean;
11
11
  }
12
12
  /**
13
- * **Server Component**
14
- *
15
13
  * @internal
16
14
  * @since 2.5.0
17
15
  * @since 6.0.0 Updated to be internal only.
@@ -5,8 +5,6 @@ import { bem } from "../utils/bem.js";
5
5
  import { getClosestThumbEventHandlers, getThumbOffsets } from "./sliderUtils.js";
6
6
  const styles = bem("rmd-slider-track");
7
7
  /**
8
- * **Server Component**
9
- *
10
8
  * @internal
11
9
  * @since 2.5.0
12
10
  * @since 6.0.0 Updated to be internal only.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/SliderTrack.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { forwardRef, type HTMLAttributes } from \"react\";\nimport { bem } from \"../utils/bem.js\";\nimport {\n getClosestThumbEventHandlers,\n getThumbOffsets,\n type ClosestThumbEventHandlersOptions,\n type ThumbOffsetsOptions,\n} from \"./sliderUtils.js\";\n\nconst styles = bem(\"rmd-slider-track\");\n\n/**\n * @internal\n * @since 2.5.0\n * @since 6.0.0 Updated to be internal only.\n */\nexport interface SliderTrackProps\n extends HTMLAttributes<HTMLSpanElement>,\n ClosestThumbEventHandlersOptions,\n ThumbOffsetsOptions {\n animate: boolean;\n disabled: boolean;\n}\n\n/**\n * **Server Component**\n *\n * @internal\n * @since 2.5.0\n * @since 6.0.0 Updated to be internal only.\n */\nexport const SliderTrack = forwardRef<HTMLSpanElement, SliderTrackProps>(\n function SliderTrack(props, ref) {\n const {\n style,\n className,\n animate,\n vertical,\n disabled,\n min,\n max,\n thumb1Ref,\n thumb1Value,\n thumb1Dragging,\n thumb1DragPercentage,\n thumb1OnMouseUp,\n thumb1OnMouseDown,\n thumb1OnMouseMove,\n thumb1OnTouchStart,\n thumb1OnTouchMove,\n thumb2Ref,\n thumb2Value,\n thumb2Dragging,\n thumb2DragPercentage,\n thumb2OnMouseUp,\n thumb2OnMouseDown,\n thumb2OnMouseMove,\n thumb2OnTouchStart,\n thumb2OnTouchMove,\n isRangeSlider,\n children,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n ref={ref}\n style={{\n ...style,\n ...getThumbOffsets({\n min,\n max,\n thumb1Value,\n thumb1Dragging,\n thumb1DragPercentage,\n thumb2Value,\n thumb2Dragging,\n thumb2DragPercentage,\n isRangeSlider,\n }),\n }}\n className={cnb(\n styles({\n animate,\n disabled,\n hoverable: !disabled,\n h: !vertical,\n h1: !vertical && !isRangeSlider,\n h2: !vertical && isRangeSlider,\n v: vertical,\n v1: vertical && !isRangeSlider,\n v2: vertical && isRangeSlider,\n }),\n className\n )}\n {...getClosestThumbEventHandlers({\n vertical,\n isRangeSlider,\n thumb1Ref,\n thumb1Dragging,\n thumb1OnMouseUp,\n thumb1OnMouseDown,\n thumb1OnMouseMove,\n thumb1OnTouchStart,\n thumb1OnTouchMove,\n thumb2Ref,\n thumb2Dragging,\n thumb2OnMouseUp,\n thumb2OnMouseDown,\n thumb2OnMouseMove,\n thumb2OnTouchStart,\n thumb2OnTouchMove,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","forwardRef","bem","getClosestThumbEventHandlers","getThumbOffsets","styles","SliderTrack","props","ref","style","className","animate","vertical","disabled","min","max","thumb1Ref","thumb1Value","thumb1Dragging","thumb1DragPercentage","thumb1OnMouseUp","thumb1OnMouseDown","thumb1OnMouseMove","thumb1OnTouchStart","thumb1OnTouchMove","thumb2Ref","thumb2Value","thumb2Dragging","thumb2DragPercentage","thumb2OnMouseUp","thumb2OnMouseDown","thumb2OnMouseMove","thumb2OnTouchStart","thumb2OnTouchMove","isRangeSlider","children","remaining","span","hoverable","h","h1","h2","v","v1","v2"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SAASC,UAAU,QAA6B,QAAQ;AACxD,SAASC,GAAG,QAAQ,kBAAkB;AACtC,SACEC,4BAA4B,EAC5BC,eAAe,QAGV,mBAAmB;AAE1B,MAAMC,SAASH,IAAI;AAenB;;;;;;CAMC,GACD,OAAO,MAAMI,4BAAcL,WACzB,SAASK,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,KAAK,EACLC,SAAS,EACTC,OAAO,EACPC,QAAQ,EACRC,QAAQ,EACRC,GAAG,EACHC,GAAG,EACHC,SAAS,EACTC,WAAW,EACXC,cAAc,EACdC,oBAAoB,EACpBC,eAAe,EACfC,iBAAiB,EACjBC,iBAAiB,EACjBC,kBAAkB,EAClBC,iBAAiB,EACjBC,SAAS,EACTC,WAAW,EACXC,cAAc,EACdC,oBAAoB,EACpBC,eAAe,EACfC,iBAAiB,EACjBC,iBAAiB,EACjBC,kBAAkB,EAClBC,iBAAiB,EACjBC,aAAa,EACbC,QAAQ,EACR,GAAGC,WACJ,GAAG7B;IAEJ,qBACE,KAAC8B;QACE,GAAGD,SAAS;QACb5B,KAAKA;QACLC,OAAO;YACL,GAAGA,KAAK;YACR,GAAGL,gBAAgB;gBACjBU;gBACAC;gBACAE;gBACAC;gBACAC;gBACAO;gBACAC;gBACAC;gBACAM;YACF,EAAE;QACJ;QACAxB,WAAWV,IACTK,OAAO;YACLM;YACAE;YACAyB,WAAW,CAACzB;YACZ0B,GAAG,CAAC3B;YACJ4B,IAAI,CAAC5B,YAAY,CAACsB;YAClBO,IAAI,CAAC7B,YAAYsB;YACjBQ,GAAG9B;YACH+B,IAAI/B,YAAY,CAACsB;YACjBU,IAAIhC,YAAYsB;QAClB,IACAxB;QAED,GAAGP,6BAA6B;YAC/BS;YACAsB;YACAlB;YACAE;YACAE;YACAC;YACAC;YACAC;YACAC;YACAC;YACAE;YACAE;YACAC;YACAC;YACAC;YACAC;QACF,EAAE;kBAEDE;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/form/SliderTrack.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { forwardRef, type HTMLAttributes } from \"react\";\nimport { bem } from \"../utils/bem.js\";\nimport {\n getClosestThumbEventHandlers,\n getThumbOffsets,\n type ClosestThumbEventHandlersOptions,\n type ThumbOffsetsOptions,\n} from \"./sliderUtils.js\";\n\nconst styles = bem(\"rmd-slider-track\");\n\n/**\n * @internal\n * @since 2.5.0\n * @since 6.0.0 Updated to be internal only.\n */\nexport interface SliderTrackProps\n extends HTMLAttributes<HTMLSpanElement>,\n ClosestThumbEventHandlersOptions,\n ThumbOffsetsOptions {\n animate: boolean;\n disabled: boolean;\n}\n\n/**\n * @internal\n * @since 2.5.0\n * @since 6.0.0 Updated to be internal only.\n */\nexport const SliderTrack = forwardRef<HTMLSpanElement, SliderTrackProps>(\n function SliderTrack(props, ref) {\n const {\n style,\n className,\n animate,\n vertical,\n disabled,\n min,\n max,\n thumb1Ref,\n thumb1Value,\n thumb1Dragging,\n thumb1DragPercentage,\n thumb1OnMouseUp,\n thumb1OnMouseDown,\n thumb1OnMouseMove,\n thumb1OnTouchStart,\n thumb1OnTouchMove,\n thumb2Ref,\n thumb2Value,\n thumb2Dragging,\n thumb2DragPercentage,\n thumb2OnMouseUp,\n thumb2OnMouseDown,\n thumb2OnMouseMove,\n thumb2OnTouchStart,\n thumb2OnTouchMove,\n isRangeSlider,\n children,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n ref={ref}\n style={{\n ...style,\n ...getThumbOffsets({\n min,\n max,\n thumb1Value,\n thumb1Dragging,\n thumb1DragPercentage,\n thumb2Value,\n thumb2Dragging,\n thumb2DragPercentage,\n isRangeSlider,\n }),\n }}\n className={cnb(\n styles({\n animate,\n disabled,\n hoverable: !disabled,\n h: !vertical,\n h1: !vertical && !isRangeSlider,\n h2: !vertical && isRangeSlider,\n v: vertical,\n v1: vertical && !isRangeSlider,\n v2: vertical && isRangeSlider,\n }),\n className\n )}\n {...getClosestThumbEventHandlers({\n vertical,\n isRangeSlider,\n thumb1Ref,\n thumb1Dragging,\n thumb1OnMouseUp,\n thumb1OnMouseDown,\n thumb1OnMouseMove,\n thumb1OnTouchStart,\n thumb1OnTouchMove,\n thumb2Ref,\n thumb2Dragging,\n thumb2OnMouseUp,\n thumb2OnMouseDown,\n thumb2OnMouseMove,\n thumb2OnTouchStart,\n thumb2OnTouchMove,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","forwardRef","bem","getClosestThumbEventHandlers","getThumbOffsets","styles","SliderTrack","props","ref","style","className","animate","vertical","disabled","min","max","thumb1Ref","thumb1Value","thumb1Dragging","thumb1DragPercentage","thumb1OnMouseUp","thumb1OnMouseDown","thumb1OnMouseMove","thumb1OnTouchStart","thumb1OnTouchMove","thumb2Ref","thumb2Value","thumb2Dragging","thumb2DragPercentage","thumb2OnMouseUp","thumb2OnMouseDown","thumb2OnMouseMove","thumb2OnTouchStart","thumb2OnTouchMove","isRangeSlider","children","remaining","span","hoverable","h","h1","h2","v","v1","v2"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SAASC,UAAU,QAA6B,QAAQ;AACxD,SAASC,GAAG,QAAQ,kBAAkB;AACtC,SACEC,4BAA4B,EAC5BC,eAAe,QAGV,mBAAmB;AAE1B,MAAMC,SAASH,IAAI;AAenB;;;;CAIC,GACD,OAAO,MAAMI,4BAAcL,WACzB,SAASK,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,KAAK,EACLC,SAAS,EACTC,OAAO,EACPC,QAAQ,EACRC,QAAQ,EACRC,GAAG,EACHC,GAAG,EACHC,SAAS,EACTC,WAAW,EACXC,cAAc,EACdC,oBAAoB,EACpBC,eAAe,EACfC,iBAAiB,EACjBC,iBAAiB,EACjBC,kBAAkB,EAClBC,iBAAiB,EACjBC,SAAS,EACTC,WAAW,EACXC,cAAc,EACdC,oBAAoB,EACpBC,eAAe,EACfC,iBAAiB,EACjBC,iBAAiB,EACjBC,kBAAkB,EAClBC,iBAAiB,EACjBC,aAAa,EACbC,QAAQ,EACR,GAAGC,WACJ,GAAG7B;IAEJ,qBACE,KAAC8B;QACE,GAAGD,SAAS;QACb5B,KAAKA;QACLC,OAAO;YACL,GAAGA,KAAK;YACR,GAAGL,gBAAgB;gBACjBU;gBACAC;gBACAE;gBACAC;gBACAC;gBACAO;gBACAC;gBACAC;gBACAM;YACF,EAAE;QACJ;QACAxB,WAAWV,IACTK,OAAO;YACLM;YACAE;YACAyB,WAAW,CAACzB;YACZ0B,GAAG,CAAC3B;YACJ4B,IAAI,CAAC5B,YAAY,CAACsB;YAClBO,IAAI,CAAC7B,YAAYsB;YACjBQ,GAAG9B;YACH+B,IAAI/B,YAAY,CAACsB;YACjBU,IAAIhC,YAAYsB;QAClB,IACAxB;QAED,GAAGP,6BAA6B;YAC/BS;YACAsB;YACAlB;YACAE;YACAE;YACAC;YACAC;YACAC;YACAC;YACAC;YACAE;YACAE;YACAC;YACAC;YACAC;YACAC;QACF,EAAE;kBAEDE;;AAGP,GACA"}
@@ -106,8 +106,6 @@ export interface SliderValueMarksProps extends RangeStepsOptions, Required<Slide
106
106
  isRangeSlider: boolean;
107
107
  }
108
108
  /**
109
- * **Server Component**
110
- *
111
109
  * @internal
112
110
  * @since 6.0.0
113
111
  */
@@ -5,8 +5,6 @@ import { getRangeSteps } from "../utils/getRangeSteps.js";
5
5
  import { SliderMark } from "./SliderMark.js";
6
6
  import { SliderMarkLabel } from "./SliderMarkLabel.js";
7
7
  /**
8
- * **Server Component**
9
- *
10
8
  * @internal
11
9
  * @since 6.0.0
12
10
  */ export function SliderValueMarks(props) {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/SliderValueMarks.tsx"],"sourcesContent":["import {\n Fragment,\n type HTMLAttributes,\n type ReactElement,\n type ReactNode,\n} from \"react\";\nimport { getPercentage } from \"../utils/getPercentage.js\";\nimport {\n getRangeSteps,\n type RangeStepsOptions,\n} from \"../utils/getRangeSteps.js\";\nimport { SliderMark } from \"./SliderMark.js\";\nimport {\n SliderMarkLabel,\n type CustomizableSliderMarkLabelProps,\n} from \"./SliderMarkLabel.js\";\n\n/**\n * @since 6.0.0\n */\nexport interface SliderValueMark {\n /**\n * An optional label to display alongside the current mark. This will be\n * positioned below the mark for horizontal sliders and to the right for\n * vertical sliders.\n */\n label?: ReactNode;\n\n /**\n * The value of the mark that should be a valid step within the slider.\n */\n value: number;\n}\n\n/**\n * @since 6.0.0\n */\nexport interface SliderValueMarkState {\n /** The {@link SliderValueMark.value} */\n value: number;\n\n /**\n * No idea if this is actually useful (maybe custom styles?), but it is the\n * current percentage the mark is offset and is what is set as the\n * `left`/`top` values for the mark.\n */\n offset: string;\n\n /**\n * This will be `true` when the mark is being covered by the slider track's\n * active state.\n */\n active: boolean;\n}\n\n/**\n * @since 6.0.0\n */\nexport interface SliderMarksOptions {\n /**\n * Set this to `true` to display a mark for each step within the slider. This\n * can be used alongside the {@link getMarkProps} and\n * {@link getMarkLabelProps} to customize the styles or display a label for\n * the mark.\n *\n * @example Custom Marks\n * ```tsx\n * const slider = useSlider({ step: 10 });\n *\n * <Slider\n * {...slider}\n * marks={[\n * { value: 0, label: \"Minimum\" },\n * { value: 10 },\n * { value: 20 },\n * { value: 30 },\n * { value: 40 },\n * { value: 50, label: \"Medium\" },\n * { value: 60 },\n * { value: 70 },\n * { value: 80 },\n * { value: 90 },\n * { value: 100, label: \"Maximum\" },\n * ]}\n * />\n * ```\n */\n marks?: boolean | readonly SliderValueMark[];\n\n /**\n * This can be used to override any styles for the specific mark.\n */\n getMarkProps?(\n options: SliderValueMarkState\n ): HTMLAttributes<HTMLSpanElement> | void;\n\n /**\n * This can be used to override any styles for a specific mark's label or\n * display a label dynamically.\n *\n * @example Dynamic Labels\n * ```tsx\n * <Slider\n * {...slider}\n * marks\n * getMarkLabelProps={({ active, value }) => {\n * if (value % 10 !== 0) {\n * return;\n * }\n *\n * return {\n * children: `${value} degrees`,\n * className: cnb(active && styles.somethingCustom),\n * };\n * }}\n * />\n * ```\n */\n getMarkLabelProps?(\n options: SliderValueMarkState\n ): Partial<CustomizableSliderMarkLabelProps> | void;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport interface SliderValueMarksProps\n extends RangeStepsOptions,\n Required<SliderMarksOptions> {\n vertical: boolean;\n thumb1Value: number;\n thumb2Value: number;\n isRangeSlider: boolean;\n}\n\n/**\n * **Server Component**\n *\n * @internal\n * @since 6.0.0\n */\nexport function SliderValueMarks(props: SliderValueMarksProps): ReactElement {\n const {\n min,\n max,\n step,\n marks: propMarks,\n vertical,\n thumb1Value,\n thumb2Value,\n isRangeSlider,\n getMarkProps,\n getMarkLabelProps,\n } = props;\n\n let marks: readonly SliderValueMark[];\n if (typeof propMarks === \"boolean\") {\n const steps = getRangeSteps({ min, max, step }) + 1;\n marks = Array.from({ length: steps }, (_, i) => ({\n value: min + i * step,\n }));\n } else {\n marks = propMarks;\n }\n\n return (\n <>\n {marks.map(({ value, label: markLabel }) => {\n // I can't think of a good name, but this is when the slider's track's\n // active color is covering the mark which requires different styles\n let active: boolean;\n let percentage = getPercentage({ min, max, value }) * 100;\n let markValue = value;\n if (vertical) {\n // need to reverse the percentage since it uses `top` for positioning\n // where the max value is at the top instead of bottom\n percentage = 100 - percentage;\n\n // need to reverse the mark's value as well for the same reason as\n // above\n markValue = max - value;\n }\n\n if (isRangeSlider) {\n active = markValue > thumb1Value && markValue < thumb2Value;\n } else {\n active = markValue < thumb1Value;\n }\n\n const offset = `${percentage}%`;\n const markProps = getMarkProps({ value, active, offset });\n const labelProps = getMarkLabelProps({ value, active, offset });\n const label = markLabel ?? labelProps?.children ?? null;\n\n return (\n <Fragment key={value}>\n <SliderMark\n {...markProps}\n offset={offset}\n active={active}\n vertical={vertical}\n />\n {label !== null && (\n <SliderMarkLabel\n {...labelProps}\n offset={offset}\n vertical={vertical}\n >\n {label}\n </SliderMarkLabel>\n )}\n </Fragment>\n );\n })}\n </>\n );\n}\n"],"names":["Fragment","getPercentage","getRangeSteps","SliderMark","SliderMarkLabel","SliderValueMarks","props","min","max","step","marks","propMarks","vertical","thumb1Value","thumb2Value","isRangeSlider","getMarkProps","getMarkLabelProps","steps","Array","from","length","_","i","value","map","label","markLabel","active","percentage","markValue","offset","markProps","labelProps","children"],"mappings":";AAAA,SACEA,QAAQ,QAIH,QAAQ;AACf,SAASC,aAAa,QAAQ,4BAA4B;AAC1D,SACEC,aAAa,QAER,4BAA4B;AACnC,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SACEC,eAAe,QAEV,uBAAuB;AAyH9B;;;;;CAKC,GACD,OAAO,SAASC,iBAAiBC,KAA4B;IAC3D,MAAM,EACJC,GAAG,EACHC,GAAG,EACHC,IAAI,EACJC,OAAOC,SAAS,EAChBC,QAAQ,EACRC,WAAW,EACXC,WAAW,EACXC,aAAa,EACbC,YAAY,EACZC,iBAAiB,EAClB,GAAGX;IAEJ,IAAII;IACJ,IAAI,OAAOC,cAAc,WAAW;QAClC,MAAMO,QAAQhB,cAAc;YAAEK;YAAKC;YAAKC;QAAK,KAAK;QAClDC,QAAQS,MAAMC,IAAI,CAAC;YAAEC,QAAQH;QAAM,GAAG,CAACI,GAAGC,IAAO,CAAA;gBAC/CC,OAAOjB,MAAMgB,IAAId;YACnB,CAAA;IACF,OAAO;QACLC,QAAQC;IACV;IAEA,qBACE;kBACGD,MAAMe,GAAG,CAAC,CAAC,EAAED,KAAK,EAAEE,OAAOC,SAAS,EAAE;YACrC,sEAAsE;YACtE,oEAAoE;YACpE,IAAIC;YACJ,IAAIC,aAAa5B,cAAc;gBAAEM;gBAAKC;gBAAKgB;YAAM,KAAK;YACtD,IAAIM,YAAYN;YAChB,IAAIZ,UAAU;gBACZ,qEAAqE;gBACrE,sDAAsD;gBACtDiB,aAAa,MAAMA;gBAEnB,kEAAkE;gBAClE,QAAQ;gBACRC,YAAYtB,MAAMgB;YACpB;YAEA,IAAIT,eAAe;gBACjBa,SAASE,YAAYjB,eAAeiB,YAAYhB;YAClD,OAAO;gBACLc,SAASE,YAAYjB;YACvB;YAEA,MAAMkB,SAAS,CAAC,EAAEF,WAAW,CAAC,CAAC;YAC/B,MAAMG,YAAYhB,aAAa;gBAAEQ;gBAAOI;gBAAQG;YAAO;YACvD,MAAME,aAAahB,kBAAkB;gBAAEO;gBAAOI;gBAAQG;YAAO;YAC7D,MAAML,QAAQC,aAAaM,YAAYC,YAAY;YAEnD,qBACE,MAAClC;;kCACC,KAACG;wBACE,GAAG6B,SAAS;wBACbD,QAAQA;wBACRH,QAAQA;wBACRhB,UAAUA;;oBAEXc,UAAU,sBACT,KAACtB;wBACE,GAAG6B,UAAU;wBACdF,QAAQA;wBACRnB,UAAUA;kCAETc;;;eAbQF;QAkBnB;;AAGN"}
1
+ {"version":3,"sources":["../../src/form/SliderValueMarks.tsx"],"sourcesContent":["import {\n Fragment,\n type HTMLAttributes,\n type ReactElement,\n type ReactNode,\n} from \"react\";\nimport { getPercentage } from \"../utils/getPercentage.js\";\nimport {\n getRangeSteps,\n type RangeStepsOptions,\n} from \"../utils/getRangeSteps.js\";\nimport { SliderMark } from \"./SliderMark.js\";\nimport {\n SliderMarkLabel,\n type CustomizableSliderMarkLabelProps,\n} from \"./SliderMarkLabel.js\";\n\n/**\n * @since 6.0.0\n */\nexport interface SliderValueMark {\n /**\n * An optional label to display alongside the current mark. This will be\n * positioned below the mark for horizontal sliders and to the right for\n * vertical sliders.\n */\n label?: ReactNode;\n\n /**\n * The value of the mark that should be a valid step within the slider.\n */\n value: number;\n}\n\n/**\n * @since 6.0.0\n */\nexport interface SliderValueMarkState {\n /** The {@link SliderValueMark.value} */\n value: number;\n\n /**\n * No idea if this is actually useful (maybe custom styles?), but it is the\n * current percentage the mark is offset and is what is set as the\n * `left`/`top` values for the mark.\n */\n offset: string;\n\n /**\n * This will be `true` when the mark is being covered by the slider track's\n * active state.\n */\n active: boolean;\n}\n\n/**\n * @since 6.0.0\n */\nexport interface SliderMarksOptions {\n /**\n * Set this to `true` to display a mark for each step within the slider. This\n * can be used alongside the {@link getMarkProps} and\n * {@link getMarkLabelProps} to customize the styles or display a label for\n * the mark.\n *\n * @example Custom Marks\n * ```tsx\n * const slider = useSlider({ step: 10 });\n *\n * <Slider\n * {...slider}\n * marks={[\n * { value: 0, label: \"Minimum\" },\n * { value: 10 },\n * { value: 20 },\n * { value: 30 },\n * { value: 40 },\n * { value: 50, label: \"Medium\" },\n * { value: 60 },\n * { value: 70 },\n * { value: 80 },\n * { value: 90 },\n * { value: 100, label: \"Maximum\" },\n * ]}\n * />\n * ```\n */\n marks?: boolean | readonly SliderValueMark[];\n\n /**\n * This can be used to override any styles for the specific mark.\n */\n getMarkProps?(\n options: SliderValueMarkState\n ): HTMLAttributes<HTMLSpanElement> | void;\n\n /**\n * This can be used to override any styles for a specific mark's label or\n * display a label dynamically.\n *\n * @example Dynamic Labels\n * ```tsx\n * <Slider\n * {...slider}\n * marks\n * getMarkLabelProps={({ active, value }) => {\n * if (value % 10 !== 0) {\n * return;\n * }\n *\n * return {\n * children: `${value} degrees`,\n * className: cnb(active && styles.somethingCustom),\n * };\n * }}\n * />\n * ```\n */\n getMarkLabelProps?(\n options: SliderValueMarkState\n ): Partial<CustomizableSliderMarkLabelProps> | void;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport interface SliderValueMarksProps\n extends RangeStepsOptions,\n Required<SliderMarksOptions> {\n vertical: boolean;\n thumb1Value: number;\n thumb2Value: number;\n isRangeSlider: boolean;\n}\n\n/**\n * @internal\n * @since 6.0.0\n */\nexport function SliderValueMarks(props: SliderValueMarksProps): ReactElement {\n const {\n min,\n max,\n step,\n marks: propMarks,\n vertical,\n thumb1Value,\n thumb2Value,\n isRangeSlider,\n getMarkProps,\n getMarkLabelProps,\n } = props;\n\n let marks: readonly SliderValueMark[];\n if (typeof propMarks === \"boolean\") {\n const steps = getRangeSteps({ min, max, step }) + 1;\n marks = Array.from({ length: steps }, (_, i) => ({\n value: min + i * step,\n }));\n } else {\n marks = propMarks;\n }\n\n return (\n <>\n {marks.map(({ value, label: markLabel }) => {\n // I can't think of a good name, but this is when the slider's track's\n // active color is covering the mark which requires different styles\n let active: boolean;\n let percentage = getPercentage({ min, max, value }) * 100;\n let markValue = value;\n if (vertical) {\n // need to reverse the percentage since it uses `top` for positioning\n // where the max value is at the top instead of bottom\n percentage = 100 - percentage;\n\n // need to reverse the mark's value as well for the same reason as\n // above\n markValue = max - value;\n }\n\n if (isRangeSlider) {\n active = markValue > thumb1Value && markValue < thumb2Value;\n } else {\n active = markValue < thumb1Value;\n }\n\n const offset = `${percentage}%`;\n const markProps = getMarkProps({ value, active, offset });\n const labelProps = getMarkLabelProps({ value, active, offset });\n const label = markLabel ?? labelProps?.children ?? null;\n\n return (\n <Fragment key={value}>\n <SliderMark\n {...markProps}\n offset={offset}\n active={active}\n vertical={vertical}\n />\n {label !== null && (\n <SliderMarkLabel\n {...labelProps}\n offset={offset}\n vertical={vertical}\n >\n {label}\n </SliderMarkLabel>\n )}\n </Fragment>\n );\n })}\n </>\n );\n}\n"],"names":["Fragment","getPercentage","getRangeSteps","SliderMark","SliderMarkLabel","SliderValueMarks","props","min","max","step","marks","propMarks","vertical","thumb1Value","thumb2Value","isRangeSlider","getMarkProps","getMarkLabelProps","steps","Array","from","length","_","i","value","map","label","markLabel","active","percentage","markValue","offset","markProps","labelProps","children"],"mappings":";AAAA,SACEA,QAAQ,QAIH,QAAQ;AACf,SAASC,aAAa,QAAQ,4BAA4B;AAC1D,SACEC,aAAa,QAER,4BAA4B;AACnC,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SACEC,eAAe,QAEV,uBAAuB;AAyH9B;;;CAGC,GACD,OAAO,SAASC,iBAAiBC,KAA4B;IAC3D,MAAM,EACJC,GAAG,EACHC,GAAG,EACHC,IAAI,EACJC,OAAOC,SAAS,EAChBC,QAAQ,EACRC,WAAW,EACXC,WAAW,EACXC,aAAa,EACbC,YAAY,EACZC,iBAAiB,EAClB,GAAGX;IAEJ,IAAII;IACJ,IAAI,OAAOC,cAAc,WAAW;QAClC,MAAMO,QAAQhB,cAAc;YAAEK;YAAKC;YAAKC;QAAK,KAAK;QAClDC,QAAQS,MAAMC,IAAI,CAAC;YAAEC,QAAQH;QAAM,GAAG,CAACI,GAAGC,IAAO,CAAA;gBAC/CC,OAAOjB,MAAMgB,IAAId;YACnB,CAAA;IACF,OAAO;QACLC,QAAQC;IACV;IAEA,qBACE;kBACGD,MAAMe,GAAG,CAAC,CAAC,EAAED,KAAK,EAAEE,OAAOC,SAAS,EAAE;YACrC,sEAAsE;YACtE,oEAAoE;YACpE,IAAIC;YACJ,IAAIC,aAAa5B,cAAc;gBAAEM;gBAAKC;gBAAKgB;YAAM,KAAK;YACtD,IAAIM,YAAYN;YAChB,IAAIZ,UAAU;gBACZ,qEAAqE;gBACrE,sDAAsD;gBACtDiB,aAAa,MAAMA;gBAEnB,kEAAkE;gBAClE,QAAQ;gBACRC,YAAYtB,MAAMgB;YACpB;YAEA,IAAIT,eAAe;gBACjBa,SAASE,YAAYjB,eAAeiB,YAAYhB;YAClD,OAAO;gBACLc,SAASE,YAAYjB;YACvB;YAEA,MAAMkB,SAAS,CAAC,EAAEF,WAAW,CAAC,CAAC;YAC/B,MAAMG,YAAYhB,aAAa;gBAAEQ;gBAAOI;gBAAQG;YAAO;YACvD,MAAME,aAAahB,kBAAkB;gBAAEO;gBAAOI;gBAAQG;YAAO;YAC7D,MAAML,QAAQC,aAAaM,YAAYC,YAAY;YAEnD,qBACE,MAAClC;;kCACC,KAACG;wBACE,GAAG6B,SAAS;wBACbD,QAAQA;wBACRH,QAAQA;wBACRhB,UAAUA;;oBAEXc,UAAU,sBACT,KAACtB;wBACE,GAAG6B,UAAU;wBACdF,QAAQA;wBACRnB,UAAUA;kCAETc;;;eAbQF;QAkBnB;;AAGN"}
@@ -17,8 +17,6 @@ export interface SwitchProps extends InputHTMLAttributes<HTMLInputElement>, Inpu
17
17
  ballClassName?: string;
18
18
  }
19
19
  /**
20
- * **Server Component**
21
- *
22
20
  * @example Simple Example
23
21
  * ```tsx
24
22
  * import { Form, Switch } from "@react-md/core";
@@ -7,8 +7,6 @@ import { Label } from "./Label.js";
7
7
  import { SwitchTrack } from "./SwitchTrack.js";
8
8
  import { switchStyles } from "./switchStyles.js";
9
9
  /**
10
- * **Server Component**
11
- *
12
10
  * @example Simple Example
13
11
  * ```tsx
14
12
  * import { Form, Switch } from "@react-md/core";
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/Switch.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type InputHTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { useEnsuredId } from \"../useEnsuredId.js\";\nimport { FormMessageContainer } from \"./FormMessageContainer.js\";\nimport { type InputToggleLabelProps } from \"./InputToggle.js\";\nimport { Label } from \"./Label.js\";\nimport { SwitchTrack } from \"./SwitchTrack.js\";\nimport { switchStyles } from \"./switchStyles.js\";\nimport {\n type FormComponentStates,\n type FormMessageContainerExtension,\n} from \"./types.js\";\n\n/**\n * @since 6.0.0 Added `containerProps` and support for the\n * `FormMessage` behavior.\n */\nexport interface SwitchProps\n extends InputHTMLAttributes<HTMLInputElement>,\n InputToggleLabelProps,\n FormMessageContainerExtension,\n FormComponentStates {\n containerProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n trackProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n trackStyle?: CSSProperties;\n trackClassName?: string;\n ballAddon?: ReactNode;\n ballProps?: PropsWithRef<HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>;\n ballStyle?: CSSProperties;\n ballClassName?: string;\n}\n\n/**\n * **Server Component**\n *\n * @example Simple Example\n * ```tsx\n * import { Form, Switch } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n * import { useState } from \"react\";\n *\n * function Example(): ReactElement {\n * const [checked, setChecked] = useState(false);\n *\n * return (\n * <Form>\n * <Switch\n * label=\"Label\"\n * name=\"enabled\"\n * checked={checked}\n * onChange={(event) => setChecked(event.currentTarget.checked)}\n * />\n * </Form>\n * );\n * }\n * ```\n *\n * @since 6.0.0 Added support for `FormMessage` behavior.\n */\nexport const Switch = forwardRef<HTMLInputElement, SwitchProps>(\n function Switch(props, ref) {\n const {\n id: propId,\n label,\n labelProps,\n style,\n className,\n containerProps,\n ballProps,\n ballStyle,\n ballClassName,\n ballAddon,\n trackProps,\n trackStyle,\n trackClassName,\n messageProps,\n messageContainerProps,\n disableLabelGap = false,\n error = false,\n active = false,\n stacked = false,\n iconAfter = false,\n disabled = false,\n readOnly = false,\n ...remaining\n } = props;\n const id = useEnsuredId(propId, \"switch\");\n\n return (\n <FormMessageContainer\n {...messageContainerProps}\n messageProps={messageProps}\n >\n <Label\n style={style}\n {...labelProps}\n className={cnb(className, labelProps?.className)}\n gap={!disableLabelGap}\n stacked={stacked}\n reversed={!iconAfter}\n active={active}\n error={error}\n disabled={disabled}\n >\n {label}\n <div\n {...containerProps}\n className={switchStyles({\n clickable: !disabled && !readOnly,\n className: containerProps?.className,\n currentColor: active || error,\n })}\n >\n <SwitchTrack\n style={trackStyle}\n {...trackProps}\n className={cnb(trackClassName, trackProps?.className)}\n disabled={disabled}\n ballAddon={ballAddon}\n ballProps={ballProps}\n ballStyle={ballStyle}\n ballClassName={ballClassName}\n >\n <input\n {...remaining}\n id={id}\n ref={ref}\n role=\"switch\"\n type=\"checkbox\"\n className={cnb(\n \"rmd-switch__input rmd-hidden-input\",\n disabled && \"rmd-hidden-input--disabled\"\n )}\n disabled={disabled}\n />\n </SwitchTrack>\n </div>\n </Label>\n </FormMessageContainer>\n );\n }\n);\n"],"names":["cnb","forwardRef","useEnsuredId","FormMessageContainer","Label","SwitchTrack","switchStyles","Switch","props","ref","id","propId","label","labelProps","style","className","containerProps","ballProps","ballStyle","ballClassName","ballAddon","trackProps","trackStyle","trackClassName","messageProps","messageContainerProps","disableLabelGap","error","active","stacked","iconAfter","disabled","readOnly","remaining","gap","reversed","div","clickable","currentColor","input","role","type"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,UAAU,QAKL,QAAQ;AAEf,SAASC,YAAY,QAAQ,qBAAqB;AAClD,SAASC,oBAAoB,QAAQ,4BAA4B;AAEjE,SAASC,KAAK,QAAQ,aAAa;AACnC,SAASC,WAAW,QAAQ,mBAAmB;AAC/C,SAASC,YAAY,QAAQ,oBAAoB;AAyBjD;;;;;;;;;;;;;;;;;;;;;;;;;;CA0BC,GACD,OAAO,MAAMC,uBAASN,WACpB,SAASM,OAAOC,KAAK,EAAEC,GAAG;IACxB,MAAM,EACJC,IAAIC,MAAM,EACVC,KAAK,EACLC,UAAU,EACVC,KAAK,EACLC,SAAS,EACTC,cAAc,EACdC,SAAS,EACTC,SAAS,EACTC,aAAa,EACbC,SAAS,EACTC,UAAU,EACVC,UAAU,EACVC,cAAc,EACdC,YAAY,EACZC,qBAAqB,EACrBC,kBAAkB,KAAK,EACvBC,QAAQ,KAAK,EACbC,SAAS,KAAK,EACdC,UAAU,KAAK,EACfC,YAAY,KAAK,EACjBC,WAAW,KAAK,EAChBC,WAAW,KAAK,EAChB,GAAGC,WACJ,GAAGzB;IACJ,MAAME,KAAKR,aAAaS,QAAQ;IAEhC,qBACE,KAACR;QACE,GAAGsB,qBAAqB;QACzBD,cAAcA;kBAEd,cAAA,MAACpB;YACCU,OAAOA;YACN,GAAGD,UAAU;YACdE,WAAWf,IAAIe,WAAWF,YAAYE;YACtCmB,KAAK,CAACR;YACNG,SAASA;YACTM,UAAU,CAACL;YACXF,QAAQA;YACRD,OAAOA;YACPI,UAAUA;;gBAETnB;8BACD,KAACwB;oBACE,GAAGpB,cAAc;oBAClBD,WAAWT,aAAa;wBACtB+B,WAAW,CAACN,YAAY,CAACC;wBACzBjB,WAAWC,gBAAgBD;wBAC3BuB,cAAcV,UAAUD;oBAC1B;8BAEA,cAAA,KAACtB;wBACCS,OAAOQ;wBACN,GAAGD,UAAU;wBACdN,WAAWf,IAAIuB,gBAAgBF,YAAYN;wBAC3CgB,UAAUA;wBACVX,WAAWA;wBACXH,WAAWA;wBACXC,WAAWA;wBACXC,eAAeA;kCAEf,cAAA,KAACoB;4BACE,GAAGN,SAAS;4BACbvB,IAAIA;4BACJD,KAAKA;4BACL+B,MAAK;4BACLC,MAAK;4BACL1B,WAAWf,IACT,sCACA+B,YAAY;4BAEdA,UAAUA;;;;;;;AAOxB,GACA"}
1
+ {"version":3,"sources":["../../src/form/Switch.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type InputHTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { useEnsuredId } from \"../useEnsuredId.js\";\nimport { FormMessageContainer } from \"./FormMessageContainer.js\";\nimport { type InputToggleLabelProps } from \"./InputToggle.js\";\nimport { Label } from \"./Label.js\";\nimport { SwitchTrack } from \"./SwitchTrack.js\";\nimport { switchStyles } from \"./switchStyles.js\";\nimport {\n type FormComponentStates,\n type FormMessageContainerExtension,\n} from \"./types.js\";\n\n/**\n * @since 6.0.0 Added `containerProps` and support for the\n * `FormMessage` behavior.\n */\nexport interface SwitchProps\n extends InputHTMLAttributes<HTMLInputElement>,\n InputToggleLabelProps,\n FormMessageContainerExtension,\n FormComponentStates {\n containerProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n trackProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n trackStyle?: CSSProperties;\n trackClassName?: string;\n ballAddon?: ReactNode;\n ballProps?: PropsWithRef<HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>;\n ballStyle?: CSSProperties;\n ballClassName?: string;\n}\n\n/**\n * @example Simple Example\n * ```tsx\n * import { Form, Switch } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n * import { useState } from \"react\";\n *\n * function Example(): ReactElement {\n * const [checked, setChecked] = useState(false);\n *\n * return (\n * <Form>\n * <Switch\n * label=\"Label\"\n * name=\"enabled\"\n * checked={checked}\n * onChange={(event) => setChecked(event.currentTarget.checked)}\n * />\n * </Form>\n * );\n * }\n * ```\n *\n * @since 6.0.0 Added support for `FormMessage` behavior.\n */\nexport const Switch = forwardRef<HTMLInputElement, SwitchProps>(\n function Switch(props, ref) {\n const {\n id: propId,\n label,\n labelProps,\n style,\n className,\n containerProps,\n ballProps,\n ballStyle,\n ballClassName,\n ballAddon,\n trackProps,\n trackStyle,\n trackClassName,\n messageProps,\n messageContainerProps,\n disableLabelGap = false,\n error = false,\n active = false,\n stacked = false,\n iconAfter = false,\n disabled = false,\n readOnly = false,\n ...remaining\n } = props;\n const id = useEnsuredId(propId, \"switch\");\n\n return (\n <FormMessageContainer\n {...messageContainerProps}\n messageProps={messageProps}\n >\n <Label\n style={style}\n {...labelProps}\n className={cnb(className, labelProps?.className)}\n gap={!disableLabelGap}\n stacked={stacked}\n reversed={!iconAfter}\n active={active}\n error={error}\n disabled={disabled}\n >\n {label}\n <div\n {...containerProps}\n className={switchStyles({\n clickable: !disabled && !readOnly,\n className: containerProps?.className,\n currentColor: active || error,\n })}\n >\n <SwitchTrack\n style={trackStyle}\n {...trackProps}\n className={cnb(trackClassName, trackProps?.className)}\n disabled={disabled}\n ballAddon={ballAddon}\n ballProps={ballProps}\n ballStyle={ballStyle}\n ballClassName={ballClassName}\n >\n <input\n {...remaining}\n id={id}\n ref={ref}\n role=\"switch\"\n type=\"checkbox\"\n className={cnb(\n \"rmd-switch__input rmd-hidden-input\",\n disabled && \"rmd-hidden-input--disabled\"\n )}\n disabled={disabled}\n />\n </SwitchTrack>\n </div>\n </Label>\n </FormMessageContainer>\n );\n }\n);\n"],"names":["cnb","forwardRef","useEnsuredId","FormMessageContainer","Label","SwitchTrack","switchStyles","Switch","props","ref","id","propId","label","labelProps","style","className","containerProps","ballProps","ballStyle","ballClassName","ballAddon","trackProps","trackStyle","trackClassName","messageProps","messageContainerProps","disableLabelGap","error","active","stacked","iconAfter","disabled","readOnly","remaining","gap","reversed","div","clickable","currentColor","input","role","type"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,UAAU,QAKL,QAAQ;AAEf,SAASC,YAAY,QAAQ,qBAAqB;AAClD,SAASC,oBAAoB,QAAQ,4BAA4B;AAEjE,SAASC,KAAK,QAAQ,aAAa;AACnC,SAASC,WAAW,QAAQ,mBAAmB;AAC/C,SAASC,YAAY,QAAQ,oBAAoB;AAyBjD;;;;;;;;;;;;;;;;;;;;;;;;CAwBC,GACD,OAAO,MAAMC,uBAASN,WACpB,SAASM,OAAOC,KAAK,EAAEC,GAAG;IACxB,MAAM,EACJC,IAAIC,MAAM,EACVC,KAAK,EACLC,UAAU,EACVC,KAAK,EACLC,SAAS,EACTC,cAAc,EACdC,SAAS,EACTC,SAAS,EACTC,aAAa,EACbC,SAAS,EACTC,UAAU,EACVC,UAAU,EACVC,cAAc,EACdC,YAAY,EACZC,qBAAqB,EACrBC,kBAAkB,KAAK,EACvBC,QAAQ,KAAK,EACbC,SAAS,KAAK,EACdC,UAAU,KAAK,EACfC,YAAY,KAAK,EACjBC,WAAW,KAAK,EAChBC,WAAW,KAAK,EAChB,GAAGC,WACJ,GAAGzB;IACJ,MAAME,KAAKR,aAAaS,QAAQ;IAEhC,qBACE,KAACR;QACE,GAAGsB,qBAAqB;QACzBD,cAAcA;kBAEd,cAAA,MAACpB;YACCU,OAAOA;YACN,GAAGD,UAAU;YACdE,WAAWf,IAAIe,WAAWF,YAAYE;YACtCmB,KAAK,CAACR;YACNG,SAASA;YACTM,UAAU,CAACL;YACXF,QAAQA;YACRD,OAAOA;YACPI,UAAUA;;gBAETnB;8BACD,KAACwB;oBACE,GAAGpB,cAAc;oBAClBD,WAAWT,aAAa;wBACtB+B,WAAW,CAACN,YAAY,CAACC;wBACzBjB,WAAWC,gBAAgBD;wBAC3BuB,cAAcV,UAAUD;oBAC1B;8BAEA,cAAA,KAACtB;wBACCS,OAAOQ;wBACN,GAAGD,UAAU;wBACdN,WAAWf,IAAIuB,gBAAgBF,YAAYN;wBAC3CgB,UAAUA;wBACVX,WAAWA;wBACXH,WAAWA;wBACXC,WAAWA;wBACXC,eAAeA;kCAEf,cAAA,KAACoB;4BACE,GAAGN,SAAS;4BACbvB,IAAIA;4BACJD,KAAKA;4BACL+B,MAAK;4BACLC,MAAK;4BACL1B,WAAWf,IACT,sCACA+B,YAAY;4BAEdA,UAAUA;;;;;;;AAOxB,GACA"}
@@ -9,6 +9,7 @@ export interface SwitchTrackProps extends HTMLAttributes<HTMLDivElement> {
9
9
  ballClassName?: string;
10
10
  }
11
11
  /**
12
- * **Server Component**
12
+ * Used to create the switch track styles
13
+ * @internal
13
14
  */
14
15
  export declare const SwitchTrack: import("react").ForwardRefExoticComponent<SwitchTrackProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -4,7 +4,8 @@ import { forwardRef } from "react";
4
4
  import { bem } from "../utils/bem.js";
5
5
  const styles = bem("rmd-switch");
6
6
  /**
7
- * **Server Component**
7
+ * Used to create the switch track styles
8
+ * @internal
8
9
  */ export const SwitchTrack = /*#__PURE__*/ forwardRef(function SwitchTrack(props, ref) {
9
10
  const { style, className, ballAddon, ballProps, ballStyle, ballClassName, active, children, disabled = false, ...remaining } = props;
10
11
  return /*#__PURE__*/ _jsxs("div", {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/SwitchTrack.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { bem } from \"../utils/bem.js\";\n\nconst styles = bem(\"rmd-switch\");\n\nexport interface SwitchTrackProps extends HTMLAttributes<HTMLDivElement> {\n active?: boolean;\n disabled?: boolean;\n ballAddon?: ReactNode;\n ballProps?: PropsWithRef<HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>;\n ballStyle?: CSSProperties;\n ballClassName?: string;\n}\n\n/**\n * **Server Component**\n */\nexport const SwitchTrack = forwardRef<HTMLDivElement, SwitchTrackProps>(\n function SwitchTrack(props, ref) {\n const {\n style,\n className,\n ballAddon,\n ballProps,\n ballStyle,\n ballClassName,\n active,\n children,\n disabled = false,\n ...remaining\n } = props;\n\n return (\n <div\n {...remaining}\n ref={ref}\n style={style}\n className={cnb(styles(\"track\", { disabled }), className)}\n >\n {children}\n <span\n style={ballStyle}\n {...ballProps}\n className={cnb(styles(\"ball\", { active }), ballClassName)}\n >\n {ballAddon}\n {ballProps?.children}\n </span>\n </div>\n );\n }\n);\n"],"names":["cnb","forwardRef","bem","styles","SwitchTrack","props","ref","style","className","ballAddon","ballProps","ballStyle","ballClassName","active","children","disabled","remaining","div","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,UAAU,QAIL,QAAQ;AAEf,SAASC,GAAG,QAAQ,kBAAkB;AAEtC,MAAMC,SAASD,IAAI;AAWnB;;CAEC,GACD,OAAO,MAAME,4BAAcH,WACzB,SAASG,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,KAAK,EACLC,SAAS,EACTC,SAAS,EACTC,SAAS,EACTC,SAAS,EACTC,aAAa,EACbC,MAAM,EACNC,QAAQ,EACRC,WAAW,KAAK,EAChB,GAAGC,WACJ,GAAGX;IAEJ,qBACE,MAACY;QACE,GAAGD,SAAS;QACbV,KAAKA;QACLC,OAAOA;QACPC,WAAWR,IAAIG,OAAO,SAAS;YAAEY;QAAS,IAAIP;;YAE7CM;0BACD,MAACI;gBACCX,OAAOI;gBACN,GAAGD,SAAS;gBACbF,WAAWR,IAAIG,OAAO,QAAQ;oBAAEU;gBAAO,IAAID;;oBAE1CH;oBACAC,WAAWI;;;;;AAIpB,GACA"}
1
+ {"version":3,"sources":["../../src/form/SwitchTrack.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { bem } from \"../utils/bem.js\";\n\nconst styles = bem(\"rmd-switch\");\n\nexport interface SwitchTrackProps extends HTMLAttributes<HTMLDivElement> {\n active?: boolean;\n disabled?: boolean;\n ballAddon?: ReactNode;\n ballProps?: PropsWithRef<HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>;\n ballStyle?: CSSProperties;\n ballClassName?: string;\n}\n\n/**\n * Used to create the switch track styles\n * @internal\n */\nexport const SwitchTrack = forwardRef<HTMLDivElement, SwitchTrackProps>(\n function SwitchTrack(props, ref) {\n const {\n style,\n className,\n ballAddon,\n ballProps,\n ballStyle,\n ballClassName,\n active,\n children,\n disabled = false,\n ...remaining\n } = props;\n\n return (\n <div\n {...remaining}\n ref={ref}\n style={style}\n className={cnb(styles(\"track\", { disabled }), className)}\n >\n {children}\n <span\n style={ballStyle}\n {...ballProps}\n className={cnb(styles(\"ball\", { active }), ballClassName)}\n >\n {ballAddon}\n {ballProps?.children}\n </span>\n </div>\n );\n }\n);\n"],"names":["cnb","forwardRef","bem","styles","SwitchTrack","props","ref","style","className","ballAddon","ballProps","ballStyle","ballClassName","active","children","disabled","remaining","div","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,UAAU,QAIL,QAAQ;AAEf,SAASC,GAAG,QAAQ,kBAAkB;AAEtC,MAAMC,SAASD,IAAI;AAWnB;;;CAGC,GACD,OAAO,MAAME,4BAAcH,WACzB,SAASG,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,KAAK,EACLC,SAAS,EACTC,SAAS,EACTC,SAAS,EACTC,SAAS,EACTC,aAAa,EACbC,MAAM,EACNC,QAAQ,EACRC,WAAW,KAAK,EAChB,GAAGC,WACJ,GAAGX;IAEJ,qBACE,MAACY;QACE,GAAGD,SAAS;QACbV,KAAKA;QACLC,OAAOA;QACPC,WAAWR,IAAIG,OAAO,SAAS;YAAEY;QAAS,IAAIP;;YAE7CM;0BACD,MAACI;gBACCX,OAAOI;gBACN,GAAGD,SAAS;gBACbF,WAAWR,IAAIG,OAAO,QAAQ;oBAAEU;gBAAO,IAAID;;oBAE1CH;oBACAC,WAAWI;;;;;AAIpB,GACA"}
@@ -52,8 +52,6 @@ export interface TextFieldProps extends TextFieldInputAttributes, UserAgentAutoc
52
52
  containerProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
53
53
  }
54
54
  /**
55
- * **Server Component**
56
- *
57
55
  * The structure for this component is:
58
56
  * @example Component Structure
59
57
  * ```tsx
@@ -6,8 +6,6 @@ import { Label } from "./Label.js";
6
6
  import { TextFieldContainer } from "./TextFieldContainer.js";
7
7
  import { textField } from "./textFieldStyles.js";
8
8
  /**
9
- * **Server Component**
10
- *
11
9
  * The structure for this component is:
12
10
  * @example Component Structure
13
11
  * ```tsx
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/TextField.tsx"],"sourcesContent":["import {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type InputHTMLAttributes,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { useEnsuredId } from \"../useEnsuredId.js\";\nimport { FormMessageContainer } from \"./FormMessageContainer.js\";\nimport { Label } from \"./Label.js\";\nimport { TextFieldContainer } from \"./TextFieldContainer.js\";\nimport { textField } from \"./textFieldStyles.js\";\nimport {\n type FormFieldOptions,\n type UserAgentAutocompleteProps,\n} from \"./types.js\";\n\n/**\n * These are all the \"supported\" input types for react-md so that they at least\n * render reasonably well by default. There is no built-in validation or\n * anything adding onto existing browser functionality for these types.\n *\n * @since 2.5.0 - `\"search\"` was added\n * @since 6.0.0 Dropped support for `\"week\"` and `\"month\"` input types since\n * they are not available in Firefox and Safari at this time.\n */\nexport type SupportedInputTypes =\n | \"text\"\n | \"password\"\n | \"number\"\n | \"tel\"\n | \"email\"\n | \"date\"\n | \"time\"\n | \"datetime-local\"\n | \"url\"\n | \"color\"\n | \"search\";\n\n/**\n * @since 6.0.0 Renamed from `TextFieldAttributes` to\n * `TextFieldInputAttributes`\n */\nexport type TextFieldInputAttributes = Omit<\n InputHTMLAttributes<HTMLInputElement>,\n \"type\"\n>;\n\n/**\n * @since 6.0.0 Removed the `containerRef` prop.\n */\nexport interface TextFieldProps\n extends TextFieldInputAttributes,\n UserAgentAutocompleteProps,\n FormFieldOptions {\n /**\n * @defaultValue `\"text-field-\" + useId()`\n */\n id?: string;\n\n /**\n * Optional placeholder text to display in the text field.\n *\n * @defaultValue `label ? \" \" : \"\"`\n */\n placeholder?: string;\n\n /**\n * Any optional inline styles to set on the input.\n */\n inputStyle?: CSSProperties;\n\n /**\n * An optional `className` to add to the input.\n */\n inputClassName?: string;\n\n /**\n * The text field type.\n *\n * @defaultValue `\"text\"`\n */\n type?: SupportedInputTypes;\n\n /**\n * Optional props to provide to the {@link TextFieldContainer} component.\n * There probably isn't any real use for this prop other than if you need to\n * add a `ref` for some DOM behavior.\n */\n containerProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n}\n\n/**\n * **Server Component**\n *\n * The structure for this component is:\n * @example Component Structure\n * ```tsx\n * <FormMessageContainer {...messageContainerProps}>\n * <TextFieldContainer {...containerProps}>\n * <input {...props} />\n * <Label {...labelProps} />\n * </TextFieldContainer>\n * </FormMessageContainer>\n * ```\n *\n * @example Simple Example\n * ```tsx\n * import { TextField } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextField\n * label=\"Name\"\n * placeholder=\"Bob\"\n * defaultValue=\"\"\n * />\n * );\n * }\n * ```\n */\nexport const TextField = forwardRef<HTMLInputElement, TextFieldProps>(\n function TextField(props, ref) {\n const {\n id: propId,\n style,\n className,\n type = \"text\",\n label,\n labelProps,\n labelStyle,\n labelClassName,\n autoCompleteValue,\n autoComplete = autoCompleteValue,\n name = autoCompleteValue,\n dense,\n error,\n active,\n inline,\n stretch,\n leftAddon,\n leftAddonProps,\n rightAddon,\n rightAddonProps,\n disableLeftAddonStyles,\n disableRightAddonStyles,\n inputStyle,\n inputClassName,\n theme,\n underlineDirection,\n messageProps,\n messageContainerProps,\n containerProps,\n ...remaining\n } = props;\n const { disabled, readOnly } = props;\n const id = useEnsuredId(propId, \"text-field\");\n\n let { placeholder = \"\" } = props;\n if (label && !placeholder) {\n // See the placeholder type definition comments for information\n placeholder = \" \";\n }\n\n return (\n <FormMessageContainer\n {...messageContainerProps}\n messageProps={\n messageProps && {\n error,\n theme,\n ...messageProps,\n }\n }\n >\n <TextFieldContainer\n {...containerProps}\n style={style}\n className={className}\n theme={theme}\n label={!!label}\n error={error}\n dense={dense}\n inline={inline}\n active={active}\n stretch={stretch}\n readOnly={readOnly}\n disabled={disabled}\n leftAddon={leftAddon}\n leftAddonProps={leftAddonProps}\n rightAddon={rightAddon}\n rightAddonProps={rightAddonProps}\n underlineDirection={underlineDirection}\n disableLeftAddonStyles={disableLeftAddonStyles}\n disableRightAddonStyles={disableRightAddonStyles}\n >\n <input\n {...remaining}\n id={id}\n ref={ref}\n type={type}\n name={name}\n disabled={disabled}\n placeholder={placeholder}\n autoComplete={autoComplete}\n style={inputStyle}\n className={textField({\n className: inputClassName,\n placeholderHidden: !!label && !active,\n })}\n />\n {label && (\n <Label\n floating\n dense={dense}\n error={error}\n active={active}\n disabled={disabled}\n {...labelProps}\n htmlFor={id}\n style={labelProps?.style ?? labelStyle}\n className={labelProps?.className ?? labelClassName}\n >\n {label}\n </Label>\n )}\n </TextFieldContainer>\n </FormMessageContainer>\n );\n }\n);\n"],"names":["forwardRef","useEnsuredId","FormMessageContainer","Label","TextFieldContainer","textField","TextField","props","ref","id","propId","style","className","type","label","labelProps","labelStyle","labelClassName","autoCompleteValue","autoComplete","name","dense","error","active","inline","stretch","leftAddon","leftAddonProps","rightAddon","rightAddonProps","disableLeftAddonStyles","disableRightAddonStyles","inputStyle","inputClassName","theme","underlineDirection","messageProps","messageContainerProps","containerProps","remaining","disabled","readOnly","placeholder","input","placeholderHidden","floating","htmlFor"],"mappings":";AAAA,SACEA,UAAU,QAIL,QAAQ;AAEf,SAASC,YAAY,QAAQ,qBAAqB;AAClD,SAASC,oBAAoB,QAAQ,4BAA4B;AACjE,SAASC,KAAK,QAAQ,aAAa;AACnC,SAASC,kBAAkB,QAAQ,0BAA0B;AAC7D,SAASC,SAAS,QAAQ,uBAAuB;AAiFjD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6BC,GACD,OAAO,MAAMC,0BAAYN,WACvB,SAASM,UAAUC,KAAK,EAAEC,GAAG;IAC3B,MAAM,EACJC,IAAIC,MAAM,EACVC,KAAK,EACLC,SAAS,EACTC,OAAO,MAAM,EACbC,KAAK,EACLC,UAAU,EACVC,UAAU,EACVC,cAAc,EACdC,iBAAiB,EACjBC,eAAeD,iBAAiB,EAChCE,OAAOF,iBAAiB,EACxBG,KAAK,EACLC,KAAK,EACLC,MAAM,EACNC,MAAM,EACNC,OAAO,EACPC,SAAS,EACTC,cAAc,EACdC,UAAU,EACVC,eAAe,EACfC,sBAAsB,EACtBC,uBAAuB,EACvBC,UAAU,EACVC,cAAc,EACdC,KAAK,EACLC,kBAAkB,EAClBC,YAAY,EACZC,qBAAqB,EACrBC,cAAc,EACd,GAAGC,WACJ,GAAGhC;IACJ,MAAM,EAAEiC,QAAQ,EAAEC,QAAQ,EAAE,GAAGlC;IAC/B,MAAME,KAAKR,aAAaS,QAAQ;IAEhC,IAAI,EAAEgC,cAAc,EAAE,EAAE,GAAGnC;IAC3B,IAAIO,SAAS,CAAC4B,aAAa;QACzB,+DAA+D;QAC/DA,cAAc;IAChB;IAEA,qBACE,KAACxC;QACE,GAAGmC,qBAAqB;QACzBD,cACEA,gBAAgB;YACdd;YACAY;YACA,GAAGE,YAAY;QACjB;kBAGF,cAAA,MAAChC;YACE,GAAGkC,cAAc;YAClB3B,OAAOA;YACPC,WAAWA;YACXsB,OAAOA;YACPpB,OAAO,CAAC,CAACA;YACTQ,OAAOA;YACPD,OAAOA;YACPG,QAAQA;YACRD,QAAQA;YACRE,SAASA;YACTgB,UAAUA;YACVD,UAAUA;YACVd,WAAWA;YACXC,gBAAgBA;YAChBC,YAAYA;YACZC,iBAAiBA;YACjBM,oBAAoBA;YACpBL,wBAAwBA;YACxBC,yBAAyBA;;8BAEzB,KAACY;oBACE,GAAGJ,SAAS;oBACb9B,IAAIA;oBACJD,KAAKA;oBACLK,MAAMA;oBACNO,MAAMA;oBACNoB,UAAUA;oBACVE,aAAaA;oBACbvB,cAAcA;oBACdR,OAAOqB;oBACPpB,WAAWP,UAAU;wBACnBO,WAAWqB;wBACXW,mBAAmB,CAAC,CAAC9B,SAAS,CAACS;oBACjC;;gBAEDT,uBACC,KAACX;oBACC0C,QAAQ;oBACRxB,OAAOA;oBACPC,OAAOA;oBACPC,QAAQA;oBACRiB,UAAUA;oBACT,GAAGzB,UAAU;oBACd+B,SAASrC;oBACTE,OAAOI,YAAYJ,SAASK;oBAC5BJ,WAAWG,YAAYH,aAAaK;8BAEnCH;;;;;AAMb,GACA"}
1
+ {"version":3,"sources":["../../src/form/TextField.tsx"],"sourcesContent":["import {\n forwardRef,\n type CSSProperties,\n type HTMLAttributes,\n type InputHTMLAttributes,\n} from \"react\";\nimport { type PropsWithRef } from \"../types.js\";\nimport { useEnsuredId } from \"../useEnsuredId.js\";\nimport { FormMessageContainer } from \"./FormMessageContainer.js\";\nimport { Label } from \"./Label.js\";\nimport { TextFieldContainer } from \"./TextFieldContainer.js\";\nimport { textField } from \"./textFieldStyles.js\";\nimport {\n type FormFieldOptions,\n type UserAgentAutocompleteProps,\n} from \"./types.js\";\n\n/**\n * These are all the \"supported\" input types for react-md so that they at least\n * render reasonably well by default. There is no built-in validation or\n * anything adding onto existing browser functionality for these types.\n *\n * @since 2.5.0 - `\"search\"` was added\n * @since 6.0.0 Dropped support for `\"week\"` and `\"month\"` input types since\n * they are not available in Firefox and Safari at this time.\n */\nexport type SupportedInputTypes =\n | \"text\"\n | \"password\"\n | \"number\"\n | \"tel\"\n | \"email\"\n | \"date\"\n | \"time\"\n | \"datetime-local\"\n | \"url\"\n | \"color\"\n | \"search\";\n\n/**\n * @since 6.0.0 Renamed from `TextFieldAttributes` to\n * `TextFieldInputAttributes`\n */\nexport type TextFieldInputAttributes = Omit<\n InputHTMLAttributes<HTMLInputElement>,\n \"type\"\n>;\n\n/**\n * @since 6.0.0 Removed the `containerRef` prop.\n */\nexport interface TextFieldProps\n extends TextFieldInputAttributes,\n UserAgentAutocompleteProps,\n FormFieldOptions {\n /**\n * @defaultValue `\"text-field-\" + useId()`\n */\n id?: string;\n\n /**\n * Optional placeholder text to display in the text field.\n *\n * @defaultValue `label ? \" \" : \"\"`\n */\n placeholder?: string;\n\n /**\n * Any optional inline styles to set on the input.\n */\n inputStyle?: CSSProperties;\n\n /**\n * An optional `className` to add to the input.\n */\n inputClassName?: string;\n\n /**\n * The text field type.\n *\n * @defaultValue `\"text\"`\n */\n type?: SupportedInputTypes;\n\n /**\n * Optional props to provide to the {@link TextFieldContainer} component.\n * There probably isn't any real use for this prop other than if you need to\n * add a `ref` for some DOM behavior.\n */\n containerProps?: PropsWithRef<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;\n}\n\n/**\n * The structure for this component is:\n * @example Component Structure\n * ```tsx\n * <FormMessageContainer {...messageContainerProps}>\n * <TextFieldContainer {...containerProps}>\n * <input {...props} />\n * <Label {...labelProps} />\n * </TextFieldContainer>\n * </FormMessageContainer>\n * ```\n *\n * @example Simple Example\n * ```tsx\n * import { TextField } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextField\n * label=\"Name\"\n * placeholder=\"Bob\"\n * defaultValue=\"\"\n * />\n * );\n * }\n * ```\n */\nexport const TextField = forwardRef<HTMLInputElement, TextFieldProps>(\n function TextField(props, ref) {\n const {\n id: propId,\n style,\n className,\n type = \"text\",\n label,\n labelProps,\n labelStyle,\n labelClassName,\n autoCompleteValue,\n autoComplete = autoCompleteValue,\n name = autoCompleteValue,\n dense,\n error,\n active,\n inline,\n stretch,\n leftAddon,\n leftAddonProps,\n rightAddon,\n rightAddonProps,\n disableLeftAddonStyles,\n disableRightAddonStyles,\n inputStyle,\n inputClassName,\n theme,\n underlineDirection,\n messageProps,\n messageContainerProps,\n containerProps,\n ...remaining\n } = props;\n const { disabled, readOnly } = props;\n const id = useEnsuredId(propId, \"text-field\");\n\n let { placeholder = \"\" } = props;\n if (label && !placeholder) {\n // See the placeholder type definition comments for information\n placeholder = \" \";\n }\n\n return (\n <FormMessageContainer\n {...messageContainerProps}\n messageProps={\n messageProps && {\n error,\n theme,\n ...messageProps,\n }\n }\n >\n <TextFieldContainer\n {...containerProps}\n style={style}\n className={className}\n theme={theme}\n label={!!label}\n error={error}\n dense={dense}\n inline={inline}\n active={active}\n stretch={stretch}\n readOnly={readOnly}\n disabled={disabled}\n leftAddon={leftAddon}\n leftAddonProps={leftAddonProps}\n rightAddon={rightAddon}\n rightAddonProps={rightAddonProps}\n underlineDirection={underlineDirection}\n disableLeftAddonStyles={disableLeftAddonStyles}\n disableRightAddonStyles={disableRightAddonStyles}\n >\n <input\n {...remaining}\n id={id}\n ref={ref}\n type={type}\n name={name}\n disabled={disabled}\n placeholder={placeholder}\n autoComplete={autoComplete}\n style={inputStyle}\n className={textField({\n className: inputClassName,\n placeholderHidden: !!label && !active,\n })}\n />\n {label && (\n <Label\n floating\n dense={dense}\n error={error}\n active={active}\n disabled={disabled}\n {...labelProps}\n htmlFor={id}\n style={labelProps?.style ?? labelStyle}\n className={labelProps?.className ?? labelClassName}\n >\n {label}\n </Label>\n )}\n </TextFieldContainer>\n </FormMessageContainer>\n );\n }\n);\n"],"names":["forwardRef","useEnsuredId","FormMessageContainer","Label","TextFieldContainer","textField","TextField","props","ref","id","propId","style","className","type","label","labelProps","labelStyle","labelClassName","autoCompleteValue","autoComplete","name","dense","error","active","inline","stretch","leftAddon","leftAddonProps","rightAddon","rightAddonProps","disableLeftAddonStyles","disableRightAddonStyles","inputStyle","inputClassName","theme","underlineDirection","messageProps","messageContainerProps","containerProps","remaining","disabled","readOnly","placeholder","input","placeholderHidden","floating","htmlFor"],"mappings":";AAAA,SACEA,UAAU,QAIL,QAAQ;AAEf,SAASC,YAAY,QAAQ,qBAAqB;AAClD,SAASC,oBAAoB,QAAQ,4BAA4B;AACjE,SAASC,KAAK,QAAQ,aAAa;AACnC,SAASC,kBAAkB,QAAQ,0BAA0B;AAC7D,SAASC,SAAS,QAAQ,uBAAuB;AAiFjD;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2BC,GACD,OAAO,MAAMC,0BAAYN,WACvB,SAASM,UAAUC,KAAK,EAAEC,GAAG;IAC3B,MAAM,EACJC,IAAIC,MAAM,EACVC,KAAK,EACLC,SAAS,EACTC,OAAO,MAAM,EACbC,KAAK,EACLC,UAAU,EACVC,UAAU,EACVC,cAAc,EACdC,iBAAiB,EACjBC,eAAeD,iBAAiB,EAChCE,OAAOF,iBAAiB,EACxBG,KAAK,EACLC,KAAK,EACLC,MAAM,EACNC,MAAM,EACNC,OAAO,EACPC,SAAS,EACTC,cAAc,EACdC,UAAU,EACVC,eAAe,EACfC,sBAAsB,EACtBC,uBAAuB,EACvBC,UAAU,EACVC,cAAc,EACdC,KAAK,EACLC,kBAAkB,EAClBC,YAAY,EACZC,qBAAqB,EACrBC,cAAc,EACd,GAAGC,WACJ,GAAGhC;IACJ,MAAM,EAAEiC,QAAQ,EAAEC,QAAQ,EAAE,GAAGlC;IAC/B,MAAME,KAAKR,aAAaS,QAAQ;IAEhC,IAAI,EAAEgC,cAAc,EAAE,EAAE,GAAGnC;IAC3B,IAAIO,SAAS,CAAC4B,aAAa;QACzB,+DAA+D;QAC/DA,cAAc;IAChB;IAEA,qBACE,KAACxC;QACE,GAAGmC,qBAAqB;QACzBD,cACEA,gBAAgB;YACdd;YACAY;YACA,GAAGE,YAAY;QACjB;kBAGF,cAAA,MAAChC;YACE,GAAGkC,cAAc;YAClB3B,OAAOA;YACPC,WAAWA;YACXsB,OAAOA;YACPpB,OAAO,CAAC,CAACA;YACTQ,OAAOA;YACPD,OAAOA;YACPG,QAAQA;YACRD,QAAQA;YACRE,SAASA;YACTgB,UAAUA;YACVD,UAAUA;YACVd,WAAWA;YACXC,gBAAgBA;YAChBC,YAAYA;YACZC,iBAAiBA;YACjBM,oBAAoBA;YACpBL,wBAAwBA;YACxBC,yBAAyBA;;8BAEzB,KAACY;oBACE,GAAGJ,SAAS;oBACb9B,IAAIA;oBACJD,KAAKA;oBACLK,MAAMA;oBACNO,MAAMA;oBACNoB,UAAUA;oBACVE,aAAaA;oBACbvB,cAAcA;oBACdR,OAAOqB;oBACPpB,WAAWP,UAAU;wBACnBO,WAAWqB;wBACXW,mBAAmB,CAAC,CAAC9B,SAAS,CAACS;oBACjC;;gBAEDT,uBACC,KAACX;oBACC0C,QAAQ;oBACRxB,OAAOA;oBACPC,OAAOA;oBACPC,QAAQA;oBACRiB,UAAUA;oBACT,GAAGzB,UAAU;oBACd+B,SAASrC;oBACTE,OAAOI,YAAYJ,SAASK;oBAC5BJ,WAAWG,YAAYH,aAAaK;8BAEnCH;;;;;AAMb,GACA"}
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { type ConfigurableTextFieldAddonProps } from "./types.js";
3
2
  /** @since 6.0.0 */
4
3
  export interface TextFieldAddonClassNameOptions {
@@ -34,9 +33,7 @@ export interface TextFieldAddonProps extends ConfigurableTextFieldAddonProps {
34
33
  disabled?: boolean;
35
34
  }
36
35
  /**
37
- * **Server Component**
38
- *
39
- * This component is used to add an an icon before or after the text field with
36
+ * This component is used to add an icon before or after the text field with
40
37
  * correct styling.
41
38
  */
42
39
  export declare const TextFieldAddon: import("react").ForwardRefExoticComponent<TextFieldAddonProps & import("react").RefAttributes<HTMLSpanElement>>;
@@ -17,9 +17,7 @@ const styles = bem("rmd-text-field-addon");
17
17
  }), className);
18
18
  }
19
19
  /**
20
- * **Server Component**
21
- *
22
- * This component is used to add an an icon before or after the text field with
20
+ * This component is used to add an icon before or after the text field with
23
21
  * correct styling.
24
22
  */ export const TextFieldAddon = /*#__PURE__*/ forwardRef(function TextFieldAddon(props, ref) {
25
23
  const { after, disabled, pointerEvents, children, className, ...remaining } = props;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/form/TextFieldAddon.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { forwardRef } from \"react\";\nimport { box } from \"../box/styles.js\";\nimport { bem } from \"../utils/bem.js\";\nimport { type ConfigurableTextFieldAddonProps } from \"./types.js\";\n\nconst styles = bem(\"rmd-text-field-addon\");\n\n/** @since 6.0.0 */\nexport interface TextFieldAddonClassNameOptions {\n className?: string;\n\n /**\n * @defaultValue `false`\n */\n after?: boolean;\n\n /**\n *\n * @defaultValue `true`\n */\n presentational?: boolean;\n}\n\n/**\n * @since 6.0.0\n */\nexport function textFieldAddon(\n options: TextFieldAddonClassNameOptions = {}\n): string {\n const { className, after, presentational } = options;\n\n return cnb(\n styles({\n before: !after,\n after,\n presentational,\n }),\n box({ disablePadding: true }),\n className\n );\n}\n\n/**\n * @since 6.0.0 Split props into `ConfigurableTextFieldAddonProps`\n */\nexport interface TextFieldAddonProps extends ConfigurableTextFieldAddonProps {\n /**\n * @defaultValue `false`\n */\n after?: boolean;\n\n /**\n * Set this to `true` if the addon should not be wrapped in a `<span>` with some\n * additional styles.\n *\n * @defaultValue `false`\n */\n disabled?: boolean;\n}\n\n/**\n * **Server Component**\n *\n * This component is used to add an an icon before or after the text field with\n * correct styling.\n */\nexport const TextFieldAddon = forwardRef<HTMLSpanElement, TextFieldAddonProps>(\n function TextFieldAddon(props, ref) {\n const {\n after,\n disabled,\n pointerEvents,\n children,\n className,\n ...remaining\n } = props;\n\n if (!children) {\n return null;\n }\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <span\n {...remaining}\n ref={ref}\n className={textFieldAddon({\n after,\n presentational: !pointerEvents,\n className,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","forwardRef","box","bem","styles","textFieldAddon","options","className","after","presentational","before","disablePadding","TextFieldAddon","props","ref","disabled","pointerEvents","children","remaining","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SAASC,UAAU,QAAQ,QAAQ;AACnC,SAASC,GAAG,QAAQ,mBAAmB;AACvC,SAASC,GAAG,QAAQ,kBAAkB;AAGtC,MAAMC,SAASD,IAAI;AAkBnB;;CAEC,GACD,OAAO,SAASE,eACdC,UAA0C,CAAC,CAAC;IAE5C,MAAM,EAAEC,SAAS,EAAEC,KAAK,EAAEC,cAAc,EAAE,GAAGH;IAE7C,OAAON,IACLI,OAAO;QACLM,QAAQ,CAACF;QACTA;QACAC;IACF,IACAP,IAAI;QAAES,gBAAgB;IAAK,IAC3BJ;AAEJ;AAoBA;;;;;CAKC,GACD,OAAO,MAAMK,+BAAiBX,WAC5B,SAASW,eAAeC,KAAK,EAAEC,GAAG;IAChC,MAAM,EACJN,KAAK,EACLO,QAAQ,EACRC,aAAa,EACbC,QAAQ,EACRV,SAAS,EACT,GAAGW,WACJ,GAAGL;IAEJ,IAAI,CAACI,UAAU;QACb,OAAO;IACT;IAEA,IAAIF,UAAU;QACZ,qBAAO;sBAAGE;;IACZ;IAEA,qBACE,KAACE;QACE,GAAGD,SAAS;QACbJ,KAAKA;QACLP,WAAWF,eAAe;YACxBG;YACAC,gBAAgB,CAACO;YACjBT;QACF;kBAECU;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/form/TextFieldAddon.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport { forwardRef } from \"react\";\nimport { box } from \"../box/styles.js\";\nimport { bem } from \"../utils/bem.js\";\nimport { type ConfigurableTextFieldAddonProps } from \"./types.js\";\n\nconst styles = bem(\"rmd-text-field-addon\");\n\n/** @since 6.0.0 */\nexport interface TextFieldAddonClassNameOptions {\n className?: string;\n\n /**\n * @defaultValue `false`\n */\n after?: boolean;\n\n /**\n *\n * @defaultValue `true`\n */\n presentational?: boolean;\n}\n\n/**\n * @since 6.0.0\n */\nexport function textFieldAddon(\n options: TextFieldAddonClassNameOptions = {}\n): string {\n const { className, after, presentational } = options;\n\n return cnb(\n styles({\n before: !after,\n after,\n presentational,\n }),\n box({ disablePadding: true }),\n className\n );\n}\n\n/**\n * @since 6.0.0 Split props into `ConfigurableTextFieldAddonProps`\n */\nexport interface TextFieldAddonProps extends ConfigurableTextFieldAddonProps {\n /**\n * @defaultValue `false`\n */\n after?: boolean;\n\n /**\n * Set this to `true` if the addon should not be wrapped in a `<span>` with some\n * additional styles.\n *\n * @defaultValue `false`\n */\n disabled?: boolean;\n}\n\n/**\n * This component is used to add an icon before or after the text field with\n * correct styling.\n */\nexport const TextFieldAddon = forwardRef<HTMLSpanElement, TextFieldAddonProps>(\n function TextFieldAddon(props, ref) {\n const {\n after,\n disabled,\n pointerEvents,\n children,\n className,\n ...remaining\n } = props;\n\n if (!children) {\n return null;\n }\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <span\n {...remaining}\n ref={ref}\n className={textFieldAddon({\n after,\n presentational: !pointerEvents,\n className,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","forwardRef","box","bem","styles","textFieldAddon","options","className","after","presentational","before","disablePadding","TextFieldAddon","props","ref","disabled","pointerEvents","children","remaining","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SAASC,UAAU,QAAQ,QAAQ;AACnC,SAASC,GAAG,QAAQ,mBAAmB;AACvC,SAASC,GAAG,QAAQ,kBAAkB;AAGtC,MAAMC,SAASD,IAAI;AAkBnB;;CAEC,GACD,OAAO,SAASE,eACdC,UAA0C,CAAC,CAAC;IAE5C,MAAM,EAAEC,SAAS,EAAEC,KAAK,EAAEC,cAAc,EAAE,GAAGH;IAE7C,OAAON,IACLI,OAAO;QACLM,QAAQ,CAACF;QACTA;QACAC;IACF,IACAP,IAAI;QAAES,gBAAgB;IAAK,IAC3BJ;AAEJ;AAoBA;;;CAGC,GACD,OAAO,MAAMK,+BAAiBX,WAC5B,SAASW,eAAeC,KAAK,EAAEC,GAAG;IAChC,MAAM,EACJN,KAAK,EACLO,QAAQ,EACRC,aAAa,EACbC,QAAQ,EACRV,SAAS,EACT,GAAGW,WACJ,GAAGL;IAEJ,IAAI,CAACI,UAAU;QACb,OAAO;IACT;IAEA,IAAIF,UAAU;QACZ,qBAAO;sBAAGE;;IACZ;IAEA,qBACE,KAACE;QACE,GAAGD,SAAS;QACbJ,KAAKA;QACLP,WAAWF,eAAe;YACxBG;YACAC,gBAAgB,CAACO;YACjBT;QACF;kBAECU;;AAGP,GACA"}
@@ -16,8 +16,6 @@ export interface FontIconProps extends HTMLAttributes<HTMLSpanElement>, FontIcon
16
16
  children?: ReactNode;
17
17
  }
18
18
  /**
19
- * **Server Component**
20
- *
21
19
  * The `FontIcon` component is used for rendering a font-icon library's icon.
22
20
  * The default is to use the `material-icons` library, but others can be used as
23
21
  * well.
@@ -2,8 +2,6 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { icon } from "./styles.js";
4
4
  /**
5
- * **Server Component**
6
- *
7
5
  * The `FontIcon` component is used for rendering a font-icon library's icon.
8
6
  * The default is to use the `material-icons` library, but others can be used as
9
7
  * well.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/FontIcon.tsx"],"sourcesContent":["import {\n forwardRef,\n type AriaAttributes,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { icon, type FontIconClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Removed the `forceSize`/`forceFontSize` props and added the\n * `inline` and `theme` props.\n */\nexport interface FontIconProps\n extends HTMLAttributes<HTMLSpanElement>,\n FontIconClassNameOptions {\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n\n /**\n * Any children to render to create the font icon. This is required for\n * material-icons.\n *\n * @example `<FontIcon>clear</FontIcon>`\n */\n children?: ReactNode;\n}\n\n/**\n * **Server Component**\n *\n * The `FontIcon` component is used for rendering a font-icon library's icon.\n * The default is to use the `material-icons` library, but others can be used as\n * well.\n *\n * @since 6.0.0 Switched from `<i>` to `<span>` element and removed\n * the `forceSize`/`forceFontSize` props.\n */\nexport const FontIcon = forwardRef<HTMLElement, FontIconProps>(\n function FontIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n iconClassName = \"material-icons\",\n dense = false,\n theme,\n className,\n children,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"font\",\n dense,\n theme,\n className,\n iconClassName,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["forwardRef","icon","FontIcon","props","ref","ariaHidden","iconClassName","dense","theme","className","children","remaining","span","aria-hidden","type"],"mappings":";AAAA,SACEA,UAAU,QAIL,QAAQ;AACf,SAASC,IAAI,QAAuC,cAAc;AAqBlE;;;;;;;;;CASC,GACD,OAAO,MAAMC,yBAAWF,WACtB,SAASE,SAASC,KAAK,EAAEC,GAAG;IAC1B,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,gBAAgB,gBAAgB,EAChCC,QAAQ,KAAK,EACbC,KAAK,EACLC,SAAS,EACTC,QAAQ,EACR,GAAGC,WACJ,GAAGR;IAEJ,qBACE,KAACS;QACE,GAAGD,SAAS;QACbE,eAAaR;QACbD,KAAKA;QACLK,WAAWR,KAAK;YACda,MAAM;YACNP;YACAC;YACAC;YACAH;QACF;kBAECI;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/icon/FontIcon.tsx"],"sourcesContent":["import {\n forwardRef,\n type AriaAttributes,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { icon, type FontIconClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Removed the `forceSize`/`forceFontSize` props and added the\n * `inline` and `theme` props.\n */\nexport interface FontIconProps\n extends HTMLAttributes<HTMLSpanElement>,\n FontIconClassNameOptions {\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n\n /**\n * Any children to render to create the font icon. This is required for\n * material-icons.\n *\n * @example `<FontIcon>clear</FontIcon>`\n */\n children?: ReactNode;\n}\n\n/**\n * The `FontIcon` component is used for rendering a font-icon library's icon.\n * The default is to use the `material-icons` library, but others can be used as\n * well.\n *\n * @since 6.0.0 Switched from `<i>` to `<span>` element and removed\n * the `forceSize`/`forceFontSize` props.\n */\nexport const FontIcon = forwardRef<HTMLElement, FontIconProps>(\n function FontIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n iconClassName = \"material-icons\",\n dense = false,\n theme,\n className,\n children,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"font\",\n dense,\n theme,\n className,\n iconClassName,\n })}\n >\n {children}\n </span>\n );\n }\n);\n"],"names":["forwardRef","icon","FontIcon","props","ref","ariaHidden","iconClassName","dense","theme","className","children","remaining","span","aria-hidden","type"],"mappings":";AAAA,SACEA,UAAU,QAIL,QAAQ;AACf,SAASC,IAAI,QAAuC,cAAc;AAqBlE;;;;;;;CAOC,GACD,OAAO,MAAMC,yBAAWF,WACtB,SAASE,SAASC,KAAK,EAAEC,GAAG;IAC1B,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,gBAAgB,gBAAgB,EAChCC,QAAQ,KAAK,EACbC,KAAK,EACLC,SAAS,EACTC,QAAQ,EACR,GAAGC,WACJ,GAAGR;IAEJ,qBACE,KAACS;QACE,GAAGD,SAAS;QACbE,eAAaR;QACbD,KAAKA;QACLK,WAAWR,KAAK;YACda,MAAM;YACNP;YACAC;YACAC;YACAH;QACF;kBAECI;;AAGP,GACA"}
@@ -27,8 +27,6 @@ export interface IconRotatorProps extends IconRotatorBaseProps {
27
27
  children: ReactNode;
28
28
  }
29
29
  /**
30
- * **Server Component**
31
- *
32
30
  * The `IconRotator` is a simple component that is used to rotate an icon from a
33
31
  * one degrees to another.
34
32
  */
@@ -3,8 +3,6 @@ import { cnb } from "cnbuilder";
3
3
  import { Children, cloneElement, forwardRef, isValidElement } from "react";
4
4
  import { iconRotator } from "./styles.js";
5
5
  /**
6
- * **Server Component**
7
- *
8
6
  * The `IconRotator` is a simple component that is used to rotate an icon from a
9
7
  * one degrees to another.
10
8
  */ export const IconRotator = /*#__PURE__*/ forwardRef(function IconRotator(props, ref) {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/IconRotator.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n Children,\n cloneElement,\n forwardRef,\n isValidElement,\n type CSSProperties,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { iconRotator, type IconRotatorClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Removed `animate` prop and added `disableTransition`\n */\nexport interface IconRotatorBaseProps\n extends HTMLAttributes<HTMLSpanElement>,\n IconRotatorClassNameOptions {\n /**\n * An optional style to apply to the surrounding span when the `forceIconWrap`\n * prop is enabled or the children is not a single react element.\n */\n style?: CSSProperties;\n\n /**\n * Boolean if the child icon should be \"forcefully\" wrapped in a `<span>`\n * element. This should be enabled if you have a custom icon that does not\n * pass the `className` prop down.\n *\n * @defaultValue `false`\n */\n forceIconWrap?: boolean;\n}\n\nexport interface IconRotatorProps extends IconRotatorBaseProps {\n /**\n * The icon that should be rotated. If this is a valid React Element, the\n * class names will be cloned into that icon, otherwise the icon will be\n * wrapped in a span with the correct class names applied.\n */\n children: ReactNode;\n}\n\n/**\n * **Server Component**\n *\n * The `IconRotator` is a simple component that is used to rotate an icon from a\n * one degrees to another.\n */\nexport const IconRotator = forwardRef<HTMLSpanElement, IconRotatorProps>(\n function IconRotator(props, ref) {\n const {\n className: propClassName,\n rotated,\n children,\n forceIconWrap = false,\n disableTransition = false,\n ...remaining\n } = props;\n\n const className = iconRotator({\n rotated,\n className: propClassName,\n disableTransition,\n });\n if (!forceIconWrap && isValidElement<{ className?: string }>(children)) {\n const child = Children.only(children);\n return cloneElement(child, {\n className: cnb(className, child.props.className),\n });\n }\n\n return (\n <span {...remaining} ref={ref} className={className}>\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","Children","cloneElement","forwardRef","isValidElement","iconRotator","IconRotator","props","ref","className","propClassName","rotated","children","forceIconWrap","disableTransition","remaining","child","only","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,QAAQ,EACRC,YAAY,EACZC,UAAU,EACVC,cAAc,QAIT,QAAQ;AACf,SAASC,WAAW,QAA0C,cAAc;AAiC5E;;;;;CAKC,GACD,OAAO,MAAMC,4BAAcH,WACzB,SAASG,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,WAAWC,aAAa,EACxBC,OAAO,EACPC,QAAQ,EACRC,gBAAgB,KAAK,EACrBC,oBAAoB,KAAK,EACzB,GAAGC,WACJ,GAAGR;IAEJ,MAAME,YAAYJ,YAAY;QAC5BM;QACAF,WAAWC;QACXI;IACF;IACA,IAAI,CAACD,+BAAiBT,eAAuCQ,WAAW;QACtE,MAAMI,QAAQf,SAASgB,IAAI,CAACL;QAC5B,qBAAOV,aAAac,OAAO;YACzBP,WAAWT,IAAIS,WAAWO,MAAMT,KAAK,CAACE,SAAS;QACjD;IACF;IAEA,qBACE,KAACS;QAAM,GAAGH,SAAS;QAAEP,KAAKA;QAAKC,WAAWA;kBACvCG;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/icon/IconRotator.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n Children,\n cloneElement,\n forwardRef,\n isValidElement,\n type CSSProperties,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { iconRotator, type IconRotatorClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Removed `animate` prop and added `disableTransition`\n */\nexport interface IconRotatorBaseProps\n extends HTMLAttributes<HTMLSpanElement>,\n IconRotatorClassNameOptions {\n /**\n * An optional style to apply to the surrounding span when the `forceIconWrap`\n * prop is enabled or the children is not a single react element.\n */\n style?: CSSProperties;\n\n /**\n * Boolean if the child icon should be \"forcefully\" wrapped in a `<span>`\n * element. This should be enabled if you have a custom icon that does not\n * pass the `className` prop down.\n *\n * @defaultValue `false`\n */\n forceIconWrap?: boolean;\n}\n\nexport interface IconRotatorProps extends IconRotatorBaseProps {\n /**\n * The icon that should be rotated. If this is a valid React Element, the\n * class names will be cloned into that icon, otherwise the icon will be\n * wrapped in a span with the correct class names applied.\n */\n children: ReactNode;\n}\n\n/**\n * The `IconRotator` is a simple component that is used to rotate an icon from a\n * one degrees to another.\n */\nexport const IconRotator = forwardRef<HTMLSpanElement, IconRotatorProps>(\n function IconRotator(props, ref) {\n const {\n className: propClassName,\n rotated,\n children,\n forceIconWrap = false,\n disableTransition = false,\n ...remaining\n } = props;\n\n const className = iconRotator({\n rotated,\n className: propClassName,\n disableTransition,\n });\n if (!forceIconWrap && isValidElement<{ className?: string }>(children)) {\n const child = Children.only(children);\n return cloneElement(child, {\n className: cnb(className, child.props.className),\n });\n }\n\n return (\n <span {...remaining} ref={ref} className={className}>\n {children}\n </span>\n );\n }\n);\n"],"names":["cnb","Children","cloneElement","forwardRef","isValidElement","iconRotator","IconRotator","props","ref","className","propClassName","rotated","children","forceIconWrap","disableTransition","remaining","child","only","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,QAAQ,EACRC,YAAY,EACZC,UAAU,EACVC,cAAc,QAIT,QAAQ;AACf,SAASC,WAAW,QAA0C,cAAc;AAiC5E;;;CAGC,GACD,OAAO,MAAMC,4BAAcH,WACzB,SAASG,YAAYC,KAAK,EAAEC,GAAG;IAC7B,MAAM,EACJC,WAAWC,aAAa,EACxBC,OAAO,EACPC,QAAQ,EACRC,gBAAgB,KAAK,EACrBC,oBAAoB,KAAK,EACzB,GAAGC,WACJ,GAAGR;IAEJ,MAAME,YAAYJ,YAAY;QAC5BM;QACAF,WAAWC;QACXI;IACF;IACA,IAAI,CAACD,+BAAiBT,eAAuCQ,WAAW;QACtE,MAAMI,QAAQf,SAASgB,IAAI,CAACL;QAC5B,qBAAOV,aAAac,OAAO;YACzBP,WAAWT,IAAIS,WAAWO,MAAMT,KAAK,CAACE,SAAS;QACjD;IACF;IAEA,qBACE,KAACS;QAAM,GAAGH,SAAS;QAAEP,KAAKA;QAAKC,WAAWA;kBACvCG;;AAGP,GACA"}
@@ -14,8 +14,6 @@ export interface MaterialIconProps extends HTMLAttributes<HTMLSpanElement>, Part
14
14
  children?: never;
15
15
  }
16
16
  /**
17
- * **Server Component**
18
- *
19
17
  * The `MaterialIcon` component is used for rendering a material icon using the
20
18
  * Google Fonts stylesheet (handled separately). This is mostly a convenience
21
19
  * wrapper around the `FontIcon` that will catch typos for the supported icon
@@ -3,8 +3,6 @@ import { forwardRef } from "react";
3
3
  import { MATERIAL_CONFIG } from "./materialConfig.js";
4
4
  import { icon } from "./styles.js";
5
5
  /**
6
- * **Server Component**
7
- *
8
6
  * The `MaterialIcon` component is used for rendering a material icon using the
9
7
  * Google Fonts stylesheet (handled separately). This is mostly a convenience
10
8
  * wrapper around the `FontIcon` that will catch typos for the supported icon
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/MaterialIcon.tsx"],"sourcesContent":["import { forwardRef, type AriaAttributes, type HTMLAttributes } from \"react\";\nimport { type MaterialIconFamily, type MaterialIconName } from \"./material.js\";\nimport { MATERIAL_CONFIG } from \"./materialConfig.js\";\nimport { icon, type MaterialIconClassNameOptions } from \"./styles.js\";\n\n/** @since 6.0.0 */\nexport interface MaterialIconProps\n extends HTMLAttributes<HTMLSpanElement>,\n Partial<MaterialIconClassNameOptions> {\n /**\n * The icon name to use\n */\n name: MaterialIconName;\n\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n\n /** @defaultValue `MATERIAL_CONFIG.iconFamily` */\n family?: MaterialIconFamily;\n children?: never;\n}\n\n/**\n * **Server Component**\n *\n * The `MaterialIcon` component is used for rendering a material icon using the\n * Google Fonts stylesheet (handled separately). This is mostly a convenience\n * wrapper around the `FontIcon` that will catch typos for the supported icon\n * names.\n *\n * @example Simple Example\n * ```tsx\n * <MaterialIcon name=\"3k\" />\n * <MaterialIcon name=\"favorite\" theme=\"primary\" />\n * <MaterialIcon name=\"wifi\" family=\"two-tone\" dense theme=\"warning\" />\n * ```\n *\n * @since 6.0.0\n */\nexport const MaterialIcon = forwardRef<HTMLSpanElement, MaterialIconProps>(\n function MaterialIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n name,\n family = MATERIAL_CONFIG.iconFamily,\n theme,\n dense,\n className,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"material\",\n family,\n theme,\n dense,\n className,\n })}\n >\n {name}\n </span>\n );\n }\n);\n"],"names":["forwardRef","MATERIAL_CONFIG","icon","MaterialIcon","props","ref","ariaHidden","name","family","iconFamily","theme","dense","className","remaining","span","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAAkD,QAAQ;AAE7E,SAASC,eAAe,QAAQ,sBAAsB;AACtD,SAASC,IAAI,QAA2C,cAAc;AAmBtE;;;;;;;;;;;;;;;;CAgBC,GACD,OAAO,MAAMC,6BAAeH,WAC1B,SAASG,aAAaC,KAAK,EAAEC,GAAG;IAC9B,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,IAAI,EACJC,SAASP,gBAAgBQ,UAAU,EACnCC,KAAK,EACLC,KAAK,EACLC,SAAS,EACT,GAAGC,WACJ,GAAGT;IAEJ,qBACE,KAACU;QACE,GAAGD,SAAS;QACbE,eAAaT;QACbD,KAAKA;QACLO,WAAWV,KAAK;YACdc,MAAM;YACNR;YACAE;YACAC;YACAC;QACF;kBAECL;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/icon/MaterialIcon.tsx"],"sourcesContent":["import { forwardRef, type AriaAttributes, type HTMLAttributes } from \"react\";\nimport { type MaterialIconFamily, type MaterialIconName } from \"./material.js\";\nimport { MATERIAL_CONFIG } from \"./materialConfig.js\";\nimport { icon, type MaterialIconClassNameOptions } from \"./styles.js\";\n\n/** @since 6.0.0 */\nexport interface MaterialIconProps\n extends HTMLAttributes<HTMLSpanElement>,\n Partial<MaterialIconClassNameOptions> {\n /**\n * The icon name to use\n */\n name: MaterialIconName;\n\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n\n /** @defaultValue `MATERIAL_CONFIG.iconFamily` */\n family?: MaterialIconFamily;\n children?: never;\n}\n\n/**\n * The `MaterialIcon` component is used for rendering a material icon using the\n * Google Fonts stylesheet (handled separately). This is mostly a convenience\n * wrapper around the `FontIcon` that will catch typos for the supported icon\n * names.\n *\n * @example Simple Example\n * ```tsx\n * <MaterialIcon name=\"3k\" />\n * <MaterialIcon name=\"favorite\" theme=\"primary\" />\n * <MaterialIcon name=\"wifi\" family=\"two-tone\" dense theme=\"warning\" />\n * ```\n *\n * @since 6.0.0\n */\nexport const MaterialIcon = forwardRef<HTMLSpanElement, MaterialIconProps>(\n function MaterialIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n name,\n family = MATERIAL_CONFIG.iconFamily,\n theme,\n dense,\n className,\n ...remaining\n } = props;\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"material\",\n family,\n theme,\n dense,\n className,\n })}\n >\n {name}\n </span>\n );\n }\n);\n"],"names":["forwardRef","MATERIAL_CONFIG","icon","MaterialIcon","props","ref","ariaHidden","name","family","iconFamily","theme","dense","className","remaining","span","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAAkD,QAAQ;AAE7E,SAASC,eAAe,QAAQ,sBAAsB;AACtD,SAASC,IAAI,QAA2C,cAAc;AAmBtE;;;;;;;;;;;;;;CAcC,GACD,OAAO,MAAMC,6BAAeH,WAC1B,SAASG,aAAaC,KAAK,EAAEC,GAAG;IAC9B,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,IAAI,EACJC,SAASP,gBAAgBQ,UAAU,EACnCC,KAAK,EACLC,KAAK,EACLC,SAAS,EACT,GAAGC,WACJ,GAAGT;IAEJ,qBACE,KAACU;QACE,GAAGD,SAAS;QACbE,eAAaT;QACbD,KAAKA;QACLO,WAAWV,KAAK;YACdc,MAAM;YACNR;YACAE;YACAC;YACAC;QACF;kBAECL;;AAGP,GACA"}
@@ -20,7 +20,6 @@ export interface MaterialSymbolProps extends HTMLAttributes<HTMLSpanElement>, Ma
20
20
  children?: never;
21
21
  }
22
22
  /**
23
- * **Server Component**
24
23
  * This is a convenience component that provides autocomplete for all the
25
24
  * available material symbols via the `name` prop.
26
25
  *
@@ -3,7 +3,6 @@ import { forwardRef } from "react";
3
3
  import { getFontVariationSettings } from "./materialConfig.js";
4
4
  import { icon } from "./styles.js";
5
5
  /**
6
- * **Server Component**
7
6
  * This is a convenience component that provides autocomplete for all the
8
7
  * available material symbols via the `name` prop.
9
8
  *
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/MaterialSymbol.tsx"],"sourcesContent":["import { forwardRef, type AriaAttributes, type HTMLAttributes } from \"react\";\nimport { type MaterialSymbolName } from \"./material.js\";\nimport {\n getFontVariationSettings,\n type MaterialSymbolCustomization,\n type MaterialSymbolFill,\n type MaterialSymbolGrade,\n type MaterialSymbolOpticalSize,\n type MaterialSymbolWeight,\n} from \"./materialConfig.js\";\nimport { icon, type MaterialSymbolClassNameOptions } from \"./styles.js\";\n\ndeclare module \"react\" {\n interface CSSProperties {\n \"--rmd-symbol-fill\"?: MaterialSymbolFill;\n \"--rmd-symbol-wght\"?: MaterialSymbolWeight;\n \"--rmd-symbol-grad\"?: MaterialSymbolGrade;\n \"--rmd-symbol-opsz\"?: MaterialSymbolOpticalSize;\n }\n}\n\n/**\n * @since 6.0.0\n */\nexport interface MaterialSymbolProps\n extends HTMLAttributes<HTMLSpanElement>,\n MaterialSymbolCustomization,\n Partial<MaterialSymbolClassNameOptions> {\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n name: MaterialSymbolName;\n children?: never;\n}\n\n/**\n * **Server Component**\n * This is a convenience component that provides autocomplete for all the\n * available material symbols via the `name` prop.\n *\n * Note: You might notice IDE slowdowns for files that use this component since\n * there are so many icons available. If it becomes an issue, just stop using\n * this component and define the icons inline instead.\n *\n * @example Simple Example\n * ```tsx\n * import { MaterialSymbol } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n * import { createRoot } from \"react-dom/client\";\n *\n * function Example(): ReactElement {\n * return (\n * <>\n * <MaterialSymbol symbol=\"close\" />\n * <MaterialSymbol symbol=\"tune\" type=\"outline\" />\n *\n * <MaterialSymbol symbol=\"add\" type=\"round\" />\n * <MaterialSymbol symbol=\"air\" type=\"sharp\" />\n * </>\n * );\n * }\n *\n * const root = createRoot(document.getElementById(\"root\"));\n * root.render(<App />);\n * ```\n *\n * @since 6.0.0\n */\nexport const MaterialSymbol = forwardRef<HTMLSpanElement, MaterialSymbolProps>(\n function MaterialSymbol(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n className,\n name: symbol,\n style: propStyle,\n family: propFamily,\n fill,\n weight,\n grade,\n opticalSize,\n theme,\n dense,\n ...remaining\n } = props;\n const { style, family } = getFontVariationSettings({\n style: propStyle,\n fill,\n weight,\n grade,\n opticalSize,\n family: propFamily,\n });\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n style={style}\n className={icon({\n type: \"symbol\",\n family,\n theme,\n dense,\n className,\n })}\n >\n {symbol}\n </span>\n );\n }\n);\n"],"names":["forwardRef","getFontVariationSettings","icon","MaterialSymbol","props","ref","ariaHidden","className","name","symbol","style","propStyle","family","propFamily","fill","weight","grade","opticalSize","theme","dense","remaining","span","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAAkD,QAAQ;AAE7E,SACEC,wBAAwB,QAMnB,sBAAsB;AAC7B,SAASC,IAAI,QAA6C,cAAc;AAwBxE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgCC,GACD,OAAO,MAAMC,+BAAiBH,WAC5B,SAASG,eAAeC,KAAK,EAAEC,GAAG;IAChC,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,SAAS,EACTC,MAAMC,MAAM,EACZC,OAAOC,SAAS,EAChBC,QAAQC,UAAU,EAClBC,IAAI,EACJC,MAAM,EACNC,KAAK,EACLC,WAAW,EACXC,KAAK,EACLC,KAAK,EACL,GAAGC,WACJ,GAAGhB;IACJ,MAAM,EAAEM,KAAK,EAAEE,MAAM,EAAE,GAAGX,yBAAyB;QACjDS,OAAOC;QACPG;QACAC;QACAC;QACAC;QACAL,QAAQC;IACV;IAEA,qBACE,KAACQ;QACE,GAAGD,SAAS;QACbE,eAAahB;QACbD,KAAKA;QACLK,OAAOA;QACPH,WAAWL,KAAK;YACdqB,MAAM;YACNX;YACAM;YACAC;YACAZ;QACF;kBAECE;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/icon/MaterialSymbol.tsx"],"sourcesContent":["import { forwardRef, type AriaAttributes, type HTMLAttributes } from \"react\";\nimport { type MaterialSymbolName } from \"./material.js\";\nimport {\n getFontVariationSettings,\n type MaterialSymbolCustomization,\n type MaterialSymbolFill,\n type MaterialSymbolGrade,\n type MaterialSymbolOpticalSize,\n type MaterialSymbolWeight,\n} from \"./materialConfig.js\";\nimport { icon, type MaterialSymbolClassNameOptions } from \"./styles.js\";\n\ndeclare module \"react\" {\n interface CSSProperties {\n \"--rmd-symbol-fill\"?: MaterialSymbolFill;\n \"--rmd-symbol-wght\"?: MaterialSymbolWeight;\n \"--rmd-symbol-grad\"?: MaterialSymbolGrade;\n \"--rmd-symbol-opsz\"?: MaterialSymbolOpticalSize;\n }\n}\n\n/**\n * @since 6.0.0\n */\nexport interface MaterialSymbolProps\n extends HTMLAttributes<HTMLSpanElement>,\n MaterialSymbolCustomization,\n Partial<MaterialSymbolClassNameOptions> {\n /** @defaultValue `true` */\n \"aria-hidden\"?: AriaAttributes[\"aria-hidden\"];\n name: MaterialSymbolName;\n children?: never;\n}\n\n/**\n * This is a convenience component that provides autocomplete for all the\n * available material symbols via the `name` prop.\n *\n * Note: You might notice IDE slowdowns for files that use this component since\n * there are so many icons available. If it becomes an issue, just stop using\n * this component and define the icons inline instead.\n *\n * @example Simple Example\n * ```tsx\n * import { MaterialSymbol } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n * import { createRoot } from \"react-dom/client\";\n *\n * function Example(): ReactElement {\n * return (\n * <>\n * <MaterialSymbol symbol=\"close\" />\n * <MaterialSymbol symbol=\"tune\" type=\"outline\" />\n *\n * <MaterialSymbol symbol=\"add\" type=\"round\" />\n * <MaterialSymbol symbol=\"air\" type=\"sharp\" />\n * </>\n * );\n * }\n *\n * const root = createRoot(document.getElementById(\"root\"));\n * root.render(<App />);\n * ```\n *\n * @since 6.0.0\n */\nexport const MaterialSymbol = forwardRef<HTMLSpanElement, MaterialSymbolProps>(\n function MaterialSymbol(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n className,\n name: symbol,\n style: propStyle,\n family: propFamily,\n fill,\n weight,\n grade,\n opticalSize,\n theme,\n dense,\n ...remaining\n } = props;\n const { style, family } = getFontVariationSettings({\n style: propStyle,\n fill,\n weight,\n grade,\n opticalSize,\n family: propFamily,\n });\n\n return (\n <span\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n style={style}\n className={icon({\n type: \"symbol\",\n family,\n theme,\n dense,\n className,\n })}\n >\n {symbol}\n </span>\n );\n }\n);\n"],"names":["forwardRef","getFontVariationSettings","icon","MaterialSymbol","props","ref","ariaHidden","className","name","symbol","style","propStyle","family","propFamily","fill","weight","grade","opticalSize","theme","dense","remaining","span","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAAkD,QAAQ;AAE7E,SACEC,wBAAwB,QAMnB,sBAAsB;AAC7B,SAASC,IAAI,QAA6C,cAAc;AAwBxE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+BC,GACD,OAAO,MAAMC,+BAAiBH,WAC5B,SAASG,eAAeC,KAAK,EAAEC,GAAG;IAChC,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,SAAS,EACTC,MAAMC,MAAM,EACZC,OAAOC,SAAS,EAChBC,QAAQC,UAAU,EAClBC,IAAI,EACJC,MAAM,EACNC,KAAK,EACLC,WAAW,EACXC,KAAK,EACLC,KAAK,EACL,GAAGC,WACJ,GAAGhB;IACJ,MAAM,EAAEM,KAAK,EAAEE,MAAM,EAAE,GAAGX,yBAAyB;QACjDS,OAAOC;QACPG;QACAC;QACAC;QACAC;QACAL,QAAQC;IACV;IAEA,qBACE,KAACQ;QACE,GAAGD,SAAS;QACbE,eAAahB;QACbD,KAAKA;QACLK,OAAOA;QACPH,WAAWL,KAAK;YACdqB,MAAM;YACNX;YACAM;YACAC;YACAZ;QACF;kBAECE;;AAGP,GACA"}
@@ -65,8 +65,6 @@ export interface SVGIconProps extends HTMLAttributes<SVGSVGElement>, SVGIconClas
65
65
  children?: ReactNode;
66
66
  }
67
67
  /**
68
- * **Server Component**
69
- *
70
68
  * The `SVGIcon` component is used to render inline SVG icons or SVG icons in a
71
69
  * sprite map as an icon.
72
70
  */
@@ -2,8 +2,6 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { icon } from "./styles.js";
4
4
  /**
5
- * **Server Component**
6
- *
7
5
  * The `SVGIcon` component is used to render inline SVG icons or SVG icons in a
8
6
  * sprite map as an icon.
9
7
  */ export const SVGIcon = /*#__PURE__*/ forwardRef(function SVGIcon(props, ref) {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/SVGIcon.tsx"],"sourcesContent":["import { forwardRef, type HTMLAttributes, type ReactNode } from \"react\";\nimport { icon, type SVGIconClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Added the `inline` and `theme` props.\n */\nexport interface SVGIconProps\n extends HTMLAttributes<SVGSVGElement>,\n SVGIconClassNameOptions {\n /**\n * Boolean if the SVG should gain the `focusable` attribute. This is disabled\n * by default since IE11 and Edge actually default this to true and keyboard's\n * will tab focus all SVGs.\n *\n * @defaultValue `false`\n */\n focusable?: \"false\" | \"true\" | boolean;\n\n /**\n * The `viewBox` attribute allows you to specify that a given set of graphics\n * stretch to fit a particular container element.\n *\n * The value of the `viewBox` attribute is a list of four numbers min-x,\n * min-y, width and height, separated by white space and/or a comma, which\n * specify a rectangle in user space which should be mapped to the bounds of\n * the viewport established by the given element, taking into account\n * attribute `preserveAspectRatio`.\n *\n * Negative values for width or height are not permitted and a value of zero\n * disables rendering of the element. An optional `viewbox` for the SVG.\n *\n * For example, if the SVG element is 250 (width) by 200 (height) and you\n * provide `viewBox=\"0 0 25 20\"`, the coordinates inside the SVG will go from\n * the top left corner (0, 0) to the bottom right (25, 20) and each unit will\n * be worth `10px`.\n *\n * @defaultValue `\"0 0 24 24\"`\n */\n viewBox?: string;\n\n /**\n * An optional `xmlns` string to provide. The `use` prop will not work without\n * this prop defined.\n *\n *\n * Note: The default value will be `undefined` unless the {@link use} prop is\n * defined.\n *\n * @defaultValue `\"http://www.w3.org/2000/svg\"`\n */\n xmlns?: string;\n\n /**\n * This should be a link to a part of an SVG sprite map. So normally one of\n * the following:\n * - `'#some-custom-svg'`\n * - `'/images/spritemap.svg#some-custom-svg'`\n *\n * This prop **should not** be used with the `children` prop as only one will\n * be rendered.\n *\n *\n * NOTE: IE **does not support** external SVGs. Please see the demo for more\n * details.\n */\n use?: string;\n\n /**\n * Any `<svg>` children to render to create your icon. This can not be used\n * with the `use` prop.\n */\n children?: ReactNode;\n}\n\n/**\n * **Server Component**\n *\n * The `SVGIcon` component is used to render inline SVG icons or SVG icons in a\n * sprite map as an icon.\n */\nexport const SVGIcon = forwardRef<SVGSVGElement, SVGIconProps>(\n function SVGIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n focusable = \"false\",\n use,\n xmlns = use ? \"http://www.w3.org/2000/svg\" : undefined,\n viewBox = \"0 0 24 24\",\n dense = false,\n className,\n theme,\n inline,\n children: propChildren,\n ...remaining\n } = props;\n\n let children = propChildren;\n if (!children && use) {\n children = <use xlinkHref={use} />;\n }\n\n return (\n <svg\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"svg\",\n dense,\n theme,\n inline,\n className,\n })}\n focusable={focusable}\n xmlns={xmlns}\n viewBox={viewBox}\n >\n {children}\n </svg>\n );\n }\n);\n"],"names":["forwardRef","icon","SVGIcon","props","ref","ariaHidden","focusable","use","xmlns","undefined","viewBox","dense","className","theme","inline","children","propChildren","remaining","xlinkHref","svg","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAA6C,QAAQ;AACxE,SAASC,IAAI,QAAsC,cAAc;AAyEjE;;;;;CAKC,GACD,OAAO,MAAMC,wBAAUF,WACrB,SAASE,QAAQC,KAAK,EAAEC,GAAG;IACzB,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,YAAY,OAAO,EACnBC,GAAG,EACHC,QAAQD,MAAM,+BAA+BE,SAAS,EACtDC,UAAU,WAAW,EACrBC,QAAQ,KAAK,EACbC,SAAS,EACTC,KAAK,EACLC,MAAM,EACNC,UAAUC,YAAY,EACtB,GAAGC,WACJ,GAAGd;IAEJ,IAAIY,WAAWC;IACf,IAAI,CAACD,YAAYR,KAAK;QACpBQ,yBAAW,KAACR;YAAIW,WAAWX;;IAC7B;IAEA,qBACE,KAACY;QACE,GAAGF,SAAS;QACbG,eAAaf;QACbD,KAAKA;QACLQ,WAAWX,KAAK;YACdoB,MAAM;YACNV;YACAE;YACAC;YACAF;QACF;QACAN,WAAWA;QACXE,OAAOA;QACPE,SAASA;kBAERK;;AAGP,GACA"}
1
+ {"version":3,"sources":["../../src/icon/SVGIcon.tsx"],"sourcesContent":["import { forwardRef, type HTMLAttributes, type ReactNode } from \"react\";\nimport { icon, type SVGIconClassNameOptions } from \"./styles.js\";\n\n/**\n * @since 6.0.0 Added the `inline` and `theme` props.\n */\nexport interface SVGIconProps\n extends HTMLAttributes<SVGSVGElement>,\n SVGIconClassNameOptions {\n /**\n * Boolean if the SVG should gain the `focusable` attribute. This is disabled\n * by default since IE11 and Edge actually default this to true and keyboard's\n * will tab focus all SVGs.\n *\n * @defaultValue `false`\n */\n focusable?: \"false\" | \"true\" | boolean;\n\n /**\n * The `viewBox` attribute allows you to specify that a given set of graphics\n * stretch to fit a particular container element.\n *\n * The value of the `viewBox` attribute is a list of four numbers min-x,\n * min-y, width and height, separated by white space and/or a comma, which\n * specify a rectangle in user space which should be mapped to the bounds of\n * the viewport established by the given element, taking into account\n * attribute `preserveAspectRatio`.\n *\n * Negative values for width or height are not permitted and a value of zero\n * disables rendering of the element. An optional `viewbox` for the SVG.\n *\n * For example, if the SVG element is 250 (width) by 200 (height) and you\n * provide `viewBox=\"0 0 25 20\"`, the coordinates inside the SVG will go from\n * the top left corner (0, 0) to the bottom right (25, 20) and each unit will\n * be worth `10px`.\n *\n * @defaultValue `\"0 0 24 24\"`\n */\n viewBox?: string;\n\n /**\n * An optional `xmlns` string to provide. The `use` prop will not work without\n * this prop defined.\n *\n *\n * Note: The default value will be `undefined` unless the {@link use} prop is\n * defined.\n *\n * @defaultValue `\"http://www.w3.org/2000/svg\"`\n */\n xmlns?: string;\n\n /**\n * This should be a link to a part of an SVG sprite map. So normally one of\n * the following:\n * - `'#some-custom-svg'`\n * - `'/images/spritemap.svg#some-custom-svg'`\n *\n * This prop **should not** be used with the `children` prop as only one will\n * be rendered.\n *\n *\n * NOTE: IE **does not support** external SVGs. Please see the demo for more\n * details.\n */\n use?: string;\n\n /**\n * Any `<svg>` children to render to create your icon. This can not be used\n * with the `use` prop.\n */\n children?: ReactNode;\n}\n\n/**\n * The `SVGIcon` component is used to render inline SVG icons or SVG icons in a\n * sprite map as an icon.\n */\nexport const SVGIcon = forwardRef<SVGSVGElement, SVGIconProps>(\n function SVGIcon(props, ref) {\n const {\n \"aria-hidden\": ariaHidden = true,\n focusable = \"false\",\n use,\n xmlns = use ? \"http://www.w3.org/2000/svg\" : undefined,\n viewBox = \"0 0 24 24\",\n dense = false,\n className,\n theme,\n inline,\n children: propChildren,\n ...remaining\n } = props;\n\n let children = propChildren;\n if (!children && use) {\n children = <use xlinkHref={use} />;\n }\n\n return (\n <svg\n {...remaining}\n aria-hidden={ariaHidden}\n ref={ref}\n className={icon({\n type: \"svg\",\n dense,\n theme,\n inline,\n className,\n })}\n focusable={focusable}\n xmlns={xmlns}\n viewBox={viewBox}\n >\n {children}\n </svg>\n );\n }\n);\n"],"names":["forwardRef","icon","SVGIcon","props","ref","ariaHidden","focusable","use","xmlns","undefined","viewBox","dense","className","theme","inline","children","propChildren","remaining","xlinkHref","svg","aria-hidden","type"],"mappings":";AAAA,SAASA,UAAU,QAA6C,QAAQ;AACxE,SAASC,IAAI,QAAsC,cAAc;AAyEjE;;;CAGC,GACD,OAAO,MAAMC,wBAAUF,WACrB,SAASE,QAAQC,KAAK,EAAEC,GAAG;IACzB,MAAM,EACJ,eAAeC,aAAa,IAAI,EAChCC,YAAY,OAAO,EACnBC,GAAG,EACHC,QAAQD,MAAM,+BAA+BE,SAAS,EACtDC,UAAU,WAAW,EACrBC,QAAQ,KAAK,EACbC,SAAS,EACTC,KAAK,EACLC,MAAM,EACNC,UAAUC,YAAY,EACtB,GAAGC,WACJ,GAAGd;IAEJ,IAAIY,WAAWC;IACf,IAAI,CAACD,YAAYR,KAAK;QACpBQ,yBAAW,KAACR;YAAIW,WAAWX;;IAC7B;IAEA,qBACE,KAACY;QACE,GAAGF,SAAS;QACbG,eAAaf;QACbD,KAAKA;QACLQ,WAAWX,KAAK;YACdoB,MAAM;YACNV;YACAE;YACAC;YACAF;QACF;QACAN,WAAWA;QACXE,OAAOA;QACPE,SAASA;kBAERK;;AAGP,GACA"}
@@ -85,8 +85,6 @@ export interface TextIconSpacingProps {
85
85
  flexReverse?: boolean;
86
86
  }
87
87
  /**
88
- * **Server Component**
89
- *
90
88
  * Note: This component **must** be rendered within a flex container unless the
91
89
  * {@link TextIconSpacingProps.forceIconWrap} is set to `true`.
92
90
  *
@@ -2,8 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
2
2
  import { cnb } from "cnbuilder";
3
3
  import { Children, cloneElement, isValidElement } from "react";
4
4
  /**
5
- * **Server Component**
6
- *
7
5
  * Note: This component **must** be rendered within a flex container unless the
8
6
  * {@link TextIconSpacingProps.forceIconWrap} is set to `true`.
9
7
  *
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/icon/TextIconSpacing.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n Children,\n cloneElement,\n isValidElement,\n type ReactElement,\n type ReactNode,\n} from \"react\";\n\nexport interface TextIconSpacingProps {\n /**\n * An optional className to apply to the surrounding `<span>` when the\n * `forceIconWrap` prop is enabled or the icon is not a valid React Element.\n * If the `forceIconWrap` prop is not enabled, it will be cloned into the icon\n * instead.\n */\n className?: string;\n\n /**\n * An optional icon to display with a text button. This is invalid for icon\n * buttons. If this is a single element, a new class name will be cloned into\n * the element to get correct spacing so if you have a custom icon element,\n * you **must** also pass that class name down. If you are using one of the\n * react-md icon component packages, this is handled automatically.\n *\n * If this is not a valid react element, the icon will be wrapped in a\n * `<span>` instead with the class names applied.\n */\n icon?: ReactElement | ReactNode;\n\n /**\n * Boolean if the icon should appear after the text instead of before.\n *\n * @defaultValue `false`\n */\n iconAfter?: boolean;\n\n /**\n * The children to render before or after the provided icon. This is defaulted\n * to `null` so that providing a `null` icon will correctly render without\n * React crashing.\n *\n * @defaultValue `null`\n */\n children?: ReactNode;\n\n /**\n * The class name to use for an icon that is placed before text.\n *\n * @defaultValue `\"rmd-icon--before\"`\n */\n beforeClassName?: string;\n\n /**\n * The class name to use for an icon that is placed after text.\n *\n * @defaultValue `\"rmd-icon--after\"`\n */\n afterClassName?: string;\n\n /**\n * The class name to use for an icon that is placed before above the text.\n * This is used when the `stacked` prop is enabled and the `iconAfter` prop is\n * disabled or omitted.\n *\n * @defaultValue `\"rmd-icon--above\"`\n */\n aboveClassName?: string;\n\n /**\n * The class name to use for an icon that is placed before above the text.\n * This is used when the `stacked` prop is enabled and the `iconAfter` prop is\n * enabled.\n *\n * @defaultValue `\"rmd-icon--below\"`\n */\n belowClassName?: string;\n\n /**\n * Boolean if the icon should be forced into a `<span>` with the class names\n * applied instead of attempting to clone into the provided icon.\n *\n * @defaultValue `false`\n */\n forceIconWrap?: boolean;\n\n /**\n * Boolean if the icon and text should be stacked instead of inline. Note:\n * You'll normally want to update the container element to have\n * `display: flex` and `flex-direction: column` for this to work.\n *\n * @defaultValue `false`\n */\n stacked?: boolean;\n\n /**\n * Boolean if the icon and content are in a `column-reverse` or `row-reverse`\n * `flex-direction`. This will swap the different classnames as needed.\n *\n * @since 2.5.0\n * @defaultValue `false`\n */\n flexReverse?: boolean;\n}\n\n/**\n * **Server Component**\n *\n * Note: This component **must** be rendered within a flex container unless the\n * {@link TextIconSpacingProps.forceIconWrap} is set to `true`.\n *\n * @example Simple Example\n * ```tsx\n * import { TextIconSpacing, FontIcon } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextIconSpacing icon={<FontIcon>favorite</FontIcon>}>\n * Favorite\n * </TextIconSpacing>\n * );\n * }\n * ```\n *\n * @example Stacked Example\n * ```tsx\n * import { TextIconSpacing, FontIcon } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextIconSpacing icon={<FontIcon>favorite</FontIcon>} stacked>\n * Favorite\n * </TextIconSpacing>\n * );\n * }\n * ```\n */\nexport function TextIconSpacing(props: TextIconSpacingProps): ReactElement {\n const {\n className,\n icon: propIcon,\n children = null,\n stacked = false,\n iconAfter = false,\n flexReverse = false,\n forceIconWrap = false,\n beforeClassName = \"rmd-icon--before\",\n afterClassName = \"rmd-icon--after\",\n aboveClassName = \"rmd-icon--above\",\n belowClassName = \"rmd-icon--below\",\n } = props;\n\n if (!propIcon) {\n return <>{children}</>;\n }\n\n const isAfter = flexReverse ? !iconAfter : iconAfter;\n const baseClassName = cnb(\n {\n [beforeClassName]: !stacked && !isAfter,\n [afterClassName]: !stacked && isAfter,\n [aboveClassName]: stacked && !isAfter,\n [belowClassName]: stacked && isAfter,\n },\n className\n );\n\n let iconEl = propIcon;\n let content = children;\n if (!forceIconWrap && isValidElement<{ className?: string }>(propIcon)) {\n const icon = Children.only(propIcon);\n iconEl = cloneElement(icon, {\n className: cnb(baseClassName, icon.props.className),\n });\n } else if (propIcon) {\n iconEl = (\n <span className={cnb(\"rmd-text-icon-spacing\", baseClassName)}>\n {propIcon}\n </span>\n );\n }\n\n if (iconEl) {\n content = (\n <>\n {!iconAfter && iconEl}\n {children}\n {iconAfter && iconEl}\n </>\n );\n }\n\n return <>{content}</>;\n}\n"],"names":["cnb","Children","cloneElement","isValidElement","TextIconSpacing","props","className","icon","propIcon","children","stacked","iconAfter","flexReverse","forceIconWrap","beforeClassName","afterClassName","aboveClassName","belowClassName","isAfter","baseClassName","iconEl","content","only","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,QAAQ,EACRC,YAAY,EACZC,cAAc,QAGT,QAAQ;AAkGf;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCC,GACD,OAAO,SAASC,gBAAgBC,KAA2B;IACzD,MAAM,EACJC,SAAS,EACTC,MAAMC,QAAQ,EACdC,WAAW,IAAI,EACfC,UAAU,KAAK,EACfC,YAAY,KAAK,EACjBC,cAAc,KAAK,EACnBC,gBAAgB,KAAK,EACrBC,kBAAkB,kBAAkB,EACpCC,iBAAiB,iBAAiB,EAClCC,iBAAiB,iBAAiB,EAClCC,iBAAiB,iBAAiB,EACnC,GAAGZ;IAEJ,IAAI,CAACG,UAAU;QACb,qBAAO;sBAAGC;;IACZ;IAEA,MAAMS,UAAUN,cAAc,CAACD,YAAYA;IAC3C,MAAMQ,gBAAgBnB,IACpB;QACE,CAACc,gBAAgB,EAAE,CAACJ,WAAW,CAACQ;QAChC,CAACH,eAAe,EAAE,CAACL,WAAWQ;QAC9B,CAACF,eAAe,EAAEN,WAAW,CAACQ;QAC9B,CAACD,eAAe,EAAEP,WAAWQ;IAC/B,GACAZ;IAGF,IAAIc,SAASZ;IACb,IAAIa,UAAUZ;IACd,IAAI,CAACI,+BAAiBV,eAAuCK,WAAW;QACtE,MAAMD,OAAON,SAASqB,IAAI,CAACd;QAC3BY,uBAASlB,aAAaK,MAAM;YAC1BD,WAAWN,IAAImB,eAAeZ,KAAKF,KAAK,CAACC,SAAS;QACpD;IACF,OAAO,IAAIE,UAAU;QACnBY,uBACE,KAACG;YAAKjB,WAAWN,IAAI,yBAAyBmB;sBAC3CX;;IAGP;IAEA,IAAIY,QAAQ;QACVC,wBACE;;gBACG,CAACV,aAAaS;gBACdX;gBACAE,aAAaS;;;IAGpB;IAEA,qBAAO;kBAAGC;;AACZ"}
1
+ {"version":3,"sources":["../../src/icon/TextIconSpacing.tsx"],"sourcesContent":["import { cnb } from \"cnbuilder\";\nimport {\n Children,\n cloneElement,\n isValidElement,\n type ReactElement,\n type ReactNode,\n} from \"react\";\n\nexport interface TextIconSpacingProps {\n /**\n * An optional className to apply to the surrounding `<span>` when the\n * `forceIconWrap` prop is enabled or the icon is not a valid React Element.\n * If the `forceIconWrap` prop is not enabled, it will be cloned into the icon\n * instead.\n */\n className?: string;\n\n /**\n * An optional icon to display with a text button. This is invalid for icon\n * buttons. If this is a single element, a new class name will be cloned into\n * the element to get correct spacing so if you have a custom icon element,\n * you **must** also pass that class name down. If you are using one of the\n * react-md icon component packages, this is handled automatically.\n *\n * If this is not a valid react element, the icon will be wrapped in a\n * `<span>` instead with the class names applied.\n */\n icon?: ReactElement | ReactNode;\n\n /**\n * Boolean if the icon should appear after the text instead of before.\n *\n * @defaultValue `false`\n */\n iconAfter?: boolean;\n\n /**\n * The children to render before or after the provided icon. This is defaulted\n * to `null` so that providing a `null` icon will correctly render without\n * React crashing.\n *\n * @defaultValue `null`\n */\n children?: ReactNode;\n\n /**\n * The class name to use for an icon that is placed before text.\n *\n * @defaultValue `\"rmd-icon--before\"`\n */\n beforeClassName?: string;\n\n /**\n * The class name to use for an icon that is placed after text.\n *\n * @defaultValue `\"rmd-icon--after\"`\n */\n afterClassName?: string;\n\n /**\n * The class name to use for an icon that is placed before above the text.\n * This is used when the `stacked` prop is enabled and the `iconAfter` prop is\n * disabled or omitted.\n *\n * @defaultValue `\"rmd-icon--above\"`\n */\n aboveClassName?: string;\n\n /**\n * The class name to use for an icon that is placed before above the text.\n * This is used when the `stacked` prop is enabled and the `iconAfter` prop is\n * enabled.\n *\n * @defaultValue `\"rmd-icon--below\"`\n */\n belowClassName?: string;\n\n /**\n * Boolean if the icon should be forced into a `<span>` with the class names\n * applied instead of attempting to clone into the provided icon.\n *\n * @defaultValue `false`\n */\n forceIconWrap?: boolean;\n\n /**\n * Boolean if the icon and text should be stacked instead of inline. Note:\n * You'll normally want to update the container element to have\n * `display: flex` and `flex-direction: column` for this to work.\n *\n * @defaultValue `false`\n */\n stacked?: boolean;\n\n /**\n * Boolean if the icon and content are in a `column-reverse` or `row-reverse`\n * `flex-direction`. This will swap the different classnames as needed.\n *\n * @since 2.5.0\n * @defaultValue `false`\n */\n flexReverse?: boolean;\n}\n\n/**\n * Note: This component **must** be rendered within a flex container unless the\n * {@link TextIconSpacingProps.forceIconWrap} is set to `true`.\n *\n * @example Simple Example\n * ```tsx\n * import { TextIconSpacing, FontIcon } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextIconSpacing icon={<FontIcon>favorite</FontIcon>}>\n * Favorite\n * </TextIconSpacing>\n * );\n * }\n * ```\n *\n * @example Stacked Example\n * ```tsx\n * import { TextIconSpacing, FontIcon } from \"@react-md/core\";\n * import type { ReactElement } from \"react\";\n *\n * function Example(): ReactElement {\n * return (\n * <TextIconSpacing icon={<FontIcon>favorite</FontIcon>} stacked>\n * Favorite\n * </TextIconSpacing>\n * );\n * }\n * ```\n */\nexport function TextIconSpacing(props: TextIconSpacingProps): ReactElement {\n const {\n className,\n icon: propIcon,\n children = null,\n stacked = false,\n iconAfter = false,\n flexReverse = false,\n forceIconWrap = false,\n beforeClassName = \"rmd-icon--before\",\n afterClassName = \"rmd-icon--after\",\n aboveClassName = \"rmd-icon--above\",\n belowClassName = \"rmd-icon--below\",\n } = props;\n\n if (!propIcon) {\n return <>{children}</>;\n }\n\n const isAfter = flexReverse ? !iconAfter : iconAfter;\n const baseClassName = cnb(\n {\n [beforeClassName]: !stacked && !isAfter,\n [afterClassName]: !stacked && isAfter,\n [aboveClassName]: stacked && !isAfter,\n [belowClassName]: stacked && isAfter,\n },\n className\n );\n\n let iconEl = propIcon;\n let content = children;\n if (!forceIconWrap && isValidElement<{ className?: string }>(propIcon)) {\n const icon = Children.only(propIcon);\n iconEl = cloneElement(icon, {\n className: cnb(baseClassName, icon.props.className),\n });\n } else if (propIcon) {\n iconEl = (\n <span className={cnb(\"rmd-text-icon-spacing\", baseClassName)}>\n {propIcon}\n </span>\n );\n }\n\n if (iconEl) {\n content = (\n <>\n {!iconAfter && iconEl}\n {children}\n {iconAfter && iconEl}\n </>\n );\n }\n\n return <>{content}</>;\n}\n"],"names":["cnb","Children","cloneElement","isValidElement","TextIconSpacing","props","className","icon","propIcon","children","stacked","iconAfter","flexReverse","forceIconWrap","beforeClassName","afterClassName","aboveClassName","belowClassName","isAfter","baseClassName","iconEl","content","only","span"],"mappings":";AAAA,SAASA,GAAG,QAAQ,YAAY;AAChC,SACEC,QAAQ,EACRC,YAAY,EACZC,cAAc,QAGT,QAAQ;AAkGf;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+BC,GACD,OAAO,SAASC,gBAAgBC,KAA2B;IACzD,MAAM,EACJC,SAAS,EACTC,MAAMC,QAAQ,EACdC,WAAW,IAAI,EACfC,UAAU,KAAK,EACfC,YAAY,KAAK,EACjBC,cAAc,KAAK,EACnBC,gBAAgB,KAAK,EACrBC,kBAAkB,kBAAkB,EACpCC,iBAAiB,iBAAiB,EAClCC,iBAAiB,iBAAiB,EAClCC,iBAAiB,iBAAiB,EACnC,GAAGZ;IAEJ,IAAI,CAACG,UAAU;QACb,qBAAO;sBAAGC;;IACZ;IAEA,MAAMS,UAAUN,cAAc,CAACD,YAAYA;IAC3C,MAAMQ,gBAAgBnB,IACpB;QACE,CAACc,gBAAgB,EAAE,CAACJ,WAAW,CAACQ;QAChC,CAACH,eAAe,EAAE,CAACL,WAAWQ;QAC9B,CAACF,eAAe,EAAEN,WAAW,CAACQ;QAC9B,CAACD,eAAe,EAAEP,WAAWQ;IAC/B,GACAZ;IAGF,IAAIc,SAASZ;IACb,IAAIa,UAAUZ;IACd,IAAI,CAACI,+BAAiBV,eAAuCK,WAAW;QACtE,MAAMD,OAAON,SAASqB,IAAI,CAACd;QAC3BY,uBAASlB,aAAaK,MAAM;YAC1BD,WAAWN,IAAImB,eAAeZ,KAAKF,KAAK,CAACC,SAAS;QACpD;IACF,OAAO,IAAIE,UAAU;QACnBY,uBACE,KAACG;YAAKjB,WAAWN,IAAI,yBAAyBmB;sBAC3CX;;IAGP;IAEA,IAAIY,QAAQ;QACVC,wBACE;;gBACG,CAACV,aAAaS;gBACdX;gBACAE,aAAaS;;;IAGpB;IAEA,qBAAO;kBAAGC;;AACZ"}