plass-ui 0.0.1 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (408) hide show
  1. package/dist/components/accordion/PlAccordion.d.ts +98 -0
  2. package/dist/components/accordion/PlAccordion.js +1 -0
  3. package/dist/components/accordion/index.d.ts +2 -0
  4. package/dist/components/accordion/index.js +1 -0
  5. package/dist/components/alert/PlAlert.d.ts +50 -0
  6. package/dist/components/alert/PlAlert.js +1 -0
  7. package/dist/components/alert/index.d.ts +2 -0
  8. package/dist/components/alert/index.js +1 -0
  9. package/dist/components/animate-appear/PlAnimateAppear.d.ts +55 -0
  10. package/dist/components/animate-appear/PlAnimateAppear.js +1 -0
  11. package/dist/components/animate-appear/index.d.ts +2 -0
  12. package/dist/components/animate-appear/index.js +1 -0
  13. package/dist/components/animate-blink/PlAnimateBlink.d.ts +30 -0
  14. package/dist/components/animate-blink/PlAnimateBlink.js +1 -0
  15. package/dist/components/animate-blink/index.d.ts +2 -0
  16. package/dist/components/animate-blink/index.js +1 -0
  17. package/dist/components/animate-fade/PlAnimateFade.d.ts +35 -0
  18. package/dist/components/animate-fade/PlAnimateFade.js +1 -0
  19. package/dist/components/animate-fade/index.d.ts +2 -0
  20. package/dist/components/animate-fade/index.js +1 -0
  21. package/dist/components/animate-grow/PlAnimateGrow.d.ts +45 -0
  22. package/dist/components/animate-grow/PlAnimateGrow.js +1 -0
  23. package/dist/components/animate-grow/index.d.ts +2 -0
  24. package/dist/components/animate-grow/index.js +1 -0
  25. package/dist/components/animate-headline/PlAnimateHeadline.d.ts +55 -0
  26. package/dist/components/animate-headline/PlAnimateHeadline.js +1 -0
  27. package/dist/components/animate-headline/index.d.ts +2 -0
  28. package/dist/components/animate-headline/index.js +1 -0
  29. package/dist/components/animate-lighting/PlAnimateLighting.d.ts +67 -0
  30. package/dist/components/animate-lighting/PlAnimateLighting.js +1 -0
  31. package/dist/components/animate-lighting/index.d.ts +2 -0
  32. package/dist/components/animate-lighting/index.js +1 -0
  33. package/dist/components/animate-marquee/PlAnimateMarquee.d.ts +65 -0
  34. package/dist/components/animate-marquee/PlAnimateMarquee.js +1 -0
  35. package/dist/components/animate-marquee/index.d.ts +2 -0
  36. package/dist/components/animate-marquee/index.js +1 -0
  37. package/dist/components/animate-rotate/PlAnimateRotate.d.ts +52 -0
  38. package/dist/components/animate-rotate/PlAnimateRotate.js +1 -0
  39. package/dist/components/animate-rotate/index.d.ts +2 -0
  40. package/dist/components/animate-rotate/index.js +1 -0
  41. package/dist/components/animate-slide/PlAnimateSlide.d.ts +47 -0
  42. package/dist/components/animate-slide/PlAnimateSlide.js +1 -0
  43. package/dist/components/animate-slide/index.d.ts +2 -0
  44. package/dist/components/animate-slide/index.js +1 -0
  45. package/dist/components/animate-typing/PlAnimateTyping.d.ts +56 -0
  46. package/dist/components/animate-typing/PlAnimateTyping.js +1 -0
  47. package/dist/components/animate-typing/index.d.ts +2 -0
  48. package/dist/components/animate-typing/index.js +1 -0
  49. package/dist/components/animate-zoom/PlAnimateZoom.d.ts +37 -0
  50. package/dist/components/animate-zoom/PlAnimateZoom.js +1 -0
  51. package/dist/components/animate-zoom/index.d.ts +2 -0
  52. package/dist/components/animate-zoom/index.js +1 -0
  53. package/dist/components/aspect-ratio/PlAspectRatio.d.ts +64 -0
  54. package/dist/components/aspect-ratio/PlAspectRatio.js +1 -0
  55. package/dist/components/aspect-ratio/index.d.ts +2 -0
  56. package/dist/components/aspect-ratio/index.js +1 -0
  57. package/dist/components/avatar/PlAvatar.d.ts +102 -0
  58. package/dist/components/avatar/PlAvatar.js +1 -0
  59. package/dist/components/avatar/index.d.ts +2 -0
  60. package/dist/components/avatar/index.js +1 -0
  61. package/dist/components/badge/PlBadge.d.ts +86 -0
  62. package/dist/components/badge/PlBadge.js +1 -0
  63. package/dist/components/badge/index.d.ts +2 -0
  64. package/dist/components/badge/index.js +1 -0
  65. package/dist/components/blockquote/PlBlockquote.d.ts +64 -0
  66. package/dist/components/blockquote/PlBlockquote.js +1 -0
  67. package/dist/components/blockquote/index.d.ts +2 -0
  68. package/dist/components/blockquote/index.js +1 -0
  69. package/dist/components/bottom-navigation/PlBottomNavigation.d.ts +111 -0
  70. package/dist/components/bottom-navigation/PlBottomNavigation.js +1 -0
  71. package/dist/components/bottom-navigation/index.d.ts +2 -0
  72. package/dist/components/bottom-navigation/index.js +1 -0
  73. package/dist/components/box/PlBox.d.ts +50 -0
  74. package/dist/components/box/PlBox.js +1 -0
  75. package/dist/components/box/index.d.ts +2 -0
  76. package/dist/components/box/index.js +1 -0
  77. package/dist/components/breadcrumb/PlBreadcrumb.d.ts +138 -0
  78. package/dist/components/breadcrumb/PlBreadcrumb.js +1 -0
  79. package/dist/components/breadcrumb/index.d.ts +2 -0
  80. package/dist/components/breadcrumb/index.js +1 -0
  81. package/dist/components/button/{Button.d.ts → PlButton.d.ts} +3 -3
  82. package/dist/components/button/PlButton.js +1 -0
  83. package/dist/components/button/index.d.ts +2 -2
  84. package/dist/components/button/index.js +1 -1
  85. package/dist/components/button-group/PlButtonGroup.d.ts +32 -0
  86. package/dist/components/button-group/PlButtonGroup.js +1 -0
  87. package/dist/components/button-group/index.d.ts +2 -0
  88. package/dist/components/button-group/index.js +1 -0
  89. package/dist/components/card/PlCard.d.ts +81 -0
  90. package/dist/components/card/PlCard.js +1 -0
  91. package/dist/components/card/index.d.ts +2 -0
  92. package/dist/components/card/index.js +1 -0
  93. package/dist/components/carousel/PlCarousel.d.ts +78 -0
  94. package/dist/components/carousel/PlCarousel.js +1 -0
  95. package/dist/components/carousel/index.d.ts +2 -0
  96. package/dist/components/carousel/index.js +1 -0
  97. package/dist/components/chat-bubble/PlChatBubble.d.ts +127 -0
  98. package/dist/components/chat-bubble/PlChatBubble.js +1 -0
  99. package/dist/components/chat-bubble/index.d.ts +2 -0
  100. package/dist/components/chat-bubble/index.js +1 -0
  101. package/dist/components/checkbox/PlCheckbox.d.ts +39 -0
  102. package/dist/components/checkbox/PlCheckbox.js +1 -0
  103. package/dist/components/checkbox/index.d.ts +2 -0
  104. package/dist/components/checkbox/index.js +1 -0
  105. package/dist/components/chip/PlChip.d.ts +55 -0
  106. package/dist/components/chip/PlChip.js +1 -0
  107. package/dist/components/chip/index.d.ts +2 -0
  108. package/dist/components/chip/index.js +1 -0
  109. package/dist/components/collapsible/PlCollapsible.d.ts +84 -0
  110. package/dist/components/collapsible/PlCollapsible.js +1 -0
  111. package/dist/components/collapsible/index.d.ts +2 -0
  112. package/dist/components/collapsible/index.js +1 -0
  113. package/dist/components/combobox/PlCombobox.d.ts +140 -0
  114. package/dist/components/combobox/PlCombobox.js +1 -0
  115. package/dist/components/combobox/index.d.ts +2 -0
  116. package/dist/components/combobox/index.js +1 -0
  117. package/dist/components/container/PlContainer.d.ts +66 -0
  118. package/dist/components/container/PlContainer.js +1 -0
  119. package/dist/components/container/index.d.ts +2 -0
  120. package/dist/components/container/index.js +1 -0
  121. package/dist/components/date-picker/PlDatePicker.d.ts +73 -0
  122. package/dist/components/date-picker/PlDatePicker.js +1 -0
  123. package/dist/components/date-picker/index.d.ts +2 -0
  124. package/dist/components/date-picker/index.js +1 -0
  125. package/dist/components/date-range-picker/PlDateRangePicker.d.ts +91 -0
  126. package/dist/components/date-range-picker/PlDateRangePicker.js +1 -0
  127. package/dist/components/date-range-picker/index.d.ts +2 -0
  128. package/dist/components/date-range-picker/index.js +1 -0
  129. package/dist/components/date-time-picker/PlDateTimePicker.d.ts +74 -0
  130. package/dist/components/date-time-picker/PlDateTimePicker.js +1 -0
  131. package/dist/components/date-time-picker/index.d.ts +2 -0
  132. package/dist/components/date-time-picker/index.js +1 -0
  133. package/dist/components/divider/PlDivider.d.ts +73 -0
  134. package/dist/components/divider/PlDivider.js +1 -0
  135. package/dist/components/divider/index.d.ts +2 -0
  136. package/dist/components/divider/index.js +1 -0
  137. package/dist/components/drawer/PlDrawer.d.ts +144 -0
  138. package/dist/components/drawer/PlDrawer.js +1 -0
  139. package/dist/components/drawer/index.d.ts +2 -0
  140. package/dist/components/drawer/index.js +1 -0
  141. package/dist/components/file-picker/PlFilePicker.d.ts +105 -0
  142. package/dist/components/file-picker/PlFilePicker.js +1 -0
  143. package/dist/components/file-picker/index.d.ts +2 -0
  144. package/dist/components/file-picker/index.js +1 -0
  145. package/dist/components/floating-bottom-navigation/PlFloatingBottomNavigation.d.ts +118 -0
  146. package/dist/components/floating-bottom-navigation/PlFloatingBottomNavigation.js +1 -0
  147. package/dist/components/floating-bottom-navigation/index.d.ts +2 -0
  148. package/dist/components/floating-bottom-navigation/index.js +1 -0
  149. package/dist/components/grid/PlGrid.d.ts +67 -0
  150. package/dist/components/grid/PlGrid.js +1 -0
  151. package/dist/components/grid/PlGridItem.d.ts +50 -0
  152. package/dist/components/grid/PlGridItem.js +1 -0
  153. package/dist/components/grid/index.d.ts +4 -0
  154. package/dist/components/grid/index.js +1 -0
  155. package/dist/components/highlight/PlHighlight.d.ts +90 -0
  156. package/dist/components/highlight/PlHighlight.js +1 -0
  157. package/dist/components/highlight/index.d.ts +2 -0
  158. package/dist/components/highlight/index.js +1 -0
  159. package/dist/components/hot-keys/PlHotKeys.d.ts +93 -0
  160. package/dist/components/hot-keys/PlHotKeys.js +1 -0
  161. package/dist/components/hot-keys/index.d.ts +2 -0
  162. package/dist/components/hot-keys/index.js +1 -0
  163. package/dist/components/icon/PlIcon.d.ts +62 -0
  164. package/dist/components/icon/PlIcon.js +1 -0
  165. package/dist/components/icon/index.d.ts +2 -0
  166. package/dist/components/icon/index.js +1 -0
  167. package/dist/components/icon-button/PlIconButton.d.ts +39 -0
  168. package/dist/components/icon-button/PlIconButton.js +1 -0
  169. package/dist/components/icon-button/index.d.ts +2 -0
  170. package/dist/components/icon-button/index.js +1 -0
  171. package/dist/components/list/PlList.d.ts +82 -0
  172. package/dist/components/list/PlList.js +1 -0
  173. package/dist/components/list/index.d.ts +2 -0
  174. package/dist/components/list/index.js +1 -0
  175. package/dist/components/menu/PlMenu.d.ts +210 -0
  176. package/dist/components/menu/PlMenu.js +1 -0
  177. package/dist/components/menu/index.d.ts +2 -0
  178. package/dist/components/menu/index.js +1 -0
  179. package/dist/components/modal/PlModal.d.ts +112 -0
  180. package/dist/components/modal/PlModal.js +1 -0
  181. package/dist/components/modal/index.d.ts +2 -0
  182. package/dist/components/modal/index.js +1 -0
  183. package/dist/components/number-field/PlNumberField.d.ts +133 -0
  184. package/dist/components/number-field/PlNumberField.js +1 -0
  185. package/dist/components/number-field/index.d.ts +2 -0
  186. package/dist/components/number-field/index.js +1 -0
  187. package/dist/components/otp-field/PlOtpField.d.ts +82 -0
  188. package/dist/components/otp-field/PlOtpField.js +1 -0
  189. package/dist/components/otp-field/index.d.ts +2 -0
  190. package/dist/components/otp-field/index.js +1 -0
  191. package/dist/components/overlay/PlOverlay.d.ts +96 -0
  192. package/dist/components/overlay/PlOverlay.js +1 -0
  193. package/dist/components/overlay/index.d.ts +2 -0
  194. package/dist/components/overlay/index.js +1 -0
  195. package/dist/components/pagination/PlPagination.d.ts +88 -0
  196. package/dist/components/pagination/PlPagination.js +1 -0
  197. package/dist/components/pagination/index.d.ts +2 -0
  198. package/dist/components/pagination/index.js +1 -0
  199. package/dist/components/panes/PlPanes.d.ts +79 -0
  200. package/dist/components/panes/PlPanes.js +1 -0
  201. package/dist/components/panes/index.d.ts +2 -0
  202. package/dist/components/panes/index.js +1 -0
  203. package/dist/components/pill/PlPill.d.ts +81 -0
  204. package/dist/components/pill/PlPill.js +1 -0
  205. package/dist/components/pill/index.d.ts +2 -0
  206. package/dist/components/pill/index.js +1 -0
  207. package/dist/components/popover/PlPopover.d.ts +107 -0
  208. package/dist/components/popover/PlPopover.js +1 -0
  209. package/dist/components/popover/index.d.ts +2 -0
  210. package/dist/components/popover/index.js +1 -0
  211. package/dist/components/progress-box/PlProgressBox.d.ts +32 -0
  212. package/dist/components/progress-box/PlProgressBox.js +1 -0
  213. package/dist/components/progress-box/index.d.ts +2 -0
  214. package/dist/components/progress-box/index.js +1 -0
  215. package/dist/components/progress-circular/PlProgressCircular.d.ts +22 -0
  216. package/dist/components/progress-circular/PlProgressCircular.js +1 -0
  217. package/dist/components/progress-circular/index.d.ts +2 -0
  218. package/dist/components/progress-circular/index.js +1 -0
  219. package/dist/components/progress-linear/PlProgressLinear.d.ts +31 -0
  220. package/dist/components/progress-linear/PlProgressLinear.js +1 -0
  221. package/dist/components/progress-linear/index.d.ts +2 -0
  222. package/dist/components/progress-linear/index.js +1 -0
  223. package/dist/components/radio-group/PlRadioGroup.d.ts +54 -0
  224. package/dist/components/radio-group/PlRadioGroup.js +1 -0
  225. package/dist/components/radio-group/index.d.ts +2 -0
  226. package/dist/components/radio-group/index.js +1 -0
  227. package/dist/components/rating/PlRating.d.ts +90 -0
  228. package/dist/components/rating/PlRating.js +1 -0
  229. package/dist/components/rating/index.d.ts +2 -0
  230. package/dist/components/rating/index.js +1 -0
  231. package/dist/components/scroll-zone/PlScrollZone.d.ts +132 -0
  232. package/dist/components/scroll-zone/PlScrollZone.js +1 -0
  233. package/dist/components/scroll-zone/index.d.ts +2 -0
  234. package/dist/components/scroll-zone/index.js +1 -0
  235. package/dist/components/segmented-button/PlSegmentedButton.d.ts +79 -0
  236. package/dist/components/segmented-button/PlSegmentedButton.js +1 -0
  237. package/dist/components/segmented-button/index.d.ts +2 -0
  238. package/dist/components/segmented-button/index.js +1 -0
  239. package/dist/components/select/PlSelect.d.ts +77 -0
  240. package/dist/components/select/PlSelect.js +1 -0
  241. package/dist/components/select/index.d.ts +2 -0
  242. package/dist/components/select/index.js +1 -0
  243. package/dist/components/skeleton/PlSkeleton.d.ts +73 -0
  244. package/dist/components/skeleton/PlSkeleton.js +1 -0
  245. package/dist/components/skeleton/index.d.ts +2 -0
  246. package/dist/components/skeleton/index.js +1 -0
  247. package/dist/components/slider/PlSlider.d.ts +44 -0
  248. package/dist/components/slider/PlSlider.js +1 -0
  249. package/dist/components/slider/index.d.ts +2 -0
  250. package/dist/components/slider/index.js +1 -0
  251. package/dist/components/spoiler/PlSpoiler.d.ts +84 -0
  252. package/dist/components/spoiler/PlSpoiler.js +1 -0
  253. package/dist/components/spoiler/index.d.ts +2 -0
  254. package/dist/components/spoiler/index.js +1 -0
  255. package/dist/components/switch/PlSwitch.d.ts +42 -0
  256. package/dist/components/switch/PlSwitch.js +1 -0
  257. package/dist/components/switch/index.d.ts +2 -0
  258. package/dist/components/switch/index.js +1 -0
  259. package/dist/components/table/PlTable.d.ts +112 -0
  260. package/dist/components/table/PlTable.js +1 -0
  261. package/dist/components/table/index.d.ts +2 -0
  262. package/dist/components/table/index.js +1 -0
  263. package/dist/components/tabs/PlTabs.d.ts +94 -0
  264. package/dist/components/tabs/PlTabs.js +1 -0
  265. package/dist/components/tabs/index.d.ts +2 -0
  266. package/dist/components/tabs/index.js +1 -0
  267. package/dist/components/text-field/{TextField.d.ts → PlTextField.d.ts} +5 -5
  268. package/dist/components/text-field/PlTextField.js +1 -0
  269. package/dist/components/text-field/index.d.ts +2 -2
  270. package/dist/components/text-field/index.js +1 -1
  271. package/dist/components/text-link/PlTextLink.d.ts +80 -0
  272. package/dist/components/text-link/PlTextLink.js +1 -0
  273. package/dist/components/text-link/index.d.ts +2 -0
  274. package/dist/components/text-link/index.js +1 -0
  275. package/dist/components/time-picker/PlTimePicker.d.ts +88 -0
  276. package/dist/components/time-picker/PlTimePicker.js +1 -0
  277. package/dist/components/time-picker/index.d.ts +2 -0
  278. package/dist/components/time-picker/index.js +1 -0
  279. package/dist/components/timeline/PlTimeline.d.ts +98 -0
  280. package/dist/components/timeline/PlTimeline.js +1 -0
  281. package/dist/components/timeline/index.d.ts +2 -0
  282. package/dist/components/timeline/index.js +1 -0
  283. package/dist/components/toast/PlToast.d.ts +122 -0
  284. package/dist/components/toast/PlToast.js +1 -0
  285. package/dist/components/toast/index.d.ts +2 -0
  286. package/dist/components/toast/index.js +1 -0
  287. package/dist/components/toolbar/PlToolbar.d.ts +68 -0
  288. package/dist/components/toolbar/PlToolbar.js +1 -0
  289. package/dist/components/toolbar/index.d.ts +2 -0
  290. package/dist/components/toolbar/index.js +1 -0
  291. package/dist/components/tooltip/PlTooltip.d.ts +92 -0
  292. package/dist/components/tooltip/PlTooltip.js +1 -0
  293. package/dist/components/tooltip/index.d.ts +2 -0
  294. package/dist/components/tooltip/index.js +1 -0
  295. package/dist/components/typography/PlTypography.d.ts +66 -0
  296. package/dist/components/typography/PlTypography.js +1 -0
  297. package/dist/components/typography/index.d.ts +2 -0
  298. package/dist/components/typography/index.js +1 -0
  299. package/dist/css/accordion.css +2 -0
  300. package/dist/css/alert.css +2 -0
  301. package/dist/css/animate-appear.css +2 -0
  302. package/dist/css/animate-blink.css +2 -0
  303. package/dist/css/animate-fade.css +2 -0
  304. package/dist/css/animate-grow.css +2 -0
  305. package/dist/css/animate-headline.css +2 -0
  306. package/dist/css/animate-lighting.css +2 -0
  307. package/dist/css/animate-marquee.css +2 -0
  308. package/dist/css/animate-rotate.css +2 -0
  309. package/dist/css/animate-slide.css +2 -0
  310. package/dist/css/animate-typing.css +2 -0
  311. package/dist/css/animate-zoom.css +2 -0
  312. package/dist/css/aspect-ratio.css +2 -0
  313. package/dist/css/avatar.css +2 -0
  314. package/dist/css/badge.css +2 -0
  315. package/dist/css/base.css +4 -0
  316. package/dist/css/blockquote.css +2 -0
  317. package/dist/css/bottom-navigation.css +2 -0
  318. package/dist/css/box.css +2 -0
  319. package/dist/css/breadcrumb.css +2 -0
  320. package/dist/css/button-group.css +2 -0
  321. package/dist/css/button.css +2 -0
  322. package/dist/css/card.css +2 -0
  323. package/dist/css/carousel.css +2 -0
  324. package/dist/css/chat-bubble.css +2 -0
  325. package/dist/css/checkbox.css +2 -0
  326. package/dist/css/chip.css +2 -0
  327. package/dist/css/collapsible.css +2 -0
  328. package/dist/css/combobox.css +2 -0
  329. package/dist/css/container.css +2 -0
  330. package/dist/css/date-picker.css +2 -0
  331. package/dist/css/date-range-picker.css +2 -0
  332. package/dist/css/date-time-picker.css +2 -0
  333. package/dist/css/divider.css +2 -0
  334. package/dist/css/drawer.css +2 -0
  335. package/dist/css/file-picker.css +2 -0
  336. package/dist/css/floating-bottom-navigation.css +2 -0
  337. package/dist/css/grid.css +2 -0
  338. package/dist/css/highlight.css +2 -0
  339. package/dist/css/hot-keys.css +2 -0
  340. package/dist/css/icon-button.css +2 -0
  341. package/dist/css/icon.css +2 -0
  342. package/dist/css/list.css +2 -0
  343. package/dist/css/menu.css +2 -0
  344. package/dist/css/modal.css +2 -0
  345. package/dist/css/number-field.css +2 -0
  346. package/dist/css/otp-field.css +2 -0
  347. package/dist/css/overlay.css +2 -0
  348. package/dist/css/pagination.css +2 -0
  349. package/dist/css/panes.css +2 -0
  350. package/dist/css/pill.css +2 -0
  351. package/dist/css/popover.css +2 -0
  352. package/dist/css/progress-box.css +2 -0
  353. package/dist/css/progress-circular.css +2 -0
  354. package/dist/css/progress-linear.css +2 -0
  355. package/dist/css/radio-group.css +2 -0
  356. package/dist/css/rating.css +2 -0
  357. package/dist/css/scroll-zone.css +2 -0
  358. package/dist/css/segmented-button.css +2 -0
  359. package/dist/css/select.css +2 -0
  360. package/dist/css/skeleton.css +2 -0
  361. package/dist/css/slider.css +2 -0
  362. package/dist/css/spoiler.css +2 -0
  363. package/dist/css/switch.css +2 -0
  364. package/dist/css/table.css +2 -0
  365. package/dist/css/tabs.css +2 -0
  366. package/dist/css/text-field.css +2 -0
  367. package/dist/css/text-link.css +2 -0
  368. package/dist/css/time-picker.css +2 -0
  369. package/dist/css/timeline.css +2 -0
  370. package/dist/css/toast.css +2 -0
  371. package/dist/css/toolbar.css +2 -0
  372. package/dist/css/tooltip.css +2 -0
  373. package/dist/css/typography.css +2 -0
  374. package/dist/index.d.ts +75 -3
  375. package/dist/index.js +1 -1
  376. package/dist/internal/animate.d.ts +161 -0
  377. package/dist/internal/animate.js +1 -0
  378. package/dist/internal/button-group.d.ts +27 -0
  379. package/dist/internal/button-group.js +2 -0
  380. package/dist/internal/calendar.d.ts +148 -0
  381. package/dist/internal/calendar.js +1 -0
  382. package/dist/internal/date.d.ts +173 -0
  383. package/dist/internal/date.js +1 -0
  384. package/dist/internal/format.d.ts +24 -0
  385. package/dist/internal/format.js +1 -0
  386. package/dist/internal/grid.d.ts +67 -0
  387. package/dist/internal/grid.js +1 -0
  388. package/dist/internal/icons.d.ts +86 -1
  389. package/dist/internal/icons.js +1 -1
  390. package/dist/internal/menu.d.ts +20 -0
  391. package/dist/internal/menu.js +1 -0
  392. package/dist/internal/picker.d.ts +118 -0
  393. package/dist/internal/picker.js +1 -0
  394. package/dist/internal/progress.d.ts +145 -0
  395. package/dist/internal/progress.js +1 -0
  396. package/dist/internal/sizer.d.ts +32 -0
  397. package/dist/internal/sizer.js +1 -0
  398. package/dist/internal/styles.d.ts +198 -8
  399. package/dist/internal/styles.js +1 -1
  400. package/dist/styles.css +1 -1
  401. package/dist/tailwind.css +899 -125
  402. package/dist/tokens.css +1275 -0
  403. package/dist/types.d.ts +150 -8
  404. package/dist/types.js +0 -8
  405. package/package.json +32 -27
  406. package/README.md +0 -111
  407. package/dist/components/button/Button.js +0 -1
  408. package/dist/components/text-field/TextField.js +0 -1
