@pine-ds/core 4.8.0 → 4.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (555) hide show
  1. package/components/attributes.js +1 -1
  2. package/components/floating-ui.dom.js +1 -1
  3. package/components/index.js +1 -1
  4. package/components/index2.js +1 -1
  5. package/components/keep-hydrated.js +1 -0
  6. package/components/mock-pds-modal.js +1 -1
  7. package/components/pds-alert.js +1 -1
  8. package/components/pds-avatar.js +1 -1
  9. package/components/pds-box2.js +1 -1
  10. package/components/pds-button2.js +1 -1
  11. package/components/pds-checkbox2.js +1 -1
  12. package/components/pds-chip2.js +1 -1
  13. package/components/pds-combobox.js +1 -1
  14. package/components/pds-container.js +1 -1
  15. package/components/pds-copytext.js +1 -1
  16. package/components/pds-datepicker.js +1 -1
  17. package/components/pds-divider.js +1 -1
  18. package/components/pds-drawer-content.js +1 -1
  19. package/components/pds-drawer-footer.js +1 -1
  20. package/components/pds-drawer-header.js +1 -1
  21. package/components/pds-drawer.js +1 -1
  22. package/components/pds-dropdown-menu-item.js +1 -1
  23. package/components/pds-dropdown-menu-separator.js +1 -1
  24. package/components/pds-dropdown-menu.js +1 -1
  25. package/components/pds-filter.js +1 -1
  26. package/components/pds-filters.js +1 -1
  27. package/components/pds-icon2.js +1 -1
  28. package/components/pds-image.js +1 -1
  29. package/components/pds-input2.js +1 -1
  30. package/components/pds-link2.js +1 -1
  31. package/components/pds-loader2.js +1 -1
  32. package/components/pds-modal-content.js +1 -1
  33. package/components/pds-modal-footer.js +1 -1
  34. package/components/pds-modal-header.js +1 -1
  35. package/components/pds-modal2.js +1 -1
  36. package/components/pds-multiselect.js +1 -1
  37. package/components/pds-popover.js +1 -1
  38. package/components/pds-progress.js +1 -1
  39. package/components/pds-property.js +1 -1
  40. package/components/pds-radio-group.js +1 -1
  41. package/components/pds-radio.js +1 -1
  42. package/components/pds-row.js +1 -1
  43. package/components/pds-select.js +1 -1
  44. package/components/pds-sortable-item.js +1 -1
  45. package/components/pds-sortable.js +2 -2
  46. package/components/pds-switch.js +1 -1
  47. package/components/pds-table-body.js +1 -1
  48. package/components/pds-table-cell2.js +1 -1
  49. package/components/pds-table-head-cell2.js +1 -1
  50. package/components/pds-table-head.js +1 -1
  51. package/components/pds-table-row.js +1 -1
  52. package/components/pds-tabpanel.js +1 -1
  53. package/components/pds-tabs.js +1 -1
  54. package/components/pds-text2.js +1 -1
  55. package/components/pds-textarea.js +1 -1
  56. package/components/pds-toast.js +1 -1
  57. package/components/pds-tooltip.js +1 -1
  58. package/components/portal-target.js +1 -0
  59. package/components/tabbable.js +1 -0
  60. package/components/truncation-tooltip.js +1 -1
  61. package/dist/cjs/{attributes-BJ7KBHql.js → attributes-CW49XqaL.js} +1 -1
  62. package/dist/cjs/{floating-ui.dom-Dc8Anyel.js → floating-ui.dom-Dw41zbyY.js} +1 -0
  63. package/dist/cjs/{index-Do70atou.js → index-BDnbr0DK.js} +1 -1
  64. package/dist/cjs/{index-jl_Q819j.js → index-D9iJuJCP.js} +13 -1
  65. package/dist/cjs/index.cjs.js +1 -1
  66. package/dist/cjs/{keep-hydrated-CiXgkEYd.js → keep-hydrated-AKoh0DG4.js} +1 -0
  67. package/dist/cjs/loader.cjs.js +3 -3
  68. package/dist/cjs/mock-pds-modal.cjs.entry.js +4 -4
  69. package/dist/cjs/pds-accordion.cjs.entry.js +3 -3
  70. package/dist/cjs/pds-alert.cjs.entry.js +17 -4
  71. package/dist/cjs/pds-avatar.cjs.entry.js +22 -12
  72. package/dist/cjs/pds-box.cjs.entry.js +4 -4
  73. package/dist/cjs/pds-button.cjs.entry.js +58 -26
  74. package/dist/cjs/pds-checkbox.cjs.entry.js +16 -8
  75. package/dist/cjs/pds-chip.cjs.entry.js +9 -11
  76. package/dist/cjs/pds-combobox.cjs.entry.js +41 -11
  77. package/dist/cjs/pds-container.cjs.entry.js +3 -3
  78. package/dist/cjs/pds-copytext.cjs.entry.js +8 -7
  79. package/dist/cjs/pds-datepicker.cjs.entry.js +8 -45
  80. package/dist/cjs/pds-divider.cjs.entry.js +3 -3
  81. package/dist/cjs/pds-drawer-content.cjs.entry.js +3 -3
  82. package/dist/cjs/pds-drawer-footer.cjs.entry.js +3 -3
  83. package/dist/cjs/pds-drawer-header.cjs.entry.js +3 -3
  84. package/dist/cjs/pds-drawer.cjs.entry.js +4 -4
  85. package/dist/cjs/pds-dropdown-menu-item.cjs.entry.js +4 -4
  86. package/dist/cjs/pds-dropdown-menu-separator.cjs.entry.js +3 -3
  87. package/dist/cjs/pds-dropdown-menu.cjs.entry.js +5 -5
  88. package/dist/cjs/pds-filter.cjs.entry.js +4 -4
  89. package/dist/cjs/pds-filters.cjs.entry.js +3 -3
  90. package/dist/cjs/pds-icon.cjs.entry.js +55 -22
  91. package/dist/cjs/pds-image.cjs.entry.js +4 -4
  92. package/dist/cjs/pds-input.cjs.entry.js +6 -6
  93. package/dist/cjs/pds-link.cjs.entry.js +16 -7
  94. package/dist/cjs/pds-loader.cjs.entry.js +4 -4
  95. package/dist/cjs/pds-modal-content.cjs.entry.js +4 -4
  96. package/dist/cjs/pds-modal-footer.cjs.entry.js +3 -3
  97. package/dist/cjs/pds-modal-header.cjs.entry.js +3 -3
  98. package/dist/cjs/pds-modal.cjs.entry.js +9 -89
  99. package/dist/cjs/pds-multiselect.cjs.entry.js +13 -7
  100. package/dist/cjs/pds-popover.cjs.entry.js +230 -153
  101. package/dist/cjs/pds-progress.cjs.entry.js +4 -4
  102. package/dist/cjs/pds-property.cjs.entry.js +3 -3
  103. package/dist/cjs/pds-radio-group.cjs.entry.js +67 -6
  104. package/dist/cjs/pds-radio.cjs.entry.js +24 -11
  105. package/dist/cjs/pds-row.cjs.entry.js +4 -4
  106. package/dist/cjs/pds-select.cjs.entry.js +132 -21
  107. package/dist/cjs/pds-sortable-item.cjs.entry.js +5 -5
  108. package/dist/cjs/pds-sortable.cjs.entry.js +4 -4
  109. package/dist/cjs/pds-switch.cjs.entry.js +7 -7
  110. package/dist/cjs/pds-tab.cjs.entry.js +3 -3
  111. package/dist/cjs/pds-table-body.cjs.entry.js +3 -3
  112. package/dist/cjs/pds-table-cell.cjs.entry.js +7 -6
  113. package/dist/cjs/pds-table-head-cell.cjs.entry.js +5 -5
  114. package/dist/cjs/pds-table-head.cjs.entry.js +3 -3
  115. package/dist/cjs/pds-table-row.cjs.entry.js +3 -3
  116. package/dist/cjs/pds-table.cjs.entry.js +2 -2
  117. package/dist/cjs/pds-tabpanel.cjs.entry.js +4 -4
  118. package/dist/cjs/pds-tabs.cjs.entry.js +4 -4
  119. package/dist/cjs/pds-text.cjs.entry.js +31 -5
  120. package/dist/cjs/pds-textarea.cjs.entry.js +8 -8
  121. package/dist/cjs/pds-toast.cjs.entry.js +14 -8
  122. package/dist/cjs/pds-tooltip.cjs.entry.js +128 -46
  123. package/dist/cjs/pine-core.cjs.js +3 -3
  124. package/dist/cjs/portal-target-e8WQ6dLx.js +70 -0
  125. package/dist/cjs/tabbable-BrrrGvdG.js +86 -0
  126. package/dist/cjs/{truncation-tooltip-BtuiXLV0.js → truncation-tooltip-DdB78RIe.js} +44 -4
  127. package/dist/collection/components/pds-alert/pds-alert.css +13 -0
  128. package/dist/collection/components/pds-alert/pds-alert.js +36 -1
  129. package/dist/collection/components/pds-alert/stories/pds-alert.stories.js +4 -0
  130. package/dist/collection/components/pds-avatar/pds-avatar.js +41 -9
  131. package/dist/collection/components/pds-avatar/stories/pds-avatar.stories.js +2 -0
  132. package/dist/collection/components/pds-box/pds-box.js +1 -1
  133. package/dist/collection/components/pds-button/pds-button.js +13 -23
  134. package/dist/collection/components/pds-checkbox/pds-checkbox.css +79 -0
  135. package/dist/collection/components/pds-checkbox/pds-checkbox.js +36 -5
  136. package/dist/collection/components/pds-checkbox/stories/pds-checkbox.stories.js +38 -0
  137. package/dist/collection/components/pds-chip/pds-chip.js +2 -5
  138. package/dist/collection/components/pds-combobox/pds-combobox.css +33 -0
  139. package/dist/collection/components/pds-combobox/pds-combobox.js +60 -7
  140. package/dist/collection/components/pds-combobox/stories/pds-combobox.stories.js +44 -0
  141. package/dist/collection/components/pds-container/pds-container.js +1 -1
  142. package/dist/collection/components/pds-copytext/pds-copytext.js +1 -1
  143. package/dist/collection/components/pds-datepicker/calendar-portal.js +1 -38
  144. package/dist/collection/components/pds-datepicker/pds-datepicker.js +2 -2
  145. package/dist/collection/components/pds-divider/pds-divider.js +1 -1
  146. package/dist/collection/components/pds-drawer/pds-drawer-content/pds-drawer-content.js +1 -1
  147. package/dist/collection/components/pds-drawer/pds-drawer-footer/pds-drawer-footer.js +1 -1
  148. package/dist/collection/components/pds-drawer/pds-drawer-header/pds-drawer-header.js +1 -1
  149. package/dist/collection/components/pds-drawer/pds-drawer.js +2 -2
  150. package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.js +24 -2
  151. package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-separator/pds-dropdown-menu-separator.js +1 -1
  152. package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu.js +1 -1
  153. package/dist/collection/components/pds-filters/pds-filter/pds-filter.js +1 -1
  154. package/dist/collection/components/pds-filters/pds-filters.js +1 -1
  155. package/dist/collection/components/pds-image/pds-image.js +2 -2
  156. package/dist/collection/components/pds-input/pds-input.js +2 -2
  157. package/dist/collection/components/pds-input/stories/pds-input.stories.js +6 -6
  158. package/dist/collection/components/pds-link/pds-link.css +1 -1
  159. package/dist/collection/components/pds-link/pds-link.js +34 -3
  160. package/dist/collection/components/pds-link/stories/pds-link.stories.js +51 -2
  161. package/dist/collection/components/pds-loader/pds-loader.js +1 -1
  162. package/dist/collection/components/pds-modal/pds-modal-content/pds-modal-content.js +2 -2
  163. package/dist/collection/components/pds-modal/pds-modal-footer/pds-modal-footer.js +1 -1
  164. package/dist/collection/components/pds-modal/pds-modal-header/pds-modal-header.js +1 -1
  165. package/dist/collection/components/pds-modal/pds-modal.css +1 -1
  166. package/dist/collection/components/pds-modal/pds-modal.js +4 -84
  167. package/dist/collection/components/pds-modal/test/mock-pds-modal.js +1 -1
  168. package/dist/collection/components/pds-multiselect/pds-multiselect.js +9 -3
  169. package/dist/collection/components/pds-popover/pds-popover.css +6 -0
  170. package/dist/collection/components/pds-popover/pds-popover.js +226 -149
  171. package/dist/collection/components/pds-progress/pds-progress.js +1 -1
  172. package/dist/collection/components/pds-property/pds-property.js +1 -1
  173. package/dist/collection/components/pds-radio/pds-radio.css +57 -0
  174. package/dist/collection/components/pds-radio/pds-radio.js +45 -9
  175. package/dist/collection/components/pds-radio/stories/pds-radio.stories.js +15 -0
  176. package/dist/collection/components/pds-radio-group/pds-radio-group.js +65 -4
  177. package/dist/collection/components/pds-radio-group/stories/pds-radio-group.stories.js +45 -0
  178. package/dist/collection/components/pds-row/pds-row.js +1 -1
  179. package/dist/collection/components/pds-select/pds-select.js +128 -17
  180. package/dist/collection/components/pds-select/stories/pds-select.stories.js +2 -2
  181. package/dist/collection/components/pds-sortable/pds-sortable-item/pds-sortable-item.js +1 -1
  182. package/dist/collection/components/pds-sortable/pds-sortable.js +1 -1
  183. package/dist/collection/components/pds-switch/pds-switch.js +3 -3
  184. package/dist/collection/components/pds-table/pds-table-body/pds-table-body.js +1 -1
  185. package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.js +2 -2
  186. package/dist/collection/components/pds-table/pds-table-head/pds-table-head.js +1 -1
  187. package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.js +2 -2
  188. package/dist/collection/components/pds-table/pds-table-row/pds-table-row.js +1 -1
  189. package/dist/collection/components/pds-table/stories/pds-table.stories.js +3 -3
  190. package/dist/collection/components/pds-tabs/pds-tabpanel/pds-tabpanel.js +1 -1
  191. package/dist/collection/components/pds-tabs/pds-tabs.js +1 -1
  192. package/dist/collection/components/pds-text/pds-text.js +28 -3
  193. package/dist/collection/components/pds-text/stories/pds-text.stories.js +16 -0
  194. package/dist/collection/components/pds-textarea/pds-textarea.js +4 -4
  195. package/dist/collection/components/pds-textarea/stories/pds-textarea.stories.js +2 -2
  196. package/dist/collection/components/pds-toast/pds-toast.css +13 -0
  197. package/dist/collection/components/pds-toast/pds-toast.js +33 -5
  198. package/dist/collection/components/pds-toast/stories/pds-toast.stories.js +4 -1
  199. package/dist/collection/components/pds-tooltip/pds-tooltip.css +11 -0
  200. package/dist/collection/components/pds-tooltip/pds-tooltip.js +125 -42
  201. package/dist/collection/components/pds-tooltip/stories/pds-tooltip.stories.js +30 -0
  202. package/dist/collection/utils/aria-references.js +42 -0
  203. package/dist/collection/utils/portal-target.js +64 -0
  204. package/dist/collection/utils/tabbable.js +82 -0
  205. package/dist/collection/utils/truncation-tooltip.js +42 -3
  206. package/dist/docs.json +245 -8
  207. package/dist/esm/{attributes-WXw_I_uJ.js → attributes-DkeVeN0g.js} +1 -1
  208. package/dist/esm/{floating-ui.dom-BPqJgIq6.js → floating-ui.dom-Cuc0DYlm.js} +1 -1
  209. package/dist/esm/{index-Cw9J31qd.js → index-4_RRPJTO.js} +13 -2
  210. package/dist/esm/{index-BWDu62Mo.js → index-DvN3tyZp.js} +2 -2
  211. package/dist/esm/index.js +1 -1
  212. package/dist/esm/{keep-hydrated-BLG6RDBt.js → keep-hydrated-BgNaWLoS.js} +1 -1
  213. package/dist/esm/loader.js +4 -4
  214. package/dist/esm/mock-pds-modal.entry.js +4 -4
  215. package/dist/esm/pds-accordion.entry.js +3 -3
  216. package/dist/esm/pds-alert.entry.js +17 -4
  217. package/dist/esm/pds-avatar.entry.js +22 -12
  218. package/dist/esm/pds-box.entry.js +4 -4
  219. package/dist/esm/pds-button.entry.js +58 -26
  220. package/dist/esm/pds-checkbox.entry.js +16 -8
  221. package/dist/esm/pds-chip.entry.js +8 -10
  222. package/dist/esm/pds-combobox.entry.js +41 -11
  223. package/dist/esm/pds-container.entry.js +3 -3
  224. package/dist/esm/pds-copytext.entry.js +8 -7
  225. package/dist/esm/pds-datepicker.entry.js +7 -44
  226. package/dist/esm/pds-divider.entry.js +3 -3
  227. package/dist/esm/pds-drawer-content.entry.js +3 -3
  228. package/dist/esm/pds-drawer-footer.entry.js +3 -3
  229. package/dist/esm/pds-drawer-header.entry.js +3 -3
  230. package/dist/esm/pds-drawer.entry.js +4 -4
  231. package/dist/esm/pds-dropdown-menu-item.entry.js +4 -4
  232. package/dist/esm/pds-dropdown-menu-separator.entry.js +3 -3
  233. package/dist/esm/pds-dropdown-menu.entry.js +5 -5
  234. package/dist/esm/pds-filter.entry.js +4 -4
  235. package/dist/esm/pds-filters.entry.js +3 -3
  236. package/dist/esm/pds-icon.entry.js +55 -22
  237. package/dist/esm/pds-image.entry.js +4 -4
  238. package/dist/esm/pds-input.entry.js +6 -6
  239. package/dist/esm/pds-link.entry.js +16 -7
  240. package/dist/esm/pds-loader.entry.js +4 -4
  241. package/dist/esm/pds-modal-content.entry.js +4 -4
  242. package/dist/esm/pds-modal-footer.entry.js +3 -3
  243. package/dist/esm/pds-modal-header.entry.js +3 -3
  244. package/dist/esm/pds-modal.entry.js +7 -87
  245. package/dist/esm/pds-multiselect.entry.js +13 -7
  246. package/dist/esm/pds-popover.entry.js +230 -153
  247. package/dist/esm/pds-progress.entry.js +4 -4
  248. package/dist/esm/pds-property.entry.js +3 -3
  249. package/dist/esm/pds-radio-group.entry.js +67 -6
  250. package/dist/esm/pds-radio.entry.js +24 -11
  251. package/dist/esm/pds-row.entry.js +4 -4
  252. package/dist/esm/pds-select.entry.js +132 -21
  253. package/dist/esm/pds-sortable-item.entry.js +5 -5
  254. package/dist/esm/pds-sortable.entry.js +4 -4
  255. package/dist/esm/pds-switch.entry.js +7 -7
  256. package/dist/esm/pds-tab.entry.js +3 -3
  257. package/dist/esm/pds-table-body.entry.js +3 -3
  258. package/dist/esm/pds-table-cell.entry.js +7 -6
  259. package/dist/esm/pds-table-head-cell.entry.js +5 -5
  260. package/dist/esm/pds-table-head.entry.js +3 -3
  261. package/dist/esm/pds-table-row.entry.js +3 -3
  262. package/dist/esm/pds-table.entry.js +2 -2
  263. package/dist/esm/pds-tabpanel.entry.js +4 -4
  264. package/dist/esm/pds-tabs.entry.js +4 -4
  265. package/dist/esm/pds-text.entry.js +31 -5
  266. package/dist/esm/pds-textarea.entry.js +8 -8
  267. package/dist/esm/pds-toast.entry.js +14 -8
  268. package/dist/esm/pds-tooltip.entry.js +128 -46
  269. package/dist/esm/pine-core.js +4 -4
  270. package/dist/esm/portal-target-CKRzRKdO.js +66 -0
  271. package/dist/esm/tabbable-C6ZWpp3v.js +84 -0
  272. package/dist/esm/{truncation-tooltip-FaW67DiY.js → truncation-tooltip-CRSdYzpA.js} +44 -5
  273. package/dist/esm-es5/{attributes-WXw_I_uJ.js → attributes-DkeVeN0g.js} +1 -1
  274. package/dist/esm-es5/{floating-ui.dom-BPqJgIq6.js → floating-ui.dom-Cuc0DYlm.js} +1 -1
  275. package/dist/esm-es5/{index-Cw9J31qd.js → index-4_RRPJTO.js} +2 -2
  276. package/dist/esm-es5/{index-BWDu62Mo.js → index-DvN3tyZp.js} +1 -1
  277. package/dist/esm-es5/index.js +1 -1
  278. package/dist/esm-es5/{keep-hydrated-BLG6RDBt.js → keep-hydrated-BgNaWLoS.js} +1 -1
  279. package/dist/esm-es5/loader.js +1 -1
  280. package/dist/esm-es5/mock-pds-modal.entry.js +1 -1
  281. package/dist/esm-es5/pds-accordion.entry.js +1 -1
  282. package/dist/esm-es5/pds-alert.entry.js +1 -1
  283. package/dist/esm-es5/pds-avatar.entry.js +1 -1
  284. package/dist/esm-es5/pds-box.entry.js +1 -1
  285. package/dist/esm-es5/pds-button.entry.js +1 -1
  286. package/dist/esm-es5/pds-checkbox.entry.js +1 -1
  287. package/dist/esm-es5/pds-chip.entry.js +1 -1
  288. package/dist/esm-es5/pds-combobox.entry.js +2 -2
  289. package/dist/esm-es5/pds-container.entry.js +1 -1
  290. package/dist/esm-es5/pds-copytext.entry.js +1 -1
  291. package/dist/esm-es5/pds-datepicker.entry.js +1 -1
  292. package/dist/esm-es5/pds-divider.entry.js +1 -1
  293. package/dist/esm-es5/pds-drawer-content.entry.js +1 -1
  294. package/dist/esm-es5/pds-drawer-footer.entry.js +1 -1
  295. package/dist/esm-es5/pds-drawer-header.entry.js +1 -1
  296. package/dist/esm-es5/pds-drawer.entry.js +1 -1
  297. package/dist/esm-es5/pds-dropdown-menu-item.entry.js +1 -1
  298. package/dist/esm-es5/pds-dropdown-menu-separator.entry.js +1 -1
  299. package/dist/esm-es5/pds-dropdown-menu.entry.js +1 -1
  300. package/dist/esm-es5/pds-filter.entry.js +1 -1
  301. package/dist/esm-es5/pds-filters.entry.js +1 -1
  302. package/dist/esm-es5/pds-icon.entry.js +1 -1
  303. package/dist/esm-es5/pds-image.entry.js +1 -1
  304. package/dist/esm-es5/pds-input.entry.js +1 -1
  305. package/dist/esm-es5/pds-link.entry.js +1 -1
  306. package/dist/esm-es5/pds-loader.entry.js +1 -1
  307. package/dist/esm-es5/pds-modal-content.entry.js +1 -1
  308. package/dist/esm-es5/pds-modal-footer.entry.js +1 -1
  309. package/dist/esm-es5/pds-modal-header.entry.js +1 -1
  310. package/dist/esm-es5/pds-modal.entry.js +1 -1
  311. package/dist/esm-es5/pds-multiselect.entry.js +1 -1
  312. package/dist/esm-es5/pds-popover.entry.js +1 -1
  313. package/dist/esm-es5/pds-progress.entry.js +1 -1
  314. package/dist/esm-es5/pds-property.entry.js +1 -1
  315. package/dist/esm-es5/pds-radio-group.entry.js +1 -1
  316. package/dist/esm-es5/pds-radio.entry.js +1 -1
  317. package/dist/esm-es5/pds-row.entry.js +1 -1
  318. package/dist/esm-es5/pds-select.entry.js +1 -1
  319. package/dist/esm-es5/pds-sortable-item.entry.js +1 -1
  320. package/dist/esm-es5/pds-sortable.entry.js +2 -2
  321. package/dist/esm-es5/pds-switch.entry.js +1 -1
  322. package/dist/esm-es5/pds-tab.entry.js +1 -1
  323. package/dist/esm-es5/pds-table-body.entry.js +1 -1
  324. package/dist/esm-es5/pds-table-cell.entry.js +1 -1
  325. package/dist/esm-es5/pds-table-head-cell.entry.js +1 -1
  326. package/dist/esm-es5/pds-table-head.entry.js +1 -1
  327. package/dist/esm-es5/pds-table-row.entry.js +1 -1
  328. package/dist/esm-es5/pds-table.entry.js +1 -1
  329. package/dist/esm-es5/pds-tabpanel.entry.js +1 -1
  330. package/dist/esm-es5/pds-tabs.entry.js +1 -1
  331. package/dist/esm-es5/pds-text.entry.js +1 -1
  332. package/dist/esm-es5/pds-textarea.entry.js +1 -1
  333. package/dist/esm-es5/pds-toast.entry.js +1 -1
  334. package/dist/esm-es5/pds-tooltip.entry.js +1 -1
  335. package/dist/esm-es5/pine-core.js +1 -1
  336. package/dist/esm-es5/portal-target-CKRzRKdO.js +1 -0
  337. package/dist/esm-es5/tabbable-C6ZWpp3v.js +1 -0
  338. package/dist/esm-es5/truncation-tooltip-CRSdYzpA.js +1 -0
  339. package/dist/pine-core/index.esm.js +1 -1
  340. package/dist/pine-core/{p-9880d251.system.entry.js → p-01f1cdaf.system.entry.js} +1 -1
  341. package/dist/pine-core/{p-138b278b.entry.js → p-07323107.entry.js} +1 -1
  342. package/dist/pine-core/p-08b8e941.entry.js +1 -0
  343. package/dist/pine-core/p-0d5f0ab5.system.entry.js +1 -0
  344. package/dist/pine-core/{p-8c8cc079.system.entry.js → p-1415c988.system.entry.js} +1 -1
  345. package/dist/pine-core/{p-9109b90a.entry.js → p-143b33a6.entry.js} +1 -1
  346. package/dist/pine-core/{p-b9d145f8.system.entry.js → p-14dedf01.system.entry.js} +1 -1
  347. package/dist/pine-core/{p-80e6f3a0.system.entry.js → p-19cf1d91.system.entry.js} +1 -1
  348. package/dist/pine-core/p-1ca8d183.entry.js +1 -0
  349. package/dist/pine-core/p-1cc39908.system.entry.js +1 -0
  350. package/dist/pine-core/p-1e3ef425.entry.js +1 -0
  351. package/dist/pine-core/{p-b914dde8.entry.js → p-1f62bb71.entry.js} +2 -2
  352. package/dist/pine-core/p-20079552.system.entry.js +1 -0
  353. package/dist/pine-core/p-2a18852f.entry.js +1 -0
  354. package/dist/pine-core/{p-ca4ee736.system.entry.js → p-2b9622c1.system.entry.js} +1 -1
  355. package/dist/pine-core/p-2dd30d12.entry.js +1 -0
  356. package/dist/pine-core/{p-cccfe60f.system.entry.js → p-3306dc5a.system.entry.js} +1 -1
  357. package/dist/pine-core/{p-BGLP3keB.js → p-35s7h-dk.js} +1 -1
  358. package/dist/pine-core/{p-8c588ca0.entry.js → p-3610cb3b.entry.js} +1 -1
  359. package/dist/pine-core/p-37718637.entry.js +1 -0
  360. package/dist/pine-core/p-383d84f4.entry.js +2 -0
  361. package/dist/pine-core/p-39276663.entry.js +1 -0
  362. package/dist/pine-core/{p-62433f32.entry.js → p-39e57657.entry.js} +1 -1
  363. package/dist/pine-core/p-3c229091.entry.js +1 -0
  364. package/dist/pine-core/p-3d34b967.system.entry.js +1 -0
  365. package/dist/pine-core/p-3e30a761.entry.js +1 -0
  366. package/dist/pine-core/{p-7a5b21d2.system.entry.js → p-3f8bd3fb.system.entry.js} +1 -1
  367. package/dist/pine-core/p-42d43c3f.system.entry.js +1 -0
  368. package/dist/pine-core/{p-f029b7da.system.entry.js → p-42f70f93.system.entry.js} +1 -1
  369. package/dist/pine-core/{p-d3d69ca4.system.entry.js → p-4a90b9c8.system.entry.js} +1 -1
  370. package/dist/pine-core/{p-ca0a8f5c.entry.js → p-4cfe922b.entry.js} +1 -1
  371. package/dist/pine-core/p-4d1a8803.entry.js +1 -0
  372. package/dist/pine-core/p-4d47023c.system.entry.js +1 -0
  373. package/dist/pine-core/p-4d98bc0c.system.entry.js +1 -0
  374. package/dist/pine-core/{p-c97bfac9.entry.js → p-50ddadbf.entry.js} +1 -1
  375. package/dist/pine-core/{p-0913f696.system.entry.js → p-548bce53.system.entry.js} +1 -1
  376. package/dist/pine-core/p-54f1e86f.system.entry.js +1 -0
  377. package/dist/pine-core/{p-631f5bcc.entry.js → p-590df41a.entry.js} +1 -1
  378. package/dist/pine-core/p-5946203c.entry.js +1 -0
  379. package/dist/pine-core/{p-11d98408.system.entry.js → p-5f181694.system.entry.js} +1 -1
  380. package/dist/pine-core/p-60a30975.system.entry.js +1 -0
  381. package/dist/pine-core/{p-9ab95438.entry.js → p-61cfdbb2.entry.js} +1 -1
  382. package/dist/pine-core/p-62aa6a78.system.entry.js +1 -0
  383. package/dist/pine-core/{p-ecc7a531.system.entry.js → p-63f85859.system.entry.js} +1 -1
  384. package/dist/pine-core/p-64bcb378.entry.js +1 -0
  385. package/dist/pine-core/{p-bdac8f2b.entry.js → p-67999353.entry.js} +1 -1
  386. package/dist/pine-core/{p-cb6a3e4c.system.entry.js → p-67f795d5.system.entry.js} +1 -1
  387. package/dist/pine-core/p-6a1aa8d3.entry.js +1 -0
  388. package/dist/pine-core/p-6f4ab1ea.system.entry.js +1 -0
  389. package/dist/pine-core/{p-acca5f7b.system.entry.js → p-724baba3.system.entry.js} +1 -1
  390. package/dist/pine-core/p-72659a0e.system.entry.js +1 -0
  391. package/dist/pine-core/{p-4bfc8b3e.system.entry.js → p-73efb1ed.system.entry.js} +1 -1
  392. package/dist/pine-core/p-7a51f15e.entry.js +1 -0
  393. package/dist/pine-core/p-7b978fff.system.entry.js +1 -0
  394. package/dist/pine-core/p-8436cbfb.entry.js +1 -0
  395. package/dist/pine-core/p-849ec281.system.entry.js +1 -0
  396. package/dist/pine-core/p-87a32ded.system.entry.js +1 -0
  397. package/dist/pine-core/p-89d38a82.system.entry.js +1 -0
  398. package/dist/pine-core/p-8ade17ce.entry.js +1 -0
  399. package/dist/pine-core/{p-4d03d1e2.system.entry.js → p-8afd5f5b.system.entry.js} +1 -1
  400. package/dist/pine-core/p-8e7f75e6.entry.js +1 -0
  401. package/dist/pine-core/{p-8f531063.entry.js → p-8fb520df.entry.js} +1 -1
  402. package/dist/pine-core/{p-9df5e204.entry.js → p-92115e88.entry.js} +1 -1
  403. package/dist/pine-core/p-93fd7dd8.system.entry.js +1 -0
  404. package/dist/pine-core/p-947582e1.entry.js +1 -0
  405. package/dist/pine-core/{p-2ac2457b.system.entry.js → p-94c9b7d1.system.entry.js} +1 -1
  406. package/dist/pine-core/p-973c3ac0.entry.js +1 -0
  407. package/dist/pine-core/p-97653e60.entry.js +1 -0
  408. package/dist/pine-core/{p-55224683.entry.js → p-97b73359.entry.js} +1 -1
  409. package/dist/pine-core/{p-b1548a20.entry.js → p-99530cb5.entry.js} +1 -1
  410. package/dist/pine-core/p-9a776443.entry.js +1 -0
  411. package/dist/pine-core/p-9b32727a.system.entry.js +1 -0
  412. package/dist/pine-core/{p-CGRdQc49.system.js → p-BK1sLRfg.system.js} +2 -2
  413. package/dist/pine-core/{p-COtCa1Md.system.js → p-BNTlHhoO.system.js} +1 -1
  414. package/dist/pine-core/p-BZ1l3LGl.system.js +1 -0
  415. package/dist/pine-core/p-BgNaWLoS.js +1 -0
  416. package/dist/pine-core/p-C6ZWpp3v.js +1 -0
  417. package/dist/pine-core/{p-Cy8cvR7I.system.js → p-CANeE7Ss.system.js} +1 -1
  418. package/dist/pine-core/p-CKRzRKdO.js +1 -0
  419. package/dist/pine-core/{p-XW4H0W6i.system.js → p-CNXspDYs.system.js} +1 -1
  420. package/dist/pine-core/{p-BPqJgIq6.js → p-Cuc0DYlm.js} +1 -1
  421. package/dist/pine-core/p-DQyF6v9Q.system.js +1 -0
  422. package/dist/pine-core/{p-BWDu62Mo.js → p-DvN3tyZp.js} +1 -1
  423. package/dist/pine-core/p-DwQ5Tjis.js +1 -0
  424. package/dist/pine-core/{p-CmSJytt1.js → p-M31tvpDN.js} +2 -2
  425. package/dist/pine-core/p-XK45dzWR.system.js +1 -0
  426. package/dist/pine-core/{p-1dc5a7e0.system.entry.js → p-a09c9c5e.system.entry.js} +1 -1
  427. package/dist/pine-core/p-a4ce12ef.entry.js +1 -0
  428. package/dist/pine-core/{p-57a2f927.entry.js → p-a594c41f.entry.js} +1 -1
  429. package/dist/pine-core/p-a9d96e22.entry.js +1 -0
  430. package/dist/pine-core/{p-047433a4.system.entry.js → p-ad5208a4.system.entry.js} +1 -1
  431. package/dist/pine-core/p-b3d4f97a.system.entry.js +3 -0
  432. package/dist/pine-core/{p-0b71ecb6.system.entry.js → p-bcc378ba.system.entry.js} +2 -2
  433. package/dist/pine-core/p-bd7dc317.system.entry.js +1 -0
  434. package/dist/pine-core/p-beb7a430.entry.js +1 -0
  435. package/dist/pine-core/p-bfa34194.entry.js +1 -0
  436. package/dist/pine-core/{p-5870b092.system.entry.js → p-c2afe4f3.system.entry.js} +1 -1
  437. package/dist/pine-core/p-c5e1eb3c.system.entry.js +1 -0
  438. package/dist/pine-core/p-c7a53c4f.entry.js +1 -0
  439. package/dist/pine-core/{p-5cfd4d41.system.entry.js → p-c8a0b562.system.entry.js} +1 -1
  440. package/dist/pine-core/{p-f1702281.entry.js → p-c9ae7964.entry.js} +1 -1
  441. package/dist/pine-core/{p-db17c626.system.entry.js → p-cb9baf78.system.entry.js} +1 -1
  442. package/dist/pine-core/{p-e5420660.entry.js → p-ce9fa14b.entry.js} +1 -1
  443. package/dist/pine-core/{p-332590c7.system.entry.js → p-d018dc60.system.entry.js} +1 -1
  444. package/dist/pine-core/p-d47b2a6a.system.entry.js +1 -0
  445. package/dist/pine-core/{p-b75b0d09.system.entry.js → p-d48fe5a0.system.entry.js} +1 -1
  446. package/dist/pine-core/p-d6f338e0.entry.js +1 -0
  447. package/dist/pine-core/{p-8191498f.system.entry.js → p-d920d759.system.entry.js} +1 -1
  448. package/dist/pine-core/{p-26642718.entry.js → p-d9719e37.entry.js} +1 -1
  449. package/dist/pine-core/{p-c483997a.entry.js → p-db7fb5a3.entry.js} +1 -1
  450. package/dist/pine-core/{p-9713fb36.entry.js → p-e1d1b5d8.entry.js} +1 -1
  451. package/dist/pine-core/p-e3de6a1d.entry.js +1 -0
  452. package/dist/pine-core/{p-d2c91e7a.entry.js → p-e7002cee.entry.js} +1 -1
  453. package/dist/pine-core/{p-86040cac.system.entry.js → p-e82f758f.system.entry.js} +1 -1
  454. package/dist/pine-core/p-e84fa9ed.entry.js +1 -0
  455. package/dist/pine-core/{p-ee0e30bf.system.entry.js → p-eb4f0daa.system.entry.js} +1 -1
  456. package/dist/pine-core/p-eeYeEogd.system.js +1 -0
  457. package/dist/pine-core/{p-0af0d752.system.entry.js → p-eecd9ad8.system.entry.js} +1 -1
  458. package/dist/pine-core/p-ef0eba9b.system.entry.js +1 -0
  459. package/dist/pine-core/p-ef3a855f.system.entry.js +1 -0
  460. package/dist/pine-core/{p-717323e4.entry.js → p-f018af99.entry.js} +1 -1
  461. package/dist/pine-core/{p-121612a7.system.entry.js → p-f11cce27.system.entry.js} +1 -1
  462. package/dist/pine-core/{p-4fd454f6.entry.js → p-f6f4fd42.entry.js} +1 -1
  463. package/dist/pine-core/{p-a939b471.entry.js → p-f71d71ca.entry.js} +1 -1
  464. package/dist/pine-core/p-f9063262.system.entry.js +1 -0
  465. package/dist/pine-core/p-f99bd77f.entry.js +1 -0
  466. package/dist/pine-core/{p-ClDiSG97.system.js → p-vFsJv75D.system.js} +1 -1
  467. package/dist/pine-core/p-wB2y8gR7.system.js +1 -0
  468. package/dist/pine-core/pine-core.esm.js +1 -1
  469. package/dist/pine-core/pine-core.js +1 -1
  470. package/dist/types/components/pds-alert/pds-alert.d.ts +10 -0
  471. package/dist/types/components/pds-avatar/pds-avatar.d.ts +8 -0
  472. package/dist/types/components/pds-button/pds-button.d.ts +2 -2
  473. package/dist/types/components/pds-checkbox/pds-checkbox.d.ts +7 -1
  474. package/dist/types/components/pds-combobox/pds-combobox.d.ts +9 -0
  475. package/dist/types/components/pds-datepicker/calendar-portal.d.ts +0 -7
  476. package/dist/types/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.d.ts +7 -0
  477. package/dist/types/components/pds-link/pds-link.d.ts +8 -0
  478. package/dist/types/components/pds-popover/pds-popover.d.ts +44 -20
  479. package/dist/types/components/pds-radio/pds-radio.d.ts +9 -3
  480. package/dist/types/components/pds-radio-group/pds-radio-group.d.ts +8 -0
  481. package/dist/types/components/pds-select/pds-select.d.ts +32 -4
  482. package/dist/types/components/pds-text/pds-text.d.ts +4 -0
  483. package/dist/types/components/pds-toast/pds-toast.d.ts +9 -0
  484. package/dist/types/components/pds-tooltip/pds-tooltip.d.ts +32 -0
  485. package/dist/types/components.d.ts +98 -10
  486. package/dist/types/utils/aria-references.d.ts +24 -0
  487. package/dist/types/utils/portal-target.d.ts +17 -0
  488. package/dist/types/utils/tabbable.d.ts +2 -0
  489. package/dist/types/utils/truncation-tooltip.d.ts +5 -2
  490. package/dist/vscode.html-data.json +82 -10
  491. package/hydrate/index.js +971 -408
  492. package/hydrate/index.mjs +971 -408
  493. package/package.json +2 -2
  494. package/dist/esm-es5/truncation-tooltip-FaW67DiY.js +0 -1
  495. package/dist/pine-core/p-0092444c.system.entry.js +0 -1
  496. package/dist/pine-core/p-00a50de5.system.entry.js +0 -3
  497. package/dist/pine-core/p-049f126a.entry.js +0 -1
  498. package/dist/pine-core/p-089c3e60.entry.js +0 -1
  499. package/dist/pine-core/p-158b2f51.entry.js +0 -1
  500. package/dist/pine-core/p-17f97f1a.entry.js +0 -1
  501. package/dist/pine-core/p-19ba2788.system.entry.js +0 -1
  502. package/dist/pine-core/p-208c7dbf.entry.js +0 -1
  503. package/dist/pine-core/p-25ea48d1.entry.js +0 -1
  504. package/dist/pine-core/p-295f64ea.entry.js +0 -1
  505. package/dist/pine-core/p-29cd4113.system.entry.js +0 -1
  506. package/dist/pine-core/p-2cb5483a.system.entry.js +0 -1
  507. package/dist/pine-core/p-36cb4bf6.entry.js +0 -1
  508. package/dist/pine-core/p-3c977d8d.system.entry.js +0 -1
  509. package/dist/pine-core/p-3d51891a.entry.js +0 -1
  510. package/dist/pine-core/p-432d5ec7.entry.js +0 -1
  511. package/dist/pine-core/p-44f546ae.entry.js +0 -1
  512. package/dist/pine-core/p-5442d983.system.entry.js +0 -1
  513. package/dist/pine-core/p-5833a072.system.entry.js +0 -1
  514. package/dist/pine-core/p-602c197f.entry.js +0 -1
  515. package/dist/pine-core/p-719542e1.system.entry.js +0 -1
  516. package/dist/pine-core/p-73f931a1.entry.js +0 -1
  517. package/dist/pine-core/p-75ee0403.entry.js +0 -1
  518. package/dist/pine-core/p-77395d62.system.entry.js +0 -1
  519. package/dist/pine-core/p-7a287635.system.entry.js +0 -1
  520. package/dist/pine-core/p-875b0436.system.entry.js +0 -1
  521. package/dist/pine-core/p-884cb31d.system.entry.js +0 -1
  522. package/dist/pine-core/p-8987fd45.system.entry.js +0 -1
  523. package/dist/pine-core/p-8cc302aa.system.entry.js +0 -1
  524. package/dist/pine-core/p-8e3ff75d.entry.js +0 -1
  525. package/dist/pine-core/p-90d5edc6.entry.js +0 -1
  526. package/dist/pine-core/p-91f60173.entry.js +0 -1
  527. package/dist/pine-core/p-9265497e.system.entry.js +0 -1
  528. package/dist/pine-core/p-94593f20.system.entry.js +0 -1
  529. package/dist/pine-core/p-99459e27.entry.js +0 -1
  530. package/dist/pine-core/p-99fdf70f.entry.js +0 -1
  531. package/dist/pine-core/p-9aaedded.entry.js +0 -1
  532. package/dist/pine-core/p-9dcd2cdb.entry.js +0 -1
  533. package/dist/pine-core/p-BLG6RDBt.js +0 -1
  534. package/dist/pine-core/p-BR5nujVX.system.js +0 -1
  535. package/dist/pine-core/p-CuSNnuFu.system.js +0 -1
  536. package/dist/pine-core/p-D04W0cAO.system.js +0 -1
  537. package/dist/pine-core/p-a0960b3d.system.entry.js +0 -1
  538. package/dist/pine-core/p-a1230a74.system.entry.js +0 -1
  539. package/dist/pine-core/p-a826f290.entry.js +0 -1
  540. package/dist/pine-core/p-acce8eb2.entry.js +0 -1
  541. package/dist/pine-core/p-aff411d0.entry.js +0 -1
  542. package/dist/pine-core/p-b182f806.entry.js +0 -2
  543. package/dist/pine-core/p-bb68431a.entry.js +0 -1
  544. package/dist/pine-core/p-be9b6e63.system.entry.js +0 -1
  545. package/dist/pine-core/p-bf30dec0.entry.js +0 -1
  546. package/dist/pine-core/p-c4e12f0a.entry.js +0 -1
  547. package/dist/pine-core/p-e0917a26.entry.js +0 -1
  548. package/dist/pine-core/p-e836a041.entry.js +0 -1
  549. package/dist/pine-core/p-ea340c55.system.entry.js +0 -1
  550. package/dist/pine-core/p-ea4d4741.system.entry.js +0 -1
  551. package/dist/pine-core/p-ea8f5d29.entry.js +0 -1
  552. package/dist/pine-core/p-eaf85be6.system.entry.js +0 -1
  553. package/dist/pine-core/p-ef13f665.system.entry.js +0 -1
  554. package/dist/pine-core/p-f3067d90.system.entry.js +0 -1
  555. package/dist/pine-core/p-jrkGLEPe.js +0 -1
