@wordpress/ui 0.12.0 → 0.13.1-next.v.202605131006.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 (521) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/CONTRIBUTING.md +34 -0
  3. package/build/alert-dialog/popup.cjs +92 -22
  4. package/build/alert-dialog/popup.cjs.map +3 -3
  5. package/build/badge/badge.cjs +84 -5
  6. package/build/badge/badge.cjs.map +3 -3
  7. package/build/button/button.cjs +90 -20
  8. package/build/button/button.cjs.map +3 -3
  9. package/build/button/icon.cjs.map +2 -2
  10. package/build/button/index.cjs +1 -0
  11. package/build/button/index.cjs.map +3 -3
  12. package/build/button/types.cjs.map +1 -1
  13. package/build/card/content.cjs +84 -5
  14. package/build/card/content.cjs.map +3 -3
  15. package/build/card/full-bleed.cjs +84 -5
  16. package/build/card/full-bleed.cjs.map +3 -3
  17. package/build/card/header.cjs +84 -5
  18. package/build/card/header.cjs.map +3 -3
  19. package/build/card/root.cjs +86 -10
  20. package/build/card/root.cjs.map +3 -3
  21. package/build/collapsible-card/content.cjs +85 -6
  22. package/build/collapsible-card/content.cjs.map +3 -3
  23. package/build/collapsible-card/header.cjs +131 -52
  24. package/build/collapsible-card/header.cjs.map +3 -3
  25. package/build/dialog/content.cjs +86 -10
  26. package/build/dialog/content.cjs.map +3 -3
  27. package/build/dialog/description.cjs +84 -5
  28. package/build/dialog/description.cjs.map +3 -3
  29. package/build/dialog/footer.cjs +84 -5
  30. package/build/dialog/footer.cjs.map +3 -3
  31. package/build/dialog/header.cjs +84 -5
  32. package/build/dialog/header.cjs.map +3 -3
  33. package/build/dialog/popup.cjs +86 -7
  34. package/build/dialog/popup.cjs.map +3 -3
  35. package/build/dialog/title.cjs +84 -5
  36. package/build/dialog/title.cjs.map +3 -3
  37. package/build/drawer/content.cjs +103 -19
  38. package/build/drawer/content.cjs.map +4 -4
  39. package/build/drawer/footer.cjs +84 -5
  40. package/build/drawer/footer.cjs.map +3 -3
  41. package/build/drawer/header.cjs +84 -5
  42. package/build/drawer/header.cjs.map +3 -3
  43. package/build/drawer/popup.cjs +86 -7
  44. package/build/drawer/popup.cjs.map +3 -3
  45. package/build/drawer/title.cjs +84 -5
  46. package/build/drawer/title.cjs.map +3 -3
  47. package/build/drawer/types.cjs.map +1 -1
  48. package/build/empty-state/actions.cjs +84 -5
  49. package/build/empty-state/actions.cjs.map +3 -3
  50. package/build/empty-state/description.cjs +84 -5
  51. package/build/empty-state/description.cjs.map +3 -3
  52. package/build/empty-state/icon.cjs +84 -5
  53. package/build/empty-state/icon.cjs.map +3 -3
  54. package/build/empty-state/root.cjs +84 -5
  55. package/build/empty-state/root.cjs.map +3 -3
  56. package/build/empty-state/title.cjs +84 -5
  57. package/build/empty-state/title.cjs.map +3 -3
  58. package/build/empty-state/visual.cjs +84 -5
  59. package/build/empty-state/visual.cjs.map +3 -3
  60. package/build/form/index.cjs +3 -1
  61. package/build/form/index.cjs.map +2 -2
  62. package/build/form/primitives/autocomplete/empty.cjs +84 -5
  63. package/build/form/primitives/autocomplete/empty.cjs.map +3 -3
  64. package/build/form/primitives/autocomplete/item.cjs +86 -10
  65. package/build/form/primitives/autocomplete/item.cjs.map +3 -3
  66. package/build/form/primitives/autocomplete/list-body.cjs +84 -5
  67. package/build/form/primitives/autocomplete/list-body.cjs.map +3 -3
  68. package/build/form/primitives/autocomplete/list.cjs +84 -5
  69. package/build/form/primitives/autocomplete/list.cjs.map +3 -3
  70. package/build/form/primitives/autocomplete/popup.cjs +90 -17
  71. package/build/form/primitives/autocomplete/popup.cjs.map +3 -3
  72. package/build/form/primitives/field/description.cjs +86 -10
  73. package/build/form/primitives/field/description.cjs.map +3 -3
  74. package/build/form/primitives/field/details.cjs +84 -5
  75. package/build/form/primitives/field/details.cjs.map +3 -3
  76. package/build/form/primitives/field/label.cjs +84 -5
  77. package/build/form/primitives/field/label.cjs.map +3 -3
  78. package/build/form/primitives/field/root.cjs +84 -5
  79. package/build/form/primitives/field/root.cjs.map +3 -3
  80. package/build/form/primitives/fieldset/description.cjs +86 -10
  81. package/build/form/primitives/fieldset/description.cjs.map +3 -3
  82. package/build/form/primitives/fieldset/details.cjs +84 -5
  83. package/build/form/primitives/fieldset/details.cjs.map +3 -3
  84. package/build/form/primitives/fieldset/legend.cjs +84 -5
  85. package/build/form/primitives/fieldset/legend.cjs.map +3 -3
  86. package/build/form/primitives/fieldset/root.cjs +84 -5
  87. package/build/form/primitives/fieldset/root.cjs.map +3 -3
  88. package/build/form/primitives/input/input.cjs +88 -15
  89. package/build/form/primitives/input/input.cjs.map +3 -3
  90. package/build/form/primitives/input-layout/input-layout.cjs +88 -15
  91. package/build/form/primitives/input-layout/input-layout.cjs.map +3 -3
  92. package/build/form/primitives/input-layout/slot.cjs +84 -5
  93. package/build/form/primitives/input-layout/slot.cjs.map +3 -3
  94. package/build/form/primitives/select/item.cjs +87 -11
  95. package/build/form/primitives/select/item.cjs.map +3 -3
  96. package/build/form/primitives/select/popup.cjs +90 -17
  97. package/build/form/primitives/select/popup.cjs.map +3 -3
  98. package/build/form/primitives/select/root.cjs.map +2 -2
  99. package/build/form/primitives/select/trigger.cjs +98 -16
  100. package/build/form/primitives/select/trigger.cjs.map +3 -3
  101. package/build/form/primitives/select/types.cjs.map +1 -1
  102. package/build/form/primitives/textarea/textarea.cjs +86 -10
  103. package/build/form/primitives/textarea/textarea.cjs.map +3 -3
  104. package/build/form/select-control/context.cjs +37 -0
  105. package/build/form/select-control/context.cjs.map +7 -0
  106. package/build/form/select-control/index.cjs +39 -0
  107. package/build/form/select-control/index.cjs.map +7 -0
  108. package/build/form/select-control/item.cjs +41 -0
  109. package/build/form/select-control/item.cjs.map +7 -0
  110. package/build/form/select-control/select-control.cjs +75 -0
  111. package/build/form/select-control/select-control.cjs.map +7 -0
  112. package/build/form/select-control/types.cjs +19 -0
  113. package/build/form/select-control/types.cjs.map +7 -0
  114. package/build/form/types.cjs.map +1 -1
  115. package/build/icon-button/icon-button.cjs +86 -6
  116. package/build/icon-button/icon-button.cjs.map +3 -3
  117. package/build/icon-button/types.cjs.map +1 -1
  118. package/build/link/link.cjs +90 -20
  119. package/build/link/link.cjs.map +3 -3
  120. package/build/notice/action-button.cjs +84 -5
  121. package/build/notice/action-button.cjs.map +3 -3
  122. package/build/notice/action-link.cjs +84 -5
  123. package/build/notice/action-link.cjs.map +3 -3
  124. package/build/notice/actions.cjs +84 -5
  125. package/build/notice/actions.cjs.map +3 -3
  126. package/build/notice/close-icon.cjs +84 -5
  127. package/build/notice/close-icon.cjs.map +3 -3
  128. package/build/notice/description.cjs +84 -5
  129. package/build/notice/description.cjs.map +3 -3
  130. package/build/notice/root.cjs +86 -10
  131. package/build/notice/root.cjs.map +3 -3
  132. package/build/notice/title.cjs +84 -5
  133. package/build/notice/title.cjs.map +3 -3
  134. package/build/popover/arrow.cjs +84 -5
  135. package/build/popover/arrow.cjs.map +3 -3
  136. package/build/popover/popup.cjs +88 -12
  137. package/build/popover/popup.cjs.map +3 -3
  138. package/build/popover/title.cjs +84 -5
  139. package/build/popover/title.cjs.map +3 -3
  140. package/build/stack/stack.cjs +84 -5
  141. package/build/stack/stack.cjs.map +3 -3
  142. package/build/tabs/list.cjs +84 -5
  143. package/build/tabs/list.cjs.map +3 -3
  144. package/build/tabs/panel.cjs +86 -10
  145. package/build/tabs/panel.cjs.map +3 -3
  146. package/build/tabs/tab.cjs +84 -5
  147. package/build/tabs/tab.cjs.map +3 -3
  148. package/build/text/text.cjs +86 -10
  149. package/build/text/text.cjs.map +3 -3
  150. package/build/tooltip/index.cjs +3 -0
  151. package/build/tooltip/index.cjs.map +2 -2
  152. package/build/tooltip/popup.cjs +111 -40
  153. package/build/tooltip/popup.cjs.map +3 -3
  154. package/build/tooltip/positioner.cjs +159 -0
  155. package/build/tooltip/positioner.cjs.map +7 -0
  156. package/build/tooltip/types.cjs.map +1 -1
  157. package/build/utils/{render-portal-with-children.cjs → render-slot-with-children.cjs} +9 -12
  158. package/build/utils/render-slot-with-children.cjs.map +7 -0
  159. package/build/visually-hidden/visually-hidden.cjs +84 -5
  160. package/build/visually-hidden/visually-hidden.cjs.map +3 -3
  161. package/build-module/alert-dialog/popup.mjs +92 -22
  162. package/build-module/alert-dialog/popup.mjs.map +3 -3
  163. package/build-module/badge/badge.mjs +84 -5
  164. package/build-module/badge/badge.mjs.map +3 -3
  165. package/build-module/button/button.mjs +90 -20
  166. package/build-module/button/button.mjs.map +3 -3
  167. package/build-module/button/icon.mjs.map +2 -2
  168. package/build-module/button/index.mjs +3 -2
  169. package/build-module/button/index.mjs.map +2 -2
  170. package/build-module/card/content.mjs +84 -5
  171. package/build-module/card/content.mjs.map +3 -3
  172. package/build-module/card/full-bleed.mjs +84 -5
  173. package/build-module/card/full-bleed.mjs.map +3 -3
  174. package/build-module/card/header.mjs +84 -5
  175. package/build-module/card/header.mjs.map +3 -3
  176. package/build-module/card/root.mjs +86 -10
  177. package/build-module/card/root.mjs.map +3 -3
  178. package/build-module/collapsible-card/content.mjs +85 -6
  179. package/build-module/collapsible-card/content.mjs.map +3 -3
  180. package/build-module/collapsible-card/header.mjs +131 -52
  181. package/build-module/collapsible-card/header.mjs.map +3 -3
  182. package/build-module/dialog/content.mjs +86 -10
  183. package/build-module/dialog/content.mjs.map +3 -3
  184. package/build-module/dialog/description.mjs +84 -5
  185. package/build-module/dialog/description.mjs.map +3 -3
  186. package/build-module/dialog/footer.mjs +84 -5
  187. package/build-module/dialog/footer.mjs.map +3 -3
  188. package/build-module/dialog/header.mjs +84 -5
  189. package/build-module/dialog/header.mjs.map +3 -3
  190. package/build-module/dialog/popup.mjs +86 -7
  191. package/build-module/dialog/popup.mjs.map +3 -3
  192. package/build-module/dialog/title.mjs +84 -5
  193. package/build-module/dialog/title.mjs.map +3 -3
  194. package/build-module/drawer/content.mjs +103 -19
  195. package/build-module/drawer/content.mjs.map +3 -3
  196. package/build-module/drawer/footer.mjs +84 -5
  197. package/build-module/drawer/footer.mjs.map +3 -3
  198. package/build-module/drawer/header.mjs +84 -5
  199. package/build-module/drawer/header.mjs.map +3 -3
  200. package/build-module/drawer/popup.mjs +86 -7
  201. package/build-module/drawer/popup.mjs.map +3 -3
  202. package/build-module/drawer/title.mjs +84 -5
  203. package/build-module/drawer/title.mjs.map +3 -3
  204. package/build-module/empty-state/actions.mjs +84 -5
  205. package/build-module/empty-state/actions.mjs.map +3 -3
  206. package/build-module/empty-state/description.mjs +84 -5
  207. package/build-module/empty-state/description.mjs.map +3 -3
  208. package/build-module/empty-state/icon.mjs +84 -5
  209. package/build-module/empty-state/icon.mjs.map +3 -3
  210. package/build-module/empty-state/root.mjs +84 -5
  211. package/build-module/empty-state/root.mjs.map +3 -3
  212. package/build-module/empty-state/title.mjs +84 -5
  213. package/build-module/empty-state/title.mjs.map +3 -3
  214. package/build-module/empty-state/visual.mjs +84 -5
  215. package/build-module/empty-state/visual.mjs.map +3 -3
  216. package/build-module/form/index.mjs +1 -0
  217. package/build-module/form/index.mjs.map +2 -2
  218. package/build-module/form/primitives/autocomplete/empty.mjs +84 -5
  219. package/build-module/form/primitives/autocomplete/empty.mjs.map +3 -3
  220. package/build-module/form/primitives/autocomplete/item.mjs +86 -10
  221. package/build-module/form/primitives/autocomplete/item.mjs.map +3 -3
  222. package/build-module/form/primitives/autocomplete/list-body.mjs +84 -5
  223. package/build-module/form/primitives/autocomplete/list-body.mjs.map +3 -3
  224. package/build-module/form/primitives/autocomplete/list.mjs +84 -5
  225. package/build-module/form/primitives/autocomplete/list.mjs.map +3 -3
  226. package/build-module/form/primitives/autocomplete/popup.mjs +90 -17
  227. package/build-module/form/primitives/autocomplete/popup.mjs.map +3 -3
  228. package/build-module/form/primitives/field/description.mjs +86 -10
  229. package/build-module/form/primitives/field/description.mjs.map +3 -3
  230. package/build-module/form/primitives/field/details.mjs +84 -5
  231. package/build-module/form/primitives/field/details.mjs.map +3 -3
  232. package/build-module/form/primitives/field/label.mjs +84 -5
  233. package/build-module/form/primitives/field/label.mjs.map +3 -3
  234. package/build-module/form/primitives/field/root.mjs +84 -5
  235. package/build-module/form/primitives/field/root.mjs.map +3 -3
  236. package/build-module/form/primitives/fieldset/description.mjs +86 -10
  237. package/build-module/form/primitives/fieldset/description.mjs.map +3 -3
  238. package/build-module/form/primitives/fieldset/details.mjs +84 -5
  239. package/build-module/form/primitives/fieldset/details.mjs.map +3 -3
  240. package/build-module/form/primitives/fieldset/legend.mjs +84 -5
  241. package/build-module/form/primitives/fieldset/legend.mjs.map +3 -3
  242. package/build-module/form/primitives/fieldset/root.mjs +84 -5
  243. package/build-module/form/primitives/fieldset/root.mjs.map +3 -3
  244. package/build-module/form/primitives/input/input.mjs +88 -15
  245. package/build-module/form/primitives/input/input.mjs.map +3 -3
  246. package/build-module/form/primitives/input-layout/input-layout.mjs +88 -15
  247. package/build-module/form/primitives/input-layout/input-layout.mjs.map +3 -3
  248. package/build-module/form/primitives/input-layout/slot.mjs +84 -5
  249. package/build-module/form/primitives/input-layout/slot.mjs.map +3 -3
  250. package/build-module/form/primitives/select/item.mjs +87 -11
  251. package/build-module/form/primitives/select/item.mjs.map +3 -3
  252. package/build-module/form/primitives/select/popup.mjs +90 -17
  253. package/build-module/form/primitives/select/popup.mjs.map +3 -3
  254. package/build-module/form/primitives/select/root.mjs.map +2 -2
  255. package/build-module/form/primitives/select/trigger.mjs +98 -16
  256. package/build-module/form/primitives/select/trigger.mjs.map +3 -3
  257. package/build-module/form/primitives/textarea/textarea.mjs +86 -10
  258. package/build-module/form/primitives/textarea/textarea.mjs.map +3 -3
  259. package/build-module/form/select-control/context.mjs +11 -0
  260. package/build-module/form/select-control/context.mjs.map +7 -0
  261. package/build-module/form/select-control/index.mjs +14 -0
  262. package/build-module/form/select-control/index.mjs.map +7 -0
  263. package/build-module/form/select-control/item.mjs +16 -0
  264. package/build-module/form/select-control/item.mjs.map +7 -0
  265. package/build-module/form/select-control/select-control.mjs +50 -0
  266. package/build-module/form/select-control/select-control.mjs.map +7 -0
  267. package/build-module/form/select-control/types.mjs +1 -0
  268. package/build-module/form/select-control/types.mjs.map +7 -0
  269. package/build-module/icon-button/icon-button.mjs +86 -6
  270. package/build-module/icon-button/icon-button.mjs.map +3 -3
  271. package/build-module/link/link.mjs +90 -20
  272. package/build-module/link/link.mjs.map +3 -3
  273. package/build-module/notice/action-button.mjs +84 -5
  274. package/build-module/notice/action-button.mjs.map +3 -3
  275. package/build-module/notice/action-link.mjs +84 -5
  276. package/build-module/notice/action-link.mjs.map +3 -3
  277. package/build-module/notice/actions.mjs +84 -5
  278. package/build-module/notice/actions.mjs.map +3 -3
  279. package/build-module/notice/close-icon.mjs +84 -5
  280. package/build-module/notice/close-icon.mjs.map +3 -3
  281. package/build-module/notice/description.mjs +84 -5
  282. package/build-module/notice/description.mjs.map +3 -3
  283. package/build-module/notice/root.mjs +86 -10
  284. package/build-module/notice/root.mjs.map +3 -3
  285. package/build-module/notice/title.mjs +84 -5
  286. package/build-module/notice/title.mjs.map +3 -3
  287. package/build-module/popover/arrow.mjs +84 -5
  288. package/build-module/popover/arrow.mjs.map +3 -3
  289. package/build-module/popover/popup.mjs +88 -12
  290. package/build-module/popover/popup.mjs.map +3 -3
  291. package/build-module/popover/title.mjs +84 -5
  292. package/build-module/popover/title.mjs.map +3 -3
  293. package/build-module/stack/stack.mjs +84 -5
  294. package/build-module/stack/stack.mjs.map +3 -3
  295. package/build-module/tabs/list.mjs +84 -5
  296. package/build-module/tabs/list.mjs.map +3 -3
  297. package/build-module/tabs/panel.mjs +86 -10
  298. package/build-module/tabs/panel.mjs.map +3 -3
  299. package/build-module/tabs/tab.mjs +84 -5
  300. package/build-module/tabs/tab.mjs.map +3 -3
  301. package/build-module/text/text.mjs +86 -10
  302. package/build-module/text/text.mjs.map +3 -3
  303. package/build-module/tooltip/index.mjs +2 -0
  304. package/build-module/tooltip/index.mjs.map +2 -2
  305. package/build-module/tooltip/popup.mjs +111 -40
  306. package/build-module/tooltip/popup.mjs.map +3 -3
  307. package/build-module/tooltip/positioner.mjs +124 -0
  308. package/build-module/tooltip/positioner.mjs.map +7 -0
  309. package/build-module/utils/render-slot-with-children.mjs +9 -0
  310. package/build-module/utils/render-slot-with-children.mjs.map +7 -0
  311. package/build-module/visually-hidden/visually-hidden.mjs +84 -5
  312. package/build-module/visually-hidden/visually-hidden.mjs.map +3 -3
  313. package/build-types/alert-dialog/portal.d.ts +1 -1
  314. package/build-types/alert-dialog/portal.d.ts.map +1 -1
  315. package/build-types/alert-dialog/root.d.ts +1 -1
  316. package/build-types/alert-dialog/root.d.ts.map +1 -1
  317. package/build-types/alert-dialog/stories/index.story.d.ts.map +1 -1
  318. package/build-types/badge/stories/choosing-intent.story.d.ts.map +1 -1
  319. package/build-types/badge/stories/index.story.d.ts.map +1 -1
  320. package/build-types/button/button.d.ts +3 -0
  321. package/build-types/button/button.d.ts.map +1 -1
  322. package/build-types/button/icon.d.ts +1 -8
  323. package/build-types/button/icon.d.ts.map +1 -1
  324. package/build-types/button/index.d.ts +6 -5
  325. package/build-types/button/index.d.ts.map +1 -1
  326. package/build-types/button/stories/index.story.d.ts.map +1 -1
  327. package/build-types/button/types.d.ts +7 -0
  328. package/build-types/button/types.d.ts.map +1 -1
  329. package/build-types/card/stories/index.story.d.ts.map +1 -1
  330. package/build-types/collapsible/panel.d.ts +1 -1
  331. package/build-types/collapsible/root.d.ts +1 -1
  332. package/build-types/collapsible/stories/index.story.d.ts.map +1 -1
  333. package/build-types/collapsible/trigger.d.ts +1 -1
  334. package/build-types/collapsible-card/header.d.ts +6 -0
  335. package/build-types/collapsible-card/header.d.ts.map +1 -1
  336. package/build-types/collapsible-card/stories/index.story.d.ts +8 -0
  337. package/build-types/collapsible-card/stories/index.story.d.ts.map +1 -1
  338. package/build-types/dialog/context.d.ts +2 -2
  339. package/build-types/dialog/popup.d.ts +1 -2
  340. package/build-types/dialog/popup.d.ts.map +1 -1
  341. package/build-types/dialog/portal.d.ts +1 -1
  342. package/build-types/dialog/portal.d.ts.map +1 -1
  343. package/build-types/dialog/stories/index.story.d.ts.map +1 -1
  344. package/build-types/drawer/content.d.ts +7 -4
  345. package/build-types/drawer/content.d.ts.map +1 -1
  346. package/build-types/drawer/context.d.ts +2 -2
  347. package/build-types/drawer/popup.d.ts +1 -2
  348. package/build-types/drawer/popup.d.ts.map +1 -1
  349. package/build-types/drawer/stories/index.story.d.ts.map +1 -1
  350. package/build-types/drawer/types.d.ts +1 -1
  351. package/build-types/empty-state/stories/index.story.d.ts.map +1 -1
  352. package/build-types/form/index.d.ts +1 -0
  353. package/build-types/form/index.d.ts.map +1 -1
  354. package/build-types/form/input-control/stories/index.story.d.ts.map +1 -1
  355. package/build-types/form/primitives/autocomplete/clear.d.ts +1 -1
  356. package/build-types/form/primitives/autocomplete/empty.d.ts +1 -1
  357. package/build-types/form/primitives/autocomplete/input-group.d.ts +1 -1
  358. package/build-types/form/primitives/autocomplete/item.d.ts +1 -1
  359. package/build-types/form/primitives/autocomplete/list-body.d.ts +1 -1
  360. package/build-types/form/primitives/autocomplete/list.d.ts +2 -2
  361. package/build-types/form/primitives/autocomplete/popup.d.ts +2 -2
  362. package/build-types/form/primitives/autocomplete/portal.d.ts +1 -1
  363. package/build-types/form/primitives/autocomplete/portal.d.ts.map +1 -1
  364. package/build-types/form/primitives/autocomplete/stories/index.story.d.ts.map +1 -1
  365. package/build-types/form/primitives/field/control.d.ts +2 -2
  366. package/build-types/form/primitives/field/description.d.ts +1 -1
  367. package/build-types/form/primitives/field/details.d.ts +1 -1
  368. package/build-types/form/primitives/field/label.d.ts +3 -3
  369. package/build-types/form/primitives/field/root.d.ts +3 -3
  370. package/build-types/form/primitives/field/stories/index.story.d.ts.map +1 -1
  371. package/build-types/form/primitives/fieldset/description.d.ts +1 -1
  372. package/build-types/form/primitives/fieldset/details.d.ts +1 -1
  373. package/build-types/form/primitives/fieldset/legend.d.ts +1 -1
  374. package/build-types/form/primitives/fieldset/root.d.ts +1 -1
  375. package/build-types/form/primitives/fieldset/stories/index.story.d.ts.map +1 -1
  376. package/build-types/form/primitives/input/input.d.ts +5 -5
  377. package/build-types/form/primitives/input/stories/index.story.d.ts.map +1 -1
  378. package/build-types/form/primitives/input-layout/stories/index.story.d.ts.map +1 -1
  379. package/build-types/form/primitives/select/item.d.ts +3 -3
  380. package/build-types/form/primitives/select/popup.d.ts +2 -2
  381. package/build-types/form/primitives/select/root.d.ts +12 -1
  382. package/build-types/form/primitives/select/root.d.ts.map +1 -1
  383. package/build-types/form/primitives/select/stories/index.story.d.ts +9 -6
  384. package/build-types/form/primitives/select/stories/index.story.d.ts.map +1 -1
  385. package/build-types/form/primitives/select/trigger.d.ts +5 -4
  386. package/build-types/form/primitives/select/trigger.d.ts.map +1 -1
  387. package/build-types/form/primitives/select/types.d.ts +12 -4
  388. package/build-types/form/primitives/select/types.d.ts.map +1 -1
  389. package/build-types/form/primitives/textarea/stories/index.story.d.ts.map +1 -1
  390. package/build-types/form/primitives/textarea/textarea.d.ts +2 -2
  391. package/build-types/form/select-control/context.d.ts +3 -0
  392. package/build-types/form/select-control/context.d.ts.map +1 -0
  393. package/build-types/form/select-control/index.d.ts +20 -0
  394. package/build-types/form/select-control/index.d.ts.map +1 -0
  395. package/build-types/form/select-control/item.d.ts +6 -0
  396. package/build-types/form/select-control/item.d.ts.map +1 -0
  397. package/build-types/form/select-control/select-control.d.ts +11 -0
  398. package/build-types/form/select-control/select-control.d.ts.map +1 -0
  399. package/build-types/form/select-control/stories/index.story.d.ts +40 -0
  400. package/build-types/form/select-control/stories/index.story.d.ts.map +1 -0
  401. package/build-types/form/select-control/test/index.test.d.ts +2 -0
  402. package/build-types/form/select-control/test/index.test.d.ts.map +1 -0
  403. package/build-types/form/select-control/types.d.ts +40 -0
  404. package/build-types/form/select-control/types.d.ts.map +1 -0
  405. package/build-types/form/types.d.ts +1 -1
  406. package/build-types/form/types.d.ts.map +1 -1
  407. package/build-types/icon/stories/index.story.d.ts.map +1 -1
  408. package/build-types/icon-button/icon-button.d.ts +2 -1
  409. package/build-types/icon-button/icon-button.d.ts.map +1 -1
  410. package/build-types/icon-button/stories/index.story.d.ts +5 -0
  411. package/build-types/icon-button/stories/index.story.d.ts.map +1 -1
  412. package/build-types/icon-button/types.d.ts +8 -0
  413. package/build-types/icon-button/types.d.ts.map +1 -1
  414. package/build-types/link/stories/index.story.d.ts.map +1 -1
  415. package/build-types/notice/stories/index.story.d.ts.map +1 -1
  416. package/build-types/popover/stories/index.story.d.ts.map +1 -1
  417. package/build-types/stack/stories/index.story.d.ts.map +1 -1
  418. package/build-types/tabs/context.d.ts +1 -1
  419. package/build-types/tabs/context.d.ts.map +1 -1
  420. package/build-types/tabs/list.d.ts +2 -2
  421. package/build-types/tabs/panel.d.ts +1 -1
  422. package/build-types/tabs/root.d.ts +1 -1
  423. package/build-types/tabs/stories/index.story.d.ts.map +1 -1
  424. package/build-types/tabs/tab.d.ts +1 -1
  425. package/build-types/text/stories/index.story.d.ts.map +1 -1
  426. package/build-types/tooltip/index.d.ts +2 -1
  427. package/build-types/tooltip/index.d.ts.map +1 -1
  428. package/build-types/tooltip/popup.d.ts.map +1 -1
  429. package/build-types/tooltip/positioner.d.ts +9 -0
  430. package/build-types/tooltip/positioner.d.ts.map +1 -0
  431. package/build-types/tooltip/stories/index.story.d.ts +11 -2
  432. package/build-types/tooltip/stories/index.story.d.ts.map +1 -1
  433. package/build-types/tooltip/stories/usage-guidelines.story.d.ts.map +1 -1
  434. package/build-types/tooltip/types.d.ts +10 -1
  435. package/build-types/tooltip/types.d.ts.map +1 -1
  436. package/build-types/utils/create-overlay-modal-context.d.ts.map +1 -1
  437. package/build-types/utils/render-slot-with-children.d.ts +24 -0
  438. package/build-types/utils/render-slot-with-children.d.ts.map +1 -0
  439. package/build-types/utils/use-deprioritized-initial-focus.d.ts +1 -1
  440. package/build-types/utils/use-deprioritized-initial-focus.d.ts.map +1 -1
  441. package/build-types/visually-hidden/stories/index.story.d.ts.map +1 -1
  442. package/package.json +13 -12
  443. package/src/alert-dialog/popup.tsx +2 -2
  444. package/src/alert-dialog/stories/index.story.tsx +8 -0
  445. package/src/badge/stories/index.story.tsx +6 -0
  446. package/src/button/button.tsx +3 -0
  447. package/src/button/icon.tsx +1 -8
  448. package/src/button/index.ts +5 -6
  449. package/src/button/stories/index.story.tsx +10 -0
  450. package/src/button/types.ts +8 -0
  451. package/src/card/stories/index.story.tsx +6 -0
  452. package/src/collapsible/stories/index.story.tsx +6 -0
  453. package/src/collapsible-card/header.tsx +55 -42
  454. package/src/collapsible-card/stories/index.story.tsx +61 -0
  455. package/src/collapsible-card/style.module.css +20 -0
  456. package/src/collapsible-card/test/index.test.tsx +60 -1
  457. package/src/dialog/popup.tsx +3 -4
  458. package/src/dialog/stories/index.story.tsx +8 -0
  459. package/src/dialog/style.module.css +3 -9
  460. package/src/drawer/content.tsx +31 -16
  461. package/src/drawer/popup.tsx +3 -4
  462. package/src/drawer/stories/index.story.tsx +7 -0
  463. package/src/drawer/style.module.css +41 -9
  464. package/src/drawer/test/index.test.tsx +56 -0
  465. package/src/drawer/types.ts +1 -1
  466. package/src/empty-state/stories/index.story.tsx +7 -0
  467. package/src/form/index.ts +1 -0
  468. package/src/form/input-control/stories/index.story.tsx +7 -0
  469. package/src/form/primitives/autocomplete/popup.tsx +2 -2
  470. package/src/form/primitives/autocomplete/stories/index.story.tsx +18 -10
  471. package/src/form/primitives/field/stories/index.story.tsx +12 -5
  472. package/src/form/primitives/fieldset/stories/index.story.tsx +10 -3
  473. package/src/form/primitives/input/stories/index.story.tsx +7 -0
  474. package/src/form/primitives/input-layout/stories/index.story.tsx +8 -1
  475. package/src/form/primitives/select/item.tsx +1 -1
  476. package/src/form/primitives/select/popup.tsx +2 -2
  477. package/src/form/primitives/select/root.tsx +13 -2
  478. package/src/form/primitives/select/stories/index.story.tsx +132 -61
  479. package/src/form/primitives/select/test/index.test.tsx +123 -5
  480. package/src/form/primitives/select/trigger.tsx +11 -8
  481. package/src/form/primitives/select/types.ts +13 -5
  482. package/src/form/primitives/textarea/stories/index.story.tsx +7 -0
  483. package/src/form/select-control/context.tsx +9 -0
  484. package/src/form/select-control/index.ts +14 -0
  485. package/src/form/select-control/item.tsx +13 -0
  486. package/src/form/select-control/select-control.tsx +65 -0
  487. package/src/form/select-control/stories/index.story.tsx +220 -0
  488. package/src/form/select-control/test/index.test.tsx +196 -0
  489. package/src/form/select-control/types.ts +50 -0
  490. package/src/form/types.ts +1 -1
  491. package/src/icon/stories/index.story.tsx +7 -0
  492. package/src/icon-button/icon-button.tsx +2 -1
  493. package/src/icon-button/stories/index.story.tsx +20 -0
  494. package/src/icon-button/types.ts +9 -0
  495. package/src/link/stories/index.story.tsx +6 -0
  496. package/src/link/style.module.css +1 -0
  497. package/src/notice/stories/index.story.tsx +7 -0
  498. package/src/popover/popup.tsx +2 -2
  499. package/src/popover/stories/index.story.tsx +7 -0
  500. package/src/stack/stories/index.story.tsx +6 -0
  501. package/src/tabs/stories/index.story.tsx +15 -1
  502. package/src/text/stories/index.story.tsx +6 -0
  503. package/src/text/style.module.css +25 -0
  504. package/src/tooltip/index.ts +2 -1
  505. package/src/tooltip/popup.tsx +30 -38
  506. package/src/tooltip/positioner.tsx +36 -0
  507. package/src/tooltip/stories/index.story.tsx +61 -10
  508. package/src/tooltip/stories/usage-guidelines.story.tsx +5 -0
  509. package/src/tooltip/types.ts +14 -3
  510. package/src/utils/css/dropdown-motion.module.css +3 -3
  511. package/src/utils/css/item-popup.module.css +5 -1
  512. package/src/utils/css/overlay-chrome.module.css +21 -4
  513. package/src/utils/css/select-trigger.module.css +5 -2
  514. package/src/utils/render-slot-with-children.ts +31 -0
  515. package/src/visually-hidden/stories/index.story.tsx +6 -0
  516. package/build/utils/render-portal-with-children.cjs.map +0 -7
  517. package/build-module/utils/render-portal-with-children.mjs +0 -12
  518. package/build-module/utils/render-portal-with-children.mjs.map +0 -7
  519. package/build-types/utils/render-portal-with-children.d.ts +0 -16
  520. package/build-types/utils/render-portal-with-children.d.ts.map +0 -1
  521. package/src/utils/render-portal-with-children.ts +0 -27
