@pitchfork-ui/elements 0.1.0 → 0.2.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 (264) hide show
  1. package/dist/cjs/control-label-C0eK8bPh.js +36 -0
  2. package/dist/cjs/control-label-C0eK8bPh.js.map +1 -0
  3. package/dist/cjs/index-CIskGKk1.js +4 -4
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/pf-checkbox.cjs.entry.js +3 -1
  6. package/dist/cjs/pf-checkbox.cjs.entry.js.map +1 -1
  7. package/dist/cjs/pf-combobox.cjs.entry.js +4 -3
  8. package/dist/cjs/pf-combobox.cjs.entry.js.map +1 -1
  9. package/dist/cjs/pf-date-picker.cjs.entry.js +3 -2
  10. package/dist/cjs/pf-date-picker.cjs.entry.js.map +1 -1
  11. package/dist/cjs/pf-date-range-picker.cjs.entry.js +6 -5
  12. package/dist/cjs/pf-date-range-picker.cjs.entry.js.map +1 -1
  13. package/dist/cjs/pf-header-navigation.cjs.entry.js +15 -3
  14. package/dist/cjs/pf-header-navigation.cjs.entry.js.map +1 -1
  15. package/dist/cjs/pf-input.cjs.entry.js +3 -1
  16. package/dist/cjs/pf-input.cjs.entry.js.map +1 -1
  17. package/dist/cjs/pf-modal.cjs.entry.js +89 -1
  18. package/dist/cjs/pf-modal.cjs.entry.js.map +1 -1
  19. package/dist/cjs/pf-multi-select.cjs.entry.js +4 -3
  20. package/dist/cjs/pf-multi-select.cjs.entry.js.map +1 -1
  21. package/dist/cjs/pf-nav-item.cjs.entry.js +29 -4
  22. package/dist/cjs/pf-nav-item.cjs.entry.js.map +1 -1
  23. package/dist/cjs/pf-number-input.cjs.entry.js +2 -1
  24. package/dist/cjs/pf-number-input.cjs.entry.js.map +1 -1
  25. package/dist/cjs/pf-select.cjs.entry.js +4 -3
  26. package/dist/cjs/pf-select.cjs.entry.js.map +1 -1
  27. package/dist/cjs/pf-sidebar-navigation.cjs.entry.js +11 -8
  28. package/dist/cjs/pf-sidebar-navigation.cjs.entry.js.map +1 -1
  29. package/dist/cjs/pf-slider.cjs.entry.js +4 -2
  30. package/dist/cjs/pf-slider.cjs.entry.js.map +1 -1
  31. package/dist/cjs/pf-switch.cjs.entry.js +3 -1
  32. package/dist/cjs/pf-switch.cjs.entry.js.map +1 -1
  33. package/dist/cjs/pf-tag-input.cjs.entry.js +3 -2
  34. package/dist/cjs/pf-tag-input.cjs.entry.js.map +1 -1
  35. package/dist/cjs/pf-textarea.cjs.entry.js +2 -1
  36. package/dist/cjs/pf-textarea.cjs.entry.js.map +1 -1
  37. package/dist/cjs/pf-time-picker.cjs.entry.js +3 -2
  38. package/dist/cjs/pf-time-picker.cjs.entry.js.map +1 -1
  39. package/dist/cjs/pitchfork.cjs.js +1 -1
  40. package/dist/collection/components/pf-accordion/pf-accordion.js +2 -2
  41. package/dist/collection/components/pf-alert/pf-alert.js +1 -1
  42. package/dist/collection/components/pf-avatar/pf-avatar.js +2 -2
  43. package/dist/collection/components/pf-badge/pf-badge.js +1 -1
  44. package/dist/collection/components/pf-badge-group/pf-badge-group.js +3 -3
  45. package/dist/collection/components/pf-button/pf-button.js +3 -3
  46. package/dist/collection/components/pf-checkbox/pf-checkbox.js +4 -1
  47. package/dist/collection/components/pf-checkbox/pf-checkbox.js.map +1 -1
  48. package/dist/collection/components/pf-combobox/pf-combobox.js +4 -3
  49. package/dist/collection/components/pf-combobox/pf-combobox.js.map +1 -1
  50. package/dist/collection/components/pf-content-divider/pf-content-divider.js +1 -1
  51. package/dist/collection/components/pf-credit-card/pf-credit-card.js +1 -1
  52. package/dist/collection/components/pf-date-picker/pf-date-picker.js +3 -2
  53. package/dist/collection/components/pf-date-picker/pf-date-picker.js.map +1 -1
  54. package/dist/collection/components/pf-date-range-picker/pf-date-range-picker.js +6 -5
  55. package/dist/collection/components/pf-date-range-picker/pf-date-range-picker.js.map +1 -1
  56. package/dist/collection/components/pf-empty-state/pf-empty-state.js +1 -1
  57. package/dist/collection/components/pf-header-navigation/pf-header-navigation.js +25 -4
  58. package/dist/collection/components/pf-header-navigation/pf-header-navigation.js.map +1 -1
  59. package/dist/collection/components/pf-inline-cta/pf-inline-cta.js +1 -1
  60. package/dist/collection/components/pf-input/pf-input.js +5 -2
  61. package/dist/collection/components/pf-input/pf-input.js.map +1 -1
  62. package/dist/collection/components/pf-kbd/pf-kbd.js +1 -1
  63. package/dist/collection/components/pf-line-chart/pf-line-chart.js +1 -1
  64. package/dist/collection/components/pf-loading-dots/pf-loading-dots.js +1 -1
  65. package/dist/collection/components/pf-metric-card/pf-metric-card.js +1 -1
  66. package/dist/collection/components/pf-modal/pf-modal.js +77 -6
  67. package/dist/collection/components/pf-modal/pf-modal.js.map +1 -1
  68. package/dist/collection/components/pf-multi-select/pf-multi-select.js +4 -3
  69. package/dist/collection/components/pf-multi-select/pf-multi-select.js.map +1 -1
  70. package/dist/collection/components/pf-nav-item/pf-nav-item.js +50 -5
  71. package/dist/collection/components/pf-nav-item/pf-nav-item.js.map +1 -1
  72. package/dist/collection/components/pf-notification/pf-notification.js +1 -1
  73. package/dist/collection/components/pf-number-input/pf-number-input.js +2 -1
  74. package/dist/collection/components/pf-number-input/pf-number-input.js.map +1 -1
  75. package/dist/collection/components/pf-progress-steps/pf-progress-steps.js +1 -1
  76. package/dist/collection/components/pf-radio-group/pf-radio-group.js +1 -1
  77. package/dist/collection/components/pf-rating-badge/pf-rating-badge.js +1 -1
  78. package/dist/collection/components/pf-scroll-area/pf-scroll-area.js +1 -1
  79. package/dist/collection/components/pf-section-header/pf-section-header.js +1 -1
  80. package/dist/collection/components/pf-select/pf-select.js +4 -3
  81. package/dist/collection/components/pf-select/pf-select.js.map +1 -1
  82. package/dist/collection/components/pf-sidebar-navigation/pf-sidebar-navigation.js +12 -9
  83. package/dist/collection/components/pf-sidebar-navigation/pf-sidebar-navigation.js.map +1 -1
  84. package/dist/collection/components/pf-slideout-menu/pf-slideout-menu.js +2 -2
  85. package/dist/collection/components/pf-slider/pf-slider.js +5 -2
  86. package/dist/collection/components/pf-slider/pf-slider.js.map +1 -1
  87. package/dist/collection/components/pf-switch/pf-switch.js +4 -1
  88. package/dist/collection/components/pf-switch/pf-switch.js.map +1 -1
  89. package/dist/collection/components/pf-tab/pf-tab.js +2 -2
  90. package/dist/collection/components/pf-table-cell/pf-table-cell.js +1 -1
  91. package/dist/collection/components/pf-tabs/pf-tabs.js +2 -2
  92. package/dist/collection/components/pf-tag/pf-tag.js +1 -1
  93. package/dist/collection/components/pf-tag-input/pf-tag-input.js +3 -2
  94. package/dist/collection/components/pf-tag-input/pf-tag-input.js.map +1 -1
  95. package/dist/collection/components/pf-textarea/pf-textarea.js +2 -1
  96. package/dist/collection/components/pf-textarea/pf-textarea.js.map +1 -1
  97. package/dist/collection/components/pf-time-picker/pf-time-picker.js +3 -2
  98. package/dist/collection/components/pf-time-picker/pf-time-picker.js.map +1 -1
  99. package/dist/collection/components/pf-timeline-item/pf-timeline-item.js +1 -1
  100. package/dist/collection/components/pf-toaster/pf-toaster.js +2 -2
  101. package/dist/collection/components/pf-toolbar/pf-toolbar.js +1 -1
  102. package/dist/collection/components/pf-toolbar-separator/pf-toolbar-separator.js +1 -1
  103. package/dist/collection/components/pf-utility-button/pf-utility-button.js +2 -2
  104. package/dist/collection/components/pf-video-player/pf-video-player.js +2 -2
  105. package/dist/collection/control-label.js +30 -0
  106. package/dist/collection/control-label.js.map +1 -0
  107. package/dist/components/p-Cy_kHPeC.js +2 -0
  108. package/dist/components/p-Cy_kHPeC.js.map +1 -0
  109. package/dist/components/pf-checkbox.js +1 -1
  110. package/dist/components/pf-checkbox.js.map +1 -1
  111. package/dist/components/pf-combobox.js +1 -1
  112. package/dist/components/pf-combobox.js.map +1 -1
  113. package/dist/components/pf-date-picker.js +1 -1
  114. package/dist/components/pf-date-picker.js.map +1 -1
  115. package/dist/components/pf-date-range-picker.js +1 -1
  116. package/dist/components/pf-date-range-picker.js.map +1 -1
  117. package/dist/components/pf-header-navigation.js +1 -1
  118. package/dist/components/pf-header-navigation.js.map +1 -1
  119. package/dist/components/pf-input.js +1 -1
  120. package/dist/components/pf-input.js.map +1 -1
  121. package/dist/components/pf-modal.js +1 -1
  122. package/dist/components/pf-modal.js.map +1 -1
  123. package/dist/components/pf-multi-select.js +1 -1
  124. package/dist/components/pf-multi-select.js.map +1 -1
  125. package/dist/components/pf-nav-item.js +1 -1
  126. package/dist/components/pf-nav-item.js.map +1 -1
  127. package/dist/components/pf-number-input.js +1 -1
  128. package/dist/components/pf-number-input.js.map +1 -1
  129. package/dist/components/pf-select.js +1 -1
  130. package/dist/components/pf-select.js.map +1 -1
  131. package/dist/components/pf-sidebar-navigation.js +1 -1
  132. package/dist/components/pf-sidebar-navigation.js.map +1 -1
  133. package/dist/components/pf-slider.js +1 -1
  134. package/dist/components/pf-slider.js.map +1 -1
  135. package/dist/components/pf-switch.js +1 -1
  136. package/dist/components/pf-switch.js.map +1 -1
  137. package/dist/components/pf-tag-input.js +1 -1
  138. package/dist/components/pf-tag-input.js.map +1 -1
  139. package/dist/components/pf-textarea.js +1 -1
  140. package/dist/components/pf-textarea.js.map +1 -1
  141. package/dist/components/pf-time-picker.js +1 -1
  142. package/dist/components/pf-time-picker.js.map +1 -1
  143. package/dist/docs.json +73 -52
  144. package/dist/elements.json +100 -10
  145. package/dist/esm/control-label-Cy_kHPeC.js +34 -0
  146. package/dist/esm/control-label-Cy_kHPeC.js.map +1 -0
  147. package/dist/esm/index-Bm6UxEit.js +4 -4
  148. package/dist/esm/loader.js +1 -1
  149. package/dist/esm/pf-checkbox.entry.js +4 -2
  150. package/dist/esm/pf-checkbox.entry.js.map +1 -1
  151. package/dist/esm/pf-combobox.entry.js +4 -3
  152. package/dist/esm/pf-combobox.entry.js.map +1 -1
  153. package/dist/esm/pf-date-picker.entry.js +3 -2
  154. package/dist/esm/pf-date-picker.entry.js.map +1 -1
  155. package/dist/esm/pf-date-range-picker.entry.js +6 -5
  156. package/dist/esm/pf-date-range-picker.entry.js.map +1 -1
  157. package/dist/esm/pf-header-navigation.entry.js +15 -3
  158. package/dist/esm/pf-header-navigation.entry.js.map +1 -1
  159. package/dist/esm/pf-input.entry.js +4 -2
  160. package/dist/esm/pf-input.entry.js.map +1 -1
  161. package/dist/esm/pf-modal.entry.js +89 -1
  162. package/dist/esm/pf-modal.entry.js.map +1 -1
  163. package/dist/esm/pf-multi-select.entry.js +4 -3
  164. package/dist/esm/pf-multi-select.entry.js.map +1 -1
  165. package/dist/esm/pf-nav-item.entry.js +30 -5
  166. package/dist/esm/pf-nav-item.entry.js.map +1 -1
  167. package/dist/esm/pf-number-input.entry.js +2 -1
  168. package/dist/esm/pf-number-input.entry.js.map +1 -1
  169. package/dist/esm/pf-select.entry.js +4 -3
  170. package/dist/esm/pf-select.entry.js.map +1 -1
  171. package/dist/esm/pf-sidebar-navigation.entry.js +11 -8
  172. package/dist/esm/pf-sidebar-navigation.entry.js.map +1 -1
  173. package/dist/esm/pf-slider.entry.js +5 -3
  174. package/dist/esm/pf-slider.entry.js.map +1 -1
  175. package/dist/esm/pf-switch.entry.js +4 -2
  176. package/dist/esm/pf-switch.entry.js.map +1 -1
  177. package/dist/esm/pf-tag-input.entry.js +3 -2
  178. package/dist/esm/pf-tag-input.entry.js.map +1 -1
  179. package/dist/esm/pf-textarea.entry.js +2 -1
  180. package/dist/esm/pf-textarea.entry.js.map +1 -1
  181. package/dist/esm/pf-time-picker.entry.js +3 -2
  182. package/dist/esm/pf-time-picker.entry.js.map +1 -1
  183. package/dist/esm/pitchfork.js +1 -1
  184. package/dist/pitchfork/p-01ed0d56.entry.js +2 -0
  185. package/dist/pitchfork/p-01ed0d56.entry.js.map +1 -0
  186. package/dist/pitchfork/p-02e28338.entry.js +2 -0
  187. package/dist/pitchfork/p-02e28338.entry.js.map +1 -0
  188. package/dist/pitchfork/p-19c0145c.entry.js +2 -0
  189. package/dist/pitchfork/p-19c0145c.entry.js.map +1 -0
  190. package/dist/pitchfork/p-22d8c69d.entry.js +2 -0
  191. package/dist/pitchfork/p-22d8c69d.entry.js.map +1 -0
  192. package/dist/pitchfork/p-2add2e98.entry.js +2 -0
  193. package/dist/pitchfork/p-2add2e98.entry.js.map +1 -0
  194. package/dist/pitchfork/p-45039de3.entry.js +2 -0
  195. package/dist/pitchfork/p-45039de3.entry.js.map +1 -0
  196. package/dist/pitchfork/p-4dfe7e8a.entry.js +2 -0
  197. package/dist/pitchfork/p-4dfe7e8a.entry.js.map +1 -0
  198. package/dist/pitchfork/p-51353d53.entry.js +2 -0
  199. package/dist/pitchfork/p-51353d53.entry.js.map +1 -0
  200. package/dist/pitchfork/p-5b98848c.entry.js +2 -0
  201. package/dist/pitchfork/{p-fd5a5ea1.entry.js.map → p-5b98848c.entry.js.map} +1 -1
  202. package/dist/pitchfork/p-7197ef71.entry.js +2 -0
  203. package/dist/pitchfork/p-7197ef71.entry.js.map +1 -0
  204. package/dist/pitchfork/p-Cy_kHPeC.js +2 -0
  205. package/dist/pitchfork/p-Cy_kHPeC.js.map +1 -0
  206. package/dist/pitchfork/p-ab6c09e7.entry.js +2 -0
  207. package/dist/pitchfork/p-ab6c09e7.entry.js.map +1 -0
  208. package/dist/pitchfork/p-d7ca4026.entry.js +2 -0
  209. package/dist/pitchfork/p-d7ca4026.entry.js.map +1 -0
  210. package/dist/pitchfork/p-dd48d94d.entry.js +2 -0
  211. package/dist/pitchfork/p-dd48d94d.entry.js.map +1 -0
  212. package/dist/pitchfork/p-ec8df806.entry.js +2 -0
  213. package/dist/pitchfork/p-ec8df806.entry.js.map +1 -0
  214. package/dist/pitchfork/p-f5df568f.entry.js +2 -0
  215. package/dist/pitchfork/p-f5df568f.entry.js.map +1 -0
  216. package/dist/pitchfork/p-f713c62d.entry.js +2 -0
  217. package/dist/pitchfork/p-f713c62d.entry.js.map +1 -0
  218. package/dist/pitchfork/p-fd802631.entry.js +2 -0
  219. package/dist/pitchfork/p-fd802631.entry.js.map +1 -0
  220. package/dist/pitchfork/pitchfork.esm.js +1 -1
  221. package/dist/types/components/pf-checkbox/pf-checkbox.d.ts +1 -0
  222. package/dist/types/components/pf-header-navigation/pf-header-navigation.d.ts +11 -2
  223. package/dist/types/components/pf-input/pf-input.d.ts +1 -0
  224. package/dist/types/components/pf-modal/pf-modal.d.ts +56 -3
  225. package/dist/types/components/pf-nav-item/pf-nav-item.d.ts +21 -1
  226. package/dist/types/components/pf-sidebar-navigation/pf-sidebar-navigation.d.ts +10 -7
  227. package/dist/types/components/pf-slider/pf-slider.d.ts +1 -0
  228. package/dist/types/components/pf-switch/pf-switch.d.ts +1 -0
  229. package/dist/types/components.d.ts +57 -18
  230. package/dist/types/control-label.d.ts +24 -0
  231. package/package.json +4 -4
  232. package/dist/pitchfork/p-1dbea97f.entry.js +0 -2
  233. package/dist/pitchfork/p-1dbea97f.entry.js.map +0 -1
  234. package/dist/pitchfork/p-23b1be9b.entry.js +0 -2
  235. package/dist/pitchfork/p-23b1be9b.entry.js.map +0 -1
  236. package/dist/pitchfork/p-33857f80.entry.js +0 -2
  237. package/dist/pitchfork/p-33857f80.entry.js.map +0 -1
  238. package/dist/pitchfork/p-47cabc33.entry.js +0 -2
  239. package/dist/pitchfork/p-47cabc33.entry.js.map +0 -1
  240. package/dist/pitchfork/p-48b2d3f7.entry.js +0 -2
  241. package/dist/pitchfork/p-48b2d3f7.entry.js.map +0 -1
  242. package/dist/pitchfork/p-5064d2dd.entry.js +0 -2
  243. package/dist/pitchfork/p-5064d2dd.entry.js.map +0 -1
  244. package/dist/pitchfork/p-52eef7eb.entry.js +0 -2
  245. package/dist/pitchfork/p-52eef7eb.entry.js.map +0 -1
  246. package/dist/pitchfork/p-845c5252.entry.js +0 -2
  247. package/dist/pitchfork/p-845c5252.entry.js.map +0 -1
  248. package/dist/pitchfork/p-a24bf2bd.entry.js +0 -2
  249. package/dist/pitchfork/p-a24bf2bd.entry.js.map +0 -1
  250. package/dist/pitchfork/p-a9b77dbb.entry.js +0 -2
  251. package/dist/pitchfork/p-a9b77dbb.entry.js.map +0 -1
  252. package/dist/pitchfork/p-c6bdd9cd.entry.js +0 -2
  253. package/dist/pitchfork/p-c6bdd9cd.entry.js.map +0 -1
  254. package/dist/pitchfork/p-d0d2070b.entry.js +0 -2
  255. package/dist/pitchfork/p-d0d2070b.entry.js.map +0 -1
  256. package/dist/pitchfork/p-d248b027.entry.js +0 -2
  257. package/dist/pitchfork/p-d248b027.entry.js.map +0 -1
  258. package/dist/pitchfork/p-d6425298.entry.js +0 -2
  259. package/dist/pitchfork/p-d6425298.entry.js.map +0 -1
  260. package/dist/pitchfork/p-d7eb6335.entry.js +0 -2
  261. package/dist/pitchfork/p-d7eb6335.entry.js.map +0 -1
  262. package/dist/pitchfork/p-e944f504.entry.js +0 -2
  263. package/dist/pitchfork/p-e944f504.entry.js.map +0 -1
  264. package/dist/pitchfork/p-fd5a5ea1.entry.js +0 -2