@@ -1,15 +1,35 @@
1
1
  import { Host, h } from "@stencil/core";
2
+ import { autoUpdate, computePosition, flip, offset, platform, shift } from "@floating-ui/dom";
2
3
  import { closest, containsComposed } from "../../utils/closest";
3
4
  import { restoreReflectedDefault } from "../../utils/reflected-attribute-default";
4
5
  import { setAttributesIfChanged } from "../../utils/attributes";
5
6
  import { cssEscape } from "../../utils/css";
6
7
  import { limitRestores } from "../../utils/keep-hydrated";
8
+ import { tabbableIn } from "../../utils/tabbable";
7
9
  /** Open popovers that close on Escape, in the order they opened: Escape goes to the last one it applies to. */
8
10
  const popoversTakingEscape = [];
9
11
  /** Hovering the trigger waits this long before opening, so a pointer passing over it doesn't open it. */
10
12
  const HOVER_OPEN_DELAY_MS = 120;
11
13
  /** Leaving the trigger and panel waits this long before closing, which covers the gap between them. */
12
14
  const HOVER_CLOSE_DELAY_MS = 200;
15
+ /**
16
+ * floating-ui reporting viewport coordinates, as `position: fixed` uses without a containing block. Its own
17
+ * containing-block check misses a backdrop filter in WebKit, so handlePopoverPositioning corrects for one itself.
18
+ */
19
+ const viewportPlatform = Object.assign(Object.assign({}, platform), { getOffsetParent: () => window });
20
+ /**
21
+ * Where `top: 0; left: 0` puts a fixed element beside the given one. An empty probe is measured instead of the
22
+ * element, whose own transforms, such as an entrance animation, would otherwise read as part of the offset.
23
+ */
24
+ const containingBlockOrigin = (element) => {
25
+ var _a;
26
+ const probe = document.createElement('div');
27
+ probe.style.cssText = 'all: initial; position: fixed; top: 0; left: 0;';
28
+ (_a = element.parentNode) === null || _a === void 0 ? void 0 : _a.insertBefore(probe, element);
29
+ const { top, left } = probe.getBoundingClientRect();
30
+ probe.remove();
31
+ return { top, left };
32
+ };
13
33
  /** The focused element, followed down through shadow roots to the control that has focus. */