@@ -0,0 +1,127 @@
1
+ import * as React from 'react';
2
+ import type { PlassColor, PlassDensity, PlassElevation, PlassSize, PlassVariant } from '../../types.js';
3
+ /**
4
+ * Whose message this is.
5
+ *
6
+ * `start` and `end` rather than `them`/`me` or `left`/`right`: a thread runs the
7
+ * way the language does, and the same two words already mean this everywhere
8
+ * else in the library. `start` is the default because a message from someone
9
+ * else is the one you have no other way of knowing about.
10
+ */
11
+ export type PlChatBubbleSide = 'start' | 'end';
12
+ /**
13
+ * How far a message has got.
14
+ *
15
+ * The four steps are a ladder and the fifth is not on it: `failed` is the
16
+ * message that did not go, which is why it is the only one drawn in another
17
+ * colour family.
18
+ */
19
+ export type PlChatBubbleStatus = 'sending' | 'sent' | 'delivered' | 'read' | 'failed';
20
+ /** What a link inside a message unfurls to. */
21
+ export interface PlChatBubbleLinkPreview {
22
+ /** Where the card goes. */
23
+ url: string;
24
+ /** The page's title. */
25
+ title?: React.ReactNode;
26
+ /** Its summary, clamped to two lines. */
27
+ description?: React.ReactNode;
28
+ /** The share image, drawn across the top of the card. */
29
+ image?: string;
30
+ /** Who published it — a domain, a site name. */
31
+ site?: React.ReactNode;
32
+ /**
33
+ * Opens the card in a new tab.
34
+ * @default false
35
+ */
36
+ newTab?: boolean;
37
+ }
38
+ export interface PlChatBubbleProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'color' | 'title'> {
39
+ /**
40
+ * Whose message this is.
41
+ * @default 'start'
42
+ */
43
+ side?: PlChatBubbleSide;
44
+ /** Who sent it, above the bubble. */
45
+ name?: React.ReactNode;
46
+ /** When it was sent, beside the name. */
47
+ time?: React.ReactNode;
48
+ /**
49
+ * The sender's picture — a `PlAvatar`, at the size the thread uses. Left out,
50
+ * the bubble takes the whole row.
51
+ */
52
+ avatar?: React.ReactNode;
53
+ /**
54
+ * How far the message has got, drawn as a mark under the bubble. Left out,
55
+ * nothing is drawn — a received message has no delivery state worth showing.
56
+ */
57
+ status?: PlChatBubbleStatus;
58
+ /**
59
+ * What the mark is read out as. Never drawn. Defaults to the English word for
60
+ * whichever `status` is set.
61
+ */
62
+ statusLabel?: string;
63
+ /**
64
+ * Draws the three dots instead of the message. What `children` holds is left
65
+ * alone, so the same bubble can go back to it when the message arrives.
66
+ * @default false
67
+ */
68
+ typing?: boolean;
69
+ /**
70
+ * What the dots are read out as. Never drawn.
71
+ * @default 'Typing…'
72
+ */
73
+ typingLabel?: string;
74
+ /**
75
+ * A picture, a video, a map — drawn edge to edge above the text, so the
76
+ * bubble's corners crop it.
77
+ */
78
+ media?: React.ReactNode;
79
+ /** A link in the message, unfurled into a card under the text. */
80
+ preview?: PlChatBubbleLinkPreview;
81
+ /**
82
+ * The message's own actions — a menu trigger, most of the time. Sits beside
83
+ * the bubble and stays out of the way until the row is hovered or something in
84
+ * it takes focus.
85
+ */
86
+ actions?: React.ReactNode;
87
+ /**
88
+ * What the bubble's surface is made of. `solid` is the usual way to tell your
89
+ * own messages from everyone else's; `side` deliberately does not decide this,
90
+ * because which end is filled is a decision about the product, not about the
91
+ * component.
92
+ * @default 'glass'
93
+ */
94
+ variant?: PlassVariant;
95
+ /** @default 'md' */
96
+ size?: PlassSize;
97
+ /** @default 'primary' */
98
+ color?: PlassColor;
99
+ /**
100
+ * Padding inside the bubble, and nothing else.
101
+ * @default 'default'
102
+ */
103
+ density?: PlassDensity;
104
+ /**
105
+ * Drop shadow depth. `0` is the default — a message lies in the thread rather
106
+ * than floating over it.
107
+ * @default 0
108
+ */
109
+ elevation?: PlassElevation;
110
+ /** The message. */
111
+ children?: React.ReactNode;
112
+ }
113
+ /**
114
+ * One message in a conversation.
115
+ *
116
+ * Everything around the bubble is optional and nothing about it is fixed by
117
+ * `side`: the avatar, the sender's name, the time, the delivery mark, the media
118
+ * above the text and the link card below it are each drawn only when they are
119
+ * given something. What `side` decides is which way the row runs and which
120
+ * corner of the sheet is cut short.
121
+ *
122
+ * `variant` is what tells your own messages from everyone else's, and it is
123
+ * deliberately not tied to `side` — filling the right-hand column is a
124
+ * convention, not a law, and a thread that fills neither is a perfectly good
125
+ * thread.
126
+ */
127
+ export declare const PlChatBubble: React.ForwardRefExoticComponent<PlChatBubbleProps & React.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,jsxs as l}from"react/jsx-runtime";import*as s from"react";import{CheckIcon as a,ClockIcon as r,LinkIcon as n,severityIcon as i}from"../../internal/icons.js";import{controlSlots as t,focusRingClasses as o,glassClasses as d,hasContent as c,metaTextClasses as p,radiusClasses as m,sheetBodyClasses as u,sheetHeaderGapClasses as v,srOnlyClasses as f,transitionClasses as g}from"../../internal/styles.js";const x={default:{xs:"px-2 py-1",sm:"px-2.5 py-1.5",md:"px-3 py-2",lg:"px-3.5 py-2.5",xl:"px-4 py-3"},compact:{xs:"px-1.5 py-0.5",sm:"px-2 py-1",md:"px-2.5 py-1.5",lg:"px-3 py-1.5",xl:"px-3.5 py-2"}},h={start:"[border-start-start-radius:0.25rem]",end:"[border-start-end-radius:0.25rem]"},b={solid:/* @__PURE__ */["text-(--p-on-solid) [background-image:var(--p-fill)]","[box-shadow:var(--p-elev),var(--p-lift)]"].join(" "),glass:/* @__PURE__ */[d,"border text-(--plass-fg) bg-(--plass-glass)","[border-color:var(--plass-glass-line)]","[box-shadow:var(--p-elev),var(--plass-gloss-glass)]"].join(" "),ghost:"text-(--plass-fg) bg-(--p-soft) [box-shadow:var(--p-elev)]"};function DoubleCheckIcon(){return l("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[e("path",{d:"m1.5 8.5 2.75 2.75L9.5 6",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"}),e("path",{d:"M7 10.75 8.25 12l5.25-5.25",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})]})}const y={sending:e(r,{}),sent:e(a,{}),delivered:e(DoubleCheckIcon,{}),read:e(DoubleCheckIcon,{}),failed:/* @__PURE__ */i("danger")},k={sending:"Sending",sent:"Sent",delivered:"Delivered",read:"Read",failed:"Not delivered"},w={sending:"text-(--plass-muted-fg)",sent:"text-(--plass-muted-fg)",delivered:"text-(--plass-muted-fg)",read:"text-(--p-accent)",failed:"text-(--plass-danger-accent)"},N=/* @__PURE__ */["block overflow-hidden rounded-(--plass-radius-sm) border no-underline","[border-color:color-mix(in_oklab,currentColor_18%,transparent)]","[background-color:color-mix(in_oklab,currentColor_7%,transparent)]","hover:[background-color:color-mix(in_oklab,currentColor_12%,transparent)]","[transition-property:background-color] [transition-duration:var(--plass-duration)]","[transition-timing-function:var(--plass-ease)]",o].join(" "),j=/* @__PURE__ */["shrink-0 opacity-0","[transition:opacity_var(--plass-duration)_var(--plass-ease)]","group-hover/bubble:opacity-100 group-focus-within/bubble:opacity-100","[@media(hover:none)]:opacity-100"].join(" ");export const PlChatBubble=/* @__PURE__ */s.forwardRef(function PlChatBubble({side:s="start",name:a,time:r,avatar:n,status:i,statusLabel:o,typing:d=!1,typingLabel:N="Typing…",media:_,preview:C,actions:L,variant:D="glass",size:B="md",color:z="primary",density:P="default",elevation:T=0,className:I,style:R,children:S,...W},M){const $="end"===s,q=c(a)||c(r),A=d||c(S)||Boolean(C),E=["flex min-w-0 flex-col overflow-hidden",m[B],h[s],b[D],g].join(" ");return l("div",{ref:M,className:["group/bubble flex w-full items-start gap-2",$?"flex-row-reverse":"",I??""].filter(Boolean).join(" "),style:{...t(z,T,D),...R},...W,children:[c(n)?e("div",{className:"shrink-0",children:n}):null,l("div",{className:["flex max-w-[min(100%,32rem)] min-w-0 flex-col",v[B],$?"items-end":"items-start"].join(" "),children:[q?l("div",{className:`flex items-baseline gap-2 ${p[B]}`,children:[c(a)?e("span",{className:"font-semibold",children:a}):null,c(r)?e("span",{className:"text-(--plass-muted-fg)",children:r}):null]}):null,l("div",{className:"flex min-w-0 items-center gap-1 "+($?"flex-row-reverse":""),children:[l("div",{className:E,children:[c(_)?e("div",{className:"[&_img]:block [&_img]:w-full [&_video]:block [&_video]:w-full",children:_}):null,A?l("div",{className:[x[P][B],"flex min-w-0 flex-col gap-2",u[B]].join(" "),children:[d?e(TypingDots,{label:N}):c(S)?e("div",{className:"min-w-0 break-words whitespace-pre-line",children:S}):null,C?e(LinkPreview,{preview:C}):null]}):null]}),c(L)?e("div",{className:j,children:L}):null]}),i?l("div",{className:["flex items-center gap-1",p[B],w[i],"[&_svg]:size-[1.15em] [&_svg]:shrink-0"].join(" "),children:[y[i],e("span",{className:f,children:o??k[i]})]}):null]})]})});function TypingDots({label:s}){return l("div",{className:"flex items-center gap-1 py-[0.35em]",role:"status",children:[[0,1,2].map(l=>e("span",{"aria-hidden":"true",className:"plass-typing-dot size-[0.45em] rounded-full",style:{"--p-i":l}},l)),e("span",{className:f,children:s})]})}function LinkPreview({preview:s}){const{url:a,title:r,description:i,image:t,site:o,newTab:d=!1}=s;return l("a",{href:a,target:d?"_blank":void 0,rel:d?"noopener noreferrer":void 0,className:N,children:[t?e("img",{src:t,alt:"",className:"block h-28 w-full object-cover"}):null,l("div",{className:"flex flex-col gap-0.5 p-2",children:[c(o)?l("span",{className:"flex items-center gap-1 text-[0.85em] opacity-70 [&_svg]:size-[1em] [&_svg]:shrink-0",children:[e(n,{}),e("span",{className:"truncate",children:o})]}):null,c(r)?e("span",{className:"font-semibold",children:r}):null,c(i)?e("span",{className:"line-clamp-2 text-[0.9em] opacity-80",children:i}):null]})]})}
@@ -0,0 +1,2 @@
1
+ export { PlChatBubble } from './PlChatBubble.js';
2
+ export type { PlChatBubbleLinkPreview, PlChatBubbleProps, PlChatBubbleSide, PlChatBubbleStatus } from './PlChatBubble.js';
@@ -0,0 +1 @@
1
+ export{PlChatBubble}from"./PlChatBubble.js";
@@ -0,0 +1,39 @@
1
+ import * as React from 'react';
2
+ import { Checkbox as BaseUICheckbox } from '@base-ui/react/checkbox';
3
+ import type { PlassColor, PlassSize } from '../../types.js';
4
+ /**
5
+ * Base UI's own props, minus the ones this component owns: `className` and
6
+ * `style` land on the field wrapper rather than on the tick, and `render` would
7
+ * replace the tick with something that is no longer a checkbox.
8
+ */
9
+ type BaseCheckboxProps = Omit<React.ComponentPropsWithoutRef<typeof BaseUICheckbox.Root>, 'className' | 'style' | 'render' | 'children'>;
10
+ export interface PlCheckboxProps extends BaseCheckboxProps {
11
+ /** @default 'md' */
12
+ size?: PlassSize;
13
+ /** @default 'primary' */
14
+ color?: PlassColor;
15
+ /** The text beside the tick. Wired to it by Base UI's Field. */
16
+ label?: React.ReactNode;
17
+ /** Helper text under the label. */
18
+ description?: React.ReactNode;
19
+ /** Error message below. Its presence also turns the checkbox invalid. */
20
+ error?: React.ReactNode;
21
+ /**
22
+ * Forces the invalid state without a message — for when an external form
23
+ * library owns the validity. Defaults to whether `error` has content.
24
+ */
25
+ invalid?: boolean;
26
+ /** Class names for the field wrapper, not for the tick itself. */
27
+ className?: string;
28
+ style?: React.CSSProperties;
29
+ }
30
+ /**
31
+ * A single yes/no, or one member of a set of them.
32
+ *
33
+ * `label`, `description` and `error` are props rather than children for the same
34
+ * reason they are on PlTextField: the arrangement is fixed and what a caller
35
+ * wants to decide is what goes in each slot. `children` is not accepted at all —
36
+ * anything a checkbox has to say belongs in one of the three.
37
+ */
38
+ export declare const PlCheckbox: React.ForwardRefExoticComponent<PlCheckboxProps & React.RefAttributes<HTMLElement>>;
39
+ export {};
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,jsxs as r}from"react/jsx-runtime";import*as a from"react";import{Checkbox as t}from"@base-ui/react/checkbox";import{Field as o}from"@base-ui/react/field";import{controlSlots as l,focusRingClasses as s,glassClasses as i,hasContent as n,metaTextClasses as c,tickRadiusClasses as d,tickRowTextClasses as p,tickSizeClasses as h,transitionClasses as m}from"../../internal/styles.js";const u=/* @__PURE__ */["relative inline-flex shrink-0 items-center justify-center border","[-webkit-tap-highlight-color:transparent] [touch-action:manipulation]",m,s].join(" "),f=/* @__PURE__ */[i,"cursor-pointer bg-(--plass-glass) [border-color:var(--plass-border)]","hover:bg-(--plass-glass-hover) hover:[border-color:var(--p-line)]","data-[checked]:[background-image:var(--p-fill)] data-[checked]:text-(--p-on-solid)","data-[checked]:[border-color:transparent] data-[checked]:hover:brightness-105","data-[indeterminate]:[background-image:var(--p-fill)] data-[indeterminate]:text-(--p-on-solid)","data-[indeterminate]:[border-color:transparent]"].join(" "),k=/* @__PURE__ */[i,"cursor-default bg-(--plass-glass) [border-color:var(--plass-border)]","saturate-[0.55]","data-[checked]:[background-image:var(--p-fill)] data-[checked]:text-(--p-on-solid)","data-[checked]:[border-color:transparent]"].join(" "),b=/* @__PURE__ */[i,"cursor-not-allowed bg-(--plass-glass) [border-color:var(--plass-border)]","opacity-50 saturate-[0.35]","data-[checked]:[background-image:var(--p-fill)] data-[checked]:text-(--p-on-solid)","data-[checked]:[border-color:transparent]","data-[indeterminate]:[background-image:var(--p-fill)] data-[indeterminate]:text-(--p-on-solid)"].join(" ");function CheckMark(){return e("svg",{viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",className:"size-full",children:e("path",{d:"M2 6.2 4.6 8.8 10 3.4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})}function DashMark(){return e("svg",{viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",className:"size-full",children:e("path",{d:"M2.5 6h7",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}export const PlCheckbox=/* @__PURE__ */a.forwardRef(function PlCheckbox({size:a="md",color:s="primary",label:i,description:m,error:g,invalid:x,disabled:v=!1,readOnly:j=!1,className:N,style:y,...C},w){const M=n(g),z=x??M,L=z?"danger":s,B=[u,h[a],d[a],v?b:j?k:f].join(" ");return r(o.Root,{disabled:v,invalid:z,className:["inline-flex flex-col gap-1 align-top",N??""].filter(Boolean).join(" "),style:{...l(L,0,"solid"),...y},children:[r("div",{className:`flex items-start gap-2 ${p[a]}`,children:[e("span",{className:"flex h-[1lh] shrink-0 items-center",children:e(t.Root,{ref:w,className:B,disabled:v,readOnly:j,...C,children:e(t.Indicator,{className:"flex size-[70%] items-center justify-center",children:C.indeterminate?e(DashMark,{}):e(CheckMark,{})})})}),i||m?r("span",{className:"flex min-w-0 flex-col gap-0.5",children:[i?e(o.Label,{className:v?"text-(--plass-muted-fg)":"cursor-pointer text-(--plass-fg)",children:i}):null,m?e(o.Description,{className:`${c[a]} text-(--plass-muted-fg)`,children:m}):null]}):null]}),M?e(o.Error,{match:!0,className:`${c[a]} text-(--p-accent)`,children:g}):null]})});
@@ -0,0 +1,2 @@
1
+ export { PlCheckbox } from './PlCheckbox.js';
2
+ export type { PlCheckboxProps } from './PlCheckbox.js';
@@ -0,0 +1 @@
1
+ export{PlCheckbox}from"./PlCheckbox.js";
@@ -0,0 +1,55 @@
1
+ import * as React from 'react';
2
+ import type { PlassElevation, PlassStyleProps } from '../../types.js';
3
+ export interface PlChipProps extends PlassStyleProps, Omit<React.ComponentPropsWithoutRef<'span'>, 'color'> {
4
+ /**
5
+ * Drop shadow depth. `0` is the default — a chip is a token sitting *on*
6
+ * something else, so it is raised even less often than a `PlButton`.
7
+ * @default 0
8
+ */
9
+ elevation?: PlassElevation;
10
+ /** Content placed before the label — an icon, a status dot, an avatar. */
11
+ startIcon?: React.ReactNode;
12
+ /** Content placed after the label, before any `count`. */
13
+ endIcon?: React.ReactNode;
14
+ /**
15
+ * A number set into the end of the chip. Drawn on its own small plate, so
16
+ * "Errors 12" reads as one token with a count rather than as two words.
17
+ */
18
+ count?: React.ReactNode;
19
+ /**
20
+ * Called when the chip's delete affordance is pressed. Passing it is what
21
+ * makes the affordance appear.
22
+ */
23
+ onDelete?: (event: React.MouseEvent<HTMLButtonElement>) => void;
24
+ /**
25
+ * Accessible name of the delete button. Never drawn.
26
+ * @default 'Remove'
27
+ */
28
+ deleteLabel?: string;
29
+ /**
30
+ * Marks the chip as chosen — a filter that is on.
31
+ *
32
+ * It moves the chip one step up the ladder its own variant already sits on,
33
+ * rather than changing the colour family, so a row of chips stays one row of
34
+ * chips.
35
+ * @default false
36
+ */
37
+ selected?: boolean;
38
+ /** Unavailable. The light goes out, the same way it does everywhere else. */
39
+ disabled?: boolean;
40
+ children?: React.ReactNode;
41
+ }
42
+ /**
43
+ * A compact token: a tag, a filter, a status, an entity plucked out of a list.
44
+ *
45
+ * The shell is always a `<span>`. What changes is what is inside it: a plain run
46
+ * of content, or — when `onClick` is given — a real `<button>` wrapping that
47
+ * content, plus a second button for `onDelete`. Both are reachable by keyboard,
48
+ * and neither is nested inside the other.
49
+ *
50
+ * An inert `<span>` carrying a click handler is the single most common way a
51
+ * component library loses its keyboard users, and a `<button>` inside a
52
+ * `<button>` is the most common way it invents a chip that Chrome silently
53
+ * rewrites. This shape is what avoids both.
54
+ */
55
+ export declare const PlChip: React.ForwardRefExoticComponent<PlChipProps & React.RefAttributes<HTMLSpanElement>>;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,Fragment as s,jsxs as l}from"react/jsx-runtime";import*as t from"react";import{CloseIcon as o}from"../../internal/icons.js";import{chipRemoveClasses as a,controlHeightClasses as n,controlSlots as r,controlTextClasses as i,disabledClasses as c,focusRingClasses as p,gapClasses as d,glassClasses as m,hasContent as g,iconClasses as h,paddingXClasses as b,radiusClasses as f,transitionClasses as u}from"../../internal/styles.js";const v={xs:"xs",sm:"xs",md:"sm",lg:"md",xl:"lg"},x={solid:"text-(--p-on-solid) [background-image:var(--p-fill)] [box-shadow:var(--p-elev)]",glass:/* @__PURE__ */[m,"border text-(--p-accent) bg-(--plass-glass)","[border-color:var(--plass-glass-line)]","[box-shadow:var(--p-elev),var(--plass-gloss-glass)]"].join(" "),ghost:"text-(--p-accent) bg-(--p-soft)"},j={solid:"[box-shadow:var(--p-elev),var(--p-lift)]",glass:"bg-(--plass-glass-press) [border-color:var(--p-line-hover)]",ghost:"bg-(--p-soft-press)"},w={solid:"hover:brightness-105 active:brightness-95",glass:"hover:bg-(--plass-glass-hover) hover:[border-color:var(--p-line)] active:bg-(--plass-glass-press)",ghost:"hover:bg-(--p-soft-hover) active:bg-(--p-soft-press)"},y=/* @__PURE__ */["relative inline-flex max-w-full shrink-0 items-center select-none","align-middle leading-none font-medium whitespace-nowrap","[-webkit-tap-highlight-color:transparent] [touch-action:manipulation]",u,h].join(" "),k=/* @__PURE__ */["flex min-w-0 flex-1 cursor-pointer items-center justify-center self-stretch rounded-[inherit]",p].join(" ");export const PlChip=/* @__PURE__ */t.forwardRef(function PlChip({variant:t="glass",size:p="md",color:m="primary",density:h="default",elevation:u=0,startIcon:N,endIcon:C,count:$,onDelete:B,deleteLabel:I="Remove",selected:P=!1,disabled:R=!1,className:z,style:D,children:F,onClick:L,...q},A){const E=Boolean(L)&&!R,G=v[p],H=b[h][G],J=[y,n[G],i[G],d[G],f[G],R?c[t]:x[t],!R&&P?j[t]:"",E?w[t]:"",E?"ps-0":H,B?"pe-1":E?"pe-0":"",z??""].filter(Boolean).join(" "),K=l(s,{children:[N,g(F)?e("span",{className:"min-w-0 truncate",children:F}):null,C,g($)?e("span",{className:["ms-0.5 inline-flex shrink-0 items-center justify-center rounded-full px-1.5 py-px","text-[0.85em] leading-none font-semibold tabular-nums","solid"===t?"bg-(--plass-glow-on-fill) text-(--p-on-solid)":"bg-(--p-soft-press) text-(--p-accent)"].join(" "),children:$}):null]});return l("span",{ref:A,className:J,style:{...r(m,u,t),...D},"aria-disabled":!(!R||E)||void 0,...q,children:[E?e("button",{type:"button","aria-pressed":P,className:`${k} ${d[G]} ${H}`,onClick:L,children:K}):K,B?e("button",{type:"button","aria-label":I,disabled:R,className:a,onClick:B,children:e(o,{})}):null]})});
@@ -0,0 +1,2 @@
1
+ export { PlChip } from './PlChip.js';
2
+ export type { PlChipProps } from './PlChip.js';
@@ -0,0 +1 @@
1
+ export{PlChip}from"./PlChip.js";
@@ -0,0 +1,84 @@
1
+ import * as React from 'react';
2
+ import type { PlassElevation, PlassStyleProps } from '../../types.js';
3
+ export interface PlCollapsibleProps extends PlassStyleProps, Omit<React.ComponentPropsWithoutRef<'div'>, 'color' | 'title' | 'onChange'> {
4
+ /**
5
+ * Drop shadow depth. `0` is the default — a fold is part of the page it is set
6
+ * into, not a panel floating over it.
7
+ * @default 0
8
+ */
9
+ elevation?: PlassElevation;
10
+ /** Whether the panel is showing. Use with `onOpenChange` for a controlled fold. */
11
+ open?: boolean;
12
+ /** Where an uncontrolled fold starts. @default false */
13
+ defaultOpen?: boolean;
14
+ onOpenChange?: (open: boolean) => void;
15
+ /** The heading on the trigger. */
16
+ title?: React.ReactNode;
17
+ /** A second line under the title, one step down the type scale and muted. */
18
+ subtitle?: React.ReactNode;
19
+ /** Content before the title — an icon, a status dot, a count. */
20
+ startIcon?: React.ReactNode;
21
+ /**
22
+ * A control pinned to the end of the header, outside the trigger.
23
+ *
24
+ * Deliberately outside it: a header that both folds and holds a switch has
25
+ * two things to press, and one of them cannot be nested inside the other —
26
+ * the browser rewrites a `<button>` inside a `<button>` on parse. The same
27
+ * shape `PlAccordionItem` uses.
28
+ */
29
+ action?: React.ReactNode;
30
+ /**
31
+ * Replaces the header entirely with a control of your own — a `PlButton`, a
32
+ * `PlChip`, a line of text you made pressable.
33
+ *
34
+ * The element you pass *becomes* the trigger: it is handed the click handler,
35
+ * `aria-expanded` and the `aria-controls` pointing at the panel, so nothing
36
+ * has to be wired up. `title` and the slots around it are for the far commoner
37
+ * case of wanting the header that is already there.
38
+ */
39
+ trigger?: React.ReactElement;
40
+ /** The chevron at the end of the header, turned to report the state. @default true */
41
+ indicator?: boolean;
42
+ /** Unavailable. The trigger stops answering and the panel stays as it is. */
43
+ disabled?: boolean;
44
+ /**
45
+ * Inner padding around the panel's content. Turn it off for something that
46
+ * should reach the edges — a table, a picture, a list of its own.
47
+ * @default true
48
+ */
49
+ padded?: boolean;
50
+ /**
51
+ * Keeps a closed panel in the DOM so the browser's own page search can find
52
+ * and open it. Overrides `keepMounted`.
53
+ * @default false
54
+ */
55
+ hiddenUntilFound?: boolean;
56
+ /**
57
+ * Keeps a closed panel in the DOM. For content that is expensive to build, or
58
+ * that holds form state which should survive being folded away.
59
+ * @default false
60
+ */
61
+ keepMounted?: boolean;
62
+ /** The body. */
63
+ children?: React.ReactNode;
64
+ }
65
+ /**
66
+ * One section that folds, standing on its own.
67
+ *
68
+ * A `PlAccordion` is a *set* of these and owns which one of them is open; this
69
+ * is the same fold with nothing else beside it, so what it needs is an `open` of
70
+ * its own rather than a place in somebody's list. Reach for it for a "Show more"
71
+ * on a form, an optional block of settings, the details under a row.
72
+ *
73
+ * Base UI owns the parts that are genuinely hard: the `button` / panel pairing
74
+ * and the `aria-controls` / `aria-expanded` wiring between them,
75
+ * `hidden="until-found"`, and measuring the panel so it has a height to animate
76
+ * from.
77
+ *
78
+ * The panel's height *is* animated, which looks like an exception to the rule
79
+ * against moving things and is not: nothing is transformed, no text is
80
+ * resampled, and the content does not shift relative to the panel it is in — the
81
+ * panel is a window opening onto it. Content that appears instantly is a page
82
+ * that jumps, which is the failure the rule exists to prevent.
83
+ */
84
+ export declare const PlCollapsible: React.ForwardRefExoticComponent<PlCollapsibleProps & React.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,jsxs as l}from"react/jsx-runtime";import*as t from"react";import{Collapsible as s}from"@base-ui/react/collapsible";import{ChevronIcon as a}from"../../internal/icons.js";import{cx as n,focusRingInsetClasses as i,gapClasses as r,hasContent as p,iconClasses as d,metaTextClasses as o,radiusClasses as c,sheetBodyClasses as m,sheetHeaderGapClasses as f,sheetPaddingXClasses as h,sheetPaddingYClasses as u,sheetRestClasses as x,sheetTitleClasses as b,surfaceSlots as g,transitionClasses as N}from"../../internal/styles.js";const v={default:{xs:"pt-1.5",sm:"pt-2",md:"pt-3",lg:"pt-3.5",xl:"pt-4"},compact:{xs:"pt-1",sm:"pt-1.5",md:"pt-2",lg:"pt-2.5",xl:"pt-3"}},w={default:{xs:"pb-2.5",sm:"pb-3",md:"pb-5",lg:"pb-6",xl:"pb-7"},compact:{xs:"pb-2",sm:"pb-2.5",md:"pb-3.5",lg:"pb-4",xl:"pb-5"}};export const PlCollapsible=/* @__PURE__ */t.forwardRef(function PlCollapsible({variant:t="glass",size:y="md",color:j="primary",density:k="default",elevation:C=0,open:O,defaultOpen:_=!1,onOpenChange:P,title:F,subtitle:M,startIcon:R,action:T,trigger:U,indicator:$=!0,disabled:z=!1,padded:I=!0,hiddenUntilFound:q=!1,keepMounted:A=!1,className:B,style:D,children:E,...G},H){const J=h[k][y],K=u[k][y];return l(s.Root,{ref:H,open:O,defaultOpen:_,onOpenChange:e=>P?.(e),disabled:z,className:n("flex flex-col overflow-hidden",c[y],x[t],N,B),style:{...g(j,C),...D},...G,children:[U?e(s.Trigger,{render:U}):l("div",{className:"flex w-full items-center",children:[l(s.Trigger,{className:n("flex min-w-0 flex-1 cursor-pointer items-center text-start",J,K,r[y],N,d,i,"hover:bg-(--p-soft)","data-[panel-open]:bg-(--p-soft) data-[panel-open]:text-(--p-accent)","disabled:cursor-not-allowed disabled:bg-transparent disabled:opacity-50"),children:[p(R)?e("span",{className:"flex h-[1lh] shrink-0 items-center text-(--plass-muted-fg)",children:R}):null,l("span",{className:n("flex min-w-0 flex-1 flex-col",f[y]),children:[p(F)?e("span",{className:n("plass-title truncate font-semibold",b[y]),children:F}):null,p(M)?e("span",{className:n("truncate text-(--plass-muted-fg)",o[y]),children:M}):null]}),$?e("span",{className:n("flex h-[1lh] shrink-0 items-center text-(--plass-muted-fg)","[transition:rotate_var(--plass-duration)_var(--plass-ease)]","data-[panel-open]:rotate-180"),children:e(a,{})}):null]}),p(T)?e("span",{className:n("flex shrink-0 items-center",J),children:T}):null]}),e(s.Panel,{hiddenUntilFound:q,keepMounted:A,className:n("h-(--collapsible-panel-height) overflow-hidden","[transition:height_var(--plass-duration-slow)_var(--plass-ease)]","data-[starting-style]:h-0 data-[ending-style]:h-0"),children:e("div",{className:n("min-w-0 text-(--plass-muted-fg)",m[y],I?J:"",I?U?`${v[k][y]} ${w[k][y]}`:w[k][y]:""),children:E})})]})});
@@ -0,0 +1,2 @@
1
+ export { PlCollapsible } from './PlCollapsible.js';
2
+ export type { PlCollapsibleProps } from './PlCollapsible.js';
@@ -0,0 +1 @@
1
+ export{PlCollapsible}from"./PlCollapsible.js";
@@ -0,0 +1,140 @@
1
+ import * as React from 'react';
2
+ import type { PlassElevation, PlassStyleProps } from '../../types.js';
3
+ /**
4
+ * What a combobox's value may be — the same two types a PlSelect submits, and
5
+ * for the same reason: a form control's value is what a form sends, and every
6
+ * escape from that buys flexibility by making the common case harder to write.
7
+ *
8
+ * A value the list does not contain is a `string`: it is what the user typed.
9
+ */
10
+ export type PlComboboxValue = string | number;
11
+ export interface PlComboboxOption {
12
+ /** Submitted, and what `value` / `onValueChange` speak in. */
13
+ value: PlComboboxValue;
14
+ /**
15
+ * Shown in the list, in the input and on the chip. Defaults to the value.
16
+ *
17
+ * A `string` rather than a `ReactNode`, which is the one place this differs
18
+ * from PlSelect: the label is typed against by the filter and written into a
19
+ * text input, and neither of those can be done to an element.
20
+ */
21
+ label?: string;
22
+ /** Unavailable, but still listed — the option exists, it just cannot be picked. */
23
+ disabled?: boolean;
24
+ }
25
+ /** One value, or an array of them, depending on `multiple`. */
26
+ type Selection<Multiple extends boolean | undefined> = Multiple extends true ? PlComboboxValue[] : PlComboboxValue | null;
27
+ export interface PlComboboxProps<Multiple extends boolean | undefined = false> extends PlassStyleProps, Omit<React.ComponentPropsWithoutRef<'div'>, 'color' | 'defaultValue' | 'children'> {
28
+ /**
29
+ * The options, as data — the same shape PlSelect takes, and for the same
30
+ * reason: what a caller has is almost always an array already.
31
+ */
32
+ items: readonly PlComboboxOption[];
33
+ /**
34
+ * Whether more than one value may be held. The chosen ones become chips
35
+ * inside the field, and the input goes on filtering after each.
36
+ * @default false
37
+ */
38
+ multiple?: Multiple;
39
+ /** The chosen value. Use with `onValueChange` for a controlled combobox. */
40
+ value?: Selection<Multiple> | null;
41
+ /** The initially chosen value, for an uncontrolled combobox. */
42
+ defaultValue?: Selection<Multiple> | null;
43
+ onValueChange?: (value: Selection<Multiple>) => void;
44
+ /** Called as the text in the input changes — the filter query, not the value. */
45
+ onInputValueChange?: (inputValue: string) => void;
46
+ /**
47
+ * Whether a value the list does not contain may be committed.
48
+ *
49
+ * On by default, and it is what separates this from a searchable PlSelect: the
50
+ * typed text is offered as its own row at the end of the list, so committing
51
+ * it is a choice the user makes rather than something that happens to them on
52
+ * blur. Turn it off for a field whose values are a closed set.
53
+ * @default true
54
+ */
55
+ allowCustom?: boolean;
56
+ /**
57
+ * What that row says. Receives the trimmed query.
58
+ * @default (query) => `Add “${query}”`
59
+ */
60
+ customLabel?: (query: string) => React.ReactNode;
61
+ /**
62
+ * Shows a × that empties the field. Off by default — a field that can be
63
+ * cleared in one click is a field that can be emptied by accident.
64
+ * @default false
65
+ */
66
+ clearable?: boolean;
67
+ /**
68
+ * Shown in the popup when nothing matched and no value may be added.
69
+ * @default 'No matches'
70
+ */
71
+ emptyMessage?: React.ReactNode;
72
+ /** The most rows the list will show at once. `-1` is all of them. @default -1 */
73
+ limit?: number;
74
+ /** Shown in the input while nothing is typed. */
75
+ placeholder?: string;
76
+ /**
77
+ * Drop shadow depth of the *field*. `0`, like a PlTextField: a field is cut
78
+ * into the sheet rather than resting on it. The popup has its own, fixed at
79
+ * `3` — it genuinely floats above the page.
80
+ * @default 0
81
+ */
82
+ elevation?: PlassElevation;
83
+ /** Label above the field, wired to it by Base UI's Field. */
84
+ label?: React.ReactNode;
85
+ /** Helper text below the field. */
86
+ description?: React.ReactNode;
87
+ /** Error message below. Its presence also turns the combobox invalid. */
88
+ error?: React.ReactNode;
89
+ /** Forces the invalid state without a message. Defaults to whether `error` has content. */
90
+ invalid?: boolean;
91
+ /** Content placed before the input. Sized in `em`, so it tracks the text. */
92
+ startIcon?: React.ReactNode;
93
+ /** Stretches to the width of the container. */
94
+ fullWidth?: boolean;
95
+ /** Unavailable. */
96
+ disabled?: boolean;
97
+ /** The value is shown but cannot be changed. */
98
+ readOnly?: boolean;
99
+ /** Whether a value must be chosen before the form is submitted. */
100
+ required?: boolean;
101
+ /** Identifies the field when a form is submitted. */
102
+ name?: string;
103
+ /** The popup is open. Use with `onOpenChange` for a controlled popup. */
104
+ open?: boolean;
105
+ /** Whether the popup starts open. */
106
+ defaultOpen?: boolean;
107
+ onOpenChange?: (open: boolean) => void;
108
+ /** Accessible name of the button that opens the list. @default 'Open' */
109
+ openLabel?: string;
110
+ /** Accessible name of the clear button. @default 'Clear' */
111
+ clearLabel?: string;
112
+ /**
113
+ * Accessible name of a chip's remove button. Receives the chip's label.
114
+ * @default (label) => `Remove ${label}`
115
+ */
116
+ removeLabel?: (label: string) => string;
117
+ /** A ref to the text input the user types into. */
118
+ inputRef?: React.Ref<HTMLInputElement>;
119
+ id?: string;
120
+ }
121
+ /**
122
+ * A field you can type into and also choose from.
123
+ *
124
+ * The shell is a PlTextField's wearing a chevron, exactly as PlSelect's trigger
125
+ * is — the three have to be indistinguishable in a form, or the form looks
126
+ * assembled rather than designed. What is different is what the text does: it
127
+ * filters the list, and — unless `allowCustom` is off — it can become the value
128
+ * itself, offered as the last row rather than committed silently on blur.
129
+ *
130
+ * With `multiple` the chosen values become PlChips inside the field and the
131
+ * input goes on filtering after each one, so a set of tags is built without the
132
+ * field ever closing.
133
+ *
134
+ * Base UI owns everything hard about this: the filtering and its collator, the
135
+ * popup's positioning and flipping, the `combobox`/`listbox` wiring, arrow-key
136
+ * navigation across both the list and the chips, and the hidden input that makes
137
+ * the whole thing submit with a form.
138
+ */
139
+ export declare function PlCombobox<Multiple extends boolean | undefined = false>({ variant, size, color, density, elevation, items, multiple, value, defaultValue, onValueChange, onInputValueChange, allowCustom, customLabel, clearable, emptyMessage, limit, placeholder, label, description, error, invalid, startIcon, fullWidth, disabled, readOnly, required, name, open, defaultOpen, onOpenChange, openLabel, clearLabel, removeLabel, inputRef, id, className, style, ...props }: PlComboboxProps<Multiple>): React.JSX.Element;
140
+ export {};
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,jsxs as a}from"react/jsx-runtime";import*as l from"react";import{Combobox as t}from"@base-ui/react/combobox";import{Field as s}from"@base-ui/react/field";import{PlChip as n}from"../chip/PlChip.js";import{CheckIcon as i,ChevronIcon as r,CloseIcon as o,PlusIcon as c}from"../../internal/icons.js";import{chipRemoveClasses as d,controlHeightClasses as m,controlTextLeadingClasses as u,cx as p,disabledClasses as h,fieldReadOnlyClasses as b,fieldRestClasses as g,focusWithinRingClasses as f,gapClasses as v,glassClasses as x,hasContent as y,iconClasses as N,metaTextClasses as w,paddingXClasses as C,radiusClasses as L,stackGapClasses as j,surfaceSlots as I,transitionClasses as S}from"../../internal/styles.js";const A=/* @__PURE__ */["group relative flex w-full cursor-text items-center","[-webkit-tap-highlight-color:transparent] [touch-action:manipulation]",S,f,N].join(" "),O={xs:"min-h-6 py-0",sm:"min-h-8 py-0.5",md:"min-h-10 py-1",lg:"min-h-12 py-1.5",xl:"min-h-14 py-2"},V=/* @__PURE__ */[x,"max-h-[min(20rem,var(--available-height))] overflow-y-auto overscroll-contain","w-[var(--anchor-width)] border bg-(--plass-glass-press) p-1","[border-color:var(--plass-glass-line)]","[box-shadow:var(--plass-shadow-3),var(--plass-gloss-glass)]","[outline:none]"].join(" "),_=/* @__PURE__ */["relative flex cursor-pointer items-center gap-2 select-none","rounded-(--plass-radius-xs) py-1.5 pe-2 ps-7",S,"data-[highlighted]:bg-(--p-soft-hover) data-[highlighted]:text-(--p-accent)","data-[selected]:font-semibold data-[selected]:text-(--p-accent)","data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50","[outline:none]"].join(" "),z=/* @__PURE__ */["inline-flex h-[1lh] shrink-0 cursor-pointer items-center justify-center","rounded-(--plass-radius-xs) text-(--plass-muted-fg)","[transition:color_var(--plass-duration)_var(--plass-ease)]","hover:text-(--p-accent)","focus-visible:[outline:2px_solid_var(--p-ring)] focus-visible:[outline-offset:1px]","disabled:cursor-not-allowed disabled:opacity-50"].join(" ");function toArray(e){return null==e?[]:Array.isArray(e)?e.slice():[e]}export function PlCombobox({variant:f="glass",size:x="md",color:N="primary",density:S="default",elevation:M=0,items:P,multiple:R,value:$,defaultValue:k,onValueChange:T,onInputValueChange:q,allowCustom:E=!0,customLabel:F,clearable:D=!1,emptyMessage:G="No matches",limit:H,placeholder:W,label:B,description:J,error:K,invalid:Q,startIcon:U,fullWidth:X=!1,disabled:Y=!1,readOnly:Z=!1,required:ee=!1,name:ae,open:le,defaultOpen:te,onOpenChange:se,openLabel:ne="Open",clearLabel:ie="Clear",removeLabel:re=e=>`Remove ${e}`,inputRef:oe,id:ce,className:de,style:me,...ue}){const pe=y(K),he=Q??pe,be=he?"danger":N,ge=!0===R,fe=l.useMemo(()=>P.map(e=>({value:e.value,label:e.label??String(e.value),disabled:e.disabled})),[P]),[ve,xe]=l.useState(()=>toArray(k)),ye=void 0===$?ve:toArray($),[Ne,we]=l.useState(""),Ce=l.useMemo(()=>new Map(fe.map(e=>[e.value,e])),[fe]),Le=l.useCallback(e=>Ce.get(e)??{value:e,label:String(e),custom:!0},[Ce]),je=Ne.trim(),Ie=je.toLocaleLowerCase(),Se=""===je||fe.some(e=>e.label.toLocaleLowerCase()===Ie||String(e.value).toLocaleLowerCase()===Ie)||ye.some(e=>String(e).toLocaleLowerCase()===Ie),Ae=!E||Z||Y||Se?null:je,Oe=l.useMemo(()=>null===Ae?fe:[...fe,{value:Ae,label:Ae,custom:!0}],[fe,Ae]),Ve=ge?ye.map(Le):ye.length>0?Le(ye[0]):null,_e=p(A,u[x],L[x],v[x],ge?O[x]:m[x],`${C[S][x]} pe-1.5`,Y?h[f]:Z?b[f]:g[f]),ze=/* @__PURE__ */["min-w-0 flex-1 self-stretch bg-transparent [font:inherit] text-inherit","[outline:none]","placeholder:text-(--plass-muted-fg)","caret-(--p-accent) selection:bg-(--p-soft-press)","disabled:cursor-not-allowed"].join(" "),renderInput=a=>e(t.Input,{ref:oe,placeholder:W,className:p(ze,ge&&"min-w-16",ge&&a&&"ms-1.5")});return a(s.Root,{disabled:Y,invalid:he,className:p("flex-col align-top",j[x],X?"flex w-full":"inline-flex",de),style:{...I(be,M),...me},...ue,children:[B?e(s.Label,{className:p(w[x],"font-semibold",Y?"text-(--plass-muted-fg)":"text-(--plass-fg)"),children:B}):null,a(t.Root,{id:ce,name:ae,items:Oe,multiple:ge,value:Ve,onValueChange:e=>{!function commit(e){void 0===$&&xe(e),T?.(ge?e:e[0]??null)}((null===e?[]:Array.isArray(e)?e:[e]).map(e=>e.value))},onInputValueChange:e=>{we(e),q?.(e)},open:le,defaultOpen:te,onOpenChange:e=>se?.(e),autoHighlight:!0,itemToStringLabel:e=>e.label,itemToStringValue:e=>String(e.value),isItemEqualToValue:(e,a)=>e.value===a.value,limit:H,disabled:Y,readOnly:Z,required:ee,children:[a(t.InputGroup,{className:_e,children:[U?e("span",{className:"flex h-[1lh] shrink-0 items-center text-(--plass-muted-fg)",children:U}):null,ge?e(t.Chips,{className:"flex min-w-0 flex-1 flex-wrap items-center gap-1",children:e(t.Value,{children:s=>a(l.Fragment,{children:[s.map(a=>e(t.Chip,{render:e(n,{variant:"glass",size:x,color:be,density:"compact",disabled:Y,endIcon:Z||Y?null:e(t.ChipRemove,{"aria-label":re(a.label),className:d,children:e(o,{})})}),children:a.label},String(a.value))),renderInput(s.length>0)]})})}):renderInput(!1),D&&!Z?e(t.Clear,{"aria-label":ie,className:z,children:e(o,{})}):null,e(t.Trigger,{"aria-label":ne,className:z,children:e(t.Icon,{className:p("flex items-center","[transition:rotate_var(--plass-duration)_var(--plass-ease)]","data-[popup-open]:rotate-180"),children:e(r,{})})})]}),e(t.Portal,{children:e(t.Positioner,{className:"plass-portal z-50 [outline:none]",sideOffset:6,children:a(t.Popup,{className:p(V,L[x],u[x]),style:I(be,3),children:[e(t.Empty,{className:"px-2 py-1.5 text-(--plass-muted-fg) empty:hidden",children:G}),e(t.List,{children:s=>e(t.Item,{value:s,disabled:s.disabled,className:_,children:s.custom?a(l.Fragment,{children:[e("span",{className:"absolute start-1.5 flex size-4 items-center justify-center text-(--p-accent) [&_svg]:size-4",children:e(c,{})}),e("span",{className:"truncate",children:F?F(s.label):`Add “${s.label}”`})]}):a(l.Fragment,{children:[e(t.ItemIndicator,{className:"absolute start-1.5 flex size-4 items-center justify-center",children:e(i,{})}),e("span",{className:"truncate",children:s.label})]})},`${s.custom?"custom:":""}${String(s.value)}`)})]})})})]}),J?e(s.Description,{className:p(w[x],"text-(--plass-muted-fg)"),children:J}):null,pe?e(s.Error,{match:!0,className:p(w[x],"text-(--p-accent)"),children:K}):null]})}
@@ -0,0 +1,2 @@
1
+ export { PlCombobox } from './PlCombobox.js';
2
+ export type { PlComboboxOption, PlComboboxProps, PlComboboxValue } from './PlCombobox.js';
@@ -0,0 +1 @@
1
+ export{PlCombobox}from"./PlCombobox.js";
@@ -0,0 +1,66 @@
1
+ import * as React from 'react';
2
+ import { useRender } from '@base-ui/react/use-render';
3
+ import type { PlassDensity, PlassSize } from '../../types.js';
4
+ /**
5
+ * How wide the content is allowed to get.
6
+ *
7
+ * `none` is the extra step and the default, because a `PlContainer`'s job is
8
+ * the gutter — a measure is a second decision, and a page should have to ask
9
+ * for one.
10
+ */
11
+ export type PlContainerWidth = PlassSize | 'none';
12
+ export interface PlContainerProps extends React.ComponentPropsWithoutRef<'div'> {
13
+ /**
14
+ * How wide the content is allowed to get, on the same ladder the breakpoints
15
+ * use — `xs` 30rem, `sm` 40rem, `md` 48rem, `lg` 64rem, `xl` 80rem.
16
+ * @default 'none'
17
+ */
18
+ maxWidth?: PlContainerWidth;
19
+ /**
20
+ * The gutter, on the `size`/`density` scale. Turn it off to keep the centring
21
+ * and the measure without the padding.
22
+ * @default true
23
+ */
24
+ padded?: boolean;
25
+ /**
26
+ * The gutter's scale.
27
+ *
28
+ * `size` here is the size of the *sheet* — it never touches a height or the
29
+ * type scale — and it is independent of `maxWidth`, which is how wide the
30
+ * content gets rather than how far it sits from the edge.
31
+ * @default 'md'
32
+ */
33
+ size?: PlassSize;
34
+ /** @default 'default' */
35
+ density?: PlassDensity;
36
+ /**
37
+ * Centres the content once `maxWidth` is narrower than the page. No effect
38
+ * while `maxWidth` is `none`, because there is nothing left over to centre in.
39
+ * @default true
40
+ */
41
+ centered?: boolean;
42
+ /**
43
+ * Renders something other than a `<div>`: `render={<main />}`,
44
+ * `render={<section />}`. Base UI's own escape hatch.
45
+ */
46
+ render?: useRender.RenderProp;
47
+ children?: React.ReactNode;
48
+ }
49
+ /**
50
+ * Horizontal breathing room, and optionally a measure.
51
+ *
52
+ * It draws nothing — no sheet, no hairline, no shadow — for the same reason
53
+ * `PlAspectRatio` does not. The outermost element on a page is the one thing
54
+ * that must not decide what the page looks like, and a container that carried a
55
+ * `variant` would put a second pane behind every card on it.
56
+ *
57
+ * The two questions it answers are deliberately separate from how the content
58
+ * inside divides itself up: a container holds a `PlGrid` as happily as it holds
59
+ * a single paragraph, and a grid needs no container around it.
60
+ *
61
+ * The gutter is the **sheet** padding track rather than the control one. What
62
+ * sits inside a container is a page, and the margin a page keeps from the edge
63
+ * of a window is the margin a card keeps around a paragraph — not the room a
64
+ * label needs beside the edge of the key it is printed on.
65
+ */
66
+ export declare const PlContainer: React.ForwardRefExoticComponent<PlContainerProps & React.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1 @@
1
+ "use client";import*as e from"react";import{useRender as r}from"@base-ui/react/use-render";import{cx as n,sheetPaddingXClasses as m}from"../../internal/styles.js";const a={xs:"max-w-[30rem]",sm:"max-w-[40rem]",md:"max-w-[48rem]",lg:"max-w-[64rem]",xl:"max-w-[80rem]"};export const PlContainer=/* @__PURE__ */e.forwardRef(function PlContainer({maxWidth:e="none",padded:t=!0,size:o="md",density:s="default",centered:d=!0,render:l,className:i,children:c,...x},f){const u=n("block w-full","none"===e?"":a[e],d?"mx-auto":"",t?m[s][o]:"",i);return r({render:l,ref:f,props:{className:u,children:c,...x}})});
@@ -0,0 +1,2 @@
1
+ export { PlContainer } from './PlContainer.js';
2
+ export type { PlContainerProps, PlContainerWidth } from './PlContainer.js';
@@ -0,0 +1 @@
1
+ export{PlContainer}from"./PlContainer.js";