@justanarthur/modo-ui 0.6.0-canary.9 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (490) hide show
  1. package/README.md +66 -164
  2. package/dist/base.css +4 -141
  3. package/dist/blocks/sidebar-app/index.js +26 -40
  4. package/dist/components/AI/input-message/index.js +16 -23
  5. package/dist/components/AI/thinking-indicator/index.js +6 -9
  6. package/dist/components/accordion/index.d.ts +11 -39
  7. package/dist/components/accordion/index.js +13 -18
  8. package/dist/components/badge/index.d.ts +11 -18
  9. package/dist/components/badge/index.js +7 -12
  10. package/dist/components/button/index.d.ts +17 -53
  11. package/dist/components/button/index.js +6 -11
  12. package/dist/components/card/index.d.ts +9 -32
  13. package/dist/components/card/index.js +11 -17
  14. package/dist/components/copy/index.d.ts +8 -41
  15. package/dist/components/copy/index.js +9 -15
  16. package/dist/components/inputs/checkbox/index.d.ts +9 -28
  17. package/dist/components/inputs/checkbox/index.js +13 -18
  18. package/dist/components/inputs/color-picker/index.d.ts +14 -22
  19. package/dist/components/inputs/color-picker/index.js +18 -26
  20. package/dist/components/inputs/combobox/index.d.ts +20 -85
  21. package/dist/components/inputs/combobox/index.js +18 -27
  22. package/dist/components/inputs/date-time/calendar/index.d.ts +18 -24
  23. package/dist/components/inputs/date-time/calendar/index.js +11 -15
  24. package/dist/components/inputs/date-time/date-picker/index.d.ts +16 -105
  25. package/dist/components/inputs/date-time/date-picker/index.js +25 -35
  26. package/dist/components/inputs/date-time/date-range-picker/index.d.ts +12 -106
  27. package/dist/components/inputs/date-time/date-range-picker/index.js +24 -35
  28. package/dist/components/inputs/date-time/duration-picker/index.d.ts +13 -66
  29. package/dist/components/inputs/date-time/duration-picker/index.js +24 -33
  30. package/dist/components/inputs/date-time/month-picker/index.d.ts +10 -60
  31. package/dist/components/inputs/date-time/month-picker/index.js +23 -32
  32. package/dist/components/inputs/date-time/time-picker/index.d.ts +10 -58
  33. package/dist/components/inputs/date-time/time-picker/index.js +24 -33
  34. package/dist/components/inputs/input/index.d.ts +13 -95
  35. package/dist/components/inputs/input/index.js +9 -18
  36. package/dist/components/inputs/radio/index.d.ts +5 -20
  37. package/dist/components/inputs/radio/index.js +12 -16
  38. package/dist/components/inputs/search/index.d.ts +3 -3
  39. package/dist/components/inputs/search/index.js +18 -26
  40. package/dist/components/inputs/select/index.d.ts +23 -99
  41. package/dist/components/inputs/select/index.js +14 -29
  42. package/dist/components/inputs/slider/index.d.ts +0 -9
  43. package/dist/components/inputs/slider/index.js +5 -8
  44. package/dist/components/inputs/switch/index.d.ts +2 -8
  45. package/dist/components/inputs/switch/index.js +12 -15
  46. package/dist/components/inputs/textarea/index.d.ts +1 -20
  47. package/dist/components/inputs/textarea/index.js +6 -9
  48. package/dist/components/navigation/sidebar/index.d.ts +21 -44
  49. package/dist/components/navigation/sidebar/index.js +31 -42
  50. package/dist/components/navigation/tabs/index.d.ts +2 -8
  51. package/dist/components/navigation/tabs/index.js +10 -15
  52. package/dist/components/navigation/tabs-subtle/index.js +10 -13
  53. package/dist/components/overlays/alert-dialog/index.d.ts +16 -135
  54. package/dist/components/overlays/alert-dialog/index.js +13 -23
  55. package/dist/components/overlays/command/index.d.ts +20 -25
  56. package/dist/components/overlays/command/index.js +17 -25
  57. package/dist/components/overlays/context-menu/index.d.ts +17 -39
  58. package/dist/components/overlays/context-menu/index.js +18 -29
  59. package/dist/components/overlays/dialog/index.d.ts +16 -42
  60. package/dist/components/overlays/dialog/index.js +12 -20
  61. package/dist/components/overlays/dropdown/index.d.ts +34 -304
  62. package/dist/components/overlays/dropdown/index.js +17 -44
  63. package/dist/components/overlays/popover/index.d.ts +12 -38
  64. package/dist/components/overlays/popover/index.js +9 -13
  65. package/dist/components/overlays/preview-card/index.js +8 -12
  66. package/dist/components/overlays/sheet/index.d.ts +8 -25
  67. package/dist/components/overlays/sheet/index.js +13 -19
  68. package/dist/components/overlays/toast/index.d.ts +50 -209
  69. package/dist/components/overlays/toast/index.js +10 -23
  70. package/dist/components/overlays/tooltip/index.d.ts +21 -123
  71. package/dist/components/overlays/tooltip/index.js +6 -16
  72. package/dist/components/table/index.d.ts +8 -63
  73. package/dist/components/table/index.js +9 -20
  74. package/dist/index.d.ts +1048 -2999
  75. package/dist/index.js +82 -231
  76. package/dist/preset.d.ts +0 -22
  77. package/dist/preset.js +2 -24
  78. package/dist/primitives/code/index.js +5 -8
  79. package/dist/primitives/craft/index.js +6 -10
  80. package/dist/primitives/fluid-hover/index.js +8 -10
  81. package/dist/primitives/morph/index.js +10 -16
  82. package/dist/primitives/motion/index.js +8 -11
  83. package/dist/primitives/scroll-area/index.js +3 -5
  84. package/dist/primitives/sizes/index.js +4 -6
  85. package/dist/primitives/surface/index.js +4 -6
  86. package/dist/shared/{components-c7rwx0ap.js → components-0q0sqfh4.js} +49 -27
  87. package/dist/shared/components-0sn7ypjw.js +61 -0
  88. package/dist/shared/{components-vc864c51.js → components-11da9ajg.js} +5 -8
  89. package/dist/shared/components-1434p1mh.js +123 -0
  90. package/dist/shared/{components-c74gf16d.js → components-1z6tdadk.js} +24 -40
  91. package/dist/shared/{components-bae8sbjx.js → components-27nnvrwe.js} +14 -15
  92. package/dist/shared/{components-qh1cvj6p.js → components-2dxkv6zm.js} +7 -8
  93. package/dist/shared/{components-y0kfy2g4.js → components-2ecg8svx.js} +152 -234
  94. package/dist/shared/{components-c5w5zk0s.js → components-2ph6t61s.js} +34 -37
  95. package/dist/shared/{components-4j3t39dd.js → components-39jq9va1.js} +24 -29
  96. package/dist/shared/components-3ky44908.js +9 -0
  97. package/dist/shared/{components-syynwm1r.js → components-3mkepka5.js} +25 -28
  98. package/dist/shared/{components-wgtjt2af.js → components-4700p9kz.js} +22 -24
  99. package/dist/shared/{components-yhgq0qxx.js → components-59efxjd9.js} +12 -13
  100. package/dist/shared/{components-91zw3d9f.js → components-5vgpnxgy.js} +27 -51
  101. package/dist/shared/{components-kz5q11pp.js → components-5xc2j8jz.js} +18 -19
  102. package/dist/shared/{components-zkk3fmw8.js → components-6p8tfcd6.js} +29 -57
  103. package/dist/shared/{components-4nck8acq.js → components-7r3etddy.js} +54 -19
  104. package/dist/shared/{components-svkt577j.js → components-8snj490h.js} +32 -78
  105. package/dist/shared/{components-ctqmge8t.js → components-b0eac83j.js} +30 -9
  106. package/dist/shared/{components-9sttq78t.js → components-b2wyq2cq.js} +59 -41
  107. package/dist/shared/{components-pv1dyrtn.js → components-b3c5et5b.js} +38 -49
  108. package/dist/shared/{components-rrbpmfx4.js → components-c6s6b43g.js} +2 -3
  109. package/dist/shared/{components-pwayrkw9.js → components-chacnk61.js} +19 -19
  110. package/dist/shared/{components-71nbt03m.js → components-cv16mryv.js} +7 -26
  111. package/dist/shared/{components-hgv6tygd.js → components-d6xtjht3.js} +30 -35
  112. package/dist/shared/{components-z8fedth5.js → components-dk0gjr5a.js} +18 -19
  113. package/dist/shared/{components-cet3jpa0.js → components-fzrq6tr3.js} +34 -37
  114. package/dist/shared/{components-cnead5qm.js → components-gc5vtq2f.js} +30 -66
  115. package/dist/shared/components-gf5s6ap9.js +42 -0
  116. package/dist/shared/{components-0h78g3b5.js → components-gz8zf3ec.js} +55 -56
  117. package/dist/shared/{components-mattt5jp.js → components-h2ajmhwn.js} +35 -107
  118. package/dist/shared/{components-m06yq8wk.js → components-hqeq3w9q.js} +23 -38
  119. package/dist/shared/{components-7qx17na9.js → components-hw9yk32z.js} +24 -36
  120. package/dist/shared/components-hyq23phv.js +310 -0
  121. package/dist/shared/{components-9jmjnkqd.js → components-jbbmdr74.js} +22 -41
  122. package/dist/shared/{components-dcc02hs2.js → components-jjw69c4c.js} +4 -7
  123. package/dist/shared/{components-303jf96s.js → components-jthe1pwb.js} +420 -139
  124. package/dist/shared/{components-dtca4s6b.js → components-jwst3vtj.js} +76 -224
  125. package/dist/shared/{components-dc5q749x.js → components-kvr7f9hy.js} +10 -19
  126. package/dist/shared/{components-s8yqk2dc.js → components-kwa6mrf9.js} +11 -46
  127. package/dist/shared/{components-de99ykt7.js → components-men63rwj.js} +2 -3
  128. package/dist/shared/{components-qx27excf.js → components-mjthm1kf.js} +9 -13
  129. package/dist/shared/{components-1e64t8aj.js → components-n42c79bz.js} +22 -23
  130. package/dist/shared/{components-tz1fv35x.js → components-n7mjr357.js} +2 -3
  131. package/dist/shared/components-ng72k97e.js +128 -0
  132. package/dist/shared/{components-w2jqa6hx.js → components-pbmqctfa.js} +65 -169
  133. package/dist/shared/{components-px2zm7dc.js → components-q5xj5c16.js} +8 -9
  134. package/dist/shared/components-raknhppb.js +64 -0
  135. package/dist/shared/{components-2a7hcand.js → components-rr7a6ja9.js} +27 -59
  136. package/dist/shared/{components-005jt2nz.js → components-s083f38z.js} +34 -164
  137. package/dist/shared/components-s5ngg32c.js +267 -0
  138. package/dist/shared/components-sn1rxx1d.js +143 -0
  139. package/dist/shared/{components-r8eqs7gz.js → components-ta7shw28.js} +4 -4
  140. package/dist/shared/{components-9as3rf68.js → components-vc7vq5nz.js} +3 -6
  141. package/dist/shared/{components-ft3zdc79.js → components-vfbhxf5r.js} +5 -6
  142. package/dist/shared/components-vynjtrk6.js +19 -0
  143. package/dist/shared/{components-p0fm0bab.js → components-w1r67ag9.js} +149 -294
  144. package/dist/shared/{components-xd3emmy4.js → components-w90endve.js} +72 -71
  145. package/dist/shared/{components-t5pk5nmc.js → components-wvp1m52g.js} +102 -149
  146. package/dist/shared/components-wy9jpqny.js +146 -0
  147. package/dist/shared/{components-yxmxn2jp.js → components-y9y0g8er.js} +28 -52
  148. package/dist/shared/components-ypp01w3p.js +986 -0
  149. package/dist/shared/{components-czdvj1a8.js → components-zfnmn5d4.js} +36 -82
  150. package/dist/shared/{components-jqpefjsn.js → components-zrkzcayz.js} +6 -54
  151. package/dist/shared/{components-vf45j12c.js → components-zx6b6yby.js} +18 -4
  152. package/dist/styles.css +32 -320
  153. package/dist/tailwind.css +0 -16
  154. package/dist/tokens.css +0 -67
  155. package/package.json +4 -227
  156. package/DESIGN.md +0 -623
  157. package/blocks/sidebar-app/examples.mdx +0 -33
  158. package/blocks/sidebar-app/index.tsx +0 -218
  159. package/blocks/sidebar-app/inset-topbar.tsx +0 -25
  160. package/blocks/sidebar-app/menu-grid.ts +0 -26
  161. package/blocks/sidebar-app/nav-data.ts +0 -36
  162. package/blocks/sidebar-app/search-field.tsx +0 -48
  163. package/blocks/sidebar-app/user-footer.tsx +0 -67
  164. package/blocks/sidebar-app/workspace-header.tsx +0 -129
  165. package/components/AI/input-message/examples.mdx +0 -130
  166. package/components/AI/input-message/file-thumbnail.tsx +0 -173
  167. package/components/AI/input-message/index.tsx +0 -1385
  168. package/components/AI/thinking-indicator/examples.mdx +0 -27
  169. package/components/AI/thinking-indicator/index.tsx +0 -210
  170. package/components/accordion/examples.mdx +0 -233
  171. package/components/accordion/index.tsx +0 -1071
  172. package/components/avatar/examples.mdx +0 -95
  173. package/components/avatar/index.tsx +0 -129
  174. package/components/badge/change-demo.tsx +0 -29
  175. package/components/badge/examples.mdx +0 -124
  176. package/components/badge/index.tsx +0 -225
  177. package/components/badge/variants.ts +0 -73
  178. package/components/button/examples.mdx +0 -168
  179. package/components/button/index.tsx +0 -424
  180. package/components/button/loading-demo.tsx +0 -25
  181. package/components/button/variants.ts +0 -168
  182. package/components/card/examples.mdx +0 -251
  183. package/components/card/index.tsx +0 -1070
  184. package/components/copy/examples.mdx +0 -125
  185. package/components/copy/index.tsx +0 -662
  186. package/components/inputs/checkbox/examples.mdx +0 -87
  187. package/components/inputs/checkbox/index.tsx +0 -611
  188. package/components/inputs/checkbox/select-all-demo.tsx +0 -48
  189. package/components/inputs/color-picker/examples.mdx +0 -111
  190. package/components/inputs/color-picker/index.tsx +0 -1981
  191. package/components/inputs/color-picker/variants.ts +0 -401
  192. package/components/inputs/combobox/examples.mdx +0 -366
  193. package/components/inputs/combobox/index.tsx +0 -1527
  194. package/components/inputs/combobox/remote-demo.tsx +0 -105
  195. package/components/inputs/date-time/calendar/examples.mdx +0 -45
  196. package/components/inputs/date-time/calendar/index.tsx +0 -370
  197. package/components/inputs/date-time/calendar/use-month-window.ts +0 -173
  198. package/components/inputs/date-time/date-picker/examples.mdx +0 -243
  199. package/components/inputs/date-time/date-picker/index.tsx +0 -476
  200. package/components/inputs/date-time/date-picker/masked-date-input.tsx +0 -348
  201. package/components/inputs/date-time/date-range-picker/examples.mdx +0 -93
  202. package/components/inputs/date-time/date-range-picker/index.tsx +0 -525
  203. package/components/inputs/date-time/duration-picker/examples.mdx +0 -40
  204. package/components/inputs/date-time/duration-picker/index.tsx +0 -253
  205. package/components/inputs/date-time/month-picker/examples.mdx +0 -45
  206. package/components/inputs/date-time/month-picker/index.tsx +0 -254
  207. package/components/inputs/date-time/picker-shell.tsx +0 -581
  208. package/components/inputs/date-time/time-columns.tsx +0 -94
  209. package/components/inputs/date-time/time-picker/examples.mdx +0 -57
  210. package/components/inputs/date-time/time-picker/index.tsx +0 -227
  211. package/components/inputs/field/examples.mdx +0 -117
  212. package/components/inputs/field/index.tsx +0 -268
  213. package/components/inputs/file-dropzone/examples.mdx +0 -83
  214. package/components/inputs/file-dropzone/file-row.tsx +0 -201
  215. package/components/inputs/file-dropzone/index.tsx +0 -316
  216. package/components/inputs/file-dropzone/upload-demo.tsx +0 -67
  217. package/components/inputs/file-dropzone/variants.ts +0 -94
  218. package/components/inputs/input/examples.mdx +0 -166
  219. package/components/inputs/input/index.tsx +0 -494
  220. package/components/inputs/input/password-demo.tsx +0 -30
  221. package/components/inputs/label/examples.mdx +0 -67
  222. package/components/inputs/label/index.tsx +0 -85
  223. package/components/inputs/number-input/examples.mdx +0 -69
  224. package/components/inputs/number-input/index.tsx +0 -221
  225. package/components/inputs/radio/examples.mdx +0 -77
  226. package/components/inputs/radio/index.tsx +0 -636
  227. package/components/inputs/search/examples.mdx +0 -74
  228. package/components/inputs/search/index.tsx +0 -333
  229. package/components/inputs/select/examples.mdx +0 -296
  230. package/components/inputs/select/index.tsx +0 -1044
  231. package/components/inputs/select/variants.ts +0 -32
  232. package/components/inputs/slider/examples.mdx +0 -153
  233. package/components/inputs/slider/index.tsx +0 -1867
  234. package/components/inputs/switch/examples.mdx +0 -96
  235. package/components/inputs/switch/index.tsx +0 -504
  236. package/components/inputs/textarea/examples.mdx +0 -126
  237. package/components/inputs/textarea/index.tsx +0 -207
  238. package/components/navigation/navigation-menu/examples.mdx +0 -136
  239. package/components/navigation/navigation-menu/index.tsx +0 -704
  240. package/components/navigation/pagination/examples.mdx +0 -74
  241. package/components/navigation/pagination/index.tsx +0 -401
  242. package/components/navigation/sidebar/examples.mdx +0 -325
  243. package/components/navigation/sidebar/index.tsx +0 -453
  244. package/components/navigation/sidebar/sidebar-core.tsx +0 -1408
  245. package/components/navigation/sidebar/sidebar-menu.tsx +0 -1495
  246. package/components/navigation/sidebar/sidebar.css +0 -74
  247. package/components/navigation/sidebar/variants.ts +0 -55
  248. package/components/navigation/tabs/examples.mdx +0 -89
  249. package/components/navigation/tabs/index.tsx +0 -494
  250. package/components/navigation/tabs-subtle/examples.mdx +0 -49
  251. package/components/navigation/tabs-subtle/index.tsx +0 -512
  252. package/components/overlays/alert-dialog/examples.mdx +0 -123
  253. package/components/overlays/alert-dialog/index.tsx +0 -276
  254. package/components/overlays/alert-dialog/pending-demo.tsx +0 -36
  255. package/components/overlays/command/examples.mdx +0 -113
  256. package/components/overlays/command/index.tsx +0 -425
  257. package/components/overlays/context-menu/examples.mdx +0 -56
  258. package/components/overlays/context-menu/index.tsx +0 -279
  259. package/components/overlays/dialog/examples.mdx +0 -165
  260. package/components/overlays/dialog/index.tsx +0 -451
  261. package/components/overlays/dropdown/dropdown-search.tsx +0 -395
  262. package/components/overlays/dropdown/examples.mdx +0 -444
  263. package/components/overlays/dropdown/index.tsx +0 -1241
  264. package/components/overlays/dropdown/menu-item.tsx +0 -510
  265. package/components/overlays/dropdown/menu-parts.tsx +0 -725
  266. package/components/overlays/popover/anchored-demo.tsx +0 -59
  267. package/components/overlays/popover/examples.mdx +0 -203
  268. package/components/overlays/popover/index.tsx +0 -317
  269. package/components/overlays/preview-card/examples.mdx +0 -61
  270. package/components/overlays/preview-card/index.tsx +0 -204
  271. package/components/overlays/sheet/examples.mdx +0 -101
  272. package/components/overlays/sheet/index.tsx +0 -307
  273. package/components/overlays/toast/examples.mdx +0 -85
  274. package/components/overlays/toast/global-demo.tsx +0 -72
  275. package/components/overlays/toast/index.tsx +0 -544
  276. package/components/overlays/toast/manager.ts +0 -193
  277. package/components/overlays/tooltip/examples.mdx +0 -106
  278. package/components/overlays/tooltip/index.tsx +0 -539
  279. package/components/progress/examples.mdx +0 -59
  280. package/components/progress/index.tsx +0 -174
  281. package/components/progress/progress.css +0 -49
  282. package/components/progress/step-demo.tsx +0 -27
  283. package/components/table/examples.mdx +0 -188
  284. package/components/table/index.tsx +0 -535
  285. package/components/table/sort-demo.tsx +0 -61
  286. package/dist/components/avatar/index.d.ts +0 -46
  287. package/dist/components/avatar/index.js +0 -19
  288. package/dist/components/badge/variants.d.ts +0 -33
  289. package/dist/components/badge/variants.js +0 -10
  290. package/dist/components/button/variants.d.ts +0 -39
  291. package/dist/components/button/variants.js +0 -8
  292. package/dist/components/inputs/color-picker/variants.d.ts +0 -61
  293. package/dist/components/inputs/color-picker/variants.js +0 -28
  294. package/dist/components/inputs/field/index.d.ts +0 -116
  295. package/dist/components/inputs/field/index.js +0 -29
  296. package/dist/components/inputs/file-dropzone/index.d.ts +0 -167
  297. package/dist/components/inputs/file-dropzone/index.js +0 -33
  298. package/dist/components/inputs/file-dropzone/variants.d.ts +0 -35
  299. package/dist/components/inputs/file-dropzone/variants.js +0 -12
  300. package/dist/components/inputs/label/index.d.ts +0 -32
  301. package/dist/components/inputs/label/index.js +0 -11
  302. package/dist/components/inputs/number-input/index.d.ts +0 -87
  303. package/dist/components/inputs/number-input/index.js +0 -21
  304. package/dist/components/inputs/select/variants.d.ts +0 -5
  305. package/dist/components/inputs/select/variants.js +0 -6
  306. package/dist/components/navigation/navigation-menu/index.d.ts +0 -126
  307. package/dist/components/navigation/navigation-menu/index.js +0 -41
  308. package/dist/components/navigation/pagination/index.d.ts +0 -75
  309. package/dist/components/navigation/pagination/index.js +0 -41
  310. package/dist/components/navigation/sidebar/variants.d.ts +0 -25
  311. package/dist/components/navigation/sidebar/variants.js +0 -28
  312. package/dist/components/progress/index.d.ts +0 -56
  313. package/dist/components/progress/index.js +0 -15
  314. package/dist/docs/index.d.ts +0 -83
  315. package/dist/docs/index.js +0 -288
  316. package/dist/docs/vite.d.ts +0 -31
  317. package/dist/docs/vite.js +0 -45
  318. package/dist/lib/date-locale.d.ts +0 -26
  319. package/dist/lib/date-locale.js +0 -24
  320. package/dist/lib/field-classes.d.ts +0 -149
  321. package/dist/lib/field-classes.js +0 -41
  322. package/dist/lib/field-variants.d.ts +0 -47
  323. package/dist/lib/field-variants.js +0 -26
  324. package/dist/lib/fluid-hover-highlight.d.ts +0 -112
  325. package/dist/lib/fluid-hover-highlight.js +0 -17
  326. package/dist/lib/focus-ring.d.ts +0 -18
  327. package/dist/lib/focus-ring.js +0 -11
  328. package/dist/lib/goo-indicator.d.ts +0 -46
  329. package/dist/lib/goo-indicator.js +0 -14
  330. package/dist/lib/icon-context.d.ts +0 -30
  331. package/dist/lib/icon-context.js +0 -12
  332. package/dist/lib/inert.d.ts +0 -9
  333. package/dist/lib/inert.js +0 -8
  334. package/dist/lib/morph-layers.d.ts +0 -93
  335. package/dist/lib/morph-layers.js +0 -13
  336. package/dist/lib/morph-part.d.ts +0 -21
  337. package/dist/lib/morph-part.js +0 -12
  338. package/dist/lib/popup.d.ts +0 -20
  339. package/dist/lib/popup.js +0 -12
  340. package/dist/lib/reduced-motion.d.ts +0 -9
  341. package/dist/lib/reduced-motion.js +0 -6
  342. package/dist/lib/row-index.d.ts +0 -10
  343. package/dist/lib/row-index.js +0 -8
  344. package/dist/lib/row-order.d.ts +0 -28
  345. package/dist/lib/row-order.js +0 -10
  346. package/dist/lib/scroll-column.d.ts +0 -31
  347. package/dist/lib/scroll-column.js +0 -19
  348. package/dist/lib/shape-context.d.ts +0 -30
  349. package/dist/lib/shape-context.js +0 -13
  350. package/dist/lib/shape-radius.d.ts +0 -19
  351. package/dist/lib/shape-radius.js +0 -6
  352. package/dist/lib/size-context.d.ts +0 -94
  353. package/dist/lib/size-context.js +0 -20
  354. package/dist/lib/size-scale.d.ts +0 -79
  355. package/dist/lib/size-scale.js +0 -8
  356. package/dist/lib/slot.d.ts +0 -39
  357. package/dist/lib/slot.js +0 -14
  358. package/dist/lib/springs.d.ts +0 -44
  359. package/dist/lib/springs.js +0 -8
  360. package/dist/lib/surface-classes.d.ts +0 -19
  361. package/dist/lib/surface-classes.js +0 -10
  362. package/dist/lib/surface-context.d.ts +0 -9
  363. package/dist/lib/surface-context.js +0 -8
  364. package/dist/lib/use-controllable-state.d.ts +0 -2
  365. package/dist/lib/use-controllable-state.js +0 -6
  366. package/dist/lib/use-fluid-hover.d.ts +0 -138
  367. package/dist/lib/use-fluid-hover.js +0 -14
  368. package/dist/lib/use-is-mobile.d.ts +0 -2
  369. package/dist/lib/use-is-mobile.js +0 -6
  370. package/dist/lib/use-keyboard-nav-gate.d.ts +0 -20
  371. package/dist/lib/use-keyboard-nav-gate.js +0 -7
  372. package/dist/lib/use-merge-split.d.ts +0 -47
  373. package/dist/lib/use-merge-split.js +0 -15
  374. package/dist/lib/use-morph.d.ts +0 -101
  375. package/dist/lib/use-morph.js +0 -20
  376. package/dist/lib/use-touch-primary.d.ts +0 -2
  377. package/dist/lib/use-touch-primary.js +0 -6
  378. package/dist/lib/utils.d.ts +0 -3
  379. package/dist/lib/utils.js +0 -6
  380. package/dist/primitives/separator/index.d.ts +0 -25
  381. package/dist/primitives/separator/index.js +0 -9
  382. package/dist/primitives/skeleton/index.d.ts +0 -35
  383. package/dist/primitives/skeleton/index.js +0 -13
  384. package/dist/shared/components-01w9qcfa.js +0 -277
  385. package/dist/shared/components-124epb7f.js +0 -53
  386. package/dist/shared/components-26snnbs9.js +0 -322
  387. package/dist/shared/components-2krsc300.js +0 -254
  388. package/dist/shared/components-2qbqqpgq.js +0 -1545
  389. package/dist/shared/components-34txk9rj.js +0 -35
  390. package/dist/shared/components-3h92d94m.js +0 -23
  391. package/dist/shared/components-4vfm04wq.js +0 -82
  392. package/dist/shared/components-54nq988h.js +0 -123
  393. package/dist/shared/components-7s7pykk5.js +0 -281
  394. package/dist/shared/components-868v7scv.js +0 -399
  395. package/dist/shared/components-8jrk5eye.js +0 -448
  396. package/dist/shared/components-adkarj8n.js +0 -35
  397. package/dist/shared/components-b1e239g3.js +0 -28
  398. package/dist/shared/components-b94t6qtj.js +0 -143
  399. package/dist/shared/components-bsqynhaj.js +0 -179
  400. package/dist/shared/components-c9yr4ed1.js +0 -44
  401. package/dist/shared/components-d3shbwqq.js +0 -95
  402. package/dist/shared/components-dhgk6mbt.js +0 -16
  403. package/dist/shared/components-drxrtnp2.js +0 -25
  404. package/dist/shared/components-f7h57m6t.js +0 -59
  405. package/dist/shared/components-g3eafs70.js +0 -337
  406. package/dist/shared/components-gx4h5rbb.js +0 -40
  407. package/dist/shared/components-gyt7my41.js +0 -328
  408. package/dist/shared/components-h6p86be3.js +0 -19
  409. package/dist/shared/components-h83az0bz.js +0 -33
  410. package/dist/shared/components-hdzrqqpx.js +0 -55
  411. package/dist/shared/components-krtx3m5b.js +0 -84
  412. package/dist/shared/components-kswxnm3h.js +0 -24
  413. package/dist/shared/components-mhza2wdn.js +0 -482
  414. package/dist/shared/components-mrbaxt8q.js +0 -62
  415. package/dist/shared/components-pt5ftm4p.js +0 -38
  416. package/dist/shared/components-rtadhd9j.js +0 -64
  417. package/dist/shared/components-tv7b8tet.js +0 -271
  418. package/dist/shared/components-tz4gaf1v.js +0 -23
  419. package/dist/shared/components-wbbckbw8.js +0 -34
  420. package/dist/shared/components-wknae3m4.js +0 -298
  421. package/dist/shared/components-xdqmt6ed.js +0 -20
  422. package/dist/shared/components-xjkdvnbg.js +0 -107
  423. package/dist/shared/components-z3v0n0de.js +0 -11
  424. package/dist/tokens/colors.css +0 -230
  425. package/dist/tokens/motion.css +0 -40
  426. package/dist/tokens/radius.css +0 -10
  427. package/dist/tokens/spacing.css +0 -9
  428. package/dist/tokens/typography.css +0 -119
  429. package/docs/chrome.css +0 -120
  430. package/docs/chrome.tsx +0 -283
  431. package/docs/index.ts +0 -9
  432. package/docs/vite.ts +0 -85
  433. package/index.ts +0 -60
  434. package/lib/date-locale.ts +0 -195
  435. package/lib/field-classes.ts +0 -121
  436. package/lib/field-variants.ts +0 -117
  437. package/lib/fluid-hover-highlight.tsx +0 -139
  438. package/lib/focus-ring.tsx +0 -46
  439. package/lib/goo-indicator.tsx +0 -261
  440. package/lib/icon-context.tsx +0 -310
  441. package/lib/inert.ts +0 -22
  442. package/lib/morph-layers.tsx +0 -102
  443. package/lib/morph-part.tsx +0 -49
  444. package/lib/popup.ts +0 -52
  445. package/lib/reduced-motion.ts +0 -19
  446. package/lib/row-index.tsx +0 -29
  447. package/lib/row-order.tsx +0 -126
  448. package/lib/scroll-column.tsx +0 -273
  449. package/lib/shape-context.tsx +0 -138
  450. package/lib/shape-radius.ts +0 -67
  451. package/lib/size-context.tsx +0 -66
  452. package/lib/size-scale.ts +0 -115
  453. package/lib/slot.ts +0 -115
  454. package/lib/springs.ts +0 -62
  455. package/lib/surface-classes.ts +0 -58
  456. package/lib/surface-context.tsx +0 -21
  457. package/lib/use-controllable-state.ts +0 -44
  458. package/lib/use-fluid-hover.ts +0 -541
  459. package/lib/use-is-mobile.ts +0 -25
  460. package/lib/use-keyboard-nav-gate.ts +0 -45
  461. package/lib/use-merge-split.tsx +0 -209
  462. package/lib/use-morph.ts +0 -575
  463. package/lib/use-touch-primary.tsx +0 -43
  464. package/lib/utils.ts +0 -37
  465. package/preset.ts +0 -199
  466. package/primitives/code/examples.mdx +0 -27
  467. package/primitives/code/index.tsx +0 -80
  468. package/primitives/craft/demos.tsx +0 -173
  469. package/primitives/craft/examples.mdx +0 -142
  470. package/primitives/craft/index.tsx +0 -76
  471. package/primitives/fluid-hover/examples.mdx +0 -84
  472. package/primitives/fluid-hover/index.tsx +0 -316
  473. package/primitives/morph/examples.mdx +0 -139
  474. package/primitives/morph/index.tsx +0 -192
  475. package/primitives/motion/examples.mdx +0 -100
  476. package/primitives/motion/index.tsx +0 -160
  477. package/primitives/scroll-area/examples.mdx +0 -58
  478. package/primitives/scroll-area/index.tsx +0 -204
  479. package/primitives/separator/examples.mdx +0 -30
  480. package/primitives/separator/index.tsx +0 -53
  481. package/primitives/sizes/examples.mdx +0 -167
  482. package/primitives/sizes/index.tsx +0 -89
  483. package/primitives/skeleton/examples.mdx +0 -51
  484. package/primitives/skeleton/index.tsx +0 -72
  485. package/primitives/skeleton/skeleton.css +0 -15
  486. package/primitives/surface/examples.mdx +0 -173
  487. package/primitives/surface/index.tsx +0 -109
  488. package/primitives/surface/surface.css +0 -176
  489. /package/dist/shared/{components-3ey0hzpb.js → components-1v7rxytx.js} +0 -0
  490. /package/dist/shared/{components-jcnjay5g.js → components-ezxhrmer.js} +0 -0
