@pine-ds/core 3.2.0 → 3.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (448) hide show
  1. package/components/index2.js +1 -1
  2. package/components/index2.js.map +1 -1
  3. package/components/mock-pds-modal.js +1 -1
  4. package/components/pds-button2.js +1 -1
  5. package/components/pds-button2.js.map +1 -1
  6. package/components/pds-chip.js +21 -6
  7. package/components/pds-chip.js.map +1 -1
  8. package/components/pds-input.js +98 -21
  9. package/components/pds-input.js.map +1 -1
  10. package/components/pds-link2.js +2 -2
  11. package/components/pds-loader2.js +1 -1
  12. package/components/pds-modal-content.js +2 -2
  13. package/components/pds-modal-footer.js +1 -1
  14. package/components/pds-modal-header.js +1 -1
  15. package/components/pds-modal.js +2 -2
  16. package/components/pds-popover.js +1 -1
  17. package/components/pds-progress.js +1 -1
  18. package/components/pds-radio.js +3 -3
  19. package/components/pds-row.js +1 -1
  20. package/components/pds-select.js +3 -3
  21. package/components/pds-select.js.map +1 -1
  22. package/components/pds-sortable-item.js +1 -1
  23. package/components/pds-sortable.js +1 -1
  24. package/components/pds-switch.js +3 -3
  25. package/components/pds-tab.js +3 -3
  26. package/components/pds-table-body.js +1 -1
  27. package/components/pds-table-cell2.js +2 -2
  28. package/components/pds-table-head-cell2.js +2 -2
  29. package/components/pds-table-head.js +1 -1
  30. package/components/pds-table-row.js +1 -1
  31. package/components/pds-table.js +1 -1
  32. package/components/pds-tabpanel.js +1 -1
  33. package/components/pds-tabs.js +1 -1
  34. package/components/pds-text2.js +1 -1
  35. package/components/pds-textarea.js +4 -4
  36. package/components/pds-toast.js +3 -3
  37. package/components/pds-tooltip.js +17 -1
  38. package/components/pds-tooltip.js.map +1 -1
  39. package/dist/cjs/{index-CG2Rr2io.js → index-B0qLG6KJ.js} +3 -3
  40. package/dist/cjs/index-B0qLG6KJ.js.map +1 -0
  41. package/dist/cjs/loader.cjs.js +1 -1
  42. package/dist/cjs/mock-pds-modal.cjs.entry.js +1 -1
  43. package/dist/cjs/pds-accordion.cjs.entry.js +1 -1
  44. package/dist/cjs/pds-avatar.cjs.entry.js +1 -1
  45. package/dist/cjs/pds-button.cjs.entry.js +2 -2
  46. package/dist/cjs/pds-button.cjs.entry.js.map +1 -1
  47. package/dist/cjs/pds-button.entry.cjs.js.map +1 -1
  48. package/dist/cjs/pds-checkbox.cjs.entry.js +1 -1
  49. package/dist/cjs/pds-chip.cjs.entry.js +21 -7
  50. package/dist/cjs/pds-chip.cjs.entry.js.map +1 -1
  51. package/dist/cjs/pds-chip.entry.cjs.js.map +1 -1
  52. package/dist/cjs/pds-copytext.cjs.entry.js +1 -1
  53. package/dist/cjs/pds-input.cjs.entry.js +88 -21
  54. package/dist/cjs/pds-input.cjs.entry.js.map +1 -1
  55. package/dist/cjs/pds-input.entry.cjs.js.map +1 -1
  56. package/dist/cjs/pds-link.cjs.entry.js +3 -3
  57. package/dist/cjs/pds-loader.cjs.entry.js +1 -1
  58. package/dist/cjs/pds-modal-content.cjs.entry.js +2 -2
  59. package/dist/cjs/pds-modal-footer.cjs.entry.js +1 -1
  60. package/dist/cjs/pds-modal-header.cjs.entry.js +1 -1
  61. package/dist/cjs/pds-modal.cjs.entry.js +2 -2
  62. package/dist/cjs/pds-popover.cjs.entry.js +1 -1
  63. package/dist/cjs/pds-progress.cjs.entry.js +1 -1
  64. package/dist/cjs/pds-radio.cjs.entry.js +4 -4
  65. package/dist/cjs/pds-row.cjs.entry.js +1 -1
  66. package/dist/cjs/pds-select.cjs.entry.js +3 -4
  67. package/dist/cjs/pds-select.cjs.entry.js.map +1 -1
  68. package/dist/cjs/pds-select.entry.cjs.js.map +1 -1
  69. package/dist/cjs/pds-sortable-item.cjs.entry.js +2 -2
  70. package/dist/cjs/pds-sortable.cjs.entry.js +1 -1
  71. package/dist/cjs/pds-switch.cjs.entry.js +4 -4
  72. package/dist/cjs/pds-tab.cjs.entry.js +3 -3
  73. package/dist/cjs/pds-table-body.cjs.entry.js +1 -1
  74. package/dist/cjs/pds-table-cell.cjs.entry.js +2 -2
  75. package/dist/cjs/pds-table-head-cell.cjs.entry.js +3 -3
  76. package/dist/cjs/pds-table-head.cjs.entry.js +1 -1
  77. package/dist/cjs/pds-table-row.cjs.entry.js +1 -1
  78. package/dist/cjs/pds-table.cjs.entry.js +1 -1
  79. package/dist/cjs/pds-tabpanel.cjs.entry.js +1 -1
  80. package/dist/cjs/pds-tabs.cjs.entry.js +1 -1
  81. package/dist/cjs/pds-text.cjs.entry.js +1 -1
  82. package/dist/cjs/pds-textarea.cjs.entry.js +5 -5
  83. package/dist/cjs/pds-toast.cjs.entry.js +3 -3
  84. package/dist/cjs/pds-tooltip.cjs.entry.js +17 -1
  85. package/dist/cjs/pds-tooltip.cjs.entry.js.map +1 -1
  86. package/dist/cjs/pds-tooltip.entry.cjs.js.map +1 -1
  87. package/dist/cjs/pine-core.cjs.js +1 -1
  88. package/dist/collection/components/pds-button/pds-button.css +17 -5
  89. package/dist/collection/components/pds-chip/pds-chip.css +48 -11
  90. package/dist/collection/components/pds-chip/pds-chip.js +42 -9
  91. package/dist/collection/components/pds-chip/pds-chip.js.map +1 -1
  92. package/dist/collection/components/pds-chip/stories/pds-chip.stories.js +17 -0
  93. package/dist/collection/components/pds-input/pds-input.css +167 -43
  94. package/dist/collection/components/pds-input/pds-input.js +212 -21
  95. package/dist/collection/components/pds-input/pds-input.js.map +1 -1
  96. package/dist/collection/components/pds-input/stories/pds-input.stories.js +84 -0
  97. package/dist/collection/components/pds-link/pds-link.js +2 -2
  98. package/dist/collection/components/pds-loader/pds-loader.js +1 -1
  99. package/dist/collection/components/pds-modal/pds-modal-content/pds-modal-content.js +2 -2
  100. package/dist/collection/components/pds-modal/pds-modal-footer/pds-modal-footer.js +1 -1
  101. package/dist/collection/components/pds-modal/pds-modal-header/pds-modal-header.js +1 -1
  102. package/dist/collection/components/pds-modal/pds-modal.js +2 -2
  103. package/dist/collection/components/pds-modal/test/mock-pds-modal.js +1 -1
  104. package/dist/collection/components/pds-popover/pds-popover.js +1 -1
  105. package/dist/collection/components/pds-progress/pds-progress.js +1 -1
  106. package/dist/collection/components/pds-radio/pds-radio.js +3 -3
  107. package/dist/collection/components/pds-row/pds-row.js +1 -1
  108. package/dist/collection/components/pds-select/pds-select.css +34 -4
  109. package/dist/collection/components/pds-select/pds-select.js +20 -2
  110. package/dist/collection/components/pds-select/pds-select.js.map +1 -1
  111. package/dist/collection/components/pds-select/stories/pds-select.stories.js +2 -0
  112. package/dist/collection/components/pds-sortable/pds-sortable-item/pds-sortable-item.js +1 -1
  113. package/dist/collection/components/pds-sortable/pds-sortable.js +1 -1
  114. package/dist/collection/components/pds-switch/pds-switch.js +3 -3
  115. package/dist/collection/components/pds-table/pds-table-body/pds-table-body.js +1 -1
  116. package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.js +2 -2
  117. package/dist/collection/components/pds-table/pds-table-head/pds-table-head.js +1 -1
  118. package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.js +2 -2
  119. package/dist/collection/components/pds-table/pds-table-row/pds-table-row.js +1 -1
  120. package/dist/collection/components/pds-table/pds-table.js +1 -1
  121. package/dist/collection/components/pds-tabs/pds-tab/pds-tab.js +3 -3
  122. package/dist/collection/components/pds-tabs/pds-tabpanel/pds-tabpanel.js +1 -1
  123. package/dist/collection/components/pds-tabs/pds-tabs.js +1 -1
  124. package/dist/collection/components/pds-text/pds-text.js +1 -1
  125. package/dist/collection/components/pds-textarea/pds-textarea.js +4 -4
  126. package/dist/collection/components/pds-toast/pds-toast.js +3 -3
  127. package/dist/collection/components/pds-tooltip/pds-tooltip.js +17 -1
  128. package/dist/collection/components/pds-tooltip/pds-tooltip.js.map +1 -1
  129. package/dist/docs.json +255 -11
  130. package/dist/esm/{index-_4gljHh-.js → index-DpOSrebJ.js} +3 -3
  131. package/dist/esm/index-DpOSrebJ.js.map +1 -0
  132. package/dist/esm/loader.js +1 -1
  133. package/dist/esm/mock-pds-modal.entry.js +1 -1
  134. package/dist/esm/pds-accordion.entry.js +1 -1
  135. package/dist/esm/pds-avatar.entry.js +1 -1
  136. package/dist/esm/pds-button.entry.js +2 -2
  137. package/dist/esm/pds-button.entry.js.map +1 -1
  138. package/dist/esm/pds-checkbox.entry.js +1 -1
  139. package/dist/esm/pds-chip.entry.js +21 -7
  140. package/dist/esm/pds-chip.entry.js.map +1 -1
  141. package/dist/esm/pds-copytext.entry.js +1 -1
  142. package/dist/esm/pds-input.entry.js +88 -21
  143. package/dist/esm/pds-input.entry.js.map +1 -1
  144. package/dist/esm/pds-link.entry.js +3 -3
  145. package/dist/esm/pds-loader.entry.js +1 -1
  146. package/dist/esm/pds-modal-content.entry.js +2 -2
  147. package/dist/esm/pds-modal-footer.entry.js +1 -1
  148. package/dist/esm/pds-modal-header.entry.js +1 -1
  149. package/dist/esm/pds-modal.entry.js +2 -2
  150. package/dist/esm/pds-popover.entry.js +1 -1
  151. package/dist/esm/pds-progress.entry.js +1 -1
  152. package/dist/esm/pds-radio.entry.js +4 -4
  153. package/dist/esm/pds-row.entry.js +1 -1
  154. package/dist/esm/pds-select.entry.js +3 -4
  155. package/dist/esm/pds-select.entry.js.map +1 -1
  156. package/dist/esm/pds-sortable-item.entry.js +2 -2
  157. package/dist/esm/pds-sortable.entry.js +1 -1
  158. package/dist/esm/pds-switch.entry.js +4 -4
  159. package/dist/esm/pds-tab.entry.js +3 -3
  160. package/dist/esm/pds-table-body.entry.js +1 -1
  161. package/dist/esm/pds-table-cell.entry.js +2 -2
  162. package/dist/esm/pds-table-head-cell.entry.js +3 -3
  163. package/dist/esm/pds-table-head.entry.js +1 -1
  164. package/dist/esm/pds-table-row.entry.js +1 -1
  165. package/dist/esm/pds-table.entry.js +1 -1
  166. package/dist/esm/pds-tabpanel.entry.js +1 -1
  167. package/dist/esm/pds-tabs.entry.js +1 -1
  168. package/dist/esm/pds-text.entry.js +1 -1
  169. package/dist/esm/pds-textarea.entry.js +5 -5
  170. package/dist/esm/pds-toast.entry.js +3 -3
  171. package/dist/esm/pds-tooltip.entry.js +17 -1
  172. package/dist/esm/pds-tooltip.entry.js.map +1 -1
  173. package/dist/esm/pine-core.js +1 -1
  174. package/dist/esm-es5/{index-_4gljHh-.js → index-DpOSrebJ.js} +1 -1
  175. package/dist/esm-es5/index-DpOSrebJ.js.map +1 -0
  176. package/dist/esm-es5/loader.js +1 -1
  177. package/dist/esm-es5/mock-pds-modal.entry.js +1 -1
  178. package/dist/esm-es5/pds-accordion.entry.js +1 -1
  179. package/dist/esm-es5/pds-avatar.entry.js +1 -1
  180. package/dist/esm-es5/pds-button.entry.js +1 -1
  181. package/dist/esm-es5/pds-button.entry.js.map +1 -1
  182. package/dist/esm-es5/pds-checkbox.entry.js +1 -1
  183. package/dist/esm-es5/pds-chip.entry.js +1 -1
  184. package/dist/esm-es5/pds-chip.entry.js.map +1 -1
  185. package/dist/esm-es5/pds-copytext.entry.js +1 -1
  186. package/dist/esm-es5/pds-input.entry.js +1 -1
  187. package/dist/esm-es5/pds-input.entry.js.map +1 -1
  188. package/dist/esm-es5/pds-link.entry.js +1 -1
  189. package/dist/esm-es5/pds-loader.entry.js +1 -1
  190. package/dist/esm-es5/pds-modal-content.entry.js +1 -1
  191. package/dist/esm-es5/pds-modal-footer.entry.js +1 -1
  192. package/dist/esm-es5/pds-modal-header.entry.js +1 -1
  193. package/dist/esm-es5/pds-modal.entry.js +1 -1
  194. package/dist/esm-es5/pds-popover.entry.js +1 -1
  195. package/dist/esm-es5/pds-progress.entry.js +1 -1
  196. package/dist/esm-es5/pds-radio.entry.js +1 -1
  197. package/dist/esm-es5/pds-row.entry.js +1 -1
  198. package/dist/esm-es5/pds-select.entry.js +1 -1
  199. package/dist/esm-es5/pds-select.entry.js.map +1 -1
  200. package/dist/esm-es5/pds-sortable-item.entry.js +1 -1
  201. package/dist/esm-es5/pds-sortable.entry.js +1 -1
  202. package/dist/esm-es5/pds-switch.entry.js +1 -1
  203. package/dist/esm-es5/pds-tab.entry.js +1 -1
  204. package/dist/esm-es5/pds-table-body.entry.js +1 -1
  205. package/dist/esm-es5/pds-table-cell.entry.js +1 -1
  206. package/dist/esm-es5/pds-table-head-cell.entry.js +1 -1
  207. package/dist/esm-es5/pds-table-head.entry.js +1 -1
  208. package/dist/esm-es5/pds-table-row.entry.js +1 -1
  209. package/dist/esm-es5/pds-table.entry.js +1 -1
  210. package/dist/esm-es5/pds-tabpanel.entry.js +1 -1
  211. package/dist/esm-es5/pds-tabs.entry.js +1 -1
  212. package/dist/esm-es5/pds-text.entry.js +1 -1
  213. package/dist/esm-es5/pds-textarea.entry.js +1 -1
  214. package/dist/esm-es5/pds-toast.entry.js +1 -1
  215. package/dist/esm-es5/pds-tooltip.entry.js +1 -1
  216. package/dist/esm-es5/pds-tooltip.entry.js.map +1 -1
  217. package/dist/esm-es5/pine-core.js +1 -1
  218. package/dist/pine-core/{p-CV405yTU.system.js.map → p--YvWqEjm.system.js.map} +1 -1
  219. package/dist/pine-core/p-00599bd8.entry.js +2 -0
  220. package/dist/pine-core/p-00599bd8.entry.js.map +1 -0
  221. package/dist/pine-core/{p-833f08f3.entry.js → p-04195bdb.entry.js} +2 -2
  222. package/dist/pine-core/p-065208a1.system.entry.js +2 -0
  223. package/dist/pine-core/p-065208a1.system.entry.js.map +1 -0
  224. package/dist/pine-core/{p-4288c861.entry.js → p-07f45626.entry.js} +2 -2
  225. package/dist/pine-core/{p-0572825b.entry.js → p-0a11384e.entry.js} +2 -2
  226. package/dist/pine-core/{p-28e28f42.system.entry.js → p-0a87e2fc.system.entry.js} +2 -2
  227. package/dist/pine-core/p-0c30661b.system.entry.js +2 -0
  228. package/dist/pine-core/{p-146fcd44.entry.js → p-10e2feff.entry.js} +2 -2
  229. package/dist/pine-core/{p-bd04212c.system.entry.js → p-13481ef5.system.entry.js} +2 -2
  230. package/dist/pine-core/{p-c4294be2.entry.js → p-19c01019.entry.js} +2 -2
  231. package/dist/pine-core/{p-f2c807ac.entry.js → p-1d395d27.entry.js} +2 -2
  232. package/dist/pine-core/{p-4ff0838c.entry.js → p-2007a0b5.entry.js} +2 -2
  233. package/dist/pine-core/{p-78cb1c40.system.entry.js → p-27c0ffda.system.entry.js} +2 -2
  234. package/dist/pine-core/p-35917a1a.entry.js +2 -0
  235. package/dist/pine-core/p-39a31730.system.entry.js +2 -0
  236. package/dist/pine-core/p-39a31730.system.entry.js.map +1 -0
  237. package/dist/pine-core/{p-1b109c01.entry.js → p-3ea415b0.entry.js} +2 -2
  238. package/dist/pine-core/p-44f10d3c.entry.js +2 -0
  239. package/dist/pine-core/p-44f10d3c.entry.js.map +1 -0
  240. package/dist/pine-core/{p-48e76945.system.entry.js → p-4b2aab79.system.entry.js} +2 -2
  241. package/dist/pine-core/{p-77c3a10d.entry.js → p-51cc93b3.entry.js} +2 -2
  242. package/dist/pine-core/{p-83252078.system.entry.js → p-5367f477.system.entry.js} +2 -2
  243. package/dist/pine-core/{p-a2572675.system.entry.js → p-593df966.system.entry.js} +2 -2
  244. package/dist/pine-core/{p-d6ac2862.system.entry.js → p-5a437fcd.system.entry.js} +2 -2
  245. package/dist/pine-core/{p-c0f74199.entry.js → p-60fbeb1c.entry.js} +2 -2
  246. package/dist/pine-core/p-65a875f6.entry.js +2 -0
  247. package/dist/pine-core/{p-30142a25.system.entry.js → p-6a7936e7.system.entry.js} +2 -2
  248. package/dist/pine-core/p-76e35041.entry.js +2 -0
  249. package/dist/pine-core/{p-d1b222f5.entry.js.map → p-76e35041.entry.js.map} +1 -1
  250. package/dist/pine-core/{p-86d388a2.entry.js → p-76f7cf21.entry.js} +2 -2
  251. package/dist/pine-core/{p-121e03ad.system.entry.js → p-78327c08.system.entry.js} +2 -2
  252. package/dist/pine-core/{p-e2dc81c0.entry.js → p-78f29270.entry.js} +2 -2
  253. package/dist/pine-core/{p-83c632f6.system.entry.js → p-79cb7835.system.entry.js} +2 -2
  254. package/dist/pine-core/{p-e9d972db.system.entry.js → p-7bb3a5d4.system.entry.js} +2 -2
  255. package/dist/pine-core/{p-17d3fa8b.entry.js → p-80f36506.entry.js} +2 -2
  256. package/dist/pine-core/{p-f47133fd.entry.js → p-8180b641.entry.js} +2 -2
  257. package/dist/pine-core/{p-a394645a.system.entry.js → p-833b2170.system.entry.js} +2 -2
  258. package/dist/pine-core/{p-83ffc1cc.entry.js → p-86329612.entry.js} +2 -2
  259. package/dist/pine-core/p-8b6b0db7.entry.js +2 -0
  260. package/dist/pine-core/p-8b6b0db7.entry.js.map +1 -0
  261. package/dist/pine-core/{p-cd2cd116.entry.js → p-8f06b020.entry.js} +2 -2
  262. package/dist/pine-core/{p-78fb945e.system.entry.js → p-959c8247.system.entry.js} +2 -2
  263. package/dist/pine-core/{p-f9e01886.system.entry.js → p-96e9774e.system.entry.js} +2 -2
  264. package/dist/pine-core/p-9c01e81b.system.entry.js +2 -0
  265. package/dist/pine-core/p-9db1f179.entry.js +2 -0
  266. package/dist/pine-core/p-9db1f179.entry.js.map +1 -0
  267. package/dist/pine-core/{p-CWtKi9tV.system.js.map → p-A4_UN20E.system.js.map} +1 -1
  268. package/dist/pine-core/{p-C-oNYS10.system.js.map → p-BE1qV1Jc.system.js.map} +1 -1
  269. package/dist/pine-core/{p-BVUeEWjl.system.js.map → p-BEYGfY83.system.js.map} +1 -1
  270. package/dist/pine-core/p-BHp2IZGP.system.js.map +1 -0
  271. package/dist/pine-core/{p-DV_GadHU.system.js.map → p-BISuGf0f.system.js.map} +1 -1
  272. package/dist/pine-core/{p-HBgo7i_E.system.js.map → p-BPQAcMLl.system.js.map} +1 -1
  273. package/dist/pine-core/{p-CzKqvFNN.system.js.map → p-BaAcO8Mz.system.js.map} +1 -1
  274. package/dist/pine-core/{p-yku4NLl6.system.js.map → p-BcuE4ZrB.system.js.map} +1 -1
  275. package/dist/pine-core/p-BsL2GDnH.system.js +1 -1
  276. package/dist/pine-core/{p-DEsea81X.system.js.map → p-BwHnCFqU.system.js.map} +1 -1
  277. package/dist/pine-core/{p-D9LPgNmN.system.js.map → p-BxBtA60x.system.js.map} +1 -1
  278. package/dist/pine-core/{p-Bs9Nyvj2.system.js.map → p-C0oRS1F9.system.js.map} +1 -1
  279. package/dist/pine-core/{p-Derxa-nn.system.js.map → p-C2d75seA.system.js.map} +1 -1
  280. package/dist/pine-core/{p-DbVkYdnF.system.js.map → p-CGABEyvz.system.js.map} +1 -1
  281. package/dist/pine-core/{p-CiDIFl28.system.js.map → p-CIc_XeAg.system.js.map} +1 -1
  282. package/dist/pine-core/{p-Bo6FQRlR.system.js.map → p-CNYB6FL-.system.js.map} +1 -1
  283. package/dist/pine-core/{p-DgOMN0Ur.system.js.map → p-CNkajx9x.system.js.map} +1 -1
  284. package/dist/pine-core/{p-Cj2r1nL6.system.js.map → p-CS2nVL5p.system.js.map} +1 -1
  285. package/dist/pine-core/{p-B-pTdYoP.system.js.map → p-CTPMEWZT.system.js.map} +1 -1
  286. package/dist/pine-core/{p-CDIHBBTC.system.js.map → p-CTWkFhWu.system.js.map} +1 -1
  287. package/dist/pine-core/{p-M2Hhmwex.system.js.map → p-CdzfTGbZ.system.js.map} +1 -1
  288. package/dist/pine-core/{p-DiJV28pi.system.js.map → p-CkoeYrxa.system.js.map} +1 -1
  289. package/dist/pine-core/{p-DKSZziVY.system.js.map → p-ClVQjta4.system.js.map} +1 -1
  290. package/dist/pine-core/{p-DS7q5AvX.system.js.map → p-D2UtaGL2.system.js.map} +1 -1
  291. package/dist/pine-core/{p-DN9puCWI.system.js.map → p-DGyATOIf.system.js.map} +1 -1
  292. package/dist/pine-core/p-DMeT5CsE.system.js.map +1 -0
  293. package/dist/pine-core/{p-CsM74dxm.system.js.map → p-DVhX1_nD.system.js.map} +1 -1
  294. package/dist/pine-core/p-DeW-6a7f.system.js.map +1 -0
  295. package/dist/pine-core/{p-BOJnNd1p.system.js.map → p-DgTp_KeO.system.js.map} +1 -1
  296. package/dist/pine-core/p-DjXmy34u.system.js.map +1 -0
  297. package/dist/pine-core/{p-_4gljHh-.js → p-DpOSrebJ.js} +1 -1
  298. package/dist/pine-core/p-DpOSrebJ.js.map +1 -0
  299. package/dist/pine-core/{p-B4W0_y2p.system.js → p-DyDReOdO.system.js} +1 -1
  300. package/dist/pine-core/p-DyDReOdO.system.js.map +1 -0
  301. package/dist/pine-core/{p-CLNi-hRD.system.js.map → p-EqAbQY8l.system.js.map} +1 -1
  302. package/dist/pine-core/p-Ke8SGZqs.system.js.map +1 -0
  303. package/dist/pine-core/{p-D-4Xbxlj.system.js.map → p-Mqxw-gWj.system.js.map} +1 -1
  304. package/dist/pine-core/{p-D5vuiRx2.system.js.map → p-PPIMiuZX.system.js.map} +1 -1
  305. package/dist/pine-core/{p-CnPERKGo.system.js.map → p-UhZHDNH2.system.js.map} +1 -1
  306. package/dist/pine-core/{p-d2ccda59.system.entry.js → p-a556a328.system.entry.js} +2 -2
  307. package/dist/pine-core/{p-6a2296e6.system.entry.js → p-a98cda38.system.entry.js} +2 -2
  308. package/dist/pine-core/{p-3f82ac77.system.entry.js → p-ab7e4700.system.entry.js} +2 -2
  309. package/dist/pine-core/{p-3798a631.system.entry.js → p-aeaae417.system.entry.js} +2 -2
  310. package/dist/pine-core/{p-b7ba6316.entry.js → p-b2820acd.entry.js} +2 -2
  311. package/dist/pine-core/{p-2296c34f.entry.js → p-bf699bad.entry.js} +2 -2
  312. package/dist/pine-core/{p-7b38e384.system.entry.js → p-c1909a5d.system.entry.js} +2 -2
  313. package/dist/pine-core/{p-984578f8.system.entry.js → p-c551191a.system.entry.js} +2 -2
  314. package/dist/pine-core/{p-1bd715ee.system.entry.js → p-c5e1ed09.system.entry.js} +2 -2
  315. package/dist/pine-core/p-c5e1ed09.system.entry.js.map +1 -0
  316. package/dist/pine-core/{p-596e0292.system.entry.js → p-cc21ddcc.system.entry.js} +2 -2
  317. package/dist/pine-core/{p-b2796d3c.system.entry.js → p-d0adaca0.system.entry.js} +2 -2
  318. package/dist/pine-core/{p-722012ac.entry.js → p-d28768d1.entry.js} +2 -2
  319. package/dist/pine-core/{p-24607f93.entry.js → p-d35b3494.entry.js} +2 -2
  320. package/dist/pine-core/{p-730221a8.system.entry.js → p-d553e05c.system.entry.js} +2 -2
  321. package/dist/pine-core/{p-04df41d7.system.entry.js → p-d6d453d8.system.entry.js} +2 -2
  322. package/dist/pine-core/p-dcda4ff5.system.entry.js +2 -0
  323. package/dist/pine-core/{p-1224c874.entry.js → p-ddcc4932.entry.js} +2 -2
  324. package/dist/pine-core/{p-c1b0f921.system.entry.js → p-de550d9e.system.entry.js} +2 -2
  325. package/dist/pine-core/p-dfd5a5b6.system.entry.js +2 -0
  326. package/dist/pine-core/p-dfd5a5b6.system.entry.js.map +1 -0
  327. package/dist/pine-core/p-e562ad73.system.entry.js +2 -0
  328. package/dist/pine-core/p-e562ad73.system.entry.js.map +1 -0
  329. package/dist/pine-core/p-e9f004c5.entry.js +2 -0
  330. package/dist/pine-core/p-e9f004c5.entry.js.map +1 -0
  331. package/dist/pine-core/{p-71265b2a.system.entry.js → p-f46c4618.system.entry.js} +2 -2
  332. package/dist/pine-core/{p-761946a0.entry.js → p-f6b226df.entry.js} +2 -2
  333. package/dist/pine-core/{p-bcc4edaa.entry.js → p-f99c59a8.entry.js} +2 -2
  334. package/dist/pine-core/{p-b3d05184.entry.js → p-fb1eb0c4.entry.js} +2 -2
  335. package/dist/pine-core/{p-367e188f.entry.js → p-fb2fb435.entry.js} +2 -2
  336. package/dist/pine-core/p-fd1ef1e1.entry.js +2 -0
  337. package/dist/pine-core/{p-85ff1482.entry.js → p-fdf3a5ff.entry.js} +2 -2
  338. package/dist/pine-core/p-fed5f55e.system.entry.js +2 -0
  339. package/dist/pine-core/pds-button.entry.esm.js.map +1 -1
  340. package/dist/pine-core/pds-chip.entry.esm.js.map +1 -1
  341. package/dist/pine-core/pds-input.entry.esm.js.map +1 -1
  342. package/dist/pine-core/pds-select.entry.esm.js.map +1 -1
  343. package/dist/pine-core/pds-tooltip.entry.esm.js.map +1 -1
  344. package/dist/pine-core/pine-core.esm.js +1 -1
  345. package/dist/types/components/pds-chip/pds-chip.d.ts +9 -1
  346. package/dist/types/components/pds-input/pds-input.d.ts +57 -9
  347. package/dist/types/components/pds-select/pds-select.d.ts +4 -0
  348. package/dist/types/components/pds-tooltip/pds-tooltip.d.ts +3 -0
  349. package/dist/types/components.d.ts +70 -6
  350. package/hydrate/index.js +187 -73
  351. package/hydrate/index.mjs +187 -73
  352. package/package.json +2 -2
  353. package/dist/cjs/index-CG2Rr2io.js.map +0 -1
  354. package/dist/esm/index-_4gljHh-.js.map +0 -1
  355. package/dist/esm-es5/index-_4gljHh-.js.map +0 -1
  356. package/dist/pine-core/p-0069abf8.system.entry.js +0 -2
  357. package/dist/pine-core/p-0069abf8.system.entry.js.map +0 -1
  358. package/dist/pine-core/p-1bd715ee.system.entry.js.map +0 -1
  359. package/dist/pine-core/p-1eec6bea.system.entry.js +0 -2
  360. package/dist/pine-core/p-1eec6bea.system.entry.js.map +0 -1
  361. package/dist/pine-core/p-21c3aaeb.entry.js +0 -2
  362. package/dist/pine-core/p-29ad0b86.entry.js +0 -2
  363. package/dist/pine-core/p-29ad0b86.entry.js.map +0 -1
  364. package/dist/pine-core/p-32bd3e33.entry.js +0 -2
  365. package/dist/pine-core/p-32bd3e33.entry.js.map +0 -1
  366. package/dist/pine-core/p-49265849.system.entry.js +0 -2
  367. package/dist/pine-core/p-71f01676.system.entry.js +0 -2
  368. package/dist/pine-core/p-742d4490.entry.js +0 -2
  369. package/dist/pine-core/p-742d4490.entry.js.map +0 -1
  370. package/dist/pine-core/p-7e92ec48.system.entry.js +0 -2
  371. package/dist/pine-core/p-7e92ec48.system.entry.js.map +0 -1
  372. package/dist/pine-core/p-7ff213bb.system.entry.js +0 -2
  373. package/dist/pine-core/p-8023086c.entry.js +0 -2
  374. package/dist/pine-core/p-8023086c.entry.js.map +0 -1
  375. package/dist/pine-core/p-929bb7ab.system.entry.js +0 -2
  376. package/dist/pine-core/p-B4W0_y2p.system.js.map +0 -1
  377. package/dist/pine-core/p-BO1OsmVU.system.js.map +0 -1
  378. package/dist/pine-core/p-CtAVdPaE.system.js.map +0 -1
  379. package/dist/pine-core/p-D8DRYw9w.system.js.map +0 -1
  380. package/dist/pine-core/p-DyQ_s5MV.system.js.map +0 -1
  381. package/dist/pine-core/p-_4gljHh-.js.map +0 -1
  382. package/dist/pine-core/p-abec6606.entry.js +0 -2
  383. package/dist/pine-core/p-abec6606.entry.js.map +0 -1
  384. package/dist/pine-core/p-b9c13f99.entry.js +0 -2
  385. package/dist/pine-core/p-d1b222f5.entry.js +0 -2
  386. package/dist/pine-core/p-e09a3682.system.entry.js +0 -2
  387. package/dist/pine-core/p-e09a3682.system.entry.js.map +0 -1
  388. package/dist/pine-core/p-e6d6e103.entry.js +0 -2
  389. package/dist/pine-core/p-xgOOHGQo.system.js.map +0 -1
  390. /package/dist/pine-core/{p-833f08f3.entry.js.map → p-04195bdb.entry.js.map} +0 -0
  391. /package/dist/pine-core/{p-4288c861.entry.js.map → p-07f45626.entry.js.map} +0 -0
  392. /package/dist/pine-core/{p-0572825b.entry.js.map → p-0a11384e.entry.js.map} +0 -0
  393. /package/dist/pine-core/{p-28e28f42.system.entry.js.map → p-0a87e2fc.system.entry.js.map} +0 -0
  394. /package/dist/pine-core/{p-71f01676.system.entry.js.map → p-0c30661b.system.entry.js.map} +0 -0
  395. /package/dist/pine-core/{p-146fcd44.entry.js.map → p-10e2feff.entry.js.map} +0 -0
  396. /package/dist/pine-core/{p-bd04212c.system.entry.js.map → p-13481ef5.system.entry.js.map} +0 -0
  397. /package/dist/pine-core/{p-c4294be2.entry.js.map → p-19c01019.entry.js.map} +0 -0
  398. /package/dist/pine-core/{p-f2c807ac.entry.js.map → p-1d395d27.entry.js.map} +0 -0
  399. /package/dist/pine-core/{p-4ff0838c.entry.js.map → p-2007a0b5.entry.js.map} +0 -0
  400. /package/dist/pine-core/{p-78cb1c40.system.entry.js.map → p-27c0ffda.system.entry.js.map} +0 -0
  401. /package/dist/pine-core/{p-21c3aaeb.entry.js.map → p-35917a1a.entry.js.map} +0 -0
  402. /package/dist/pine-core/{p-1b109c01.entry.js.map → p-3ea415b0.entry.js.map} +0 -0
  403. /package/dist/pine-core/{p-48e76945.system.entry.js.map → p-4b2aab79.system.entry.js.map} +0 -0
  404. /package/dist/pine-core/{p-77c3a10d.entry.js.map → p-51cc93b3.entry.js.map} +0 -0
  405. /package/dist/pine-core/{p-83252078.system.entry.js.map → p-5367f477.system.entry.js.map} +0 -0
  406. /package/dist/pine-core/{p-a2572675.system.entry.js.map → p-593df966.system.entry.js.map} +0 -0
  407. /package/dist/pine-core/{p-d6ac2862.system.entry.js.map → p-5a437fcd.system.entry.js.map} +0 -0
  408. /package/dist/pine-core/{p-c0f74199.entry.js.map → p-60fbeb1c.entry.js.map} +0 -0
  409. /package/dist/pine-core/{p-e6d6e103.entry.js.map → p-65a875f6.entry.js.map} +0 -0
  410. /package/dist/pine-core/{p-30142a25.system.entry.js.map → p-6a7936e7.system.entry.js.map} +0 -0
  411. /package/dist/pine-core/{p-86d388a2.entry.js.map → p-76f7cf21.entry.js.map} +0 -0
  412. /package/dist/pine-core/{p-121e03ad.system.entry.js.map → p-78327c08.system.entry.js.map} +0 -0
  413. /package/dist/pine-core/{p-e2dc81c0.entry.js.map → p-78f29270.entry.js.map} +0 -0
  414. /package/dist/pine-core/{p-83c632f6.system.entry.js.map → p-79cb7835.system.entry.js.map} +0 -0
  415. /package/dist/pine-core/{p-e9d972db.system.entry.js.map → p-7bb3a5d4.system.entry.js.map} +0 -0
  416. /package/dist/pine-core/{p-17d3fa8b.entry.js.map → p-80f36506.entry.js.map} +0 -0
  417. /package/dist/pine-core/{p-f47133fd.entry.js.map → p-8180b641.entry.js.map} +0 -0
  418. /package/dist/pine-core/{p-a394645a.system.entry.js.map → p-833b2170.system.entry.js.map} +0 -0
  419. /package/dist/pine-core/{p-83ffc1cc.entry.js.map → p-86329612.entry.js.map} +0 -0
  420. /package/dist/pine-core/{p-cd2cd116.entry.js.map → p-8f06b020.entry.js.map} +0 -0
  421. /package/dist/pine-core/{p-78fb945e.system.entry.js.map → p-959c8247.system.entry.js.map} +0 -0
  422. /package/dist/pine-core/{p-f9e01886.system.entry.js.map → p-96e9774e.system.entry.js.map} +0 -0
  423. /package/dist/pine-core/{p-929bb7ab.system.entry.js.map → p-9c01e81b.system.entry.js.map} +0 -0
  424. /package/dist/pine-core/{p-d2ccda59.system.entry.js.map → p-a556a328.system.entry.js.map} +0 -0
  425. /package/dist/pine-core/{p-6a2296e6.system.entry.js.map → p-a98cda38.system.entry.js.map} +0 -0
  426. /package/dist/pine-core/{p-3f82ac77.system.entry.js.map → p-ab7e4700.system.entry.js.map} +0 -0
  427. /package/dist/pine-core/{p-3798a631.system.entry.js.map → p-aeaae417.system.entry.js.map} +0 -0
  428. /package/dist/pine-core/{p-b7ba6316.entry.js.map → p-b2820acd.entry.js.map} +0 -0
  429. /package/dist/pine-core/{p-2296c34f.entry.js.map → p-bf699bad.entry.js.map} +0 -0
  430. /package/dist/pine-core/{p-7b38e384.system.entry.js.map → p-c1909a5d.system.entry.js.map} +0 -0
  431. /package/dist/pine-core/{p-984578f8.system.entry.js.map → p-c551191a.system.entry.js.map} +0 -0
  432. /package/dist/pine-core/{p-596e0292.system.entry.js.map → p-cc21ddcc.system.entry.js.map} +0 -0
  433. /package/dist/pine-core/{p-b2796d3c.system.entry.js.map → p-d0adaca0.system.entry.js.map} +0 -0
  434. /package/dist/pine-core/{p-722012ac.entry.js.map → p-d28768d1.entry.js.map} +0 -0
  435. /package/dist/pine-core/{p-24607f93.entry.js.map → p-d35b3494.entry.js.map} +0 -0
  436. /package/dist/pine-core/{p-730221a8.system.entry.js.map → p-d553e05c.system.entry.js.map} +0 -0
  437. /package/dist/pine-core/{p-04df41d7.system.entry.js.map → p-d6d453d8.system.entry.js.map} +0 -0
  438. /package/dist/pine-core/{p-49265849.system.entry.js.map → p-dcda4ff5.system.entry.js.map} +0 -0
  439. /package/dist/pine-core/{p-1224c874.entry.js.map → p-ddcc4932.entry.js.map} +0 -0
  440. /package/dist/pine-core/{p-c1b0f921.system.entry.js.map → p-de550d9e.system.entry.js.map} +0 -0
  441. /package/dist/pine-core/{p-71265b2a.system.entry.js.map → p-f46c4618.system.entry.js.map} +0 -0
  442. /package/dist/pine-core/{p-761946a0.entry.js.map → p-f6b226df.entry.js.map} +0 -0
  443. /package/dist/pine-core/{p-bcc4edaa.entry.js.map → p-f99c59a8.entry.js.map} +0 -0
  444. /package/dist/pine-core/{p-b3d05184.entry.js.map → p-fb1eb0c4.entry.js.map} +0 -0
  445. /package/dist/pine-core/{p-367e188f.entry.js.map → p-fb2fb435.entry.js.map} +0 -0
  446. /package/dist/pine-core/{p-b9c13f99.entry.js.map → p-fd1ef1e1.entry.js.map} +0 -0
  447. /package/dist/pine-core/{p-85ff1482.entry.js.map → p-fdf3a5ff.entry.js.map} +0 -0
  448. /package/dist/pine-core/{p-7ff213bb.system.entry.js.map → p-fed5f55e.system.entry.js.map} +0 -0
