@pine-ds/core 3.26.0 → 3.26.3

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 (610) hide show
  1. package/components/mock-pds-modal.js +1 -1
  2. package/components/mock-pds-modal.js.map +1 -1
  3. package/components/pds-alert.js +2 -2
  4. package/components/pds-alert.js.map +1 -1
  5. package/components/pds-button2.js +1 -1
  6. package/components/pds-button2.js.map +1 -1
  7. package/components/pds-checkbox2.js +1 -1
  8. package/components/pds-checkbox2.js.map +1 -1
  9. package/components/pds-combobox.js +3 -3
  10. package/components/pds-combobox.js.map +1 -1
  11. package/components/pds-filter.js +14 -10
  12. package/components/pds-filter.js.map +1 -1
  13. package/components/pds-input.js +5 -2
  14. package/components/pds-input.js.map +1 -1
  15. package/components/pds-modal.js +1 -1
  16. package/components/pds-modal.js.map +1 -1
  17. package/components/pds-select.js +1 -1
  18. package/components/pds-select.js.map +1 -1
  19. package/components/pds-switch.js +1 -1
  20. package/components/pds-switch.js.map +1 -1
  21. package/components/pds-table-cell2.js +5 -4
  22. package/components/pds-table-cell2.js.map +1 -1
  23. package/components/pds-table-head-cell2.js +5 -4
  24. package/components/pds-table-head-cell2.js.map +1 -1
  25. package/components/pds-table.js +12 -10
  26. package/components/pds-table.js.map +1 -1
  27. package/components/pds-tooltip.js +1 -1
  28. package/components/pds-tooltip.js.map +1 -1
  29. package/components/scroll.js +78 -0
  30. package/components/scroll.js.map +1 -0
  31. package/dist/cjs/{index-Dlc5O3n_.js → index-BYnQkA7p.js} +3 -3
  32. package/dist/cjs/index-BYnQkA7p.js.map +1 -0
  33. package/dist/cjs/loader.cjs.js +1 -1
  34. package/dist/cjs/mock-pds-modal.cjs.entry.js +2 -2
  35. package/dist/cjs/mock-pds-modal.entry.cjs.js.map +1 -1
  36. package/dist/cjs/pds-accordion.cjs.entry.js +1 -1
  37. package/dist/cjs/pds-alert.cjs.entry.js +3 -3
  38. package/dist/cjs/pds-alert.entry.cjs.js.map +1 -1
  39. package/dist/cjs/pds-avatar.cjs.entry.js +1 -1
  40. package/dist/cjs/pds-box.cjs.entry.js +1 -1
  41. package/dist/cjs/pds-button.cjs.entry.js +2 -2
  42. package/dist/cjs/pds-button.entry.cjs.js.map +1 -1
  43. package/dist/cjs/pds-checkbox.cjs.entry.js +2 -2
  44. package/dist/cjs/pds-checkbox.entry.cjs.js.map +1 -1
  45. package/dist/cjs/pds-chip.cjs.entry.js +1 -1
  46. package/dist/cjs/pds-combobox.cjs.entry.js +4 -4
  47. package/dist/cjs/pds-combobox.entry.cjs.js.map +1 -1
  48. package/dist/cjs/pds-container.cjs.entry.js +1 -1
  49. package/dist/cjs/pds-copytext.cjs.entry.js +1 -1
  50. package/dist/cjs/pds-divider.cjs.entry.js +1 -1
  51. package/dist/cjs/pds-dropdown-menu-item.cjs.entry.js +1 -1
  52. package/dist/cjs/pds-dropdown-menu-separator.cjs.entry.js +1 -1
  53. package/dist/cjs/pds-dropdown-menu.cjs.entry.js +1 -1
  54. package/dist/cjs/pds-filter.cjs.entry.js +15 -11
  55. package/dist/cjs/pds-filter.entry.cjs.js.map +1 -1
  56. package/dist/cjs/pds-filters.cjs.entry.js +1 -1
  57. package/dist/cjs/pds-icon.cjs.entry.js +1 -1
  58. package/dist/cjs/pds-image.cjs.entry.js +1 -1
  59. package/dist/cjs/pds-input.cjs.entry.js +6 -3
  60. package/dist/cjs/pds-input.entry.cjs.js.map +1 -1
  61. package/dist/cjs/pds-link.cjs.entry.js +1 -1
  62. package/dist/cjs/pds-loader.cjs.entry.js +1 -1
  63. package/dist/cjs/pds-modal-content.cjs.entry.js +1 -1
  64. package/dist/cjs/pds-modal-footer.cjs.entry.js +1 -1
  65. package/dist/cjs/pds-modal-header.cjs.entry.js +1 -1
  66. package/dist/cjs/pds-modal.cjs.entry.js +2 -2
  67. package/dist/cjs/pds-modal.entry.cjs.js.map +1 -1
  68. package/dist/cjs/pds-multiselect.cjs.entry.js +1 -1
  69. package/dist/cjs/pds-popover.cjs.entry.js +1 -1
  70. package/dist/cjs/pds-progress.cjs.entry.js +1 -1
  71. package/dist/cjs/pds-property.cjs.entry.js +1 -1
  72. package/dist/cjs/pds-radio-group.cjs.entry.js +1 -1
  73. package/dist/cjs/pds-radio.cjs.entry.js +1 -1
  74. package/dist/cjs/pds-row.cjs.entry.js +1 -1
  75. package/dist/cjs/pds-select.cjs.entry.js +2 -2
  76. package/dist/cjs/pds-select.entry.cjs.js.map +1 -1
  77. package/dist/cjs/pds-sortable-item.cjs.entry.js +1 -1
  78. package/dist/cjs/pds-sortable.cjs.entry.js +1 -1
  79. package/dist/cjs/pds-switch.cjs.entry.js +2 -2
  80. package/dist/cjs/pds-switch.entry.cjs.js.map +1 -1
  81. package/dist/cjs/pds-tab.cjs.entry.js +1 -1
  82. package/dist/cjs/pds-table-body.cjs.entry.js +1 -1
  83. package/dist/cjs/pds-table-cell.cjs.entry.js +6 -5
  84. package/dist/cjs/pds-table-cell.entry.cjs.js.map +1 -1
  85. package/dist/cjs/pds-table-head-cell.cjs.entry.js +6 -5
  86. package/dist/cjs/pds-table-head-cell.entry.cjs.js.map +1 -1
  87. package/dist/cjs/pds-table-head.cjs.entry.js +1 -1
  88. package/dist/cjs/pds-table-row.cjs.entry.js +1 -1
  89. package/dist/cjs/pds-table.cjs.entry.js +13 -11
  90. package/dist/cjs/pds-table.entry.cjs.js.map +1 -1
  91. package/dist/cjs/pds-tabpanel.cjs.entry.js +1 -1
  92. package/dist/cjs/pds-tabs.cjs.entry.js +1 -1
  93. package/dist/cjs/pds-text.cjs.entry.js +1 -1
  94. package/dist/cjs/pds-textarea.cjs.entry.js +1 -1
  95. package/dist/cjs/pds-toast.cjs.entry.js +1 -1
  96. package/dist/cjs/pds-tooltip.cjs.entry.js +2 -2
  97. package/dist/cjs/pds-tooltip.entry.cjs.js.map +1 -1
  98. package/dist/cjs/pine-core.cjs.js +1 -1
  99. package/dist/cjs/scroll-2XcoE_6Q.js +82 -0
  100. package/dist/cjs/scroll-2XcoE_6Q.js.map +1 -0
  101. package/dist/collection/components/pds-alert/pds-alert.css +1 -1
  102. package/dist/collection/components/pds-alert/pds-alert.js +1 -1
  103. package/dist/collection/components/pds-alert/pds-alert.js.map +1 -1
  104. package/dist/collection/components/pds-button/pds-button.css +1 -1
  105. package/dist/collection/components/pds-checkbox/pds-checkbox.css +10 -6
  106. package/dist/collection/components/pds-combobox/pds-combobox.css +2 -2
  107. package/dist/collection/components/pds-combobox/pds-combobox.js +2 -2
  108. package/dist/collection/components/pds-combobox/pds-combobox.js.map +1 -1
  109. package/dist/collection/components/pds-filters/pds-filter/pds-filter.css +11 -9
  110. package/dist/collection/components/pds-filters/pds-filter/pds-filter.js +13 -9
  111. package/dist/collection/components/pds-filters/pds-filter/pds-filter.js.map +1 -1
  112. package/dist/collection/components/pds-input/pds-input.css +7 -3
  113. package/dist/collection/components/pds-input/pds-input.js +4 -1
  114. package/dist/collection/components/pds-input/pds-input.js.map +1 -1
  115. package/dist/collection/components/pds-modal/pds-modal.css +2 -1
  116. package/dist/collection/components/pds-select/pds-select.css +8 -5
  117. package/dist/collection/components/pds-switch/pds-switch.css +4 -4
  118. package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.css +6 -1
  119. package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.js +4 -3
  120. package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.js.map +1 -1
  121. package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.css +6 -1
  122. package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.js +4 -3
  123. package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.js.map +1 -1
  124. package/dist/collection/components/pds-table/pds-table.css +16 -6
  125. package/dist/collection/components/pds-table/pds-table.js +11 -9
  126. package/dist/collection/components/pds-table/pds-table.js.map +1 -1
  127. package/dist/collection/components/pds-tooltip/pds-tooltip.css +2 -1
  128. package/dist/collection/utils/scroll.js +78 -0
  129. package/dist/collection/utils/scroll.js.map +1 -0
  130. package/dist/collection/utils/test/axe.js +101 -0
  131. package/dist/collection/utils/test/axe.js.map +1 -0
  132. package/dist/docs.json +1 -1
  133. package/dist/esm/{index-CO9kz-Pi.js → index-QYCDCKN2.js} +3 -3
  134. package/dist/esm/index-QYCDCKN2.js.map +1 -0
  135. package/dist/esm/loader.js +2 -2
  136. package/dist/esm/mock-pds-modal.entry.js +2 -2
  137. package/dist/esm/mock-pds-modal.entry.js.map +1 -1
  138. package/dist/esm/pds-accordion.entry.js +1 -1
  139. package/dist/esm/pds-alert.entry.js +3 -3
  140. package/dist/esm/pds-alert.entry.js.map +1 -1
  141. package/dist/esm/pds-avatar.entry.js +1 -1
  142. package/dist/esm/pds-box.entry.js +1 -1
  143. package/dist/esm/pds-button.entry.js +2 -2
  144. package/dist/esm/pds-button.entry.js.map +1 -1
  145. package/dist/esm/pds-checkbox.entry.js +2 -2
  146. package/dist/esm/pds-checkbox.entry.js.map +1 -1
  147. package/dist/esm/pds-chip.entry.js +1 -1
  148. package/dist/esm/pds-combobox.entry.js +4 -4
  149. package/dist/esm/pds-combobox.entry.js.map +1 -1
  150. package/dist/esm/pds-container.entry.js +1 -1
  151. package/dist/esm/pds-copytext.entry.js +1 -1
  152. package/dist/esm/pds-divider.entry.js +1 -1
  153. package/dist/esm/pds-dropdown-menu-item.entry.js +1 -1
  154. package/dist/esm/pds-dropdown-menu-separator.entry.js +1 -1
  155. package/dist/esm/pds-dropdown-menu.entry.js +1 -1
  156. package/dist/esm/pds-filter.entry.js +15 -11
  157. package/dist/esm/pds-filter.entry.js.map +1 -1
  158. package/dist/esm/pds-filters.entry.js +1 -1
  159. package/dist/esm/pds-icon.entry.js +1 -1
  160. package/dist/esm/pds-image.entry.js +1 -1
  161. package/dist/esm/pds-input.entry.js +6 -3
  162. package/dist/esm/pds-input.entry.js.map +1 -1
  163. package/dist/esm/pds-link.entry.js +1 -1
  164. package/dist/esm/pds-loader.entry.js +1 -1
  165. package/dist/esm/pds-modal-content.entry.js +1 -1
  166. package/dist/esm/pds-modal-footer.entry.js +1 -1
  167. package/dist/esm/pds-modal-header.entry.js +1 -1
  168. package/dist/esm/pds-modal.entry.js +2 -2
  169. package/dist/esm/pds-modal.entry.js.map +1 -1
  170. package/dist/esm/pds-multiselect.entry.js +1 -1
  171. package/dist/esm/pds-popover.entry.js +1 -1
  172. package/dist/esm/pds-progress.entry.js +1 -1
  173. package/dist/esm/pds-property.entry.js +1 -1
  174. package/dist/esm/pds-radio-group.entry.js +1 -1
  175. package/dist/esm/pds-radio.entry.js +1 -1
  176. package/dist/esm/pds-row.entry.js +1 -1
  177. package/dist/esm/pds-select.entry.js +2 -2
  178. package/dist/esm/pds-select.entry.js.map +1 -1
  179. package/dist/esm/pds-sortable-item.entry.js +1 -1
  180. package/dist/esm/pds-sortable.entry.js +1 -1
  181. package/dist/esm/pds-switch.entry.js +2 -2
  182. package/dist/esm/pds-switch.entry.js.map +1 -1
  183. package/dist/esm/pds-tab.entry.js +1 -1
  184. package/dist/esm/pds-table-body.entry.js +1 -1
  185. package/dist/esm/pds-table-cell.entry.js +6 -5
  186. package/dist/esm/pds-table-cell.entry.js.map +1 -1
  187. package/dist/esm/pds-table-head-cell.entry.js +6 -5
  188. package/dist/esm/pds-table-head-cell.entry.js.map +1 -1
  189. package/dist/esm/pds-table-head.entry.js +1 -1
  190. package/dist/esm/pds-table-row.entry.js +1 -1
  191. package/dist/esm/pds-table.entry.js +13 -11
  192. package/dist/esm/pds-table.entry.js.map +1 -1
  193. package/dist/esm/pds-tabpanel.entry.js +1 -1
  194. package/dist/esm/pds-tabs.entry.js +1 -1
  195. package/dist/esm/pds-text.entry.js +1 -1
  196. package/dist/esm/pds-textarea.entry.js +1 -1
  197. package/dist/esm/pds-toast.entry.js +1 -1
  198. package/dist/esm/pds-tooltip.entry.js +2 -2
  199. package/dist/esm/pds-tooltip.entry.js.map +1 -1
  200. package/dist/esm/pine-core.js +2 -2
  201. package/dist/esm/scroll-DtgUQhjl.js +78 -0
  202. package/dist/esm/scroll-DtgUQhjl.js.map +1 -0
  203. package/dist/esm-es5/{index-CO9kz-Pi.js → index-QYCDCKN2.js} +3 -3
  204. package/dist/esm-es5/index-QYCDCKN2.js.map +1 -0
  205. package/dist/esm-es5/loader.js +1 -1
  206. package/dist/esm-es5/mock-pds-modal.entry.js +1 -1
  207. package/dist/esm-es5/mock-pds-modal.entry.js.map +1 -1
  208. package/dist/esm-es5/pds-accordion.entry.js +1 -1
  209. package/dist/esm-es5/pds-alert.entry.js +1 -1
  210. package/dist/esm-es5/pds-alert.entry.js.map +1 -1
  211. package/dist/esm-es5/pds-avatar.entry.js +1 -1
  212. package/dist/esm-es5/pds-box.entry.js +1 -1
  213. package/dist/esm-es5/pds-button.entry.js +1 -1
  214. package/dist/esm-es5/pds-button.entry.js.map +1 -1
  215. package/dist/esm-es5/pds-checkbox.entry.js +1 -1
  216. package/dist/esm-es5/pds-checkbox.entry.js.map +1 -1
  217. package/dist/esm-es5/pds-chip.entry.js +1 -1
  218. package/dist/esm-es5/pds-combobox.entry.js +2 -2
  219. package/dist/esm-es5/pds-combobox.entry.js.map +1 -1
  220. package/dist/esm-es5/pds-container.entry.js +1 -1
  221. package/dist/esm-es5/pds-copytext.entry.js +1 -1
  222. package/dist/esm-es5/pds-divider.entry.js +1 -1
  223. package/dist/esm-es5/pds-dropdown-menu-item.entry.js +1 -1
  224. package/dist/esm-es5/pds-dropdown-menu-separator.entry.js +1 -1
  225. package/dist/esm-es5/pds-dropdown-menu.entry.js +1 -1
  226. package/dist/esm-es5/pds-filter.entry.js +1 -1
  227. package/dist/esm-es5/pds-filter.entry.js.map +1 -1
  228. package/dist/esm-es5/pds-filters.entry.js +1 -1
  229. package/dist/esm-es5/pds-icon.entry.js +1 -1
  230. package/dist/esm-es5/pds-image.entry.js +1 -1
  231. package/dist/esm-es5/pds-input.entry.js +1 -1
  232. package/dist/esm-es5/pds-input.entry.js.map +1 -1
  233. package/dist/esm-es5/pds-link.entry.js +1 -1
  234. package/dist/esm-es5/pds-loader.entry.js +1 -1
  235. package/dist/esm-es5/pds-modal-content.entry.js +1 -1
  236. package/dist/esm-es5/pds-modal-footer.entry.js +1 -1
  237. package/dist/esm-es5/pds-modal-header.entry.js +1 -1
  238. package/dist/esm-es5/pds-modal.entry.js +1 -1
  239. package/dist/esm-es5/pds-modal.entry.js.map +1 -1
  240. package/dist/esm-es5/pds-multiselect.entry.js +1 -1
  241. package/dist/esm-es5/pds-popover.entry.js +1 -1
  242. package/dist/esm-es5/pds-progress.entry.js +1 -1
  243. package/dist/esm-es5/pds-property.entry.js +1 -1
  244. package/dist/esm-es5/pds-radio-group.entry.js +1 -1
  245. package/dist/esm-es5/pds-radio.entry.js +1 -1
  246. package/dist/esm-es5/pds-row.entry.js +1 -1
  247. package/dist/esm-es5/pds-select.entry.js +1 -1
  248. package/dist/esm-es5/pds-select.entry.js.map +1 -1
  249. package/dist/esm-es5/pds-sortable-item.entry.js +1 -1
  250. package/dist/esm-es5/pds-sortable.entry.js +1 -1
  251. package/dist/esm-es5/pds-switch.entry.js +1 -1
  252. package/dist/esm-es5/pds-switch.entry.js.map +1 -1
  253. package/dist/esm-es5/pds-tab.entry.js +1 -1
  254. package/dist/esm-es5/pds-table-body.entry.js +1 -1
  255. package/dist/esm-es5/pds-table-cell.entry.js +1 -1
  256. package/dist/esm-es5/pds-table-cell.entry.js.map +1 -1
  257. package/dist/esm-es5/pds-table-head-cell.entry.js +1 -1
  258. package/dist/esm-es5/pds-table-head-cell.entry.js.map +1 -1
  259. package/dist/esm-es5/pds-table-head.entry.js +1 -1
  260. package/dist/esm-es5/pds-table-row.entry.js +1 -1
  261. package/dist/esm-es5/pds-table.entry.js +1 -1
  262. package/dist/esm-es5/pds-table.entry.js.map +1 -1
  263. package/dist/esm-es5/pds-tabpanel.entry.js +1 -1
  264. package/dist/esm-es5/pds-tabs.entry.js +1 -1
  265. package/dist/esm-es5/pds-text.entry.js +1 -1
  266. package/dist/esm-es5/pds-textarea.entry.js +1 -1
  267. package/dist/esm-es5/pds-toast.entry.js +1 -1
  268. package/dist/esm-es5/pds-tooltip.entry.js +1 -1
  269. package/dist/esm-es5/pds-tooltip.entry.js.map +1 -1
  270. package/dist/esm-es5/pine-core.js +1 -1
  271. package/dist/esm-es5/scroll-DtgUQhjl.js +2 -0
  272. package/dist/esm-es5/scroll-DtgUQhjl.js.map +1 -0
  273. package/dist/pine-core/mock-pds-modal.entry.esm.js.map +1 -1
  274. package/dist/pine-core/p-043395a8.entry.js +2 -0
  275. package/dist/pine-core/{p-8d0c1f6d.entry.js.map → p-043395a8.entry.js.map} +1 -1
  276. package/dist/pine-core/{p-932f4860.entry.js → p-07a19657.entry.js} +2 -2
  277. package/dist/pine-core/p-08267d86.system.entry.js +2 -0
  278. package/dist/pine-core/{p-93b379c2.system.entry.js.map → p-08267d86.system.entry.js.map} +1 -1
  279. package/dist/pine-core/{p-aed5cf70.system.entry.js → p-0bc89023.system.entry.js} +2 -2
  280. package/dist/pine-core/{p-aed5cf70.system.entry.js.map → p-0bc89023.system.entry.js.map} +1 -1
  281. package/dist/pine-core/p-0ca1dada.entry.js +2 -0
  282. package/dist/pine-core/{p-b63c7247.entry.js.map → p-0ca1dada.entry.js.map} +1 -1
  283. package/dist/pine-core/{p-26aa3195.entry.js → p-0d3a6abc.entry.js} +2 -2
  284. package/dist/pine-core/p-0jF8lVUy.system.js.map +1 -0
  285. package/dist/pine-core/{p-e7e166f2.entry.js → p-1256b83e.entry.js} +2 -2
  286. package/dist/pine-core/p-1700705c.entry.js +2 -0
  287. package/dist/pine-core/{p-952b41e5.system.entry.js → p-1d7cbf49.system.entry.js} +2 -2
  288. package/dist/pine-core/p-1eJB2hvd.system.js.map +1 -0
  289. package/dist/pine-core/{p-DkENjswB.system.js.map → p-1hZDd74J.system.js.map} +1 -1
  290. package/dist/pine-core/{p-205d8c56.entry.js → p-21a858a0.entry.js} +2 -2
  291. package/dist/pine-core/{p-3c864e3d.entry.js → p-2335222d.entry.js} +2 -2
  292. package/dist/pine-core/p-24656fd4.entry.js +2 -0
  293. package/dist/pine-core/p-24656fd4.entry.js.map +1 -0
  294. package/dist/pine-core/p-2549e386.system.entry.js +2 -0
  295. package/dist/pine-core/{p-7bc34bce.system.entry.js.map → p-2549e386.system.entry.js.map} +1 -1
  296. package/dist/pine-core/{p-24f9a03b.system.entry.js → p-2728bb30.system.entry.js} +2 -2
  297. package/dist/pine-core/p-2a4be282.entry.js +3 -0
  298. package/dist/pine-core/{p-127a84bf.entry.js.map → p-2a4be282.entry.js.map} +1 -1
  299. package/dist/pine-core/{p-9e073662.entry.js → p-2c88b85e.entry.js} +2 -2
  300. package/dist/pine-core/{p-bd277581.entry.js → p-2dcd369d.entry.js} +2 -2
  301. package/dist/pine-core/{p-9d7f17a4.system.entry.js → p-30302dbb.system.entry.js} +2 -2
  302. package/dist/pine-core/{p-5552ca6b.system.entry.js → p-33fd214a.system.entry.js} +2 -2
  303. package/dist/pine-core/{p-8b997cb3.entry.js → p-360130c2.entry.js} +2 -2
  304. package/dist/pine-core/{p-0f037132.system.entry.js → p-3824d80d.system.entry.js} +2 -2
  305. package/dist/pine-core/{p-94fde072.system.entry.js → p-3c89502e.system.entry.js} +2 -2
  306. package/dist/pine-core/{p-1fd52c1b.system.entry.js → p-3d0f3dcb.system.entry.js} +2 -2
  307. package/dist/pine-core/p-3eae6f9f.system.entry.js +2 -0
  308. package/dist/pine-core/{p-617dc902.system.entry.js.map → p-3eae6f9f.system.entry.js.map} +1 -1
  309. package/dist/pine-core/{p-69221099.system.entry.js → p-3f4435b8.system.entry.js} +2 -2
  310. package/dist/pine-core/{p-13821696.entry.js → p-43565cf5.entry.js} +2 -2
  311. package/dist/pine-core/{p-d90f7fe4.entry.js → p-44318b5c.entry.js} +2 -2
  312. package/dist/pine-core/{p-e0862ab5.entry.js → p-4728c80a.entry.js} +2 -2
  313. package/dist/pine-core/{p-dd9888e9.entry.js → p-4a4048f3.entry.js} +2 -2
  314. package/dist/pine-core/p-4e79023c.system.entry.js +2 -0
  315. package/dist/pine-core/p-4e79023c.system.entry.js.map +1 -0
  316. package/dist/pine-core/{p-dc724dee.entry.js → p-4fc48330.entry.js} +2 -2
  317. package/dist/pine-core/{p-0561744f.entry.js → p-500ef8ee.entry.js} +2 -2
  318. package/dist/pine-core/{p-a76a454f.system.entry.js → p-528d50eb.system.entry.js} +2 -2
  319. package/dist/pine-core/p-56aedf71.entry.js +2 -0
  320. package/dist/pine-core/{p-61674647.entry.js.map → p-56aedf71.entry.js.map} +1 -1
  321. package/dist/pine-core/{p-128a483e.system.entry.js → p-58bd1590.system.entry.js} +2 -2
  322. package/dist/pine-core/p-5b521b20.entry.js +2 -0
  323. package/dist/pine-core/p-5c259f42.system.entry.js +4 -0
  324. package/dist/pine-core/{p-ea94b002.system.entry.js.map → p-5c259f42.system.entry.js.map} +1 -1
  325. package/dist/pine-core/{p-519d44b8.entry.js → p-5f9a6f53.entry.js} +2 -2
  326. package/dist/pine-core/{p-7d9f7018.entry.js → p-61bcaaee.entry.js} +2 -2
  327. package/dist/pine-core/p-621405fc.entry.js +2 -0
  328. package/dist/pine-core/{p-4beb8ae5.entry.js.map → p-621405fc.entry.js.map} +1 -1
  329. package/dist/pine-core/p-65224129.system.entry.js +2 -0
  330. package/dist/pine-core/{p-c746c9ad.system.entry.js.map → p-65224129.system.entry.js.map} +1 -1
  331. package/dist/pine-core/{p-0bf1fee1.entry.js → p-67a81e55.entry.js} +2 -2
  332. package/dist/pine-core/{p-c5dc1e2d.system.entry.js → p-6a20ba14.system.entry.js} +2 -2
  333. package/dist/pine-core/p-6af000e5.entry.js +2 -0
  334. package/dist/pine-core/{p-54e967ca.entry.js.map → p-6af000e5.entry.js.map} +1 -1
  335. package/dist/pine-core/{p-8731836c.entry.js → p-6c836757.entry.js} +2 -2
  336. package/dist/pine-core/p-6c9bb2a5.entry.js +2 -0
  337. package/dist/pine-core/{p-61c885c7.entry.js.map → p-6c9bb2a5.entry.js.map} +1 -1
  338. package/dist/pine-core/{p-42d83b1f.entry.js → p-6ca31ddd.entry.js} +2 -2
  339. package/dist/pine-core/p-6f4f62ff.system.entry.js +2 -0
  340. package/dist/pine-core/p-6f4f62ff.system.entry.js.map +1 -0
  341. package/dist/pine-core/{p-c299c019.system.entry.js → p-74486022.system.entry.js} +2 -2
  342. package/dist/pine-core/p-7456ae7a.system.entry.js +2 -0
  343. package/dist/pine-core/{p-00e487c4.system.entry.js.map → p-7456ae7a.system.entry.js.map} +1 -1
  344. package/dist/pine-core/{p-6ff1d23e.entry.js → p-77807b63.entry.js} +2 -2
  345. package/dist/pine-core/p-78184199.entry.js +2 -0
  346. package/dist/pine-core/p-78184199.entry.js.map +1 -0
  347. package/dist/pine-core/{p-5df670e9.entry.js → p-7ba75e19.entry.js} +3 -3
  348. package/dist/pine-core/p-7u7MeeeZ.system.js.map +1 -0
  349. package/dist/pine-core/{p-fd6e7155.entry.js → p-847ca369.entry.js} +2 -2
  350. package/dist/pine-core/p-859aa3b0.entry.js +2 -0
  351. package/dist/pine-core/{p-ec974e1d.entry.js.map → p-859aa3b0.entry.js.map} +1 -1
  352. package/dist/pine-core/{p-2c48e33c.entry.js → p-8c8048df.entry.js} +2 -2
  353. package/dist/pine-core/{p-6acc2e5b.system.entry.js → p-8dea1946.system.entry.js} +2 -2
  354. package/dist/pine-core/{p-Cng7Mtub.system.js.map → p-8nqjUIna.system.js.map} +1 -1
  355. package/dist/pine-core/{p-0d4b2bbc.system.entry.js → p-9120a7fa.system.entry.js} +2 -2
  356. package/dist/pine-core/{p-35d9e3c8.system.entry.js → p-97d5a937.system.entry.js} +2 -2
  357. package/dist/pine-core/{p-4993f30e.system.entry.js → p-97e0b205.system.entry.js} +2 -2
  358. package/dist/pine-core/{p-a713fedd.system.entry.js → p-98332835.system.entry.js} +2 -2
  359. package/dist/pine-core/{p-939ae09f.entry.js → p-99739465.entry.js} +2 -2
  360. package/dist/pine-core/{p-Djhe2zUv.system.js → p-9X_erY0S.system.js} +2 -2
  361. package/dist/pine-core/{p-Djhe2zUv.system.js.map → p-9X_erY0S.system.js.map} +1 -1
  362. package/dist/pine-core/{p-3524e30c.system.entry.js → p-9a2dc18d.system.entry.js} +2 -2
  363. package/dist/pine-core/{p-06fbdc35.entry.js → p-9e62532d.entry.js} +2 -2
  364. package/dist/pine-core/{p-1768ad5e.entry.js → p-9e98793e.entry.js} +2 -2
  365. package/dist/pine-core/p-B5hxTy5U.system.js.map +1 -0
  366. package/dist/pine-core/p-B8wXrRCn.system.js.map +1 -0
  367. package/dist/pine-core/p-BEk_6bpE.system.js.map +1 -0
  368. package/dist/pine-core/{p-CIRw0SFV.system.js.map → p-BHr70Hts.system.js.map} +1 -1
  369. package/dist/pine-core/{p-iOyU21aP.system.js.map → p-BILA6IDX.system.js.map} +1 -1
  370. package/dist/pine-core/{p-D504xCQQ.system.js.map → p-BR3EzrR2.system.js.map} +1 -1
  371. package/dist/pine-core/{p-VWcPIY1a.system.js.map → p-BWYstZfx.system.js.map} +1 -1
  372. package/dist/pine-core/{p-DWrLi0lj.system.js.map → p-B_ue56xA.system.js.map} +1 -1
  373. package/dist/pine-core/{p-xKyEDmi0.system.js.map → p-Bdrd1hDP.system.js.map} +1 -1
  374. package/dist/pine-core/{p-DUvF_h4G.system.js.map → p-BfwVCQ2C.system.js.map} +1 -1
  375. package/dist/pine-core/{p-BYHypIS4.system.js.map → p-BhXECqd_.system.js.map} +1 -1
  376. package/dist/pine-core/{p-CNgeZOJ8.system.js.map → p-Bq2VWG-F.system.js.map} +1 -1
  377. package/dist/pine-core/{p-B7_7oNQG.system.js.map → p-BtZYIh3H.system.js.map} +1 -1
  378. package/dist/pine-core/p-BzszOvm1.system.js.map +1 -0
  379. package/dist/pine-core/p-C0XRql_j.system.js.map +1 -0
  380. package/dist/pine-core/{p-M5aqIQje.system.js.map → p-C0r-Omcz.system.js.map} +1 -1
  381. package/dist/pine-core/p-C2Pw0xAP.system.js.map +1 -0
  382. package/dist/pine-core/p-C6LTEDPh.system.js.map +1 -0
  383. package/dist/pine-core/{p-BjaDq65J.system.js.map → p-C8wBjwhX.system.js.map} +1 -1
  384. package/dist/pine-core/{p-CeUxuw8r.system.js.map → p-CG-Uj3mN.system.js.map} +1 -1
  385. package/dist/pine-core/{p-D2CTdoEq.system.js.map → p-CIRsbQAW.system.js.map} +1 -1
  386. package/dist/pine-core/{p-B2EsHCoA.system.js.map → p-CKshb3YH.system.js.map} +1 -1
  387. package/dist/pine-core/{p-D4yK_qVB.system.js.map → p-CMbqUapr.system.js.map} +1 -1
  388. package/dist/pine-core/{p-BD9ysh2r.system.js.map → p-CQS3Y0nn.system.js.map} +1 -1
  389. package/dist/pine-core/p-CX0Csdth.system.js.map +1 -0
  390. package/dist/pine-core/{p-BwqSEhik.system.js.map → p-CZSA3A1S.system.js.map} +1 -1
  391. package/dist/pine-core/{p-BuXqrZlE.system.js.map → p-CbRVp4gv.system.js.map} +1 -1
  392. package/dist/pine-core/{p-C08fY97u.system.js.map → p-CfyFDUw5.system.js.map} +1 -1
  393. package/dist/pine-core/{p-BLil033h.system.js.map → p-CgPvrU-c.system.js.map} +1 -1
  394. package/dist/pine-core/{p-DFd5KJNr.system.js.map → p-CjuuQ5fk.system.js.map} +1 -1
  395. package/dist/pine-core/{p-Bm0i20zh.system.js.map → p-Ck9i0WVa.system.js.map} +1 -1
  396. package/dist/pine-core/{p-0mArGKTT.system.js.map → p-Cm5r7dPz.system.js.map} +1 -1
  397. package/dist/pine-core/{p-DxU4fApL.system.js.map → p-CtZbV7sl.system.js.map} +1 -1
  398. package/dist/pine-core/{p-DDgPxucg.system.js.map → p-CwlStDlm.system.js.map} +1 -1
  399. package/dist/pine-core/{p-B1bh2Wvv.system.js → p-CyJVqIlm.system.js} +3 -3
  400. package/dist/pine-core/p-CyJVqIlm.system.js.map +1 -0
  401. package/dist/pine-core/p-D2ZsBdFi.system.js.map +1 -0
  402. package/dist/pine-core/{p-1S7sNRrT.system.js.map → p-DSfc0hSW.system.js.map} +1 -1
  403. package/dist/pine-core/p-DUOWHRqL.system.js.map +1 -0
  404. package/dist/pine-core/{p-sB8ZB68H.system.js.map → p-DUaDwLU_.system.js.map} +1 -1
  405. package/dist/pine-core/p-DVra397g.system.js +2 -0
  406. package/dist/pine-core/p-DVra397g.system.js.map +1 -0
  407. package/dist/pine-core/p-D_X9pwRF.system.js.map +1 -0
  408. package/dist/pine-core/{p-CoxD4Fzc.system.js.map → p-Dn6xWpZX.system.js.map} +1 -1
  409. package/dist/pine-core/{p-4d6YziBa.system.js.map → p-Dt4eN_hu.system.js.map} +1 -1
  410. package/dist/pine-core/{p-MtzjfzAh.system.js.map → p-DtKEcQXo.system.js.map} +1 -1
  411. package/dist/pine-core/p-DtgUQhjl.js +2 -0
  412. package/dist/pine-core/p-DtgUQhjl.js.map +1 -0
  413. package/dist/pine-core/{p-IrhpBtZN.system.js.map → p-DuIwxDGo.system.js.map} +1 -1
  414. package/dist/pine-core/{p-5MZ-y5Ap.system.js.map → p-KgPSFwRc.system.js.map} +1 -1
  415. package/dist/pine-core/{p-CO9kz-Pi.js → p-QYCDCKN2.js} +3 -3
  416. package/dist/pine-core/{p-B1bh2Wvv.system.js.map → p-QYCDCKN2.js.map} +1 -1
  417. package/dist/pine-core/{p-05771ef2.system.entry.js → p-a6ab979f.system.entry.js} +2 -2
  418. package/dist/pine-core/p-a80f68ce.entry.js +2 -0
  419. package/dist/pine-core/p-a80f68ce.entry.js.map +1 -0
  420. package/dist/pine-core/{p-b272656d.system.entry.js → p-a81aa273.system.entry.js} +2 -2
  421. package/dist/pine-core/{p-63fd14b1.system.entry.js → p-a896db32.system.entry.js} +2 -2
  422. package/dist/pine-core/{p-779c4bd5.system.entry.js → p-ac2900e1.system.entry.js} +2 -2
  423. package/dist/pine-core/p-acf6592f.system.entry.js +2 -0
  424. package/dist/pine-core/p-acf6592f.system.entry.js.map +1 -0
  425. package/dist/pine-core/p-ad2bb5e4.entry.js +2 -0
  426. package/dist/pine-core/p-ad2bb5e4.entry.js.map +1 -0
  427. package/dist/pine-core/p-ae80a5cc.system.entry.js +2 -0
  428. package/dist/pine-core/{p-c7246fe4.system.entry.js.map → p-ae80a5cc.system.entry.js.map} +1 -1
  429. package/dist/pine-core/{p-fbd8a4ac.entry.js → p-b294a16b.entry.js} +2 -2
  430. package/dist/pine-core/{p-bb4bb3a7.entry.js → p-b37b3ad2.entry.js} +2 -2
  431. package/dist/pine-core/{p-c54334bf.entry.js → p-b42320fe.entry.js} +2 -2
  432. package/dist/pine-core/{p-c54334bf.entry.js.map → p-b42320fe.entry.js.map} +1 -1
  433. package/dist/pine-core/p-b4c51353.system.entry.js +2 -0
  434. package/dist/pine-core/{p-cb733c9c.system.entry.js.map → p-b4c51353.system.entry.js.map} +1 -1
  435. package/dist/pine-core/{p-253e2bfd.system.entry.js → p-b611b9ab.system.entry.js} +2 -2
  436. package/dist/pine-core/{p-4cf4558e.entry.js → p-b7342b09.entry.js} +2 -2
  437. package/dist/pine-core/p-c53bfe6e.entry.js +2 -0
  438. package/dist/pine-core/{p-be76de9e.entry.js.map → p-c53bfe6e.entry.js.map} +1 -1
  439. package/dist/pine-core/{p-90126a46.system.entry.js → p-c7259d80.system.entry.js} +3 -3
  440. package/dist/pine-core/p-cb9b6ccc.system.entry.js +2 -0
  441. package/dist/pine-core/p-cb9b6ccc.system.entry.js.map +1 -0
  442. package/dist/pine-core/{p-4710c59d.entry.js → p-cc7e0da3.entry.js} +2 -2
  443. package/dist/pine-core/p-cd6b266c.system.entry.js +2 -0
  444. package/dist/pine-core/{p-a12e38aa.system.entry.js.map → p-cd6b266c.system.entry.js.map} +1 -1
  445. package/dist/pine-core/{p-bf1ab568.system.entry.js → p-ce4de7f0.system.entry.js} +2 -2
  446. package/dist/pine-core/{p-1c26a838.system.entry.js → p-cfebee75.system.entry.js} +2 -2
  447. package/dist/pine-core/{p-c424a27a.system.entry.js → p-d5ba377c.system.entry.js} +2 -2
  448. package/dist/pine-core/{p-f924994c.entry.js → p-d83e411d.entry.js} +2 -2
  449. package/dist/pine-core/{p-c7cab4ca.entry.js → p-d96c3850.entry.js} +2 -2
  450. package/dist/pine-core/{p-b117b00a.system.entry.js → p-e2c42a2e.system.entry.js} +2 -2
  451. package/dist/pine-core/{p-f4662c9d.system.entry.js → p-e4f66d23.system.entry.js} +2 -2
  452. package/dist/pine-core/{p-2c2d2080.system.entry.js → p-e626cbd5.system.entry.js} +2 -2
  453. package/dist/pine-core/{p-2c7f3d5e.system.entry.js → p-e65b1e5f.system.entry.js} +2 -2
  454. package/dist/pine-core/{p-cea4bfaa.system.entry.js → p-e9e4e7f9.system.entry.js} +2 -2
  455. package/dist/pine-core/{p-5eb9a3e2.entry.js → p-ec7f210f.entry.js} +2 -2
  456. package/dist/pine-core/{p-13a814c0.system.entry.js → p-ef155f8e.system.entry.js} +2 -2
  457. package/dist/pine-core/{p-2ca648d8.system.entry.js → p-f9a46770.system.entry.js} +2 -2
  458. package/dist/pine-core/{p-b8ca7bca.entry.js → p-fa68509f.entry.js} +2 -2
  459. package/dist/pine-core/{p-f30bde36.system.entry.js → p-fc2789df.system.entry.js} +2 -2
  460. package/dist/pine-core/{p-9e8b71ed.system.entry.js → p-fcea314c.system.entry.js} +2 -2
  461. package/dist/pine-core/{p-A6hgZgB9.system.js.map → p-lXz5a0gw.system.js.map} +1 -1
  462. package/dist/pine-core/{p-BtXGBfVh.system.js.map → p-yb-SBJqk.system.js.map} +1 -1
  463. package/dist/pine-core/pds-alert.entry.esm.js.map +1 -1
  464. package/dist/pine-core/pds-button.entry.esm.js.map +1 -1
  465. package/dist/pine-core/pds-checkbox.entry.esm.js.map +1 -1
  466. package/dist/pine-core/pds-combobox.entry.esm.js.map +1 -1
  467. package/dist/pine-core/pds-filter.entry.esm.js.map +1 -1
  468. package/dist/pine-core/pds-input.entry.esm.js.map +1 -1
  469. package/dist/pine-core/pds-modal.entry.esm.js.map +1 -1
  470. package/dist/pine-core/pds-select.entry.esm.js.map +1 -1
  471. package/dist/pine-core/pds-switch.entry.esm.js.map +1 -1
  472. package/dist/pine-core/pds-table-cell.entry.esm.js.map +1 -1
  473. package/dist/pine-core/pds-table-head-cell.entry.esm.js.map +1 -1
  474. package/dist/pine-core/pds-table.entry.esm.js.map +1 -1
  475. package/dist/pine-core/pds-tooltip.entry.esm.js.map +1 -1
  476. package/dist/pine-core/pine-core.css +1 -1
  477. package/dist/pine-core/pine-core.esm.js +1 -1
  478. package/dist/pine-core/pine-core.js +1 -1
  479. package/dist/types/components/pds-table/pds-table.d.ts +1 -1
  480. package/dist/types/utils/scroll.d.ts +21 -0
  481. package/dist/types/utils/test/axe.d.ts +80 -0
  482. package/hydrate/index.js +123 -42
  483. package/hydrate/index.mjs +123 -42
  484. package/package.json +3 -2
  485. package/dist/cjs/index-Dlc5O3n_.js.map +0 -1
  486. package/dist/esm/index-CO9kz-Pi.js.map +0 -1
  487. package/dist/esm-es5/index-CO9kz-Pi.js.map +0 -1
  488. package/dist/pine-core/p--fC0IwVR.system.js.map +0 -1
  489. package/dist/pine-core/p-00e487c4.system.entry.js +0 -2
  490. package/dist/pine-core/p-0fefe6ef.entry.js +0 -2
  491. package/dist/pine-core/p-127a84bf.entry.js +0 -3
  492. package/dist/pine-core/p-31b51eae.entry.js +0 -2
  493. package/dist/pine-core/p-31b51eae.entry.js.map +0 -1
  494. package/dist/pine-core/p-4768b52b.system.entry.js +0 -2
  495. package/dist/pine-core/p-4768b52b.system.entry.js.map +0 -1
  496. package/dist/pine-core/p-4beb8ae5.entry.js +0 -2
  497. package/dist/pine-core/p-4d3122ff.system.entry.js +0 -2
  498. package/dist/pine-core/p-4d3122ff.system.entry.js.map +0 -1
  499. package/dist/pine-core/p-54e967ca.entry.js +0 -2
  500. package/dist/pine-core/p-61674647.entry.js +0 -2
  501. package/dist/pine-core/p-617dc902.system.entry.js +0 -2
  502. package/dist/pine-core/p-61c885c7.entry.js +0 -2
  503. package/dist/pine-core/p-673dd006.system.entry.js +0 -2
  504. package/dist/pine-core/p-673dd006.system.entry.js.map +0 -1
  505. package/dist/pine-core/p-7bc34bce.system.entry.js +0 -2
  506. package/dist/pine-core/p-88c2001b.entry.js +0 -2
  507. package/dist/pine-core/p-8a2433ba.entry.js +0 -2
  508. package/dist/pine-core/p-8a2433ba.entry.js.map +0 -1
  509. package/dist/pine-core/p-8d0c1f6d.entry.js +0 -2
  510. package/dist/pine-core/p-93b379c2.system.entry.js +0 -2
  511. package/dist/pine-core/p-AcWjVzMO.system.js.map +0 -1
  512. package/dist/pine-core/p-B8BcpYlQ.system.js.map +0 -1
  513. package/dist/pine-core/p-BFO0Qv1J.system.js.map +0 -1
  514. package/dist/pine-core/p-BHXH-Irt.system.js.map +0 -1
  515. package/dist/pine-core/p-BvEsTKJw.system.js.map +0 -1
  516. package/dist/pine-core/p-BvlpNhcl.system.js.map +0 -1
  517. package/dist/pine-core/p-C1AMzooU.system.js.map +0 -1
  518. package/dist/pine-core/p-C7zvuvWK.system.js.map +0 -1
  519. package/dist/pine-core/p-CHUAwdle.system.js.map +0 -1
  520. package/dist/pine-core/p-CO9kz-Pi.js.map +0 -1
  521. package/dist/pine-core/p-D0Q8TzYd.system.js.map +0 -1
  522. package/dist/pine-core/p-DMxjKSUq.system.js.map +0 -1
  523. package/dist/pine-core/p-NzmeWArw.system.js.map +0 -1
  524. package/dist/pine-core/p-UYm57tw3.system.js.map +0 -1
  525. package/dist/pine-core/p-a12e38aa.system.entry.js +0 -2
  526. package/dist/pine-core/p-b63c7247.entry.js +0 -2
  527. package/dist/pine-core/p-be76de9e.entry.js +0 -2
  528. package/dist/pine-core/p-c5f4d4c0.entry.js +0 -2
  529. package/dist/pine-core/p-c5f4d4c0.entry.js.map +0 -1
  530. package/dist/pine-core/p-c7246fe4.system.entry.js +0 -2
  531. package/dist/pine-core/p-c746c9ad.system.entry.js +0 -2
  532. package/dist/pine-core/p-cb733c9c.system.entry.js +0 -2
  533. package/dist/pine-core/p-da50a223.entry.js +0 -2
  534. package/dist/pine-core/p-da50a223.entry.js.map +0 -1
  535. package/dist/pine-core/p-ea94b002.system.entry.js +0 -4
  536. package/dist/pine-core/p-ebf96abc.system.entry.js +0 -2
  537. package/dist/pine-core/p-ebf96abc.system.entry.js.map +0 -1
  538. package/dist/pine-core/p-ec974e1d.entry.js +0 -2
  539. /package/dist/pine-core/{p-932f4860.entry.js.map → p-07a19657.entry.js.map} +0 -0
  540. /package/dist/pine-core/{p-26aa3195.entry.js.map → p-0d3a6abc.entry.js.map} +0 -0
  541. /package/dist/pine-core/{p-e7e166f2.entry.js.map → p-1256b83e.entry.js.map} +0 -0
  542. /package/dist/pine-core/{p-88c2001b.entry.js.map → p-1700705c.entry.js.map} +0 -0
  543. /package/dist/pine-core/{p-952b41e5.system.entry.js.map → p-1d7cbf49.system.entry.js.map} +0 -0
  544. /package/dist/pine-core/{p-205d8c56.entry.js.map → p-21a858a0.entry.js.map} +0 -0
  545. /package/dist/pine-core/{p-3c864e3d.entry.js.map → p-2335222d.entry.js.map} +0 -0
  546. /package/dist/pine-core/{p-24f9a03b.system.entry.js.map → p-2728bb30.system.entry.js.map} +0 -0
  547. /package/dist/pine-core/{p-9e073662.entry.js.map → p-2c88b85e.entry.js.map} +0 -0
  548. /package/dist/pine-core/{p-bd277581.entry.js.map → p-2dcd369d.entry.js.map} +0 -0
  549. /package/dist/pine-core/{p-9d7f17a4.system.entry.js.map → p-30302dbb.system.entry.js.map} +0 -0
  550. /package/dist/pine-core/{p-5552ca6b.system.entry.js.map → p-33fd214a.system.entry.js.map} +0 -0
  551. /package/dist/pine-core/{p-8b997cb3.entry.js.map → p-360130c2.entry.js.map} +0 -0
  552. /package/dist/pine-core/{p-0f037132.system.entry.js.map → p-3824d80d.system.entry.js.map} +0 -0
  553. /package/dist/pine-core/{p-94fde072.system.entry.js.map → p-3c89502e.system.entry.js.map} +0 -0
  554. /package/dist/pine-core/{p-1fd52c1b.system.entry.js.map → p-3d0f3dcb.system.entry.js.map} +0 -0
  555. /package/dist/pine-core/{p-69221099.system.entry.js.map → p-3f4435b8.system.entry.js.map} +0 -0
  556. /package/dist/pine-core/{p-13821696.entry.js.map → p-43565cf5.entry.js.map} +0 -0
  557. /package/dist/pine-core/{p-d90f7fe4.entry.js.map → p-44318b5c.entry.js.map} +0 -0
  558. /package/dist/pine-core/{p-e0862ab5.entry.js.map → p-4728c80a.entry.js.map} +0 -0
  559. /package/dist/pine-core/{p-dd9888e9.entry.js.map → p-4a4048f3.entry.js.map} +0 -0
  560. /package/dist/pine-core/{p-dc724dee.entry.js.map → p-4fc48330.entry.js.map} +0 -0
  561. /package/dist/pine-core/{p-0561744f.entry.js.map → p-500ef8ee.entry.js.map} +0 -0
  562. /package/dist/pine-core/{p-a76a454f.system.entry.js.map → p-528d50eb.system.entry.js.map} +0 -0
  563. /package/dist/pine-core/{p-128a483e.system.entry.js.map → p-58bd1590.system.entry.js.map} +0 -0
  564. /package/dist/pine-core/{p-0fefe6ef.entry.js.map → p-5b521b20.entry.js.map} +0 -0
  565. /package/dist/pine-core/{p-519d44b8.entry.js.map → p-5f9a6f53.entry.js.map} +0 -0
  566. /package/dist/pine-core/{p-7d9f7018.entry.js.map → p-61bcaaee.entry.js.map} +0 -0
  567. /package/dist/pine-core/{p-0bf1fee1.entry.js.map → p-67a81e55.entry.js.map} +0 -0
  568. /package/dist/pine-core/{p-c5dc1e2d.system.entry.js.map → p-6a20ba14.system.entry.js.map} +0 -0
  569. /package/dist/pine-core/{p-8731836c.entry.js.map → p-6c836757.entry.js.map} +0 -0
  570. /package/dist/pine-core/{p-42d83b1f.entry.js.map → p-6ca31ddd.entry.js.map} +0 -0
  571. /package/dist/pine-core/{p-c299c019.system.entry.js.map → p-74486022.system.entry.js.map} +0 -0
  572. /package/dist/pine-core/{p-6ff1d23e.entry.js.map → p-77807b63.entry.js.map} +0 -0
  573. /package/dist/pine-core/{p-5df670e9.entry.js.map → p-7ba75e19.entry.js.map} +0 -0
  574. /package/dist/pine-core/{p-fd6e7155.entry.js.map → p-847ca369.entry.js.map} +0 -0
  575. /package/dist/pine-core/{p-2c48e33c.entry.js.map → p-8c8048df.entry.js.map} +0 -0
  576. /package/dist/pine-core/{p-6acc2e5b.system.entry.js.map → p-8dea1946.system.entry.js.map} +0 -0
  577. /package/dist/pine-core/{p-0d4b2bbc.system.entry.js.map → p-9120a7fa.system.entry.js.map} +0 -0
  578. /package/dist/pine-core/{p-35d9e3c8.system.entry.js.map → p-97d5a937.system.entry.js.map} +0 -0
  579. /package/dist/pine-core/{p-4993f30e.system.entry.js.map → p-97e0b205.system.entry.js.map} +0 -0
  580. /package/dist/pine-core/{p-a713fedd.system.entry.js.map → p-98332835.system.entry.js.map} +0 -0
  581. /package/dist/pine-core/{p-939ae09f.entry.js.map → p-99739465.entry.js.map} +0 -0
  582. /package/dist/pine-core/{p-3524e30c.system.entry.js.map → p-9a2dc18d.system.entry.js.map} +0 -0
  583. /package/dist/pine-core/{p-06fbdc35.entry.js.map → p-9e62532d.entry.js.map} +0 -0
  584. /package/dist/pine-core/{p-1768ad5e.entry.js.map → p-9e98793e.entry.js.map} +0 -0
  585. /package/dist/pine-core/{p-05771ef2.system.entry.js.map → p-a6ab979f.system.entry.js.map} +0 -0
  586. /package/dist/pine-core/{p-b272656d.system.entry.js.map → p-a81aa273.system.entry.js.map} +0 -0
  587. /package/dist/pine-core/{p-63fd14b1.system.entry.js.map → p-a896db32.system.entry.js.map} +0 -0
  588. /package/dist/pine-core/{p-779c4bd5.system.entry.js.map → p-ac2900e1.system.entry.js.map} +0 -0
  589. /package/dist/pine-core/{p-fbd8a4ac.entry.js.map → p-b294a16b.entry.js.map} +0 -0
  590. /package/dist/pine-core/{p-bb4bb3a7.entry.js.map → p-b37b3ad2.entry.js.map} +0 -0
  591. /package/dist/pine-core/{p-253e2bfd.system.entry.js.map → p-b611b9ab.system.entry.js.map} +0 -0
  592. /package/dist/pine-core/{p-4cf4558e.entry.js.map → p-b7342b09.entry.js.map} +0 -0
  593. /package/dist/pine-core/{p-90126a46.system.entry.js.map → p-c7259d80.system.entry.js.map} +0 -0
  594. /package/dist/pine-core/{p-4710c59d.entry.js.map → p-cc7e0da3.entry.js.map} +0 -0
  595. /package/dist/pine-core/{p-bf1ab568.system.entry.js.map → p-ce4de7f0.system.entry.js.map} +0 -0
  596. /package/dist/pine-core/{p-1c26a838.system.entry.js.map → p-cfebee75.system.entry.js.map} +0 -0
  597. /package/dist/pine-core/{p-c424a27a.system.entry.js.map → p-d5ba377c.system.entry.js.map} +0 -0
  598. /package/dist/pine-core/{p-f924994c.entry.js.map → p-d83e411d.entry.js.map} +0 -0
  599. /package/dist/pine-core/{p-c7cab4ca.entry.js.map → p-d96c3850.entry.js.map} +0 -0
  600. /package/dist/pine-core/{p-b117b00a.system.entry.js.map → p-e2c42a2e.system.entry.js.map} +0 -0
  601. /package/dist/pine-core/{p-f4662c9d.system.entry.js.map → p-e4f66d23.system.entry.js.map} +0 -0
  602. /package/dist/pine-core/{p-2c2d2080.system.entry.js.map → p-e626cbd5.system.entry.js.map} +0 -0
  603. /package/dist/pine-core/{p-2c7f3d5e.system.entry.js.map → p-e65b1e5f.system.entry.js.map} +0 -0
  604. /package/dist/pine-core/{p-cea4bfaa.system.entry.js.map → p-e9e4e7f9.system.entry.js.map} +0 -0
  605. /package/dist/pine-core/{p-5eb9a3e2.entry.js.map → p-ec7f210f.entry.js.map} +0 -0
  606. /package/dist/pine-core/{p-13a814c0.system.entry.js.map → p-ef155f8e.system.entry.js.map} +0 -0
  607. /package/dist/pine-core/{p-2ca648d8.system.entry.js.map → p-f9a46770.system.entry.js.map} +0 -0
  608. /package/dist/pine-core/{p-b8ca7bca.entry.js.map → p-fa68509f.entry.js.map} +0 -0
  609. /package/dist/pine-core/{p-f30bde36.system.entry.js.map → p-fc2789df.system.entry.js.map} +0 -0
  610. /package/dist/pine-core/{p-9e8b71ed.system.entry.js.map → p-fcea314c.system.entry.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{h as handle}from"./index-D4ys0pep.js";var pdsSortableItemCss=".pds-sortable-item.sc-pds-sortable-item-h{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;padding-block:var(--pine-dimension-xs);padding-inline:var(--pine-dimension-md)}.pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__actions.sc-pds-sortable-item{-webkit-margin-start:auto;margin-inline-start:auto;-webkit-padding-start:var(--pine-dimension-md);padding-inline-start:var(--pine-dimension-md)}.pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{line-height:1;-webkit-margin-end:var(--pine-dimension-md);margin-inline-end:var(--pine-dimension-md)}.pds-sortable--bordered .pds-sortable-item.sc-pds-sortable-item-h:first-child{border-start-end-radius:calc(var(--pine-dimension-xs) * 1.25);border-start-start-radius:calc(var(--pine-dimension-xs) * 1.25)}.pds-sortable--bordered .pds-sortable-item.sc-pds-sortable-item-h:last-child{border-end-end-radius:calc(var(--pine-dimension-xs) * 1.25);border-end-start-radius:calc(var(--pine-dimension-xs) * 1.25)}.pds-sortable--divided .pds-sortable-item.sc-pds-sortable-item-h{-webkit-border-after:var(--pine-border);border-block-end:var(--pine-border)}.pds-sortable--divided .pds-sortable-item.sc-pds-sortable-item-h:last-child{-webkit-border-after:0;border-block-end:0}.pds-sortable--handle-type-row .pds-sortable-item.sc-pds-sortable-item-h{cursor:-webkit-grab;cursor:grab}.pds-sortable--handle-type-handle .pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{cursor:-webkit-grab;cursor:grab}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h{cursor:not-allowed;opacity:0.5}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{cursor:not-allowed}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h:hover{background-color:transparent}.pds-sortable:not(.pds-sortable--disabled) .pds-sortable-item.sc-pds-sortable-item-h:hover{background-color:var(--pine-color-background-container-hover)}.pds-sortable:not(.pds-sortable--disabled) .pds-sortable-item.sc-pds-sortable-item-h:hover pds-icon.sc-pds-sortable-item{color:var(--pine-color-info)}.pds-sortable-item--drag.sc-pds-sortable-item-h{background-color:var(--pine-color-background-container);border-radius:0;-webkit-box-shadow:var(--pine-box-shadow-400);box-shadow:var(--pine-box-shadow-400);opacity:1}.pds-sortable-item--ghost.sc-pds-sortable-item-h{background-color:var(--pine-color-background-container-hover);border-radius:0}";var PdsSortableItem=function(){function e(e){registerInstance(this,e);this.enableActions=false;this.showHandle=false}e.prototype.componentWillRender=function(){this.sortableRef=this.el.closest("pds-sortable");if(this.sortableRef&&this.sortableRef.handleType==="handle"){this.showHandle=true}};e.prototype.render=function(){return h(Host,{key:"631a0c1150226256cdb47d1a7bc6635144bb56d0",class:"pds-sortable-item",id:this.componentId},this.showHandle&&h("div",{key:"bdb6ff779a5d750b75d404521bc91cad02176ea8",class:"pds-sortable-item__handle"},h("pds-icon",{key:"144f4b6fe33a3a3a864ac48041fc93935fbf99c3",icon:handle})),h("slot",{key:"cdddce9c5fa3fde34481c41c46c5f6504e33a358"}),this.enableActions&&h("div",{key:"527e1d22f20223a850dbd956dea4db93878fd9f9",class:"pds-sortable-item__actions"},h("slot",{key:"85ea35dbfdf0393721471dd229e80e9e57f58230",name:"sortable-item-actions"})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();PdsSortableItem.style=pdsSortableItemCss;export{PdsSortableItem as pds_sortable_item};
1
+ import{r as registerInstance,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{h as handle}from"./index-D4ys0pep.js";var pdsSortableItemCss=".pds-sortable-item.sc-pds-sortable-item-h{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;padding-block:var(--pine-dimension-xs);padding-inline:var(--pine-dimension-md)}.pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__actions.sc-pds-sortable-item{-webkit-margin-start:auto;margin-inline-start:auto;-webkit-padding-start:var(--pine-dimension-md);padding-inline-start:var(--pine-dimension-md)}.pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{line-height:1;-webkit-margin-end:var(--pine-dimension-md);margin-inline-end:var(--pine-dimension-md)}.pds-sortable--bordered .pds-sortable-item.sc-pds-sortable-item-h:first-child{border-start-end-radius:calc(var(--pine-dimension-xs) * 1.25);border-start-start-radius:calc(var(--pine-dimension-xs) * 1.25)}.pds-sortable--bordered .pds-sortable-item.sc-pds-sortable-item-h:last-child{border-end-end-radius:calc(var(--pine-dimension-xs) * 1.25);border-end-start-radius:calc(var(--pine-dimension-xs) * 1.25)}.pds-sortable--divided .pds-sortable-item.sc-pds-sortable-item-h{-webkit-border-after:var(--pine-border);border-block-end:var(--pine-border)}.pds-sortable--divided .pds-sortable-item.sc-pds-sortable-item-h:last-child{-webkit-border-after:0;border-block-end:0}.pds-sortable--handle-type-row .pds-sortable-item.sc-pds-sortable-item-h{cursor:-webkit-grab;cursor:grab}.pds-sortable--handle-type-handle .pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{cursor:-webkit-grab;cursor:grab}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h{cursor:not-allowed;opacity:0.5}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h .pds-sortable-item__handle.sc-pds-sortable-item{cursor:not-allowed}.pds-sortable--disabled .pds-sortable-item.sc-pds-sortable-item-h:hover{background-color:transparent}.pds-sortable:not(.pds-sortable--disabled) .pds-sortable-item.sc-pds-sortable-item-h:hover{background-color:var(--pine-color-background-container-hover)}.pds-sortable:not(.pds-sortable--disabled) .pds-sortable-item.sc-pds-sortable-item-h:hover pds-icon.sc-pds-sortable-item{color:var(--pine-color-info)}.pds-sortable-item--drag.sc-pds-sortable-item-h{background-color:var(--pine-color-background-container);border-radius:0;-webkit-box-shadow:var(--pine-box-shadow-400);box-shadow:var(--pine-box-shadow-400);opacity:1}.pds-sortable-item--ghost.sc-pds-sortable-item-h{background-color:var(--pine-color-background-container-hover);border-radius:0}";var PdsSortableItem=function(){function e(e){registerInstance(this,e);this.enableActions=false;this.showHandle=false}e.prototype.componentWillRender=function(){this.sortableRef=this.el.closest("pds-sortable");if(this.sortableRef&&this.sortableRef.handleType==="handle"){this.showHandle=true}};e.prototype.render=function(){return h(Host,{key:"631a0c1150226256cdb47d1a7bc6635144bb56d0",class:"pds-sortable-item",id:this.componentId},this.showHandle&&h("div",{key:"bdb6ff779a5d750b75d404521bc91cad02176ea8",class:"pds-sortable-item__handle"},h("pds-icon",{key:"144f4b6fe33a3a3a864ac48041fc93935fbf99c3",icon:handle})),h("slot",{key:"cdddce9c5fa3fde34481c41c46c5f6504e33a358"}),this.enableActions&&h("div",{key:"527e1d22f20223a850dbd956dea4db93878fd9f9",class:"pds-sortable-item__actions"},h("slot",{key:"85ea35dbfdf0393721471dd229e80e9e57f58230",name:"sortable-item-actions"})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();PdsSortableItem.style=pdsSortableItemCss;export{PdsSortableItem as pds_sortable_item};
2
2
  //# sourceMappingURL=pds-sortable-item.entry.js.map
@@ -1,4 +1,4 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";
1
+ import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";
2
2
  /**!
3
3
  * Sortable 1.15.7
4
4
  * @author RubaXa <trash@rubaxa.org>
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{e as exposeTypeProperty,i as isSpecTest,m as messageId,a as assignDescription}from"./form-C3xDZBme.js";import{b as danger}from"./index-D4ys0pep.js";import{i as inheritAriaAttributes}from"./attributes-C0M1gTKv.js";var labelCss=":host{display:inline-block}:host([aria-disabled=true]) label{color:var(--pine-color-text-label-disabled)}:host([aria-readonly=true]) label{color:var(--pine-color-text-label-readonly)}label{color:var(--pine-color-text-label);font:var(--pine-typography-body-medium);letter-spacing:var(--pine-letter-spacing)}";var pdsSwitchCss=':host{--sizing-input-toggle-size:calc(var(--pine-dimension-250) - (var(--pine-dimension-025) * 2));--pine-dimension-025:2px;--spacing-message-inline:calc(var(--pine-dimension-450) + var(--pine-dimension-150));--number-transition-timing:0.15s ease-out;-ms-flex-align:start;align-items:flex-start;color:var(--pine-color-text);display:-ms-inline-flexbox;display:inline-flex;-ms-flex-flow:row wrap;flex-flow:row wrap;position:relative}:host(.pds-switch--error){color:var(--pine-color-text-message-danger)}:host(.pds-switch--error) input,:host(.pds-switch--error) input:checked,:host(.pds-switch--error) input:hover:not(:disabled):not(:checked){background-color:var(--pine-color-danger)}:host(.pds-switch--error) input:focus-visible:not(:disabled):not(:checked){outline-color:var(--pine-color-focus-ring-danger)}:host(.pds-switch--error) label{color:var(--color-text-error)}input{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:var(--pine-color-neutral);border:0;border-radius:var(--pine-dimension-sm);cursor:pointer;display:inline-block;-ms-flex-negative:0;flex-shrink:0;height:var(--pine-dimension-250);margin:0;padding:0;position:relative;-webkit-transition:var(--number-transition-timing);transition:var(--number-transition-timing);-webkit-transition-property:background, border, color;transition-property:background, border, color;width:var(--pine-dimension-450)}input::after{background:var(--pine-color-secondary);border-radius:var(--pine-border-radius-full);-webkit-box-shadow:var(--pine-box-shadow);box-shadow:var(--pine-box-shadow);content:"";display:block;height:var(--sizing-input-toggle-size);inset-block-start:50%;inset-inline-start:50%;position:absolute;-webkit-transform:translate3d(-100%, -50%, 0);transform:translate3d(-100%, -50%, 0);-webkit-transition:-webkit-transform var(--number-transition-timing);transition:-webkit-transform var(--number-transition-timing);transition:transform var(--number-transition-timing);transition:transform var(--number-transition-timing), -webkit-transform var(--number-transition-timing);width:var(--sizing-input-toggle-size)}label{display:-ms-flexbox;display:flex;gap:var(--pine-dimension-150)}.pds-switch--error label{color:inherit}.visually-hidden{border:0;clip:rect(0 0 0 0);-webkit-clip-path:polygon(0 0, 0 0, 0 0);clip-path:polygon(0 0, 0 0, 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.pds-switch__message{color:var(--pine-color-text-message);font:var(--pine-typography-body-sm-medium);-webkit-margin-before:var(--pine-dimension-xs);margin-block-start:var(--pine-dimension-xs);-webkit-margin-start:var(--spacing-message-inline);margin-inline-start:var(--spacing-message-inline);width:100%}.pds-switch__message+.pds-switch__message{-webkit-margin-before:var(--spacing-message-inline);margin-block-start:var(--spacing-message-inline)}.pds-switch__message--error{color:inherit;display:-ms-flexbox;display:flex;gap:var(--pine-dimension-2xs)}.pds-switch__message--error pds-icon{-webkit-margin-before:var(--pine-dimension-025);margin-block-start:var(--pine-dimension-025)}input:disabled{background-color:var(--pine-color-neutral-disabled);cursor:not-allowed}input:disabled~label{cursor:initial}input:disabled:hover::after{background-color:var(--pine-color-secondary)}input:disabled .pds-switch__message{color:initial}input:hover:not(:disabled){background-color:var(--pine-color-neutral-hover)}input:focus-visible:not(:disabled){outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}input:checked::after{-webkit-transform:translate3d(0, -50%, 0);transform:translate3d(0, -50%, 0)}input:checked:not(:disabled){background-color:currentColor;color:var(--pine-color-accent)}input:checked:not(:disabled):hover{border-color:currentColor;color:var(--pine-color-accent-hover)}';var PdsSwitch=function(){function i(i){var e=this;registerInstance(this,i);this.pdsSwitchChange=createEvent(this,"pdsSwitchChange");this.inheritedAttributes={};this._type="checkbox";this.checked=false;this.disabled=false;this.invalid=false;this.required=false;this.onSwitchUpdate=function(i){if(e.disabled)return;var t=i.target;e.checked=t.checked;e.updateFormValue();e.pdsSwitchChange.emit(i)};this.switchClassNames=function(){var i="pds-switch";if(e.invalid===true){i+=" pds-switch--error"}if(e.helperMessage!==undefined){i+=" pds-switch--message"}return i}}i.prototype.connectedCallback=function(){var i=this;if(this.el.attachInternals&&!this.internals){this.internals=this.el.attachInternals()}exposeTypeProperty(this.el,(function(){return i._type}))};i.prototype.componentDidLoad=function(){this.updateFormValue()};i.prototype.checkedChanged=function(){this.updateFormValue()};i.prototype.updateFormValue=function(){if(isSpecTest())return;if(this.internals&&this.internals.setFormValue){var i=this.checked?this.value||"on":null;this.internals.setFormValue(i)}if(this.internals&&this.internals.setValidity){this.internals.setValidity({})}};i.prototype.formStateRestoreCallback=function(i){if(i instanceof FormData){var e=this.value||"on";this.checked=i.get(this.name||this.componentId)===e}else if(typeof i==="string"){this.checked=i===(this.value||"on")}};i.prototype.componentWillLoad=function(){this.inheritedAttributes=Object.assign({},inheritAriaAttributes(this.el))};i.prototype.render=function(){return h(Host,{key:"96ee8c40c04e95b461ba2942b740503897a56b27",class:this.switchClassNames(),"aria-disabled":this.disabled?"true":null},h("label",{key:"441d6854f2c0b02ecf3d874198b3e0636d68c83b",htmlFor:this.componentId},h("input",Object.assign({key:"a26cd5fb407abc20da3e9dcfe0e52333690b783a","aria-describedby":assignDescription(this.componentId,this.invalid,this.errorMessage||this.helperMessage),"aria-invalid":this.invalid?"true":undefined,checked:this.checked,class:"pds-switch__input",disabled:this.disabled,id:this.componentId,name:this.name?this.name:this.componentId,onChange:this.onSwitchUpdate,required:this.required,type:"checkbox",value:this.value},this.inheritedAttributes)),h("span",{key:"5762c48f481c5c5d7b62e8dab40579a4e7ff290b",class:this.hideLabel?"visually-hidden":""},this.label)),this.helperMessage&&h("div",{key:"64c14b8833b45b4e9efb2f76faa47f0d24127c91",class:"pds-switch__message",id:messageId(this.componentId,"helper")},this.helperMessage),this.errorMessage&&h("div",{key:"cecd2e8da713e74b8e6b528b50733015f5d5069b",class:"pds-switch__message pds-switch__message--error",id:messageId(this.componentId,"error"),"aria-live":"assertive"},h("pds-icon",{key:"3a1c8f87b3909cdad1bc680931f5521ecb77acd6",icon:danger,size:"small"}),this.errorMessage))};Object.defineProperty(i,"formAssociated",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(i.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(i,"watchers",{get:function(){return{checked:["checkedChanged"]}},enumerable:false,configurable:true});return i}();PdsSwitch.style=labelCss+pdsSwitchCss;export{PdsSwitch as pds_switch};
1
+ import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{e as exposeTypeProperty,i as isSpecTest,m as messageId,a as assignDescription}from"./form-C3xDZBme.js";import{b as danger}from"./index-D4ys0pep.js";import{i as inheritAriaAttributes}from"./attributes-C0M1gTKv.js";var labelCss=":host{display:inline-block}:host([aria-disabled=true]) label{color:var(--pine-color-text-label-disabled)}:host([aria-readonly=true]) label{color:var(--pine-color-text-label-readonly)}label{color:var(--pine-color-text-label);font:var(--pine-typography-body-medium);letter-spacing:var(--pine-letter-spacing)}";var pdsSwitchCss=':host{--sizing-input-toggle-size:calc(var(--pine-dimension-250) - (var(--pine-dimension-025) * 2));--pine-dimension-025:2px;--spacing-message-inline:calc(var(--pine-dimension-450) + var(--pine-dimension-150));--number-transition-timing:0.15s ease-out;-ms-flex-align:start;align-items:flex-start;color:var(--pine-color-text);display:-ms-inline-flexbox;display:inline-flex;-ms-flex-flow:row wrap;flex-flow:row wrap;position:relative}:host(.pds-switch--error){color:var(--pine-color-text-message-danger)}:host(.pds-switch--error) input,:host(.pds-switch--error) input:checked,:host(.pds-switch--error) input:hover:not(:disabled):not(:checked){background-color:var(--pine-color-danger)}:host(.pds-switch--error) input:focus-visible:not(:disabled):not(:checked){outline-color:var(--pine-color-focus-ring-danger)}:host(.pds-switch--error) label{color:var(--color-text-error)}input{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:var(--pine-color-neutral);border:0;border-radius:var(--pine-dimension-sm);cursor:pointer;display:inline-block;-ms-flex-negative:0;flex-shrink:0;height:var(--pine-dimension-250);margin:0;padding:0;position:relative;-webkit-transition:var(--number-transition-timing);transition:var(--number-transition-timing);-webkit-transition-property:background, border, color;transition-property:background, border, color;width:var(--pine-dimension-450)}input::after{background:var(--pine-color-secondary);border-radius:var(--pine-border-radius-full);-webkit-box-shadow:var(--pine-box-shadow);box-shadow:var(--pine-box-shadow);content:"";display:block;height:var(--sizing-input-toggle-size);inset-block-start:50%;inset-inline-start:var(--pine-dimension-025);position:absolute;-webkit-transform:translateY(-50%);transform:translateY(-50%);-webkit-transition:inset-inline-start var(--number-transition-timing);transition:inset-inline-start var(--number-transition-timing);width:var(--sizing-input-toggle-size)}label{display:-ms-flexbox;display:flex;gap:var(--pine-dimension-150)}.pds-switch--error label{color:inherit}.visually-hidden{border:0;clip:rect(0 0 0 0);-webkit-clip-path:polygon(0 0, 0 0, 0 0);clip-path:polygon(0 0, 0 0, 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.pds-switch__message{color:var(--pine-color-text-message);font:var(--pine-typography-body-sm-medium);-webkit-margin-before:var(--pine-dimension-xs);margin-block-start:var(--pine-dimension-xs);-webkit-margin-start:var(--spacing-message-inline);margin-inline-start:var(--spacing-message-inline);width:100%}.pds-switch__message+.pds-switch__message{-webkit-margin-before:var(--spacing-message-inline);margin-block-start:var(--spacing-message-inline)}.pds-switch__message--error{color:inherit;display:-ms-flexbox;display:flex;gap:var(--pine-dimension-2xs)}.pds-switch__message--error pds-icon{-webkit-margin-before:var(--pine-dimension-025);margin-block-start:var(--pine-dimension-025)}input:disabled{background-color:var(--pine-color-neutral-disabled);cursor:not-allowed}input:disabled~label{cursor:initial}input:disabled:hover::after{background-color:var(--pine-color-secondary)}input:disabled .pds-switch__message{color:initial}input:hover:not(:disabled){background-color:var(--pine-color-neutral-hover)}input:focus-visible:not(:disabled){outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}input:checked::after{inset-inline-start:calc(100% - var(--sizing-input-toggle-size) - var(--pine-dimension-025))}input:checked:not(:disabled){background-color:currentColor;color:var(--pine-color-accent)}input:checked:not(:disabled):hover{border-color:currentColor;color:var(--pine-color-accent-hover)}';var PdsSwitch=function(){function i(i){var e=this;registerInstance(this,i);this.pdsSwitchChange=createEvent(this,"pdsSwitchChange");this.inheritedAttributes={};this._type="checkbox";this.checked=false;this.disabled=false;this.invalid=false;this.required=false;this.onSwitchUpdate=function(i){if(e.disabled)return;var s=i.target;e.checked=s.checked;e.updateFormValue();e.pdsSwitchChange.emit(i)};this.switchClassNames=function(){var i="pds-switch";if(e.invalid===true){i+=" pds-switch--error"}if(e.helperMessage!==undefined){i+=" pds-switch--message"}return i}}i.prototype.connectedCallback=function(){var i=this;if(this.el.attachInternals&&!this.internals){this.internals=this.el.attachInternals()}exposeTypeProperty(this.el,(function(){return i._type}))};i.prototype.componentDidLoad=function(){this.updateFormValue()};i.prototype.checkedChanged=function(){this.updateFormValue()};i.prototype.updateFormValue=function(){if(isSpecTest())return;if(this.internals&&this.internals.setFormValue){var i=this.checked?this.value||"on":null;this.internals.setFormValue(i)}if(this.internals&&this.internals.setValidity){this.internals.setValidity({})}};i.prototype.formStateRestoreCallback=function(i){if(i instanceof FormData){var e=this.value||"on";this.checked=i.get(this.name||this.componentId)===e}else if(typeof i==="string"){this.checked=i===(this.value||"on")}};i.prototype.componentWillLoad=function(){this.inheritedAttributes=Object.assign({},inheritAriaAttributes(this.el))};i.prototype.render=function(){return h(Host,{key:"96ee8c40c04e95b461ba2942b740503897a56b27",class:this.switchClassNames(),"aria-disabled":this.disabled?"true":null},h("label",{key:"441d6854f2c0b02ecf3d874198b3e0636d68c83b",htmlFor:this.componentId},h("input",Object.assign({key:"a26cd5fb407abc20da3e9dcfe0e52333690b783a","aria-describedby":assignDescription(this.componentId,this.invalid,this.errorMessage||this.helperMessage),"aria-invalid":this.invalid?"true":undefined,checked:this.checked,class:"pds-switch__input",disabled:this.disabled,id:this.componentId,name:this.name?this.name:this.componentId,onChange:this.onSwitchUpdate,required:this.required,type:"checkbox",value:this.value},this.inheritedAttributes)),h("span",{key:"5762c48f481c5c5d7b62e8dab40579a4e7ff290b",class:this.hideLabel?"visually-hidden":""},this.label)),this.helperMessage&&h("div",{key:"64c14b8833b45b4e9efb2f76faa47f0d24127c91",class:"pds-switch__message",id:messageId(this.componentId,"helper")},this.helperMessage),this.errorMessage&&h("div",{key:"cecd2e8da713e74b8e6b528b50733015f5d5069b",class:"pds-switch__message pds-switch__message--error",id:messageId(this.componentId,"error"),"aria-live":"assertive"},h("pds-icon",{key:"3a1c8f87b3909cdad1bc680931f5521ecb77acd6",icon:danger,size:"small"}),this.errorMessage))};Object.defineProperty(i,"formAssociated",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(i.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(i,"watchers",{get:function(){return{checked:["checkedChanged"]}},enumerable:false,configurable:true});return i}();PdsSwitch.style=labelCss+pdsSwitchCss;export{PdsSwitch as pds_switch};
2
2
  //# sourceMappingURL=pds-switch.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pds-switch.entry.js","sources":["src/global/styles/utils/label.scss?tag=pds-switch&encapsulation=shadow","src/components/pds-switch/pds-switch.scss?tag=pds-switch&encapsulation=shadow","src/components/pds-switch/pds-switch.tsx"],"sourcesContent":[":host {\n display: inline-block;\n}\n\n:host([aria-disabled=\"true\"]) label {\n color: var(--pine-color-text-label-disabled);\n}\n\n:host([aria-readonly=\"true\"]) {\n label {\n color: var(--pine-color-text-label-readonly);\n }\n}\n\nlabel {\n color: var(--pine-color-text-label);\n font: var(--pine-typography-body-medium);\n letter-spacing: var(--pine-letter-spacing);\n}\n",":host {\n// Need discussions\n --sizing-input-toggle-size: calc(var(--pine-dimension-250) - (var(--pine-dimension-025) * 2));\n --pine-dimension-025: 2px;\n --spacing-message-inline: calc(var(--pine-dimension-450) + var(--pine-dimension-150));\n --number-transition-timing: 0.15s ease-out;\n\n align-items: flex-start;\n color: var(--pine-color-text);\n display: inline-flex;\n flex-flow: row wrap;\n position: relative;\n}\n\n:host(.pds-switch--error) {\n color: var(--pine-color-text-message-danger);\n\n input,\n input:checked,\n input:hover:not(:disabled):not(:checked) {\n background-color: var(--pine-color-danger);\n }\n\n input:focus-visible:not(:disabled):not(:checked) {\n outline-color: var(--pine-color-focus-ring-danger);\n }\n\n label {\n color: var(--color-text-error);\n }\n}\n\n// switch container\ninput {\n appearance: none;\n background: var(--pine-color-neutral);\n border: 0;\n border-radius: var(--pine-dimension-sm);\n cursor: pointer;\n display: inline-block;\n flex-shrink: 0;\n height: var(--pine-dimension-250);\n margin: 0;\n padding: 0;\n position: relative;\n transition: var(--number-transition-timing);\n transition-property: background, border, color;\n width: var(--pine-dimension-450);\n\n // switch toggle\n &::after {\n background: var(--pine-color-secondary);\n border-radius: var(--pine-border-radius-full);\n box-shadow: var(--pine-box-shadow);\n content: \"\";\n display: block;\n height: var(--sizing-input-toggle-size);\n inset-block-start: 50%;\n inset-inline-start: 50%;\n position: absolute;\n transform: translate3d(-100%, -50%, 0);\n transition: transform var(--number-transition-timing);\n width: var(--sizing-input-toggle-size);\n }\n}\n\nlabel {\n display: flex;\n gap: var(--pine-dimension-150);\n\n .pds-switch--error & {\n color: inherit;\n }\n}\n\n.visually-hidden {\n border: 0;\n clip: rect(0 0 0 0);\n clip-path: polygon(0 0, 0 0, 0 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n white-space: nowrap;\n width: 1px;\n}\n\n// Help and error messages\n.pds-switch__message {\n color: var(--pine-color-text-message);\n font: var(--pine-typography-body-sm-medium);\n margin-block-start: var(--pine-dimension-xs);\n margin-inline-start: var(--spacing-message-inline);\n width: 100%;\n\n + .pds-switch__message {\n margin-block-start: var(--spacing-message-inline);\n }\n}\n\n.pds-switch__message--error {\n color: inherit;\n display: flex;\n gap: var(--pine-dimension-2xs);\n\n pds-icon {\n margin-block-start: var(--pine-dimension-025);\n }\n}\n\n// Disabled state\ninput:disabled {\n background-color: var(--pine-color-neutral-disabled);\n cursor: not-allowed;\n\n ~ label {\n cursor: initial;\n }\n\n &:hover::after {\n background-color: var(--pine-color-secondary);\n }\n\n .pds-switch__message {\n color: initial;\n }\n}\n\n// Hover state\ninput:hover:not(:disabled) {\n background-color: var(--pine-color-neutral-hover);\n}\n\n // Focus state\ninput:focus-visible:not(:disabled) {\n outline: var(--pine-outline-focus);\n outline-offset: var(--pine-border-width);\n}\n\n// 'Checked' state\n// switch toggle\ninput:checked::after {\n transform: translate3d(0, -50%, 0);\n}\n\n// switch container\ninput:checked:not(:disabled) {\n background-color: currentColor;\n color: var(--pine-color-accent);\n\n &:hover {\n border-color: currentColor;\n color: var(--pine-color-accent-hover);\n }\n}\n","import { Component, Element, Event, EventEmitter, Host, h, Prop, Watch } from '@stencil/core';\nimport { assignDescription, isSpecTest, messageId, exposeTypeProperty } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\nimport { inheritAriaAttributes } from '@utils/attributes';\nimport type { Attributes } from '@utils/attributes';\n\n@Component({\n tag: 'pds-switch',\n styleUrls: ['../../global/styles/utils/label.scss', 'pds-switch.scss'],\n shadow: true,\n formAssociated: true,\n})\nexport class PdsSwitch {\n private inheritedAttributes: Attributes = {};\n private internals?: ElementInternals;\n private readonly _type = 'checkbox' as const;\n\n @Element() el: HTMLPdsSwitchElement;\n\n /**\n * A unique identifier used for the underlying component `id` attribute and the label `for` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Determines the input 'checked' state.\n */\n @Prop({ mutable: true }) checked = false;\n\n /**\n * Determines the input 'disabled' state, preventing user interaction.\n */\n @Prop() disabled? = false;\n\n /**\n * Displays message text describing an invalid state.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Visually hides the label text for instances where only the switch should be displayed. Label remains accessible to assistive technology such as screen readers.\n */\n @Prop() hideLabel: boolean;\n\n /**\n * Displays help text for additional description of an input.\n */\n @Prop() helperMessage: string;\n\n /**\n * Determines the input 'invalid' state, signifying an error is present.\n */\n @Prop() invalid? = false;\n\n /**\n * Displays text to describe the input.\n */\n @Prop() label!: string;\n\n /**\n * Identifies form data and unifies a group of radio inputs for toggling a single property/value.\n */\n @Prop() name: string;\n\n /**\n * Determines the 'required' state of the input.\n */\n @Prop() required? = false;\n\n /**\n * Provides input with a string submitted in form data.\n */\n @Prop() value: string;\n\n\n /**\n * Emits an event on input change.\n */\n @Event() pdsSwitchChange: EventEmitter<InputEvent>;\n\n private onSwitchUpdate = (e: Event) => {\n if (this.disabled) return;\n\n const input = e.target as HTMLInputElement;\n this.checked = input.checked;\n\n this.updateFormValue();\n\n this.pdsSwitchChange.emit(e as InputEvent);\n };\n\n private switchClassNames = () => {\n let switchClasses = `pds-switch`;\n\n if (this.invalid === true) {\n switchClasses += \" pds-switch--error\";\n }\n if (this.helperMessage !== undefined) {\n switchClasses += \" pds-switch--message\";\n }\n return switchClasses;\n };\n\n connectedCallback() {\n // Initialize ElementInternals for form association (only once per element instance)\n if (this.el.attachInternals && !this.internals) {\n this.internals = this.el.attachInternals();\n }\n\n // Expose type property on the element instance to match native form element behavior\n exposeTypeProperty(this.el, () => this._type);\n }\n\n componentDidLoad() {\n this.updateFormValue();\n }\n\n @Watch('checked')\n checkedChanged() {\n this.updateFormValue();\n }\n\n private updateFormValue() {\n if (isSpecTest()) return;\n\n if (this.internals && this.internals.setFormValue) {\n // For switches, only send the value when checked, otherwise send null\n const formValue = this.checked ? (this.value || 'on') : null;\n this.internals.setFormValue(formValue);\n }\n\n if (this.internals && this.internals.setValidity) {\n this.internals.setValidity({});\n }\n }\n\n formStateRestoreCallback(state: string | FormData | null) {\n if (state instanceof FormData) {\n // For switches, restore if the value exists in FormData\n const value = this.value || 'on';\n this.checked = state.get(this.name || this.componentId) === value;\n } else if (typeof state === 'string') {\n // Restore from string state\n this.checked = state === (this.value || 'on');\n }\n }\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n }\n }\n\n render() {\n return (\n <Host class={this.switchClassNames()} aria-disabled={this.disabled ? 'true' : null}>\n <label htmlFor={this.componentId}>\n <input\n aria-describedby={assignDescription(this.componentId, this.invalid, this.errorMessage || this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n checked={this.checked}\n class=\"pds-switch__input\"\n disabled={this.disabled}\n id={this.componentId}\n name={this.name ? this.name : this.componentId}\n onChange={this.onSwitchUpdate}\n required={this.required}\n type=\"checkbox\"\n value={this.value}\n {...this.inheritedAttributes}\n />\n <span class={this.hideLabel ? 'visually-hidden' : ''}>\n {this.label}\n </span>\n </label>\n {this.helperMessage &&\n <div\n class={`pds-switch__message`}\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </div>\n }\n {this.errorMessage &&\n <div\n class={`pds-switch__message pds-switch__message--error`}\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </div>\n }\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,QAAQ,GAAG,oTAAoT;;ACArU,MAAM,YAAY,GAAG,4uHAA4uH;;MCapvH,SAAS,GAAA,MAAA;AANtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAOU,QAAA,IAAmB,CAAA,mBAAA,GAAe,EAAE;AAE3B,QAAA,IAAK,CAAA,KAAA,GAAG,UAAmB;AAS5C;;AAEG;AACsB,QAAA,IAAO,CAAA,OAAA,GAAG,KAAK;AAExC;;AAEG;AACK,QAAA,IAAQ,CAAA,QAAA,GAAI,KAAK;AAiBzB;;AAEG;AACK,QAAA,IAAO,CAAA,OAAA,GAAI,KAAK;AAYxB;;AAEG;AACK,QAAA,IAAQ,CAAA,QAAA,GAAI,KAAK;AAajB,QAAA,IAAA,CAAA,cAAc,GAAG,CAAC,CAAQ,KAAI;YACpC,IAAI,IAAI,CAAC,QAAQ;gBAAE;AAEnB,YAAA,MAAM,KAAK,GAAG,CAAC,CAAC,MAA0B;AAC1C,YAAA,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC,OAAO;YAE5B,IAAI,CAAC,eAAe,EAAE;AAEtB,YAAA,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,CAAe,CAAC;AAC5C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AAI,CAAC,QAAQ,EACvB,IAAI,EAAC,UAAU,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACb,EAAA,IAAI,CAAC,mBAAmB,CAC5B,CAAA,EACF,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,KAAK,EAAE,IAAI,CAAC,SAAS,GAAG,iBAAiB,GAAG,EAAE,EAAA,EACjD,IAAI,CAAC,KAAK,CACN,CACD,EACP,IAAI,CAAC,aAAa;AACjB,YAAA,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAE,CAAqB,mBAAA,CAAA,EAC5B,EAAE,EAAE,SAAS,CAAC,IAAI,CAAC,WAAW,EAAE,QAAQ,CAAC,IAExC,IAAI,CAAC,aAAa,CACf,EAEP,IAAI,CAAC,YAAY;YAChB,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAE,CAAgD,8CAAA,CAAA,EACvD,EAAE,EAAE,SAAS,CAAC,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC,eAC9B,WAAW,EAAA,EAErB,CAAA,CAAA,UAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAU,IAAI,EAAE,MAAM,EAAE,IAAI,EAAC,OAAO,EAAG,CAAA,EACtC,IAAI,CAAC,YAAY,CACd,CAEH;;;;;;;;;;;;"}
1
+ {"version":3,"file":"pds-switch.entry.js","sources":["src/global/styles/utils/label.scss?tag=pds-switch&encapsulation=shadow","src/components/pds-switch/pds-switch.scss?tag=pds-switch&encapsulation=shadow","src/components/pds-switch/pds-switch.tsx"],"sourcesContent":[":host {\n display: inline-block;\n}\n\n:host([aria-disabled=\"true\"]) label {\n color: var(--pine-color-text-label-disabled);\n}\n\n:host([aria-readonly=\"true\"]) {\n label {\n color: var(--pine-color-text-label-readonly);\n }\n}\n\nlabel {\n color: var(--pine-color-text-label);\n font: var(--pine-typography-body-medium);\n letter-spacing: var(--pine-letter-spacing);\n}\n",":host {\n// Need discussions\n --sizing-input-toggle-size: calc(var(--pine-dimension-250) - (var(--pine-dimension-025) * 2));\n --pine-dimension-025: 2px;\n --spacing-message-inline: calc(var(--pine-dimension-450) + var(--pine-dimension-150));\n --number-transition-timing: 0.15s ease-out;\n\n align-items: flex-start;\n color: var(--pine-color-text);\n display: inline-flex;\n flex-flow: row wrap;\n position: relative;\n}\n\n:host(.pds-switch--error) {\n color: var(--pine-color-text-message-danger);\n\n input,\n input:checked,\n input:hover:not(:disabled):not(:checked) {\n background-color: var(--pine-color-danger);\n }\n\n input:focus-visible:not(:disabled):not(:checked) {\n outline-color: var(--pine-color-focus-ring-danger);\n }\n\n label {\n color: var(--color-text-error);\n }\n}\n\n// switch container\ninput {\n appearance: none;\n background: var(--pine-color-neutral);\n border: 0;\n border-radius: var(--pine-dimension-sm);\n cursor: pointer;\n display: inline-block;\n flex-shrink: 0;\n height: var(--pine-dimension-250);\n margin: 0;\n padding: 0;\n position: relative;\n transition: var(--number-transition-timing);\n transition-property: background, border, color;\n width: var(--pine-dimension-450);\n\n // switch toggle\n &::after {\n background: var(--pine-color-secondary);\n border-radius: var(--pine-border-radius-full);\n box-shadow: var(--pine-box-shadow);\n content: \"\";\n display: block;\n height: var(--sizing-input-toggle-size);\n inset-block-start: 50%;\n inset-inline-start: var(--pine-dimension-025);\n position: absolute;\n transform: translateY(-50%);\n transition: inset-inline-start var(--number-transition-timing);\n width: var(--sizing-input-toggle-size);\n }\n}\n\nlabel {\n display: flex;\n gap: var(--pine-dimension-150);\n\n .pds-switch--error & {\n color: inherit;\n }\n}\n\n.visually-hidden {\n border: 0;\n clip: rect(0 0 0 0);\n clip-path: polygon(0 0, 0 0, 0 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n white-space: nowrap;\n width: 1px;\n}\n\n// Help and error messages\n.pds-switch__message {\n color: var(--pine-color-text-message);\n font: var(--pine-typography-body-sm-medium);\n margin-block-start: var(--pine-dimension-xs);\n margin-inline-start: var(--spacing-message-inline);\n width: 100%;\n\n + .pds-switch__message {\n margin-block-start: var(--spacing-message-inline);\n }\n}\n\n.pds-switch__message--error {\n color: inherit;\n display: flex;\n gap: var(--pine-dimension-2xs);\n\n pds-icon {\n margin-block-start: var(--pine-dimension-025);\n }\n}\n\n// Disabled state\ninput:disabled {\n background-color: var(--pine-color-neutral-disabled);\n cursor: not-allowed;\n\n ~ label {\n cursor: initial;\n }\n\n &:hover::after {\n background-color: var(--pine-color-secondary);\n }\n\n .pds-switch__message {\n color: initial;\n }\n}\n\n// Hover state\ninput:hover:not(:disabled) {\n background-color: var(--pine-color-neutral-hover);\n}\n\n // Focus state\ninput:focus-visible:not(:disabled) {\n outline: var(--pine-outline-focus);\n outline-offset: var(--pine-border-width);\n}\n\n// 'Checked' state\n// switch toggle\ninput:checked::after {\n inset-inline-start: calc(100% - var(--sizing-input-toggle-size) - var(--pine-dimension-025));\n}\n\n// switch container\ninput:checked:not(:disabled) {\n background-color: currentColor;\n color: var(--pine-color-accent);\n\n &:hover {\n border-color: currentColor;\n color: var(--pine-color-accent-hover);\n }\n}\n","import { Component, Element, Event, EventEmitter, Host, h, Prop, Watch } from '@stencil/core';\nimport { assignDescription, isSpecTest, messageId, exposeTypeProperty } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\nimport { inheritAriaAttributes } from '@utils/attributes';\nimport type { Attributes } from '@utils/attributes';\n\n@Component({\n tag: 'pds-switch',\n styleUrls: ['../../global/styles/utils/label.scss', 'pds-switch.scss'],\n shadow: true,\n formAssociated: true,\n})\nexport class PdsSwitch {\n private inheritedAttributes: Attributes = {};\n private internals?: ElementInternals;\n private readonly _type = 'checkbox' as const;\n\n @Element() el: HTMLPdsSwitchElement;\n\n /**\n * A unique identifier used for the underlying component `id` attribute and the label `for` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Determines the input 'checked' state.\n */\n @Prop({ mutable: true }) checked = false;\n\n /**\n * Determines the input 'disabled' state, preventing user interaction.\n */\n @Prop() disabled? = false;\n\n /**\n * Displays message text describing an invalid state.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Visually hides the label text for instances where only the switch should be displayed. Label remains accessible to assistive technology such as screen readers.\n */\n @Prop() hideLabel: boolean;\n\n /**\n * Displays help text for additional description of an input.\n */\n @Prop() helperMessage: string;\n\n /**\n * Determines the input 'invalid' state, signifying an error is present.\n */\n @Prop() invalid? = false;\n\n /**\n * Displays text to describe the input.\n */\n @Prop() label!: string;\n\n /**\n * Identifies form data and unifies a group of radio inputs for toggling a single property/value.\n */\n @Prop() name: string;\n\n /**\n * Determines the 'required' state of the input.\n */\n @Prop() required? = false;\n\n /**\n * Provides input with a string submitted in form data.\n */\n @Prop() value: string;\n\n\n /**\n * Emits an event on input change.\n */\n @Event() pdsSwitchChange: EventEmitter<InputEvent>;\n\n private onSwitchUpdate = (e: Event) => {\n if (this.disabled) return;\n\n const input = e.target as HTMLInputElement;\n this.checked = input.checked;\n\n this.updateFormValue();\n\n this.pdsSwitchChange.emit(e as InputEvent);\n };\n\n private switchClassNames = () => {\n let switchClasses = `pds-switch`;\n\n if (this.invalid === true) {\n switchClasses += \" pds-switch--error\";\n }\n if (this.helperMessage !== undefined) {\n switchClasses += \" pds-switch--message\";\n }\n return switchClasses;\n };\n\n connectedCallback() {\n // Initialize ElementInternals for form association (only once per element instance)\n if (this.el.attachInternals && !this.internals) {\n this.internals = this.el.attachInternals();\n }\n\n // Expose type property on the element instance to match native form element behavior\n exposeTypeProperty(this.el, () => this._type);\n }\n\n componentDidLoad() {\n this.updateFormValue();\n }\n\n @Watch('checked')\n checkedChanged() {\n this.updateFormValue();\n }\n\n private updateFormValue() {\n if (isSpecTest()) return;\n\n if (this.internals && this.internals.setFormValue) {\n // For switches, only send the value when checked, otherwise send null\n const formValue = this.checked ? (this.value || 'on') : null;\n this.internals.setFormValue(formValue);\n }\n\n if (this.internals && this.internals.setValidity) {\n this.internals.setValidity({});\n }\n }\n\n formStateRestoreCallback(state: string | FormData | null) {\n if (state instanceof FormData) {\n // For switches, restore if the value exists in FormData\n const value = this.value || 'on';\n this.checked = state.get(this.name || this.componentId) === value;\n } else if (typeof state === 'string') {\n // Restore from string state\n this.checked = state === (this.value || 'on');\n }\n }\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n }\n }\n\n render() {\n return (\n <Host class={this.switchClassNames()} aria-disabled={this.disabled ? 'true' : null}>\n <label htmlFor={this.componentId}>\n <input\n aria-describedby={assignDescription(this.componentId, this.invalid, this.errorMessage || this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n checked={this.checked}\n class=\"pds-switch__input\"\n disabled={this.disabled}\n id={this.componentId}\n name={this.name ? this.name : this.componentId}\n onChange={this.onSwitchUpdate}\n required={this.required}\n type=\"checkbox\"\n value={this.value}\n {...this.inheritedAttributes}\n />\n <span class={this.hideLabel ? 'visually-hidden' : ''}>\n {this.label}\n </span>\n </label>\n {this.helperMessage &&\n <div\n class={`pds-switch__message`}\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </div>\n }\n {this.errorMessage &&\n <div\n class={`pds-switch__message pds-switch__message--error`}\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </div>\n }\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,QAAQ,GAAG,oTAAoT;;ACArU,MAAM,YAAY,GAAG,imHAAimH;;MCazmH,SAAS,GAAA,MAAA;AANtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAOU,QAAA,IAAmB,CAAA,mBAAA,GAAe,EAAE;AAE3B,QAAA,IAAK,CAAA,KAAA,GAAG,UAAmB;AAS5C;;AAEG;AACsB,QAAA,IAAO,CAAA,OAAA,GAAG,KAAK;AAExC;;AAEG;AACK,QAAA,IAAQ,CAAA,QAAA,GAAI,KAAK;AAiBzB;;AAEG;AACK,QAAA,IA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;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";var pdsTabCss='pds-tab{-ms-flex-align:center;align-items:center;display:-ms-inline-flexbox;display:inline-flex;position:relative}.pds-tabs--pill pds-tab{-ms-flex:1;flex:1}.pds-tab{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:var(--pine-border-width-none);-webkit-box-shadow:none;box-shadow:none;color:inherit;cursor:pointer;font-family:inherit;padding:var(--pine-dimension-none);-ms-flex-align:center;align-items:center;color:var(--pine-color-text-secondary);display:-ms-inline-flexbox;display:inline-flex;position:relative;text-decoration:none;white-space:nowrap}.pds-tab.is-active,.pds-tab[aria-selected=true]{color:var(--pine-color-text)}.pds-tab.is-active .pds-tab__content::after,.pds-tab[aria-selected=true] .pds-tab__content::after{opacity:1}.pds-tab:hover:not(:disabled){color:var(--pine-color-text)}.pds-tab:focus{outline:none}.pds-tab:focus-visible{outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}.pds-tab:disabled,.pds-tab.is-disabled{color:var(--pine-color-text-disabled);cursor:not-allowed}.pds-tab .pds-tab__content{font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-medium);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);-webkit-padding-after:11px;padding-block-end:11px;position:relative}.pds-tab .pds-tab__content::after{background-color:var(--pine-color-brand);content:"";height:3px;inset-block-end:var(--pine-dimension-none);inset-inline-end:var(--pine-dimension-none);inset-inline-start:var(--pine-dimension-none);opacity:0;position:absolute}.pds-tab .pds-tab-edge{display:none}.pds-tabs--availability{--color-background-tab:transparent}.pds-tabs--availability .pds-tab{background-color:var(--color-background-tab);border-radius:calc(var(--pine-dimension-xs) * 1.25) calc(var(--pine-dimension-xs) * 1.25) var(--pine-dimension-none) var(--pine-dimension-none);color:var(--pine-color-text-secondary);padding:8px 16px 13px}.pds-tabs--availability .pds-tab.is-active,.pds-tabs--availability .pds-tab[aria-selected=true]{--color-background-tab:var(--pine-color-secondary);color:var(--pine-color-text)}.pds-tabs--availability .pds-tab.is-active .pds-tab__content::after,.pds-tabs--availability .pds-tab[aria-selected=true] .pds-tab__content::after{opacity:1}.pds-tabs--availability .pds-tab.is-active .pds-tab-edge,.pds-tabs--availability .pds-tab[aria-selected=true] .pds-tab-edge{z-index:var(--pine-z-index-raised)}.pds-tabs--availability .pds-tab:hover:not(.is-active,[aria-selected=true],:disabled){--color-background-tab:var(--pine-color-secondary-hover);color:var(--pine-color-text)}.pds-tabs--availability .pds-tab:focus-visible{color:var(--pine-color-text-secondary)}.pds-tabs--availability .pds-tab:disabled,.pds-tabs--availability .pds-tab.is-disabled{--color-background-tab:transparent;color:var(--pine-color-text-disabled)}.pds-tabs--availability .pds-tab__content{-webkit-padding-after:7px;padding-block-end:7px}.pds-tabs--availability .pds-tab-edge{bottom:0;display:block;height:8px;inset-inline-end:100%;overflow:hidden;position:absolute;width:8px}.pds-tabs--availability .pds-tab-edge::before{border-radius:50%;bottom:0;-webkit-box-shadow:4px 4px 0 0 var(--color-background-tab);box-shadow:4px 4px 0 0 var(--color-background-tab);content:"";display:block;height:200%;inset-inline-end:0;position:absolute;width:200%}.pds-tabs--availability .pds-tab-edge--end{inset-inline-end:unset;inset-inline-start:100%}.pds-tabs--availability .pds-tab-edge--end::before{-webkit-box-shadow:-4px 4px 0 0 var(--color-background-tab);box-shadow:-4px 4px 0 0 var(--color-background-tab);inset-inline-end:unset;inset-inline-start:0}.pds-tabs--filter .pds-tab{background-color:var(--pine-color-background-muted);border-radius:50px;color:var(--pine-color-text);padding:6px 15px}.pds-tabs--filter .pds-tab.is-active,.pds-tabs--filter .pds-tab[aria-selected=true]{background-color:var(--pine-color-primary);color:var(--pine-color-text-primary)}.pds-tabs--filter .pds-tab.is-active:hover:not(:disabled),.pds-tabs--filter .pds-tab[aria-selected=true]:hover:not(:disabled){background-color:var(--pine-color-primary-hover)}.pds-tabs--filter .pds-tab:hover:not(.is-active,[aria-selected=true],:disabled){background-color:var(--pine-color-border-disabled)}.pds-tabs--filter .pds-tab:disabled,.pds-tabs--filter .pds-tab.is-disabled{background-color:transparent;color:var(--pine-color-text-disabled)}.pds-tabs--filter .pds-tab:disabled.is-active,.pds-tabs--filter .pds-tab:disabled[aria-selected=true],.pds-tabs--filter .pds-tab.is-disabled.is-active,.pds-tabs--filter .pds-tab.is-disabled[aria-selected=true]{background-color:var(--pine-color-primary-disabled)}.pds-tabs--filter .pds-tab__content{-webkit-padding-after:var(--pine-dimension-none);padding-block-end:var(--pine-dimension-none)}.pds-tabs--filter .pds-tab__content::after{content:unset}.pds-tabs--pill{--color-background-tab:transparent}.pds-tabs--pill .pds-tab{background-color:var(--color-background-tab);border:var(--pine-border-width-thin) solid transparent;border-radius:var(--pine-dimension-xs);color:var(--pine-color-text-muted);-ms-flex:1;flex:1;height:34px;-ms-flex-pack:center;justify-content:center}.pds-tabs--pill .pds-tab .pds-tab__content{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-webkit-padding-after:0;padding-block-end:0}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{--color-background-tab:var(--pine-color-background-container);border-color:var(--pine-color-border);-webkit-box-shadow:var(--pine-box-shadow-100);box-shadow:var(--pine-box-shadow-100);color:var(--pine-color-text-active)}.pds-tabs--pill .pds-tab.is-active:focus-visible,.pds-tabs--pill .pds-tab[aria-selected=true]:focus-visible{border-color:var(--color-border-focus);outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{}.pds-tabs--pill .pds-tab.is-active .pds-tab__content::after,.pds-tabs--pill .pds-tab[aria-selected=true] .pds-tab__content::after{opacity:0}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{}.pds-tabs--pill .pds-tab:disabled,.pds-tabs--pill .pds-tab.is-disabled{color:var(--pine-color-text-disabled)}';var PdsTab=function(){function a(a){registerInstance(this,a);this.pdsTabClick=createEvent(this,"pdsTabClick");this.disabled=false;this.selected=false}a.prototype.onTabClick=function(a,e){if(this.disabled)return;this.pdsTabClick.emit([a,e])};a.prototype.classNames=function(){var a=["pds-tab",this.selected&&"is-active",this.disabled&&"is-disabled"];return a.filter(Boolean).join(" ")};a.prototype.render=function(){var a=h("span",{key:"934d84846bd84471047f9ab7503e5bb151426cbc",class:"pds-tab-edge",role:"presentation"});var e=h("span",{key:"e35b9da7b312ed95dab7bf803c40a22b3485ee05",class:"pds-tab-edge pds-tab-edge--end",role:"presentation"});return h(Host,{key:"310188521230d3e16cff23b857769c4b5d04fd8d",variant:this.variant,slot:"tabs",index:this.index},h("button",{key:"9df38c2aa1fa29487fdce62ce7dc5f67df6bcde1",role:"tab",id:this.parentComponentId+"__"+this.name,"aria-controls":this.parentComponentId+"__"+this.name+"-panel",tabindex:this.disabled?"-1":this.selected?"0":"-1","aria-selected":this.selected?"true":"false","aria-disabled":this.disabled?"true":null,disabled:this.disabled,class:this.classNames(),onClick:this.onTabClick.bind(this,this.index,this.parentComponentId)},this.variant==="availability"&&a,this.variant==="availability"&&e,h("div",{key:"4936599dd547f236880ea9a0ccabc4b50836d1d5",class:"pds-tab__content"},h("slot",{key:"567388faf912bb307676cea9a4626ce9669087dd"}))))};Object.defineProperty(a.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return a}();PdsTab.style=pdsTabCss;export{PdsTab as pds_tab};
1
+ import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";var pdsTabCss='pds-tab{-ms-flex-align:center;align-items:center;display:-ms-inline-flexbox;display:inline-flex;position:relative}.pds-tabs--pill pds-tab{-ms-flex:1;flex:1}.pds-tab{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:var(--pine-border-width-none);-webkit-box-shadow:none;box-shadow:none;color:inherit;cursor:pointer;font-family:inherit;padding:var(--pine-dimension-none);-ms-flex-align:center;align-items:center;color:var(--pine-color-text-secondary);display:-ms-inline-flexbox;display:inline-flex;position:relative;text-decoration:none;white-space:nowrap}.pds-tab.is-active,.pds-tab[aria-selected=true]{color:var(--pine-color-text)}.pds-tab.is-active .pds-tab__content::after,.pds-tab[aria-selected=true] .pds-tab__content::after{opacity:1}.pds-tab:hover:not(:disabled){color:var(--pine-color-text)}.pds-tab:focus{outline:none}.pds-tab:focus-visible{outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}.pds-tab:disabled,.pds-tab.is-disabled{color:var(--pine-color-text-disabled);cursor:not-allowed}.pds-tab .pds-tab__content{font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-medium);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);-webkit-padding-after:11px;padding-block-end:11px;position:relative}.pds-tab .pds-tab__content::after{background-color:var(--pine-color-brand);content:"";height:3px;inset-block-end:var(--pine-dimension-none);inset-inline-end:var(--pine-dimension-none);inset-inline-start:var(--pine-dimension-none);opacity:0;position:absolute}.pds-tab .pds-tab-edge{display:none}.pds-tabs--availability{--color-background-tab:transparent}.pds-tabs--availability .pds-tab{background-color:var(--color-background-tab);border-radius:calc(var(--pine-dimension-xs) * 1.25) calc(var(--pine-dimension-xs) * 1.25) var(--pine-dimension-none) var(--pine-dimension-none);color:var(--pine-color-text-secondary);padding:8px 16px 13px}.pds-tabs--availability .pds-tab.is-active,.pds-tabs--availability .pds-tab[aria-selected=true]{--color-background-tab:var(--pine-color-secondary);color:var(--pine-color-text)}.pds-tabs--availability .pds-tab.is-active .pds-tab__content::after,.pds-tabs--availability .pds-tab[aria-selected=true] .pds-tab__content::after{opacity:1}.pds-tabs--availability .pds-tab.is-active .pds-tab-edge,.pds-tabs--availability .pds-tab[aria-selected=true] .pds-tab-edge{z-index:var(--pine-z-index-raised)}.pds-tabs--availability .pds-tab:hover:not(.is-active,[aria-selected=true],:disabled){--color-background-tab:var(--pine-color-secondary-hover);color:var(--pine-color-text)}.pds-tabs--availability .pds-tab:focus-visible{color:var(--pine-color-text-secondary)}.pds-tabs--availability .pds-tab:disabled,.pds-tabs--availability .pds-tab.is-disabled{--color-background-tab:transparent;color:var(--pine-color-text-disabled)}.pds-tabs--availability .pds-tab__content{-webkit-padding-after:7px;padding-block-end:7px}.pds-tabs--availability .pds-tab-edge{bottom:0;display:block;height:8px;inset-inline-end:100%;overflow:hidden;position:absolute;width:8px}.pds-tabs--availability .pds-tab-edge::before{border-radius:50%;bottom:0;-webkit-box-shadow:4px 4px 0 0 var(--color-background-tab);box-shadow:4px 4px 0 0 var(--color-background-tab);content:"";display:block;height:200%;inset-inline-end:0;position:absolute;width:200%}.pds-tabs--availability .pds-tab-edge--end{inset-inline-end:unset;inset-inline-start:100%}.pds-tabs--availability .pds-tab-edge--end::before{-webkit-box-shadow:-4px 4px 0 0 var(--color-background-tab);box-shadow:-4px 4px 0 0 var(--color-background-tab);inset-inline-end:unset;inset-inline-start:0}.pds-tabs--filter .pds-tab{background-color:var(--pine-color-background-muted);border-radius:50px;color:var(--pine-color-text);padding:6px 15px}.pds-tabs--filter .pds-tab.is-active,.pds-tabs--filter .pds-tab[aria-selected=true]{background-color:var(--pine-color-primary);color:var(--pine-color-text-primary)}.pds-tabs--filter .pds-tab.is-active:hover:not(:disabled),.pds-tabs--filter .pds-tab[aria-selected=true]:hover:not(:disabled){background-color:var(--pine-color-primary-hover)}.pds-tabs--filter .pds-tab:hover:not(.is-active,[aria-selected=true],:disabled){background-color:var(--pine-color-border-disabled)}.pds-tabs--filter .pds-tab:disabled,.pds-tabs--filter .pds-tab.is-disabled{background-color:transparent;color:var(--pine-color-text-disabled)}.pds-tabs--filter .pds-tab:disabled.is-active,.pds-tabs--filter .pds-tab:disabled[aria-selected=true],.pds-tabs--filter .pds-tab.is-disabled.is-active,.pds-tabs--filter .pds-tab.is-disabled[aria-selected=true]{background-color:var(--pine-color-primary-disabled)}.pds-tabs--filter .pds-tab__content{-webkit-padding-after:var(--pine-dimension-none);padding-block-end:var(--pine-dimension-none)}.pds-tabs--filter .pds-tab__content::after{content:unset}.pds-tabs--pill{--color-background-tab:transparent}.pds-tabs--pill .pds-tab{background-color:var(--color-background-tab);border:var(--pine-border-width-thin) solid transparent;border-radius:var(--pine-dimension-xs);color:var(--pine-color-text-muted);-ms-flex:1;flex:1;height:34px;-ms-flex-pack:center;justify-content:center}.pds-tabs--pill .pds-tab .pds-tab__content{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-webkit-padding-after:0;padding-block-end:0}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{--color-background-tab:var(--pine-color-background-container);border-color:var(--pine-color-border);-webkit-box-shadow:var(--pine-box-shadow-100);box-shadow:var(--pine-box-shadow-100);color:var(--pine-color-text-active)}.pds-tabs--pill .pds-tab.is-active:focus-visible,.pds-tabs--pill .pds-tab[aria-selected=true]:focus-visible{border-color:var(--color-border-focus);outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{}.pds-tabs--pill .pds-tab.is-active .pds-tab__content::after,.pds-tabs--pill .pds-tab[aria-selected=true] .pds-tab__content::after{opacity:0}.pds-tabs--pill .pds-tab.is-active,.pds-tabs--pill .pds-tab[aria-selected=true]{}.pds-tabs--pill .pds-tab:disabled,.pds-tabs--pill .pds-tab.is-disabled{color:var(--pine-color-text-disabled)}';var PdsTab=function(){function a(a){registerInstance(this,a);this.pdsTabClick=createEvent(this,"pdsTabClick");this.disabled=false;this.selected=false}a.prototype.onTabClick=function(a,e){if(this.disabled)return;this.pdsTabClick.emit([a,e])};a.prototype.classNames=function(){var a=["pds-tab",this.selected&&"is-active",this.disabled&&"is-disabled"];return a.filter(Boolean).join(" ")};a.prototype.render=function(){var a=h("span",{key:"934d84846bd84471047f9ab7503e5bb151426cbc",class:"pds-tab-edge",role:"presentation"});var e=h("span",{key:"e35b9da7b312ed95dab7bf803c40a22b3485ee05",class:"pds-tab-edge pds-tab-edge--end",role:"presentation"});return h(Host,{key:"310188521230d3e16cff23b857769c4b5d04fd8d",variant:this.variant,slot:"tabs",index:this.index},h("button",{key:"9df38c2aa1fa29487fdce62ce7dc5f67df6bcde1",role:"tab",id:this.parentComponentId+"__"+this.name,"aria-controls":this.parentComponentId+"__"+this.name+"-panel",tabindex:this.disabled?"-1":this.selected?"0":"-1","aria-selected":this.selected?"true":"false","aria-disabled":this.disabled?"true":null,disabled:this.disabled,class:this.classNames(),onClick:this.onTabClick.bind(this,this.index,this.parentComponentId)},this.variant==="availability"&&a,this.variant==="availability"&&e,h("div",{key:"4936599dd547f236880ea9a0ccabc4b50836d1d5",class:"pds-tab__content"},h("slot",{key:"567388faf912bb307676cea9a4626ce9669087dd"}))))};Object.defineProperty(a.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return a}();PdsTab.style=pdsTabCss;export{PdsTab as pds_tab};
2
2
  //# sourceMappingURL=pds-tab.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host}from"./index-CO9kz-Pi.js";var pdsTableBodyCss=":host{border-color:inherit;display:table-row-group;vertical-align:middle}";var PdsTableBody=function(){function e(e){registerInstance(this,e)}e.prototype.render=function(){return h(Host,{key:"457fc5406a1fe67055038398e03bfad97a393747",role:"rowgroup",part:"body"},h("slot",{key:"5950bced36f7ba590f34173149cf8663ba76103b"}))};return e}();PdsTableBody.style=pdsTableBodyCss;export{PdsTableBody as pds_table_body};
1
+ import{r as registerInstance,h,H as Host}from"./index-QYCDCKN2.js";var pdsTableBodyCss=":host{border-color:inherit;display:table-row-group;vertical-align:middle}";var PdsTableBody=function(){function e(e){registerInstance(this,e)}e.prototype.render=function(){return h(Host,{key:"457fc5406a1fe67055038398e03bfad97a393747",role:"rowgroup",part:"body"},h("slot",{key:"5950bced36f7ba590f34173149cf8663ba76103b"}))};return e}();PdsTableBody.style=pdsTableBodyCss;export{PdsTableBody as pds_table_body};
2
2
  //# sourceMappingURL=pds-table-body.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{s as setupTruncationTooltip}from"./truncation-tooltip-Blk4GigP.js";import"./floating-ui.dom-DDtwbwIl.js";var pdsTableCellCss=":host{--box-shadow-fixed:3px 3px 6px -2px rgba(0, 0, 0, 0.2);color:var(--pine-color-text);display:table-cell;font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-regular);inset-inline-start:var(--pine-dimension-none);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);padding:var(--pine-dimension-sm);vertical-align:middle}:host(.is-compact){padding-block:var(--pine-dimension-2xs)}:host(.is-fixed){background:var(--pine-color-background-container);left:0;position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host(.has-scrolled.is-fixed){-webkit-box-shadow:var(--box-shadow-fixed);box-shadow:var(--box-shadow-fixed)}:host(.is-truncated){max-width:var(--pds-table-cell-truncate-max-width, 100px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.has-checkbox){vertical-align:middle;width:16px}:host(.pds-table-cell--align-start){text-align:start}:host(.pds-table-cell--align-center){text-align:center}:host(.pds-table-cell--align-end){text-align:end}:host(.pds-table-cell--align-justify){text-align:justify}";var PdsTableCell=function(){function t(t){var i=this;registerInstance(this,t);this.scrollContainer=null;this.setupRetries=0;this.truncationCleanup=null;this.tableScrolling=false;this.handleScroll=function(){if(!i.scrollContainer){return}try{i.tableScrolling=i.scrollContainer.scrollLeft>0}catch(t){console.warn("Scroll handler error:",t)}}}t.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table")};t.prototype.componentDidLoad=function(){if(this.tableRef&&this.tableRef.responsive&&this.tableRef.fixedColumn){this.setupScrollListener()}if(this.truncate){this.initTruncationTooltip()}};t.prototype.disconnectedCallback=function(){this.cleanupScrollListener();this.destroyTruncationTooltip()};t.prototype.setupScrollListener=function(){var t=this;var i;if(!this.tableRef)return;var e=(i=this.tableRef.shadowRoot)===null||i===void 0?void 0:i.querySelector(".pds-table-responsive-container");if(e){this.scrollContainer=e;this.scrollContainer.addEventListener("scroll",this.handleScroll,{passive:true});this.handleScroll();this.setupRetries=0}else{this.setupTimer=window.setTimeout((function(){if(t.scrollContainer)return;t.setupRetries=(t.setupRetries||0)+1;if(t.setupRetries<=50){t.setupScrollListener()}else{console.warn("Failed to find responsive container after 50 attempts")}}),100)}};t.prototype.cleanupScrollListener=function(){if(this.scrollContainer){this.scrollContainer.removeEventListener("scroll",this.handleScroll);this.scrollContainer=null}if(this.setupTimer!==undefined){window.clearTimeout(this.setupTimer);this.setupTimer=undefined}this.setupRetries=0};t.prototype.handleTruncateChange=function(t){if(t){this.initTruncationTooltip()}else{this.destroyTruncationTooltip()}};t.prototype.initTruncationTooltip=function(){var t=this;this.destroyTruncationTooltip();this.truncationCleanup=setupTruncationTooltip({hostEl:this.hostElement,contentEl:this.hostElement,getTooltipText:function(){return t.hostElement.textContent||""}})};t.prototype.destroyTruncationTooltip=function(){if(this.truncationCleanup){this.truncationCleanup();this.truncationCleanup=null}};t.prototype.classNames=function(){var t=[];if(this.tableRef&&this.tableRef.compact){t.push("is-compact")}if(this.cellAlign){t.push("pds-table-cell--align-".concat(this.cellAlign))}if(this.truncate){t.push("is-truncated")}if(this.tableRef&&this.tableRef.fixedColumn&&this.tableScrolling){t.push("has-scrolled")}return t.join(" ")};t.prototype.render=function(){return h(Host,{key:"f1526ebf858c52e01185174cb37770d130abd3ca",class:this.classNames(),role:"gridcell",part:"cell",tabIndex:this.truncate?0:undefined,style:this.tableRef&&this.tableRef.fixedColumn&&this.tableRef.selectable?{"--fixed-cell-position":"40px"}:{}},h("slot",{key:"518a3cb3fad0bbbe029f218c2dc89596d1cd0b16"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{truncate:["handleTruncateChange"]}},enumerable:false,configurable:true});return t}();PdsTableCell.style=pdsTableCellCss;export{PdsTableCell as pds_table_cell};
1
+ import{r as registerInstance,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{a as isScrolledFromInlineStart}from"./scroll-DtgUQhjl.js";import{s as setupTruncationTooltip}from"./truncation-tooltip-Blk4GigP.js";import"./floating-ui.dom-DDtwbwIl.js";var pdsTableCellCss=":host{--box-shadow-fixed:3px 3px 6px -2px rgba(0, 0, 0, 0.2);color:var(--pine-color-text);display:table-cell;font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-regular);inset-inline-start:var(--pine-dimension-none);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);padding:var(--pine-dimension-sm);vertical-align:middle}:host(.is-compact){padding-block:var(--pine-dimension-2xs)}:host(.is-fixed){background:var(--pine-color-background-container);inset-inline-start:0;position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host-context([dir=rtl]){--box-shadow-fixed:-3px 3px 6px -2px rgba(0, 0, 0, 0.2)}:host(.has-scrolled.is-fixed){-webkit-box-shadow:var(--box-shadow-fixed);box-shadow:var(--box-shadow-fixed)}:host(.is-truncated){max-width:var(--pds-table-cell-truncate-max-width, 100px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.has-checkbox){vertical-align:middle;width:16px}:host(.pds-table-cell--align-start){text-align:start}:host(.pds-table-cell--align-center){text-align:center}:host(.pds-table-cell--align-end){text-align:end}:host(.pds-table-cell--align-justify){text-align:justify}";var PdsTableCell=function(){function t(t){var i=this;registerInstance(this,t);this.scrollContainer=null;this.setupRetries=0;this.truncationCleanup=null;this.tableScrolling=false;this.handleScroll=function(){if(!i.scrollContainer){return}try{i.tableScrolling=isScrolledFromInlineStart(i.scrollContainer)}catch(t){console.warn("Scroll handler error:",t)}}}t.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table")};t.prototype.componentDidLoad=function(){if(this.tableRef&&this.tableRef.responsive&&this.tableRef.fixedColumn){this.setupScrollListener()}if(this.truncate){this.initTruncationTooltip()}};t.prototype.disconnectedCallback=function(){this.cleanupScrollListener();this.destroyTruncationTooltip()};t.prototype.setupScrollListener=function(){var t=this;var i;if(!this.tableRef)return;var e=(i=this.tableRef.shadowRoot)===null||i===void 0?void 0:i.querySelector(".pds-table-responsive-container");if(e){this.scrollContainer=e;this.scrollContainer.addEventListener("scroll",this.handleScroll,{passive:true});this.handleScroll();this.setupRetries=0}else{this.setupTimer=window.setTimeout((function(){if(t.scrollContainer)return;t.setupRetries=(t.setupRetries||0)+1;if(t.setupRetries<=50){t.setupScrollListener()}else{console.warn("Failed to find responsive container after 50 attempts")}}),100)}};t.prototype.cleanupScrollListener=function(){if(this.scrollContainer){this.scrollContainer.removeEventListener("scroll",this.handleScroll);this.scrollContainer=null}if(this.setupTimer!==undefined){window.clearTimeout(this.setupTimer);this.setupTimer=undefined}this.setupRetries=0};t.prototype.handleTruncateChange=function(t){if(t){this.initTruncationTooltip()}else{this.destroyTruncationTooltip()}};t.prototype.initTruncationTooltip=function(){var t=this;this.destroyTruncationTooltip();this.truncationCleanup=setupTruncationTooltip({hostEl:this.hostElement,contentEl:this.hostElement,getTooltipText:function(){return t.hostElement.textContent||""}})};t.prototype.destroyTruncationTooltip=function(){if(this.truncationCleanup){this.truncationCleanup();this.truncationCleanup=null}};t.prototype.classNames=function(){var t=[];if(this.tableRef&&this.tableRef.compact){t.push("is-compact")}if(this.cellAlign){t.push("pds-table-cell--align-".concat(this.cellAlign))}if(this.truncate){t.push("is-truncated")}if(this.tableRef&&this.tableRef.fixedColumn&&this.tableScrolling){t.push("has-scrolled")}return t.join(" ")};t.prototype.render=function(){return h(Host,{key:"b108b0fce3ff0d5c503922a6c936ffd6ca52523f",class:this.classNames(),role:"gridcell",part:"cell",tabIndex:this.truncate?0:undefined,style:this.tableRef&&this.tableRef.fixedColumn&&this.tableRef.selectable?{"--fixed-cell-position":"40px"}:{}},h("slot",{key:"ebc1709ef52029bc6afec2fa89a90d47620892cb"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{truncate:["handleTruncateChange"]}},enumerable:false,configurable:true});return t}();PdsTableCell.style=pdsTableCellCss;export{PdsTableCell as pds_table_cell};
2
2
  //# sourceMappingURL=pds-table-cell.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pds-table-cell.entry.js","sources":["src/components/pds-table/pds-table-cell/pds-table-cell.scss?tag=pds-table-cell&encapsulation=shadow","src/components/pds-table/pds-table-cell/pds-table-cell.tsx"],"sourcesContent":[":host {\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-fixed: 3px 3px 6px -2px rgba(0, 0, 0, 0.2);\n\n color: var(--pine-color-text);\n display: table-cell;\n font-family: var(--pine-font-family-body);\n font-size: var(--pine-font-size);\n font-weight: var(--pine-font-weight-regular);\n inset-inline-start: var(--pine-dimension-none);\n letter-spacing: var(--pine-letter-spacing);\n line-height: var(--pine-line-height-body);\n padding: var(--pine-dimension-sm);\n vertical-align: middle;\n}\n\n:host(.is-compact) {\n padding-block: var(--pine-dimension-2xs)\n}\n\n:host(.is-fixed) {\n background: var(--pine-color-background-container);\n left: 0;\n position: sticky;\n z-index: var(--pine-z-index-raised);\n}\n\n// box shadow when table has scrolled and cell is fixed\n:host(.has-scrolled.is-fixed) {\n box-shadow: var(--box-shadow-fixed);\n}\n\n:host(.is-truncated) {\n max-width: var(--pds-table-cell-truncate-max-width, 100px);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n:host(.has-checkbox) {\n vertical-align: middle;\n width: 16px;\n}\n\n// Text Alignment\n:host(.pds-table-cell--align-start) {\n text-align: start;\n}\n\n:host(.pds-table-cell--align-center) {\n text-align: center;\n}\n\n:host(.pds-table-cell--align-end) {\n text-align: end;\n}\n\n:host(.pds-table-cell--align-justify) {\n text-align: justify;\n}\n","import { Component, Element, Host, Prop, State, Watch, h } from '@stencil/core';\nimport { setupTruncationTooltip } from '../../../utils/truncation-tooltip';\n\n@Component({\n tag: 'pds-table-cell',\n styleUrls: ['pds-table-cell.scss'],\n shadow: true,\n})\nexport class PdsTableCell {\n @Element() hostElement: HTMLPdsTableCellElement;\n private tableRef: HTMLPdsTableElement;\n private scrollContainer: HTMLElement | null = null;\n private setupTimer: number | undefined;\n private setupRetries: number = 0;\n private truncationCleanup: (() => void) | null = null;\n\n componentWillRender() {\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n }\n\n componentDidLoad() {\n if (this.tableRef && this.tableRef.responsive && this.tableRef.fixedColumn) {\n // For responsive tables with fixed columns, set up scroll detection\n // This enables the first column to show a shadow when the table is scrolled horizontally\n this.setupScrollListener();\n }\n\n if (this.truncate) {\n this.initTruncationTooltip();\n }\n }\n\n disconnectedCallback() {\n this.cleanupScrollListener();\n this.destroyTruncationTooltip();\n }\n\n private setupScrollListener() {\n if (!this.tableRef) return;\n\n // Query shadowRoot once and cache the container\n const container = this.tableRef.shadowRoot?.querySelector('.pds-table-responsive-container') as HTMLElement;\n\n if (container) {\n // Container available immediately\n this.scrollContainer = container;\n this.scrollContainer.addEventListener('scroll', this.handleScroll, { passive: true });\n this.handleScroll(); // Initial check\n this.setupRetries = 0; // Reset counter on success\n } else {\n // Container not ready, set up timer for retry with bounds\n this.setupTimer = window.setTimeout(() => {\n if (this.scrollContainer) return; // Already found\n this.setupRetries = (this.setupRetries || 0) + 1;\n if (this.setupRetries <= 50) {\n this.setupScrollListener();\n } else {\n console.warn('Failed to find responsive container after 50 attempts');\n }\n }, 100);\n }\n }\n\n private cleanupScrollListener() {\n if (this.scrollContainer) {\n this.scrollContainer.removeEventListener('scroll', this.handleScroll);\n this.scrollContainer = null;\n }\n\n if (this.setupTimer !== undefined) {\n window.clearTimeout(this.setupTimer);\n this.setupTimer = undefined;\n }\n\n this.setupRetries = 0; // Reset retry counter\n }\n\n /**\n * Sets the text alignment within the cell.\n */\n @Prop() cellAlign?: 'start' | 'center' | 'end' | 'justify';\n\n /**\n * Truncates content to a max width and adds an ellipsis.\n * When text overflows, a tooltip showing the full text will appear on hover/focus.\n * Note: When truncate is enabled, the element automatically receives tabindex=\"0\" for keyboard accessibility.\n */\n @Prop() truncate: boolean;\n\n @Watch('truncate')\n handleTruncateChange(newValue: boolean) {\n if (newValue) {\n this.initTruncationTooltip();\n } else {\n this.destroyTruncationTooltip();\n }\n }\n\n /**\n * Determines if the table is currently scrolling.\n * @defaultValue false\n */\n @State() private tableScrolling: boolean = false;\n\n private initTruncationTooltip() {\n this.destroyTruncationTooltip();\n\n this.truncationCleanup = setupTruncationTooltip({\n hostEl: this.hostElement,\n contentEl: this.hostElement,\n getTooltipText: () => this.hostElement.textContent || '',\n });\n }\n\n private destroyTruncationTooltip() {\n if (this.truncationCleanup) {\n this.truncationCleanup();\n this.truncationCleanup = null;\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.tableRef && this.tableRef.compact) {\n classNames.push('is-compact');\n }\n\n if (this.cellAlign) {\n classNames.push(`pds-table-cell--align-${this.cellAlign}`);\n }\n\n if (this.truncate) {\n classNames.push('is-truncated');\n }\n\n if (this.tableRef && this.tableRef.fixedColumn && this.tableScrolling) {\n classNames.push('has-scrolled');\n }\n\n return classNames.join(' ');\n }\n\n /**\n * Handles scroll events to update fixed column shadow state.\n * Updates the tableScrolling state to control CSS classes for fixed column shadows.\n * @private\n */\n private handleScroll = () => {\n if (!this.scrollContainer) {\n return;\n }\n\n try {\n this.tableScrolling = this.scrollContainer.scrollLeft > 0;\n } catch (error) {\n console.warn('Scroll handler error:', error);\n }\n };\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"gridcell\"\n part=\"cell\"\n tabIndex={this.truncate ? 0 : undefined}\n style={\n this.tableRef &&\n this.tableRef.f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,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,EACxB,IAAI,EAAC,UAAU,EACf,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,IAAI,CAAC,QAAQ,GAAG,CAAC,GAAG,SAAS,EACvC,KAAK,EACH,IAAI,CAAC,QAAQ;gBACb,IAAI,CAAC,QAAQ,CAAC,WAAW;gBACzB,IAAI,CAAC,QAAQ,CAAC;AACZ,kBAAE,EAAE,uBAAuB,EAAE,MAAM;AACnC,kBAAE,EAAE,EAAA,EAGR,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;"}
1
+ {"version":3,"file":"pds-table-cell.entry.js","sources":["src/components/pds-table/pds-table-cell/pds-table-cell.scss?tag=pds-table-cell&encapsulation=shadow","src/components/pds-table/pds-table-cell/pds-table-cell.tsx"],"sourcesContent":[":host {\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-fixed: 3px 3px 6px -2px rgba(0, 0, 0, 0.2);\n\n color: var(--pine-color-text);\n display: table-cell;\n font-family: var(--pine-font-family-body);\n font-size: var(--pine-font-size);\n font-weight: var(--pine-font-weight-regular);\n inset-inline-start: var(--pine-dimension-none);\n letter-spacing: var(--pine-letter-spacing);\n line-height: var(--pine-line-height-body);\n padding: var(--pine-dimension-sm);\n vertical-align: middle;\n}\n\n:host(.is-compact) {\n padding-block: var(--pine-dimension-2xs)\n}\n\n:host(.is-fixed) {\n background: var(--pine-color-background-container);\n inset-inline-start: 0;\n position: sticky;\n z-index: var(--pine-z-index-raised);\n}\n\n// Flip shadow toward scrollable content when fixed column is on the inline-end edge.\n:host-context([dir='rtl']) {\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-fixed: -3px 3px 6px -2px rgba(0, 0, 0, 0.2);\n}\n\n// box shadow when table has scrolled and cell is fixed\n:host(.has-scrolled.is-fixed) {\n box-shadow: var(--box-shadow-fixed);\n}\n\n:host(.is-truncated) {\n max-width: var(--pds-table-cell-truncate-max-width, 100px);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n:host(.has-checkbox) {\n vertical-align: middle;\n width: 16px;\n}\n\n// Text Alignment\n:host(.pds-table-cell--align-start) {\n text-align: start;\n}\n\n:host(.pds-table-cell--align-center) {\n text-align: center;\n}\n\n:host(.pds-table-cell--align-end) {\n text-align: end;\n}\n\n:host(.pds-table-cell--align-justify) {\n text-align: justify;\n}\n","import { Component, Element, Host, Prop, State, Watch, h } from '@stencil/core';\nimport { isScrolledFromInlineStart } from '../../../utils/scroll';\nimport { setupTruncationTooltip } from '../../../utils/truncation-tooltip';\n\n@Component({\n tag: 'pds-table-cell',\n styleUrls: ['pds-table-cell.scss'],\n shadow: true,\n})\nexport class PdsTableCell {\n @Element() hostElement: HTMLPdsTableCellElement;\n private tableRef: HTMLPdsTableElement;\n private scrollContainer: HTMLElement | null = null;\n private setupTimer: number | undefined;\n private setupRetries: number = 0;\n private truncationCleanup: (() => void) | null = null;\n\n componentWillRender() {\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n }\n\n componentDidLoad() {\n if (this.tableRef && this.tableRef.responsive && this.tableRef.fixedColumn) {\n // For responsive tables with fixed columns, set up scroll detection\n // This enables the first column to show a shadow when the table is scrolled horizontally\n this.setupScrollListener();\n }\n\n if (this.truncate) {\n this.initTruncationTooltip();\n }\n }\n\n disconnectedCallback() {\n this.cleanupScrollListener();\n this.destroyTruncationTooltip();\n }\n\n private setupScrollListener() {\n if (!this.tableRef) return;\n\n // Query shadowRoot once and cache the container\n const container = this.tableRef.shadowRoot?.querySelector('.pds-table-responsive-container') as HTMLElement;\n\n if (container) {\n // Container available immediately\n this.scrollContainer = container;\n this.scrollContainer.addEventListener('scroll', this.handleScroll, { passive: true });\n this.handleScroll(); // Initial check\n this.setupRetries = 0; // Reset counter on success\n } else {\n // Container not ready, set up timer for retry with bounds\n this.setupTimer = window.setTimeout(() => {\n if (this.scrollContainer) return; // Already found\n this.setupRetries = (this.setupRetries || 0) + 1;\n if (this.setupRetries <= 50) {\n this.setupScrollListener();\n } else {\n console.warn('Failed to find responsive container after 50 attempts');\n }\n }, 100);\n }\n }\n\n private cleanupScrollListener() {\n if (this.scrollContainer) {\n this.scrollContainer.removeEventListener('scroll', this.handleScroll);\n this.scrollContainer = null;\n }\n\n if (this.setupTimer !== undefined) {\n window.clearTimeout(this.setupTimer);\n this.setupTimer = undefined;\n }\n\n this.setupRetries = 0; // Reset retry counter\n }\n\n /**\n * Sets the text alignment within the cell.\n */\n @Prop() cellAlign?: 'start' | 'center' | 'end' | 'justify';\n\n /**\n * Truncates content to a max width and adds an ellipsis.\n * When text overflows, a tooltip showing the full text will appear on hover/focus.\n * Note: When truncate is enabled, the element automatically receives tabindex=\"0\" for keyboard accessibility.\n */\n @Prop() truncate: boolean;\n\n @Watch('truncate')\n handleTruncateChange(newValue: boolean) {\n if (newValue) {\n this.initTruncationTooltip();\n } else {\n this.destroyTruncationTooltip();\n }\n }\n\n /**\n * Determines if the table is currently scrolling.\n * @defaultValue false\n */\n @State() private tableScrolling: boolean = false;\n\n private initTruncationTooltip() {\n this.destroyTruncationTooltip();\n\n this.truncationCleanup = setupTruncationTooltip({\n hostEl: this.hostElement,\n contentEl: this.hostElement,\n getTooltipText: () => this.hostElement.textContent || '',\n });\n }\n\n private destroyTruncationTooltip() {\n if (this.truncationCleanup) {\n this.truncationCleanup();\n this.truncationCleanup = null;\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.tableRef && this.tableRef.compact) {\n classNames.push('is-compact');\n }\n\n if (this.cellAlign) {\n classNames.push(`pds-table-cell--align-${this.cellAlign}`);\n }\n\n if (this.truncate) {\n classNames.push('is-truncated');\n }\n\n if (this.tableRef && this.tableRef.fixedColumn && this.tableScrolling) {\n classNames.push('has-scrolled');\n }\n\n return classNames.join(' ');\n }\n\n /**\n * Handles scroll events to update fixed column shadow state.\n * Updates the tableScrolling state to control CSS classes for fixed column shadows.\n * @private\n */\n private handleScroll = () => {\n if (!this.scrollContainer) {\n return;\n }\n\n try {\n this.tableScrolling = isScrolledFromInlineStart(this.scrollContainer);\n } catch (error) {\n console.warn('Scroll handler error:', error);\n }\n };\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"gridcell\"\n part=\"cell\"\n tabIndex={this.truncate ? 0 : undefined}\n style={\n this.tableRef &&\n this.tableRef.fixedColumn &&\n this.tableRef.selectable\n ? { '--fixed-cell-position': '40px' }\n : {}\n }\n >\n <slot></slot>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,eAAe,GAAG,4sCAA4sC;;MCSvtC,YAAY,GAAA,MAAA;AALzB,IAAA,WAAA,CAAA,OAAA,EAAA;;AAQU,QAAA,IAAe,CAAA,eAAA,GAAuB,IAAI;AAE1C,QAAA,IAAY,CAAA,YAAA,GAAW,CAAC;AACxB,QAAA,IAAiB,CAAA,iBAAA,GAAwB,IAAI;AAoFrD;;;AAGG;AACc,QAAA,IAAc,CAAA,cAAA,GAAY,KAAK;AAyChD;;;;AAIG;AACK,QAAA,IAAY,CAAA,YAAA,GAAG,MAAK;AAC1B,YAAA,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE;gBACzB;;AAGF,YAAA,IAAI;gBACF,IAAI,CAAC,cAAc,GAAG,yBAAyB,CAAC,IAAI,CAAC,eAAe,CAAC;;YACrE,OAAO,KAAK,EAAE;AACd,gBAAA,OAAO,CAAC,IAAI,CAAC,uBAAuB,EAAE,KAAK,CAAC;;AAEhD,SAAC;AAqBF;IAnKC,mBAAmB,GAAA;QACjB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,WAAW,CAAwB;;IAG9E,gBAAgB,GAAA;AACd,QAAA,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC,UAAU,IAAI,IAAI,CAAC,QAAQ,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,CAAC,cAAc,CAAC;;AAGjC,QAAA,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,IAAI,IAAI,CAAC,cAAc,EAAE;AACrE,YAAA,UAAU,CAAC,IAAI,CAAC,cAAc,CAAC;;AAGjC,QAAA,OAAO,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC;;IAoB7B,MAAM,GAAA;AACJ,QAAA,QACE,CAAC,CAAA,IAAI,EACH,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,EACxB,IAAI,EAAC,UAAU,EACf,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,IAAI,CAAC,QAAQ,GAAG,CAAC,GAAG,SAAS,EACvC,KAAK,EACH,IAAI,CAAC,QAAQ;gBACb,IAAI,CAAC,QAAQ,CAAC,WAAW;gBACzB,IAAI,CAAC,QAAQ,CAAC;AACZ,kBAAE,EAAE,uBAAuB,EAAE,MAAM;AACnC,kBAAE,EAAE,EAAA,EAGR,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- import{__awaiter,__generator}from"tslib";import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{i as upSmall,d as downSmall}from"./index-D4ys0pep.js";var pdsTableHeadCellCss=":host{--border-head-cell-default:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);--box-shadow-default:3px 3px 6px -2px rgba(0, 0, 0, 0.1);-webkit-border-after:var(--border-head-cell-default);border-block-end:var(--border-head-cell-default);color:var(--pine-color-text);display:table-cell;font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-regular);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);padding:var(--pine-dimension-sm);position:relative;text-align:start;vertical-align:inherit}:host(.is-compact){padding-block:var(--pine-dimension-2xs)}:host(.is-fixed){background:var(--pine-color-background-container);left:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host(.is-fixed.has-head-background){background-color:var(--pine-color-background-subtle)}:host(.has-head-border){-webkit-border-before:var(--border-head-cell-default);border-block-start:var(--border-head-cell-default)}:host(.has-scrolled.is-fixed){-webkit-box-shadow:var(--box-shadow-default);box-shadow:var(--box-shadow-default)}:host(.is-sortable){cursor:pointer}:host(.is-sortable) pds-icon{-webkit-margin-start:var(--pine-dimension-2xs);margin-inline-start:var(--pine-dimension-2xs);-webkit-padding-before:2px;padding-block-start:2px;position:absolute}:host(.is-sortable:hover),:host(.is-active){color:var(--pine-color-text-strong)}:host(.pds-table-head-cell--align-start){text-align:start}:host(.pds-table-head-cell--align-center){text-align:center}:host(.pds-table-head-cell--align-end){text-align:end}:host(.pds-table-head-cell--align-justify){text-align:justify}";var PdsTableHeadCell=function(){function t(t){var e=this;registerInstance(this,t);this.pdsTableSort=createEvent(this,"pdsTableSort");this.scrollContainer=null;this.setupRetries=0;this.sortingDirection="asc";this.tableScrolling=false;this.isSelected=false;this.hasHeadBorder=false;this.hasHeadBackground=false;this.isActive=false;this.handleScroll=function(){if(!e.scrollContainer){return}try{e.tableScrolling=e.scrollContainer.scrollLeft>0}catch(t){console.warn("Scroll handler error:",t)}};this.toggleSort=function(){if(e.sortable){if(!e.tableRef){return}var t=e.hostElement.innerText.trim();e.sortingDirection=e.sortingDirection==="asc"?"desc":"asc";e.tableRef.querySelectorAll("pds-table-head-cell").forEach((function(t){return __awaiter(e,void 0,void 0,(function(){var e;return __generator(this,(function(i){switch(i.label){case 0:if(!(t!==this.hostElement))return[3,2];e=t;return[4,e.clearActiveSort()];case 1:i.sent();i.label=2;case 2:return[2]}}))}))}));e.isActive=true;e.hostElement.classList.add("is-active");e.pdsTableSort.emit({column:t,direction:e.sortingDirection})}}}t.prototype.setActiveSort=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){if(!this.sortable)return[2];this.sortingDirection=t;this.isActive=true;this.hostElement.classList.add("is-active");return[2]}))}))};t.prototype.clearActiveSort=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.isActive=false;this.hostElement.classList.remove("is-active");return[2]}))}))};t.prototype.componentWillLoad=function(){this.tableRef=this.hostElement.closest("pds-table");var t=this.hostElement.closest("pds-table-head");if(t){this.hasHeadBorder=t.hasAttribute("border");this.hasHeadBackground=t.hasAttribute("background")}};t.prototype.componentDidLoad=function(){var t=this;if(this.tableRef&&this.tableRef.responsive&&this.tableRef.fixedColumn){this.setupScrollListener()}var e=this.hostElement.closest("pds-table-head");if(e&&typeof MutationObserver!=="undefined"){if(this.headObserver){this.headObserver.disconnect()}this.headObserver=new MutationObserver((function(){t.hasHeadBorder=e.hasAttribute("border");t.hasHeadBackground=e.hasAttribute("background")}));this.headObserver.observe(e,{attributes:true,attributeFilter:["border","background"]})}};t.prototype.disconnectedCallback=function(){this.cleanupScrollListener();if(this.headObserver){this.headObserver.disconnect()}};t.prototype.setupScrollListener=function(){var t=this;var e;if(!this.tableRef)return;var i=(e=this.tableRef.shadowRoot)===null||e===void 0?void 0:e.querySelector(".pds-table-responsive-container");if(i){this.scrollContainer=i;this.scrollContainer.addEventListener("scroll",this.handleScroll,{passive:true});this.handleScroll();this.setupRetries=0}else{this.setupTimer=window.setTimeout((function(){if(t.scrollContainer)return;t.setupRetries=(t.setupRetries||0)+1;if(t.setupRetries<=50){t.setupScrollListener()}else{console.warn("Failed to find responsive container after 50 attempts")}}),100)}};t.prototype.cleanupScrollListener=function(){if(this.scrollContainer){this.scrollContainer.removeEventListener("scroll",this.handleScroll);this.scrollContainer=null}if(this.setupTimer!==undefined){window.clearTimeout(this.setupTimer);this.setupTimer=undefined}this.setupRetries=0};t.prototype.classNames=function(){var t=[];if(this.tableRef&&this.tableRef.compact){t.push("is-compact")}if(this.cellAlign){t.push("pds-table-head-cell--align-".concat(this.cellAlign))}if(this.sortable){t.push("is-sortable")}if(this.sortable&&this.sortingDirection!==null){t.push("sort-"+this.sortingDirection)}if(this.tableRef&&this.tableRef.fixedColumn&&this.tableScrolling){t.push("has-scrolled")}if(this.hasHeadBackground){t.push("has-head-background")}if(this.hasHeadBorder){t.push("has-head-border")}return t.join(" ")};t.prototype.render=function(){return h(Host,{key:"a0196e242282574b969375a4767950ffd7a1e5b8",class:this.classNames(),role:"columnheader",onClick:this.toggleSort,part:"head-cell",style:this.tableRef&&this.tableRef.fixedColumn&&this.tableRef.selectable?{"--fixed-cell-position":"40px"}:{}},h("slot",{key:"90f6d190ed912276fb8ff5607a80b592d1884d71"}),this.sortable&&this.isActive&&h("pds-icon",{key:"128bd50d5163ea1690a66a4bef227480a0076f39",icon:this.sortingDirection==="asc"?upSmall:downSmall,part:"sort-icon"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTableHeadCell.style=pdsTableHeadCellCss;export{PdsTableHeadCell as pds_table_head_cell};
1
+ import{__awaiter,__generator}from"tslib";import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{i as upSmall,d as downSmall}from"./index-D4ys0pep.js";import{a as isScrolledFromInlineStart}from"./scroll-DtgUQhjl.js";var pdsTableHeadCellCss=":host{--border-head-cell-default:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);--box-shadow-default:3px 3px 6px -2px rgba(0, 0, 0, 0.1);-webkit-border-after:var(--border-head-cell-default);border-block-end:var(--border-head-cell-default);color:var(--pine-color-text);display:table-cell;font-family:var(--pine-font-family-body);font-size:var(--pine-font-size);font-weight:var(--pine-font-weight-regular);letter-spacing:var(--pine-letter-spacing);line-height:var(--pine-line-height-body);padding:var(--pine-dimension-sm);position:relative;text-align:start;vertical-align:inherit}:host(.is-compact){padding-block:var(--pine-dimension-2xs)}:host(.is-fixed){background:var(--pine-color-background-container);inset-inline-start:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host(.is-fixed.has-head-background){background-color:var(--pine-color-background-subtle)}:host(.has-head-border){-webkit-border-before:var(--border-head-cell-default);border-block-start:var(--border-head-cell-default)}:host-context([dir=rtl]){--box-shadow-default:-3px 3px 6px -2px rgba(0, 0, 0, 0.1)}:host(.has-scrolled.is-fixed){-webkit-box-shadow:var(--box-shadow-default);box-shadow:var(--box-shadow-default)}:host(.is-sortable){cursor:pointer}:host(.is-sortable) pds-icon{-webkit-margin-start:var(--pine-dimension-2xs);margin-inline-start:var(--pine-dimension-2xs);-webkit-padding-before:2px;padding-block-start:2px;position:absolute}:host(.is-sortable:hover),:host(.is-active){color:var(--pine-color-text-strong)}:host(.pds-table-head-cell--align-start){text-align:start}:host(.pds-table-head-cell--align-center){text-align:center}:host(.pds-table-head-cell--align-end){text-align:end}:host(.pds-table-head-cell--align-justify){text-align:justify}";var PdsTableHeadCell=function(){function t(t){var e=this;registerInstance(this,t);this.pdsTableSort=createEvent(this,"pdsTableSort");this.scrollContainer=null;this.setupRetries=0;this.sortingDirection="asc";this.tableScrolling=false;this.isSelected=false;this.hasHeadBorder=false;this.hasHeadBackground=false;this.isActive=false;this.handleScroll=function(){if(!e.scrollContainer){return}try{e.tableScrolling=isScrolledFromInlineStart(e.scrollContainer)}catch(t){console.warn("Scroll handler error:",t)}};this.toggleSort=function(){if(e.sortable){if(!e.tableRef){return}var t=e.hostElement.innerText.trim();e.sortingDirection=e.sortingDirection==="asc"?"desc":"asc";e.tableRef.querySelectorAll("pds-table-head-cell").forEach((function(t){return __awaiter(e,void 0,void 0,(function(){var e;return __generator(this,(function(i){switch(i.label){case 0:if(!(t!==this.hostElement))return[3,2];e=t;return[4,e.clearActiveSort()];case 1:i.sent();i.label=2;case 2:return[2]}}))}))}));e.isActive=true;e.hostElement.classList.add("is-active");e.pdsTableSort.emit({column:t,direction:e.sortingDirection})}}}t.prototype.setActiveSort=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){if(!this.sortable)return[2];this.sortingDirection=t;this.isActive=true;this.hostElement.classList.add("is-active");return[2]}))}))};t.prototype.clearActiveSort=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.isActive=false;this.hostElement.classList.remove("is-active");return[2]}))}))};t.prototype.componentWillLoad=function(){this.tableRef=this.hostElement.closest("pds-table");var t=this.hostElement.closest("pds-table-head");if(t){this.hasHeadBorder=t.hasAttribute("border");this.hasHeadBackground=t.hasAttribute("background")}};t.prototype.componentDidLoad=function(){var t=this;if(this.tableRef&&this.tableRef.responsive&&this.tableRef.fixedColumn){this.setupScrollListener()}var e=this.hostElement.closest("pds-table-head");if(e&&typeof MutationObserver!=="undefined"){if(this.headObserver){this.headObserver.disconnect()}this.headObserver=new MutationObserver((function(){t.hasHeadBorder=e.hasAttribute("border");t.hasHeadBackground=e.hasAttribute("background")}));this.headObserver.observe(e,{attributes:true,attributeFilter:["border","background"]})}};t.prototype.disconnectedCallback=function(){this.cleanupScrollListener();if(this.headObserver){this.headObserver.disconnect()}};t.prototype.setupScrollListener=function(){var t=this;var e;if(!this.tableRef)return;var i=(e=this.tableRef.shadowRoot)===null||e===void 0?void 0:e.querySelector(".pds-table-responsive-container");if(i){this.scrollContainer=i;this.scrollContainer.addEventListener("scroll",this.handleScroll,{passive:true});this.handleScroll();this.setupRetries=0}else{this.setupTimer=window.setTimeout((function(){if(t.scrollContainer)return;t.setupRetries=(t.setupRetries||0)+1;if(t.setupRetries<=50){t.setupScrollListener()}else{console.warn("Failed to find responsive container after 50 attempts")}}),100)}};t.prototype.cleanupScrollListener=function(){if(this.scrollContainer){this.scrollContainer.removeEventListener("scroll",this.handleScroll);this.scrollContainer=null}if(this.setupTimer!==undefined){window.clearTimeout(this.setupTimer);this.setupTimer=undefined}this.setupRetries=0};t.prototype.classNames=function(){var t=[];if(this.tableRef&&this.tableRef.compact){t.push("is-compact")}if(this.cellAlign){t.push("pds-table-head-cell--align-".concat(this.cellAlign))}if(this.sortable){t.push("is-sortable")}if(this.sortable&&this.sortingDirection!==null){t.push("sort-"+this.sortingDirection)}if(this.tableRef&&this.tableRef.fixedColumn&&this.tableScrolling){t.push("has-scrolled")}if(this.hasHeadBackground){t.push("has-head-background")}if(this.hasHeadBorder){t.push("has-head-border")}return t.join(" ")};t.prototype.render=function(){return h(Host,{key:"e0a30c326b81e0cc3fa8c0392b61f2a6625aad71",class:this.classNames(),role:"columnheader",onClick:this.toggleSort,part:"head-cell",style:this.tableRef&&this.tableRef.fixedColumn&&this.tableRef.selectable?{"--fixed-cell-position":"40px"}:{}},h("slot",{key:"3d0012983b2b552e4e61a3d84717afb9de8e572f"}),this.sortable&&this.isActive&&h("pds-icon",{key:"326607f90b12ecc26a731dc696d0a3b8ebb0960c",icon:this.sortingDirection==="asc"?upSmall:downSmall,part:"sort-icon"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTableHeadCell.style=pdsTableHeadCellCss;export{PdsTableHeadCell as pds_table_head_cell};
2
2
  //# sourceMappingURL=pds-table-head-cell.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pds-table-head-cell.entry.js","sources":["src/components/pds-table/pds-table-head-cell/pds-table-head-cell.scss?tag=pds-table-head-cell&encapsulation=shadow","src/components/pds-table/pds-table-head-cell/pds-table-head-cell.tsx"],"sourcesContent":[":host {\n --border-head-cell-default: var(--pine-border-width-thin) solid var(--pine-color-border-subtle);\n\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-default: 3px 3px 6px -2px rgba(0, 0, 0, 0.1);\n\n border-block-end: var(--border-head-cell-default);\n color: var(--pine-color-text);\n display: table-cell;\n font-family: var(--pine-font-family-body);\n font-size: var(--pine-font-size);\n font-weight: var(--pine-font-weight-regular);\n letter-spacing: var(--pine-letter-spacing);\n line-height: var(--pine-line-height-body);\n padding: var(--pine-dimension-sm);\n position: relative;\n text-align: start;\n vertical-align: inherit;\n}\n\n:host(.is-compact) {\n padding-block: var(--pine-dimension-2xs)\n}\n\n:host(.is-fixed) {\n background: var(--pine-color-background-container);\n left: var(--pine-dimension-none);\n position: sticky;\n z-index: var(--pine-z-index-raised);\n}\n\n// When parent table-head has background, fixed cells should inherit it\n:host(.is-fixed.has-head-background) {\n background-color: var(--pine-color-background-subtle);\n}\n\n// When parent table-head has border prop, add top border (bottom already set in :host)\n:host(.has-head-border) {\n border-block-start: var(--border-head-cell-default);\n}\n\n// box shadow when table has scrolled and cell is fixed\n:host(.has-scrolled.is-fixed) {\n box-shadow: var(--box-shadow-default);\n}\n\n:host(.is-sortable) {\n cursor: pointer;\n\n pds-icon {\n margin-inline-start: var(--pine-dimension-2xs);\n padding-block-start: 2px;\n position: absolute;\n }\n}\n\n:host(.is-sortable:hover),\n:host(.is-active) {\n color: var(--pine-color-text-strong);\n}\n\n// Text Alignment\n:host(.pds-table-head-cell--align-start) {\n text-align: start;\n}\n\n:host(.pds-table-head-cell--align-center) {\n text-align: center;\n}\n\n:host(.pds-table-head-cell--align-end) {\n text-align: end;\n}\n\n:host(.pds-table-head-cell--align-justify) {\n text-align: justify;\n}\n","import { Component, Element, Host, Prop, h, Event, EventEmitter, State, Method } from '@stencil/core';\n\nimport { downSmall, upSmall } from '@pine-ds/icons/icons';\n\n@Component({\n tag: 'pds-table-head-cell',\n styleUrls: ['pds-table-head-cell.scss'],\n shadow: true,\n})\nexport class PdsTableHeadCell {\n @Element() hostElement: HTMLPdsTableHeadCellElement;\n private tableRef: HTMLPdsTableElement;\n private scrollContainer: HTMLElement | null = null;\n private setupTimer: number | undefined;\n private setupRetries: number = 0;\n private headObserver?: MutationObserver;\n\n /**\n * Sets the text alignment within the head cell.\n */\n @Prop() cellAlign?: 'start' | 'center' | 'end' | 'justify';\n\n /**\n * Determines whether the table column is sortable when set to `true`.\n */\n @Prop() sortable: boolean;\n\n /**\n * Event emitted to signal that a table column header has been sorted, providing information about the sorted column's name and sorting direction.\n */\n @Event() pdsTableSort: EventEmitter<{ column: string; direction: string }>;\n\n /**\n * The direction of sorting.\n */\n @State() private sortingDirection: 'asc' | 'desc' = 'asc';\n\n /**\n * Determines if the table is currently scrolling.\n * @defaultValue false\n */\n @State() private tableScrolling: boolean = false;\n\n /**\n * Determines if the table row is currently selected.\n * @defaultValue false\n */\n @State() isSelected: boolean = false;\n\n /**\n * Determines if the parent table-head has the border attribute.\n * @defaultValue false\n */\n @State() private hasHeadBorder: boolean = false;\n\n /**\n * Determines if the parent table-head has the background attribute.\n * @defaultValue false\n */\n @State() private hasHeadBackground: boolean = false;\n\n /**\n * Determines if this column is the currently active sorted column.\n * @defaultValue false\n */\n @State() private isActive: boolean = false;\n\n /**\n * Programmatically sets this column as the active sort column with the specified direction.\n * Used by pds-table to apply a default sort on initial load.\n * @param direction - The sort direction to apply ('asc' or 'desc')\n */\n @Method()\n async setActiveSort(direction: 'asc' | 'desc') {\n if (!this.sortable) return;\n\n this.sortingDirection = direction;\n this.isActive = true;\n this.hostElement.classList.add('is-active');\n }\n\n /**\n * Clears the active sort state from this column.\n * Used internally when another column becomes active.\n */\n @Method()\n async clearActiveSort() {\n this.isActive = false;\n this.hostElement.classList.remove('is-active');\n }\n\n componentWillLoad() {\n // Set initial references and state before first render\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n\n const tableHead = this.hostElement.closest('pds-table-head') as HTMLElement;\n if (tableHead) {\n this.hasHeadBorder = tableHead.hasAttribute('border');\n this.hasHeadBackground = tableHead.hasAttribute('background');\n }\n }\n\n componentDidLoad() {\n if (this.tableRef && this.tableRef.responsive && this.tableRef.fixedColumn) {\n // For responsive tables with fixed columns, set up scroll detection\n // This enables the first column header to show a shadow when the table is scrolled horizontally\n this.setupScrollListener();\n }\n\n // Watch for changes to the parent table-head's border and background attributes\n const tableHead = this.hostElement.closest('pds-table-head') as HTMLElement;\n if (tableHead && typeof MutationObserver !== 'undefined') {\n // Defensive guard: disconnect existing observer before creating a new one\n if (this.headObserver) {\n this.headObserver.disconnect();\n }\n\n this.headObserver = new MutationObserver(() => {\n // Update state when border or background attributes change\n this.hasHeadBorder = tableHead.hasAttribute('border');\n this.hasHeadBackground = tableHead.hasAttribute('background');\n });\n\n this.headObserver.observe(tableHead, {\n attributes: true,\n attributeFilter: ['border', 'background']\n });\n }\n }\n\n disconnectedCallback() {\n this.cleanupScrollListener();\n\n if (this.headObserver) {\n this.headObserver.disconnect();\n }\n }\n\n\n private setupScrollListener() {\n if (!this.tableRef) return;\n\n // Query shadowRoot once and cache the container\n const container = this.tableRef.shadowRoot?.querySelector('.pds-table-responsive-container') as HTMLElement;\n\n if (container) {\n // Container available immediately\n this.scrollContainer = container;\n this.scrollContainer.addEventListener('scroll', this.handleScroll, { passive: true });\n this.handleScroll(); // Initial check\n this.setupRetries = 0; // Reset counter on success\n } else {\n // Container not ready, set up timer for retry with bounds\n this.setupTimer = window.setTimeout(() => {\n if (this.scrollContainer) return; // Already found\n this.setupRetries = (this.setupRetries || 0) + 1;\n if (this.setupRetries <= 50) {\n this.setupScrollListener();\n } else {\n console.warn('Failed to find responsive container after 50 attempts');\n }\n }, 100);\n }\n }\n\n private cleanupScrollListener() {\n if (this.scrollContainer) {\n this.scrollContainer.removeEventListener('scroll', this.handleScroll);\n this.scrollContainer = null;\n }\n\n if (this.setupTimer !== undefined) {\n window.clearTimeout(this.setupTimer);\n this.setupTimer = undefined;\n }\n\n this.setupRetries = 0; // Reset retry counter\n }\n\n /**\n * Handles scroll events to update fixed column shadow state.\n * Updates the tableScrolling state to control CSS classes for fixed column shadows.\n * @private\n */\n private handleScroll = () => {\n if (!this.scrollContainer) {\n return;\n }\n\n try {\n this.tableScrolling = this.scrollContainer.scrollLeft > 0;\n } catch (error) {\n console.warn('Scroll handler error:', error);\n }\n };\n\n private toggleSort = () => {\n if (this.sortable) {\n // Guard: return early if tableRef is not available\n if (!this.tableRef) {\n return;\n }\n\n const column = this.hostElement.innerText.trim();\n \n // Always toggle the direction (preserves original behavior)\n this.sortingDirection = this.sortingDirection === 'asc' ? 'desc' : 'asc';\n \n // Reset all OTHER head cells to inactive state (skip the current one)\n this.tableRef.querySelectorAll('pds-table-head-cell').forEach(async (headCell) => {\n // Skip clearing the current cell\n if (headCell !== this.hostElement) {\n const headCellComponent = headCell as HTMLPdsTableHeadCellElement;\n await headCellComponent.clearActiveSort();\n }\n });\n \n // Mark this column as active\n this.isActive = true;\n this.hostElement.classList.add('is-active');\n\n // Emit the sort event with the current direction\n this.pdsTableSort.emit({ column, direction: this.sortingDirection });\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.tableRef && this.tableRef.compact) {\n classNames.push('is-compact');\n }\n\n if (this.cellAlign) {\n classNames.push(`pds-table-head-cell--align-${this.cellAlign}`);\n }\n\n if (this.sortable) {\n classNames.push('is-sortable');\n }\n\n if (this.sortable && this.sortingDirection !== null) {\n classNames.push('sort-' + this.sortingDirection);\n }\n\n if (this.tableRef && this.tableRef.fixedColumn && this.tableScrolling) {\n classNames.push('has-scrolled');\n }\n\n if (this.hasHeadBackground) {\n classNames.push('has-head-background');\n }\n\n if (this.hasHeadBorder) {\n classNames.push('has-head-border');\n }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"columnheader\"\n onClick={this.toggleSort}\n part=\"head-cell\"\n style={\n this.tableRef &&\n this.tableRef.fixedColumn &&\n this.tableRef.selectable\n ? { '--fixed-cell-position': '40px' }\n : {}\n }\n >\n <slot></slot>\n {this.sortable && this.isActive && (\n <pds-icon icon={this.sortingDirection === 'asc' ? upSmall : downSmall} part=\"sort-icon\" />\n )}\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;AAAA,MAAM,mBAAmB,GAAG,yqDAAyqD;;MCSxrD,gBAAgB,GAAA,MAAA;AAL7B,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAQU,QAAA,IAAe,CAAA,eAAA,GAAuB,IAAI;AAE1C,QAAA,IAAY,CAAA,YAAA,GAAW,CAAC;AAkBhC;;AAEG;AACc,QAAA,IAAgB,CAAA,gBAAA,GAA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ag=pds-table-head-cell&encapsulation=shadow","src/components/pds-table/pds-table-head-cell/pds-table-head-cell.tsx"],"sourcesContent":[":host {\n --border-head-cell-default: var(--pine-border-width-thin) solid var(--pine-color-border-subtle);\n\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-default: 3px 3px 6px -2px rgba(0, 0, 0, 0.1);\n\n border-block-end: var(--border-head-cell-default);\n color: var(--pine-color-text);\n display: table-cell;\n font-family: var(--pine-font-family-body);\n font-size: var(--pine-font-size);\n font-weight: var(--pine-font-weight-regular);\n letter-spacing: var(--pine-letter-spacing);\n line-height: var(--pine-line-height-body);\n padding: var(--pine-dimension-sm);\n position: relative;\n text-align: start;\n vertical-align: inherit;\n}\n\n:host(.is-compact) {\n padding-block: var(--pine-dimension-2xs)\n}\n\n:host(.is-fixed) {\n background: var(--pine-color-background-container);\n inset-inline-start: var(--pine-dimension-none);\n position: sticky;\n z-index: var(--pine-z-index-raised);\n}\n\n// When parent table-head has background, fixed cells should inherit it\n:host(.is-fixed.has-head-background) {\n background-color: var(--pine-color-background-subtle);\n}\n\n// When parent table-head has border prop, add top border (bottom already set in :host)\n:host(.has-head-border) {\n border-block-start: var(--border-head-cell-default);\n}\n\n// Flip shadow toward scrollable content when fixed column is on the inline-end edge.\n:host-context([dir='rtl']) {\n /* stylelint-disable-next-line pine-design-system/no-hardcoded-colors */\n --box-shadow-default: -3px 3px 6px -2px rgba(0, 0, 0, 0.1);\n}\n\n// box shadow when table has scrolled and cell is fixed\n:host(.has-scrolled.is-fixed) {\n box-shadow: var(--box-shadow-default);\n}\n\n:host(.is-sortable) {\n cursor: pointer;\n\n pds-icon {\n margin-inline-start: var(--pine-dimension-2xs);\n padding-block-start: 2px;\n position: absolute;\n }\n}\n\n:host(.is-sortable:hover),\n:host(.is-active) {\n color: var(--pine-color-text-strong);\n}\n\n// Text Alignment\n:host(.pds-table-head-cell--align-start) {\n text-align: start;\n}\n\n:host(.pds-table-head-cell--align-center) {\n text-align: center;\n}\n\n:host(.pds-table-head-cell--align-end) {\n text-align: end;\n}\n\n:host(.pds-table-head-cell--align-justify) {\n text-align: justify;\n}\n","import { Component, Element, Host, Prop, h, Event, EventEmitter, State, Method } from '@stencil/core';\n\nimport { downSmall, upSmall } from '@pine-ds/icons/icons';\nimport { isScrolledFromInlineStart } from '../../../utils/scroll';\n\n@Component({\n tag: 'pds-table-head-cell',\n styleUrls: ['pds-table-head-cell.scss'],\n shadow: true,\n})\nexport class PdsTableHeadCell {\n @Element() hostElement: HTMLPdsTableHeadCellElement;\n private tableRef: HTMLPdsTableElement;\n private scrollContainer: HTMLElement | null = null;\n private setupTimer: number | undefined;\n private setupRetries: number = 0;\n private headObserver?: MutationObserver;\n\n /**\n * Sets the text alignment within the head cell.\n */\n @Prop() cellAlign?: 'start' | 'center' | 'end' | 'justify';\n\n /**\n * Determines whether the table column is sortable when set to `true`.\n */\n @Prop() sortable: boolean;\n\n /**\n * Event emitted to signal that a table column header has been sorted, providing information about the sorted column's name and sorting direction.\n */\n @Event() pdsTableSort: EventEmitter<{ column: string; direction: string }>;\n\n /**\n * The direction of sorting.\n */\n @State() private sortingDirection: 'asc' | 'desc' = 'asc';\n\n /**\n * Determines if the table is currently scrolling.\n * @defaultValue false\n */\n @State() private tableScrolling: boolean = false;\n\n /**\n * Determines if the table row is currently selected.\n * @defaultValue false\n */\n @State() isSelected: boolean = false;\n\n /**\n * Determines if the parent table-head has the border attribute.\n * @defaultValue false\n */\n @State() private hasHeadBorder: boolean = false;\n\n /**\n * Determines if the parent table-head has the background attribute.\n * @defaultValue false\n */\n @State() private hasHeadBackground: boolean = false;\n\n /**\n * Determines if this column is the currently active sorted column.\n * @defaultValue false\n */\n @State() private isActive: boolean = false;\n\n /**\n * Programmatically sets this column as the active sort column with the specified direction.\n * Used by pds-table to apply a default sort on initial load.\n * @param direction - The sort direction to apply ('asc' or 'desc')\n */\n @Method()\n async setActiveSort(direction: 'asc' | 'desc') {\n if (!this.sortable) return;\n\n this.sortingDirection = direction;\n this.isActive = true;\n this.hostElement.classList.add('is-active');\n }\n\n /**\n * Clears the active sort state from this column.\n * Used internally when another column becomes active.\n */\n @Method()\n async clearActiveSort() {\n this.isActive = false;\n this.hostElement.classList.remove('is-active');\n }\n\n componentWillLoad() {\n // Set initial references and state before first render\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n\n const tableHead = this.hostElement.closest('pds-table-head') as HTMLElement;\n if (tableHead) {\n this.hasHeadBorder = tableHead.hasAttribute('border');\n this.hasHeadBackground = tableHead.hasAttribute('background');\n }\n }\n\n componentDidLoad() {\n if (this.tableRef && this.tableRef.responsive && this.tableRef.fixedColumn) {\n // For responsive tables with fixed columns, set up scroll detection\n // This enables the first column header to show a shadow when the table is scrolled horizontally\n this.setupScrollListener();\n }\n\n // Watch for changes to the parent table-head's border and background attributes\n const tableHead = this.hostElement.closest('pds-table-head') as HTMLElement;\n if (tableHead && typeof MutationObserver !== 'undefined') {\n // Defensive guard: disconnect existing observer before creating a new one\n if (this.headObserver) {\n this.headObserver.disconnect();\n }\n\n this.headObserver = new MutationObserver(() => {\n // Update state when border or background attributes change\n this.hasHeadBorder = tableHead.hasAttribute('border');\n this.hasHeadBackground = tableHead.hasAttribute('background');\n });\n\n this.headObserver.observe(tableHead, {\n attributes: true,\n attributeFilter: ['border', 'background']\n });\n }\n }\n\n disconnectedCallback() {\n this.cleanupScrollListener();\n\n if (this.headObserver) {\n this.headObserver.disconnect();\n }\n }\n\n\n private setupScrollListener() {\n if (!this.tableRef) return;\n\n // Query shadowRoot once and cache the container\n const container = this.tableRef.shadowRoot?.querySelector('.pds-table-responsive-container') as HTMLElement;\n\n if (container) {\n // Container available immediately\n this.scrollContainer = container;\n this.scrollContainer.addEventListener('scroll', this.handleScroll, { passive: true });\n this.handleScroll(); // Initial check\n this.setupRetries = 0; // Reset counter on success\n } else {\n // Container not ready, set up timer for retry with bounds\n this.setupTimer = window.setTimeout(() => {\n if (this.scrollContainer) return; // Already found\n this.setupRetries = (this.setupRetries || 0) + 1;\n if (this.setupRetries <= 50) {\n this.setupScrollListener();\n } else {\n console.warn('Failed to find responsive container after 50 attempts');\n }\n }, 100);\n }\n }\n\n private cleanupScrollListener() {\n if (this.scrollContainer) {\n this.scrollContainer.removeEventListener('scroll', this.handleScroll);\n this.scrollContainer = null;\n }\n\n if (this.setupTimer !== undefined) {\n window.clearTimeout(this.setupTimer);\n this.setupTimer = undefined;\n }\n\n this.setupRetries = 0; // Reset retry counter\n }\n\n /**\n * Handles scroll events to update fixed column shadow state.\n * Updates the tableScrolling state to control CSS classes for fixed column shadows.\n * @private\n */\n private handleScroll = () => {\n if (!this.scrollContainer) {\n return;\n }\n\n try {\n this.tableScrolling = isScrolledFromInlineStart(this.scrollContainer);\n } catch (error) {\n console.warn('Scroll handler error:', error);\n }\n };\n\n private toggleSort = () => {\n if (this.sortable) {\n // Guard: return early if tableRef is not available\n if (!this.tableRef) {\n return;\n }\n\n const column = this.hostElement.innerText.trim();\n \n // Always toggle the direction (preserves original behavior)\n this.sortingDirection = this.sortingDirection === 'asc' ? 'desc' : 'asc';\n \n // Reset all OTHER head cells to inactive state (skip the current one)\n this.tableRef.querySelectorAll('pds-table-head-cell').forEach(async (headCell) => {\n // Skip clearing the current cell\n if (headCell !== this.hostElement) {\n const headCellComponent = headCell as HTMLPdsTableHeadCellElement;\n await headCellComponent.clearActiveSort();\n }\n });\n \n // Mark this column as active\n this.isActive = true;\n this.hostElement.classList.add('is-active');\n\n // Emit the sort event with the current direction\n this.pdsTableSort.emit({ column, direction: this.sortingDirection });\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.tableRef && this.tableRef.compact) {\n classNames.push('is-compact');\n }\n\n if (this.cellAlign) {\n classNames.push(`pds-table-head-cell--align-${this.cellAlign}`);\n }\n\n if (this.sortable) {\n classNames.push('is-sortable');\n }\n\n if (this.sortable && this.sortingDirection !== null) {\n classNames.push('sort-' + this.sortingDirection);\n }\n\n if (this.tableRef && this.tableRef.fixedColumn && this.tableScrolling) {\n classNames.push('has-scrolled');\n }\n\n if (this.hasHeadBackground) {\n classNames.push('has-head-background');\n }\n\n if (this.hasHeadBorder) {\n classNames.push('has-head-border');\n }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"columnheader\"\n onClick={this.toggleSort}\n part=\"head-cell\"\n style={\n this.tableRef &&\n this.tableRef.fixedColumn &&\n this.tableRef.selectable\n ? { '--fixed-cell-position': '40px' }\n : {}\n }\n >\n <slot></slot>\n {this.sortable && this.isActive && (\n <pds-icon icon={this.sortingDirection === 'asc' ? upSmall : downSmall} part=\"sort-icon\" />\n )}\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;AAAA,MAAM,mBAAmB,GAAG,0wDAA0wD;;MCUzxD,gBAAgB,GAAA,MAAA;AAL7B,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAQU,QAAA,IAAe,CAAA,eAAA,GAAuB,IAAI;AAE1C,QAAA,IAAY,CAAA,YAAA,GAAW,CAAC;AAkBhC;;AAEG;AACc,QAAA,IAAgB,CAAA,gBAAA,GAAmB,KAAK;AAEzD;;;AAGG;AACc,QAAA,IAAc,CAAA,cAAA,GAAY,KAAK;AAEhD;;;AAGG;AACM,QAAA,IAAU,CAAA,UAAA,GAAY,KAAK;AAEpC;;;AAGG;AACc,QAAA,IAAa,CAAA,aAAA,GAAY,KAAK;AAE/C;;;AAGG;AACc,QAAA,IAAiB,CAAA,iBAAA,GAAY,KAAK;AAEnD;;;AAGG;AACc,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AAkH1C;;;;AAIG;AACK,QAAA,IAAY,CAAA,YAAA,GAAG,MAAK;AAC1B,YAAA,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE;gBACzB;;AAGF,YAAA,IAAI;gBACF,IAAI,CAAC,cAAc,GAAG,yBAAyB,CAAC,IAAI,CAAC,eAAe,CAAC;;YACrE,OAAO,KAAK,EAAE;AACd,gBAAA,OAAO,C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CAAA,EACH,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,EACxB,IAAI,EAAC,cAAc,EACnB,OAAO,EAAE,IAAI,CAAC,UAAU,EACxB,IAAI,EAAC,WAAW,EAChB,KAAK,EACH,IAAI,CAAC,QAAQ;gBACb,IAAI,CAAC,QAAQ,CAAC,WAAW;gBACzB,IAAI,CAAC,QAAQ,CAAC;AACZ,kBAAE,EAAE,uBAAuB,EAAE,MAAM;kBACjC,EAAE,EAAA,EAGR,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,EACZ,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,KAC7B,CAAA,CAAA,UAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAU,IAAI,EAAE,IAAI,CAAC,gBAAgB,KAAK,KAAK,GAAG,OAAO,GAAG,SAAS,EAAE,IAAI,EAAC,WAAW,EAAA,CAAG,CAC3F,CACI;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{c as closest}from"./closest-DnUJodVd.js";var pdsTableHeadCss=":host{--border-head-default:var(--pine-border-width-thin) solid var(--pine-color-background-subtle);border-color:inherit;-webkit-box-sizing:border-box;box-sizing:border-box;display:table-header-group;vertical-align:middle}:host::part(checkbox-cell){background-color:var(--pine-color-background-container);inset-inline-start:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host pds-table-checkbox-cell{-webkit-border-after:var(--border-head-default);border-block-end:var(--border-head-default)}:host([border]){-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);-webkit-border-before:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-start:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host([border]) pds-table-head-cell{-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);-webkit-border-before:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-start:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host([background]){background-color:var(--pine-color-background-subtle)}:host([background]) pds-table-head-cell{background-color:var(--pine-color-background-subtle)}";var PdsTableHead=function(){function e(e){var r=this;registerInstance(this,e);this.pdsTableSelectAll=createEvent(this,"pdsTableSelectAll");this.border=false;this.background=false;this.generateUniqueId=function(){var e=Math.random().toString(36).substring(2,8);var r=(new Date).toISOString().replace(/[:.]/g,"-");var t="".concat(e,"-").concat(r);return t};this.handleInput=function(e){r.isSelected=!e.target.checked;r.handleSelect(r.isSelected)};this.handleSelect=function(e){r.indeterminate=false;if(closest("pds-table-head",r.hostElement)){r.pdsTableSelectAll.emit({isSelected:e})}}}e.prototype.componentWillLoad=function(){if(this.isSelected){this.handleSelect(this.isSelected)}};e.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table");if(this.tableRef&&this.tableRef.fixedColumn){var e=this.hostElement.querySelector("pds-table-head-cell:first-child");e===null||e===void 0?void 0:e.classList.add("is-fixed")}};e.prototype.render=function(){return h(Host,{key:"d5d5906bdb23794b911ecd5904a4cc58aa5380d6",role:"row",part:"head"},this.tableRef&&this.tableRef.selectable&&h("pds-table-head-cell",{key:"85df57fb4371e4fba855e16ce62c8329b49e08cf",part:this.tableRef.selectable?"checkbox-cell":""},!this.tableRef.disableSelectAll&&h("pds-checkbox",{key:"92bd5565463e29d249d1ac71d9dc0d000f3eea79",componentId:this.generateUniqueId(),indeterminate:this.indeterminate,onInput:this.handleInput,label:"Select All Rows",hideLabel:true,checked:this.isSelected,part:"select-all-checkbox"})),h("slot",{key:"494dc0395da229a264c38540479f36967601cc26"}))};Object.defineProperty(e.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();PdsTableHead.style=pdsTableHeadCss;export{PdsTableHead as pds_table_head};
1
+ import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{c as closest}from"./closest-DnUJodVd.js";var pdsTableHeadCss=":host{--border-head-default:var(--pine-border-width-thin) solid var(--pine-color-background-subtle);border-color:inherit;-webkit-box-sizing:border-box;box-sizing:border-box;display:table-header-group;vertical-align:middle}:host::part(checkbox-cell){background-color:var(--pine-color-background-container);inset-inline-start:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host pds-table-checkbox-cell{-webkit-border-after:var(--border-head-default);border-block-end:var(--border-head-default)}:host([border]){-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);-webkit-border-before:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-start:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host([border]) pds-table-head-cell{-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);-webkit-border-before:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-start:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host([background]){background-color:var(--pine-color-background-subtle)}:host([background]) pds-table-head-cell{background-color:var(--pine-color-background-subtle)}";var PdsTableHead=function(){function e(e){var r=this;registerInstance(this,e);this.pdsTableSelectAll=createEvent(this,"pdsTableSelectAll");this.border=false;this.background=false;this.generateUniqueId=function(){var e=Math.random().toString(36).substring(2,8);var r=(new Date).toISOString().replace(/[:.]/g,"-");var t="".concat(e,"-").concat(r);return t};this.handleInput=function(e){r.isSelected=!e.target.checked;r.handleSelect(r.isSelected)};this.handleSelect=function(e){r.indeterminate=false;if(closest("pds-table-head",r.hostElement)){r.pdsTableSelectAll.emit({isSelected:e})}}}e.prototype.componentWillLoad=function(){if(this.isSelected){this.handleSelect(this.isSelected)}};e.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table");if(this.tableRef&&this.tableRef.fixedColumn){var e=this.hostElement.querySelector("pds-table-head-cell:first-child");e===null||e===void 0?void 0:e.classList.add("is-fixed")}};e.prototype.render=function(){return h(Host,{key:"d5d5906bdb23794b911ecd5904a4cc58aa5380d6",role:"row",part:"head"},this.tableRef&&this.tableRef.selectable&&h("pds-table-head-cell",{key:"85df57fb4371e4fba855e16ce62c8329b49e08cf",part:this.tableRef.selectable?"checkbox-cell":""},!this.tableRef.disableSelectAll&&h("pds-checkbox",{key:"92bd5565463e29d249d1ac71d9dc0d000f3eea79",componentId:this.generateUniqueId(),indeterminate:this.indeterminate,onInput:this.handleInput,label:"Select All Rows",hideLabel:true,checked:this.isSelected,part:"select-all-checkbox"})),h("slot",{key:"494dc0395da229a264c38540479f36967601cc26"}))};Object.defineProperty(e.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();PdsTableHead.style=pdsTableHeadCss;export{PdsTableHead as pds_table_head};
2
2
  //# sourceMappingURL=pds-table-head.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";import{c as closest}from"./closest-DnUJodVd.js";var pdsTableRowCss=":host{--color-background-interactive:var(--pine-color-background-subtle);border-color:inherit;display:table-row;vertical-align:inherit}:host::part(checkbox-cell){background-color:var(--pine-color-background-container);inset-inline-start:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host(:hover),:host(:hover)::part(checkbox-cell),:host(:hover) ::slotted(pds-table-cell),:host(.is-selected),:host(.is-selected)::part(checkbox-cell),:host(.is-selected) ::slotted(pds-table-cell){background:var(--color-background-interactive)}:host(.has-divider) ::slotted(pds-table-cell),:host(.has-divider) pds-table-cell{-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host(.has-divider.is-last-row) ::slotted(pds-table-cell),:host(.has-divider.is-last-row) pds-table-cell{-webkit-border-after:0;border-block-end:0}";var PdsTableRow=function(){function t(t){var e=this;registerInstance(this,t);this.pdsTableRowSelected=createEvent(this,"pdsTableRowSelected");this.observer=null;this.bodyObserver=null;this.hasDivider=false;this.isLastRow=false;this.handleCheckboxChange=function(t){e.isSelected=t.detail.checked;e.handleSelect(e.isSelected)};this.handleSelect=function(t){e.indeterminate=false;if(!closest("pds-table-head",e.hostElement)){var i=Array.from(e.hostElement.parentNode.children).indexOf(e.hostElement);e.pdsTableRowSelected.emit({rowIndex:i,isSelected:t})}};this.generateUniqueId=function(){var t=Math.random().toString(36).substring(2,8);var e=(new Date).toISOString().replace(/[:.]/g,"-");var i="".concat(t,"-").concat(e);return i}}t.prototype.classNames=function(){var t=[];if(this.isSelected){t.push("is-selected")}if(this.hasDivider){t.push("has-divider")}if(this.isLastRow){t.push("is-last-row")}return t.join(" ")};t.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table");if(this.tableRef&&this.tableRef.fixedColumn){var t=this.hostElement.querySelector("pds-table-cell");t===null||t===void 0?void 0:t.classList.add("is-fixed")}};t.prototype.componentWillLoad=function(){if(this.isSelected){this.handleSelect(this.isSelected)}};t.prototype.connectedCallback=function(){this.tableRef=this.hostElement.closest("pds-table");this.setupObservers();this.updateDividerState()};t.prototype.disconnectedCallback=function(){this.cleanupObservers()};t.prototype.cleanupObservers=function(){if(this.observer){this.observer.disconnect();this.observer=null}if(this.bodyObserver){this.bodyObserver.disconnect();this.bodyObserver=null}};t.prototype.setupObservers=function(){var t=this;this.cleanupObservers();if(this.tableRef&&typeof MutationObserver!=="undefined"){this.observer=new MutationObserver((function(){t.updateDividerState()}));this.observer.observe(this.tableRef,{attributes:true,attributeFilter:["row-dividers"]})}var e=this.hostElement.closest("pds-table-body");if(e&&typeof MutationObserver!=="undefined"){this.bodyObserver=new MutationObserver((function(){t.updateLastRowState()}));this.bodyObserver.observe(e,{childList:true})}};t.prototype.shouldHaveDivider=function(){if(!this.tableRef){this.tableRef=this.hostElement.closest("pds-table")}return!!(this.tableRef&&this.tableRef.rowDividers)};t.prototype.updateDividerState=function(){this.hasDivider=this.shouldHaveDivider();this.updateLastRowState()};t.prototype.updateLastRowState=function(){if(!this.hasDivider){this.isLastRow=false;return}var t=this.hostElement.closest("pds-table-body");if(t){var e=Array.from(t.querySelectorAll("pds-table-row"));this.isLastRow=e[e.length-1]===this.hostElement}else{this.isLastRow=false}};t.prototype.render=function(){return h(Host,{key:"6bbd8bb7cd1f90de0e418748bf8d3b9240ab0cb8",class:this.classNames(),role:"row",part:"row"},this.tableRef&&this.tableRef.selectable&&h("pds-table-cell",{key:"9a92396654e7cdf819536335ebe95169d4d4c26d",part:this.tableRef.fixedColumn?"checkbox-cell":"checkbox-cell",class:this.tableRef.selectable?"has-checkbox":""},h("pds-checkbox",{key:"bf61a00da4d3c19280aae90d8eaff9515a716c52",componentId:this.generateUniqueId(),onPdsCheckboxChange:this.handleCheckboxChange,indeterminate:this.indeterminate,label:"Select Row",hideLabel:true,checked:this.isSelected,part:"row-checkbox"})),h("slot",{key:"f77887e878913bea5e0ca0a281a639285a65f1c1"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTableRow.style=pdsTableRowCss;export{PdsTableRow as pds_table_row};
1
+ import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{c as closest}from"./closest-DnUJodVd.js";var pdsTableRowCss=":host{--color-background-interactive:var(--pine-color-background-subtle);border-color:inherit;display:table-row;vertical-align:inherit}:host::part(checkbox-cell){background-color:var(--pine-color-background-container);inset-inline-start:var(--pine-dimension-none);position:-webkit-sticky;position:sticky;z-index:var(--pine-z-index-raised)}:host(:hover),:host(:hover)::part(checkbox-cell),:host(:hover) ::slotted(pds-table-cell),:host(.is-selected),:host(.is-selected)::part(checkbox-cell),:host(.is-selected) ::slotted(pds-table-cell){background:var(--color-background-interactive)}:host(.has-divider) ::slotted(pds-table-cell),:host(.has-divider) pds-table-cell{-webkit-border-after:var(--pine-border-width-thin) solid var(--pine-color-border-subtle);border-block-end:var(--pine-border-width-thin) solid var(--pine-color-border-subtle)}:host(.has-divider.is-last-row) ::slotted(pds-table-cell),:host(.has-divider.is-last-row) pds-table-cell{-webkit-border-after:0;border-block-end:0}";var PdsTableRow=function(){function t(t){var e=this;registerInstance(this,t);this.pdsTableRowSelected=createEvent(this,"pdsTableRowSelected");this.observer=null;this.bodyObserver=null;this.hasDivider=false;this.isLastRow=false;this.handleCheckboxChange=function(t){e.isSelected=t.detail.checked;e.handleSelect(e.isSelected)};this.handleSelect=function(t){e.indeterminate=false;if(!closest("pds-table-head",e.hostElement)){var s=Array.from(e.hostElement.parentNode.children).indexOf(e.hostElement);e.pdsTableRowSelected.emit({rowIndex:s,isSelected:t})}};this.generateUniqueId=function(){var t=Math.random().toString(36).substring(2,8);var e=(new Date).toISOString().replace(/[:.]/g,"-");var s="".concat(t,"-").concat(e);return s}}t.prototype.classNames=function(){var t=[];if(this.isSelected){t.push("is-selected")}if(this.hasDivider){t.push("has-divider")}if(this.isLastRow){t.push("is-last-row")}return t.join(" ")};t.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table");if(this.tableRef&&this.tableRef.fixedColumn){var t=this.hostElement.querySelector("pds-table-cell");t===null||t===void 0?void 0:t.classList.add("is-fixed")}};t.prototype.componentWillLoad=function(){if(this.isSelected){this.handleSelect(this.isSelected)}};t.prototype.connectedCallback=function(){this.tableRef=this.hostElement.closest("pds-table");this.setupObservers();this.updateDividerState()};t.prototype.disconnectedCallback=function(){this.cleanupObservers()};t.prototype.cleanupObservers=function(){if(this.observer){this.observer.disconnect();this.observer=null}if(this.bodyObserver){this.bodyObserver.disconnect();this.bodyObserver=null}};t.prototype.setupObservers=function(){var t=this;this.cleanupObservers();if(this.tableRef&&typeof MutationObserver!=="undefined"){this.observer=new MutationObserver((function(){t.updateDividerState()}));this.observer.observe(this.tableRef,{attributes:true,attributeFilter:["row-dividers"]})}var e=this.hostElement.closest("pds-table-body");if(e&&typeof MutationObserver!=="undefined"){this.bodyObserver=new MutationObserver((function(){t.updateLastRowState()}));this.bodyObserver.observe(e,{childList:true})}};t.prototype.shouldHaveDivider=function(){if(!this.tableRef){this.tableRef=this.hostElement.closest("pds-table")}return!!(this.tableRef&&this.tableRef.rowDividers)};t.prototype.updateDividerState=function(){this.hasDivider=this.shouldHaveDivider();this.updateLastRowState()};t.prototype.updateLastRowState=function(){if(!this.hasDivider){this.isLastRow=false;return}var t=this.hostElement.closest("pds-table-body");if(t){var e=Array.from(t.querySelectorAll("pds-table-row"));this.isLastRow=e[e.length-1]===this.hostElement}else{this.isLastRow=false}};t.prototype.render=function(){return h(Host,{key:"6bbd8bb7cd1f90de0e418748bf8d3b9240ab0cb8",class:this.classNames(),role:"row",part:"row"},this.tableRef&&this.tableRef.selectable&&h("pds-table-cell",{key:"9a92396654e7cdf819536335ebe95169d4d4c26d",part:this.tableRef.fixedColumn?"checkbox-cell":"checkbox-cell",class:this.tableRef.selectable?"has-checkbox":""},h("pds-checkbox",{key:"bf61a00da4d3c19280aae90d8eaff9515a716c52",componentId:this.generateUniqueId(),onPdsCheckboxChange:this.handleCheckboxChange,indeterminate:this.indeterminate,label:"Select Row",hideLabel:true,checked:this.isSelected,part:"row-checkbox"})),h("slot",{key:"f77887e878913bea5e0ca0a281a639285a65f1c1"}))};Object.defineProperty(t.prototype,"hostElement",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTableRow.style=pdsTableRowCss;export{PdsTableRow as pds_table_row};
2
2
  //# sourceMappingURL=pds-table-row.entry.js.map
@@ -1,2 +1,2 @@
1
- import{__awaiter,__generator}from"tslib";import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-CO9kz-Pi.js";var pdsTableCss='@charset "UTF-8";:host{--color-background-default:var(--pine-color-background-container);background:var(--color-background-default);border-collapse:separate;border-radius:inherit;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;isolation:isolate;width:100%}:host(:focus-visible){outline:var(--pine-outline-focus)}:host(.pds-table-responsive-host){border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;display:block !important;max-width:100% !important;overflow:hidden !important;position:relative !important;width:100% !important}.pds-table-responsive-container{border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;overflow-x:auto !important;overflow-y:visible !important;position:relative !important;width:100% !important}.pds-table-responsive-wrapper{border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;display:block !important;position:relative !important;width:100% !important}.pds-table-responsive-wrapper .pds-table{display:table !important;min-width:-webkit-max-content !important;min-width:-moz-max-content !important;min-width:max-content !important;table-layout:auto !important;white-space:nowrap !important;width:100% !important}.scroll-shadow-left,.scroll-shadow-right{height:100%;opacity:0;pointer-events:none;position:absolute;top:0;-webkit-transition:opacity 0.1s ease;transition:opacity 0.1s ease;width:4px;z-index:var(--pine-z-index)}.scroll-shadow-left{background:-webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to right, rgba(0, 0, 0, 0.1), transparent);border-bottom-left-radius:inherit;border-top-left-radius:inherit;left:0}.scroll-shadow-right{background:-webkit-gradient(linear, right top, left top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to left, rgba(0, 0, 0, 0.1), transparent);border-bottom-right-radius:inherit;border-top-right-radius:inherit;right:0}';var PdsTable=function(){function t(t){registerInstance(this,t);this.pdsTableSelectAll=createEvent(this,"pdsTableSelectAll");this.scrollContainer=null;this._responsiveHandleScroll=null;this._responsiveHandleResize=null;this._responsiveResizeObserver=null;this._teardownResponsive=null;this.disableSelectAll=false;this.rowDividers=false;this.defaultSortDirection="asc";this.sortingColumn=null;this.sortingDirection="asc"}t.prototype.componentDidLoad=function(){var t=this;if(this.responsive){this.setupResponsiveScrolling()}if(this.defaultSortColumn){requestAnimationFrame((function(){void t.applyDefaultSort().catch((function(t){console.warn("Failed to apply default sort.",t)}))}))}};t.prototype.applyDefaultSort=function(){return __awaiter(this,void 0,void 0,(function(){var t,i,r,e,n;var o=this;return __generator(this,(function(s){switch(s.label){case 0:i=this.defaultSortDirection==="desc"?"desc":"asc";r=Array.from(this.el.querySelectorAll("pds-table-head-cell[sortable]"));e=r.find((function(t){var i;return((i=t.textContent)!==null&&i!==void 0?i:"").trim()===o.defaultSortColumn}));if(!e)return[3,2];n=((t=e.textContent)!==null&&t!==void 0?t:"").trim();this.sortTable(n,i);this.sortingColumn=n;this.sortingDirection=i;return[4,e.setActiveSort(i)];case 1:s.sent();return[3,3];case 2:console.warn('Default sort column "'.concat(this.defaultSortColumn,'" not found.'));s.label=3;case 3:return[2]}}))}))};t.prototype.disconnectedCallback=function(){if(this._teardownResponsive){this._teardownResponsive();this._teardownResponsive=null}};t.prototype.setupResponsiveScrolling=function(){var t=this;var i,r,e;var n=(i=this.el.shadowRoot)===null||i===void 0?void 0:i.querySelector(".pds-table-responsive-container");var o=(r=this.el.shadowRoot)===null||r===void 0?void 0:r.querySelector(".scroll-shadow-left");var s=(e=this.el.shadowRoot)===null||e===void 0?void 0:e.querySelector(".scroll-shadow-right");if(!n||!o||!s)return;this.scrollContainer=n;this._responsiveHandleScroll=function(){if(!t.scrollContainer)return;var i=t.scrollContainer.scrollLeft;var r=t.scrollContainer.scrollWidth-t.scrollContainer.clientWidth;o.style.opacity=i>0&&!t.fixedColumn?"1":"0";s.style.opacity=r>0&&i<r-1?"1":"0"};this.scrollContainer.addEventListener("scroll",this._responsiveHandleScroll,{passive:true});if(typeof window!=="undefined"&&window.ResizeObserver){try{this._responsiveResizeObserver=new ResizeObserver((function(){var i;(i=t._responsiveHandleScroll)===null||i===void 0?void 0:i.call(t)}));this._responsiveResizeObserver.observe(this.scrollContainer)}catch(t){}}if(typeof window!=="undefined"){this._responsiveHandleResize=function(){var i;(i=t._responsiveHandleScroll)===null||i===void 0?void 0:i.call(t)};window.addEventListener("resize",this._responsiveHandleResize)}this._teardownResponsive=function(){if(t.scrollContainer&&t._responsiveHandleScroll){t.scrollContainer.removeEventListener("scroll",t._responsiveHandleScroll);t.scrollContainer=null}if(t._responsiveResizeObserver){t._responsiveResizeObserver.disconnect();t._responsiveResizeObserver=null}if(typeof window!=="undefined"&&t._responsiveHandleResize){window.removeEventListener("resize",t._responsiveHandleResize);t._responsiveHandleResize=null}t._responsiveHandleScroll=null};this._responsiveHandleScroll()};t.prototype.classNames=function(){var t=["pds-table"];if(this.compact){t.push("is-compact")}if(this.responsive){t.push("is-responsive")}return t.join(" ")};t.prototype.sortTable=function(t,i){var r=this.el.querySelector("pds-table-body");if(!r)return;var e=Array.from(r.querySelectorAll("pds-table-row"));var n=Array.from(this.el.querySelectorAll("pds-table-head-cell[sortable]"));var o=n.find((function(i){return i.innerText.trim()===t}));if(!o){console.warn('Column "'.concat(t,'" not found.'));return}var s=n.indexOf(o);e.sort((function(t,r){var e=t.querySelector("pds-table-cell:nth-child(".concat(s+1,")")).textContent.trim();var n=r.querySelector("pds-table-cell:nth-child(".concat(s+1,")")).textContent.trim();if(i==="asc"){return e.localeCompare(n,undefined,{sensitivity:"base"})}else{return n.localeCompare(e,undefined,{sensitivity:"base"})}}));r.innerHTML="";e.forEach((function(t){r.appendChild(t)}))};t.prototype.handleTableSort=function(t){if(t.defaultPrevented)return;var i=t.detail.direction;this.sortTable(t.detail.column,i);this.sortingColumn=t.detail.column;this.sortingDirection=i};t.prototype.handleTableSelectAll=function(t){if(t.defaultPrevented)return;var i=this.el.querySelector("pds-table-body");var r=Array.from(i.querySelectorAll("pds-table-row"));r.forEach((function(i){i.isSelected=t.detail.isSelected}))};t.prototype.handleTableSelect=function(t){return __awaiter(this,void 0,void 0,(function(){var i,r,e,n,o;return __generator(this,(function(s){if(t.defaultPrevented)return[2];i=this.el.querySelectorAll("pds-table-row");r=Array.from(i).every((function(t){return t.isSelected}));e=Array.from(i).every((function(t){return!t.isSelected}));n=this.el.querySelector("pds-table-head");if(!n)return[2];o=n.shadowRoot.querySelector("pds-checkbox");if(o){o.checked=r;o.indeterminate=!r&&!e}return[2]}))}))};t.prototype.render=function(){if(this.responsive){return h(Host,{class:"pds-table is-responsive pds-table-responsive-host",id:this.componentId,role:"grid",selectable:this.selectable,tabindex:"0",part:"table responsive-table"},h("div",{class:"scroll-shadow-left",part:"scroll-shadow-left"}),h("div",{class:"scroll-shadow-right",part:"scroll-shadow-right"}),h("div",{class:"pds-table-responsive-container",part:"responsive-container"},h("div",{class:"pds-table-responsive-wrapper",part:"responsive-wrapper"},h("div",{class:this.classNames(),part:"table-inner"},h("slot",null)))))}return h(Host,{class:this.classNames(),id:this.componentId,role:"grid",selectable:this.selectable,tabindex:"0",part:"table"},h("slot",null))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTable.style=pdsTableCss;export{PdsTable as pds_table};
1
+ import{__awaiter,__generator}from"tslib";import{r as registerInstance,c as createEvent,h,H as Host,a as getElement}from"./index-QYCDCKN2.js";import{g as getScrollOffsetFromStart}from"./scroll-DtgUQhjl.js";var pdsTableCss='@charset "UTF-8";:host{--color-background-default:var(--pine-color-background-container);background:var(--color-background-default);border-collapse:separate;border-radius:inherit;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;isolation:isolate;width:100%}:host(:focus-visible){outline:var(--pine-outline-focus)}:host(.pds-table-responsive-host){border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;display:block !important;max-width:100% !important;overflow:hidden !important;position:relative !important;width:100% !important}.pds-table-responsive-container{border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;overflow-x:auto !important;overflow-y:visible !important;position:relative !important;width:100% !important}.pds-table-responsive-wrapper{border-radius:inherit;-webkit-box-sizing:border-box !important;box-sizing:border-box !important;display:block !important;position:relative !important;width:100% !important}.pds-table-responsive-wrapper .pds-table{display:table !important;min-width:-webkit-max-content !important;min-width:-moz-max-content !important;min-width:max-content !important;table-layout:auto !important;white-space:nowrap !important;width:100% !important}.scroll-shadow-left,.scroll-shadow-right{height:100%;opacity:0;pointer-events:none;position:absolute;top:0;-webkit-transition:opacity 0.1s ease;transition:opacity 0.1s ease;width:4px;z-index:var(--pine-z-index)}.scroll-shadow-left{background:-webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to right, rgba(0, 0, 0, 0.1), transparent);border-end-start-radius:inherit;border-start-start-radius:inherit;inset-inline-start:0}:host-context([dir=rtl]) .scroll-shadow-left{background:-webkit-gradient(linear, right top, left top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to left, rgba(0, 0, 0, 0.1), transparent)}.scroll-shadow-right{background:-webkit-gradient(linear, right top, left top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to left, rgba(0, 0, 0, 0.1), transparent);border-end-end-radius:inherit;border-start-end-radius:inherit;inset-inline-end:0}:host-context([dir=rtl]) .scroll-shadow-right{background:-webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.1)), to(transparent));background:linear-gradient(to right, rgba(0, 0, 0, 0.1), transparent)}';var PdsTable=function(){function t(t){registerInstance(this,t);this.pdsTableSelectAll=createEvent(this,"pdsTableSelectAll");this.scrollContainer=null;this._responsiveHandleScroll=null;this._responsiveHandleResize=null;this._responsiveResizeObserver=null;this._teardownResponsive=null;this.disableSelectAll=false;this.rowDividers=false;this.defaultSortDirection="asc";this.sortingColumn=null;this.sortingDirection="asc"}t.prototype.componentDidLoad=function(){var t=this;if(this.responsive){this.setupResponsiveScrolling()}if(this.defaultSortColumn){requestAnimationFrame((function(){void t.applyDefaultSort().catch((function(t){console.warn("Failed to apply default sort.",t)}))}))}};t.prototype.applyDefaultSort=function(){return __awaiter(this,void 0,void 0,(function(){var t,i,r,e,n;var o=this;return __generator(this,(function(s){switch(s.label){case 0:i=this.defaultSortDirection==="desc"?"desc":"asc";r=Array.from(this.el.querySelectorAll("pds-table-head-cell[sortable]"));e=r.find((function(t){var i;return((i=t.textContent)!==null&&i!==void 0?i:"").trim()===o.defaultSortColumn}));if(!e)return[3,2];n=((t=e.textContent)!==null&&t!==void 0?t:"").trim();this.sortTable(n,i);this.sortingColumn=n;this.sortingDirection=i;return[4,e.setActiveSort(i)];case 1:s.sent();return[3,3];case 2:console.warn('Default sort column "'.concat(this.defaultSortColumn,'" not found.'));s.label=3;case 3:return[2]}}))}))};t.prototype.disconnectedCallback=function(){if(this._teardownResponsive){this._teardownResponsive();this._teardownResponsive=null}};t.prototype.setupResponsiveScrolling=function(){var t=this;var i,r,e;var n=(i=this.el.shadowRoot)===null||i===void 0?void 0:i.querySelector(".pds-table-responsive-container");var o=(r=this.el.shadowRoot)===null||r===void 0?void 0:r.querySelector(".scroll-shadow-left");var s=(e=this.el.shadowRoot)===null||e===void 0?void 0:e.querySelector(".scroll-shadow-right");if(!n||!o||!s)return;this.scrollContainer=n;this._responsiveHandleScroll=function(){if(!t.scrollContainer)return;var i=t.scrollContainer,r=i.scrollWidth,e=i.clientWidth;var n=r-e;var a=getScrollOffsetFromStart(t.scrollContainer);o.style.opacity=a>0&&!t.fixedColumn?"1":"0";s.style.opacity=n>0&&a<n-1?"1":"0"};this.scrollContainer.addEventListener("scroll",this._responsiveHandleScroll,{passive:true});if(typeof window!=="undefined"&&window.ResizeObserver){try{this._responsiveResizeObserver=new ResizeObserver((function(){var i;(i=t._responsiveHandleScroll)===null||i===void 0?void 0:i.call(t)}));this._responsiveResizeObserver.observe(this.scrollContainer)}catch(t){}}if(typeof window!=="undefined"){this._responsiveHandleResize=function(){var i;(i=t._responsiveHandleScroll)===null||i===void 0?void 0:i.call(t)};window.addEventListener("resize",this._responsiveHandleResize)}this._teardownResponsive=function(){if(t.scrollContainer&&t._responsiveHandleScroll){t.scrollContainer.removeEventListener("scroll",t._responsiveHandleScroll);t.scrollContainer=null}if(t._responsiveResizeObserver){t._responsiveResizeObserver.disconnect();t._responsiveResizeObserver=null}if(typeof window!=="undefined"&&t._responsiveHandleResize){window.removeEventListener("resize",t._responsiveHandleResize);t._responsiveHandleResize=null}t._responsiveHandleScroll=null};this._responsiveHandleScroll()};t.prototype.classNames=function(){var t=["pds-table"];if(this.compact){t.push("is-compact")}if(this.responsive){t.push("is-responsive")}return t.join(" ")};t.prototype.sortTable=function(t,i){var r=this.el.querySelector("pds-table-body");if(!r)return;var e=Array.from(r.querySelectorAll("pds-table-row"));var n=Array.from(this.el.querySelectorAll("pds-table-head-cell[sortable]"));var o=n.find((function(i){return i.innerText.trim()===t}));if(!o){console.warn('Column "'.concat(t,'" not found.'));return}var s=n.indexOf(o);e.sort((function(t,r){var e=t.querySelector("pds-table-cell:nth-child(".concat(s+1,")")).textContent.trim();var n=r.querySelector("pds-table-cell:nth-child(".concat(s+1,")")).textContent.trim();if(i==="asc"){return e.localeCompare(n,undefined,{sensitivity:"base"})}else{return n.localeCompare(e,undefined,{sensitivity:"base"})}}));r.innerHTML="";e.forEach((function(t){r.appendChild(t)}))};t.prototype.handleTableSort=function(t){if(t.defaultPrevented)return;var i=t.detail.direction;this.sortTable(t.detail.column,i);this.sortingColumn=t.detail.column;this.sortingDirection=i};t.prototype.handleTableSelectAll=function(t){if(t.defaultPrevented)return;var i=this.el.querySelector("pds-table-body");var r=Array.from(i.querySelectorAll("pds-table-row"));r.forEach((function(i){i.isSelected=t.detail.isSelected}))};t.prototype.handleTableSelect=function(t){return __awaiter(this,void 0,void 0,(function(){var i,r,e,n,o;return __generator(this,(function(s){if(t.defaultPrevented)return[2];i=this.el.querySelectorAll("pds-table-row");r=Array.from(i).every((function(t){return t.isSelected}));e=Array.from(i).every((function(t){return!t.isSelected}));n=this.el.querySelector("pds-table-head");if(!n)return[2];o=n.shadowRoot.querySelector("pds-checkbox");if(o){o.checked=r;o.indeterminate=!r&&!e}return[2]}))}))};t.prototype.render=function(){if(this.responsive){return h(Host,{class:"pds-table is-responsive pds-table-responsive-host",id:this.componentId,role:"grid",selectable:this.selectable,tabindex:"0",part:"table responsive-table"},h("div",{class:"scroll-shadow-left",part:"scroll-shadow-left"}),h("div",{class:"scroll-shadow-right",part:"scroll-shadow-right"}),h("div",{class:"pds-table-responsive-container",part:"responsive-container"},h("div",{class:"pds-table-responsive-wrapper",part:"responsive-wrapper"},h("div",{class:this.classNames(),part:"table-inner"},h("slot",null)))))}return h(Host,{class:this.classNames(),id:this.componentId,role:"grid",selectable:this.selectable,tabindex:"0",part:"table"},h("slot",null))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();PdsTable.style=pdsTableCss;export{PdsTable as pds_table};
2
2
  //# sourceMappingURL=pds-table.entry.js.map