@@ -1 +1 @@
1
- {"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/tooltip/stories/index.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAG5D,OAAO,KAAK,OAAO,MAAM,KAAK,CAAC;AAE/B,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,OAAO,CAAC,IAAI,CASpC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,OAAO,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CASlD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAMnD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,WAAW,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CA+BtD,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAkB3D,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,YAAY,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAoBvD,CAAC"}
1
+ {"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/tooltip/stories/index.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAG5D,OAAO,KAAK,OAAO,MAAM,KAAK,CAAC;AAE/B,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,OAAO,CAAC,IAAI,CAiBpC,CAAC;eACa,IAAI;AAEnB,eAAO,MAAM,OAAO,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CASlD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAMnD,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CA6CtD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAmB/D,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAkB3D,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,YAAY,EAAE,QAAQ,CAAE,OAAO,OAAO,CAAC,IAAI,CAoBvD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"usage-guidelines.story.d.ts","sourceRoot":"","sources":["../../../src/tooltip/stories/usage-guidelines.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAa5D,QAAA,MAAM,IAAI,EAAE,IAMX,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AAEtB;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,KA2B9B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,EAAE,KA0ChC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,KAYnC,CAAC"}
1
+ {"version":3,"file":"usage-guidelines.story.d.ts","sourceRoot":"","sources":["../../../src/tooltip/stories/usage-guidelines.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAa5D,QAAA,MAAM,IAAI,EAAE,IAWX,CAAC;eACa,IAAI;AAEnB,KAAK,KAAK,GAAG,QAAQ,CAAC;AAEtB;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,KA2B9B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,EAAE,KA0ChC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,KAYnC,CAAC"}
@@ -2,6 +2,7 @@ import type { ComponentPropsWithoutRef, ReactElement, ReactNode } from 'react';
2
2
  import type { Tooltip as _Tooltip } from '@base-ui/react/tooltip';
3
3
  import type { ComponentProps } from '../utils/types';
4
4
  export type PortalProps = ComponentPropsWithoutRef<typeof _Tooltip.Portal>;
5
+ export type PositionerProps = ComponentPropsWithoutRef<typeof _Tooltip.Positioner>;
5
6
  export type RootProps = Pick<_Tooltip.Root.Props, 'disabled' | 'children'>;
6
7
  export type ProviderProps = Pick<_Tooltip.Provider.Props, 'delay' | 'children'>;
7
8
  export interface TriggerProps extends ComponentProps<'button'> {
@@ -10,7 +11,7 @@ export interface TriggerProps extends ComponentProps<'button'> {
10
11
  */
11
12
  children?: ReactNode;
12
13
  }
13
- export interface PopupProps extends ComponentProps<'div'>, Pick<_Tooltip.Positioner.Props, 'align' | 'side' | 'sideOffset'> {
14
+ export interface PopupProps extends ComponentProps<'div'> {
14
15
  /**
15
16
  * The content to be rendered inside the component.
16
17
  */
@@ -22,5 +23,13 @@ export interface PopupProps extends ComponentProps<'div'>, Pick<_Tooltip.Positio
22
23
  * be ignored.
23
24
  */
24
25
  portal?: ReactElement<Omit<PortalProps, 'children'>>;
26
+ /**
27
+ * Optional positioner element, typically `<Tooltip.Positioner />` with
28
+ * custom positioning props (`side`, `align`, `sideOffset`, collision
29
+ * settings, etc.). When omitted, `Tooltip.Popup` uses `Tooltip.Positioner`
30
+ * with default props. Do not pass `children` on the positioner element;
31
+ * they would be ignored.
32
+ */
33
+ positioner?: ReactElement<Omit<PositionerProps, 'children'>>;
25
34
  }
26
35
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/tooltip/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC/E,OAAO,KAAK,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAErD,MAAM,MAAM,WAAW,GAAG,wBAAwB,CAAE,OAAO,QAAQ,CAAC,MAAM,CAAE,CAAC;AAE7E,MAAM,MAAM,SAAS,GAAG,IAAI,CAAE,QAAQ,CAAC,IAAI,CAAC,KAAK,EAAE,UAAU,GAAG,UAAU,CAAE,CAAC;AAE7E,MAAM,MAAM,aAAa,GAAG,IAAI,CAC/B,QAAQ,CAAC,QAAQ,CAAC,KAAK,EACvB,OAAO,GAAG,UAAU,CACpB,CAAC;AAEF,MAAM,WAAW,YAAa,SAAQ,cAAc,CAAE,QAAQ,CAAE;IAC/D;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,MAAM,WAAW,UAChB,SAAQ,cAAc,CAAE,KAAK,CAAE,EAC9B,IAAI,CAAE,QAAQ,CAAC,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,YAAY,CAAE;IACnE;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,YAAY,CAAE,IAAI,CAAE,WAAW,EAAE,UAAU,CAAE,CAAE,CAAC;CACzD"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/tooltip/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC/E,OAAO,KAAK,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAErD,MAAM,MAAM,WAAW,GAAG,wBAAwB,CAAE,OAAO,QAAQ,CAAC,MAAM,CAAE,CAAC;AAE7E,MAAM,MAAM,eAAe,GAAG,wBAAwB,CACrD,OAAO,QAAQ,CAAC,UAAU,CAC1B,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG,IAAI,CAAE,QAAQ,CAAC,IAAI,CAAC,KAAK,EAAE,UAAU,GAAG,UAAU,CAAE,CAAC;AAE7E,MAAM,MAAM,aAAa,GAAG,IAAI,CAC/B,QAAQ,CAAC,QAAQ,CAAC,KAAK,EACvB,OAAO,GAAG,UAAU,CACpB,CAAC;AAEF,MAAM,WAAW,YAAa,SAAQ,cAAc,CAAE,QAAQ,CAAE;IAC/D;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,MAAM,WAAW,UAAW,SAAQ,cAAc,CAAE,KAAK,CAAE;IAC1D;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,YAAY,CAAE,IAAI,CAAE,WAAW,EAAE,UAAU,CAAE,CAAE,CAAC;IAEzD;;;;;;OAMG;IACH,UAAU,CAAC,EAAE,YAAY,CAAE,IAAI,CAAE,eAAe,EAAE,UAAU,CAAE,CAAE,CAAC;CACjE"}
@@ -1 +1 @@
1
- {"version":3,"file":"create-overlay-modal-context.d.ts","sourceRoot":"","sources":["../../src/utils/create-overlay-modal-context.tsx"],"names":[],"mappings":"AAEA,KAAK,yBAAyB,CAAE,KAAK,IAAK;IACzC,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,yBAAyB,CAAE,KAAK,EAAI,YAAY,EAAE,KAAK;qCAMnE,yBAAyB,CAAE,KAAK,CAAE;;EAgBrC"}
1
+ {"version":3,"file":"create-overlay-modal-context.d.ts","sourceRoot":"","sources":["../../src/utils/create-overlay-modal-context.tsx"],"names":[],"mappings":"AAEA,KAAK,yBAAyB,CAAE,KAAK,IAAK;IACzC,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,yBAAyB,CAAE,KAAK,EAAI,YAAY,EAAE,KAAK;IAmBrE,QAAQ,yBAbN,yBAAyB,CAAE,KAAK,CAAE;IAcpC,QAAQ;EAET"}
@@ -0,0 +1,24 @@
1
+ import type { ReactElement, ReactNode } from 'react';
2
+ /**
3
+ * Fills an optional "slot" element prop with content by cloning it and
4
+ * injecting the given `children`. When `slot` is undefined, the provided
5
+ * `defaultSlot` is used in its place.
6
+ *
7
+ * Shared by overlay `Popup` components for their slot-shaped customization
8
+ * props (e.g. `portal`, `positioner`), so the merge behavior — defaults,
9
+ * children injection — stays consistent across all of them.
10
+ *
11
+ * Callers should type the slot prop as `ReactElement<Omit<Props, 'children'>>`:
12
+ * any subtree passed on the slot element is overwritten by `children`.
13
+ *
14
+ * @param slot Optional element from the slot prop (e.g. `<Tooltip.Portal … />`
15
+ * or `<Tooltip.Positioner … />`). When omitted, `defaultSlot`
16
+ * is used. Injected `children` replace any subtree the caller
17
+ * may have passed on the slot element.
18
+ * @param defaultSlot Unpopulated default element used when `slot` is omitted
19
+ * (e.g. `<Tooltip.Portal />`).
20
+ * @param children Content to inject as the slot's children (backdrop,
21
+ * positioner, popup subtree, etc.).
22
+ */
23
+ export declare function renderSlotWithChildren(slot: ReactElement | undefined, defaultSlot: ReactElement, children: ReactNode): ReactElement;
24
+ //# sourceMappingURL=render-slot-with-children.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render-slot-with-children.d.ts","sourceRoot":"","sources":["../../src/utils/render-slot-with-children.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,sBAAsB,CACrC,IAAI,EAAE,YAAY,GAAG,SAAS,EAC9B,WAAW,EAAE,YAAY,EACzB,QAAQ,EAAE,SAAS,GACjB,YAAY,CAEd"}
@@ -26,7 +26,7 @@ type InitialFocus = _Popover.Popup.Props['initialFocus'];
26
26
  * @param props.initialFocus The consumer-provided `initialFocus` value.
27
27
  * @param props.deprioritizedAttributes The data attributes whose elements should be deprioritized.
28
28
  */
29
- export declare function useDeprioritizedInitialFocus({ initialFocus, deprioritizedAttributes, }: {
29
+ export declare function useDeprioritizedInitialFocus({ initialFocus, deprioritizedAttributes }: {
30
30
  initialFocus: InitialFocus;
31
31
  deprioritizedAttributes: string[];
32
32
  }): {
@@ -1 +1 @@
1
- {"version":3,"file":"use-deprioritized-initial-focus.d.ts","sourceRoot":"","sources":["../../src/utils/use-deprioritized-initial-focus.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAIlE;;;;GAIG;AACH,KAAK,YAAY,GAAG,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAE,cAAc,CAAE,CAAC;AAe3D;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,4BAA4B,CAAE,EAC7C,YAAY,EACZ,uBAAuB,GACvB,EAAE;IACF,YAAY,EAAE,YAAY,CAAC;IAC3B,uBAAuB,EAAE,MAAM,EAAE,CAAC;CAClC;;;EAsCA"}
1
+ {"version":3,"file":"use-deprioritized-initial-focus.d.ts","sourceRoot":"","sources":["../../src/utils/use-deprioritized-initial-focus.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAIlE;;;;GAIG;AACH,KAAK,YAAY,GAAG,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAE,cAAc,CAAE,CAAC;AAe3D;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,4BAA4B,CAAE,EAC7C,YAAY,EACZ,uBAAuB,EACvB,EAAE;IACF,YAAY,EAAE,YAAY,CAAC;IAC3B,uBAAuB,EAAE,MAAM,EAAE,CAAC;CAClC;;;EAsCA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/visually-hidden/stories/index.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAErC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,cAAc,CAItC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAE,OAAO,cAAc,CAAE,CAAC;AAE/C,eAAO,MAAM,OAAO,EAAE,KAUrB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,EAAE,KAgB/B,CAAC"}
1
+ {"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/visually-hidden/stories/index.story.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAErC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,cAAc,CAUtC,CAAC;eACa,IAAI;AAEnB,KAAK,KAAK,GAAG,QAAQ,CAAE,OAAO,cAAc,CAAE,CAAC;AAE/C,eAAO,MAAM,OAAO,EAAE,KAUrB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,EAAE,KAgB/B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/ui",
3
- "version": "0.12.0",
3
+ "version": "0.13.1-next.v.202605131006.0+2a3d07cab",
4
4
  "description": "Themeable React UI components for the WordPress Design System.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -44,15 +44,16 @@
44
44
  "sideEffects": false,
45
45
  "dependencies": {
46
46
  "@base-ui/react": "^1.4.1",
47
- "@wordpress/a11y": "^4.45.0",
48
- "@wordpress/compose": "^7.45.0",
49
- "@wordpress/element": "^6.45.0",
50
- "@wordpress/i18n": "^6.18.0",
51
- "@wordpress/icons": "^13.0.0",
52
- "@wordpress/keycodes": "^4.45.0",
53
- "@wordpress/primitives": "^4.45.0",
54
- "@wordpress/private-apis": "^1.45.0",
55
- "@wordpress/theme": "^0.12.0",
47
+ "@wordpress/a11y": "^4.45.1-next.v.202605131006.0+2a3d07cab",
48
+ "@wordpress/compose": "^7.45.1-next.v.202605131006.0+2a3d07cab",
49
+ "@wordpress/element": "^6.45.1-next.v.202605131006.0+2a3d07cab",
50
+ "@wordpress/i18n": "^6.18.1-next.v.202605131006.0+2a3d07cab",
51
+ "@wordpress/icons": "^13.0.1-next.v.202605131006.0+2a3d07cab",
52
+ "@wordpress/keycodes": "^4.45.1-next.v.202605131006.0+2a3d07cab",
53
+ "@wordpress/primitives": "^4.45.1-next.v.202605131006.0+2a3d07cab",
54
+ "@wordpress/private-apis": "^1.45.1-next.v.202605131006.0+2a3d07cab",
55
+ "@wordpress/style-runtime": "^0.1.2-next.v.202605131006.0+2a3d07cab",
56
+ "@wordpress/theme": "^0.13.1-next.v.202605131006.0+2a3d07cab",
56
57
  "clsx": "^2.1.1",
57
58
  "tabbable": "^6.4.0"
58
59
  },
@@ -61,7 +62,7 @@
61
62
  "@storybook/react-vite": "^10.2.8",
62
63
  "@testing-library/jest-dom": "^6.9.1",
63
64
  "@types/jest": "^29.5.14",
64
- "@types/node": "^20.17.10",
65
+ "@types/node": "^20.19.39",
65
66
  "storybook": "^10.2.8"
66
67
  },
67
68
  "peerDependencies": {
@@ -71,5 +72,5 @@
71
72
  "publishConfig": {
72
73
  "access": "public"
73
74
  },
74
- "gitHead": "8c229eaed0e88c9827e2da3d73a78f9ddd77714b"
75
+ "gitHead": "8804fa29bc78a1d98e5a4d40c3e180ddd907016c"
75
76
  }
@@ -8,7 +8,7 @@ import {
8
8
  privateApis as themePrivateApis,
9
9
  } from '@wordpress/theme';
10
10
 
11
- import { renderPortalWithChildren } from '../utils/render-portal-with-children';
11
+ import { renderSlotWithChildren } from '../utils/render-slot-with-children';
12
12
  import { Button } from '../button';
13
13
  import dialogStyles from '../dialog/style.module.css';
14
14
  import focusStyles from '../utils/css/focus.module.css';
@@ -178,7 +178,7 @@ const Popup = forwardRef< HTMLDivElement, PopupProps >(
178
178
  </>
179
179
  );
180
180
 
181
- return renderPortalWithChildren( portal, <Portal />, portalChildren );
181
+ return renderSlotWithChildren( portal, <Portal />, portalChildren );
182
182
  }
183
183
  );
184
184
 
@@ -12,12 +12,20 @@ const meta: Meta< typeof AlertDialog.Root > = {
12
12
  component: AlertDialog.Root,
13
13
  subcomponents: {
14
14
  'AlertDialog.Trigger': AlertDialog.Trigger,
15
+ 'AlertDialog.Portal': AlertDialog.Portal,
15
16
  'AlertDialog.Popup': AlertDialog.Popup,
16
17
  },
17
18
  argTypes: {
18
19
  onConfirm: { action: fn() },
19
20
  onOpenChange: { action: fn() },
20
21
  },
22
+ parameters: {
23
+ componentStatus: {
24
+ status: 'use-with-caution',
25
+ whereUsed: 'global',
26
+ notes: 'Not yet recommended for use alongside components from `@wordpress/components`, pending review of overlays compatibility. See [WordPress/gutenberg#76135](https://github.com/WordPress/gutenberg/issues/76135).',
27
+ },
28
+ },
21
29
  };
22
30
  export default meta;
23
31
 
@@ -6,6 +6,12 @@ const meta: Meta< typeof Badge > = {
6
6
  tags: [ 'manifest' ],
7
7
  title: 'Design System/Components/Badge',
8
8
  component: Badge,
9
+ parameters: {
10
+ componentStatus: {
11
+ status: 'recommended',
12
+ whereUsed: 'global',
13
+ },
14
+ },
9
15
  };
10
16
  export default meta;
11
17
 
@@ -9,6 +9,9 @@ import resetStyles from '../utils/css/resets.module.css';
9
9
  import focusStyles from '../utils/css/focus.module.css';
10
10
  import defenseStyles from '../utils/css/global-css-defense.module.css';
11
11
 
12
+ /**
13
+ * A versatile button component with multiple variants, tones, and sizes.
14
+ */
12
15
  export const Button = forwardRef< HTMLButtonElement, ButtonProps >(
13
16
  function Button(
14
17
  {
@@ -1,14 +1,7 @@
1
1
  import { forwardRef } from '@wordpress/element';
2
- import { type IconProps } from '../icon/types';
2
+ import { type ButtonIconProps } from './types';
3
3
  import { Icon } from '../icon';
4
4
 
5
- interface ButtonIconProps extends IconProps {
6
- /**
7
- * The icon to display, from the `@wordpress/icons` package.
8
- */
9
- icon: IconProps[ 'icon' ];
10
- }
11
-
12
5
  export const ButtonIcon = forwardRef< SVGSVGElement, ButtonIconProps >(
13
6
  function ButtonIcon( { icon, ...props }, ref ) {
14
7
  return (
@@ -1,16 +1,15 @@
1
- import { Button as ButtonButton } from './button';
1
+ import { Button as _Button } from './button';
2
2
  import { ButtonIcon } from './icon';
3
3
 
4
+ ButtonIcon.displayName = 'Button.Icon';
5
+
4
6
  /**
5
7
  * A versatile button component with multiple variants, tones, and sizes.
6
- * Built on design tokens for consistent theming and accessibility.
7
8
  */
8
- export const Button = Object.assign( ButtonButton, {
9
+ export const Button = Object.assign( _Button, {
9
10
  /**
10
11
  * An icon component specifically designed to work well when rendered inside
11
12
  * a `Button` component.
12
13
  */
13
14
  Icon: ButtonIcon,
14
- } ) as typeof ButtonButton & {
15
- Icon: typeof ButtonIcon;
16
- };
15
+ } );
@@ -6,11 +6,21 @@ import { Button } from '../index';
6
6
  const meta: Meta< typeof Button > = {
7
7
  title: 'Design System/Components/Button',
8
8
  component: Button,
9
+ subcomponents: {
10
+ 'Button.Icon': Button.Icon,
11
+ },
9
12
  argTypes: {
10
13
  'aria-pressed': {
11
14
  control: { type: 'boolean' },
12
15
  },
13
16
  },
17
+ parameters: {
18
+ componentStatus: {
19
+ status: 'use-with-caution',
20
+ whereUsed: 'global',
21
+ notes: 'Not yet recommended for use alongside components from `@wordpress/components`, pending review of style consistency with `@wordpress/components` and text overflow behavior. See [WordPress/gutenberg#76135](https://github.com/WordPress/gutenberg/issues/76135).',
22
+ },
23
+ },
14
24
  };
15
25
  export default meta;
16
26
 
@@ -1,5 +1,6 @@
1
1
  import { type ReactNode, type HTMLAttributes } from 'react';
2
2
  import type { Button as _Button } from '@base-ui/react/button';
3
+ import { type IconProps } from '../icon/types';
3
4
  import type { ComponentProps } from '../utils/types';
4
5
 
5
6
  type _ButtonProps = ComponentProps< typeof _Button >;
@@ -70,3 +71,10 @@ export interface ButtonProps
70
71
  */
71
72
  loadingAnnouncement?: string;
72
73
  }
74
+
75
+ export interface ButtonIconProps extends IconProps {
76
+ /**
77
+ * The icon to display, from the `@wordpress/icons` package.
78
+ */
79
+ icon: IconProps[ 'icon' ];
80
+ }
@@ -33,6 +33,12 @@ const meta: Meta< typeof Card.Root > = {
33
33
  'Card.FullBleed': Card.FullBleed,
34
34
  'Card.Title': Card.Title,
35
35
  },
36
+ parameters: {
37
+ componentStatus: {
38
+ status: 'recommended',
39
+ whereUsed: 'global',
40
+ },
41
+ },
36
42
  };
37
43
  export default meta;
38
44
 
@@ -10,6 +10,12 @@ const meta: Meta< typeof Collapsible.Root > = {
10
10
  'Collapsible.Trigger': Collapsible.Trigger,
11
11
  'Collapsible.Panel': Collapsible.Panel,
12
12
  },
13
+ parameters: {
14
+ componentStatus: {
15
+ status: 'recommended',
16
+ whereUsed: 'global',
17
+ },
18
+ },
13
19
  };
14
20
  export default meta;
15
21
 
@@ -1,3 +1,4 @@
1
+ import { mergeProps, useRender } from '@base-ui/react';
1
2
  import clsx from 'clsx';
2
3
  import { forwardRef, useMemo, useState } from '@wordpress/element';
3
4
  import { chevronDown } from '@wordpress/icons';
@@ -15,6 +16,12 @@ import type { HeaderProps } from './types';
15
16
  * toggle trigger — clicking anywhere on it expands or collapses the
16
17
  * card's content.
17
18
  *
19
+ * Defaults to a `<div>` wrapper around the trigger. Since the right heading
20
+ * level depends on the surrounding document outline, the consumer is
21
+ * expected to opt in to heading semantics. Pass `render` to wrap the
22
+ * trigger in a heading (e.g. `render={ <h2 /> }`), following the W3C APG
23
+ * accordion pattern (heading wraps button).
24
+ *
18
25
  * Avoid placing interactive elements (buttons, links, inputs) inside the
19
26
  * header, since the entire area is clickable and their events will bubble
20
27
  * to trigger the collapse toggle.
@@ -31,48 +38,54 @@ export const Header = forwardRef< HTMLDivElement, HeaderProps >(
31
38
  [ setDescriptionId ]
32
39
  );
33
40
 
34
- return (
35
- <HeaderDescriptionIdContext.Provider value={ contextValue }>
36
- <Collapsible.Trigger
37
- className={ clsx( styles.header, className ) }
38
- render={
39
- <Card.Header
40
- ref={ ref }
41
- render={ render }
42
- { ...restProps }
43
- />
44
- }
45
- nativeButton={ false }
46
- aria-describedby={ descriptionId }
47
- >
48
- <div className={ styles[ 'header-content' ] }>
49
- { children }
50
- </div>
51
- <div
52
- className={ clsx(
53
- styles[ 'header-trigger-positioner' ]
54
- ) }
55
- >
56
- <div
57
- className={ clsx(
58
- styles[ 'header-trigger-wrapper' ],
59
- defenseStyles.div,
60
- // While the interactive trigger element is the whole header,
61
- // the focus ring will be displayed only on the icon to visually
62
- // emulate it being the button.
63
- focusStyles[
64
- 'outset-ring--focus-parent-visible'
65
- ]
66
- ) }
41
+ return useRender( {
42
+ defaultTagName: 'div',
43
+ render,
44
+ ref,
45
+ props: mergeProps< 'div' >( restProps, {
46
+ className: clsx(
47
+ defenseStyles.heading,
48
+ styles[ 'heading-wrapper' ],
49
+ className
50
+ ),
51
+ children: (
52
+ <HeaderDescriptionIdContext.Provider value={ contextValue }>
53
+ <Collapsible.Trigger
54
+ className={ styles.header }
55
+ render={ <Card.Header /> }
56
+ nativeButton={ false }
57
+ aria-describedby={ descriptionId }
67
58
  >
68
- <Icon
69
- icon={ chevronDown }
70
- className={ styles[ 'header-trigger' ] }
71
- />
72
- </div>
73
- </div>
74
- </Collapsible.Trigger>
75
- </HeaderDescriptionIdContext.Provider>
76
- );
59
+ <div className={ styles[ 'header-content' ] }>
60
+ { children }
61
+ </div>
62
+ <div
63
+ className={ clsx(
64
+ styles[ 'header-trigger-positioner' ]
65
+ ) }
66
+ >
67
+ <div
68
+ className={ clsx(
69
+ styles[ 'header-trigger-wrapper' ],
70
+ defenseStyles.div,
71
+ // While the interactive trigger element is the whole header,
72
+ // the focus ring will be displayed only on the icon to visually
73
+ // emulate it being the button.
74
+ focusStyles[
75
+ 'outset-ring--focus-parent-visible'
76
+ ]
77
+ ) }
78
+ >
79
+ <Icon
80
+ icon={ chevronDown }
81
+ className={ styles[ 'header-trigger' ] }
82
+ />
83
+ </div>
84
+ </div>
85
+ </Collapsible.Trigger>
86
+ </HeaderDescriptionIdContext.Provider>
87
+ ),
88
+ } ),
89
+ } );
77
90
  }
78
91
  );
@@ -34,6 +34,12 @@ const meta: Meta< typeof CollapsibleCard.Root > = {
34
34
  'CollapsibleCard.HeaderDescription': CollapsibleCard.HeaderDescription,
35
35
  'CollapsibleCard.Content': CollapsibleCard.Content,
36
36
  },
37
+ parameters: {
38
+ componentStatus: {
39
+ status: 'recommended',
40
+ whereUsed: 'global',
41
+ },
42
+ },
37
43
  };
38
44
  export default meta;
39
45
 
@@ -159,6 +165,61 @@ export const Stacked: Story = {
159
165
  ),
160
166
  };
161
167
 
168
+ /**
169
+ * `CollapsibleCard.Header` renders a `<div>` wrapper by default. Pass an
170
+ * `<h1>`–`<h6>` React element to the `render` prop to wrap the trigger in
171
+ * a heading and contribute to the document outline. The right level
172
+ * depends on the surrounding outline, so the consumer is expected to opt
173
+ * in.
174
+ */
175
+ export const WithHeadingElement: Story = {
176
+ parameters: { controls: { disable: true } },
177
+ render: () => (
178
+ <div
179
+ style={ {
180
+ display: 'flex',
181
+ flexDirection: 'column',
182
+ gap: 'var(--wpds-dimension-gap-lg)',
183
+ } }
184
+ >
185
+ <CollapsibleCard.Root>
186
+ <CollapsibleCard.Header render={ <h2 /> }>
187
+ <Card.Title>Heading level 2</Card.Title>
188
+ </CollapsibleCard.Header>
189
+ <CollapsibleCard.Content>
190
+ <Text>
191
+ The wrapper renders as an h2 element when the consumer
192
+ passes an h2 React element to the render prop.
193
+ </Text>
194
+ </CollapsibleCard.Content>
195
+ </CollapsibleCard.Root>
196
+ <CollapsibleCard.Root>
197
+ <CollapsibleCard.Header render={ <h3 /> }>
198
+ <Card.Title>Heading level 3</Card.Title>
199
+ </CollapsibleCard.Header>
200
+ <CollapsibleCard.Content>
201
+ <Text>
202
+ Pass any of h1–h6 to choose the level that fits the
203
+ surrounding document outline.
204
+ </Text>
205
+ </CollapsibleCard.Content>
206
+ </CollapsibleCard.Root>
207
+ <CollapsibleCard.Root>
208
+ <CollapsibleCard.Header>
209
+ <Card.Title>No heading (default)</Card.Title>
210
+ </CollapsibleCard.Header>
211
+ <CollapsibleCard.Content>
212
+ <Text>
213
+ Without a render prop, the header wraps the trigger in a
214
+ plain div and does not contribute to the document
215
+ outline.
216
+ </Text>
217
+ </CollapsibleCard.Content>
218
+ </CollapsibleCard.Root>
219
+ </div>
220
+ ),
221
+ };
222
+
162
223
  /**
163
224
  * A collapsible card with a `HeaderDescription` that provides supplementary
164
225
  * information (e.g. status, summary) as an `aria-describedby` relationship.
@@ -1,6 +1,26 @@
1
1
  @layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;
2
2
 
3
3
  @layer wp-ui-components {
4
+ /*
5
+ * Style overrides for the outer wrapper rendered by `CollapsibleCard.Header`
6
+ * (defaults to `<div>`, but consumers can opt into a heading level via
7
+ * `render={ <h2 /> }` etc.). Combined with `defenseStyles.heading` so that,
8
+ * when the wrapper renders as an h1–h6, the unlayered defense class beats
9
+ * wp-admin's bare `h2`/`h3`/etc. selectors. Keeps the wrapper visually
10
+ * transparent so UA and host stylesheets don't bleed into the inner
11
+ * trigger.
12
+ */
13
+ .heading-wrapper {
14
+ --_gcd-heading-color: inherit;
15
+ --_gcd-heading-font-size: inherit;
16
+ --_gcd-heading-font-weight: inherit;
17
+ --_gcd-heading-margin: 0;
18
+
19
+ /* Properties not covered by the defense file. */
20
+ font-family: inherit;
21
+ line-height: inherit;
22
+ }
23
+
4
24
  .header-content {
5
25
  flex: 1;
6
26
  min-width: 0;
@@ -1,4 +1,4 @@
1
- import { render, screen } from '@testing-library/react';
1
+ import { render, screen, within } from '@testing-library/react';
2
2
  import { userEvent } from '@testing-library/user-event';
3
3
  import { createRef } from '@wordpress/element';
4
4
  import * as Card from '../../card';
@@ -179,6 +179,65 @@ describe( 'CollapsibleCard', () => {
179
179
  } );
180
180
  } );
181
181
 
182
+ describe( 'header wrapper', () => {
183
+ it( 'does not contribute a heading to the document outline by default', () => {
184
+ render(
185
+ <CollapsibleCard.Root>
186
+ <CollapsibleCard.Header>
187
+ <Card.Title>Title</Card.Title>
188
+ </CollapsibleCard.Header>
189
+ </CollapsibleCard.Root>
190
+ );
191
+
192
+ expect(
193
+ screen.queryByRole( 'heading', { name: 'Title' } )
194
+ ).not.toBeInTheDocument();
195
+ expect(
196
+ screen.getByRole( 'button', { name: 'Title' } )
197
+ ).toBeVisible();
198
+ } );
199
+
200
+ it( 'wraps the trigger in a heading via `render`', () => {
201
+ render(
202
+ <CollapsibleCard.Root>
203
+ <CollapsibleCard.Header render={ <h2 /> }>
204
+ <Card.Title>Title</Card.Title>
205
+ </CollapsibleCard.Header>
206
+ </CollapsibleCard.Root>
207
+ );
208
+
209
+ const heading = screen.getByRole( 'heading', {
210
+ level: 2,
211
+ name: 'Title',
212
+ } );
213
+ expect( heading ).toBeVisible();
214
+ expect(
215
+ within( heading ).getByRole( 'button', { name: 'Title' } )
216
+ ).toBeVisible();
217
+ } );
218
+
219
+ it( 'forwards `className` and other props to the outer wrapper', () => {
220
+ render(
221
+ <CollapsibleCard.Root>
222
+ <CollapsibleCard.Header
223
+ className="custom-header"
224
+ data-testid="header"
225
+ >
226
+ <Card.Title>Title</Card.Title>
227
+ </CollapsibleCard.Header>
228
+ </CollapsibleCard.Root>
229
+ );
230
+
231
+ const wrapper = screen.getByTestId( 'header' );
232
+ expect( wrapper ).toHaveClass( 'custom-header' );
233
+ // The forwarded attributes land on the outer wrapper, not the
234
+ // inner button trigger.
235
+ expect(
236
+ within( wrapper ).getByRole( 'button', { name: 'Title' } )
237
+ ).not.toHaveAttribute( 'data-testid' );
238
+ } );
239
+ } );
240
+
182
241
  describe( 'HeaderDescription', () => {
183
242
  it( 'sets aria-describedby on the trigger pointing to the description', () => {
184
243
  render(
@@ -9,7 +9,7 @@ import {
9
9
  import { unlock } from '../lock-unlock';
10
10
  import { useDeprioritizedInitialFocus } from '../utils/use-deprioritized-initial-focus';
11
11
  import { SCROLL_CONTAINER_ATTR } from '../utils/use-overlay-scroll-state-attributes';
12
- import { renderPortalWithChildren } from '../utils/render-portal-with-children';
12
+ import { renderSlotWithChildren } from '../utils/render-slot-with-children';
13
13
  import { DialogValidationProvider, useDialogModal } from './context';
14
14
  import { Portal } from './portal';
15
15
  import styles from './style.module.css';
@@ -24,8 +24,7 @@ const CLOSE_ICON_ATTR = 'data-wp-ui-dialog-close-icon';
24
24
  * Renders the dialog popup element that contains the dialog content.
25
25
  * Uses a portal to render outside the DOM hierarchy.
26
26
  *
27
- * When `portal` is omitted, defaults to `Dialog.Portal`. Portal merging is
28
- * handled by `renderPortalWithChildren` (shared with other overlay `Popup`s).
27
+ * When `portal` is omitted, defaults to `Dialog.Portal`.
29
28
  */
30
29
  const Popup = forwardRef< HTMLDivElement, PopupProps >( function DialogPopup(
31
30
  {
@@ -80,7 +79,7 @@ const Popup = forwardRef< HTMLDivElement, PopupProps >( function DialogPopup(
80
79
  </>
81
80
  );
82
81
 
83
- return renderPortalWithChildren( portal, <Portal />, portalChildren );
82
+ return renderSlotWithChildren( portal, <Portal />, portalChildren );
84
83
  } );
85
84
 
86
85
  export { Popup };