@@ -0,0 +1 @@
1
+ {"version":3,"names":["pfInputCss","PfInput","internals","name","value","type","label","description","error","placeholder","required","disabled","readonly","pfInput","pfChange","initialValue","componentWillLoad","this","syncFormState","setFormValue","applyControlValidity","Boolean","checkValidity","reportValidity","getValidationMessage","validationMessage","formResetCallback","onInput","event","target","emit","onChange","render","describedBy","composeDescribedBy","h","Host","key","class","part","htmlFor","id","controlAriaLabel","el","input","readOnly"],"sources":["src/components/pf-input/pf-input.css?tag=pf-input&encapsulation=shadow","src/components/pf-input/pf-input.tsx"],"sourcesContent":[":host {\n display: block;\n}\n\n:host([hidden]) {\n display: none;\n}\n\n.field {\n display: grid;\n gap: var(--space-2);\n}\n\n.label {\n color: var(--pf-input-field-label, var(--pf-field-label));\n font-size: var(--font-size-sm);\n font-weight: var(--font-weight-medium);\n}\n\n.required {\n color: var(--pf-field-required);\n margin-inline-start: var(--space-1);\n}\n\n.description {\n color: var(--pf-input-field-description, var(--pf-field-description));\n font-size: var(--font-size-sm);\n margin: 0;\n}\n\n.error {\n color: var(--pf-input-field-error, var(--pf-field-error));\n font-size: var(--font-size-sm);\n margin: 0;\n}\n\n.input {\n background: var(--pf-input-bg);\n border: 1px solid var(--pf-input-border);\n border-radius: var(--radius-md);\n color: var(--pf-input-text);\n font: inherit;\n min-height: 40px;\n padding: 0 var(--space-3);\n width: 100%;\n transition:\n background 0.2s,\n border 0.2s,\n color 0.2s,\n opacity 0.2s;\n}\n\n.input:disabled {\n background: var(--pf-control-bg-disabled);\n border-color: var(--pf-control-border-disabled);\n color: var(--pf-control-text-disabled);\n cursor: not-allowed;\n opacity: 0.6;\n}\n\n.input:focus {\n outline: none;\n}\n\n.input:focus-visible {\n border-color: var(--pf-input-focus-border);\n box-shadow: var(--pf-input-focus-ring, var(--pf-focus-ring));\n}\n\n.input::placeholder {\n color: var(--pf-input-placeholder);\n}\n\n.input--invalid {\n border-color: var(--pf-input-invalid-border);\n}\n\n@media (prefers-reduced-motion: reduce) {\n .input {\n transition: none;\n }\n}\n","import { composeDescribedBy } from '@pitchfork-ui/core';\nimport { applyControlValidity } from '../../form-validity';\nimport { controlAriaLabel } from '../../control-label';\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Method,\n Prop,\n Watch,\n} from '@stencil/core';\n\nexport type PfInputType = 'text' | 'email' | 'password' | 'search' | 'tel' | 'url';\n\n/**\n * A form-associated text input.\n *\n * `formAssociated` plus `ElementInternals` is what makes this participate in a\n * real `<form>`: the value reaches `FormData`, constraint validation works, and\n * Angular's generated value accessor has something to bind to. A plain\n * `<input>` inside a shadow root does none of that.\n *\n * @part field - the wrapper around label, control and messages.\n * @part label - the label element.\n * @part input - the native input.\n * @part description - the hint text below the control.\n * @part error - the error message below the control.\n */\n@Component({\n tag: 'pf-input',\n styleUrl: 'pf-input.css',\n formAssociated: true,\n shadow: { delegatesFocus: true },\n})\nexport class PfInput {\n @Element() el!: HTMLElement;\n\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * Submitted under this name.\n *\n * Reflected, because a form-associated custom element takes its submission\n * name from the `name` *content attribute* -- not from this property. A\n * framework wrapper that sets properties rather than attributes (the\n * generated React bindings do) would otherwise leave the control nameless\n * and absent from the submission, with every other sign of working.\n */\n @Prop({ reflect: true }) name?: string;\n\n /** The control's value. */\n @Prop({ mutable: true }) value = '';\n\n @Prop({ reflect: true }) type: PfInputType = 'text';\n\n /** Visible label. Rendered in the same root as the input, so `for` works. */\n @Prop() label?: string;\n\n /** Hint text below the control. */\n @Prop() description?: string;\n\n /** Error message. Its presence is what marks the control invalid. */\n @Prop() error?: string;\n\n @Prop() placeholder?: string;\n\n @Prop({ reflect: true }) required = false;\n\n @Prop({ reflect: true }) disabled = false;\n\n @Prop({ reflect: true }) readonly = false;\n\n /** Fires on every keystroke, like the native `input` event. */\n @Event() pfInput!: EventEmitter<{ value: string }>;\n\n /** Fires when the value is committed, like the native `change` event. */\n @Event() pfChange!: EventEmitter<{ value: string }>;\n\n /**\n * The value the control had when it was created, which is what a form reset\n * restores. Captured here because `value` has been overwritten by then.\n */\n private initialValue = '';\n\n componentWillLoad() {\n this.initialValue = this.value ?? '';\n this.syncFormState();\n }\n\n @Watch('value')\n @Watch('error')\n @Watch('required')\n syncFormState() {\n this.internals.setFormValue(this.value ?? '');\n applyControlValidity(this.internals, Boolean(this.value), this.required, this.error);\n }\n\n /**\n * Whether the control currently satisfies its constraints.\n *\n * A form-associated custom element does not inherit `checkValidity` from\n * anywhere -- the spec puts it on ElementInternals, so the element has to\n * forward it or consumers cannot ask.\n */\n @Method()\n async checkValidity(): Promise<boolean> {\n return this.internals.checkValidity();\n }\n\n /** As `checkValidity`, but also shows the browser's validation message. */\n @Method()\n async reportValidity(): Promise<boolean> {\n return this.internals.reportValidity();\n }\n\n /** The message explaining why the control is invalid, or an empty string. */\n @Method()\n async getValidationMessage(): Promise<string> {\n return this.internals.validationMessage;\n }\n\n /**\n * A reset restores the value the control started with, not an empty string —\n * verified against a native `<input value=\"initial\">`, which comes back to\n * \"initial\" rather than to \"\". Clearing it was a real defect: a\n * `<pf-input value=\"…\">` in a form lost its value on any reset.\n */\n formResetCallback() {\n this.value = this.initialValue;\n }\n\n private onInput = (event: Event) => {\n this.value = (event.target as HTMLInputElement).value;\n this.pfInput.emit({ value: this.value });\n };\n\n private onChange = () => {\n this.pfChange.emit({ value: this.value });\n };\n\n render() {\n // IDs are scoped to this shadow root, so they can be literal -- the useId()\n // the React component needs has no counterpart here.\n const describedBy = composeDescribedBy(\n this.description && 'description',\n this.error && 'error',\n );\n\n return (\n <Host>\n <div class=\"field\" part=\"field\">\n {this.label && (\n <label class=\"label\" part=\"label\" htmlFor=\"input\">\n {this.label}\n {this.required && (\n <span class=\"required\" aria-hidden=\"true\">\n *\n </span>\n )}\n </label>\n )}\n <input\n id=\"input\"\n aria-label={controlAriaLabel(this.el, this.label)}\n part=\"input\"\n class={{ input: true, 'input--invalid': Boolean(this.error) }}\n type={this.type}\n name={this.name}\n value={this.value}\n placeholder={this.placeholder}\n required={this.required}\n disabled={this.disabled}\n readOnly={this.readonly}\n aria-invalid={this.error ? 'true' : null}\n aria-describedby={describedBy}\n onInput={this.onInput}\n onChange={this.onChange}\n />\n {this.description && (\n <p class=\"description\" part=\"description\" id=\"description\">\n {this.description}\n </p>\n )}\n {this.error && (\n <p class=\"error\" part=\"error\" id=\"error\">\n {this.error}\n </p>\n )}\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"4KAAA,MAAMA,EAAa,IAAM,qxC,MCsCZC,EAAO,M,kRAGCC,UAWMC,KAGAC,MAAQ,GAERC,KAAoB,OAGrCC,MAGAC,YAGAC,MAEAC,YAEiBC,SAAW,MAEXC,SAAW,MAEXC,SAAW,MAG3BC,QAGAC,SAMDC,aAAe,GAEvB,iBAAAC,GACEC,KAAKF,aAAeE,KAAKb,OAAS,GAClCa,KAAKC,e,CAMP,aAAAA,GACED,KAAKf,UAAUiB,aAAaF,KAAKb,OAAS,IAC1CgB,EAAqBH,KAAKf,UAAWmB,QAAQJ,KAAKb,OAAQa,KAAKP,SAAUO,KAAKT,M,CAWhF,mBAAMc,GACJ,OAAOL,KAAKf,UAAUoB,e,CAKxB,oBAAMC,GACJ,OAAON,KAAKf,UAAUqB,gB,CAKxB,0BAAMC,GACJ,OAAOP,KAAKf,UAAUuB,iB,CASxB,iBAAAC,GACET,KAAKb,MAAQa,KAAKF,Y,CAGZY,QAAWC,IACjBX,KAAKb,MAASwB,EAAMC,OAA4BzB,MAChDa,KAAKJ,QAAQiB,KAAK,CAAE1B,MAAOa,KAAKb,OAAQ,EAGlC2B,SAAW,KACjBd,KAAKH,SAASgB,KAAK,CAAE1B,MAAOa,KAAKb,OAAQ,EAG3C,MAAA4B,GAGE,MAAMC,EAAcC,EAClBjB,KAAKV,aAAe,cACpBU,KAAKT,OAAS,SAGhB,OACE2B,EAACC,EAAI,CAAAC,IAAA,4CACHF,EAAA,OAAAE,IAAA,2CAAKC,MAAM,QAAQC,KAAK,SACrBtB,KAAKX,OACJ6B,EAAA,SAAAE,IAAA,2CAAOC,MAAM,QAAQC,KAAK,QAAQC,QAAQ,SACvCvB,KAAKX,MACLW,KAAKP,UACJyB,EAAA,QAAAE,IAAA,2CAAMC,MAAM,WAAU,cAAa,QAAM,MAM/CH,EAAA,SAAAE,IAAA,2CACEI,GAAG,QAAO,aACEC,EAAiBzB,KAAK0B,GAAI1B,KAAKX,OAC3CiC,KAAK,QACLD,MAAO,CAAEM,MAAO,KAAM,iBAAkBvB,QAAQJ,KAAKT,QACrDH,KAAMY,KAAKZ,KACXF,KAAMc,KAAKd,KACXC,MAAOa,KAAKb,MACZK,YAAaQ,KAAKR,YAClBC,SAAUO,KAAKP,SACfC,SAAUM,KAAKN,SACfkC,SAAU5B,KAAKL,SAAQ,eACTK,KAAKT,MAAQ,OAAS,KAAI,mBACtByB,EAClBN,QAASV,KAAKU,QACdI,SAAUd,KAAKc,WAEhBd,KAAKV,aACJ4B,EAAA,KAAAE,IAAA,2CAAGC,MAAM,cAAcC,KAAK,cAAcE,GAAG,eAC1CxB,KAAKV,aAGTU,KAAKT,OACJ2B,EAAA,KAAAE,IAAA,2CAAGC,MAAM,QAAQC,KAAK,QAAQE,GAAG,SAC9BxB,KAAKT,Q","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as t,c as e,a as i,h as s,H as r}from"./p-Bm6UxEit.js";import{o as a,p as o}from"./p-CC7AyfOt.js";import{c as n}from"./p-DfpCerXM.js";import{i as l,K as c}from"./p-g4FlTDZx.js";import{g as h,r as p}from"./p-CAz7-p8y.js";import{b as d,p as f,a as u,f as b}from"./p-BmcsJLdy.js";import{a as m}from"./p-Cr6IXrUk.js";import{c as v}from"./p-Cy_kHPeC.js";const g=()=>`:host{display:block;--pf-option-text:var(--pf-multiselect-text);--pf-option-text-disabled:var(--pf-multiselect-text-muted);--pf-option-active-bg:var(--pf-multiselect-active-bg);--pf-option-active-text:var(--pf-multiselect-active-text)}:host([hidden]){display:none}.field{display:grid;gap:var(--space-1)}.label{color:var(--pf-multiselect-text);font-size:var(--font-size-sm);font-weight:var(--font-weight-medium)}.required{color:var(--pf-multiselect-invalid-border);margin-inline-start:var(--space-1)}.trigger{align-items:center;background:var(--pf-multiselect-bg);border:1px solid var(--pf-multiselect-border);border-radius:var(--radius-md);color:var(--pf-multiselect-text);cursor:pointer;display:flex;font-family:inherit;font-size:var(--font-size-sm);gap:var(--space-2);justify-content:space-between;padding:var(--space-2) var(--space-3);text-align:start;width:100%}.trigger:focus-visible{border-color:var(--pf-multiselect-focus-border);box-shadow:var(--pf-focus-ring);outline:none}.trigger:disabled{cursor:not-allowed;opacity:0.6}.trigger--invalid{border-color:var(--pf-multiselect-invalid-border)}.chips{display:flex;flex-wrap:wrap;gap:var(--space-1);min-width:0}.chip{background:var(--pf-multiselect-bg-subtle);border-radius:var(--radius-sm);font-size:var(--font-size-xs);padding:2px var(--space-2)}.placeholder{color:var(--pf-multiselect-text-muted)}.chevron{align-items:center;display:inline-flex;flex-shrink:0;transition:transform var(--pf-transition-fast)}:host([open]) .chevron{transform:rotate(180deg)}@media (prefers-reduced-motion: reduce){.chevron{transition:none}}.description{color:var(--pf-multiselect-text-muted);font-size:var(--font-size-xs);margin:0}.error{color:var(--pf-multiselect-invalid-border);font-size:var(--font-size-xs);margin:0}.listbox{inset:auto;margin:0;background:var(--pf-multiselect-bg);border:1px solid var(--pf-multiselect-border);border-radius:var(--radius-md);box-shadow:var(--pf-elevation-popover-shadow);padding:var(--space-1)}.listbox:popover-open{animation:pf-multi-select-in var(--pf-transition-enter)}@keyframes pf-multi-select-in{from{opacity:0;transform:translateY(-4px)}}@media (prefers-reduced-motion: reduce){.listbox:popover-open{animation:none}}`;const y={[c.ArrowDown]:"next",[c.ArrowUp]:"previous",[c.Home]:"first",[c.End]:"last"};const x=class{constructor(i){t(this,i);this.pfChange=e(this,"pfChange");this.pfOpenChange=e(this,"pfOpenChange");if(i.$hostElement$["s-ei"]){this.internals=i.$hostElement$["s-ei"]}else{this.internals=i.$hostElement$.attachInternals();i.$hostElement$["s-ei"]=this.internals}}get el(){return i(this)}internals;name;value="";open=false;label;description;error;placeholder="Select options";required=false;disabled=false;maxVisibleOptions;pfChange;pfOpenChange;chips=[];initialValue="";stopObserving;activeOption=null;warnedAboutSeparator=false;componentWillLoad(){this.initialValue=this.value??"";this.syncFormState();this.syncOptions()}componentDidRender(){this.syncActiveDescendant()}disconnectedCallback(){this.stopObserving?.()}syncFormState(){const t=this.values();if(t.length===0||!this.name){this.internals.setFormValue(null)}else{const e=new FormData;for(const i of t)e.append(this.name,i);this.internals.setFormValue(e)}m(this.internals,t.length>0,this.required,this.error)}syncOptions(){const t=this.values();const e=[];for(const e of this.options()){const i=t.includes(this.optionValue(e));e.selected=i}for(const i of t){const t=this.options().find((t=>this.optionValue(t)===i));if(t)e.push(t.textContent?.trim()??i)}this.chips=e;this.warnAboutSeparators()}warnAboutSeparators(){if(this.warnedAboutSeparator)return;const t=d(this.options().map((t=>this.optionValue(t))));if(t.length===0)return;this.warnedAboutSeparator=true;console.warn(`[pf-multi-select] option values cannot contain a comma, because \`value\` is a `+`comma-separated list: ${t.join(" ")}`)}syncOpen(t,e){if(t)this.showListbox();else this.hideListbox();if(t!==e)this.pfOpenChange.emit({open:t})}async show(){if(!this.disabled)this.open=true}async hide(){this.open=false}async checkValidity(){return this.internals.checkValidity()}async reportValidity(){return this.internals.reportValidity()}async getValidationMessage(){return this.internals.validationMessage}formResetCallback(){this.value=this.initialValue}async refresh(){this.syncOptions()}onSlotChange=()=>{this.syncOptions()};values(){return f(this.value)}options(){return Array.from(this.el.querySelectorAll("pf-option"))}enabled(){return this.options().filter((t=>!t.hasAttribute("disabled")))}optionValue(t){return t.value??t.getAttribute("value")??""}get listbox(){return this.el.shadowRoot?.querySelector('[part="listbox"]')??null}get trigger(){return this.el.shadowRoot?.querySelector('[part="trigger"]')??null}showListbox(){const t=this.listbox;if(this.disabled||!t||t.matches(":popover-open"))return;t.showPopover();this.stopObserving?.();this.stopObserving=a({getAnchor:()=>this.trigger,getFloating:()=>t,matchAnchorWidth:true,flip:true,onChange:({left:e,top:i,width:s,minWidth:r})=>{o(t,e,i);if(s!==undefined)t.style.width=`${s}px`;if(r!==undefined)t.style.minWidth=`${r}px`}});const e=this.values();const i=this.options().find((t=>e.includes(this.optionValue(t))&&!t.hasAttribute("disabled")))??this.enabled()[0];this.setActive(i??null)}hideListbox(){this.stopObserving?.();this.stopObserving=undefined;const t=this.listbox;if(t?.matches(":popover-open"))t.hidePopover()}onToggle=t=>{const e=t.newState==="open";if(this.open!==e)this.open=e;if(!e)this.trigger?.focus()};setActive(t){for(const e of this.options()){if(e!==t)e.active=false}if(t)t.active=true;this.activeOption=t;this.syncActiveDescendant();if(t&&typeof t.scrollIntoView==="function"){t.scrollIntoView({block:"nearest"})}}syncActiveDescendant(){const t=this.trigger;if(!t||!("ariaActiveDescendantElement"in t))return;t.ariaActiveDescendantElement=this.open?this.activeOption:null}toggle(t){if(t.hasAttribute("disabled")||this.disabled)return;const e=u(this.values(),this.optionValue(t));this.value=b(e);this.pfChange.emit({value:this.value,values:e})}handleOptionSelect(t){t.stopPropagation();const e=this.options().find((e=>this.optionValue(e)===t.detail.value));if(e)this.toggle(e)}move(t){const e=this.options();const i=h(e,(t=>t.hasAttribute("disabled")));const s=this.activeOption?e.indexOf(this.activeOption):-1;const r=p(t,i,s);if(r!==-1)this.setActive(e[r]??null)}handleKeyDown(t){if(this.disabled||t.defaultPrevented)return;const e=y[t.key];if(e){t.preventDefault();if(!this.open)this.open=true;else this.move(e);return}if(l(t.key)){t.preventDefault();if(!this.open)this.open=true;else if(this.activeOption)this.toggle(this.activeOption)}}render(){const t=n(this.description&&"description",this.error&&"error");return s(r,{key:"84f645358443d6dc41515a835cf0c7136a6f2a30"},s("div",{key:"2abaf9886654a5cef6756a4c566f61e37c7c876a",class:"field",part:"field"},this.label&&s("label",{key:"76f9cf451c6fba652494862a0fa05e320a4790c4",class:"label",part:"label",htmlFor:"trigger"},this.label,this.required&&s("span",{key:"9f4a8074bc2ef06ae7256267bab07d9baf52dc2c",class:"required","aria-hidden":"true"},"*")),s("button",{key:"a5a15ff1c857e6f727bc43131741ee95ba345efd",id:"trigger","aria-label":v(this.el,this.label),part:"trigger",class:{trigger:true,"trigger--invalid":Boolean(this.error)},type:"button",role:"combobox",disabled:this.disabled,"aria-haspopup":"listbox","aria-expanded":this.open?"true":"false","aria-controls":"listbox","aria-invalid":this.error?"true":null,"aria-required":this.required?"true":null,"aria-describedby":t,onClick:()=>{if(!this.disabled)this.open=!this.open}},this.chips.length>0?s("span",{class:"chips"},this.chips.map((t=>s("span",{key:t,class:"chip",part:"chip"},t)))):s("span",{class:"placeholder"},this.placeholder),s("span",{key:"9b662f3899c243059b07b4ecc0166b74b97501cc",class:"chevron","aria-hidden":"true"},s("pf-icon",{key:"5a869e8d9d1aa023e57ed556afc613544f54424f",name:"chevron-down"}))),this.description&&s("p",{key:"d231f94ad697dc52d3115cf13c0b47f0b20045a6",class:"description",part:"description",id:"description"},this.description),this.error&&s("p",{key:"dcc0995d743ea214575031de7225f0bce71aebb6",class:"error",part:"error",id:"error"},this.error)),s("div",{key:"c161c902c9859dd71dda4967dc4e074db29dd448",id:"listbox",part:"listbox",class:"listbox",popover:"auto",role:"listbox","aria-multiselectable":"true","aria-label":this.label??this.placeholder,style:this.maxVisibleOptions?{maxHeight:`calc(${this.maxVisibleOptions} * 36px)`,overflowY:"auto"}:undefined,onToggle:this.onToggle},s("slot",{key:"8fec52209e91211ba15d8c32f53d111b2058b76f",onSlotchange:this.onSlotChange})))}static get formAssociated(){return true}static get watchers(){return{name:[{syncFormState:0}],value:[{syncFormState:0},{syncOptions:0}],error:[{syncFormState:0}],required:[{syncFormState:0}],open:[{syncOpen:0}]}}};x.style=g();export{x as pf_multi_select};
2
+ //# sourceMappingURL=p-ec8df806.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["pfMultiSelectCss","MOVES","Keys","ArrowDown","ArrowUp","Home","End","PfMultiSelect","internals","name","value","open","label","description","error","placeholder","required","disabled","maxVisibleOptions","pfChange","pfOpenChange","chips","initialValue","stopObserving","activeOption","warnedAboutSeparator","componentWillLoad","this","syncFormState","syncOptions","componentDidRender","syncActiveDescendant","disconnectedCallback","values","length","setFormValue","data","FormData","append","applyControlValidity","chosen","labels","option","options","selected","includes","optionValue","find","candidate","push","textContent","trim","warnAboutSeparators","offenders","assertSeparableValues","map","o","console","warn","join","syncOpen","next","previous","showListbox","hideListbox","emit","show","hide","checkValidity","reportValidity","getValidationMessage","validationMessage","formResetCallback","refresh","onSlotChange","parseValueList","Array","from","el","querySelectorAll","enabled","filter","hasAttribute","getAttribute","listbox","shadowRoot","querySelector","trigger","panel","matches","showPopover","observeAnchoredPosition","getAnchor","getFloating","matchAnchorWidth","flip","onChange","left","top","width","minWidth","placePopover","undefined","style","first","setActive","hidePopover","onToggle","event","nowOpen","newState","focus","other","active","scrollIntoView","block","ariaActiveDescendantElement","toggle","toggleValueInList","formatValueList","handleOptionSelect","stopPropagation","detail","move","action","enabledIndexes","getEnabledIndexes","current","indexOf","resolveListMove","handleKeyDown","defaultPrevented","key","preventDefault","isActivationKey","render","describedBy","composeDescribedBy","h","Host","class","part","htmlFor","id","controlAriaLabel","Boolean","type","role","onClick","chip","popover","maxHeight","overflowY","onSlotchange"],"sources":["src/components/pf-multi-select/pf-multi-select.css?tag=pf-multi-select&encapsulation=shadow","src/components/pf-multi-select/pf-multi-select.tsx"],"sourcesContent":["/*\n * The generic set pf-option reads, mapped to this control's own family — see\n * pf-option.css.\n */\n:host {\n display: block;\n --pf-option-text: var(--pf-multiselect-text);\n --pf-option-text-disabled: var(--pf-multiselect-text-muted);\n --pf-option-active-bg: var(--pf-multiselect-active-bg);\n --pf-option-active-text: var(--pf-multiselect-active-text);\n}\n\n:host([hidden]) {\n display: none;\n}\n\n.field {\n display: grid;\n gap: var(--space-1);\n}\n\n.label {\n color: var(--pf-multiselect-text);\n font-size: var(--font-size-sm);\n font-weight: var(--font-weight-medium);\n}\n\n.required {\n color: var(--pf-multiselect-invalid-border);\n margin-inline-start: var(--space-1);\n}\n\n.trigger {\n align-items: center;\n background: var(--pf-multiselect-bg);\n border: 1px solid var(--pf-multiselect-border);\n border-radius: var(--radius-md);\n color: var(--pf-multiselect-text);\n cursor: pointer;\n display: flex;\n font-family: inherit;\n font-size: var(--font-size-sm);\n gap: var(--space-2);\n justify-content: space-between;\n padding: var(--space-2) var(--space-3);\n text-align: start;\n width: 100%;\n}\n\n.trigger:focus-visible {\n border-color: var(--pf-multiselect-focus-border);\n box-shadow: var(--pf-focus-ring);\n outline: none;\n}\n\n.trigger:disabled {\n cursor: not-allowed;\n opacity: 0.6;\n}\n\n.trigger--invalid {\n border-color: var(--pf-multiselect-invalid-border);\n}\n\n.chips {\n display: flex;\n flex-wrap: wrap;\n gap: var(--space-1);\n min-width: 0;\n}\n\n.chip {\n background: var(--pf-multiselect-bg-subtle);\n border-radius: var(--radius-sm);\n font-size: var(--font-size-xs);\n padding: 2px var(--space-2);\n}\n\n.placeholder {\n color: var(--pf-multiselect-text-muted);\n}\n\n.chevron {\n align-items: center;\n display: inline-flex;\n flex-shrink: 0;\n transition: transform var(--pf-transition-fast);\n}\n\n:host([open]) .chevron {\n transform: rotate(180deg);\n}\n\n@media (prefers-reduced-motion: reduce) {\n .chevron {\n transition: none;\n }\n}\n\n.description {\n color: var(--pf-multiselect-text-muted);\n font-size: var(--font-size-xs);\n margin: 0;\n}\n\n.error {\n color: var(--pf-multiselect-invalid-border);\n font-size: var(--font-size-xs);\n margin: 0;\n}\n\n/* See src/place-popover.ts: the UA stylesheet centres a popover otherwise. */\n.listbox {\n inset: auto;\n margin: 0;\n background: var(--pf-multiselect-bg);\n border: 1px solid var(--pf-multiselect-border);\n border-radius: var(--radius-md);\n box-shadow: var(--pf-elevation-popover-shadow);\n padding: var(--space-1);\n}\n\n.listbox:popover-open {\n animation: pf-multi-select-in var(--pf-transition-enter);\n}\n\n/* Its own copy: @keyframes do not cross a shadow boundary. */\n@keyframes pf-multi-select-in {\n from {\n opacity: 0;\n transform: translateY(-4px);\n }\n}\n\n@media (prefers-reduced-motion: reduce) {\n .listbox:popover-open {\n animation: none;\n }\n}\n","import {\n composeDescribedBy,\n formatValueList,\n getEnabledIndexes,\n isActivationKey,\n Keys,\n observeAnchoredPosition,\n parseValueList,\n resolveListMove,\n toggleValueInList,\n assertSeparableValues,\n type ListNavigationAction,\n} from '@pitchfork-ui/core';\n\nimport { applyControlValidity } from '../../form-validity';\nimport { controlAriaLabel } from '../../control-label';\nimport { placePopover } from '../../place-popover';\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Method,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\n\nconst MOVES: Record<string, ListNavigationAction> = {\n [Keys.ArrowDown]: 'next',\n [Keys.ArrowUp]: 'previous',\n [Keys.Home]: 'first',\n [Keys.End]: 'last',\n};\n\n/**\n * A form-associated multi-choice select over `pf-option` children.\n *\n * **It submits one entry per chosen value from a single control.**\n * `setFormValue` takes a `FormData`, and a key repeated in it is submitted\n * once per value — measured, and the same shape the React component gets from\n * rendering one hidden `<input>` per selection. So a server reads\n * `data.getAll(name)` exactly as it would from a native multiple select.\n *\n * `value` is one comma-separated string, because that is what an attribute can\n * carry; `pfChange` also reports the parsed `values` array, which is what a\n * framework consumer usually wants. A value containing a comma cannot survive\n * that, so one is reported on the console rather than silently mangled.\n *\n * Shares `pf-option` with `pf-select` and `pf-combobox` through the generic\n * `--pf-option-*` set.\n *\n * @slot - the `pf-option` children.\n * @part field - the wrapper around label, control and messages.\n * @part label - the label element.\n * @part trigger - the combobox button.\n * @part chip - each chosen value's chip in the trigger.\n * @part listbox - the floating listbox the options are slotted into.\n * @part description - the hint text below the control.\n * @part error - the error message below the control.\n */\n@Component({\n tag: 'pf-multi-select',\n styleUrl: 'pf-multi-select.css',\n formAssociated: true,\n shadow: true,\n})\nexport class PfMultiSelect {\n @Element() el!: HTMLElement;\n @AttachInternals() internals!: ElementInternals;\n\n /** Submitted under this name, once per chosen value. Reflected. */\n @Prop({ reflect: true }) name?: string;\n\n /** The chosen values, comma-separated. Reflected, so HTML can set it. */\n @Prop({ mutable: true, reflect: true }) value = '';\n\n /** Whether the listbox is showing. Reflected for the stylesheet. */\n @Prop({ mutable: true, reflect: true }) open = false;\n\n @Prop() label?: string;\n\n @Prop() description?: string;\n\n @Prop() error?: string;\n\n @Prop() placeholder = 'Select options';\n\n @Prop({ reflect: true }) required = false;\n\n @Prop({ reflect: true }) disabled = false;\n\n /** Options to show before the listbox scrolls. */\n @Prop() maxVisibleOptions?: number;\n\n /** Fires when the chosen set changes, with both representations. */\n @Event() pfChange!: EventEmitter<{ value: string; values: string[] }>;\n\n /** Fires whenever the listbox opens or closes, whoever caused it. */\n @Event() pfOpenChange!: EventEmitter<{ open: boolean }>;\n\n /** The labels of the chosen options, for the trigger's chips. */\n @State() chips: string[] = [];\n\n private initialValue = '';\n private stopObserving?: () => void;\n private activeOption: HTMLElement | null = null;\n private warnedAboutSeparator = false;\n\n componentWillLoad() {\n this.initialValue = this.value ?? '';\n this.syncFormState();\n this.syncOptions();\n }\n\n componentDidRender() {\n this.syncActiveDescendant();\n }\n\n disconnectedCallback() {\n this.stopObserving?.();\n }\n\n /*\n * `name` is watched here and not on the controls that pass a plain string to\n * `setFormValue`: those take their submission name from the reflected\n * attribute, so the platform picks a change up by itself. This one builds\n * the name *into* a FormData, so without the watch a name assigned after\n * load would never reach the submission.\n */\n @Watch('name')\n @Watch('value')\n @Watch('error')\n @Watch('required')\n syncFormState() {\n const values = this.values();\n\n if (values.length === 0 || !this.name) {\n this.internals.setFormValue(null);\n } else {\n // One entry per value under the one name, which `data.getAll(name)`\n // reads back as an array.\n const data = new FormData();\n for (const value of values) data.append(this.name, value);\n this.internals.setFormValue(data);\n }\n\n applyControlValidity(this.internals, values.length > 0, this.required, this.error);\n }\n\n /** The value changed, so the children's `selected` and the chips follow. */\n @Watch('value')\n syncOptions() {\n const chosen = this.values();\n const labels: string[] = [];\n\n for (const option of this.options()) {\n const selected = chosen.includes(this.optionValue(option));\n (option as HTMLElement & { selected: boolean }).selected = selected;\n }\n\n // Chips in the order they were chosen, not the options' order.\n for (const value of chosen) {\n const option = this.options().find((candidate) => this.optionValue(candidate) === value);\n if (option) labels.push(option.textContent?.trim() ?? value);\n }\n\n this.chips = labels;\n this.warnAboutSeparators();\n }\n\n /**\n * One warning naming every offending value.\n *\n * A value holding a comma cannot round-trip through `value`, and failing\n * silently would show the right chips over a wrong submission.\n */\n private warnAboutSeparators() {\n if (this.warnedAboutSeparator) return;\n const offenders = assertSeparableValues(this.options().map((o) => this.optionValue(o)));\n if (offenders.length === 0) return;\n\n this.warnedAboutSeparator = true;\n console.warn(\n `[pf-multi-select] option values cannot contain a comma, because \\`value\\` is a ` +\n `comma-separated list: ${offenders.join(' ')}`,\n );\n }\n\n @Watch('open')\n syncOpen(next: boolean, previous: boolean) {\n if (next) this.showListbox();\n else this.hideListbox();\n if (next !== previous) this.pfOpenChange.emit({ open: next });\n }\n\n @Method()\n async show(): Promise<void> {\n if (!this.disabled) this.open = true;\n }\n\n @Method()\n async hide(): Promise<void> {\n this.open = false;\n }\n\n @Method()\n async checkValidity(): Promise<boolean> {\n return this.internals.checkValidity();\n }\n\n @Method()\n async reportValidity(): Promise<boolean> {\n return this.internals.reportValidity();\n }\n\n @Method()\n async getValidationMessage(): Promise<string> {\n return this.internals.validationMessage;\n }\n\n formResetCallback() {\n this.value = this.initialValue;\n }\n\n /** Re-reads the options, for a label edited in place. */\n @Method()\n async refresh(): Promise<void> {\n this.syncOptions();\n }\n\n private onSlotChange = () => {\n this.syncOptions();\n };\n\n private values(): string[] {\n return parseValueList(this.value);\n }\n\n private options(): HTMLElement[] {\n return Array.from(this.el.querySelectorAll<HTMLElement>('pf-option'));\n }\n\n private enabled(): HTMLElement[] {\n return this.options().filter((option) => !option.hasAttribute('disabled'));\n }\n\n /** The property, never the attribute: a binding may only have set the former. */\n private optionValue(option: HTMLElement): string {\n return (option as HTMLElement & { value?: string }).value ?? option.getAttribute('value') ?? '';\n }\n\n private get listbox() {\n return this.el.shadowRoot?.querySelector<HTMLElement>('[part=\"listbox\"]') ?? null;\n }\n\n private get trigger() {\n return this.el.shadowRoot?.querySelector<HTMLButtonElement>('[part=\"trigger\"]') ?? null;\n }\n\n private showListbox() {\n const panel = this.listbox;\n if (this.disabled || !panel || panel.matches(':popover-open')) return;\n\n panel.showPopover();\n this.stopObserving?.();\n this.stopObserving = observeAnchoredPosition({\n getAnchor: () => this.trigger,\n getFloating: () => panel,\n matchAnchorWidth: true,\n flip: true,\n onChange: ({ left, top, width, minWidth }) => {\n placePopover(panel, left, top);\n if (width !== undefined) panel.style.width = `${width}px`;\n if (minWidth !== undefined) panel.style.minWidth = `${minWidth}px`;\n },\n });\n\n // Opens on the first chosen option, or the first selectable one.\n const chosen = this.values();\n const first =\n this.options().find(\n (option) => chosen.includes(this.optionValue(option)) && !option.hasAttribute('disabled'),\n ) ?? this.enabled()[0];\n this.setActive(first ?? null);\n }\n\n private hideListbox() {\n this.stopObserving?.();\n this.stopObserving = undefined;\n const panel = this.listbox;\n if (panel?.matches(':popover-open')) panel.hidePopover();\n }\n\n private onToggle = (event: ToggleEvent) => {\n const nowOpen = event.newState === 'open';\n if (this.open !== nowOpen) this.open = nowOpen;\n if (!nowOpen) this.trigger?.focus();\n };\n\n private setActive(option: HTMLElement | null) {\n for (const other of this.options()) {\n if (other !== option) (other as HTMLElement & { active: boolean }).active = false;\n }\n if (option) (option as HTMLElement & { active: boolean }).active = true;\n\n this.activeOption = option;\n this.syncActiveDescendant();\n if (option && typeof option.scrollIntoView === 'function') {\n option.scrollIntoView({ block: 'nearest' });\n }\n }\n\n /** An element, not an IDREF: a cross-root IDREF resolves to nothing. */\n private syncActiveDescendant() {\n const trigger = this.trigger;\n if (!trigger || !('ariaActiveDescendantElement' in trigger)) return;\n (\n trigger as unknown as { ariaActiveDescendantElement: Element | null }\n ).ariaActiveDescendantElement = this.open ? this.activeOption : null;\n }\n\n /**\n * Toggles one value and keeps the listbox open — the difference from\n * `pf-select`, and the whole point of a multi-choice control: closing after\n * each pick would make choosing three things three round trips.\n */\n private toggle(option: HTMLElement) {\n if (option.hasAttribute('disabled') || this.disabled) return;\n\n const next = toggleValueInList(this.values(), this.optionValue(option));\n this.value = formatValueList(next);\n this.pfChange.emit({ value: this.value, values: next });\n }\n\n @Listen('pfOptionSelect')\n handleOptionSelect(event: CustomEvent<{ value: string }>) {\n event.stopPropagation();\n const option = this.options().find(\n (candidate) => this.optionValue(candidate) === event.detail.value,\n );\n if (option) this.toggle(option);\n }\n\n private move(action: ListNavigationAction) {\n const options = this.options();\n const enabledIndexes = getEnabledIndexes(options, (option) => option.hasAttribute('disabled'));\n const current = this.activeOption ? options.indexOf(this.activeOption) : -1;\n const next = resolveListMove(action, enabledIndexes, current);\n if (next !== -1) this.setActive(options[next] ?? null);\n }\n\n @Listen('keydown')\n handleKeyDown(event: KeyboardEvent) {\n if (this.disabled || event.defaultPrevented) return;\n\n const move = MOVES[event.key];\n if (move) {\n event.preventDefault();\n if (!this.open) this.open = true;\n else this.move(move);\n return;\n }\n\n if (isActivationKey(event.key)) {\n event.preventDefault();\n if (!this.open) this.open = true;\n else if (this.activeOption) this.toggle(this.activeOption);\n }\n }\n\n render() {\n const describedBy = composeDescribedBy(\n this.description && 'description',\n this.error && 'error',\n );\n\n return (\n <Host>\n <div class=\"field\" part=\"field\">\n {this.label && (\n <label class=\"label\" part=\"label\" htmlFor=\"trigger\">\n {this.label}\n {this.required && (\n <span class=\"required\" aria-hidden=\"true\">\n *\n </span>\n )}\n </label>\n )}\n\n <button\n id=\"trigger\"\n aria-label={controlAriaLabel(this.el, this.label)}\n part=\"trigger\"\n class={{ trigger: true, 'trigger--invalid': Boolean(this.error) }}\n type=\"button\"\n role=\"combobox\"\n disabled={this.disabled}\n aria-haspopup=\"listbox\"\n aria-expanded={this.open ? 'true' : 'false'}\n /* Same shadow root as the listbox, so this IDREF resolves. */\n aria-controls=\"listbox\"\n aria-invalid={this.error ? 'true' : null}\n aria-required={this.required ? 'true' : null}\n aria-describedby={describedBy}\n onClick={() => {\n if (!this.disabled) this.open = !this.open;\n }}\n >\n {this.chips.length > 0 ? (\n <span class=\"chips\">\n {this.chips.map((chip) => (\n <span key={chip} class=\"chip\" part=\"chip\">\n {chip}\n </span>\n ))}\n </span>\n ) : (\n <span class=\"placeholder\">{this.placeholder}</span>\n )}\n <span class=\"chevron\" aria-hidden=\"true\">\n <pf-icon name=\"chevron-down\"></pf-icon>\n </span>\n </button>\n\n {this.description && (\n <p class=\"description\" part=\"description\" id=\"description\">\n {this.description}\n </p>\n )}\n {this.error && (\n <p class=\"error\" part=\"error\" id=\"error\">\n {this.error}\n </p>\n )}\n </div>\n\n <div\n id=\"listbox\"\n part=\"listbox\"\n class=\"listbox\"\n popover=\"auto\"\n role=\"listbox\"\n /* The one ARIA difference from pf-select, and the important one. */\n aria-multiselectable=\"true\"\n aria-label={this.label ?? this.placeholder}\n style={\n this.maxVisibleOptions\n ? { maxHeight: `calc(${this.maxVisibleOptions} * 36px)`, overflowY: 'auto' }\n : undefined\n }\n onToggle={this.onToggle}\n >\n <slot onSlotchange={this.onSlotChange} />\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"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","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as e,c as t,a,h as i,H as o}from"./p-Bm6UxEit.js";import{l as s}from"./p-C-VLyxRR.js";var n=e=>{if(typeof e.checkVisibility==="function")return e.checkVisibility();return e.offsetParent!==null||e.getClientRects().length>0};var r=e=>{const t=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[contenteditable]:not([contenteditable="false"])','[tabindex]:not([tabindex="-1"])'].join(",");return Array.from(e.querySelectorAll(t)).filter((e=>{if(e.hasAttribute("disabled")||e.getAttribute("aria-hidden")==="true")return false;return n(e)}))};const l=()=>`:host{display:contents}.dialog{align-items:center;background:none;border:0;display:none;height:100%;justify-content:center;max-height:100%;max-width:100%;padding:var(--space-4);width:100%}.dialog[open]{display:flex}.dialog::backdrop{background:var(--pf-modal-overlay-backdrop, var(--pf-overlay-backdrop))}.panel{background:var(--pf-modal-bg);border:1px solid var(--pf-modal-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-lg);color:var(--pf-modal-text);display:flex;flex-direction:column;max-height:100%;overflow:auto;position:relative;width:100%}:host([size='sm']) .panel{max-width:400px}:host([size='md']) .panel{max-width:560px}:host([size='lg']) .panel{max-width:800px}.close{background:none;border:0;border-radius:var(--radius-sm);color:var(--pf-modal-text-muted);cursor:pointer;display:inline-flex;inset-block-start:var(--space-3);inset-inline-end:var(--space-3);padding:var(--space-1);position:absolute}.close:hover{color:var(--pf-modal-text)}.close:focus-visible{box-shadow:var(--pf-focus-ring);outline:none}.dialog[open] .panel{animation:pf-modal-in var(--pf-transition-enter)}@keyframes pf-modal-in{from{opacity:0;transform:translateY(8px)}}@media (prefers-reduced-motion: reduce){.dialog[open] .panel{animation:none}}`;const d=class{constructor(a){e(this,a);this.pfOpenChange=t(this,"pfOpenChange")}get el(){return a(this)}open=false;size="md";label;dismissable=true;showCloseButton=true;pfOpenChange;releaseScroll=null;componentDidLoad(){if(this.open)this.showDialog()}disconnectedCallback(){this.unlockScroll()}async show(){this.open=true}async hide(){this.open=false}syncOpen(e,t){if(e)this.showDialog();else this.closeDialog();if(e!==t)this.pfOpenChange.emit({open:e})}get dialog(){return this.el.shadowRoot?.querySelector("dialog")??null}lockScroll(){if(this.releaseScroll)return;this.releaseScroll=s()}unlockScroll(){this.releaseScroll?.();this.releaseScroll=null}showDialog(){const e=this.dialog;if(!e||e.open)return;e.showModal();this.lockScroll();requestAnimationFrame((()=>this.ensureFocusInside()))}componentDidRender(){this.ensureFocusInside()}onFocusOut=e=>{if(!this.open||e.relatedTarget)return;requestAnimationFrame((()=>{if(document.hasFocus())this.ensureFocusInside()}))};ensureFocusInside(){const e=this.dialog;if(!this.open||!e?.isConnected||!e.open)return;if(e.matches(":focus-within"))return;const[t]=r(e);(t??e).focus()}closeDialog(){const e=this.dialog;this.unlockScroll();if(e?.open)e.close()}onCancel=e=>{if(!this.dismissable){e.preventDefault();return}};onClose=()=>{this.unlockScroll();if(this.open)this.open=false};onDialogClick=e=>{if(!this.dismissable||e.target!==this.dialog)return;this.open=false};accessibleName(){if(this.label)return this.label;const e=this.el.textContent?.trim();return e?e.slice(0,120):undefined}render(){return i(o,{key:"bf6b14acf276e7e327dad4e2adb0759c5371caa0"},i("dialog",{key:"fa8836858cd2ac18fe270c860671e77f5f9f6b93",part:"dialog",class:"dialog","aria-label":this.accessibleName(),onCancel:this.onCancel,onFocusout:this.onFocusOut,onClose:this.onClose,onClick:this.onDialogClick},i("div",{key:"6bfce72c9c19619388b93e3385b2fa8fe8fecc8e",class:"panel",part:"panel"},this.showCloseButton&&i("button",{key:"f11faa39f8854d5dd6854bb3c6e8e8e2f1abc6e3",class:"close",part:"close",type:"button","aria-label":"Close",onClick:()=>this.hide()},i("svg",{key:"7530bfc0821a2d09e6045589cbbf2d390e8c6897",viewBox:"0 0 16 16",width:"16",height:"16","aria-hidden":"true",focusable:"false"},i("path",{key:"74c4d8385baa9776cfdf23570f46fd1621bd3fa2",d:"M4 4l8 8M12 4l-8 8",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round",fill:"none"}))),i("slot",{key:"d11d9ae0716dc7f846ea05dc24689f0c6465057d"}))))}static get watchers(){return{open:[{syncOpen:0}]}}};d.style=l();export{d as pf_modal};
2
+ //# sourceMappingURL=p-f5df568f.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["isElementVisible","element","checkVisibility","offsetParent","getClientRects","length","getFocusableElements","container","selector","join","Array","from","querySelectorAll","filter","hasAttribute","getAttribute","pfModalCss","PfModal","open","size","label","dismissable","showCloseButton","pfOpenChange","releaseScroll","componentDidLoad","this","showDialog","disconnectedCallback","unlockScroll","show","hide","syncOpen","next","previous","closeDialog","emit","dialog","el","shadowRoot","querySelector","lockScroll","lockPageScroll","showModal","requestAnimationFrame","ensureFocusInside","componentDidRender","onFocusOut","event","relatedTarget","document","hasFocus","isConnected","matches","first","focus","close","onCancel","preventDefault","onClose","onDialogClick","target","accessibleName","text","textContent","trim","slice","undefined","render","h","Host","key","part","class","onFocusout","onClick","type","viewBox","width","height","focusable","d","stroke","fill"],"sources":["../core/dist/focus.js","src/components/pf-modal/pf-modal.css?tag=pf-modal&encapsulation=shadow","src/components/pf-modal/pf-modal.tsx"],"sourcesContent":["import { noop } from \"./internal.js\";\nimport { Keys } from \"./keys.js\";\n//#region src/focus.ts\nvar isElementVisible = (element) => {\n\tif (typeof element.checkVisibility === \"function\") return element.checkVisibility();\n\treturn element.offsetParent !== null || element.getClientRects().length > 0;\n};\nvar getFocusableElements = (container) => {\n\tconst selector = [\n\t\t\"a[href]\",\n\t\t\"button:not([disabled])\",\n\t\t\"input:not([disabled])\",\n\t\t\"select:not([disabled])\",\n\t\t\"textarea:not([disabled])\",\n\t\t\"[contenteditable]:not([contenteditable=\\\"false\\\"])\",\n\t\t\"[tabindex]:not([tabindex=\\\"-1\\\"])\"\n\t].join(\",\");\n\treturn Array.from(container.querySelectorAll(selector)).filter((element) => {\n\t\tif (element.hasAttribute(\"disabled\") || element.getAttribute(\"aria-hidden\") === \"true\") return false;\n\t\treturn isElementVisible(element);\n\t});\n};\n/**\n* Moves focus into the container and keeps Tab cycling inside it. Returns a\n* cleanup function that removes the listener and, unless told otherwise,\n* restores focus to the previously active element.\n*/\nfunction trapFocus({ getContainer, onEscape, restoreFocus = true }) {\n\tif (typeof document === \"undefined\") return noop;\n\tconst container = getContainer();\n\tconst previousActiveElement = document.activeElement;\n\tconst initialFocusable = container ? getFocusableElements(container)[0] : void 0;\n\tif (initialFocusable) initialFocusable.focus();\n\telse container?.focus();\n\tconst onKeyDown = (event) => {\n\t\tif (event.key === Keys.Escape) {\n\t\t\tonEscape?.();\n\t\t\treturn;\n\t\t}\n\t\tif (event.key !== Keys.Tab) return;\n\t\tconst current = getContainer();\n\t\tif (!current) return;\n\t\tconst focusableElements = getFocusableElements(current);\n\t\tif (focusableElements.length === 0) {\n\t\t\tevent.preventDefault();\n\t\t\tcurrent.focus();\n\t\t\treturn;\n\t\t}\n\t\tconst firstElement = focusableElements[0];\n\t\tconst lastElement = focusableElements[focusableElements.length - 1];\n\t\tconst activeElement = document.activeElement;\n\t\tif (!(activeElement ? current.contains(activeElement) : false)) {\n\t\t\tevent.preventDefault();\n\t\t\t(event.shiftKey ? lastElement : firstElement).focus();\n\t\t\treturn;\n\t\t}\n\t\tif (event.shiftKey && activeElement === firstElement) {\n\t\t\tevent.preventDefault();\n\t\t\tlastElement.focus();\n\t\t\treturn;\n\t\t}\n\t\tif (!event.shiftKey && activeElement === lastElement) {\n\t\t\tevent.preventDefault();\n\t\t\tfirstElement.focus();\n\t\t}\n\t};\n\tdocument.addEventListener(\"keydown\", onKeyDown);\n\treturn () => {\n\t\tdocument.removeEventListener(\"keydown\", onKeyDown);\n\t\tif (restoreFocus) previousActiveElement?.focus?.();\n\t};\n}\n//#endregion\nexport { getFocusableElements, trapFocus };\n",":host {\n display: contents;\n}\n\n/*\n * The dialog is the overlay: it fills the viewport and centres the panel, so a\n * click that lands on it rather than on the panel is an overlay click.\n */\n.dialog {\n align-items: center;\n background: none;\n border: 0;\n display: none;\n height: 100%;\n justify-content: center;\n max-height: 100%;\n max-width: 100%;\n padding: var(--space-4);\n width: 100%;\n}\n\n.dialog[open] {\n display: flex;\n}\n\n.dialog::backdrop {\n background: var(--pf-modal-overlay-backdrop, var(--pf-overlay-backdrop));\n}\n\n.panel {\n background: var(--pf-modal-bg);\n border: 1px solid var(--pf-modal-border);\n border-radius: var(--radius-lg);\n box-shadow: var(--shadow-lg);\n color: var(--pf-modal-text);\n display: flex;\n flex-direction: column;\n max-height: 100%;\n overflow: auto;\n position: relative;\n width: 100%;\n}\n\n:host([size='sm']) .panel {\n max-width: 400px;\n}\n\n:host([size='md']) .panel {\n max-width: 560px;\n}\n\n:host([size='lg']) .panel {\n max-width: 800px;\n}\n\n.close {\n background: none;\n border: 0;\n border-radius: var(--radius-sm);\n color: var(--pf-modal-text-muted);\n cursor: pointer;\n display: inline-flex;\n inset-block-start: var(--space-3);\n inset-inline-end: var(--space-3);\n padding: var(--space-1);\n position: absolute;\n}\n\n.close:hover {\n color: var(--pf-modal-text);\n}\n\n.close:focus-visible {\n box-shadow: var(--pf-focus-ring);\n outline: none;\n}\n\n.dialog[open] .panel {\n animation: pf-modal-in var(--pf-transition-enter);\n}\n\n/* Its own copy: @keyframes do not cross a shadow boundary. */\n@keyframes pf-modal-in {\n from {\n opacity: 0;\n transform: translateY(8px);\n }\n}\n\n@media (prefers-reduced-motion: reduce) {\n .dialog[open] .panel {\n animation: none;\n }\n}\n","import { getFocusableElements, lockPageScroll } from '@pitchfork-ui/core';\n\nimport {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Method,\n Prop,\n Watch,\n} from '@stencil/core';\n\nexport type PfModalSize = 'sm' | 'md' | 'lg';\n\n/**\n * A modal dialog.\n *\n * A native `<dialog>` opened with `showModal()`, which from inside a shadow\n * root gives the focus trap, Escape and the backdrop for nothing — all\n * measured: focus cannot be taken by a light-DOM button, and a real Escape\n * fires `cancel` then `close`. So `trapFocus` from core is not needed here,\n * unlike in the React component.\n *\n * The one part of `showModal()` that cannot be relied on is where it puts\n * focus, and the gap is exactly the case every framework consumer is in. See\n * `showDialog` below.\n *\n * What `showModal()` does *not* do is lock page scroll — measured: a real\n * wheel still scrolled the page behind an open modal — so this element locks\n * it, exactly as the React component does.\n *\n * @slot - the modal's sections, usually `pf-modal-header`, `pf-modal-body` and\n * `pf-modal-footer`.\n * @part dialog - the native dialog, which is also the overlay.\n * @part panel - the bordered box the content sits in.\n * @part close - the close button.\n */\n@Component({\n tag: 'pf-modal',\n styleUrl: 'pf-modal.css',\n shadow: true,\n})\nexport class PfModal {\n @Element() el!: HTMLElement;\n\n /** Whether the modal is showing. Reflected so the stylesheet can select on it. */\n @Prop({ mutable: true, reflect: true }) open = false;\n\n /** Panel width. Reflected so the stylesheet can select on it. */\n @Prop({ reflect: true }) size: PfModalSize = 'md';\n\n /**\n * Accessible name. Falls back to the text of whatever is slotted, which is\n * usually the header — `aria-labelledby` cannot be used, because an IDREF\n * does not cross a shadow boundary and the header is in the light DOM.\n */\n @Prop() label?: string;\n\n /** Close on Escape or a click on the overlay. Defaults to true. */\n @Prop() dismissable = true;\n\n /** Render the corner close button. Defaults to true. */\n @Prop() showCloseButton = true;\n\n /** Fires whenever the modal opens or closes, whoever caused it. */\n @Event() pfOpenChange!: EventEmitter<{ open: boolean }>;\n\n /**\n * Releases the page-scroll lock, or null when this modal does not hold it.\n * The lock is core's and reference-counted, so a slideout opening over a\n * modal cannot leave the page unscrollable.\n */\n private releaseScroll: (() => void) | null = null;\n\n componentDidLoad() {\n if (this.open) this.showDialog();\n }\n\n disconnectedCallback() {\n // A modal removed while open would otherwise leave the page unscrollable.\n this.unlockScroll();\n }\n\n /** Opens the modal. */\n @Method()\n async show(): Promise<void> {\n this.open = true;\n }\n\n /** Closes the modal. */\n @Method()\n async hide(): Promise<void> {\n this.open = false;\n }\n\n /**\n * The one place a state change is announced, whatever caused it: `show()`,\n * the close button, Escape, an overlay click, or a consumer writing the prop.\n *\n * The first version emitted from the `close` handler alone, which fired for\n * every close and for no open — caught by its own test. A consumer mirroring\n * this value back sets `open` to what it already is, which Stencil does not\n * treat as a change, so there is no loop.\n */\n @Watch('open')\n syncOpen(next: boolean, previous: boolean) {\n if (next) this.showDialog();\n else this.closeDialog();\n if (next !== previous) this.pfOpenChange.emit({ open: next });\n }\n\n private get dialog() {\n return this.el.shadowRoot?.querySelector('dialog') ?? null;\n }\n\n private lockScroll() {\n if (this.releaseScroll) return;\n this.releaseScroll = lockPageScroll();\n }\n\n private unlockScroll() {\n this.releaseScroll?.();\n this.releaseScroll = null;\n }\n\n /**\n * Opens the dialog, and makes sure focus actually went into it.\n *\n * `showModal()` focuses the dialog or its first focusable descendant — but\n * **not** when light-DOM children were appended in the same task as the\n * open. Measured in Chromium with no framework involved: append the three\n * `pf-modal-*` sections to a long-mounted `pf-modal` and set `open` in the\n * same task, and the dialog opens with `document.activeElement` still on\n * `<body>` and `:focus-within` false. Leave one frame between the two and\n * focus lands inside; mount the element with its children and `open`\n * already set and focus lands inside. So it is the append racing the open,\n * and the flattened tree `showModal()`'s focusing steps read.\n *\n * That race is not an edge case: React, Angular and Vue all commit a\n * modal's content and its `open` in one go, so every framework consumer got\n * an open modal with focus outside it and nothing to say so — the page is\n * still inert, so the only symptom is that a reader is not taken to the\n * dialog and the first Tab is needed. Porting `apps/demo` is what found it.\n *\n * What the trace shows, with element identity and a `MutationObserver` on\n * the shadow root: `showModal()` **does** focus, onto `div[part=panel]`,\n * and one frame later a `focusout` with `relatedTarget: null` drops it,\n * with nothing removed from the shadow root. That is Chromium's focus\n * fixup running once the appended children are assigned to the slot and\n * finding the panel is no longer a valid target -- so it is not a render\n * that loses focus, and re-asserting after a render does not catch it\n * (measured: `componentDidRender` alone changes nothing here).\n *\n * So the dialog watches for exactly that: a `focusout` that goes nowhere\n * while the modal is open puts focus back. `requestAnimationFrame` after\n * `showModal()` covers the case where focus never arrived at all, and\n * `componentDidRender` covers a render that discards the focused node. All\n * three are the same guarded call, and the `:focus-within` guard makes it a\n * no-op whenever focus is already inside -- so none of them moves focus\n * that the platform or a consumer placed.\n */\n private showDialog() {\n const dialog = this.dialog;\n if (!dialog || dialog.open) return;\n dialog.showModal();\n this.lockScroll();\n requestAnimationFrame(() => this.ensureFocusInside());\n }\n\n componentDidRender() {\n this.ensureFocusInside();\n }\n\n /**\n * Focus left the dialog for nothing while it is open, which the platform\n * does when its focus fixup runs after the slotted content changes.\n *\n * `relatedTarget` is the test: a Tab or a click inside names where focus\n * went, and a modal dialog means it cannot have gone outside. The window\n * losing focus also reports null, hence the `document.hasFocus()` guard --\n * without it, switching tabs would pull focus back on return.\n */\n private onFocusOut = (event: FocusEvent) => {\n if (!this.open || event.relatedTarget) return;\n requestAnimationFrame(() => {\n if (document.hasFocus()) this.ensureFocusInside();\n });\n };\n\n /** Focus inside the open dialog, unless it is already there. */\n private ensureFocusInside() {\n const dialog = this.dialog;\n if (!this.open || !dialog?.isConnected || !dialog.open) return;\n if (dialog.matches(':focus-within')) return;\n const [first] = getFocusableElements(dialog);\n (first ?? dialog).focus();\n }\n\n private closeDialog() {\n const dialog = this.dialog;\n this.unlockScroll();\n if (dialog?.open) dialog.close();\n }\n\n /** Fires on Escape. Blocking it is how a non-dismissable modal stays put. */\n private onCancel = (event: Event) => {\n if (!this.dismissable) {\n event.preventDefault();\n return;\n }\n // Let it close; `close` does the state mirroring.\n };\n\n /**\n * Mirrors a close the browser made — Escape, or the dialog being closed by\n * anything other than this element — back into `open`, which then announces\n * it through the watch above.\n */\n private onClose = () => {\n this.unlockScroll();\n if (this.open) this.open = false;\n };\n\n /**\n * A click on the dialog element itself is a click on the overlay: the panel\n * is an inner box, so anything landing on the dialog missed the content.\n */\n private onDialogClick = (event: MouseEvent) => {\n if (!this.dismissable || event.target !== this.dialog) return;\n this.open = false;\n };\n\n private accessibleName() {\n if (this.label) return this.label;\n const text = this.el.textContent?.trim();\n return text ? text.slice(0, 120) : undefined;\n }\n\n render() {\n return (\n <Host>\n <dialog\n part=\"dialog\"\n class=\"dialog\"\n aria-label={this.accessibleName()}\n onCancel={this.onCancel}\n onFocusout={this.onFocusOut}\n onClose={this.onClose}\n onClick={this.onDialogClick}\n >\n <div class=\"panel\" part=\"panel\">\n {this.showCloseButton && (\n <button\n class=\"close\"\n part=\"close\"\n type=\"button\"\n aria-label=\"Close\"\n onClick={() => this.hide()}\n >\n <svg\n viewBox=\"0 0 16 16\"\n width=\"16\"\n height=\"16\"\n aria-hidden=\"true\"\n focusable=\"false\"\n >\n <path\n d=\"M4 4l8 8M12 4l-8 8\"\n stroke=\"currentColor\"\n stroke-width=\"1.6\"\n stroke-linecap=\"round\"\n fill=\"none\"\n />\n </svg>\n </button>\n )}\n <slot />\n </div>\n </dialog>\n </Host>\n );\n }\n}\n"],"mappings":"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","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as e,c as t,h as a,H as r}from"./p-Bm6UxEit.js";const i=()=>`:host{display:block}:host([hidden]){display:none}:host([orientation='horizontal']){flex:0 0 auto}.link{align-items:center;background:transparent;border:0;border-radius:var(--pf-nav-item-radius, var(--radius-sm));color:var(--pf-nav-item-text);cursor:pointer;display:flex;font:inherit;gap:var(--pf-nav-item-gap, var(--space-2));min-height:var(--pf-nav-item-min-height, 32px);padding:var(--pf-nav-item-padding, 0 var(--space-2));text-decoration:none;white-space:nowrap}:host([orientation='vertical']) .link{min-height:var(--pf-nav-item-vertical-min-height, 36px);padding:var(--pf-nav-item-vertical-padding, 0 var(--space-3));width:100%}.link:hover{background:var(--pf-nav-item-hover-bg);color:var(--pf-nav-item-hover-text)}a.link:focus-visible{box-shadow:var(--pf-nav-item-focus-ring, var(--pf-focus-ring));outline:none}:host([current-page]) .link{background:var(--pf-nav-item-current-bg);color:var(--pf-nav-item-current-text);font-weight:var(--font-weight-semibold)}:host([disabled]) .link{cursor:not-allowed;opacity:var(--pf-nav-item-disabled-opacity, 0.5)}:host([disabled]) .link:hover{background:transparent;color:var(--pf-nav-item-text)}.label{flex:1 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis}:host([orientation='horizontal']) .label{flex:0 0 auto}::slotted([slot='icon']){color:inherit;flex:0 0 auto}::slotted([slot='badge']){flex:0 0 auto}::slotted(a),::slotted(button){align-items:center;align-self:stretch;background:none;border:0;color:inherit;cursor:inherit;display:flex;flex:1 1 auto;font:inherit;margin:0;padding:0;text-decoration:none}`;const n=class{constructor(a){e(this,a);this.pfNavStructure=t(this,"pfNavStructure")}href;target;rel;current=false;pfNavStructure;handleCurrentChange(){this.pfNavStructure.emit()}currentPage=false;disabled=false;orientation="horizontal";render(){const e=[a("slot",{key:"b478a66b7ae6c6d00b18f762600435dbac37996d",name:"icon"}),a("span",{key:"4b1ddbe87804c604d492b00bbc743299c54f7240",class:"label",part:"label"},a("slot",{key:"86778db42fef8af44096211cd8a743155dca3fb0"})),a("slot",{key:"02fef2701ef217701ce18e71e9ff873dc3bd3a44",name:"badge"})];return a(r,{key:"c4ee7f6245eedd2bf0546ebcb987120212ea18e3",role:"listitem"},this.href&&!this.disabled?a("a",{class:"link",part:"link",href:this.href,target:this.target,rel:this.rel,"aria-current":this.currentPage?"page":null},e):a("span",{class:"link",part:"link","aria-current":this.currentPage?"page":null,"aria-disabled":this.disabled?"true":null},e))}static get watchers(){return{current:[{handleCurrentChange:0}]}}};n.style=i();export{n as pf_nav_item};
2
+ //# sourceMappingURL=p-f713c62d.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["pfNavItemCss","PfNavItem","href","target","rel","current","pfNavStructure","handleCurrentChange","this","emit","currentPage","disabled","orientation","render","content","h","key","name","class","part","Host","role"],"sources":["src/components/pf-nav-item/pf-nav-item.css?tag=pf-nav-item&encapsulation=shadow","src/components/pf-nav-item/pf-nav-item.tsx"],"sourcesContent":["/*\n * This element is shared by pf-header-navigation and pf-sidebar-navigation,\n * whose React counterparts have separate alias families with their own\n * values. Rather than pick one and diverge from the other, the item reads a\n * generic `--pf-nav-item-*` set that each navigation defines on itself --\n * custom properties inherit through the shadow boundary, so a slotted item\n * picks up whichever navigation it is inside, which no selector can do\n * (`:host-context` is not in Firefox). Exactly the pf-option arrangement, for\n * the same reason. There is deliberately no `:root` default: without one the\n * bridge is load-bearing, and a missing one shows up as an item with no\n * colours at all rather than as one that quietly looks right.\n */\n:host {\n display: block;\n}\n\n:host([hidden]) {\n display: none;\n}\n\n:host([orientation='horizontal']) {\n flex: 0 0 auto;\n}\n\n.link {\n align-items: center;\n background: transparent;\n border: 0;\n border-radius: var(--pf-nav-item-radius, var(--radius-sm));\n color: var(--pf-nav-item-text);\n cursor: pointer;\n display: flex;\n font: inherit;\n gap: var(--pf-nav-item-gap, var(--space-2));\n min-height: var(--pf-nav-item-min-height, 32px);\n padding: var(--pf-nav-item-padding, 0 var(--space-2));\n text-decoration: none;\n white-space: nowrap;\n}\n\n:host([orientation='vertical']) .link {\n min-height: var(--pf-nav-item-vertical-min-height, 36px);\n padding: var(--pf-nav-item-vertical-padding, 0 var(--space-3));\n width: 100%;\n}\n\n.link:hover {\n background: var(--pf-nav-item-hover-bg);\n color: var(--pf-nav-item-hover-text);\n}\n\na.link:focus-visible {\n box-shadow: var(--pf-nav-item-focus-ring, var(--pf-focus-ring));\n outline: none;\n}\n\n/*\n * `current-page` is the group's answer, not the consumer's `current` ask: the\n * highlight and the announcement are the same decision, so they read the same\n * attribute.\n */\n:host([current-page]) .link {\n background: var(--pf-nav-item-current-bg);\n color: var(--pf-nav-item-current-text);\n font-weight: var(--font-weight-semibold);\n}\n\n:host([disabled]) .link {\n cursor: not-allowed;\n opacity: var(--pf-nav-item-disabled-opacity, 0.5);\n}\n\n:host([disabled]) .link:hover {\n background: transparent;\n color: var(--pf-nav-item-text);\n}\n\n/* The label takes the slack so a badge sits at the far edge of a sidebar. */\n.label {\n flex: 1 1 auto;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n:host([orientation='horizontal']) .label {\n flex: 0 0 auto;\n}\n\n/*\n * No wrapper around the icon and badge slots: an unassigned slot is\n * `display: contents` and generates nothing, while a wrapper around one\n * cannot be collapsed from CSS and would cost a gap in front of every label\n * with no icon.\n */\n::slotted([slot='icon']) {\n color: inherit;\n flex: 0 0 auto;\n}\n\n::slotted([slot='badge']) {\n flex: 0 0 auto;\n}\n\n/*\n * A consumer's own router link, slotted in with no `href` of ours. It fills\n * the box's content area rather than being a word inside it, and it inherits\n * every colour the box resolved, so hover and the current page look the same\n * whichever of the two is the control.\n */\n::slotted(a),\n::slotted(button) {\n align-items: center;\n align-self: stretch;\n background: none;\n border: 0;\n color: inherit;\n cursor: inherit;\n display: flex;\n flex: 1 1 auto;\n font: inherit;\n margin: 0;\n padding: 0;\n text-decoration: none;\n}\n","import { Component, Event, EventEmitter, h, Host, Prop, Watch } from '@stencil/core';\n\n/**\n * One item in a `pf-header-navigation` or a `pf-sidebar-navigation`.\n *\n * Shared by both, because the React library's `HeaderNavigationItem` and\n * `SidebarNavigationItem` are the same shape — one element rather than two\n * that would drift. What differs is the layout, and that is the group's to\n * say: it pushes `orientation` down, which is the only thing an item cannot\n * work out for itself.\n *\n * With an `href` it renders a link; without one it renders a plain box, which\n * is how a framework's own router is used — slot an `<a routerLink>` or a\n * `<Link>` in and leave `href` unset.\n *\n * `currentPage` and `orientation` are the group's to set. A consumer asks by\n * setting `current`; the group resolves every item with core's rule and\n * writes the answer to `currentPage`. Changing the ask tells the group, so\n * the answer follows a framework's re-render without the consumer calling\n * anything.\n *\n * @slot - the item's label.\n * @slot icon - a leading icon.\n * @slot badge - a trailing badge or count.\n * @part link - the link, or the box standing in for one.\n */\n@Component({\n tag: 'pf-nav-item',\n styleUrl: 'pf-nav-item.css',\n shadow: true,\n})\nexport class PfNavItem {\n /** Where the item goes. Reflected; a consumer's stylesheet reads it. */\n @Prop({ reflect: true }) href?: string;\n\n /** Opens elsewhere, as on a plain anchor. Ignored without an `href`. */\n @Prop() target?: string;\n\n /** Goes on the anchor as-is. Ignored without an `href`. */\n @Prop() rel?: string;\n\n /**\n * Set it to mark this item as the current page.\n *\n * The *asking* half, which the group never writes — `currentPage` below is\n * the answer. The two are kept apart for the reason `pf-breadcrumb` keeps\n * them apart: a group that wrote its answer back would leave the mark\n * behind on an item the consumer had not marked.\n */\n @Prop({ reflect: true }) current = false;\n\n /**\n * Tells the group the ask changed, so it can resolve again.\n *\n * The same event `pf-nav-section` emits when its items move, because the\n * groups do the same thing with both: re-read every item and resolve the\n * one current page. Without this a navigation resolves at load and never\n * again for a consumer who marks items through the *property*, which is\n * every framework consumer — the generated bindings set props as\n * properties, so there is no attribute change and no `slotchange` either.\n * The symptom is a navigation whose highlight never moves while the router\n * works perfectly, which is what porting `apps/demo` ran into.\n *\n * `current` only. Watching `currentPage` would loop, since that is what the\n * group writes back.\n */\n @Event() pfNavStructure!: EventEmitter<void>;\n\n @Watch('current')\n handleCurrentChange() {\n this.pfNavStructure.emit();\n }\n\n /**\n * Set by the group: the resolved current page, which is the one thing that\n * renders `aria-current=\"page\"`. At most one item in a navigation carries\n * it, and the highlight follows it rather than `current` — a second\n * highlighted item with no `aria-current` would be a sighted-only lie.\n */\n @Prop({ mutable: true, reflect: true }) currentPage = false;\n\n /**\n * Takes the item out of the navigation without removing it.\n *\n * A disabled item renders **no anchor at all**, because an anchor has no\n * disabled state: `aria-disabled` alone leaves it focusable and clickable,\n * and dropping the `href` is the only thing that really takes it out of the\n * tab order.\n */\n @Prop({ reflect: true }) disabled = false;\n\n /** Set by the group, which is the only one that knows which it is. */\n @Prop({ mutable: true, reflect: true }) orientation: 'horizontal' | 'vertical' = 'horizontal';\n\n render() {\n const content = [\n <slot name=\"icon\" />,\n <span class=\"label\" part=\"label\">\n <slot />\n </span>,\n <slot name=\"badge\" />,\n ];\n\n return (\n <Host role=\"listitem\">\n {this.href && !this.disabled ? (\n <a\n class=\"link\"\n part=\"link\"\n href={this.href}\n target={this.target}\n rel={this.rel}\n aria-current={this.currentPage ? 'page' : null}\n >\n {content}\n </a>\n ) : (\n <span\n class=\"link\"\n part=\"link\"\n aria-current={this.currentPage ? 'page' : null}\n aria-disabled={this.disabled ? 'true' : null}\n >\n {content}\n </span>\n )}\n </Host>\n );\n }\n}\n"],"mappings":"yDAAA,MAAMA,EAAe,IAAM,6hD,MC+BdC,EAAS,M,sEAEKC,KAGjBC,OAGAC,IAUiBC,QAAU,MAiB1BC,eAGT,mBAAAC,GACEC,KAAKF,eAAeG,M,CASkBC,YAAc,MAU7BC,SAAW,MAGIC,YAAyC,aAEjF,MAAAC,GACE,MAAMC,EAAU,CACdC,EAAA,QAAAC,IAAA,2CAAMC,KAAK,SACXF,EAAA,QAAAC,IAAA,2CAAME,MAAM,QAAQC,KAAK,SACvBJ,EAAA,QAAAC,IAAA,8CAEFD,EAAA,QAAAC,IAAA,2CAAMC,KAAK,WAGb,OACEF,EAACK,EAAI,CAAAJ,IAAA,2CAACK,KAAK,YACRb,KAAKN,OAASM,KAAKG,SAClBI,EAAA,KACEG,MAAM,OACNC,KAAK,OACLjB,KAAMM,KAAKN,KACXC,OAAQK,KAAKL,OACbC,IAAKI,KAAKJ,IAAG,eACCI,KAAKE,YAAc,OAAS,MAEzCI,GAGHC,EAAA,QACEG,MAAM,OACNC,KAAK,OAAM,eACGX,KAAKE,YAAc,OAAS,KAAI,gBAC/BF,KAAKG,SAAW,OAAS,MAEvCG,G","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as e,c as r,a as t,h as i,H as a}from"./p-Bm6UxEit.js";import{a as s}from"./p-Cr6IXrUk.js";import{c as o}from"./p-Cy_kHPeC.js";const c=()=>`:host{display:inline-block}:host([hidden]){display:none}.field{align-items:center;display:inline-flex;gap:var(--space-2)}.input{appearance:none;background:var(--pf-checkbox-bg);border:1px solid var(--pf-checkbox-border);border-radius:var(--pf-checkbox-radius, var(--radius-sm));box-sizing:border-box;cursor:pointer;display:inline-block;flex-shrink:0;height:18px;margin:0;position:relative;width:18px}.input:checked{background:var(--pf-checkbox-checked-bg);border-color:var(--pf-checkbox-border)}.input::after{border:solid var(--pf-checkbox-check-color);border-width:0 2px 2px 0;content:'';height:9px;left:5px;opacity:0;position:absolute;top:2px;transform:rotate(45deg);width:5px}.input:checked::after{opacity:1}.input:focus-visible{box-shadow:var(--pf-checkbox-focus-ring, var(--pf-focus-ring));outline:none}.input:disabled{cursor:not-allowed;opacity:0.55}.input:disabled+.label{cursor:not-allowed;opacity:0.65}.label{color:var(--pf-checkbox-label-text);font-size:var(--font-size-md)}.error{color:var(--pf-checkbox-field-error, var(--pf-field-error));font-size:var(--font-size-sm);margin:var(--space-1) 0 0}`;const n=class{constructor(t){e(this,t);this.pfChange=r(this,"pfChange");if(t.$hostElement$["s-ei"]){this.internals=t.$hostElement$["s-ei"]}else{this.internals=t.$hostElement$.attachInternals();t.$hostElement$["s-ei"]=this.internals}}get el(){return t(this)}internals;name;checked=false;value="on";label;error;required=false;disabled=false;pfChange;initialChecked=false;componentWillLoad(){this.initialChecked=this.checked;this.syncFormState()}syncFormState(){this.internals.setFormValue(this.checked?this.value:null);s(this.internals,this.checked,this.required,this.error)}async checkValidity(){return this.internals.checkValidity()}async reportValidity(){return this.internals.reportValidity()}async getValidationMessage(){return this.internals.validationMessage}formResetCallback(){this.checked=this.initialChecked}onChange=e=>{this.checked=e.target.checked;this.pfChange.emit({checked:this.checked,value:this.value})};render(){return i(a,{key:"f0888c00b688aef2c90deb60a7496971c2e52ac3"},i("div",{key:"25dbafc87f7c597cc055ade975033bab23ed67d9",class:"field",part:"field"},i("input",{key:"2d6f97d80d2686ad13ddac12bf70d12828611ad8",id:"input","aria-label":o(this.el,this.label),part:"input",class:"input",type:"checkbox",name:this.name,value:this.value,checked:this.checked,required:this.required,disabled:this.disabled,"aria-invalid":this.error?"true":null,"aria-describedby":this.error?"error":null,onChange:this.onChange}),this.label&&i("label",{key:"0c6427fb3168226dd5c69e06e5769efab4cc0d5e",class:"label",part:"label",htmlFor:"input"},this.label)),this.error&&i("p",{key:"401852018ce3b0c0a856e669d96c33d185a5b730",class:"error",part:"error",id:"error"},this.error))}static get delegatesFocus(){return true}static get formAssociated(){return true}static get watchers(){return{checked:[{syncFormState:0}],error:[{syncFormState:0}],required:[{syncFormState:0}],value:[{syncFormState:0}]}}};n.style=c();export{n as pf_checkbox};
2
+ //# sourceMappingURL=p-fd802631.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["pfCheckboxCss","PfCheckbox","internals","name","checked","value","label","error","required","disabled","pfChange","initialChecked","componentWillLoad","this","syncFormState","setFormValue","applyControlValidity","checkValidity","reportValidity","getValidationMessage","validationMessage","formResetCallback","onChange","event","target","emit","render","h","Host","key","class","part","id","controlAriaLabel","el","type","htmlFor"],"sources":["src/components/pf-checkbox/pf-checkbox.css?tag=pf-checkbox&encapsulation=shadow","src/components/pf-checkbox/pf-checkbox.tsx"],"sourcesContent":[":host {\n display: inline-block;\n}\n\n:host([hidden]) {\n display: none;\n}\n\n.field {\n align-items: center;\n display: inline-flex;\n gap: var(--space-2);\n}\n\n.input {\n appearance: none;\n background: var(--pf-checkbox-bg);\n border: 1px solid var(--pf-checkbox-border);\n border-radius: var(--pf-checkbox-radius, var(--radius-sm));\n box-sizing: border-box;\n cursor: pointer;\n display: inline-block;\n flex-shrink: 0;\n height: 18px;\n margin: 0;\n position: relative;\n width: 18px;\n}\n\n.input:checked {\n background: var(--pf-checkbox-checked-bg);\n border-color: var(--pf-checkbox-border);\n}\n\n/* The tick: two borders of a rotated box. */\n.input::after {\n border: solid var(--pf-checkbox-check-color);\n border-width: 0 2px 2px 0;\n content: '';\n height: 9px;\n left: 5px;\n opacity: 0;\n position: absolute;\n top: 2px;\n transform: rotate(45deg);\n width: 5px;\n}\n\n.input:checked::after {\n opacity: 1;\n}\n\n.input:focus-visible {\n box-shadow: var(--pf-checkbox-focus-ring, var(--pf-focus-ring));\n outline: none;\n}\n\n.input:disabled {\n cursor: not-allowed;\n opacity: 0.55;\n}\n\n.input:disabled + .label {\n cursor: not-allowed;\n opacity: 0.65;\n}\n\n.label {\n color: var(--pf-checkbox-label-text);\n font-size: var(--font-size-md);\n}\n\n.error {\n color: var(--pf-checkbox-field-error, var(--pf-field-error));\n font-size: var(--font-size-sm);\n margin: var(--space-1) 0 0;\n}\n","import {\n AttachInternals,\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Method,\n Prop,\n Watch,\n} from '@stencil/core';\n\nimport { applyControlValidity } from '../../form-validity';\nimport { controlAriaLabel } from '../../control-label';\n\n/**\n * A form-associated checkbox.\n *\n * @part field - the wrapper around control and label.\n * @part input - the native checkbox.\n * @part label - the label element.\n */\n@Component({\n tag: 'pf-checkbox',\n styleUrl: 'pf-checkbox.css',\n formAssociated: true,\n shadow: { delegatesFocus: true },\n})\nexport class PfCheckbox {\n @Element() el!: HTMLElement;\n\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * Submitted under this name.\n *\n * Reflected, because a form-associated custom element takes its submission\n * name from the `name` *content attribute* -- not from this property. A\n * framework wrapper that sets properties rather than attributes (the\n * generated React bindings do) would otherwise leave the control nameless\n * and absent from the submission, with every other sign of working.\n */\n @Prop({ reflect: true }) name?: string;\n\n /** Whether the box is ticked. Reflected so the stylesheet can select on it. */\n @Prop({ mutable: true, reflect: true }) checked = false;\n\n /**\n * What is submitted when ticked. Mirrors the native attribute, whose default\n * is also `on` — a checkbox with no value still submits something.\n */\n @Prop() value = 'on';\n\n /** Visible label, rendered in the same root so `for` actually associates. */\n @Prop() label?: string;\n\n /** Error message. Its presence is what marks the control invalid. */\n @Prop() error?: string;\n\n @Prop({ reflect: true }) required = false;\n\n @Prop({ reflect: true }) disabled = false;\n\n /** Fires when the user ticks or unticks the box. */\n @Event() pfChange!: EventEmitter<{ checked: boolean; value: string }>;\n\n /** The state a form reset restores, which is the initial attribute. */\n private initialChecked = false;\n\n componentWillLoad() {\n this.initialChecked = this.checked;\n this.syncFormState();\n }\n\n @Watch('checked')\n @Watch('error')\n @Watch('required')\n @Watch('value')\n syncFormState() {\n /*\n * `null`, not an empty string, when unticked: an unchecked checkbox is\n * absent from the submission entirely, rather than present and empty.\n * That is what a server distinguishing \"unticked\" from \"not sent\" relies\n * on, and it is what a native checkbox does.\n */\n this.internals.setFormValue(this.checked ? this.value : null);\n applyControlValidity(this.internals, this.checked, this.required, this.error);\n }\n\n /** A form-associated custom element does not inherit this. */\n @Method()\n async checkValidity(): Promise<boolean> {\n return this.internals.checkValidity();\n }\n\n /** As `checkValidity`, but also shows the browser's validation message. */\n @Method()\n async reportValidity(): Promise<boolean> {\n return this.internals.reportValidity();\n }\n\n /** The message explaining why the control is invalid, or an empty string. */\n @Method()\n async getValidationMessage(): Promise<string> {\n return this.internals.validationMessage;\n }\n\n /**\n * A reset restores the initial state, not `false` — a native\n * `<input type=checkbox checked>` comes back ticked.\n */\n formResetCallback() {\n this.checked = this.initialChecked;\n }\n\n private onChange = (event: Event) => {\n this.checked = (event.target as HTMLInputElement).checked;\n this.pfChange.emit({ checked: this.checked, value: this.value });\n };\n\n render() {\n return (\n <Host>\n <div class=\"field\" part=\"field\">\n <input\n id=\"input\"\n aria-label={controlAriaLabel(this.el, this.label)}\n part=\"input\"\n class=\"input\"\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n required={this.required}\n disabled={this.disabled}\n aria-invalid={this.error ? 'true' : null}\n aria-describedby={this.error ? 'error' : null}\n onChange={this.onChange}\n />\n {this.label && (\n <label class=\"label\" part=\"label\" htmlFor=\"input\">\n {this.label}\n </label>\n )}\n </div>\n {this.error && (\n <p class=\"error\" part=\"error\" id=\"error\">\n {this.error}\n </p>\n )}\n </Host>\n );\n }\n}\n"],"mappings":"wIAAA,MAAMA,EAAgB,IAAM,slC,MC6BfC,EAAU,M,mPAGFC,UAWMC,KAGeC,QAAU,MAM1CC,MAAQ,KAGRC,MAGAC,MAEiBC,SAAW,MAEXC,SAAW,MAG3BC,SAGDC,eAAiB,MAEzB,iBAAAC,GACEC,KAAKF,eAAiBE,KAAKT,QAC3BS,KAAKC,e,CAOP,aAAAA,GAOED,KAAKX,UAAUa,aAAaF,KAAKT,QAAUS,KAAKR,MAAQ,MACxDW,EAAqBH,KAAKX,UAAWW,KAAKT,QAASS,KAAKL,SAAUK,KAAKN,M,CAKzE,mBAAMU,GACJ,OAAOJ,KAAKX,UAAUe,e,CAKxB,oBAAMC,GACJ,OAAOL,KAAKX,UAAUgB,gB,CAKxB,0BAAMC,GACJ,OAAON,KAAKX,UAAUkB,iB,CAOxB,iBAAAC,GACER,KAAKT,QAAUS,KAAKF,c,CAGdW,SAAYC,IAClBV,KAAKT,QAAWmB,EAAMC,OAA4BpB,QAClDS,KAAKH,SAASe,KAAK,CAAErB,QAASS,KAAKT,QAASC,MAAOQ,KAAKR,OAAQ,EAGlE,MAAAqB,GACE,OACEC,EAACC,EAAI,CAAAC,IAAA,4CACHF,EAAA,OAAAE,IAAA,2CAAKC,MAAM,QAAQC,KAAK,SACtBJ,EAAA,SAAAE,IAAA,2CACEG,GAAG,QAAO,aACEC,EAAiBpB,KAAKqB,GAAIrB,KAAKP,OAC3CyB,KAAK,QACLD,MAAM,QACNK,KAAK,WACLhC,KAAMU,KAAKV,KACXE,MAAOQ,KAAKR,MACZD,QAASS,KAAKT,QACdI,SAAUK,KAAKL,SACfC,SAAUI,KAAKJ,SAAQ,eACTI,KAAKN,MAAQ,OAAS,KAAI,mBACtBM,KAAKN,MAAQ,QAAU,KACzCe,SAAUT,KAAKS,WAEhBT,KAAKP,OACJqB,EAAA,SAAAE,IAAA,2CAAOC,MAAM,QAAQC,KAAK,QAAQK,QAAQ,SACvCvB,KAAKP,QAIXO,KAAKN,OACJoB,EAAA,KAAAE,IAAA,2CAAGC,MAAM,QAAQC,KAAK,QAAQC,GAAG,SAC9BnB,KAAKN,O","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{p as e,g as a,b as t}from"./p-Bm6UxEit.js";export{s as setNonce}from"./p-Bm6UxEit.js";var l=()=>{const a=import.meta.url;const t={};if(a!==""){t.resourcesUrl=new URL(".",a).href}return e(t)};l().then((async e=>{await a();return t(JSON.parse('[["p-4b16ef92",[[769,"pf-command-palette",{"open":[1540],"placeholder":[1],"emptyMessage":[1,"empty-message"],"label":[1],"dismissable":[4],"query":[32],"matchCount":[32],"show":[64],"hide":[64],"refresh":[64]},[[0,"pfCommandSelect","handleCommandSelect"]],{"open":[{"syncOpen":0}]}]]],["p-e944f504",[[577,"pf-date-picker",{"name":[513],"value":[1025],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"allowClear":[4,"allow-clear"],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"showOutsideDays":[4,"show-outside-days"],"isDateDisabled":[16],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-ac3fcb57",[[769,"pf-tab",{"value":[513],"disabled":[516],"selected":[1540],"variant":[1537],"size":[1537],"fullWidth":[1540,"full-width"],"icon":[1],"iconPlacement":[1,"icon-placement"],"count":[2],"badgePlacement":[1,"badge-placement"]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]]]]],["p-23b1be9b",[[577,"pf-tag-input",{"name":[513],"value":[1537],"label":[1],"description":[1],"error":[1],"placeholder":[1],"max":[2],"allowDuplicates":[4,"allow-duplicates"],"tagVariant":[1,"tag-variant"],"required":[516],"disabled":[516],"validate":[16],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"name":[{"syncFormState":0}],"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-a1a7838d",[[769,"pf-toaster",{"placement":[513],"duration":[2],"entries":[32],"toast":[64],"dismiss":[64],"dismissAll":[64]}]]],["p-685f817b",[[785,"pf-accordion-item",{"value":[513],"disabled":[516],"expanded":[1540],"headingLevel":[1026,"heading-level"]}]]],["p-bf044fb5",[[769,"pf-alert",{"variant":[513],"heading":[1],"description":[1],"dismissible":[516],"dismissLabel":[1,"dismiss-label"],"exiting":[32],"hasSlottedBody":[32],"dismiss":[64]}]]],["p-248bd301",[[769,"pf-avatar-group",{"max":[2],"size":[513],"total":[2],"label":[1],"overflow":[32],"counted":[32],"refresh":[64]},null,{"max":[{"handleStateChange":0}],"size":[{"handleStateChange":0}],"total":[{"handleStateChange":0}]}]]],["p-f855c9d4",[[769,"pf-button-group-item",{"value":[513],"disabled":[516],"groupDisabled":[1540,"group-disabled"],"selected":[1540],"icon":[1],"dot":[516]}]]],["p-8718bb3a",[[769,"pf-carousel",{"index":[1026],"loop":[516],"showIndicators":[516,"show-indicators"],"autoPlay":[516,"auto-play"],"autoPlayInterval":[2,"auto-play-interval"],"label":[1],"previousLabel":[1,"previous-label"],"nextLabel":[1,"next-label"],"total":[32],"refresh":[64],"next":[64],"previous":[64]},null,{"index":[{"handleIndexChange":0}],"loop":[{"handleIndexChange":0}],"autoPlay":[{"handleTimerChange":0}],"autoPlayInterval":[{"handleTimerChange":0}]}]]],["p-fa1302c7",[[769,"pf-code-snippet",{"code":[1],"language":[513],"heading":[1],"showLineNumbers":[516,"show-line-numbers"],"maxHeight":[2,"max-height"],"copyLabel":[1,"copy-label"],"copiedLabel":[1,"copied-label"],"copyFailedLabel":[1,"copy-failed-label"],"feedbackDuration":[2,"feedback-duration"],"copied":[32],"failed":[32],"hasMarkup":[32],"copy":[64]}]]],["p-1bb6b456",[[769,"pf-collapsible",{"open":[1540],"disabled":[516],"showChevron":[4,"show-chevron"],"show":[64],"hide":[64]},[[0,"keydown","handleKeyDown"]],{"open":[{"handleOpenChange":0}]}]]],["p-47cabc33",[[833,"pf-combobox",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"emptyMessage":[1,"empty-message"],"required":[516],"disabled":[516],"clearable":[4],"clearLabel":[1,"clear-label"],"query":[32],"matchCount":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"]],{"value":[{"syncFormState":0},{"syncSelection":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-52eef7eb",[[577,"pf-date-range-picker",{"name":[513],"value":[1025],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"allowClear":[4,"allow-clear"],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"isDateDisabled":[16],"leftMonth":[32],"focusedDate":[32],"hovered":[32],"awaitingEnd":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncDisplayedMonths":0},{"syncFormState":0}],"name":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-742f2cc4",[[769,"pf-empty-state",{"size":[513],"icon":[1],"hasIcon":[32],"hasAction":[32]}]]],["p-04869bdc",[[577,"pf-file-uploader",{"name":[513],"files":[1040],"accept":[1],"multiple":[516],"maxFiles":[2,"max-files"],"maxFileSize":[2,"max-file-size"],"label":[1],"description":[1],"error":[1],"required":[516],"disabled":[516],"rejection":[32],"dragDepth":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"open":[64]},null,{"files":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"rejection":[{"syncFormState":0}]}]]],["p-b26df5a0",[[769,"pf-inline-cta",{"tone":[513],"icon":[1],"dismissible":[516],"dismissLabel":[1,"dismiss-label"],"exiting":[1540],"hasIcon":[32],"hasAction":[32],"dismiss":[64]}]]],["p-4217a92a",[[769,"pf-metric-card",{"trend":[513],"icon":[1],"hasIcon":[32],"hasAction":[32],"hasTrend":[32]}]]],["p-a24bf2bd",[[833,"pf-multi-select",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"maxVisibleOptions":[2,"max-visible-options"],"chips":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"],[0,"keydown","handleKeyDown"]],{"name":[{"syncFormState":0}],"value":[{"syncFormState":0},{"syncOptions":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-33857f80",[[593,"pf-number-input",{"name":[513],"value":[1025],"min":[2],"max":[2],"step":[2],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"decrementLabel":[1,"decrement-label"],"incrementLabel":[1,"increment-label"],"draft":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"stepBy":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-aa869013",[[513,"pf-rating-badge",{"value":[2],"max":[2],"reviews":[2],"size":[513]}]]],["p-dcaaedeb",[[513,"pf-rating-stars",{"value":[2],"max":[2],"size":[2],"showValue":[4,"show-value"],"label":[1]}]]],["p-a9b77dbb",[[833,"pf-select",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"maxVisibleOptions":[2,"max-visible-options"],"selectedLabel":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"syncFormState":0},{"syncOptions":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-5064d2dd",[[577,"pf-time-picker",{"name":[513],"value":[1025],"open":[1540],"hourCycle":[2,"hour-cycle"],"minuteStep":[2,"minute-step"],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-c07c5847",[[769,"pf-tree-item",{"value":[513],"disabled":[516],"icon":[1],"level":[1026],"selected":[1540],"expanded":[1540],"hasChildren":[1540,"has-children"],"active":[1540],"hasBadge":[32]}]]],["p-26e119df",[[769,"pf-accordion",{"value":[1537],"type":[513],"headingLevel":[2,"heading-level"],"refresh":[64]},[[0,"pfAccordionToggle","handleToggle"],[0,"keydown","handleKeyDown"]],{"value":[{"handleStateChange":0}],"type":[{"handleStateChange":0}],"headingLevel":[{"handleStateChange":0}]}]]],["p-fe6f403c",[[513,"pf-badge-group",{"label":[1],"message":[1],"color":[513],"appearance":[513],"badgePosition":[513,"badge-position"]}]]],["p-b2df1ecb",[[769,"pf-bar-chart",{"data":[1],"stacked":[516],"showLegend":[516,"show-legend"],"yAxisLabel":[1,"y-axis-label"],"label":[1],"series":[32],"refresh":[64]},null,{"data":[{"sync":0}]}]]],["p-51528462",[[769,"pf-breadcrumb",{"href":[513],"current":[516],"currentPage":[1540,"current-page"],"last":[1540],"separator":[1025]}]]],["p-77168a0d",[[769,"pf-breadcrumbs",{"label":[1],"separator":[1],"refresh":[64]},null,{"separator":[{"handleSeparatorChange":0}]}]]],["p-7e5ba1f9",[[785,"pf-button",{"variant":[513],"size":[513],"fullWidth":[516,"full-width"],"loading":[516],"disabled":[516],"type":[1],"label":[1]}]]],["p-8a1e2ba8",[[769,"pf-button-group",{"value":[1537],"multiple":[516],"disabled":[516],"refresh":[64]},[[0,"pfButtonGroupSelect","handleSelect"]],{"value":[{"handleStateChange":0}],"multiple":[{"handleStateChange":0}],"disabled":[{"handleStateChange":0}]}]]],["p-22c7e5b4",[[257,"pf-card"]]],["p-69d27f61",[[257,"pf-card-content"]]],["p-d4bbcba0",[[257,"pf-card-footer"]]],["p-f0889512",[[257,"pf-card-header"]]],["p-643f7e00",[[769,"pf-carousel-slide",{"active":[1540],"position":[1026],"total":[1026]}]]],["p-8e1a4b26",[[769,"pf-chart-series",{"seriesKey":[513,"series-key"],"color":[513],"dashed":[516],"swatch":[1025]}]]],["p-d248b027",[[593,"pf-checkbox",{"name":[513],"checked":[1540],"value":[1],"label":[1],"error":[1],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"checked":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"value":[{"syncFormState":0}]}]]],["p-3cd7d421",[[769,"pf-command-group",{"label":[1]}]]],["p-9dc1dd8a",[[769,"pf-command-item",{"value":[513],"description":[1],"disabled":[516]}]]],["p-43c103bb",[[769,"pf-content-divider",{"orientation":[513],"inset":[516],"hasLabel":[32]}]]],["p-31e0fbc7",[[769,"pf-context-menu",{"open":[1540],"label":[1],"disabled":[516],"showAt":[64],"hide":[64]},[[0,"contextmenu","handleContextMenu"],[0,"pfMenuSelect","handleMenuSelect"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-dd0e0d79",[[513,"pf-credit-card",{"brand":[513],"cardNumber":[1,"card-number"],"cardholderName":[1,"cardholder-name"],"expiry":[1],"cvc":[1],"masked":[516]}]]],["p-03db6bae",[[769,"pf-dropdown",{"open":[1540],"align":[1],"label":[1],"disabled":[516],"show":[64],"hide":[64]},[[0,"click","handleClick"],[0,"pfMenuSelect","handleMenuSelect"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-aac27e62",[[769,"pf-gauge-chart",{"value":[2],"max":[2],"size":[2],"strokeWidth":[2,"stroke-width"],"color":[1],"label":[1]}]]],["p-d7eb6335",[[769,"pf-header-navigation",{"label":[1],"hasBrand":[32],"hasActions":[32],"refresh":[64]}]]],["p-aa615fe9",[[769,"pf-heatmap",{"data":[1],"startDate":[1,"start-date"],"endDate":[1,"end-date"],"levels":[2],"weekStartsOn":[2,"week-starts-on"],"cellSize":[2,"cell-size"],"cellGap":[2,"cell-gap"],"showWeekdayLabels":[516,"show-weekday-labels"],"showMonthLabels":[516,"show-month-labels"],"label":[1]}]]],["p-c6bdd9cd",[[593,"pf-input",{"name":[513],"value":[1025],"type":[513],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"readonly":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-6066ce98",[[769,"pf-line-chart",{"data":[1],"area":[516],"curved":[516],"showLegend":[516,"show-legend"],"yAxisLabel":[1,"y-axis-label"],"label":[1],"series":[32],"refresh":[64]},null,{"data":[{"sync":0}]}]]],["p-a5b5c09a",[[513,"pf-loading-dots",{"size":[513],"label":[1]}]]],["p-f5242cee",[[513,"pf-loading-skeleton",{"width":[8],"height":[8],"rounded":[516],"label":[1]}]]],["p-50ad12be",[[513,"pf-loading-spinner",{"size":[2],"label":[1]}]]],["p-1e171d52",[[769,"pf-menu-item",{"value":[513],"disabled":[516],"destructive":[516]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]]]]],["p-34f2df95",[[1,"pf-menu-separator"]]],["p-1fa3b37b",[[257,"pf-metric-grid"]]],["p-d6425298",[[769,"pf-modal",{"open":[1540],"size":[513],"label":[1],"dismissable":[4],"showCloseButton":[4,"show-close-button"],"show":[64],"hide":[64]},null,{"open":[{"syncOpen":0}]}]]],["p-edb28479",[[257,"pf-modal-body"]]],["p-e9d767df",[[257,"pf-modal-footer"]]],["p-e882124b",[[257,"pf-modal-header"]]],["p-1dbea97f",[[769,"pf-nav-item",{"href":[513],"target":[1],"rel":[1],"current":[516],"currentPage":[1540,"current-page"],"disabled":[516],"orientation":[1537]}]]],["p-97dd4193",[[769,"pf-nav-section",{"hasTitle":[32]}]]],["p-3133eb1a",[[769,"pf-option",{"value":[513],"disabled":[516],"selected":[1540],"active":[1540]}]]],["p-37ee290d",[[769,"pf-page-header",{"hasBreadcrumbs":[32],"hasMetadata":[32],"hasActions":[32]}]]],["p-ae5fd08e",[[769,"pf-pagination",{"page":[1026],"totalPages":[2,"total-pages"],"siblingCount":[2,"sibling-count"],"boundaryCount":[2,"boundary-count"],"showPrevNext":[516,"show-prev-next"],"disabled":[516],"label":[1]}]]],["p-2798795f",[[769,"pf-pie-chart",{"size":[2],"cutout":[2],"showLegend":[516,"show-legend"],"label":[1],"gradient":[32],"hasData":[32],"refresh":[64]},null,{"cutout":[{"sync":0}]}]]],["p-f3d80b42",[[769,"pf-pie-slice",{"value":[514],"color":[513],"swatch":[1025],"share":[1026],"drawn":[1540]}]]],["p-4e7c51e4",[[769,"pf-popover",{"open":[1540],"align":[1],"label":[1],"dismissable":[4],"show":[64],"hide":[64]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-9d93b1ea",[[513,"pf-progress-bar",{"value":[2],"max":[2],"showValue":[516,"show-value"],"label":[1]}]]],["p-a7ce64b1",[[513,"pf-progress-circle",{"value":[2],"max":[2],"size":[2],"strokeWidth":[2,"stroke-width"],"showValue":[516,"show-value"],"label":[1]}]]],["p-1133b2fa",[[769,"pf-progress-step",{"status":[513],"state":[1537],"position":[1026],"last":[1540],"orientation":[1537]}]]],["p-f689e353",[[769,"pf-progress-steps",{"orientation":[513],"refresh":[64]},null,{"orientation":[{"handleOrientationChange":0}]}]]],["p-b6b18062",[[513,"pf-radar-axis",{"label":[513],"value":[514],"drawn":[1540]}]]],["p-be2c6150",[[769,"pf-radar-chart",{"size":[2],"max":[2],"levels":[2],"showAxes":[516,"show-axes"],"showLegend":[516,"show-legend"],"label":[1],"axes":[32],"refresh":[64]},null,{"max":[{"sync":0}]}]]],["p-3fd3444b",[[785,"pf-radio-button",{"value":[513],"checked":[1540],"disabled":[516]}]]],["p-6d3c4094",[[833,"pf-radio-group",{"name":[513],"value":[1025],"legend":[1],"error":[1],"orientation":[513],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},[[0,"pfRadioSelect","handleSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"syncFormState":0},{"syncChildren":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"disabled":[{"syncChildren":0}]}]]],["p-1bc87b8c",[[769,"pf-resizable",{"orientation":[513],"size":[1026],"min":[2],"max":[2],"step":[2],"handleLabel":[1,"handle-label"]},[[1,"pointerup","handlePointerEnd"],[1,"pointercancel","handlePointerEnd"]],{"min":[{"handleBoundsChange":0}],"max":[{"handleBoundsChange":0}]}]]],["p-4df4eed8",[[577,"pf-rich-text-editor",{"name":[513],"value":[1025],"label":[1],"description":[1],"error":[1],"placeholder":[1],"minHeight":[2,"min-height"],"characterMax":[2,"character-max"],"required":[516],"disabled":[516],"characterCount":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"format":[64]},null,{"value":[{"handleValueChange":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-b4480baf",[[769,"pf-scroll-area",{"orientation":[513],"focusable":[4]}]]],["p-c82804d4",[[769,"pf-section-footer",{"divider":[516],"align":[513],"hasHeading":[32],"hasActions":[32]}]]],["p-76f0f473",[[769,"pf-section-header",{"divider":[516],"align":[513],"hasMetadata":[32],"hasActions":[32]}]]],["p-fd5a5ea1",[[769,"pf-sidebar-navigation",{"label":[1],"hasHeader":[32],"hasFooter":[32],"refresh":[64]},[[0,"pfNavStructure","handleStructureChange"]]]]],["p-4959a556",[[769,"pf-slideout-menu",{"open":[1540],"placement":[513],"size":[513],"heading":[1],"description":[1],"label":[1],"dismissable":[4],"showCloseButton":[4,"show-close-button"],"hasFooter":[32],"show":[64],"hide":[64]},null,{"open":[{"syncOpen":0}]}]]],["p-48b2d3f7",[[593,"pf-slider",{"name":[513],"value":[1026],"min":[2],"max":[2],"step":[2],"label":[1],"description":[1],"error":[1],"showValue":[516,"show-value"],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"min":[{"syncFormState":0}],"max":[{"syncFormState":0}]}]]],["p-b4774cba",[[513,"pf-sparkline",{"data":[1],"width":[2],"height":[2],"variant":[513],"strokeWidth":[2,"stroke-width"],"color":[1],"endDot":[516,"end-dot"],"animated":[516],"label":[1]}]]],["p-d0d2070b",[[593,"pf-switch",{"name":[513],"checked":[1540],"value":[1],"label":[1],"error":[1],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"checked":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"value":[{"syncFormState":0}]}]]],["p-0bbec059",[[769,"pf-tab-panel",{"value":[513],"active":[1540]}]]],["p-068baf6d",[[769,"pf-table",{"dense":[516],"striped":[516],"hoverable":[516],"stickyHeader":[516,"sticky-header"],"sortKey":[1537,"sort-key"],"sortDirection":[1537,"sort-direction"],"label":[1],"isEmpty":[32],"hasCaption":[32],"refresh":[64]},[[0,"pfTableSort","handleSort"]],{"sortKey":[{"handleSortChange":0}],"sortDirection":[{"handleSortChange":0}]}]]],["p-4e785310",[[769,"pf-table-cell",{"head":[1540],"last":[1540],"align":[513],"width":[1],"sortKey":[513,"sort-key"],"sortable":[516],"sort":[1025]}]]],["p-8e304481",[[769,"pf-table-row",{"head":[516],"odd":[1540],"last":[1540]},null,{"head":[{"sync":0}],"last":[{"sync":0}]}]]],["p-3843faa6",[[769,"pf-tabs",{"value":[1025],"variant":[513],"size":[513],"fullWidth":[516,"full-width"],"refresh":[64]},[[0,"pfTabSelect","handleTabSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"handleStateChange":0}],"variant":[{"handleStateChange":0}],"size":[{"handleStateChange":0}],"fullWidth":[{"handleStateChange":0}]}]]],["p-845c5252",[[593,"pf-textarea",{"name":[513],"value":[1025],"rows":[2],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"readonly":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-578db1a6",[[769,"pf-timeline",{"label":[1],"refresh":[64]},null,{"label":[{"handleLabelChange":0}]}]]],["p-ea63c122",[[769,"pf-timeline-item",{"tone":[513],"last":[1540],"hasIcon":[32]}]]],["p-4b05851a",[[769,"pf-toolbar",{"orientation":[513]},[[0,"focusin","handleFocusIn"],[0,"keydown","handleKeyDown"]],{"orientation":[{"sync":0}]}]]],["p-41d997d9",[[513,"pf-toolbar-separator",{"orientation":[513]}]]],["p-a864dae5",[[769,"pf-tooltip",{"placement":[513],"delay":[2],"open":[4],"disabled":[516],"resolvedSide":[32]},[[1,"pointerenter","handlePointerEnter"],[1,"pointerleave","handlePointerLeave"],[0,"focusin","handleFocusIn"],[0,"focusout","handleFocusOut"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-25d0a34b",[[769,"pf-tree-view",{"value":[1537],"expanded":[1537],"label":[1],"activeValue":[32],"refresh":[64],"expandAll":[64],"collapseAll":[64]},[[0,"pfTreeSelect","handleSelect"],[0,"pfTreeToggle","handleToggle"],[0,"keydown","handleKeyDown"],[0,"pfTreeStructure","handleStructureChange"]],{"value":[{"handleStateChange":0}],"expanded":[{"handleStateChange":0}]}]]],["p-1e7e8d25",[[785,"pf-utility-button",{"variant":[513],"size":[513],"disabled":[516],"type":[1],"label":[1],"tooltip":[1]}]]],["p-a4fad812",[[769,"pf-video-player",{"src":[1],"sources":[16],"tracks":[16],"label":[1],"description":[1],"error":[1],"aspectRatio":[513,"aspect-ratio"],"controls":[4],"poster":[1],"preload":[1],"muted":[516],"loop":[516],"autoplay":[516],"play":[64],"pause":[64],"getVideoElement":[64]}]]],["p-6cfacd82",[[769,"pf-visually-hidden",{"focusable":[516]}]]],["p-2577564c",[[513,"pf-icon",{"name":[1],"label":[1]}]]],["p-b442330b",[[513,"pf-calendar",{"value":[1537],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"showOutsideDays":[4,"show-outside-days"],"label":[1],"isDateDisabled":[16],"displayMonth":[32],"focusedDate":[32],"goToMonth":[64],"focusSelectedDay":[64]},null,{"value":[{"syncValue":0}]}]]],["p-4b7c186f",[[769,"pf-notification",{"variant":[513],"heading":[1],"description":[1],"dismissable":[516],"exiting":[1540],"hasSlottedBody":[32],"dismiss":[64]}]]],["p-aa2acec3",[[769,"pf-tag",{"variant":[513],"dismissible":[516],"dismissLabel":[1,"dismiss-label"]}]]],["p-717b552a",[[769,"pf-avatar",{"src":[1],"alt":[1],"name":[1],"size":[513],"status":[513]}]]],["p-a4cc62e1",[[769,"pf-badge",{"variant":[513]}]]],["p-ad93b614",[[769,"pf-kbd",{"keys":[16],"size":[513],"separator":[1]}]]]]'),e)}));
1
+ import{p as e,g as a,b as t}from"./p-Bm6UxEit.js";export{s as setNonce}from"./p-Bm6UxEit.js";var l=()=>{const a=import.meta.url;const t={};if(a!==""){t.resourcesUrl=new URL(".",a).href}return e(t)};l().then((async e=>{await a();return t(JSON.parse('[["p-4b16ef92",[[769,"pf-command-palette",{"open":[1540],"placeholder":[1],"emptyMessage":[1,"empty-message"],"label":[1],"dismissable":[4],"query":[32],"matchCount":[32],"show":[64],"hide":[64],"refresh":[64]},[[0,"pfCommandSelect","handleCommandSelect"]],{"open":[{"syncOpen":0}]}]]],["p-ab6c09e7",[[577,"pf-date-picker",{"name":[513],"value":[1025],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"allowClear":[4,"allow-clear"],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"showOutsideDays":[4,"show-outside-days"],"isDateDisabled":[16],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-ac3fcb57",[[769,"pf-tab",{"value":[513],"disabled":[516],"selected":[1540],"variant":[1537],"size":[1537],"fullWidth":[1540,"full-width"],"icon":[1],"iconPlacement":[1,"icon-placement"],"count":[2],"badgePlacement":[1,"badge-placement"]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]]]]],["p-45039de3",[[577,"pf-tag-input",{"name":[513],"value":[1537],"label":[1],"description":[1],"error":[1],"placeholder":[1],"max":[2],"allowDuplicates":[4,"allow-duplicates"],"tagVariant":[1,"tag-variant"],"required":[516],"disabled":[516],"validate":[16],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"name":[{"syncFormState":0}],"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-a1a7838d",[[769,"pf-toaster",{"placement":[513],"duration":[2],"entries":[32],"toast":[64],"dismiss":[64],"dismissAll":[64]}]]],["p-685f817b",[[785,"pf-accordion-item",{"value":[513],"disabled":[516],"expanded":[1540],"headingLevel":[1026,"heading-level"]}]]],["p-bf044fb5",[[769,"pf-alert",{"variant":[513],"heading":[1],"description":[1],"dismissible":[516],"dismissLabel":[1,"dismiss-label"],"exiting":[32],"hasSlottedBody":[32],"dismiss":[64]}]]],["p-248bd301",[[769,"pf-avatar-group",{"max":[2],"size":[513],"total":[2],"label":[1],"overflow":[32],"counted":[32],"refresh":[64]},null,{"max":[{"handleStateChange":0}],"size":[{"handleStateChange":0}],"total":[{"handleStateChange":0}]}]]],["p-f855c9d4",[[769,"pf-button-group-item",{"value":[513],"disabled":[516],"groupDisabled":[1540,"group-disabled"],"selected":[1540],"icon":[1],"dot":[516]}]]],["p-8718bb3a",[[769,"pf-carousel",{"index":[1026],"loop":[516],"showIndicators":[516,"show-indicators"],"autoPlay":[516,"auto-play"],"autoPlayInterval":[2,"auto-play-interval"],"label":[1],"previousLabel":[1,"previous-label"],"nextLabel":[1,"next-label"],"total":[32],"refresh":[64],"next":[64],"previous":[64]},null,{"index":[{"handleIndexChange":0}],"loop":[{"handleIndexChange":0}],"autoPlay":[{"handleTimerChange":0}],"autoPlayInterval":[{"handleTimerChange":0}]}]]],["p-fa1302c7",[[769,"pf-code-snippet",{"code":[1],"language":[513],"heading":[1],"showLineNumbers":[516,"show-line-numbers"],"maxHeight":[2,"max-height"],"copyLabel":[1,"copy-label"],"copiedLabel":[1,"copied-label"],"copyFailedLabel":[1,"copy-failed-label"],"feedbackDuration":[2,"feedback-duration"],"copied":[32],"failed":[32],"hasMarkup":[32],"copy":[64]}]]],["p-1bb6b456",[[769,"pf-collapsible",{"open":[1540],"disabled":[516],"showChevron":[4,"show-chevron"],"show":[64],"hide":[64]},[[0,"keydown","handleKeyDown"]],{"open":[{"handleOpenChange":0}]}]]],["p-22d8c69d",[[833,"pf-combobox",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"emptyMessage":[1,"empty-message"],"required":[516],"disabled":[516],"clearable":[4],"clearLabel":[1,"clear-label"],"query":[32],"matchCount":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"]],{"value":[{"syncFormState":0},{"syncSelection":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-02e28338",[[577,"pf-date-range-picker",{"name":[513],"value":[1025],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"allowClear":[4,"allow-clear"],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"isDateDisabled":[16],"leftMonth":[32],"focusedDate":[32],"hovered":[32],"awaitingEnd":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncDisplayedMonths":0},{"syncFormState":0}],"name":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-742f2cc4",[[769,"pf-empty-state",{"size":[513],"icon":[1],"hasIcon":[32],"hasAction":[32]}]]],["p-04869bdc",[[577,"pf-file-uploader",{"name":[513],"files":[1040],"accept":[1],"multiple":[516],"maxFiles":[2,"max-files"],"maxFileSize":[2,"max-file-size"],"label":[1],"description":[1],"error":[1],"required":[516],"disabled":[516],"rejection":[32],"dragDepth":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"open":[64]},null,{"files":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"rejection":[{"syncFormState":0}]}]]],["p-b26df5a0",[[769,"pf-inline-cta",{"tone":[513],"icon":[1],"dismissible":[516],"dismissLabel":[1,"dismiss-label"],"exiting":[1540],"hasIcon":[32],"hasAction":[32],"dismiss":[64]}]]],["p-4217a92a",[[769,"pf-metric-card",{"trend":[513],"icon":[1],"hasIcon":[32],"hasAction":[32],"hasTrend":[32]}]]],["p-ec8df806",[[833,"pf-multi-select",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"maxVisibleOptions":[2,"max-visible-options"],"chips":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"],[0,"keydown","handleKeyDown"]],{"name":[{"syncFormState":0}],"value":[{"syncFormState":0},{"syncOptions":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-7197ef71",[[593,"pf-number-input",{"name":[513],"value":[1025],"min":[2],"max":[2],"step":[2],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"decrementLabel":[1,"decrement-label"],"incrementLabel":[1,"increment-label"],"draft":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"stepBy":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-aa869013",[[513,"pf-rating-badge",{"value":[2],"max":[2],"reviews":[2],"size":[513]}]]],["p-dcaaedeb",[[513,"pf-rating-stars",{"value":[2],"max":[2],"size":[2],"showValue":[4,"show-value"],"label":[1]}]]],["p-51353d53",[[833,"pf-select",{"name":[513],"value":[1537],"open":[1540],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"maxVisibleOptions":[2,"max-visible-options"],"selectedLabel":[32],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"refresh":[64]},[[0,"pfOptionSelect","handleOptionSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"syncFormState":0},{"syncOptions":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-2add2e98",[[577,"pf-time-picker",{"name":[513],"value":[1025],"open":[1540],"hourCycle":[2,"hour-cycle"],"minuteStep":[2,"minute-step"],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"show":[64],"hide":[64],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"open":[{"syncOpen":0}]}]]],["p-c07c5847",[[769,"pf-tree-item",{"value":[513],"disabled":[516],"icon":[1],"level":[1026],"selected":[1540],"expanded":[1540],"hasChildren":[1540,"has-children"],"active":[1540],"hasBadge":[32]}]]],["p-26e119df",[[769,"pf-accordion",{"value":[1537],"type":[513],"headingLevel":[2,"heading-level"],"refresh":[64]},[[0,"pfAccordionToggle","handleToggle"],[0,"keydown","handleKeyDown"]],{"value":[{"handleStateChange":0}],"type":[{"handleStateChange":0}],"headingLevel":[{"handleStateChange":0}]}]]],["p-fe6f403c",[[513,"pf-badge-group",{"label":[1],"message":[1],"color":[513],"appearance":[513],"badgePosition":[513,"badge-position"]}]]],["p-b2df1ecb",[[769,"pf-bar-chart",{"data":[1],"stacked":[516],"showLegend":[516,"show-legend"],"yAxisLabel":[1,"y-axis-label"],"label":[1],"series":[32],"refresh":[64]},null,{"data":[{"sync":0}]}]]],["p-51528462",[[769,"pf-breadcrumb",{"href":[513],"current":[516],"currentPage":[1540,"current-page"],"last":[1540],"separator":[1025]}]]],["p-77168a0d",[[769,"pf-breadcrumbs",{"label":[1],"separator":[1],"refresh":[64]},null,{"separator":[{"handleSeparatorChange":0}]}]]],["p-7e5ba1f9",[[785,"pf-button",{"variant":[513],"size":[513],"fullWidth":[516,"full-width"],"loading":[516],"disabled":[516],"type":[1],"label":[1]}]]],["p-8a1e2ba8",[[769,"pf-button-group",{"value":[1537],"multiple":[516],"disabled":[516],"refresh":[64]},[[0,"pfButtonGroupSelect","handleSelect"]],{"value":[{"handleStateChange":0}],"multiple":[{"handleStateChange":0}],"disabled":[{"handleStateChange":0}]}]]],["p-22c7e5b4",[[257,"pf-card"]]],["p-69d27f61",[[257,"pf-card-content"]]],["p-d4bbcba0",[[257,"pf-card-footer"]]],["p-f0889512",[[257,"pf-card-header"]]],["p-643f7e00",[[769,"pf-carousel-slide",{"active":[1540],"position":[1026],"total":[1026]}]]],["p-8e1a4b26",[[769,"pf-chart-series",{"seriesKey":[513,"series-key"],"color":[513],"dashed":[516],"swatch":[1025]}]]],["p-fd802631",[[593,"pf-checkbox",{"name":[513],"checked":[1540],"value":[1],"label":[1],"error":[1],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"checked":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"value":[{"syncFormState":0}]}]]],["p-3cd7d421",[[769,"pf-command-group",{"label":[1]}]]],["p-9dc1dd8a",[[769,"pf-command-item",{"value":[513],"description":[1],"disabled":[516]}]]],["p-43c103bb",[[769,"pf-content-divider",{"orientation":[513],"inset":[516],"hasLabel":[32]}]]],["p-31e0fbc7",[[769,"pf-context-menu",{"open":[1540],"label":[1],"disabled":[516],"showAt":[64],"hide":[64]},[[0,"contextmenu","handleContextMenu"],[0,"pfMenuSelect","handleMenuSelect"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-dd0e0d79",[[513,"pf-credit-card",{"brand":[513],"cardNumber":[1,"card-number"],"cardholderName":[1,"cardholder-name"],"expiry":[1],"cvc":[1],"masked":[516]}]]],["p-03db6bae",[[769,"pf-dropdown",{"open":[1540],"align":[1],"label":[1],"disabled":[516],"show":[64],"hide":[64]},[[0,"click","handleClick"],[0,"pfMenuSelect","handleMenuSelect"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-aac27e62",[[769,"pf-gauge-chart",{"value":[2],"max":[2],"size":[2],"strokeWidth":[2,"stroke-width"],"color":[1],"label":[1]}]]],["p-19c0145c",[[769,"pf-header-navigation",{"label":[1],"hasBrand":[32],"hasActions":[32],"refresh":[64]},[[0,"pfNavStructure","handleStructureChange"]]]]],["p-aa615fe9",[[769,"pf-heatmap",{"data":[1],"startDate":[1,"start-date"],"endDate":[1,"end-date"],"levels":[2],"weekStartsOn":[2,"week-starts-on"],"cellSize":[2,"cell-size"],"cellGap":[2,"cell-gap"],"showWeekdayLabels":[516,"show-weekday-labels"],"showMonthLabels":[516,"show-month-labels"],"label":[1]}]]],["p-dd48d94d",[[593,"pf-input",{"name":[513],"value":[1025],"type":[513],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"readonly":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-6066ce98",[[769,"pf-line-chart",{"data":[1],"area":[516],"curved":[516],"showLegend":[516,"show-legend"],"yAxisLabel":[1,"y-axis-label"],"label":[1],"series":[32],"refresh":[64]},null,{"data":[{"sync":0}]}]]],["p-a5b5c09a",[[513,"pf-loading-dots",{"size":[513],"label":[1]}]]],["p-f5242cee",[[513,"pf-loading-skeleton",{"width":[8],"height":[8],"rounded":[516],"label":[1]}]]],["p-50ad12be",[[513,"pf-loading-spinner",{"size":[2],"label":[1]}]]],["p-1e171d52",[[769,"pf-menu-item",{"value":[513],"disabled":[516],"destructive":[516]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]]]]],["p-34f2df95",[[1,"pf-menu-separator"]]],["p-1fa3b37b",[[257,"pf-metric-grid"]]],["p-f5df568f",[[769,"pf-modal",{"open":[1540],"size":[513],"label":[1],"dismissable":[4],"showCloseButton":[4,"show-close-button"],"show":[64],"hide":[64]},null,{"open":[{"syncOpen":0}]}]]],["p-edb28479",[[257,"pf-modal-body"]]],["p-e9d767df",[[257,"pf-modal-footer"]]],["p-e882124b",[[257,"pf-modal-header"]]],["p-f713c62d",[[769,"pf-nav-item",{"href":[513],"target":[1],"rel":[1],"current":[516],"currentPage":[1540,"current-page"],"disabled":[516],"orientation":[1537]},null,{"current":[{"handleCurrentChange":0}]}]]],["p-97dd4193",[[769,"pf-nav-section",{"hasTitle":[32]}]]],["p-3133eb1a",[[769,"pf-option",{"value":[513],"disabled":[516],"selected":[1540],"active":[1540]}]]],["p-37ee290d",[[769,"pf-page-header",{"hasBreadcrumbs":[32],"hasMetadata":[32],"hasActions":[32]}]]],["p-ae5fd08e",[[769,"pf-pagination",{"page":[1026],"totalPages":[2,"total-pages"],"siblingCount":[2,"sibling-count"],"boundaryCount":[2,"boundary-count"],"showPrevNext":[516,"show-prev-next"],"disabled":[516],"label":[1]}]]],["p-2798795f",[[769,"pf-pie-chart",{"size":[2],"cutout":[2],"showLegend":[516,"show-legend"],"label":[1],"gradient":[32],"hasData":[32],"refresh":[64]},null,{"cutout":[{"sync":0}]}]]],["p-f3d80b42",[[769,"pf-pie-slice",{"value":[514],"color":[513],"swatch":[1025],"share":[1026],"drawn":[1540]}]]],["p-4e7c51e4",[[769,"pf-popover",{"open":[1540],"align":[1],"label":[1],"dismissable":[4],"show":[64],"hide":[64]},[[0,"click","handleClick"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-9d93b1ea",[[513,"pf-progress-bar",{"value":[2],"max":[2],"showValue":[516,"show-value"],"label":[1]}]]],["p-a7ce64b1",[[513,"pf-progress-circle",{"value":[2],"max":[2],"size":[2],"strokeWidth":[2,"stroke-width"],"showValue":[516,"show-value"],"label":[1]}]]],["p-1133b2fa",[[769,"pf-progress-step",{"status":[513],"state":[1537],"position":[1026],"last":[1540],"orientation":[1537]}]]],["p-f689e353",[[769,"pf-progress-steps",{"orientation":[513],"refresh":[64]},null,{"orientation":[{"handleOrientationChange":0}]}]]],["p-b6b18062",[[513,"pf-radar-axis",{"label":[513],"value":[514],"drawn":[1540]}]]],["p-be2c6150",[[769,"pf-radar-chart",{"size":[2],"max":[2],"levels":[2],"showAxes":[516,"show-axes"],"showLegend":[516,"show-legend"],"label":[1],"axes":[32],"refresh":[64]},null,{"max":[{"sync":0}]}]]],["p-3fd3444b",[[785,"pf-radio-button",{"value":[513],"checked":[1540],"disabled":[516]}]]],["p-6d3c4094",[[833,"pf-radio-group",{"name":[513],"value":[1025],"legend":[1],"error":[1],"orientation":[513],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},[[0,"pfRadioSelect","handleSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"syncFormState":0},{"syncChildren":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"disabled":[{"syncChildren":0}]}]]],["p-1bc87b8c",[[769,"pf-resizable",{"orientation":[513],"size":[1026],"min":[2],"max":[2],"step":[2],"handleLabel":[1,"handle-label"]},[[1,"pointerup","handlePointerEnd"],[1,"pointercancel","handlePointerEnd"]],{"min":[{"handleBoundsChange":0}],"max":[{"handleBoundsChange":0}]}]]],["p-4df4eed8",[[577,"pf-rich-text-editor",{"name":[513],"value":[1025],"label":[1],"description":[1],"error":[1],"placeholder":[1],"minHeight":[2,"min-height"],"characterMax":[2,"character-max"],"required":[516],"disabled":[516],"characterCount":[32],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64],"format":[64]},null,{"value":[{"handleValueChange":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-b4480baf",[[769,"pf-scroll-area",{"orientation":[513],"focusable":[4]}]]],["p-c82804d4",[[769,"pf-section-footer",{"divider":[516],"align":[513],"hasHeading":[32],"hasActions":[32]}]]],["p-76f0f473",[[769,"pf-section-header",{"divider":[516],"align":[513],"hasMetadata":[32],"hasActions":[32]}]]],["p-5b98848c",[[769,"pf-sidebar-navigation",{"label":[1],"hasHeader":[32],"hasFooter":[32],"refresh":[64]},[[0,"pfNavStructure","handleStructureChange"]]]]],["p-4959a556",[[769,"pf-slideout-menu",{"open":[1540],"placement":[513],"size":[513],"heading":[1],"description":[1],"label":[1],"dismissable":[4],"showCloseButton":[4,"show-close-button"],"hasFooter":[32],"show":[64],"hide":[64]},null,{"open":[{"syncOpen":0}]}]]],["p-01ed0d56",[[593,"pf-slider",{"name":[513],"value":[1026],"min":[2],"max":[2],"step":[2],"label":[1],"description":[1],"error":[1],"showValue":[516,"show-value"],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"min":[{"syncFormState":0}],"max":[{"syncFormState":0}]}]]],["p-b4774cba",[[513,"pf-sparkline",{"data":[1],"width":[2],"height":[2],"variant":[513],"strokeWidth":[2,"stroke-width"],"color":[1],"endDot":[516,"end-dot"],"animated":[516],"label":[1]}]]],["p-4dfe7e8a",[[593,"pf-switch",{"name":[513],"checked":[1540],"value":[1],"label":[1],"error":[1],"required":[516],"disabled":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"checked":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}],"value":[{"syncFormState":0}]}]]],["p-0bbec059",[[769,"pf-tab-panel",{"value":[513],"active":[1540]}]]],["p-068baf6d",[[769,"pf-table",{"dense":[516],"striped":[516],"hoverable":[516],"stickyHeader":[516,"sticky-header"],"sortKey":[1537,"sort-key"],"sortDirection":[1537,"sort-direction"],"label":[1],"isEmpty":[32],"hasCaption":[32],"refresh":[64]},[[0,"pfTableSort","handleSort"]],{"sortKey":[{"handleSortChange":0}],"sortDirection":[{"handleSortChange":0}]}]]],["p-4e785310",[[769,"pf-table-cell",{"head":[1540],"last":[1540],"align":[513],"width":[1],"sortKey":[513,"sort-key"],"sortable":[516],"sort":[1025]}]]],["p-8e304481",[[769,"pf-table-row",{"head":[516],"odd":[1540],"last":[1540]},null,{"head":[{"sync":0}],"last":[{"sync":0}]}]]],["p-3843faa6",[[769,"pf-tabs",{"value":[1025],"variant":[513],"size":[513],"fullWidth":[516,"full-width"],"refresh":[64]},[[0,"pfTabSelect","handleTabSelect"],[0,"keydown","handleKeyDown"]],{"value":[{"handleStateChange":0}],"variant":[{"handleStateChange":0}],"size":[{"handleStateChange":0}],"fullWidth":[{"handleStateChange":0}]}]]],["p-d7ca4026",[[593,"pf-textarea",{"name":[513],"value":[1025],"rows":[2],"label":[1],"description":[1],"error":[1],"placeholder":[1],"required":[516],"disabled":[516],"readonly":[516],"checkValidity":[64],"reportValidity":[64],"getValidationMessage":[64]},null,{"value":[{"syncFormState":0}],"error":[{"syncFormState":0}],"required":[{"syncFormState":0}]}]]],["p-578db1a6",[[769,"pf-timeline",{"label":[1],"refresh":[64]},null,{"label":[{"handleLabelChange":0}]}]]],["p-ea63c122",[[769,"pf-timeline-item",{"tone":[513],"last":[1540],"hasIcon":[32]}]]],["p-4b05851a",[[769,"pf-toolbar",{"orientation":[513]},[[0,"focusin","handleFocusIn"],[0,"keydown","handleKeyDown"]],{"orientation":[{"sync":0}]}]]],["p-41d997d9",[[513,"pf-toolbar-separator",{"orientation":[513]}]]],["p-a864dae5",[[769,"pf-tooltip",{"placement":[513],"delay":[2],"open":[4],"disabled":[516],"resolvedSide":[32]},[[1,"pointerenter","handlePointerEnter"],[1,"pointerleave","handlePointerLeave"],[0,"focusin","handleFocusIn"],[0,"focusout","handleFocusOut"],[0,"keydown","handleKeyDown"]],{"open":[{"syncOpen":0}]}]]],["p-25d0a34b",[[769,"pf-tree-view",{"value":[1537],"expanded":[1537],"label":[1],"activeValue":[32],"refresh":[64],"expandAll":[64],"collapseAll":[64]},[[0,"pfTreeSelect","handleSelect"],[0,"pfTreeToggle","handleToggle"],[0,"keydown","handleKeyDown"],[0,"pfTreeStructure","handleStructureChange"]],{"value":[{"handleStateChange":0}],"expanded":[{"handleStateChange":0}]}]]],["p-1e7e8d25",[[785,"pf-utility-button",{"variant":[513],"size":[513],"disabled":[516],"type":[1],"label":[1],"tooltip":[1]}]]],["p-a4fad812",[[769,"pf-video-player",{"src":[1],"sources":[16],"tracks":[16],"label":[1],"description":[1],"error":[1],"aspectRatio":[513,"aspect-ratio"],"controls":[4],"poster":[1],"preload":[1],"muted":[516],"loop":[516],"autoplay":[516],"play":[64],"pause":[64],"getVideoElement":[64]}]]],["p-6cfacd82",[[769,"pf-visually-hidden",{"focusable":[516]}]]],["p-2577564c",[[513,"pf-icon",{"name":[1],"label":[1]}]]],["p-b442330b",[[513,"pf-calendar",{"value":[1537],"min":[1],"max":[1],"startYear":[2,"start-year"],"endYear":[2,"end-year"],"showOutsideDays":[4,"show-outside-days"],"label":[1],"isDateDisabled":[16],"displayMonth":[32],"focusedDate":[32],"goToMonth":[64],"focusSelectedDay":[64]},null,{"value":[{"syncValue":0}]}]]],["p-4b7c186f",[[769,"pf-notification",{"variant":[513],"heading":[1],"description":[1],"dismissable":[516],"exiting":[1540],"hasSlottedBody":[32],"dismiss":[64]}]]],["p-aa2acec3",[[769,"pf-tag",{"variant":[513],"dismissible":[516],"dismissLabel":[1,"dismiss-label"]}]]],["p-717b552a",[[769,"pf-avatar",{"src":[1],"alt":[1],"name":[1],"size":[513],"status":[513]}]]],["p-a4cc62e1",[[769,"pf-badge",{"variant":[513]}]]],["p-ad93b614",[[769,"pf-kbd",{"keys":[16],"size":[513],"separator":[1]}]]]]'),e)}));
2
2
  //# sourceMappingURL=pitchfork.esm.js.map
@@ -7,6 +7,7 @@ import { EventEmitter } from '../../stencil-public-runtime';
7
7
  * @part label - the label element.
8
8
  */
9
9
  export declare class PfCheckbox {
10
+ el: HTMLElement;
10
11
  internals: ElementInternals;
11
12
  /**
12
13
  * Submitted under this name.
@@ -39,8 +39,17 @@ export declare class PfHeaderNavigation {
39
39
  componentWillLoad(): void;
40
40
  componentDidLoad(): void;
41
41
  /**
42
- * Re-reads the items, for a consumer who marked one current through its
43
- * *property* — which leaves no attribute and fires no `slotchange`.
42
+ * An item's `current` changed, so the resolution has to run again.
43
+ *
44
+ * The items are this navigation's own light-DOM children, so nothing is
45
+ * retargeted and a host listener is safe — the same reason the sidebar can
46
+ * listen for a section's copy of this event. `refresh()` stays for a
47
+ * consumer who changes something else the group reads.
48
+ */
49
+ handleStructureChange(event: CustomEvent<void>): void;
50
+ /**
51
+ * Re-reads the items, for a consumer who changed something the group reads
52
+ * and has no event for.
44
53
  */
45
54
  refresh(): Promise<void>;
46
55
  /** Direct children only: a nested navigation owns its own items. */
@@ -15,6 +15,7 @@ export type PfInputType = 'text' | 'email' | 'password' | 'search' | 'tel' | 'ur
15
15
  * @part error - the error message below the control.
16
16
  */
17
17
  export declare class PfInput {
18
+ el: HTMLElement;
18
19
  internals: ElementInternals;
19
20
  /**
20
21
  * Submitted under this name.
@@ -5,9 +5,13 @@ export type PfModalSize = 'sm' | 'md' | 'lg';
5
5
  *
6
6
  * A native `<dialog>` opened with `showModal()`, which from inside a shadow
7
7
  * root gives the focus trap, Escape and the backdrop for nothing — all
8
- * measured: focus moves inside on open and cannot be taken by a light-DOM
9
- * button, and a real Escape fires `cancel` then `close`. So `trapFocus` from
10
- * core is not needed here, unlike in the React component.
8
+ * measured: focus cannot be taken by a light-DOM button, and a real Escape
9
+ * fires `cancel` then `close`. So `trapFocus` from core is not needed here,
10
+ * unlike in the React component.
11
+ *
12
+ * The one part of `showModal()` that cannot be relied on is where it puts
13
+ * focus, and the gap is exactly the case every framework consumer is in. See
14
+ * `showDialog` below.
11
15
  *
12
16
  * What `showModal()` does *not* do is lock page scroll — measured: a real
13
17
  * wheel still scrolled the page behind an open modal — so this element locks
@@ -64,7 +68,56 @@ export declare class PfModal {
64
68
  private get dialog();
65
69
  private lockScroll;
66
70
  private unlockScroll;
71
+ /**
72
+ * Opens the dialog, and makes sure focus actually went into it.
73
+ *
74
+ * `showModal()` focuses the dialog or its first focusable descendant — but
75
+ * **not** when light-DOM children were appended in the same task as the
76
+ * open. Measured in Chromium with no framework involved: append the three
77
+ * `pf-modal-*` sections to a long-mounted `pf-modal` and set `open` in the
78
+ * same task, and the dialog opens with `document.activeElement` still on
79
+ * `<body>` and `:focus-within` false. Leave one frame between the two and
80
+ * focus lands inside; mount the element with its children and `open`
81
+ * already set and focus lands inside. So it is the append racing the open,
82
+ * and the flattened tree `showModal()`'s focusing steps read.
83
+ *
84
+ * That race is not an edge case: React, Angular and Vue all commit a
85
+ * modal's content and its `open` in one go, so every framework consumer got
86
+ * an open modal with focus outside it and nothing to say so — the page is
87
+ * still inert, so the only symptom is that a reader is not taken to the
88
+ * dialog and the first Tab is needed. Porting `apps/demo` is what found it.
89
+ *
90
+ * What the trace shows, with element identity and a `MutationObserver` on
91
+ * the shadow root: `showModal()` **does** focus, onto `div[part=panel]`,
92
+ * and one frame later a `focusout` with `relatedTarget: null` drops it,
93
+ * with nothing removed from the shadow root. That is Chromium's focus
94
+ * fixup running once the appended children are assigned to the slot and
95
+ * finding the panel is no longer a valid target -- so it is not a render
96
+ * that loses focus, and re-asserting after a render does not catch it
97
+ * (measured: `componentDidRender` alone changes nothing here).
98
+ *
99
+ * So the dialog watches for exactly that: a `focusout` that goes nowhere
100
+ * while the modal is open puts focus back. `requestAnimationFrame` after
101
+ * `showModal()` covers the case where focus never arrived at all, and
102
+ * `componentDidRender` covers a render that discards the focused node. All
103
+ * three are the same guarded call, and the `:focus-within` guard makes it a
104
+ * no-op whenever focus is already inside -- so none of them moves focus
105
+ * that the platform or a consumer placed.
106
+ */
67
107
  private showDialog;
108
+ componentDidRender(): void;
109
+ /**
110
+ * Focus left the dialog for nothing while it is open, which the platform
111
+ * does when its focus fixup runs after the slotted content changes.
112
+ *
113
+ * `relatedTarget` is the test: a Tab or a click inside names where focus
114
+ * went, and a modal dialog means it cannot have gone outside. The window
115
+ * losing focus also reports null, hence the `document.hasFocus()` guard --
116
+ * without it, switching tabs would pull focus back on return.
117
+ */
118
+ private onFocusOut;
119
+ /** Focus inside the open dialog, unless it is already there. */
120
+ private ensureFocusInside;
68
121
  private closeDialog;
69
122
  /** Fires on Escape. Blocking it is how a non-dismissable modal stays put. */
70
123
  private onCancel;
@@ -1,3 +1,4 @@
1
+ import { EventEmitter } from '../../stencil-public-runtime';
1
2
  /**
2
3
  * One item in a `pf-header-navigation` or a `pf-sidebar-navigation`.
3
4
  *
@@ -13,7 +14,9 @@
13
14
  *
14
15
  * `currentPage` and `orientation` are the group's to set. A consumer asks by
15
16
  * setting `current`; the group resolves every item with core's rule and
16
- * writes the answer to `currentPage`.
17
+ * writes the answer to `currentPage`. Changing the ask tells the group, so
18
+ * the answer follows a framework's re-render without the consumer calling
19
+ * anything.
17
20
  *
18
21
  * @slot - the item's label.
19
22
  * @slot icon - a leading icon.
@@ -36,6 +39,23 @@ export declare class PfNavItem {
36
39
  * behind on an item the consumer had not marked.
37
40
  */
38
41
  current: boolean;
42
+ /**
43
+ * Tells the group the ask changed, so it can resolve again.
44
+ *
45
+ * The same event `pf-nav-section` emits when its items move, because the
46
+ * groups do the same thing with both: re-read every item and resolve the
47
+ * one current page. Without this a navigation resolves at load and never
48
+ * again for a consumer who marks items through the *property*, which is
49
+ * every framework consumer — the generated bindings set props as
50
+ * properties, so there is no attribute change and no `slotchange` either.
51
+ * The symptom is a navigation whose highlight never moves while the router
52
+ * works perfectly, which is what porting `apps/demo` ran into.
53
+ *
54
+ * `current` only. Watching `currentPage` would loop, since that is what the
55
+ * group writes back.
56
+ */
57
+ pfNavStructure: EventEmitter<void>;
58
+ handleCurrentChange(): void;
39
59
  /**
40
60
  * Set by the group: the resolved current page, which is the one thing that
41
61
  * renders `aria-current="page"`. At most one item in a navigation carries