@@ -1,12 +1,34 @@
1
1
  import { h, Host } from "@stencil/core";
2
2
  import { assignDescription, messageId } from "../../utils/form";
3
- import { danger } from "@pine-ds/icons/icons";
4
- import { debounceEvent } from "../../utils/utils";
5
3
  import { inheritAriaAttributes } from "../../utils/attributes";
4
+ import { debounceEvent } from "../../utils/utils";
5
+ import { danger } from "@pine-ds/icons/icons";
6
+ /**
7
+ * @slot append - Content to be displayed after the input field
8
+ * @slot prefix - Content that is displayed visually within the input field before the input field
9
+ * @slot prepend - Content to be displayed before the input field
10
+ * @slot suffix - Content that is displayed visually within the input field after the input field
11
+ */
6
12
  export class PdsInput {
7
13
  constructor() {
8
14
  this.inheritedAttributes = {};
9
15
  this.isComposing = false;
16
+ /**
17
+ * If true, the input has prefix content (non-focusable)
18
+ */
19
+ this.hasPrefix = false;
20
+ /**
21
+ * If true, the input has suffix content (non-focusable)
22
+ */
23
+ this.hasSuffix = false;
24
+ /**
25
+ * If true, the input has prepend content (focusable)
26
+ */
27
+ this.hasPrepend = false;
28
+ /**
29
+ * If true, the input has append content (focusable)
30
+ */
31
+ this.hasAppend = false;
10
32
  /**
11
33
  * Determines the type of control that will be displayed
12
34
  * `'email'`, `'number'`, `'password'`, `'tel'`, `'text'`, `'url'`
@@ -63,6 +85,62 @@ export class PdsInput {
63
85
  this.nativeInput.focus();
64
86
  }
65
87
  }
88
+ updateAddonWidths() {
89
+ requestAnimationFrame(() => {
90
+ if (this.prefixEl) {
91
+ const prefixWidth = this.prefixEl.offsetWidth;
92
+ this.el.style.setProperty('--prefix-width', `${prefixWidth}px`);
93
+ }
94
+ if (this.suffixEl) {
95
+ const suffixWidth = this.suffixEl.offsetWidth;
96
+ this.el.style.setProperty('--suffix-width', `${suffixWidth}px`);
97
+ }
98
+ });
99
+ }
100
+ renderPrefix() {
101
+ const hasPrefix = this.el.querySelector('[slot="prefix"]') !== null;
102
+ if (hasPrefix) {
103
+ return (h("div", { class: "pds-input__prefix", part: "prefix", ref: (el) => this.prefixEl = el }, h("slot", { name: "prefix", onSlotchange: () => this.updateAddonWidths() })));
104
+ }
105
+ return null;
106
+ }
107
+ renderSuffix() {
108
+ const hasSuffix = this.el.querySelector('[slot="suffix"]') !== null;
109
+ if (hasSuffix) {
110
+ return (h("div", { class: "pds-input__suffix", part: "suffix", ref: (el) => this.suffixEl = el }, h("slot", { name: "suffix", onSlotchange: () => this.updateAddonWidths() })));
111
+ }
112
+ return null;
113
+ }
114
+ renderPrepend() {
115
+ const hasPrepend = this.el.querySelector('[slot="prepend"]') !== null;
116
+ if (hasPrepend) {
117
+ return (h("div", { class: "pds-input__prepend", part: "prepend" }, h("slot", { name: "prepend" })));
118
+ }
119
+ return null;
120
+ }
121
+ renderAppend() {
122
+ const hasAppend = this.el.querySelector('[slot="append"]') !== null;
123
+ if (hasAppend) {
124
+ return (h("div", { class: "pds-input__append", part: "append" }, h("slot", { name: "append" })));
125
+ }
126
+ return null;
127
+ }
128
+ componentWillLoad() {
129
+ this.inheritedAttributes = Object.assign({}, inheritAriaAttributes(this.el));
130
+ this.hasPrefix = this.el.querySelector('[slot="prefix"]') !== null;
131
+ this.hasSuffix = this.el.querySelector('[slot="suffix"]') !== null;
132
+ this.hasPrepend = this.el.querySelector('[slot="prepend"]') !== null;
133
+ this.hasAppend = this.el.querySelector('[slot="append"]') !== null;
134
+ // Store the original pdsInput event emitter
135
+ this.originalPdsInput = this.pdsInput;
136
+ }
137
+ componentDidLoad() {
138
+ this.debounceChanged();
139
+ this.updateAddonWidths();
140
+ }
141
+ componentDidUpdate() {
142
+ this.updateAddonWidths();
143
+ }
66
144
  debounceChanged() {
67
145
  const { pdsInput, debounce, originalPdsInput } = this;
68
146
  /**
@@ -91,7 +169,6 @@ export class PdsInput {
91
169
  this.pdsChange.emit({ value: newValue, event });
92
170
  }
93
171
  /**
94
- *
95
172
  * Emits a `pdsInput` event
96
173
  */
97
174
  emitInputChange(event) {
@@ -100,24 +177,20 @@ export class PdsInput {
100
177
  const newValue = value == null ? value : value.toString();
101
178
  this.pdsInput.emit({ value: newValue, event });
102
179
  }
103
- componentWillLoad() {
104
- this.inheritedAttributes = Object.assign({}, inheritAriaAttributes(this.el));
105
- }
106
- componentDidLoad() {
107
- this.debounceChanged();
108
- }
109
- inputClassNames() {
110
- const classNames = ['pds-input__field'];
111
- if (this.invalid && this.invalid === true) {
112
- classNames.push('is-invalid');
113
- }
114
- return classNames.join(' ');
115
- }
116
180
  render() {
117
- return (h(Host, { key: 'a2a05a1e0d3e7722c1dc3dea957facaf5ef24c3c', "aria-disabled": this.disabled ? 'true' : null, "aria-readonly": this.readonly ? 'true' : null }, h("div", { key: 'd95ad9600e7d80050bf41503a2eb9ccb91f77893', class: "pds-input" }, this.label &&
118
- h("label", { key: 'b5772c8283fe3c8899235c432bbabd36012c2aef', class: "pds-input__label", htmlFor: this.componentId }, this.label), h("input", Object.assign({ key: '65a2ff8c31ebf545caf755609fa2f3e95cdd1098', class: this.inputClassNames(), ref: (input) => this.nativeInput = input, "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, autocomplete: this.autocomplete, disabled: this.disabled, id: this.componentId, name: this.name, placeholder: this.placeholder, readOnly: this.readonly, required: this.required, type: this.type, value: this.value, onInput: this.onInputEvent, onChange: this.onChangeEvent, onBlur: this.onBlurEvent, onFocus: this.onFocusEvent, onCompositionstart: this.onCompositionStart, onCompositionend: this.onCompositionEnd }, this.inheritedAttributes)), this.helperMessage &&
119
- h("p", { key: 'a7a30bc28a0e9aa16ebd842b8b3851569f556591', class: "pds-input__helper-message", id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
120
- h("p", { key: '3ffc19523e9378534e665ba52247935e924d4168', class: "pds-input__error-message", id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: '6961e5735ffe279414ea5333224baa72561697d5', icon: danger, size: "small" }), this.errorMessage))));
181
+ const { componentId, disabled, errorMessage, helperMessage, invalid = false, label, } = this;
182
+ const value = this.getValue();
183
+ const inputWrapperClasses = {
184
+ 'pds-input__field-wrapper': true,
185
+ 'has-focus': this.hasFocus,
186
+ 'has-error': invalid || !!errorMessage,
187
+ 'is-disabled': disabled,
188
+ 'has-prefix': this.hasPrefix,
189
+ 'has-suffix': this.hasSuffix,
190
+ 'has-prepend': this.hasPrepend,
191
+ 'has-append': this.hasAppend,
192
+ };
193
+ return (h(Host, { key: '6ae7251aeee049e0e4f3a66c7d947a3ceb7d2b26', "aria-disabled": this.disabled ? 'true' : null, "aria-readonly": this.readonly ? 'true' : null, "has-prefix": this.hasPrefix ? 'true' : null, "has-suffix": this.hasSuffix ? 'true' : null, "has-prepend": this.hasPrepend ? 'true' : null, "has-append": this.hasAppend ? 'true' : null }, h("div", { key: 'f397d329cf587b9bdf699a0c80a3bdb9c1de0b53', class: "pds-input" }, label && (h("label", { key: '7e5523268dd59acb3fbf2bd659f319cc458166c0', htmlFor: componentId, class: "pds-input__label" }, label, this.required && h("span", { key: 'f197ce55768d8409c9c7832af56e0a6bdc27e90a', class: "pds-input__required-indicator" }, " *"))), h("div", { key: 'ad92476c65ad280622a8aa8c731609aff8ec51a4', class: inputWrapperClasses }, this.renderPrepend(), this.renderPrefix(), h("input", Object.assign({ key: '187ee16cc7458af1dc06a7f424ce6bc2ffede359', ref: (input) => (this.nativeInput = input), class: "pds-input__field", "aria-describedby": assignDescription(componentId, invalid, helperMessage), "aria-invalid": invalid ? "true" : undefined, autocomplete: this.autocomplete, disabled: disabled, id: componentId, max: this.max, maxlength: this.maxlength, min: this.min, minlength: this.minlength, name: this.name, pattern: this.pattern, placeholder: this.placeholder, readOnly: this.readonly, required: this.required, step: this.step, type: this.type, value: value, onInput: this.onInputEvent, onChange: this.onChangeEvent, onBlur: this.onBlurEvent, onFocus: this.onFocusEvent, onCompositionstart: this.onCompositionStart, onCompositionend: this.onCompositionEnd }, this.inheritedAttributes)), this.renderSuffix(), this.renderAppend()), helperMessage && (h("p", { key: 'c11daa2e4ed085033d90a3e9185dd7beb259aa9e', class: "pds-input__helper-message", id: messageId(componentId, 'helper') }, helperMessage)), errorMessage && (h("p", { key: 'd5adbb495bd7abd83655390e0d34cbdf527b656a', class: "pds-input__error-message", id: messageId(componentId, 'error') }, h("pds-icon", { key: 'd1a80c2d7e6f8389488fe2c0bb6dd1923536588a', icon: danger, size: "small" }), errorMessage)))));
121
194
  }
122
195
  static get is() { return "pds-input"; }
123
196
  static get encapsulation() { return "shadow"; }
@@ -285,6 +358,82 @@ export class PdsInput {
285
358
  "attribute": "label",
286
359
  "reflect": false
287
360
  },
361
+ "max": {
362
+ "type": "string",
363
+ "mutable": false,
364
+ "complexType": {
365
+ "original": "string",
366
+ "resolved": "string",
367
+ "references": {}
368
+ },
369
+ "required": false,
370
+ "optional": true,
371
+ "docs": {
372
+ "tags": [],
373
+ "text": "Specifies the maximum value for the input field."
374
+ },
375
+ "getter": false,
376
+ "setter": false,
377
+ "attribute": "max",
378
+ "reflect": false
379
+ },
380
+ "maxlength": {
381
+ "type": "string",
382
+ "mutable": false,
383
+ "complexType": {
384
+ "original": "string",
385
+ "resolved": "string",
386
+ "references": {}
387
+ },
388
+ "required": false,
389
+ "optional": true,
390
+ "docs": {
391
+ "tags": [],
392
+ "text": "Specifies the maximum number of characters allowed in the input field."
393
+ },
394
+ "getter": false,
395
+ "setter": false,
396
+ "attribute": "maxlength",
397
+ "reflect": false
398
+ },
399
+ "min": {
400
+ "type": "string",
401
+ "mutable": false,
402
+ "complexType": {
403
+ "original": "string",
404
+ "resolved": "string",
405
+ "references": {}
406
+ },
407
+ "required": false,
408
+ "optional": true,
409
+ "docs": {
410
+ "tags": [],
411
+ "text": "Specifies the minimum value for the input field."
412
+ },
413
+ "getter": false,
414
+ "setter": false,
415
+ "attribute": "min",
416
+ "reflect": false
417
+ },
418
+ "minlength": {
419
+ "type": "string",
420
+ "mutable": false,
421
+ "complexType": {
422
+ "original": "string",
423
+ "resolved": "string",
424
+ "references": {}
425
+ },
426
+ "required": false,
427
+ "optional": true,
428
+ "docs": {
429
+ "tags": [],
430
+ "text": "Specifies the minimum number of characters allowed in the input field."
431
+ },
432
+ "getter": false,
433
+ "setter": false,
434
+ "attribute": "minlength",
435
+ "reflect": false
436
+ },
288
437
  "name": {
289
438
  "type": "string",
290
439
  "mutable": false,
@@ -304,6 +453,25 @@ export class PdsInput {
304
453
  "attribute": "name",
305
454
  "reflect": false
306
455
  },
456
+ "pattern": {
457
+ "type": "string",
458
+ "mutable": false,
459
+ "complexType": {
460
+ "original": "string",
461
+ "resolved": "string",
462
+ "references": {}
463
+ },
464
+ "required": false,
465
+ "optional": true,
466
+ "docs": {
467
+ "tags": [],
468
+ "text": "Specifies the regular expression that the input value is checked against."
469
+ },
470
+ "getter": false,
471
+ "setter": false,
472
+ "attribute": "pattern",
473
+ "reflect": false
474
+ },
307
475
  "placeholder": {
308
476
  "type": "string",
309
477
  "mutable": false,
@@ -361,6 +529,25 @@ export class PdsInput {
361
529
  "attribute": "required",
362
530
  "reflect": false
363
531
  },
532
+ "step": {
533
+ "type": "string",
534
+ "mutable": false,
535
+ "complexType": {
536
+ "original": "string",
537
+ "resolved": "string",
538
+ "references": {}
539
+ },
540
+ "required": false,
541
+ "optional": true,
542
+ "docs": {
543
+ "tags": [],
544
+ "text": "Works with the `min` and `max` attributes to define increments for the input field."
545
+ },
546
+ "getter": false,
547
+ "setter": false,
548
+ "attribute": "step",
549
+ "reflect": false
550
+ },
364
551
  "type": {
365
552
  "type": "string",
366
553
  "mutable": false,
@@ -408,6 +595,10 @@ export class PdsInput {
408
595
  }
409
596
  static get states() {
410
597
  return {
598
+ "hasPrefix": {},
599
+ "hasSuffix": {},
600
+ "hasPrepend": {},
601
+ "hasAppend": {},
411
602
  "hasFocus": {}
412
603
  };
413
604
  }
@@ -440,7 +631,7 @@ export class PdsInput {
440
631
  "composed": true,
441
632
  "docs": {
442
633
  "tags": [],
443
- "text": "\nEmitted when the value has changed.\n\nThis event will not emit when programmatically setting the `value` property."
634
+ "text": "Emitted when the value has changed.\n\nThis event will not emit when programmatically setting the `value` property."
444
635
  },
445
636
  "complexType": {
446
637
  "original": "InputChangeEventDetail",
@@ -1 +1 @@
1
- {"version":3,"file":"pds-input.js","sourceRoot":"","sources":["../../../src/components/pds-input/pds-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAC7G,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAU1D,MAAM,OAAO,QAAQ;IALrB;QAOU,wBAAmB,GAAe,EAAE,CAAC;QACrC,gBAAW,GAAG,KAAK,CAAC;QAwG5B;;;;WAI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AChB,CAEF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\nimport { debounceEvent } from '@utils/utils';\nimport { inheritAriaAttributes } from '@utils/attributes';\n\nimport type { Attributes } from '@utils/attributes';\nimport type { InputChangeEventDetail, InputInputEventDetail } from './input-interface';\n\n@Component({\n tag: 'pds-input',\n styleUrls: ['pds-input.tokens.scss', '../../global/styles/utils/label.scss', 'pds-input.scss'],\n shadow: true,\n})\nexport class PdsInput {\n private nativeInput?: HTMLInputElement;\n private inheritedAttributes: Attributes = {};\n private isComposing = false;\n /**\n * The value of the input when the input is focused.\n */\n private focusedValue?: string | number | null;\n\n private originalPdsInput?: EventEmitter<InputInputEventDetail>;\n\n @Element() el!: HTMLPdsInputElement;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() pdsBlur!: EventEmitter<FocusEvent>;\n\n /**\n *\n * Emitted when the value has changed.\n *\n * This event will not emit when programmatically setting the `value` property.\n */\n @Event() pdsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() pdsFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when a keyboard input occurs.\n */\n @Event() pdsInput: EventEmitter<InputInputEventDetail>;\n\n /**\n * Sets focus on the native `input` in the `pds-input`. Use this method instead of the global\n * `input.focus()`.\n */\n @Method()\n async setFocus() {\n if ( this.nativeInput ) {\n this.nativeInput.focus();\n }\n }\n\n /**\n * Specifies if and how the browser provides `autocomplete` assistance for the field.\n */\n @Prop() autocomplete: string;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Sets the number of milliseconds to wait before updating the value.\n */\n @Prop() debounce?: number;\n\n /**\n * Determines whether or not the input field is disabled.\n */\n @Prop() disabled?: boolean;\n\n /**\n * Specifies the error message and provides an error-themed treatment to the field.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Displays a message or hint below the input field.\n */\n @Prop() helperMessage?: string;\n\n /**\n * Determines whether or not the input field is invalid or throws an error.\n */\n @Prop() invalid?: boolean;\n\n /**\n * Text to be displayed as the input label.\n */\n @Prop() label?: string;\n\n /**\n * Specifies the name. Submitted with the form name/value pair.\n */\n @Prop() name?: string;\n\n /**\n * Specifies a short hint that describes the expected value of the input field.\n */\n @Prop() placeholder?: string;\n\n /**\n * Determines whether or not the input field is readonly.\n */\n @Prop() readonly?: boolean;\n\n /**\n * Determines whether or not the input field is required.\n */\n @Prop() required?: boolean;\n\n /**\n * Determines the type of control that will be displayed\n * `'email'`, `'number'`, `'password'`, `'tel'`, `'text'`, `'url'`\n * @defaultValue \"text\"\n */\n @Prop() type = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Determines if the input has focus.\n */\n @State() hasFocus = false;\n\n\n @Watch('debounce')\n protected debounceChanged() {\n const { pdsInput, debounce, originalPdsInput } = this;\n\n /**\n * If debounce is undefined, we have to manually revert the pdsInput emitter in case\n * debounce used to be set to a number. Otherwise, the event would stay debounced.\n */\n this.pdsInput = debounce === undefined ? originalPdsInput ?? pdsInput : debounceEvent(pdsInput, debounce);\n }\n\n @Watch('value')\n protected valueChanged() {\n const nativeInput = this.nativeInput;\n const value = this.getValue();\n\n if (nativeInput && nativeInput.value !== value && !this.isComposing) {\n nativeInput.value = value;\n }\n }\n\n private getValue(): string {\n return typeof this.value === 'number' ? this.value.toString() : (this.value || '').toString();\n }\n\n private onInputEvent = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.emitInputChange(ev);\n };\n\n private onChangeEvent = (ev: Event) => {\n this.emitValueChange(ev);\n };\n\n private onBlurEvent = (ev: FocusEvent) => {\n this.hasFocus = false;\n\n if (this.focusedValue !== this.value) {\n /**\n * Emits the `pdsChange` event when the input value\n * is different than the value when the input was focused.\n */\n this.emitValueChange(ev);\n }\n\n this.pdsBlur.emit(ev);\n };\n\n private onFocusEvent = (ev: FocusEvent) => {\n this.hasFocus = true;\n this.focusedValue = this.value;\n\n this.pdsFocus.emit(ev);\n };\n\n private onCompositionStart = () => {\n this.isComposing = true;\n }\n\n private onCompositionEnd = () => {\n this.isComposing = false;\n }\n\n /**\n * Emits a pdsChange event\n */\n private emitValueChange(event?: Event) {\n const { value } = this;\n const newValue = value == null ? value : value.toString();\n\n this.focusedValue = newValue;\n this.pdsChange.emit({ value: newValue, event });\n }\n\n /**\n *\n * Emits a `pdsInput` event\n */\n private emitInputChange(event?: Event) {\n const { value } = this;\n\n // Checks for both null and undefined values\n const newValue = value == null ? value : value.toString();\n\n this.pdsInput.emit({ value: newValue, event });\n }\n\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n }\n }\n\n componentDidLoad() {\n this.debounceChanged();\n }\n\n private inputClassNames() {\n const classNames = ['pds-input__field'];\n\n if (this.invalid && this.invalid === true) {\n classNames.push('is-invalid');\n }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n aria-readonly={this.readonly ? 'true' : null}\n >\n <div class=\"pds-input\">\n {this.label &&\n <label class=\"pds-input__label\" htmlFor={this.componentId}>{this.label}</label>\n }\n <input\n class={this.inputClassNames()}\n ref={(input) => this.nativeInput = input}\n aria-describedby={assignDescription(this.componentId, this.invalid, this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n autocomplete={this.autocomplete}\n disabled={this.disabled}\n id={this.componentId}\n name={this.name}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n type={this.type}\n value={this.value}\n onInput={this.onInputEvent}\n onChange={this.onChangeEvent}\n onBlur={this.onBlurEvent}\n onFocus={this.onFocusEvent}\n onCompositionstart={this.onCompositionStart}\n onCompositionend={this.onCompositionEnd}\n {...this.inheritedAttributes}\n />\n {this.helperMessage &&\n <p\n class=\"pds-input__helper-message\"\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </p>\n }\n {this.errorMessage &&\n <p\n class=\"pds-input__error-message\"\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </p>\n }\n </div>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"pds-input.js","sourceRoot":"","sources":["../../../src/components/pds-input/pds-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAC7G,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAG1D,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C;;;;;GAKG;AAMH,MAAM,OAAO,QAAQ;IALrB;QAO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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { inheritAriaAttributes } from '@utils/attributes';\nimport type { Attributes } from '@utils/attributes';\nimport { InputChangeEventDetail, InputInputEventDetail } from './input-interface';\nimport { debounceEvent } from '@utils/utils';\nimport { danger } from '@pine-ds/icons/icons';\n\n/**\n * @slot append - Content to be displayed after the input field\n * @slot prefix - Content that is displayed visually within the input field before the input field\n * @slot prepend - Content to be displayed before the input field\n * @slot suffix - Content that is displayed visually within the input field after the input field\n */\n@Component({\n tag: 'pds-input',\n styleUrls: ['pds-input.tokens.scss', '../../global/styles/utils/label.scss', 'pds-input.scss'],\n shadow: true,\n})\nexport class PdsInput {\n private nativeInput?: HTMLInputElement;\n private inheritedAttributes: Attributes = {};\n private isComposing = false;\n private prefixEl?: HTMLElement;\n private suffixEl?: HTMLElement;\n private focusedValue?: string | number | null;\n private originalPdsInput?: EventEmitter<InputInputEventDetail>;\n\n @Element() el!: HTMLPdsInputElement;\n\n /**\n * If true, the input has prefix content (non-focusable)\n */\n @State() hasPrefix = false;\n\n /**\n * If true, the input has suffix content (non-focusable)\n */\n @State() hasSuffix = false;\n\n /**\n * If true, the input has prepend content (focusable)\n */\n @State() hasPrepend = false;\n\n /**\n * If true, the input has append content (focusable)\n */\n @State() hasAppend = false;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() pdsBlur!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the value has changed.\n *\n * This event will not emit when programmatically setting the `value` property.\n */\n @Event() pdsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() pdsFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when a keyboard input occurs.\n */\n @Event() pdsInput: EventEmitter<InputInputEventDetail>;\n\n /**\n * Sets focus on the native `input` in the `pds-input`. Use this method instead of the global\n * `input.focus()`.\n */\n @Method()\n async setFocus() {\n if (this.nativeInput) {\n this.nativeInput.focus();\n }\n }\n\n\n /**\n * Specifies if and how the browser provides `autocomplete` assistance for the field.\n */\n @Prop() autocomplete: string;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Sets the number of milliseconds to wait before updating the value.\n */\n @Prop() debounce?: number;\n\n /**\n * Determines whether or not the input field is disabled.\n */\n @Prop() disabled?: boolean;\n\n /**\n * Specifies the error message and provides an error-themed treatment to the field.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Displays a message or hint below the input field.\n */\n @Prop() helperMessage?: string;\n\n /**\n * Determines whether or not the input field is invalid or throws an error.\n */\n @Prop() invalid?: boolean;\n\n /**\n * Text to be displayed as the input label.\n */\n @Prop() label?: string;\n\n /**\n * Specifies the maximum value for the input field.\n */\n @Prop() max?: string;\n\n /**\n * Specifies the maximum number of characters allowed in the input field.\n */\n @Prop() maxlength?: string;\n\n /**\n * Specifies the minimum value for the input field.\n */\n @Prop() min?: string;\n\n /**\n * Specifies the minimum number of characters allowed in the input field.\n */\n @Prop() minlength?: string;\n\n /**\n * Specifies the name. Submitted with the form name/value pair.\n */\n @Prop() name?: string;\n\n /**\n * Specifies the regular expression that the input value is checked against.\n */\n @Prop() pattern?: string;\n\n /**\n * Specifies a short hint that describes the expected value of the input field.\n */\n @Prop() placeholder?: string;\n\n /**\n * Determines whether or not the input field is readonly.\n */\n @Prop() readonly?: boolean;\n\n /**\n * Determines whether or not the input field is required.\n */\n @Prop() required?: boolean;\n\n /**\n * Works with the `min` and `max` attributes to define increments for the input field.\n */\n @Prop() step?: string;\n\n /**\n * Determines the type of control that will be displayed\n * `'email'`, `'number'`, `'password'`, `'tel'`, `'text'`, `'url'`\n * @defaultValue \"text\"\n */\n @Prop() type = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Determines if the input has focus.\n */\n @State() hasFocus = false;\n\n private updateAddonWidths() {\n requestAnimationFrame(() => {\n if (this.prefixEl) {\n const prefixWidth = this.prefixEl.offsetWidth;\n this.el.style.setProperty('--prefix-width', `${prefixWidth}px`);\n }\n\n if (this.suffixEl) {\n const suffixWidth = this.suffixEl.offsetWidth;\n this.el.style.setProperty('--suffix-width', `${suffixWidth}px`);\n }\n });\n }\n\n private renderPrefix() {\n const hasPrefix = this.el.querySelector('[slot=\"prefix\"]') !== null;\n if (hasPrefix) {\n return (\n <div class=\"pds-input__prefix\" part=\"prefix\" ref={(el) => this.prefixEl = el as HTMLElement}>\n <slot name=\"prefix\" onSlotchange={() => this.updateAddonWidths()}></slot>\n </div>\n );\n }\n return null;\n }\n\n private renderSuffix() {\n const hasSuffix = this.el.querySelector('[slot=\"suffix\"]') !== null;\n if (hasSuffix) {\n return (\n <div class=\"pds-input__suffix\" part=\"suffix\" ref={(el) => this.suffixEl = el as HTMLElement}>\n <slot name=\"suffix\" onSlotchange={() => this.updateAddonWidths()}></slot>\n </div>\n );\n }\n return null;\n }\n\n private renderPrepend() {\n const hasPrepend = this.el.querySelector('[slot=\"prepend\"]') !== null;\n if (hasPrepend) {\n return (\n <div class=\"pds-input__prepend\" part=\"prepend\">\n <slot name=\"prepend\"></slot>\n </div>\n );\n }\n return null;\n }\n\n private renderAppend() {\n const hasAppend = this.el.querySelector('[slot=\"append\"]') !== null;\n if (hasAppend) {\n return (\n <div class=\"pds-input__append\" part=\"append\">\n <slot name=\"append\"></slot>\n </div>\n );\n }\n return null;\n }\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n };\n this.hasPrefix = this.el.querySelector('[slot=\"prefix\"]') !== null;\n this.hasSuffix = this.el.querySelector('[slot=\"suffix\"]') !== null;\n this.hasPrepend = this.el.querySelector('[slot=\"prepend\"]') !== null;\n this.hasAppend = this.el.querySelector('[slot=\"append\"]') !== null;\n\n // Store the original pdsInput event emitter\n this.originalPdsInput = this.pdsInput;\n }\n\n componentDidLoad() {\n this.debounceChanged();\n this.updateAddonWidths();\n }\n\n componentDidUpdate() {\n this.updateAddonWidths();\n }\n\n @Watch('debounce')\n protected debounceChanged() {\n const { pdsInput, debounce, originalPdsInput } = this;\n\n /**\n * If debounce is undefined, we have to manually revert the pdsInput emitter in case\n * debounce used to be set to a number. Otherwise, the event would stay debounced.\n */\n this.pdsInput = debounce === undefined ? originalPdsInput ?? pdsInput : debounceEvent(pdsInput, debounce);\n }\n\n @Watch('value')\n protected valueChanged() {\n const nativeInput = this.nativeInput;\n const value = this.getValue();\n\n if (nativeInput && nativeInput.value !== value && !this.isComposing) {\n nativeInput.value = value;\n }\n }\n\n private getValue(): string {\n return typeof this.value === 'number' ? this.value.toString() : (this.value || '').toString();\n }\n\n private onInputEvent = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.emitInputChange(ev);\n };\n\n private onChangeEvent = (ev: Event) => {\n this.emitValueChange(ev);\n };\n\n private onBlurEvent = (ev: FocusEvent) => {\n this.hasFocus = false;\n\n if (this.focusedValue !== this.value) {\n /**\n * Emits the `pdsChange` event when the input value\n * is different than the value when the input was focused.\n */\n this.emitValueChange(ev);\n }\n\n this.pdsBlur.emit(ev);\n };\n\n private onFocusEvent = (ev: FocusEvent) => {\n this.hasFocus = true;\n this.focusedValue = this.value;\n\n this.pdsFocus.emit(ev);\n };\n\n private onCompositionStart = () => {\n this.isComposing = true;\n }\n\n private onCompositionEnd = () => {\n this.isComposing = false;\n }\n\n /**\n * Emits a pdsChange event\n */\n private emitValueChange(event?: Event) {\n const { value } = this;\n const newValue = value == null ? value : value.toString();\n\n this.focusedValue = newValue;\n this.pdsChange.emit({ value: newValue, event });\n }\n\n /**\n * Emits a `pdsInput` event\n */\n private emitInputChange(event?: Event) {\n const { value } = this;\n\n // Checks for both null and undefined values\n const newValue = value == null ? value : value.toString();\n\n this.pdsInput.emit({ value: newValue, event });\n }\n\n render() {\n const {\n componentId,\n disabled,\n errorMessage,\n helperMessage,\n invalid = false,\n label,\n } = this;\n\n const value = this.getValue();\n\n const inputWrapperClasses = {\n 'pds-input__field-wrapper': true,\n 'has-focus': this.hasFocus,\n 'has-error': invalid || !!errorMessage,\n 'is-disabled': disabled,\n 'has-prefix': this.hasPrefix,\n 'has-suffix': this.hasSuffix,\n 'has-prepend': this.hasPrepend,\n 'has-append': this.hasAppend,\n };\n\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n aria-readonly={this.readonly ? 'true' : null}\n has-prefix={this.hasPrefix ? 'true' : null}\n has-suffix={this.hasSuffix ? 'true' : null}\n has-prepend={this.hasPrepend ? 'true' : null}\n has-append={this.hasAppend ? 'true' : null}\n >\n <div class=\"pds-input\">\n {label && (\n <label htmlFor={componentId} class=\"pds-input__label\">\n {label}\n {this.required && <span class=\"pds-input__required-indicator\"> *</span>}\n </label>\n )}\n\n <div class={inputWrapperClasses}>\n {this.renderPrepend()}\n {this.renderPrefix()}\n <input\n ref={(input) => (this.nativeInput = input)}\n class=\"pds-input__field\"\n aria-describedby={assignDescription(componentId, invalid, helperMessage)}\n aria-invalid={invalid ? \"true\" : undefined}\n autocomplete={this.autocomplete}\n disabled={disabled}\n id={componentId}\n max={this.max}\n maxlength={this.maxlength}\n min={this.min}\n minlength={this.minlength}\n name={this.name}\n pattern={this.pattern}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n step={this.step}\n type={this.type}\n value={value}\n onInput={this.onInputEvent}\n onChange={this.onChangeEvent}\n onBlur={this.onBlurEvent}\n onFocus={this.onFocusEvent}\n onCompositionstart={this.onCompositionStart}\n onCompositionend={this.onCompositionEnd}\n {...this.inheritedAttributes}\n />\n {this.renderSuffix()}\n {this.renderAppend()}\n </div>\n\n {helperMessage && (\n <p class=\"pds-input__helper-message\" id={messageId(componentId, 'helper')}>\n {helperMessage}\n </p>\n )}\n\n {errorMessage && (\n <p class=\"pds-input__error-message\" id={messageId(componentId, 'error')}>\n <pds-icon icon={danger} size=\"small\" />\n {errorMessage}\n </p>\n )}\n </div>\n </Host>\n );\n }\n}\n"]}
@@ -11,6 +11,12 @@ export default {
11
11
  errorMessage: null,
12
12
  helperMessage: null,
13
13
  invalid: false,
14
+ max: null,
15
+ maxlength: null,
16
+ min: null,
17
+ minlength: null,
18
+ pattern: null,
19
+ step: null,
14
20
  name: null,
15
21
  placeholder: null,
16
22
  readonly: false,
@@ -46,6 +52,10 @@ const BaseTemplate = (args) => html`<pds-input
46
52
  required="${args.required}"
47
53
  type="${args.type}"
48
54
  value="${args.value}">
55
+ ${args.prefix}
56
+ ${args.suffix}
57
+ ${args.prepend}
58
+ ${args.append}
49
59
  </pds-input>`;
50
60
 
51
61
  export const Text = BaseTemplate.bind({});
@@ -124,3 +134,77 @@ Autocomplete.args = {
124
134
  type: 'text',
125
135
  autocomplete: 'given-name',
126
136
  };
137
+
138
+ export const withPrefixIcon = BaseTemplate.bind({});
139
+ withPrefixIcon.args = {
140
+ componentId: 'pds-input-prefix-icon',
141
+ label: 'Email',
142
+ type: 'email',
143
+ prefix: html`<pds-icon slot="prefix" name="mail" size="small"></pds-icon>`,
144
+ };
145
+
146
+ export const withSuffixButton = BaseTemplate.bind({});
147
+ withSuffixButton.args = {
148
+ componentId: 'pds-input-suffix-button',
149
+ label: 'Search',
150
+ type: 'text',
151
+ suffix: html`<pds-button slot="suffix" variant="unstyled" class="pds-input__suffix"><pds-icon name="search" size="small"></pds-icon></pds-button>`,
152
+ };
153
+
154
+ export const withPrependSelect = BaseTemplate.bind({});
155
+ withPrependSelect.args = {
156
+ componentId: 'pds-input-prepend-select',
157
+ label: 'Amount',
158
+ type: 'text',
159
+ prepend: html`
160
+ <pds-select hide-label label="Currency" slot="prepend" class="pds-input__prepend">
161
+ <option value="USD">USD</option>
162
+ <option value="EUR">EUR</option>
163
+ <option value="GBP">GBP</option>
164
+ </pds-select>
165
+ `,
166
+ };
167
+
168
+ export const withAppendSelect = BaseTemplate.bind({});
169
+ withAppendSelect.args = {
170
+ componentId: 'pds-input-append-select',
171
+ label: 'Phone',
172
+ type: 'tel',
173
+ append: html`
174
+ <pds-select hide-label slot="append" class="pds-input__append">
175
+ <option value="mobile">Mobile</option>
176
+ <option value="home">Home</option>
177
+ <option value="work">Work</option>
178
+ </pds-select>
179
+ `,
180
+ };
181
+
182
+ export const withPrefixAndAppend = BaseTemplate.bind({});
183
+ withPrefixAndAppend.args = {
184
+ componentId: 'pds-input-prefix-append',
185
+ label: 'Amount',
186
+ type: 'text',
187
+ prefix: html`<pds-icon name="dollar" size="small"></pds-icon>`,
188
+ append: html`
189
+ <pds-select hide-label slot="append" class="pds-input__append">
190
+ <option value="USD">USD</option>
191
+ <option value="EUR">EUR</option>
192
+ <option value="GBP">GBP</option>
193
+ </pds-select>
194
+ `,
195
+ };
196
+
197
+ export const withPrependAndSuffix = BaseTemplate.bind({});
198
+ withPrependAndSuffix.args = {
199
+ componentId: 'pds-input-prepend-suffix',
200
+ label: 'Amount',
201
+ type: 'text',
202
+ prepend: html`
203
+ <pds-select hide-label slot="prepend" class="pds-input__prepend">
204
+ <option value="USD">USD</option>
205
+ <option value="EUR">EUR</option>
206
+ <option value="GBP">GBP</option>
207
+ </pds-select>
208
+ `,
209
+ suffix: html`<pds-button slot="suffix" variant="unstyled" class="pds-input__suffix"><pds-icon name="remove-circle" size="small"></pds-icon></pds-button>`,
210
+ };
@@ -45,8 +45,8 @@ export class PdsLink {
45
45
  return linkStyles;
46
46
  }
47
47
  render() {
48
- return (h("a", { key: 'bd418a8fd35a3f3b7e240c09f9dcae3bdaa49013', class: this.classNames(), href: this.href, id: this.componentId, part: "link", target: this.external ? '_blank' : undefined, style: this.setLinkStyles() }, h("slot", { key: '45aa4d6d1b2daaf4413227e39811595073f65744' }, this.href), this.external &&
49
- h("pds-icon", { key: '4b8dec593ddefb68278e3c102174ec24b63680f6', icon: launch, size: this.fontSize })));
48
+ return (h("a", { key: 'f2b3e7f26b833f7b187fce6f36c392415e2499df', class: this.classNames(), href: this.href, id: this.componentId, part: "link", target: this.external ? '_blank' : undefined, style: this.setLinkStyles() }, h("slot", { key: 'c85c0add786ab8a90f7cb0d12b75d65a51b8e313' }, this.href), this.external &&
49
+ h("pds-icon", { key: '2ce9fa8d29168659546bc95b0633815978142bbb', icon: launch, size: this.fontSize })));
50
50
  }
51
51
  static get is() { return "pds-link"; }
52
52
  static get encapsulation() { return "shadow"; }
@@ -45,7 +45,7 @@ export class PdsLoader {
45
45
  }
46
46
  }
47
47
  render() {
48
- return (h(Host, { key: '1885f34a4ea3b114fac209f543680e531059bbbc', class: `pds-loader ${this.isLoading ? '' : 'pds-loader--hidden'}`, "aria-hidden": !this.isLoading, "aria-busy": this.isLoading, "aria-live": "polite" }, this.variant === 'spinner' && (h("div", { key: '179e5c12cf4b049fc065034f0a6658ad6ddd9040', class: "pds-loader--spinner" }, h("svg", { key: '8f4ba909fc4b9fe64ea7ea37ff26ae1d835292ae', style: this.style(), viewBox: "0 0 200 200", fill: "none" }, h("defs", { key: 'ded765d5064790ad53f65a7e831e86367ce394ee' }, h("linearGradient", { key: 'a8d3bca4fb569a52e61fd3908512803b2020dc38', id: "spinner-secondHalf" }, h("stop", { key: '5c573e2545c778350b7481a4f2f468f4ae8094c0', offset: "0%", "stop-opacity": "0", "stop-color": "currentColor" }), h("stop", { key: '99ade176b1d6a84f4ae8a4d3b2c9e98954dbb519', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" })), h("linearGradient", { key: '3730c343c31190b037d0a6401a89b63640250f4a', id: "spinner-firstHalf" }, h("stop", { key: 'f989c168a08aec3cb0b3f3bbfc71483b1991aff3', offset: "0%", "stop-opacity": "1", "stop-color": "currentColor" }), h("stop", { key: '2ef58c6b7ec9058856b0fa30158182e4262396c6', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" }))), h("g", { key: '6421330f6d04f90f24207057a67e03a38985d63b', class: "pds-loader__spinner-path" }, h("path", { key: '594bf9e8c6b5c311ba2f461f873f6e5e9b6ccf27', stroke: "url(#spinner-secondHalf)", d: "M 4 100 A 96 96 0 0 1 196 100" }), h("path", { key: 'd44edd943fe5ffd3d8708232a0ca16a254e688e4', stroke: "url(#spinner-firstHalf)", d: "M 196 100 A 96 96 0 0 1 4 100" }), h("path", { key: 'ed3a5152042d5970dfa01d560ad234a8401702ca', stroke: "currentColor", "stroke-linecap": "round", d: "M 4 100 A 96 96 0 0 1 4 98" }))))), this.variant === 'typing' && (h("div", { key: 'b7c4a013453a7233b8a9090b614b1ef0e5234ccd', class: "pds-loader--typing" }, h("span", { key: '41408b1e02d88e80f8aa0468f607aad34015ff38' }), h("span", { key: 'c41fc78a3160a72875301b968da6229351953e30' }), h("span", { key: '02d33e3953dc291e60f293ac2c5906229decc4b9' }))), h("div", { key: '2e767fdad673b59d07ab1aa02aeb002eb1930d24', class: `pds-loader__label ${this.showLabel ? '' : 'pds-loader--hidden'}` }, h("slot", { key: '27956937cf99517d73c8a465457fde1c0c985c15', name: "label" }, "Loading..."))));
48
+ return (h(Host, { key: '5f9677b6338e4b1d7df0ab3182c91ecae4c5c857', class: `pds-loader ${this.isLoading ? '' : 'pds-loader--hidden'}`, "aria-hidden": !this.isLoading, "aria-busy": this.isLoading, "aria-live": "polite" }, this.variant === 'spinner' && (h("div", { key: '5083b0fd6d468439dd0faa4375107c2cddc49812', class: "pds-loader--spinner" }, h("svg", { key: '689659c659901091215e3745e1778613dc8c64dc', style: this.style(), viewBox: "0 0 200 200", fill: "none" }, h("defs", { key: '2f20b260a1155a966abb9f8d0541374d707d4c09' }, h("linearGradient", { key: '2049a48645d6c02c3e5b4a659cb3767af297172a', id: "spinner-secondHalf" }, h("stop", { key: '8a51fd7117b39505d6e40ded168c1a323f19d791', offset: "0%", "stop-opacity": "0", "stop-color": "currentColor" }), h("stop", { key: '7a5273675a64eb794b8bbe513fa3fbfddb2b8b6b', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" })), h("linearGradient", { key: '12ea88879ebbd8c207e9d5e5838505796c747fd6', id: "spinner-firstHalf" }, h("stop", { key: '08a2198273017b0feeb16ec93a1a1daed34ada94', offset: "0%", "stop-opacity": "1", "stop-color": "currentColor" }), h("stop", { key: '02ac704dd21ba49f579f0f305123b53333ae669e', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" }))), h("g", { key: 'feb3d05f93da9f8d67181864d318678d2930b1dd', class: "pds-loader__spinner-path" }, h("path", { key: 'dde73e34e0a78bdd87f33212eb21a25e0c212b4f', stroke: "url(#spinner-secondHalf)", d: "M 4 100 A 96 96 0 0 1 196 100" }), h("path", { key: 'ce0c541df6294f6b08772d89cf791f0e6342ec0b', stroke: "url(#spinner-firstHalf)", d: "M 196 100 A 96 96 0 0 1 4 100" }), h("path", { key: '25fae107003b2c9172131b54a97ecd9780ac4e42', stroke: "currentColor", "stroke-linecap": "round", d: "M 4 100 A 96 96 0 0 1 4 98" }))))), this.variant === 'typing' && (h("div", { key: '7b467d87b5d4c0dbd96a277868bc587544259cff', class: "pds-loader--typing" }, h("span", { key: '1e0833eec5fc48e990bbfa7ce4e724a1eee019ad' }), h("span", { key: 'ef517f1aafca68e77fed199552a7a468ac8b37b2' }), h("span", { key: 'b6379ba5b3e1fb88c5ce0478bb51bf4471bd6dd1' }))), h("div", { key: '6148a67bddb3749b8778f5a97d381f01096fda23', class: `pds-loader__label ${this.showLabel ? '' : 'pds-loader--hidden'}` }, h("slot", { key: '774fd7274d111b17afe9ef0740e64448c6fcd8d4', name: "label" }, "Loading..."))));
49
49
  }
50
50
  static get is() { return "pds-loader"; }
51
51
  static get encapsulation() { return "shadow"; }
@@ -72,10 +72,10 @@ export class PdsModalContent {
72
72
  }
73
73
  }
74
74
  render() {
75
- return (h(Host, { key: '4ff98a386d18f5047752cf8915fa30ea3b6805e2' }, h("div", { key: '686b6fc2263664f7b5f8178827c9e9ae9d53d086', class: {
75
+ return (h(Host, { key: '6b214e3462d8e1e1cb58d6c0075b3143e0db2d51' }, h("div", { key: '2f6a2daeb09a99f096cd46230813fe1b9a6950e9', class: {
76
76
  'pds-modal-content': true,
77
77
  [`pds-modal-content--border-${this.border}`]: true
78
- }, style: { maxHeight: this.contentMaxHeight }, tabindex: "-1" }, h("slot", { key: '4531f6ba4c499c9404704c9d3a59e1b9ef4744f9' }))));
78
+ }, style: { maxHeight: this.contentMaxHeight }, tabindex: "-1" }, h("slot", { key: '8392cc48a2dba0f32d4a83e642bd3f295832251b' }))));
79
79
  }
80
80
  static get is() { return "pds-modal-content"; }
81
81
  static get originalStyleUrls() {
@@ -1,7 +1,7 @@
1
1
  import { h } from "@stencil/core";
2
2
  export class PdsModalFooter {
3
3
  render() {
4
- return (h("footer", { key: 'ea47425a063c04c1cdff3481fc09f32bd65b7679', class: "pds-modal__footer" }, h("slot", { key: '55c560cb8cca95687eb04ba727ae45542ef2209f' })));
4
+ return (h("footer", { key: '63d1121b84d10ea99354d07b029b7625d52d9095', class: "pds-modal__footer" }, h("slot", { key: 'dd08fc600f122e422ccd3161bc558f3b9cc075f9' })));
5
5
  }
6
6
  static get is() { return "pds-modal-footer"; }
7
7
  static get originalStyleUrls() {
@@ -1,7 +1,7 @@
1
1
  import { h } from "@stencil/core";
2
2
  export class PdsModalHeader {
3
3
  render() {
4
- return (h("header", { key: '63d1121b84d10ea99354d07b029b7625d52d9095', class: "pds-modal__header" }, h("slot", { key: 'dd08fc600f122e422ccd3161bc558f3b9cc075f9' })));
4
+ return (h("header", { key: 'c832013aee204170c29336e931d36f1eda667f11', class: "pds-modal__header" }, h("slot", { key: '19a76b689a8d8bf116f7061fd7c32415da4299e1' })));
5
5
  }
6
6
  static get is() { return "pds-modal-header"; }
7
7
  static get originalStyleUrls() {
@@ -227,10 +227,10 @@ export class PdsModal {
227
227
  return thisZIndex === maxZIndex;
228
228
  }
229
229
  render() {
230
- return (h("dialog", { key: 'c27d56b7717f739fb8ed7a243e0715a806ed3b0c', class: {
230
+ return (h("dialog", { key: '6ec691cfcf4865baeeba14f097d5e647a3201dba', class: {
231
231
  'pds-modal__backdrop': true,
232
232
  'open': this.open
233
- }, "aria-modal": "true", "aria-labelledby": `${this.componentId}-heading`, onClick: this.handleBackdropClick }, h("div", { key: '083bfc9fa7ec82b9f5deb9b49f19d10abfc5c912', class: `pds-modal pds-modal--${this.size} pds-modal--scrollable` }, h("slot", { key: '2c47ddf024a9b1b7824de478f8d15a4af74627bb' }))));
233
+ }, "aria-modal": "true", "aria-labelledby": `${this.componentId}-heading`, onClick: this.handleBackdropClick }, h("div", { key: 'b7c4681717bfc0d095653c7dcf1a0e42cf069e8b', class: `pds-modal pds-modal--${this.size} pds-modal--scrollable` }, h("slot", { key: '9ca7f711579587c2f49fd19f81a488192d62ce72' }))));
234
234
  }
235
235
  static get is() { return "pds-modal"; }
236
236
  static get originalStyleUrls() {
@@ -69,7 +69,7 @@ export class MockPdsModal {
69
69
  'pds-modal__backdrop': true,
70
70
  'open': this.open,
71
71
  };
72
- return (h("div", { key: 'fb141b585e21257f4e2b1e189211ffd8fdbf5f21', class: backdropClasses }, h("div", { key: '2431265c962c17042b79e59e8799159c0af79bba', class: modalClasses, role: "dialog", "aria-modal": "true", "aria-labelledby": this.componentId ? `${this.componentId}-heading` : null }, h("div", { key: '122d233ca19497ccd8541474343442391a9fd60b', class: "pds-modal__header" }, h("slot", { key: 'abb92bd56f45ac7a1007649952eb6351dbe1193d', name: "header" })), h("div", { key: 'fb096821bccb813311f3047bb33a81374808a99d', class: "pds-modal-content" }, h("slot", { key: '79400555ec3420db6eda65f12b90060b5507c96e' })), h("div", { key: '60462c314237b4b573c222df26aa41073437f298', class: "pds-modal__footer" }, h("slot", { key: '9253219fc90477c4c86df974f4a6a196f693e548', name: "footer" })))));
72
+ return (h("div", { key: 'e61d355aaf75d5adc97a3e930f898e075f54d931', class: backdropClasses }, h("div", { key: '059c930eb27b9420ca294b2a7c07e53b15ce1c91', class: modalClasses, role: "dialog", "aria-modal": "true", "aria-labelledby": this.componentId ? `${this.componentId}-heading` : null }, h("div", { key: '9b2423c26eb6f015ee68f73805bd50965a32b5b0', class: "pds-modal__header" }, h("slot", { key: '770d212b20667a1ea4dce88a345f4cbbed363e52', name: "header" })), h("div", { key: '51821cd7d5323ae4543d354589ceabebf0c0ccb0', class: "pds-modal-content" }, h("slot", { key: '475b5844c8f9ac44d7fc366b95ca282a908e0cbb' })), h("div", { key: 'eb67b8e10942d51824296b82947025f8afee8a24', class: "pds-modal__footer" }, h("slot", { key: 'b66c31cd4abfb8d30d5dc66735a367d99f149559', name: "footer" })))));
73
73
  }
74
74
  static get is() { return "mock-pds-modal"; }
75
75
  static get originalStyleUrls() {
@@ -102,7 +102,7 @@ export class PdsPopover {
102
102
  popoverEl.style.left = `${left}px`;
103
103
  }
104
104
  render() {
105
- return (h(Host, { key: 'b150645b71d528055c6cd6cf2ff9c898c3fe1f3f' }, h("button", { key: '3090efe8ffd85d0d3e4d5dc5f54147a5aff61fb9', class: "pds-popover__trigger", popoverTarget: this.componentId, popoverTargetAction: this.popoverTargetAction, onClick: this.handleClick }, this.text), h("div", { key: '6e9b4af0278507b6f8bf4b5f2d8c3a2891f974b6', class: `pds-popover ${this.active ? 'pds-popover--active' : ''}`, id: this.componentId, popover: this.popoverType, style: { maxWidth: `${this.maxWidth}px` } }, h("slot", { key: 'f4303d3f3aca19314413b86d3973c8d9f1477e8f' }))));
105
+ return (h(Host, { key: '35e5f4c21884f02b17dcb920e5c7ba73b8bed849' }, h("button", { key: '586880a84a4ad659a00500206e5b3c6c5e7e1a37', class: "pds-popover__trigger", popoverTarget: this.componentId, popoverTargetAction: this.popoverTargetAction, onClick: this.handleClick }, this.text), h("div", { key: 'fcb97e9b4033eef58bdca4915572b986dabde43c', class: `pds-popover ${this.active ? 'pds-popover--active' : ''}`, id: this.componentId, popover: this.popoverType, style: { maxWidth: `${this.maxWidth}px` } }, h("slot", { key: '1ffb626c69e06f17379ebf4ff4d5498f030909e8' }))));
106
106
  }
107
107
  static get is() { return "pds-popover"; }
108
108
  static get encapsulation() { return "shadow"; }
@@ -18,7 +18,7 @@ export class PdsProgress {
18
18
  this.showPercent = false;
19
19
  }
20
20
  render() {
21
- return (h(Host, { key: '71ce602dccee62ee76ef51c3994af86829399452', class: this.animated ? { 'is-animated': this.animated } : '' }, h("div", { key: 'c26188786bcfd4d6f039050032cd48982327355e', class: "pds-progress" }, h("label", { key: 'e18f75dae8fcf3fde684156638cc47f9d5e253dd', class: "pds-progress__label", htmlFor: this.componentId }, this.label), h("progress", { key: '37a5bb5609e25912c006a89dd0bbc244cfa5896b', id: this.componentId, max: "100", style: this.fillColor ? { '--color-progress-fill': this.fillColor } : {}, value: this.percent })), this.showPercent && h("div", { key: '68e859cafbcf74c74fc3b72a5347fb03eda83556', class: "pds-progress__percentage" }, this.percent, "%")));
21
+ return (h(Host, { key: '2a7768cc769f62579bfee6d8f9e6109d10df0aaf', class: this.animated ? { 'is-animated': this.animated } : '' }, h("div", { key: '1eef3758e8c6e470f8cdd170e8d6c49e25bf9aa3', class: "pds-progress" }, h("label", { key: '5b75150a747a15379fdf0ee23b1be561e6d990e7', class: "pds-progress__label", htmlFor: this.componentId }, this.label), h("progress", { key: 'e20ad7d705d97ac11173ae515332fc1620a96328', id: this.componentId, max: "100", style: this.fillColor ? { '--color-progress-fill': this.fillColor } : {}, value: this.percent })), this.showPercent && h("div", { key: '8bafb39b5976149b80e720952e625f60f1e3c73c', class: "pds-progress__percentage" }, this.percent, "%")));
22
22
  }
23
23
  static get is() { return "pds-progress"; }
24
24
  static get encapsulation() { return "shadow"; }
@@ -43,9 +43,9 @@ export class PdsRadio {
43
43
  return classNames.join(' ');
44
44
  }
45
45
  render() {
46
- return (h(Host, { key: 'a31d9cd94150a104a83595043dc003fa5d9779a2', class: this.classNames() }, h("label", { key: '1d71e515a00c25bbaac7d0420f4a4ee6a5189836', htmlFor: this.componentId }, h("input", { key: '800b2bbf703e68fbf60f62d6c28228759d976436', "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, type: "radio", id: this.componentId, name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, onChange: this.handleRadioChange }), h("span", { key: '33c241168498b07a25dfc5ac6f9244eb3ce93547', class: this.hideLabel ? 'visually-hidden' : '' }, this.label)), this.helperMessage &&
47
- h("div", { key: 'f159de72b68a0f1bf07abb52d50a0d6d89b4f766', class: 'pds-radio__message', id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
48
- h("div", { key: 'fb5877c78e519db27964308c1607ab58fc2fcb08', class: `pds-radio__message pds-radio__message--error`, id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: '1385571ed511a800778d64edf48e2853a1c4793e', icon: danger, size: "small" }), this.errorMessage)));
46
+ return (h(Host, { key: '8c215fa4193cf8bd246cd83edf97b8316685714e', class: this.classNames() }, h("label", { key: '578530f26dd25f73ccbbb39c773290cd275920cf', htmlFor: this.componentId }, h("input", { key: '9ab61a2683246fae862feb5e432a0872288b7a87', "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, type: "radio", id: this.componentId, name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, onChange: this.handleRadioChange }), h("span", { key: 'f48c47ddb347bf0d7388359665dbbf3abf1b4859', class: this.hideLabel ? 'visually-hidden' : '' }, this.label)), this.helperMessage &&
47
+ h("div", { key: 'b8dbb34af90eed82f69621ceaadd8da668f0b3de', class: 'pds-radio__message', id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
48
+ h("div", { key: 'e777e4f2397ba833aefb7e8cd4ab9a32ea93685a', class: `pds-radio__message pds-radio__message--error`, id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: '13bd73d91bb3d676757ac9f4dcfcef7d2a5fcc55', icon: danger, size: "small" }), this.errorMessage)));
49
49
  }
50
50
  static get is() { return "pds-radio"; }
51
51
  static get encapsulation() { return "scoped"; }