14
34
  function deepActiveElement() {
15
35
  var _a;
@@ -18,6 +38,27 @@ function deepActiveElement() {
18
38
  active = active.shadowRoot.activeElement;
19
39
  return active;
20
40
  }
41
+ /** `node`, or the shadow host it sits in, lifted until it shares a tree with `other` or reaches the document. */
42
+ function liftToTreeOf(node, other) {
43
+ let current = node;
44
+ while (current.getRootNode() !== other.getRootNode() && current.getRootNode() instanceof ShadowRoot) {
45
+ current = current.getRootNode().host;
46
+ }
47
+ return current;
48
+ }
49
+ /**
50
+ * Where `node` sits relative to `ref`, as `compareDocumentPosition` reports it. Whichever of the two
51
+ * is inside a shadow root is lifted to its host first, so a control inside a component compares too.
52
+ */
53
+ function positionAcrossTrees(ref, node) {
54
+ const lifted = liftToTreeOf(node, ref);
55
+ return liftToTreeOf(ref, lifted).compareDocumentPosition(lifted);
56
+ }
57
+ const isPosition = (position, flag) => (position & Node.DOCUMENT_POSITION_DISCONNECTED) === 0 && (position & flag) !== 0;
58
+ /** The popover each panel belongs to, so a popover inside another one's panel can find it. */
59
+ const panelOwners = new WeakMap();
60
+ /** Floating layers Pine components put at the end of the page or of a dialog, as a popover does its panel. */
61
+ const FLOATING_LAYERS = '.pds-popover, .pds-datepicker-calendar-portal, .pds-combobox-dropdown-portal';
21
62
  /**
22
63
  * @slot trigger - The trigger element for the popover
23
64
  * @slot (default) - The content to display inside the popover
@@ -54,14 +95,21 @@ export class PdsPopover {
54
95
  */
55
96
  this.portalEl = null;
56
97
  /**
57
- * Guard to prevent repositioning loops
98
+ * Stops floating-ui's autoUpdate, which repositions the open panel as its trigger or the page moves or resizes
58
99
  */
59
- this.isRepositioning = false;
100
+ this.stopAutoUpdate = null;
60
101
  /**
61
- * Debounce timers for performance optimization
102
+ * Counts positioning runs, so a run that resolves after a newer one started is dropped
62
103
  */
63
- this.scrollDebounceTimer = null;
64
- this.resizeDebounceTimer = null;
104
+ this.positioningRun = 0;
105
+ /**
106
+ * The latest positioning run, which pdsPopoverOpen waits for so the panel's side is set when it fires
107
+ */
108
+ this.positioning = Promise.resolve();
109
+ /**
110
+ * Set while show() waits to emit pdsPopoverOpen, so a hide() in the meantime emits it first
111
+ */
112
+ this.openEventPending = false;
65
113
  /**
66
114
  * Track moved nodes and their placeholders for restoration
67
115
  */
@@ -82,6 +130,18 @@ export class PdsPopover {
82
130
  * How far the pointer was from the panel at its last move after leaving the trigger
83
131
  */
84
132
  this.panelDistance = Infinity;
133
+ /**
134
+ * Stands in for the panel in the Tab order, right after the trigger, while the popover is open
135
+ */
136
+ this.tabGuardEl = null;
137
+ /**
138
+ * Set while focus passes through the guard on its way out of the panel
139
+ */
140
+ this.leavingPanel = false;
141
+ /**
142
+ * The direction of the Tab key being handled, until its default action has run
143
+ */
144
+ this.tabDirection = null;
85
145
  /**
86
146
  * Determines the action that triggers the popover. For manual popovers, the consumer is responsible for toggling this value.
87
147
  * @defaultValue "show"
@@ -135,6 +195,9 @@ export class PdsPopover {
135
195
  else {
136
196
  this.triggerEl = null;
137
197
  }
198
+ // autoUpdate watches the trigger it started with, so an open popover starts it again on the new one.
199
+ if (this.active)
200
+ this.addScrollAndResizeListeners();
138
201
  this.observeTrigger();
139
202
  };
140
203
  /**
@@ -252,6 +315,59 @@ export class PdsPopover {
252
315
  event.stopPropagation();
253
316
  }
254
317
  };
318
+ // At the end of the body or of a dialog, the panel would come last in the Tab order. The guard
319
+ // after the trigger takes its place there, while the panel has a control for it to lead to.
320
+ this.syncTabGuard = (event) => {
321
+ if (event.key !== 'Tab')
322
+ return;
323
+ this.releasePanel();
324
+ this.tabDirection = event.shiftKey ? 'backward' : 'forward';
325
+ setTimeout(this.endTabKey);
326
+ // Read on each Tab, as the panel's content can arrive after it opens.
327
+ const guarding = this.guardedTabbables().length > 0;
328
+ if (this.tabGuardEl != null)
329
+ this.tabGuardEl.tabIndex = guarding ? 0 : -1;
330
+ // Inert for this key press, the panel is reached only through the guard, either way round. A
331
+ // control in another floating layer, such as a nested popover's panel, may move focus back into it.
332
+ const focused = deepActiveElement();
333
+ if (guarding && !containsComposed(this.portalEl, focused) && !closest(FLOATING_LAYERS, focused !== null && focused !== void 0 ? focused : document)) {
334
+ this.portalEl.inert = true;
335
+ }
336
+ };
337
+ this.endTabKey = () => {
338
+ this.tabDirection = null;
339
+ this.releasePanel();
340
+ };
341
+ this.handleTabGuardFocus = (event) => {
342
+ if (this.leavingPanel)
343
+ return;
344
+ // An inert panel's controls aren't tabbable, so the guard would find none to send focus to.
345
+ this.releasePanel();
346
+ const tabbables = this.guardedTabbables();
347
+ // A Tab press says which end of the panel focus comes in at; without one, where it came from does.
348
+ const from = event.relatedTarget;
349
+ const backward = this.tabDirection != null ? this.tabDirection === 'backward' : from != null && this.isAfterPopover(from);
350
+ const target = backward ? tabbables[tabbables.length - 1] : tabbables[0];
351
+ // Focus can reach the guard without a Tab keydown here (from a frame, or assistive tech) after
352
+ // the panel's controls are gone. The trigger is the nearest visible place for it.
353
+ if (target == null)
354
+ this.returnFocusToTrigger();
355
+ else
356
+ target.focus();
357
+ };
358
+ this.handleTabFromPanel = (event) => {
359
+ if (event.key !== 'Tab' || event.defaultPrevented || this.tabGuardEl == null)
360
+ return;
361
+ const tabbables = this.guardedTabbables();
362
+ const edge = event.shiftKey ? tabbables[0] : tabbables[tabbables.length - 1];
363
+ if (edge == null || deepActiveElement() !== edge)
364
+ return;
365
+ this.leavePanel(edge, event.shiftKey);
366
+ };
367
+ this.releasePanel = () => {
368
+ if (this.portalEl != null)
369
+ this.portalEl.inert = false;
370
+ };
255
371
  }
256
372
  openOnChanged() {
257
373
  this.pin();
@@ -287,8 +403,6 @@ export class PdsPopover {
287
403
  // Bind event handlers for cleanup
288
404
  this.boundClickOutsideHandler = this.handleClickOutside.bind(this);
289
405
  this.boundEscapeKeyHandler = this.handleEscapeKey.bind(this);
290
- this.boundScrollHandler = this.handleScroll.bind(this);
291
- this.boundResizeHandler = this.handleResize.bind(this);
292
406
  // Create portal element
293
407
  this.createPortal();
294
408
  this.hasLoaded = true;
@@ -387,11 +501,12 @@ export class PdsPopover {
387
501
  // is in now, if any.
388
502
  if (this.active) {
389
503
  this.placePortal();
390
- requestAnimationFrame(() => this.handlePopoverPositioning());
504
+ // autoUpdate listens to the scroll containers around where the trigger was, so it starts again.
505
+ this.addScrollAndResizeListeners();
391
506
  }
392
507
  }
393
508
  disconnectedCallback() {
394
- var _a;
509
+ var _a, _b;
395
510
  // Moved in one operation (a DOM morph, or a framework reparenting it), the popover is
396
511
  // already back in the page. Its portal is outside the popover, so it stays open, with focus
397
512
  // where it was; connectedCallback moves it to follow the popover.
@@ -406,6 +521,7 @@ export class PdsPopover {
406
521
  this.restorePortalContent();
407
522
  this.active = false;
408
523
  this.linkTriggerToPortal();
524
+ this.emitOpenEvent();
409
525
  this.pdsPopoverClose.emit({
410
526
  componentId: this.componentId,
411
527
  popoverType: this.popoverType,
@@ -422,32 +538,20 @@ export class PdsPopover {
422
538
  this.removeLightDismissListeners();
423
539
  this.removeScrollAndResizeListeners();
424
540
  document.removeEventListener('submit', this.handleSubmitFromPanel, true);
425
- // Clear any pending debounce timers
426
- this.clearDebounceTimers();
541
+ document.removeEventListener('keydown', this.syncTabGuard, true);
542
+ (_b = this.tabGuardEl) === null || _b === void 0 ? void 0 : _b.removeAttribute('tabindex');
427
543
  this.clearHoverTimers();
428
544
  this.hoverOpened = false;
429
545
  // Remove portal from DOM
430
546
  this.removePortal();
431
547
  }
432
- /**
433
- * Clears any pending debounce timers
434
- */
435
- clearDebounceTimers() {
436
- if (this.scrollDebounceTimer !== null) {
437
- clearTimeout(this.scrollDebounceTimer);
438
- this.scrollDebounceTimer = null;
439
- }
440
- if (this.resizeDebounceTimer !== null) {
441
- clearTimeout(this.resizeDebounceTimer);
442
- this.resizeDebounceTimer = null;
443
- }
444
- }
445
548
  createPortal() {
446
549
  var _a;
447
550
  if (this.portalEl !== null)
448
551
  return;
449
552
  this.portalEl = document.createElement('div');
450
553
  this.portalEl.className = 'pds-popover';
554
+ panelOwners.set(this.portalEl, this);
451
555
  // Apply all styles inline since portal is outside shadow DOM
452
556
  this.portalEl.style.position = 'fixed';
453
557
  this.portalEl.style.zIndex = 'var(--pine-z-index-raised)';
@@ -474,6 +578,7 @@ export class PdsPopover {
474
578
  // This is done after appending to ensure it's part of the document and can access CSS variables
475
579
  this.addPortalFocusStyles();
476
580
  this.listenForHover(this.portalEl);
581
+ this.portalEl.addEventListener('keydown', this.handleTabFromPanel);
477
582
  }
478
583
  /**
479
584
  * Adds Pine design system focus styles and dark mode border to the portal element
@@ -607,15 +712,10 @@ export class PdsPopover {
607
712
  this.portalEl.style.display = 'block';
608
713
  this.portalEl.style.opacity = '1';
609
714
  this.portalEl.style.visibility = 'visible';
610
- // Position the popover
611
- requestAnimationFrame(() => {
612
- if (!this.isComponentMounted)
613
- return;
614
- this.handlePopoverPositioning();
615
- });
616
- // Add scroll and resize listeners for repositioning (always)
715
+ // Position the popover now, and again whenever its trigger or the page moves or resizes
617
716
  this.addScrollAndResizeListeners();
618
717
  document.addEventListener('submit', this.handleSubmitFromPanel, true);
718
+ document.addEventListener('keydown', this.syncTabGuard, true);
619
719
  // Add document listeners for light dismiss and escape key (auto type only), or for the escape
620
720
  // key alone while hover holds a manual popover open
621
721
  if (this.popoverType === 'auto') {
@@ -626,7 +726,20 @@ export class PdsPopover {
626
726
  popoversTakingEscape.push(this);
627
727
  document.addEventListener('keydown', this.boundEscapeKeyHandler);
628
728
  }
629
- // Emit open event
729
+ // Emit open event once the panel is positioned, with the side it took already on it. A reconnect, a
730
+ // trigger swap or another show() can start a newer run meanwhile, which drops this one, so wait for the latest.
731
+ this.openEventPending = true;
732
+ let positioning;
733
+ do {
734
+ positioning = this.positioning;
735
+ await positioning;
736
+ } while (positioning !== this.positioning);
737
+ this.emitOpenEvent();
738
+ }
739
+ emitOpenEvent() {
740
+ if (!this.openEventPending)
741
+ return;
742
+ this.openEventPending = false;
630
743
  this.pdsPopoverOpen.emit({
631
744
  componentId: this.componentId,
632
745
  popoverType: this.popoverType,
@@ -636,6 +749,7 @@ export class PdsPopover {
636
749
  * Closes the popover programmatically
637
750
  */
638
751
  async hide() {
752
+ var _a;
639
753
  this.clearHoverTimers();
640
754
  if (!this.active || !this.portalEl)
641
755
  return;
@@ -651,6 +765,7 @@ export class PdsPopover {
651
765
  // Hide portal. The dark-mode border set in a shadow root is worked out again on the next open.
652
766
  this.portalEl.style.border = '';
653
767
  this.portalEl.removeAttribute('data-pds-popover-open');
768
+ this.portalEl.removeAttribute('data-pds-popover-placement');
654
769
  this.portalEl.style.display = 'none';
655
770
  this.portalEl.style.opacity = '0';
656
771
  this.portalEl.style.visibility = 'hidden';
@@ -664,8 +779,11 @@ export class PdsPopover {
664
779
  this.removeLightDismissListeners();
665
780
  this.removeScrollAndResizeListeners();
666
781
  document.removeEventListener('submit', this.handleSubmitFromPanel, true);
667
- // Clear any pending timers
668
- this.clearDebounceTimers();
782
+ document.removeEventListener('keydown', this.syncTabGuard, true);
783
+ (_a = this.tabGuardEl) === null || _a === void 0 ? void 0 : _a.removeAttribute('tabindex');
784
+ this.releasePanel();
785
+ // Closed before its first position resolved, it still announces the open before the close.
786
+ this.emitOpenEvent();
669
787
  // Emit close event
670
788
  this.pdsPopoverClose.emit({
671
789
  componentId: this.componentId,
@@ -677,10 +795,10 @@ export class PdsPopover {
677
795
  */
678
796
  async toggle() {
679
797
  if (this.active) {
680
- this.hide();
798
+ await this.hide();
681
799
  }
682
800
  else {
683
- this.show();
801
+ await this.show();
684
802
  }
685
803
  }
686
804
  /**
@@ -764,19 +882,62 @@ export class PdsPopover {
764
882
  document.removeEventListener('click', this.boundClickOutsideHandler, true);
765
883
  document.removeEventListener('keydown', this.boundEscapeKeyHandler);
766
884
  }
885
+ /**
886
+ * The panel's controls that Tab reaches through the guard. None when the panel sits right after
887
+ * the popover, in a dialog, where it's already next in the Tab order.
888
+ */
889
+ guardedTabbables() {
890
+ if (this.portalEl == null || this.el.nextElementSibling === this.portalEl)
891
+ return [];
892
+ return tabbableIn(this.portalEl);
893
+ }
894
+ isAfterPopover(node) {
895
+ if (containsComposed(this.el, node))
896
+ return false;
897
+ return isPosition(positionAcrossTrees(this.el, node), Node.DOCUMENT_POSITION_FOLLOWING);
898
+ }
899
+ /**
900
+ * Moves focus to the guard without preventing the Tab, so the browser's Tab carries on from there.
901
+ * Inert until then, the panel can't be where it lands.
902
+ */
903
+ leavePanel(edge, backward) {
904
+ var _a, _b;
905
+ this.leavingPanel = true;
906
+ (_a = this.tabGuardEl) === null || _a === void 0 ? void 0 : _a.focus();
907
+ this.leavingPanel = false;
908
+ this.portalEl.inert = true;
909
+ setTimeout(() => this.finishLeavingPanel(edge));
910
+ // Last in another popover's panel, the guard hands the Tab on to that popover's own guard.
911
+ const outer = panelOwners.get(closest('.pds-popover', this.el));
912
+ const outerTabbables = (_b = outer === null || outer === void 0 ? void 0 : outer.guardedTabbables()) !== null && _b !== void 0 ? _b : [];
913
+ if (!backward && outerTabbables[outerTabbables.length - 1] === this.tabGuardEl)
914
+ outer.leavePanel(edge, false);
915
+ }
916
+ // With nowhere for the browser's Tab to go, focus would stay on the invisible guard.
917
+ finishLeavingPanel(edge) {
918
+ var _a;
919
+ this.releasePanel();
920
+ if (this.active && ((_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.activeElement) === this.tabGuardEl)
921
+ edge.focus();
922
+ }
767
923
  /**
768
924
  * Adds scroll and resize listeners for repositioning
769
925
  */
770
926
  addScrollAndResizeListeners() {
771
- window.addEventListener('scroll', this.boundScrollHandler, true);
772
- window.addEventListener('resize', this.boundResizeHandler);
927
+ this.removeScrollAndResizeListeners();
928
+ if (this.triggerEl == null || this.portalEl == null)
929
+ return;
930
+ this.stopAutoUpdate = autoUpdate(this.triggerEl, this.portalEl, () => {
931
+ this.positioning = this.handlePopoverPositioning().catch(error => console.warn('pds-popover: failed to position the panel', error));
932
+ });
773
933
  }
774
934
  /**
775
935
  * Removes scroll and resize listeners
776
936
  */
777
937
  removeScrollAndResizeListeners() {
778
- window.removeEventListener('scroll', this.boundScrollHandler, true);
779
- window.removeEventListener('resize', this.boundResizeHandler);
938
+ var _a;
939
+ (_a = this.stopAutoUpdate) === null || _a === void 0 ? void 0 : _a.call(this);
940
+ this.stopAutoUpdate = null;
780
941
  }
781
942
  /**
782
943
  * Handles clicks outside the popover for light dismiss (auto type only)
@@ -840,122 +1001,38 @@ export class PdsPopover {
840
1001
  this.hide();
841
1002
  }
842
1003
  /**
843
- * Handles scroll events to reposition the popover (debounced for performance)
844
- */
845
- handleScroll() {
846
- if (!this.active)
847
- return;
848
- if (this.scrollDebounceTimer !== null) {
849
- clearTimeout(this.scrollDebounceTimer);
850
- }
851
- this.scrollDebounceTimer = setTimeout(() => {
852
- this.handlePopoverPositioning();
853
- this.scrollDebounceTimer = null;
854
- }, 10); // 10ms debounce for smooth repositioning
855
- }
856
- /**
857
- * Handles resize events to reposition the popover (debounced for performance)
858
- */
859
- handleResize() {
860
- if (!this.active)
861
- return;
862
- if (this.resizeDebounceTimer !== null) {
863
- clearTimeout(this.resizeDebounceTimer);
864
- }
865
- this.resizeDebounceTimer = setTimeout(() => {
866
- this.handlePopoverPositioning();
867
- this.resizeDebounceTimer = null;
868
- }, 100); // 100ms debounce for resize
869
- }
870
- /**
871
- * Positions the popover relative to its trigger element
1004
+ * Positions the popover relative to its trigger element, flipping to the opposite side when only that side has
1005
+ * room and shifting to stay 8px inside the viewport. The side it takes goes on the panel's `data-pds-popover-placement`.
872
1006
  */
873
- handlePopoverPositioning() {
874
- // Prevent repositioning loops
875
- if (this.isRepositioning) {
876
- return;
877
- }
878
- this.isRepositioning = true;
879
- if (this.triggerEl == null || this.portalEl == null) {
880
- this.isRepositioning = false;
1007
+ async handlePopoverPositioning() {
1008
+ // Counted before the guards, so a run still in flight is dropped even when this one can't position.
1009
+ const run = ++this.positioningRun;
1010
+ if (this.triggerEl == null || this.portalEl == null)
881
1011
  return;
882
- }
883
- const triggerRect = this.triggerEl.getBoundingClientRect();
884
- const popoverRect = this.portalEl.getBoundingClientRect();
885
1012
  // Safety check: ensure trigger has valid dimensions (is rendered and visible)
886
- if (triggerRect.width === 0 || triggerRect.height === 0) {
887
- this.isRepositioning = false;
1013
+ const triggerRect = this.triggerEl.getBoundingClientRect();
1014
+ if (triggerRect.width === 0 || triggerRect.height === 0)
888
1015
  return;
889
- }
890
- let top = 0;
891
- let left = 0;
892
- const offset = 8;
893
- switch (this.placement) {
894
- case 'top':
895
- top = triggerRect.top - popoverRect.height - offset;
896
- left = triggerRect.left + (triggerRect.width - popoverRect.width) / 2;
897
- break;
898
- case 'top-start':
899
- top = triggerRect.top - popoverRect.height - offset;
900
- left = triggerRect.left;
901
- break;
902
- case 'top-end':
903
- top = triggerRect.top - popoverRect.height - offset;
904
- left = triggerRect.right - popoverRect.width;
905
- break;
906
- case 'right':
907
- top = triggerRect.top + (triggerRect.height - popoverRect.height) / 2;
908
- left = triggerRect.right + offset;
909
- break;
910
- case 'right-start':
911
- top = triggerRect.top;
912
- left = triggerRect.right + offset;
913
- break;
914
- case 'right-end':
915
- top = triggerRect.bottom - popoverRect.height;
916
- left = triggerRect.right + offset;
917
- break;
918
- case 'bottom':
919
- top = triggerRect.bottom + offset;
920
- left = triggerRect.left + (triggerRect.width - popoverRect.width) / 2;
921
- break;
922
- case 'bottom-start':
923
- top = triggerRect.bottom + offset;
924
- left = triggerRect.left;
925
- break;
926
- case 'bottom-end':
927
- top = triggerRect.bottom + offset;
928
- left = triggerRect.right - popoverRect.width;
929
- break;
930
- case 'left':
931
- top = triggerRect.top + (triggerRect.height - popoverRect.height) / 2;
932
- left = triggerRect.left - popoverRect.width - offset;
933
- break;
934
- case 'left-start':
935
- top = triggerRect.top;
936
- left = triggerRect.left - popoverRect.width - offset;
937
- break;
938
- case 'left-end':
939
- top = triggerRect.bottom - popoverRect.height;
940
- left = triggerRect.left - popoverRect.width - offset;
941
- break;
942
- }
943
- this.portalEl.style.top = `${top}px`;
944
- this.portalEl.style.left = `${left}px`;
1016
+ const portal = this.portalEl;
1017
+ const { x: left, y: top, placement } = await computePosition(this.triggerEl, portal, {
1018
+ placement: this.placement,
1019
+ strategy: 'fixed',
1020
+ // With no room on either side, stay on the preferred side: the side that overflows less can still push
1021
+ // a tall panel's start above the viewport.
1022
+ middleware: [offset(8), flip({ fallbackStrategy: 'initialPlacement' }), shift({ padding: 8 })],
1023
+ platform: viewportPlatform,
1024
+ });
1025
+ if (!this.active || run !== this.positioningRun || portal !== this.portalEl)
1026
+ return;
1027
+ portal.setAttribute('data-pds-popover-placement', placement);
945
1028
  // `position: fixed` measures from the viewport unless an ancestor becomes its containing block,
946
- // as a modal dialog does with its backdrop filter. Shift by however far it landed from the spot.
947
- const placed = this.portalEl.getBoundingClientRect();
948
- if (Math.abs(placed.top - top) > 0.5 || Math.abs(placed.left - left) > 0.5) {
949
- this.portalEl.style.top = `${2 * top - placed.top}px`;
950
- this.portalEl.style.left = `${2 * left - placed.left}px`;
951
- }
952
- // Reset the repositioning guard after a short delay
953
- setTimeout(() => {
954
- this.isRepositioning = false;
955
- }, 16); // ~1 frame at 60fps
1029
+ // as a modal dialog does with its backdrop filter. Offset by however far that block's corner is from the viewport's.
1030
+ const origin = containingBlockOrigin(portal);
1031
+ portal.style.top = `${top - origin.top}px`;
1032
+ portal.style.left = `${left - origin.left}px`;
956
1033
  }
957
1034
  render() {
958
- return (h(Host, { key: 'e48b897acdc9e89f2e6b1449e7a358da7da1060c', id: this.componentId }, h("span", { key: 'b83b2c234b07703c2c850a9991c94939ed2fdaf7', class: "pds-popover__trigger-wrapper" }, h("slot", { key: '0a7f7829ee445fd57cf824ebee1409b3c571f983', name: "trigger", onSlotchange: this.handleTriggerSlotChange })), h("div", { key: '8c1fe2d4d7c4342b4bd5eb4c56e596f17b4e14fa', class: "pds-popover__content-slot-wrapper" }, h("slot", { key: '4ccfce1f335acbc436f7942e497f5d360f849d48', onSlotchange: this.handleContentSlotChange }))));
1035
+ return (h(Host, { key: '85422eb7544a4795ce78b51684b7224a5d856a4e', id: this.componentId }, h("span", { key: '6fe9c827ed4d46ca723d6013f296faf80ba31366', class: "pds-popover__trigger-wrapper" }, h("slot", { key: '970d1974d2be1451e670a36e7d2ccdc5979595bb', name: "trigger", onSlotchange: this.handleTriggerSlotChange })), h("span", { key: '0c76f76286a30d8e6e948bd0abab3317b3673aa6', class: "pds-popover__tab-guard", ref: (el) => (this.tabGuardEl = el !== null && el !== void 0 ? el : null), onFocus: this.handleTabGuardFocus }), h("div", { key: '692c45e93899e74a3d5970f3a3625f6115ab63b0', class: "pds-popover__content-slot-wrapper" }, h("slot", { key: 'f1566e0eb1eb08626f2a8285447702ce96b09f4d', onSlotchange: this.handleContentSlotChange }))));
959
1036
  }
960
1037
  static get is() { return "pds-popover"; }
961
1038
  static get encapsulation() { return "shadow"; }
@@ -30,7 +30,7 @@ export class PdsProgress {
30
30
  const normalizedFillColor = normalizeColorValue(this.fillColor);
31
31
  const hostClass = this.animated ? { 'is-animated': this.animated } : '';
32
32
  this.hostKeeper.record(hostClass);
33
- return (h(Host, { key: 'a224e1e9bc50433553ab8bf4b0d772f01148ee76', class: hostClass }, h("div", { key: '261742044f3d68c204cbf640cc4447eb6d74df11', class: "pds-progress" }, h("label", { key: 'd686bdc6ab450bf8c14dd56077525a3139593f46', class: "pds-progress__label", htmlFor: this.componentId }, this.label), h("progress", { key: 'c716e977a952a628aec600fa680aa9c3b8d0e996', id: this.componentId, max: "100", style: normalizedFillColor ? { '--color-progress-fill': normalizedFillColor } : {}, value: this.percent })), this.showPercent && h("div", { key: '44176a580b435f69993be4a60ee2e888b87e10fb', class: "pds-progress__percentage" }, this.percent, "%")));
33
+ return (h(Host, { key: '6d2151cdd1f65b33a7478e5ac12df711d8252d1f', class: hostClass }, h("div", { key: '4a902c6c7d51fe8e8a778e1fa24bdbf95d625b1f', class: "pds-progress" }, h("label", { key: 'c50955234a7eee05cdf47531e25b4413f206e416', class: "pds-progress__label", htmlFor: this.componentId }, this.label), h("progress", { key: 'c54ad90f7b3fcf3368afca4c5618949f1a370114', id: this.componentId, max: "100", style: normalizedFillColor ? { '--color-progress-fill': normalizedFillColor } : {}, value: this.percent })), this.showPercent && h("div", { key: '6b3e3f42f04a516ef7992d1f8bc967be432f55bb', class: "pds-progress__percentage" }, this.percent, "%")));
34
34
  }
35
35
  static get is() { return "pds-progress"; }
36
36
  static get encapsulation() { return "shadow"; }
@@ -10,7 +10,7 @@ export class PdsProperty {
10
10
  this.icon = 'star';
11
11
  }
12
12
  render() {
13
- return (h(Host, { key: 'd599b62be4bacf1d89afcc26b14fc93bdc9bb3a4', id: this.componentId }, h("pds-box", { key: 'd7f80f6598615c761d672893c8acab09bd9ea33f', "align-items": "center", gap: "xs" }, h("pds-icon", { key: '15a6a6545c2cd2332bd830451106b7b08adc39ff', icon: this.icon, size: "var(--pine-dimension-sm)", "aria-hidden": "true" }), h("slot", { key: '4e5661563b99ec56189447faabcdd1ae631159b2' }))));
13
+ return (h(Host, { key: '198ffd747b7a84a6f58a1b072890fc8bd3ed93aa', id: this.componentId }, h("pds-box", { key: 'be71f3d96efea0a45f357d888f71dbe5ad8b68d6', "align-items": "center", gap: "xs" }, h("pds-icon", { key: '1a52407e00b158d5e6a515ad4b07ed3407d31f75', icon: this.icon, size: "var(--pine-dimension-sm)", "aria-hidden": "true" }), h("slot", { key: '46ac5019b27bdd079c7853abeef8f7c240d19c2c' }))));
14
14
  }
15
15
  static get is() { return "pds-property"; }
16
16
  static get encapsulation() { return "shadow"; }
@@ -271,4 +271,61 @@ label:has(input:disabled) {
271
271
  }
272
272
  :host(.has-image).is-invalid .pds-radio__message--error {
273
273
  color: var(--pine-color-text-message-danger);
274
+ }
275
+
276
+ :host(.pds-radio--pill) label {
277
+ align-items: center;
278
+ background: var(--pine-color-background-container);
279
+ border: var(--pine-border);
280
+ border-radius: var(--pine-border-radius-full);
281
+ box-sizing: border-box;
282
+ color: var(--pine-color-text-active);
283
+ cursor: pointer;
284
+ font: var(--pine-typography-body);
285
+ min-block-size: var(--pine-dimension-xl);
286
+ padding: 0 var(--pine-dimension-sm);
287
+ transition: border-color var(--pine-motion-duration-fast) ease;
288
+ }
289
+ :host(.pds-radio--pill) label span {
290
+ min-width: 0;
291
+ overflow-wrap: anywhere;
292
+ }
293
+ :host(.pds-radio--pill) label:hover {
294
+ border-color: var(--pine-color-text);
295
+ }
296
+ :host(.pds-radio--pill) label:has(input:checked) {
297
+ border-color: var(--pine-color-text-active);
298
+ box-shadow: inset 0 0 0 var(--pine-border-width) var(--pine-color-text-active);
299
+ }
300
+ :host(.pds-radio--pill) label:has(input:focus-visible) {
301
+ outline: var(--pine-outline-focus);
302
+ outline-offset: var(--pine-border-width-thick);
303
+ }
304
+ :host(.pds-radio--pill) label:has(input:disabled) {
305
+ background: var(--pine-color-background-container-disabled);
306
+ border-color: var(--pine-color-border-disabled);
307
+ color: var(--pine-color-text-label-disabled);
308
+ cursor: not-allowed;
309
+ }
310
+ :host(.pds-radio--pill) label:has(input:disabled:checked) {
311
+ border-color: var(--pine-color-text-label-disabled);
312
+ box-shadow: inset 0 0 0 var(--pine-border-width) var(--pine-color-text-label-disabled);
313
+ }
314
+ @media (forced-colors: active) {
315
+ :host(.pds-radio--pill) label:has(input:disabled) {
316
+ border-color: GrayText;
317
+ }
318
+ :host(.pds-radio--pill) label:has(input:checked) {
319
+ border-color: Highlight;
320
+ border-width: var(--pine-border-width-thick);
321
+ padding-inline: calc(var(--pine-dimension-sm) - (var(--pine-border-width-thick) - var(--pine-border-width)));
322
+ }
323
+ :host(.pds-radio--pill) label:has(input:disabled:checked) {
324
+ border-color: GrayText;
325
+ border-width: var(--pine-border-width-thick);
326
+ padding-inline: calc(var(--pine-dimension-sm) - (var(--pine-border-width-thick) - var(--pine-border-width)));
327
+ }
328
+ }
329
+ :host(.pds-radio--pill) .pds-radio__message {
330
+ margin-inline-start: 0;
274
331
  }