@@ -1,6 +1,6 @@
1
- import { MenuRootChangeEventDetails as MenuRootChangeEventDetails2, MenuTriggerProps } from "@base-ui/react/menu";
2
- import { Menu as BaseMenu } from "@base-ui/react/menu";
3
- import { ComponentProps as ComponentProps2, ForwardRefExoticComponent, HTMLAttributes as HTMLAttributes4, ReactNode as ReactNode4, RefAttributes, RefObject as RefObject5 } from "react";
1
+ import { MenuTriggerProps } from "@base-ui/react/menu";
2
+ import { Menu } from "@base-ui/react/menu";
3
+ import { ComponentProps, ForwardRefExoticComponent, HTMLAttributes as HTMLAttributes3, ReactNode as ReactNode3, RefAttributes, RefObject as RefObject2 } from "react";
4
4
  type SizeVariant = "default" | "compact";
5
5
  import { HTMLAttributes, InputHTMLAttributes } from "react";
6
6
  import { ForwardRefExoticComponent as ForwardRefExoticComponent_tcubfn } from "react";
@@ -44,11 +44,10 @@ interface MenuItemRenderOptions {
44
44
  checkbox: boolean;
45
45
  /** The item's checked state (radio and checkbox items). */
46
46
  checked?: boolean;
47
- /** The radio value: the item's index, or a `Dropdown.RadioItem`'s own value. */
48
- value: unknown;
47
+ /** The item's index — doubles as the radio value. */
48
+ value: number;
49
49
  disabled?: boolean;
50
- /** Typeahead text. Undefined for a children-based row: the primitive reads its text content. */
51
- label?: string;
50
+ label: string;
52
51
  closeOnClick: boolean;
53
52
  /** The row's activation. It goes on the primitive, not on `element`: Base
54
53
  * UI's Enter/Space activation calls the primitive's own `onClick` prop and
@@ -81,241 +80,35 @@ interface DropdownContextValue {
81
80
  /** Local addition. Toggles the row at an AUTHORED index (see
82
81
  * `sourceIndex`). Present with `selfManaged`. */
83
82
  toggleIndex?: (sourceIndex: number) => void;
84
- /** Local addition. Keeps the highlight on a row while its submenu is open. */
85
- pin?: (index: number, on: boolean) => void;
86
- /** Local addition. A value-checked row (`Dropdown.CheckboxItem`,
87
- * `Dropdown.RadioItem`) reports itself for the merged selection background. */
88
- reportChecked?: (index: number, on: boolean) => void;
89
83
  }
90
84
  declare function useDropdown(): DropdownContextValue;
91
85
  /** Null-safe context read for callers that render outside a provider. */
92
86
  declare function useDropdownMaybe(): DropdownContextValue | null;
93
- interface MenuItemProps extends Omit<HTMLAttributes2<HTMLDivElement>, "onSelect"> {
87
+ interface MenuItemProps extends HTMLAttributes2<HTMLDivElement> {
94
88
  /** Optional leading icon. When omitted, the row renders text-only with no
95
89
  * reserved icon column. */
96
90
  icon?: IconComponent;
97
- /** The row text, also its typeahead text and what a `Dropdown.Search filter` matches. Omit it to pass the row's content as `children`. */
98
- label?: string;
99
- /** Position among the panel's rows, for the index-based selection (`checkedIndex`). Omitted, the row takes its place in document order. */
100
- index?: number;
101
- /** The row's content when there is no `label`: text, or any nodes (an svg among them takes the icon size). */
102
- children?: ReactNode2;
91
+ label: string;
92
+ index: number;
103
93
  /** When a boolean, the item is a radio-style option (role="menuitemradio"
104
94
  * with aria-checked). When undefined, it is a plain action item
105
95
  * (role="menuitem"), unless the panel owns the selection — then the row
106
96
  * reads its checked state off the panel and toggles it on activation. */
107
97
  checked?: boolean;
108
- /** Called when the row is picked, by pointer or keyboard. Call `event.preventDefault()` to keep the menu open. */
109
- onSelect?: (event: Event) => void;
110
- /** Dims the row; the pointer and the keyboard skip it. Defaults to `false`. */
98
+ onSelect?: () => void;
111
99
  disabled?: boolean;
112
100
  /** Popup-only (inside DropdownContent): whether activating the item closes
113
- * the menu. Ignored in the inline Dropdown panel. Defaults to `true` (`false` in multiple selection). */
101
+ * the menu. Ignored in the inline Dropdown panel. @default true */
114
102
  closeOnClick?: boolean;
115
- /** Indents the row to the label column of rows with an icon. Defaults to `false`. */
116
- inset?: boolean;
117
- /** A keyboard shortcut shown muted at the row's end, e.g. `⌘K` (see Dropdown.Shortcut). */
118
- shortcut?: ReactNode2;
119
- /** Typeahead text for a row whose content is more than a string (an icon beside markup): the key a press matches while the menu is open. Defaults to `label`, else the row's text `children`. */
120
- textValue?: string;
121
- /** The element that becomes the row, e.g. a link: `render={<a href="/docs" />}`. Its own props and ref are kept, the row's classes and handlers are added, and its children are the row's content. */
122
- render?: ReactElement;
123
- /** Compose onto the single child instead of `render`: `<Dropdown.Item asChild><a href="/docs">Docs</a></Dropdown.Item>`. Defaults to `false`. */
124
- asChild?: boolean;
125
103
  /** Internal: the row's authored index, stamped by a filtering panel that
126
104
  * re-indexed the visible rows. Selection is keyed on it. */
127
105
  sourceIndex?: number;
128
- /** Internal: the selection primitive a `Dropdown.CheckboxItem` / `Dropdown.RadioItem` forces. */
129
- kind?: "checkbox" | "radio";
130
- /** Internal: a `Dropdown.RadioItem`'s value. */
131
- value?: unknown;
132
- /** Internal: keeps the panel's highlight on the row (a `Dropdown.SubTrigger` whose submenu is open). */
133
- pinned?: boolean;
134
106
  }
135
- interface DropdownShortcutProps extends HTMLAttributes2<HTMLElement> {
136
- /** The keys, e.g. `⇧⌘P`. */
137
- children?: ReactNode2;
138
- /** Extra classes. */
139
- className?: string;
140
- }
141
- /** A muted caption at the end of a row: the row's keyboard shortcut. */
142
- declare const DropdownShortcut: ForwardRefExoticComponent_tcubfn2<DropdownShortcutProps & RefAttributes_miuf562<HTMLElement>>;
143
107
  declare const MenuItem: ForwardRefExoticComponent_tcubfn2<MenuItemProps & RefAttributes_miuf562<HTMLDivElement>>;
144
- import { Menu as Menu2, MenuRootChangeEventDetails } from "@base-ui/react/menu";
145
- import { ComponentProps, HTMLAttributes as HTMLAttributes3, ReactNode as ReactNode3, RefObject as RefObject4 } from "react";
146
108
  import { JSX as JSX_1kxb2 } from "react";
147
- import { ForwardRefExoticComponent as ForwardRefExoticComponent_tcubfn3 } from "react";
148
- import { RefAttributes as RefAttributes_miuf563 } from "react";
149
- type MenuPositionerProps = ComponentProps<typeof Menu2.Positioner>;
150
- type MenuPopupProps = ComponentProps<typeof Menu2.Popup>;
151
- type MenuPortalProps = ComponentProps<typeof Menu2.Portal>;
152
- type Element_12xgc2 = JSX_1kxb2["Element"];
153
- interface DropdownGroupProps extends HTMLAttributes3<HTMLDivElement> {
154
- /** Rows, with an optional `Dropdown.Label` first: it becomes the group's accessible name. */
155
- children?: ReactNode3;
156
- /** Extra classes. */
157
- className?: string;
158
- }
159
- /** A run of related rows (role="group"), named by the `Dropdown.Label` inside it. */
160
- declare const DropdownGroup: ForwardRefExoticComponent_tcubfn3<DropdownGroupProps & RefAttributes_miuf563<HTMLDivElement>>;
161
- interface DropdownCheckboxItemProps extends Omit<HTMLAttributes3<HTMLDivElement>, "onSelect" | "defaultChecked"> {
162
- /** Whether the row is checked. Pair with `onCheckedChange`. */
163
- checked?: boolean;
164
- /** Initial checked state, for an uncontrolled row. Defaults to `false`. */
165
- defaultChecked?: boolean;
166
- /** Called with the new state when the row is toggled. */
167
- onCheckedChange?: (checked: boolean) => void;
168
- /** Optional leading icon. */
169
- icon?: IconComponent;
170
- /** The row text. Omit it to pass the row's content as `children`. */
171
- label?: string;
172
- /** Typeahead text for a row whose content is more than a string (an icon beside markup): the key a press matches while the menu is open. Defaults to `label`, else the row's text `children`. */
173
- textValue?: string;
174
- /** The row's content when there is no `label`. */
175
- children?: ReactNode3;
176
- /** Position among the panel's rows. Omitted, the row takes its place in document order. */
177
- index?: number;
178
- /** Called when the row is picked, before it toggles. With `closeOnClick`, `event.preventDefault()` keeps the menu open. */
179
- onSelect?: (event: Event) => void;
180
- /** Dims the row; the pointer and the keyboard skip it. Defaults to `false`. */
181
- disabled?: boolean;
182
- /** Whether toggling closes the menu. Defaults to `false`. */
183
- closeOnClick?: boolean;
184
- /** Indents the row to the label column of rows with an icon. Defaults to `false`. */
185
- inset?: boolean;
186
- /** A keyboard shortcut shown muted at the row's end. */
187
- shortcut?: ReactNode3;
188
- /** Extra classes for the row. */
189
- className?: string;
190
- }
191
- /** A row that toggles on and off by itself (role="menuitemcheckbox"), keyed on its own state rather than an index. */
192
- declare const DropdownCheckboxItem: ForwardRefExoticComponent_tcubfn3<DropdownCheckboxItemProps & RefAttributes_miuf563<HTMLDivElement>>;
193
- interface DropdownRadioGroupProps extends Omit<HTMLAttributes3<HTMLDivElement>, "defaultValue" | "onChange"> {
194
- /** The picked row's value. Pair with `onValueChange`. */
195
- value?: string;
196
- /** Initial value, for an uncontrolled group. */
197
- defaultValue?: string;
198
- /** Called with the picked row's value. */
199
- onValueChange?: (value: string) => void;
200
- /** `Dropdown.RadioItem` rows, plus an optional `Dropdown.Label`. */
201
- children?: ReactNode3;
202
- /** Extra classes. */
203
- className?: string;
204
- }
205
- /** One choice among its `Dropdown.RadioItem` rows, keyed on their `value`. */
206
- declare const DropdownRadioGroup: ForwardRefExoticComponent_tcubfn3<DropdownRadioGroupProps & RefAttributes_miuf563<HTMLDivElement>>;
207
- interface DropdownRadioItemProps extends Omit<HTMLAttributes3<HTMLDivElement>, "onSelect"> {
208
- /** The value this row stands for in its `Dropdown.RadioGroup`. */
209
- value: string;
210
- /** Optional leading icon. */
211
- icon?: IconComponent;
212
- /** The row text. Omit it to pass the row's content as `children`. */
213
- label?: string;
214
- /** Typeahead text for a row whose content is more than a string (an icon beside markup): the key a press matches while the menu is open. Defaults to `label`, else the row's text `children`. */
215
- textValue?: string;
216
- /** The row's content when there is no `label`. */
217
- children?: ReactNode3;
218
- /** Position among the panel's rows. Omitted, the row takes its place in document order. */
219
- index?: number;
220
- /** Called when the row is picked, before the group's value changes. Call `event.preventDefault()` to keep the menu open. */
221
- onSelect?: (event: Event) => void;
222
- /** Dims the row; the pointer and the keyboard skip it. Defaults to `false`. */
223
- disabled?: boolean;
224
- /** Whether picking the row closes the menu. Defaults to `true`. */
225
- closeOnClick?: boolean;
226
- /** Indents the row to the label column of rows with an icon. Defaults to `false`. */
227
- inset?: boolean;
228
- /** A keyboard shortcut shown muted at the row's end. */
229
- shortcut?: ReactNode3;
230
- /** Extra classes for the row. */
231
- className?: string;
232
- }
233
- /** A row of a `Dropdown.RadioGroup` (role="menuitemradio"), checked while the group's value is its `value`. */
234
- declare const DropdownRadioItem: ForwardRefExoticComponent_tcubfn3<DropdownRadioItemProps & RefAttributes_miuf563<HTMLDivElement>>;
235
- interface DropdownSubProps {
236
- /** `Dropdown.SubTrigger` and `Dropdown.SubContent`. */
237
- children: ReactNode3;
238
- /** Controlled open state. Pair with `onOpenChange`. */
239
- open?: boolean;
240
- /** Initial open state, for an uncontrolled submenu. Defaults to `false`. */
241
- defaultOpen?: boolean;
242
- /** Called when the submenu opens or closes, with Base UI's event details: `reason` and `cancel()`, which keeps the submenu as it is. */
243
- onOpenChange?: (open: boolean, details: MenuRootChangeEventDetails) => void;
244
- /** Disables the submenu. Defaults to `false`. */
245
- disabled?: boolean;
246
- }
247
- /** A submenu: its trigger row and its panel. Lives inside `Dropdown.Content` (or another submenu). */
248
- declare function DropdownSub({ children, open, defaultOpen, onOpenChange, disabled }: DropdownSubProps): Element_12xgc2;
249
- interface DropdownSubTriggerProps extends Omit<HTMLAttributes3<HTMLDivElement>, "onSelect"> {
250
- /** Optional leading icon. */
251
- icon?: IconComponent;
252
- /** The row text. Omit it to pass the row's content as `children`. */
253
- label?: string;
254
- /** Typeahead text for a row whose content is more than a string (an icon beside markup): the key a press matches while the menu is open. Defaults to `label`, else the row's text `children`. */
255
- textValue?: string;
256
- /** The row's content when there is no `label`. */
257
- children?: ReactNode3;
258
- /** Position among the panel's rows. Omitted, the row takes its place in document order. */
259
- index?: number;
260
- /** Dims the row; the pointer and the keyboard skip it. Defaults to `false`. */
261
- disabled?: boolean;
262
- /** Indents the row to the label column of rows with an icon. Defaults to `false`. */
263
- inset?: boolean;
264
- /** Open the submenu when the pointer rests on the row. Defaults to `true`. */
265
- openOnHover?: boolean;
266
- /** How long the pointer rests before it opens, in ms. Defaults to `100`. */
267
- delay?: number;
268
- /** How long before a hover-opened submenu closes once the pointer leaves, in ms. Defaults to `0`. */
269
- closeDelay?: number;
270
- /** Extra classes for the row. */
271
- className?: string;
272
- }
273
- /**
274
- * The row that opens a submenu, with a trailing chevron: ArrowRight, a press
275
- * or a resting pointer opens it, ArrowLeft closes it. Its row stays lit while
276
- * the submenu is open.
277
- */
278
- declare const DropdownSubTrigger: ForwardRefExoticComponent_tcubfn3<DropdownSubTriggerProps & RefAttributes_miuf563<HTMLDivElement>>;
279
- interface DropdownSubContentProps extends Omit<HTMLAttributes3<HTMLDivElement>, "className"> {
280
- /** Rows: `Dropdown.Item`, `Dropdown.CheckboxItem`, `Dropdown.RadioGroup`, `Dropdown.Group`, `Dropdown.Label`, `Dropdown.Separator`, another `Dropdown.Sub`. */
281
- children: ReactNode3;
282
- /** Extra classes for the submenu surface — it is 14rem wide by default. */
283
- className?: string;
284
- /** Classes for the portalled positioner element: a z utility here lifts the submenu above other fixed layers (the positioner is `z-50`). */
285
- positionerClassName?: string;
286
- /** Side of the trigger row the submenu prefers. Defaults to `"inline-end"`. */
287
- side?: MenuPositionerProps["side"];
288
- /** Alignment against the trigger row. Defaults to `"start"`. */
289
- align?: MenuPositionerProps["align"];
290
- /** Gap to the parent menu, in px: the goo neck's length. Defaults to `8`. */
291
- sideOffset?: number;
292
- /** Shift along the trigger row, in px; `-4` lines the first row up with the trigger. Defaults to `-4`. */
293
- alignOffset?: number;
294
- /** Space to keep between the submenu and the edge of the collision boundary, in px (a number, or per side). Defaults to `5`. */
295
- collisionPadding?: MenuPositionerProps["collisionPadding"];
296
- /** The element the portalled submenu mounts into. Defaults to `document.body`. */
297
- container?: MenuPortalProps["container"];
298
- /** Where focus goes once the submenu has closed: `false` leaves it, a ref moves it there, a function picks by how it closed. Defaults to `undefined`: Base UI's own return to the trigger row. */
299
- finalFocus?: MenuPopupProps["finalFocus"];
300
- /** An element to focus once the submenu has opened. The ref may be a fresh object each render: it is read when the submenu opens. Defaults to `undefined`: keyboard opens focus the first row, as Base UI does. */
301
- initialFocus?: RefObject4<HTMLElement | null>;
302
- /** Key handler on the popup, in the capture phase, ahead of the panel's own. `preventDefault` is harmless: navigation and typeahead still run. `stopPropagation` stops Base UI's key handling; the keyboard ring still runs. Defaults to `undefined`. */
303
- onKeyDownCapture?: HTMLAttributes3<HTMLDivElement>["onKeyDownCapture"];
304
- /** Where the submenu grows from (see Morph): its trigger row, its own center, a viewport edge, or a ref to any element. Defaults to `'trigger'`. */
305
- from?: "trigger" | "center" | "top" | "right" | "bottom" | "left" | RefObject4<HTMLElement | null>;
306
- /** How it grows (see Morph): with the liquid goo neck, a plain morph, a slide or a fade. Defaults to `'goo'`. */
307
- effect?: "goo" | "morph" | "slide" | "fade";
308
- /** Spring tier of a plain morph, slide or fade; goo runs on its own `spring.goo`. Defaults to `'moderate'`. */
309
- tier?: "moderate" | "slow";
310
- /** Keep the rows mounted (hidden) while the submenu is closed, so rows that run their own state keep it across opens. Defaults to `false`. */
311
- keepMounted?: boolean;
312
- }
313
- /** The submenu's panel: the same rows and systems as `Dropdown.Content`, lifted 2 levels above the menu it came from. */
314
- declare const DropdownSubContent: ForwardRefExoticComponent_tcubfn3<DropdownSubContentProps & RefAttributes_miuf563<HTMLDivElement>>;
315
- import { JSX as JSX_1kxb3 } from "react";
316
- interface DropdownProps extends HTMLAttributes4<HTMLDivElement> {
109
+ interface DropdownProps extends HTMLAttributes3<HTMLDivElement> {
317
110
  /** `Dropdown.Item` rows, plus `Dropdown.Label` and `Dropdown.Separator`. */
318
- children: ReactNode4;
111
+ children: ReactNode3;
319
112
  /** The checked row: drives the animated selected background and the rows' radio semantics. */
320
113
  checkedIndex?: number;
321
114
  /** Uncontrolled twin of `checkedIndex`: the panel owns the selection, so rows need no `checked` or `onSelect` of their own. */
@@ -342,14 +135,6 @@ type DropdownComponent = ForwardRefExoticComponent<DropdownProps & RefAttributes
342
135
  Separator: typeof DropdownSeparator;
343
136
  Search: typeof DropdownSearch;
344
137
  Empty: typeof DropdownEmpty;
345
- Group: typeof DropdownGroup;
346
- Shortcut: typeof DropdownShortcut;
347
- CheckboxItem: typeof DropdownCheckboxItem;
348
- RadioGroup: typeof DropdownRadioGroup;
349
- RadioItem: typeof DropdownRadioItem;
350
- Sub: typeof DropdownSub;
351
- SubTrigger: typeof DropdownSubTrigger;
352
- SubContent: typeof DropdownSubContent;
353
138
  };
354
139
  /**
355
140
  * A menu in two forms: an inline panel that sits in the page, or a popup on
@@ -368,70 +153,39 @@ type DropdownComponent = ForwardRefExoticComponent<DropdownProps & RefAttributes
368
153
  * the query too, keeping only the rows whose `label` matches and showing
369
154
  * `Dropdown.Empty` when none do.
370
155
  *
371
- * Rows also come shadcn-style: children instead of a `label`, no `index` (a
372
- * row takes its place in document order, so the hover, the keyboard ring and
373
- * the selection backgrounds still find it, inside groups and behind
374
- * conditions alike), `inset` to line up with rows that have an icon and a
375
- * trailing `shortcut`. `Dropdown.CheckboxItem` and `Dropdown.RadioGroup` /
376
- * `Dropdown.RadioItem` select by their own state and value instead of by
377
- * index, their checked rows melting into one background like a multiple
378
- * selection. A `Dropdown.Sub` opens a submenu from its trigger row (ArrowRight,
379
- * a press, or a resting pointer) that grows out of that row and lifts above
380
- * the menu, with a highlight and a keyboard ring of its own. Every popup
381
- * lifts 2 surface levels off whatever it opens over, a Dialog included.
382
- *
383
- * Statics:
384
- * - `Dropdown.Menu` — the popup root: `open`, `defaultOpen`, `onOpenChange`, `disabled`, `size`.
385
- * - `Dropdown.Trigger` — the trigger: `render` or `asChild`.
386
- * - `Dropdown.Content` — the popup panel: `side`, `align`, `sideOffset`, the
387
- * index selection, and the morph options `from`, `effect`, `hideSource`, `tier`.
388
- * - `Dropdown.Item` — a row: `label` or `children`, `index`, `icon`, `inset`,
389
- * `shortcut`, `checked`, `onSelect`, `closeOnClick`, `disabled`.
390
- * - `Dropdown.CheckboxItem` — a row toggling itself: `checked`, `defaultChecked`, `onCheckedChange`.
391
- * - `Dropdown.RadioGroup` / `Dropdown.RadioItem` — one choice by value: `value`,
392
- * `defaultValue`, `onValueChange` on the group, `value` on each row.
393
- * - `Dropdown.Group` / `Dropdown.Label` — a named run of rows and its caption (`inset`).
394
- * - `Dropdown.Separator` — a rule between runs.
395
- * - `Dropdown.Shortcut` — a muted caption at a row's end.
396
- * - `Dropdown.Sub` / `Dropdown.SubTrigger` / `Dropdown.SubContent` — a submenu:
397
- * its state, its trigger row (`openOnHover`, `delay`), its panel (`side`,
398
- * `align`, `sideOffset`, `alignOffset`, `from`, `effect`, `tier`).
399
- * - `Dropdown.Search` / `Dropdown.Empty` — a filter field and its no-match row.
156
+ * Statics: Dropdown.Menu (the popup root: open, defaultOpen, onOpenChange,
157
+ * disabled), Dropdown.Trigger (render), Dropdown.Content (the popup panel:
158
+ * side, align, sideOffset and the morph options from, effect, hideSource, tier),
159
+ * Dropdown.Item (a row: index, label, icon, checked, onSelect, disabled),
160
+ * Dropdown.Label, Dropdown.Separator, Dropdown.Search and Dropdown.Empty.
400
161
  *
401
162
  * @example {@include ./examples.mdx}
402
163
  */
403
164
  declare const Dropdown: DropdownComponent;
404
165
  interface DropdownMenuProps {
405
166
  /** `Dropdown.Trigger` and `Dropdown.Content`. */
406
- children: ReactNode4;
167
+ children: ReactNode3;
407
168
  /** Controlled open state. Pair with `onOpenChange`. */
408
169
  open?: boolean;
409
170
  /** Initial open state — uncontrolled. Defaults to `false`. */
410
171
  defaultOpen?: boolean;
411
- /** Called when the menu opens or closes, with Base UI's event details: `reason` (why: `'escape-key'`, `'outside-press'`, `'focus-out'`, `'item-press'`, `'trigger-press'`…), `event`, and `cancel()`, which keeps the menu as it is. A callback that takes only `open` keeps working. */
412
- onOpenChange?: (open: boolean, details: MenuRootChangeEventDetails2) => void;
172
+ /** Called when the menu opens or closes. */
173
+ onOpenChange?: (open: boolean) => void;
413
174
  /** Disables the menu. Defaults to `false`. */
414
175
  disabled?: boolean;
415
- /** Locks the page scroll while the menu is open and keeps the pointer off everything outside it. Non-modal, the page keeps scrolling and the popup follows its trigger. Defaults to `false`. */
416
- modal?: boolean;
417
176
  /** Pins trigger-side content and the portalled popup rows to one step of the size ladder (default 36px, compact 28px — see Sizes). Omitted, they follow the surrounding SizeProvider. */
418
177
  size?: SizeVariant;
419
178
  }
420
- type Element_12xgc3 = JSX_1kxb3["Element"];
421
- declare function DropdownMenu({ children, open: openProp, defaultOpen, onOpenChange, disabled, modal, size }: DropdownMenuProps): Element_12xgc3;
422
- type DropdownTriggerProps = MenuTriggerProps & {
423
- /** Compose onto the single child instead of `render`. Defaults to `false`. */
424
- asChild?: boolean;
425
- };
426
- declare const DropdownTrigger: ForwardRefExoticComponent<Omit<DropdownTriggerProps, "ref"> & RefAttributes<HTMLButtonElement>>;
427
- type MenuPositionerProps2 = ComponentProps2<typeof BaseMenu.Positioner>;
428
- interface DropdownContentProps extends Omit<HTMLAttributes4<HTMLDivElement>, "className"> {
179
+ type Element_12xgc2 = JSX_1kxb2["Element"];
180
+ declare function DropdownMenu({ children, open: openProp, defaultOpen, onOpenChange, disabled, size }: DropdownMenuProps): Element_12xgc2;
181
+ type DropdownTriggerProps = MenuTriggerProps;
182
+ declare const DropdownTrigger: Menu.Trigger;
183
+ type MenuPositionerProps = ComponentProps<typeof Menu.Positioner>;
184
+ interface DropdownContentProps {
429
185
  /** `Dropdown.Item` rows, plus `Dropdown.Label`, `Dropdown.Separator`, `Dropdown.Search`, `Dropdown.Empty`. */
430
- children: ReactNode4;
186
+ children: ReactNode3;
431
187
  /** Extra classes for the popup surface. */
432
188
  className?: string;
433
- /** Classes for the portalled positioner element: a z utility here lifts the menu above other fixed layers (the positioner is `z-50`), e.g. `z-[60]`. */
434
- positionerClassName?: string;
435
189
  /** Index of the checked item. Drives the animated selected background and
436
190
  * the radio-group value announced to assistive tech. */
437
191
  checkedIndex?: number;
@@ -448,45 +202,21 @@ interface DropdownContentProps extends Omit<HTMLAttributes4<HTMLDivElement>, "cl
448
202
  /** Called with every checked row after a toggle. */
449
203
  onCheckedIndicesChange?: (indices: number[]) => void;
450
204
  /** Side of the trigger the popup prefers. Defaults to `"bottom"`. */
451
- side?: MenuPositionerProps2["side"];
205
+ side?: MenuPositionerProps["side"];
452
206
  /** Alignment against the trigger. Defaults to `"start"`. */
453
- align?: MenuPositionerProps2["align"];
207
+ align?: MenuPositionerProps["align"];
454
208
  /** Gap to the trigger, in px. Ignored when the menu opens in place over its trigger (`effect="morph"` with `hideSource`). Defaults to `6`. */
455
209
  sideOffset?: number;
456
- /** Shift along the trigger's edge, in px. Defaults to `0`. */
457
- alignOffset?: MenuPositionerProps2["alignOffset"];
458
- /** Space to keep between the menu and the edge of the collision boundary, in px (a number, or per side). Defaults to `5`. */
459
- collisionPadding?: MenuPositionerProps2["collisionPadding"];
460
- /** The element or rectangle the menu stays inside when it flips and shifts. Defaults to `'clipping-ancestors'`. */
461
- collisionBoundary?: MenuPositionerProps2["collisionBoundary"];
462
- /** The element the portalled menu mounts into, e.g. a Dialog's popup so it stays inside its focus trap. Defaults to `document.body`. */
463
- container?: MenuPortalProps["container"];
464
- /** Where focus goes once the menu has closed: `false` leaves it, a ref moves it there (a text field after a pick), a function picks by how it closed. Defaults to `undefined`: Base UI's own return to the trigger. */
465
- finalFocus?: MenuPopupProps["finalFocus"];
466
- /** An element to focus once the menu has opened, in place of the first row, or `false` to drop modo's own first-row focus. Base UI 1.4.1's Menu.Popup has no such option, so this is modo's: it acts a frame after the open. `false` does not silence Base UI's own initial focus, which still lands on the first row after a keyboard open and on the popup after a pointer open. The ref may be a fresh object each render: it is read when the menu opens, and only a change to or from `false` re-runs it. Defaults to `undefined`: the first row (the search field when there is one). */
467
- initialFocus?: boolean | RefObject5<HTMLElement | null>;
468
- /** Key handler on the popup, in the capture phase, ahead of the panel's own. `preventDefault` is harmless: navigation and typeahead still run. `stopPropagation` stops Base UI's key handling and the panel's arrow navigation; the keyboard ring and typing redirected into `Dropdown.Search` still run. Defaults to `undefined`. */
469
- onKeyDownCapture?: HTMLAttributes4<HTMLDivElement>["onKeyDownCapture"];
470
210
  /** Where the menu grows from (see Morph): the trigger, the pointer, its own center, a viewport edge, or a ref to any element. Defaults to `'trigger'`. */
471
- from?: "trigger" | "pointer" | "center" | "top" | "right" | "bottom" | "left" | RefObject5<HTMLElement | null>;
211
+ from?: "trigger" | "pointer" | "center" | "top" | "right" | "bottom" | "left" | RefObject2<HTMLElement | null>;
472
212
  /** How it grows (see Morph): with the liquid goo neck, a plain morph, a slide or a fade. Defaults to `'goo'`. */
473
213
  effect?: "goo" | "morph" | "slide" | "fade";
474
214
  /** Hide the trigger while open, so it reads as turning into the menu. Defaults to `false`. */
475
215
  hideSource?: boolean;
476
216
  /** Spring tier of a plain morph, slide or fade; goo runs on its own `spring.goo`. Defaults to `'moderate'`. */
477
217
  tier?: "moderate" | "slow";
478
- /** Keep the rows mounted (hidden) while the menu is closed, so rows that run their own state — `Dropdown.CheckboxItem defaultChecked`, `Dropdown.RadioGroup defaultValue`, an uncontrolled `Dropdown.Sub` — keep it across opens. Defaults to `false`. */
479
- keepMounted?: boolean;
480
218
  }
481
219
  declare const DropdownContent: ForwardRefExoticComponent<DropdownContentProps & RefAttributes<HTMLDivElement>>;
482
- interface DropdownLabelProps extends HTMLAttributes4<HTMLDivElement> {
483
- /** The caption. */
484
- children?: ReactNode4;
485
- /** Indents the caption to the label column of rows with an icon. Defaults to `false`. */
486
- inset?: boolean;
487
- /** Extra classes. */
488
- className?: string;
489
- }
490
- declare const DropdownLabel: ForwardRefExoticComponent<DropdownLabelProps & RefAttributes<HTMLDivElement>>;
491
- declare const DropdownSeparator: ForwardRefExoticComponent<HTMLAttributes4<HTMLDivElement> & RefAttributes<HTMLDivElement>>;
492
- export { Dropdown, DropdownCheckboxItem, DropdownCheckboxItemProps, DropdownContent, DropdownContentProps, DropdownContextValue, DropdownEmpty, DropdownGroup, DropdownGroupProps, DropdownLabel, DropdownLabelProps, DropdownMenu, DropdownMenuProps, DropdownProps, DropdownRadioGroup, DropdownRadioGroupProps, DropdownRadioItem, DropdownRadioItemProps, DropdownSearch, DropdownSearchProps, DropdownSeparator, DropdownShortcut, DropdownShortcutProps, DropdownSub, DropdownSubContent, DropdownSubContentProps, DropdownSubProps, DropdownSubTrigger, DropdownSubTriggerProps, DropdownTrigger, DropdownTriggerProps, MenuItem, MenuItemProps, MenuItemRenderOptions, Dropdown as default, useDropdown, useDropdownMaybe };
220
+ declare const DropdownLabel: ForwardRefExoticComponent<HTMLAttributes3<HTMLDivElement> & RefAttributes<HTMLDivElement>>;
221
+ declare const DropdownSeparator: ForwardRefExoticComponent<HTMLAttributes3<HTMLDivElement> & RefAttributes<HTMLDivElement>>;
222
+ export { Dropdown, DropdownContent, DropdownContentProps, DropdownContextValue, DropdownEmpty, DropdownLabel, DropdownMenu, DropdownMenuProps, DropdownProps, DropdownSearch, DropdownSearchProps, DropdownSeparator, DropdownTrigger, DropdownTriggerProps, MenuItem, MenuItemRenderOptions, Dropdown as default, useDropdown, useDropdownMaybe };
@@ -3,15 +3,7 @@ import {
3
3
  DropdownEmpty2,
4
4
  useDropdown2,
5
5
  useDropdownMaybe2,
6
- DropdownShortcut2,
7
6
  MenuItem2,
8
- DropdownGroup2,
9
- DropdownCheckboxItem2,
10
- DropdownRadioGroup2,
11
- DropdownRadioItem2,
12
- DropdownSub2,
13
- DropdownSubTrigger2,
14
- DropdownSubContent2,
15
7
  Dropdown2,
16
8
  DropdownMenu2,
17
9
  DropdownTrigger2,
@@ -19,50 +11,31 @@ import {
19
11
  DropdownLabel2,
20
12
  DropdownSeparator2,
21
13
  dropdown_default
22
- } from "../../../shared/components-2qbqqpgq.js";
23
- import"../../../shared/components-kz5q11pp.js";
24
- import"../../../shared/components-tz4gaf1v.js";
25
- import"../../../shared/components-wbbckbw8.js";
26
- import"../../../shared/components-9as3rf68.js";
27
- import"../../../shared/components-krtx3m5b.js";
28
- import"../../../shared/components-h6p86be3.js";
29
- import"../../../shared/components-vf45j12c.js";
30
- import"../../../shared/components-mrbaxt8q.js";
31
- import"../../../shared/components-c7rwx0ap.js";
32
- import"../../../shared/components-b1e239g3.js";
33
- import"../../../shared/components-dhgk6mbt.js";
34
- import"../../../shared/components-jqpefjsn.js";
35
- import"../../../shared/components-dc5q749x.js";
36
- import"../../../shared/components-pwayrkw9.js";
37
- import"../../../shared/components-yhgq0qxx.js";
38
- import"../../../shared/components-m06yq8wk.js";
39
- import"../../../shared/components-dcc02hs2.js";
40
- import"../../../shared/components-tz1fv35x.js";
41
- import"../../../shared/components-ctqmge8t.js";
42
- import"../../../shared/components-drxrtnp2.js";
43
- import"../../../shared/components-de99ykt7.js";
44
- import"../../../shared/components-3ey0hzpb.js";
45
- import"../../../shared/components-h83az0bz.js";
46
- import"../../../shared/components-34txk9rj.js";
47
- import"../../../shared/components-71nbt03m.js";
48
- import"../../../shared/components-gx4h5rbb.js";
49
- import"../../../shared/components-jcnjay5g.js";
14
+ } from "../../../shared/components-ypp01w3p.js";
15
+ import"../../../shared/components-5xc2j8jz.js";
16
+ import"../../../shared/components-zrkzcayz.js";
17
+ import"../../../shared/components-0q0sqfh4.js";
18
+ import"../../../shared/components-kvr7f9hy.js";
19
+ import"../../../shared/components-chacnk61.js";
20
+ import"../../../shared/components-59efxjd9.js";
21
+ import"../../../shared/components-hqeq3w9q.js";
22
+ import"../../../shared/components-jjw69c4c.js";
23
+ import"../../../shared/components-n7mjr357.js";
24
+ import"../../../shared/components-men63rwj.js";
25
+ import"../../../shared/components-0sn7ypjw.js";
26
+ import"../../../shared/components-b0eac83j.js";
27
+ import"../../../shared/components-cv16mryv.js";
28
+ import"../../../shared/components-vc7vq5nz.js";
29
+ import"../../../shared/components-zx6b6yby.js";
30
+ import"../../../shared/components-ezxhrmer.js";
50
31
  export {
51
32
  Dropdown2 as Dropdown,
52
- DropdownCheckboxItem2 as DropdownCheckboxItem,
53
33
  DropdownContent2 as DropdownContent,
54
34
  DropdownEmpty2 as DropdownEmpty,
55
- DropdownGroup2 as DropdownGroup,
56
35
  DropdownLabel2 as DropdownLabel,
57
36
  DropdownMenu2 as DropdownMenu,
58
- DropdownRadioGroup2 as DropdownRadioGroup,
59
- DropdownRadioItem2 as DropdownRadioItem,
60
37
  DropdownSearch2 as DropdownSearch,
61
38
  DropdownSeparator2 as DropdownSeparator,
62
- DropdownShortcut2 as DropdownShortcut,
63
- DropdownSub2 as DropdownSub,
64
- DropdownSubContent2 as DropdownSubContent,
65
- DropdownSubTrigger2 as DropdownSubTrigger,
66
39
  DropdownTrigger2 as DropdownTrigger,
67
40
  MenuItem2 as MenuItem,
68
41
  dropdown_default as default,
@@ -1,15 +1,12 @@
1
- import { Popover as PopoverPrimitive } from "@base-ui/react/popover";
2
- import { ComponentProps, HTMLAttributes, ReactNode as ReactNode2, RefObject } from "react";
1
+ import { HTMLAttributes, ReactNode as ReactNode2, RefObject } from "react";
3
2
  import { ButtonHTMLAttributes, ReactElement, ReactNode } from "react";
4
3
  interface SlotProps extends ButtonHTMLAttributes<HTMLButtonElement> {
5
- /** The element that becomes the control, e.g. a Button. Children fill it when it has none of its own. */
4
+ /** The element that becomes the control, e.g. a Button. */
6
5
  render?: ReactElement;
7
6
  /** Compose onto the single child instead. Both spellings work in both flavors. Defaults to `false`. */
8
7
  asChild?: boolean;
9
- /** Control content when there is no render element, or the content of a render element that has none of its own. */
8
+ /** Control content when there is no render element. */
10
9
  children?: ReactNode;
11
- /** Whether the render element is a native `<button>`: pass `false` for a `<div>` or a link, so Base UI adds the button role and keyboard handling itself. Parts not built on a Base UI button ignore it. Defaults to `true`. */
12
- nativeButton?: boolean;
13
10
  }
14
11
  import { ForwardRefExoticComponent as ForwardRefExoticComponent_tcubfn } from "react";
15
12
  import { RefAttributes as RefAttributes_miuf56 } from "react";
@@ -24,30 +21,14 @@ interface PopoverTriggerProps extends SlotProps {
24
21
  }
25
22
  declare const PopoverTrigger: ForwardRefExoticComponent_tcubfn<PopoverTriggerProps & RefAttributes_miuf56<HTMLButtonElement>>;
26
23
  declare const PopoverClose: ForwardRefExoticComponent_tcubfn<SlotProps & RefAttributes_miuf56<HTMLButtonElement>>;
27
- type PositionerProps = ComponentProps<typeof PopoverPrimitive.Positioner>;
28
- type PopupProps = ComponentProps<typeof PopoverPrimitive.Popup>;
29
- /** What the panel is positioned against: an element, a ref to one, a virtual element (`{ getBoundingClientRect }`), or a function returning either. */
30
- type PopoverAnchor = PositionerProps["anchor"];
31
24
  interface PopoverContentProps extends HTMLAttributes<HTMLDivElement> {
32
- /** Side of the anchor the panel opens on; it flips when there is no room. Defaults to `'bottom'`. */
25
+ /** Side of the trigger the panel opens on; it flips when there is no room. Defaults to `'bottom'`. */
33
26
  side?: "top" | "right" | "bottom" | "left";
34
27
  /** Alignment along that side. Defaults to `'center'`, or `'start'` when the panel opens in place (`effect="morph"` with `hideSource`). */
35
28
  align?: "start" | "center" | "end";
36
- /** Gap between anchor and panel in px — the length of the goo neck. Ignored when the panel opens in place over its trigger (`effect="morph"` with `hideSource`). Defaults to `12`. */
29
+ /** Gap between trigger and panel in px — the length of the goo neck. Ignored when the panel opens in place over its trigger (`effect="morph"` with `hideSource`). Defaults to `12`. */
37
30
  sideOffset?: number;
38
- /** Shift along the aligned edge in px, after `align` (a number, or Base UI's function of side, align and sizes). Defaults to `0`. */
39
- alignOffset?: PositionerProps["alignOffset"];
40
- /** What the panel is positioned against instead of the trigger: an element, a ref to one, a virtual element (`{ getBoundingClientRect }`) or a function returning either. An element anchor is also where the panel grows from, and sets `--anchor-width` / `--anchor-height` for sizing the panel to it. Defaults to the trigger. */
41
- anchor?: PopoverAnchor;
42
- /** Space kept between the panel and the edge of its collision boundary, in px or per side. Defaults to `5`. */
43
- collisionPadding?: PositionerProps["collisionPadding"];
44
- /** The area the panel must stay inside: an element, several, or a rect. Defaults to `'clipping-ancestors'`. */
45
- collisionBoundary?: PositionerProps["collisionBoundary"];
46
- /** Where focus goes when the panel opens: a ref, `false` to leave it, `true` for the default, or a function of how it opened (`'mouse'`, `'touch'`, `'pen'`, `'keyboard'`). Defaults to the panel itself. */
47
- initialFocus?: PopupProps["initialFocus"];
48
- /** Where focus goes when the panel closes: a ref, `false` to leave it, `true` for the default, or a function of how it closed. Defaults to the trigger. */
49
- finalFocus?: PopupProps["finalFocus"];
50
- /** Where the panel grows from (see Morph): the pressed trigger, the press point, its own center, a viewport edge, or a ref to any element. Defaults to the `anchor` when it is an element, otherwise `'trigger'`. */
31
+ /** Where the panel grows from (see Morph): the pressed trigger, the press point, its own center, a viewport edge, or a ref to any element. Defaults to `'trigger'`. */
51
32
  from?: "trigger" | "pointer" | "center" | "top" | "right" | "bottom" | "left" | RefObject<HTMLElement | null>;
52
33
  /** How it grows (see Morph): with the liquid goo neck, a plain morph, a slide or a fade. Defaults to `'goo'`. */
53
34
  effect?: "goo" | "morph" | "slide" | "fade";
@@ -65,15 +46,13 @@ interface PopoverContentProps extends HTMLAttributes<HTMLDivElement> {
65
46
  declare const PopoverContent: ForwardRefExoticComponent_tcubfn<PopoverContentProps & RefAttributes_miuf56<HTMLDivElement>>;
66
47
  declare const PopoverTitle: ForwardRefExoticComponent_tcubfn<HTMLAttributes<HTMLHeadingElement> & RefAttributes_miuf56<HTMLHeadingElement>>;
67
48
  declare const PopoverDescription: ForwardRefExoticComponent_tcubfn<HTMLAttributes<HTMLParagraphElement> & RefAttributes_miuf56<HTMLParagraphElement>>;
68
- /** What `onOpenChange` receives besides the open state: Base UI's Popover change details. */
69
- type PopoverOpenChangeDetails = PopoverPrimitive.Root.ChangeEventDetails;
70
49
  interface PopoverProps {
71
50
  /** Controlled open state. Pair with `onOpenChange`. */
72
51
  open?: boolean;
73
52
  /** Initial open state, for an uncontrolled popover. Defaults to `false`. */
74
53
  defaultOpen?: boolean;
75
- /** Called when the popover opens or closes, with Base UI's change details: `reason` (`'escape-key'`, `'outside-press'`, `'trigger-press'`, …), the `event`, and `cancel()` to keep it as it is. */
76
- onOpenChange?: (open: boolean, details: PopoverOpenChangeDetails) => void;
54
+ /** Called when the popover opens or closes. */
55
+ onOpenChange?: (open: boolean) => void;
77
56
  /** Trap focus and block page interaction while open. Defaults to `false`. */
78
57
  modal?: boolean;
79
58
  /** The trigger and the panel — `Popover.Trigger` plus a `Popover.Content`. */
@@ -91,18 +70,13 @@ type Element_12xgc = JSX_1kxb["Element"];
91
70
  * off its substrate and re-provides that level. Built on Base UI's Popover:
92
71
  * it opens on press, or on hover too with `openOnHover`; it flips to the
93
72
  * other side when there is no room; Escape and an outside press close it.
94
- * `onOpenChange` hears why (`details.reason`) and can `details.cancel()` it.
95
73
  *
96
74
  * Statics:
97
75
  * - `Popover.Trigger` — the control that opens it: `render={<Button/>}` or
98
- * `asChild`; `openOnHover`, `delay`, `closeDelay`. Children fill a render
99
- * element that has none of its own (`render={<span/>}` + children), and
100
- * `nativeButton={false}` tells Base UI it isn't a `<button>`.
76
+ * `asChild`; `openOnHover`, `delay`, `closeDelay`.
101
77
  * - `Popover.Content` — the panel: `side`, `align` (the trigger's `start`,
102
- * `center` or `end`), `sideOffset`, `alignOffset`, `anchor` (position it
103
- * against another element than the trigger, which it then grows from),
104
- * `collisionPadding`, `collisionBoundary`, `initialFocus`, `finalFocus`
105
- * and the morph options `from`, `effect`, `hideSource`, `tier`.
78
+ * `center` or `end`), `sideOffset` and the morph options `from`,
79
+ * `effect`, `hideSource`, `tier`.
106
80
  * - `Popover.Title` / `Popover.Description` — its labelled heading and
107
81
  * supporting line, wired for screen readers.
108
82
  * - `Popover.Close` — closes it; same `render` / `asChild` shape.
@@ -110,4 +84,4 @@ type Element_12xgc = JSX_1kxb["Element"];
110
84
  * @example {@include ./examples.mdx}
111
85
  */
112
86
  declare function Popover({ open, defaultOpen, onOpenChange, modal, children }: PopoverProps): Element_12xgc;
113
- export { Popover, PopoverClose, PopoverContent, PopoverContentProps, PopoverDescription, PopoverOpenChangeDetails, PopoverProps, PopoverTitle, PopoverTrigger, PopoverTriggerProps, Popover as default };
87
+ export { Popover, PopoverClose, PopoverContent, PopoverContentProps, PopoverDescription, PopoverProps, PopoverTitle, PopoverTrigger, PopoverTriggerProps, Popover as default };