@quartzds/core 1.0.0-beta.13 → 1.0.0-beta.130

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 (444) hide show
  1. package/CHANGELOG.md +2145 -0
  2. package/README.md +23 -23
  3. package/components/index.d.ts +52 -0
  4. package/components/index.js +63 -28
  5. package/components/index.js.map +1 -1
  6. package/components/p-B9xuNEzc.js +438 -0
  7. package/components/p-B9xuNEzc.js.map +1 -0
  8. package/components/p-BHBodFuD.js +200 -0
  9. package/components/p-BHBodFuD.js.map +1 -0
  10. package/components/p-BLA62eFO.js +513 -0
  11. package/components/p-BLA62eFO.js.map +1 -0
  12. package/components/p-Bn9o5Um2.js +91 -0
  13. package/components/p-Bn9o5Um2.js.map +1 -0
  14. package/components/{floating-ui.dom.esm.js → p-Bv2vPjgL.js} +557 -345
  15. package/components/p-Bv2vPjgL.js.map +1 -0
  16. package/components/p-C-pZcrGt.js +357 -0
  17. package/components/p-C-pZcrGt.js.map +1 -0
  18. package/components/p-CZRW1LV_.js +28 -0
  19. package/components/p-CZRW1LV_.js.map +1 -0
  20. package/components/p-Cb4tcewD.js +281 -0
  21. package/components/p-Cb4tcewD.js.map +1 -0
  22. package/components/p-Cb5Tgh-o.js +102 -0
  23. package/components/p-Cb5Tgh-o.js.map +1 -0
  24. package/components/p-D2489VzR.js +2133 -0
  25. package/components/p-D2489VzR.js.map +1 -0
  26. package/components/p-D2BuSQre.js +160 -0
  27. package/components/p-D2BuSQre.js.map +1 -0
  28. package/components/p-DL21f4D7.js +149 -0
  29. package/components/p-DL21f4D7.js.map +1 -0
  30. package/components/p-DOqfdgQA.js +124 -0
  31. package/components/p-DOqfdgQA.js.map +1 -0
  32. package/components/p-Do46q_Gd.js +135 -0
  33. package/components/p-Do46q_Gd.js.map +1 -0
  34. package/components/p-XP2CY_fo.js +105 -0
  35. package/components/p-XP2CY_fo.js.map +1 -0
  36. package/components/p-eUDNu0SE.js +3561 -0
  37. package/components/p-eUDNu0SE.js.map +1 -0
  38. package/components/p-fKK7EmM2.js +256 -0
  39. package/components/p-fKK7EmM2.js.map +1 -0
  40. package/components/qds-action-item.d.ts +11 -0
  41. package/components/qds-action-item.js +204 -0
  42. package/components/qds-action-item.js.map +1 -0
  43. package/components/qds-avatar-media.d.ts +11 -0
  44. package/components/qds-avatar-media.js +14 -0
  45. package/components/qds-avatar-media.js.map +1 -0
  46. package/components/qds-avatar.d.ts +11 -0
  47. package/components/qds-avatar.js +120 -0
  48. package/components/qds-avatar.js.map +1 -0
  49. package/components/qds-badge-counter.d.ts +11 -0
  50. package/components/qds-badge-counter.js +14 -0
  51. package/components/qds-badge-counter.js.map +1 -0
  52. package/components/qds-badge-indicator.d.ts +11 -0
  53. package/components/qds-badge-indicator.js +14 -0
  54. package/components/qds-badge-indicator.js.map +1 -0
  55. package/components/qds-breadcrumb-item.d.ts +11 -0
  56. package/components/qds-breadcrumb-item.js +174 -0
  57. package/components/qds-breadcrumb-item.js.map +1 -0
  58. package/components/qds-button.d.ts +2 -2
  59. package/components/qds-button.js +475 -129
  60. package/components/qds-button.js.map +1 -1
  61. package/components/qds-checkbox.d.ts +2 -2
  62. package/components/qds-checkbox.js +4 -146
  63. package/components/qds-checkbox.js.map +1 -1
  64. package/components/qds-chip.d.ts +11 -0
  65. package/components/qds-chip.js +337 -0
  66. package/components/qds-chip.js.map +1 -0
  67. package/components/qds-dialog.d.ts +2 -2
  68. package/components/qds-dialog.js +179 -93
  69. package/components/qds-dialog.js.map +1 -1
  70. package/components/qds-divider.d.ts +2 -2
  71. package/components/qds-divider.js +4 -39
  72. package/components/qds-divider.js.map +1 -1
  73. package/components/qds-dropdown.d.ts +2 -2
  74. package/components/qds-dropdown.js +4 -249
  75. package/components/qds-dropdown.js.map +1 -1
  76. package/components/qds-form-message.d.ts +2 -2
  77. package/components/qds-form-message.js +106 -50
  78. package/components/qds-form-message.js.map +1 -1
  79. package/components/qds-icon-button.d.ts +11 -0
  80. package/components/qds-icon-button.js +14 -0
  81. package/components/qds-icon-button.js.map +1 -0
  82. package/components/qds-icon-tab.d.ts +11 -0
  83. package/components/qds-icon-tab.js +312 -0
  84. package/components/qds-icon-tab.js.map +1 -0
  85. package/components/qds-icon.d.ts +2 -2
  86. package/components/qds-icon.js +4 -3
  87. package/components/qds-inline-link.d.ts +2 -2
  88. package/components/qds-inline-link.js +173 -74
  89. package/components/qds-inline-link.js.map +1 -1
  90. package/components/qds-input.d.ts +2 -2
  91. package/components/qds-input.js +579 -230
  92. package/components/qds-input.js.map +1 -1
  93. package/components/qds-label.d.ts +2 -2
  94. package/components/qds-label.js +156 -3
  95. package/components/qds-label.js.map +1 -1
  96. package/components/qds-list-item.d.ts +11 -0
  97. package/components/qds-list-item.js +430 -0
  98. package/components/qds-list-item.js.map +1 -0
  99. package/components/qds-loader.d.ts +11 -0
  100. package/components/qds-loader.js +152 -0
  101. package/components/qds-loader.js.map +1 -0
  102. package/components/qds-menu-item.d.ts +11 -0
  103. package/components/qds-menu-item.js +263 -0
  104. package/components/qds-menu-item.js.map +1 -0
  105. package/components/qds-mini-button.d.ts +11 -0
  106. package/components/qds-mini-button.js +14 -0
  107. package/components/qds-mini-button.js.map +1 -0
  108. package/components/qds-progress-bar.d.ts +11 -0
  109. package/components/qds-progress-bar.js +155 -0
  110. package/components/qds-progress-bar.js.map +1 -0
  111. package/components/qds-radio.d.ts +2 -2
  112. package/components/qds-radio.js +4 -99
  113. package/components/qds-radio.js.map +1 -1
  114. package/components/qds-select.d.ts +11 -0
  115. package/components/qds-select.js +377 -0
  116. package/components/qds-select.js.map +1 -0
  117. package/components/qds-standalone-link.d.ts +11 -0
  118. package/components/qds-standalone-link.js +210 -0
  119. package/components/qds-standalone-link.js.map +1 -0
  120. package/components/qds-switch.d.ts +2 -2
  121. package/components/qds-switch.js +257 -105
  122. package/components/qds-switch.js.map +1 -1
  123. package/components/qds-tab.d.ts +11 -0
  124. package/components/qds-tab.js +354 -0
  125. package/components/qds-tab.js.map +1 -0
  126. package/components/qds-tabbar.d.ts +11 -0
  127. package/components/qds-tabbar.js +599 -0
  128. package/components/qds-tabbar.js.map +1 -0
  129. package/components/qds-table-cell.d.ts +11 -0
  130. package/components/qds-table-cell.js +109 -0
  131. package/components/qds-table-cell.js.map +1 -0
  132. package/components/qds-table-head-cell.d.ts +11 -0
  133. package/components/qds-table-head-cell.js +115 -0
  134. package/components/qds-table-head-cell.js.map +1 -0
  135. package/components/qds-table-row.d.ts +11 -0
  136. package/components/qds-table-row.js +48 -0
  137. package/components/qds-table-row.js.map +1 -0
  138. package/components/qds-table.d.ts +11 -0
  139. package/components/qds-table.js +48 -0
  140. package/components/qds-table.js.map +1 -0
  141. package/components/qds-tag.d.ts +11 -0
  142. package/components/qds-tag.js +14 -0
  143. package/components/qds-tag.js.map +1 -0
  144. package/components/qds-textarea.d.ts +2 -2
  145. package/components/qds-textarea.js +352 -193
  146. package/components/qds-textarea.js.map +1 -1
  147. package/components/qds-title.d.ts +2 -2
  148. package/components/qds-title.js +4 -84
  149. package/components/qds-title.js.map +1 -1
  150. package/components/qds-tooltip.d.ts +2 -2
  151. package/components/qds-tooltip.js +4 -315
  152. package/components/qds-tooltip.js.map +1 -1
  153. package/dist/cjs/app-globals-CLoao1by.js +13 -0
  154. package/dist/cjs/app-globals-CLoao1by.js.map +1 -0
  155. package/dist/cjs/controls-DKGeNyr5.js +32 -0
  156. package/dist/cjs/controls-DKGeNyr5.js.map +1 -0
  157. package/dist/cjs/{floating-ui.dom.esm-7f1cac3e.js → floating-ui.dom-Bvzubd50.js} +557 -345
  158. package/dist/cjs/floating-ui.dom-Bvzubd50.js.map +1 -0
  159. package/dist/cjs/helpers-D6srVOLt.js +3584 -0
  160. package/dist/cjs/helpers-D6srVOLt.js.map +1 -0
  161. package/dist/cjs/index-DIY7gpXM.js +2376 -0
  162. package/dist/cjs/index-DIY7gpXM.js.map +1 -0
  163. package/dist/cjs/index.cjs.js +40 -31
  164. package/dist/cjs/index.cjs.js.map +1 -1
  165. package/dist/cjs/library-CeKRI2f2.js +142 -0
  166. package/dist/cjs/library-CeKRI2f2.js.map +1 -0
  167. package/dist/cjs/loader.cjs.js +9 -10
  168. package/dist/cjs/loader.cjs.js.map +1 -1
  169. package/dist/cjs/qds-action-item.cjs.entry.js +165 -0
  170. package/dist/cjs/qds-action-item.entry.cjs.js.map +1 -0
  171. package/dist/cjs/qds-avatar-media.cjs.entry.js +105 -0
  172. package/dist/cjs/qds-avatar-media.entry.cjs.js.map +1 -0
  173. package/dist/cjs/qds-avatar.cjs.entry.js +70 -0
  174. package/dist/cjs/qds-avatar.entry.cjs.js.map +1 -0
  175. package/dist/cjs/qds-badge-counter.qds-badge-indicator.entry.cjs.js.map +1 -0
  176. package/dist/cjs/qds-badge-counter_2.cjs.entry.js +168 -0
  177. package/dist/cjs/qds-breadcrumb-item.cjs.entry.js +134 -0
  178. package/dist/cjs/qds-breadcrumb-item.entry.cjs.js.map +1 -0
  179. package/dist/cjs/qds-button.cjs.entry.js +402 -93
  180. package/dist/cjs/qds-button.entry.cjs.js.map +1 -0
  181. package/dist/cjs/qds-checkbox.qds-radio.entry.cjs.js.map +1 -0
  182. package/dist/cjs/qds-checkbox_2.cjs.entry.js +456 -0
  183. package/dist/cjs/qds-chip.cjs.entry.js +285 -0
  184. package/dist/cjs/qds-chip.entry.cjs.js.map +1 -0
  185. package/dist/cjs/qds-dialog.cjs.entry.js +124 -77
  186. package/dist/cjs/qds-dialog.entry.cjs.js.map +1 -0
  187. package/dist/cjs/qds-divider.qds-icon-button.entry.cjs.js.map +1 -0
  188. package/dist/cjs/qds-divider_2.cjs.entry.js +291 -0
  189. package/dist/cjs/qds-dropdown.cjs.entry.js +461 -213
  190. package/dist/cjs/qds-dropdown.entry.cjs.js.map +1 -0
  191. package/dist/cjs/qds-form-message.cjs.entry.js +80 -27
  192. package/dist/cjs/qds-form-message.entry.cjs.js.map +1 -0
  193. package/dist/cjs/qds-icon-tab.cjs.entry.js +244 -0
  194. package/dist/cjs/qds-icon-tab.entry.cjs.js.map +1 -0
  195. package/dist/cjs/qds-icon.cjs.entry.js +92 -93
  196. package/dist/cjs/qds-icon.entry.cjs.js.map +1 -0
  197. package/dist/cjs/qds-inline-link.cjs.entry.js +139 -49
  198. package/dist/cjs/qds-inline-link.entry.cjs.js.map +1 -0
  199. package/dist/cjs/qds-input.cjs.entry.js +503 -188
  200. package/dist/cjs/qds-input.entry.cjs.js.map +1 -0
  201. package/dist/cjs/qds-label.cjs.entry.js +118 -27
  202. package/dist/cjs/qds-label.entry.cjs.js.map +1 -0
  203. package/dist/cjs/qds-list-item.cjs.entry.js +328 -0
  204. package/dist/cjs/qds-list-item.entry.cjs.js.map +1 -0
  205. package/dist/cjs/qds-loader.cjs.entry.js +126 -0
  206. package/dist/cjs/qds-loader.entry.cjs.js.map +1 -0
  207. package/dist/cjs/qds-menu-item.cjs.entry.js +214 -0
  208. package/dist/cjs/qds-menu-item.entry.cjs.js.map +1 -0
  209. package/dist/cjs/qds-mini-button.cjs.entry.js +130 -0
  210. package/dist/cjs/qds-mini-button.entry.cjs.js.map +1 -0
  211. package/dist/cjs/qds-progress-bar.cjs.entry.js +131 -0
  212. package/dist/cjs/qds-progress-bar.entry.cjs.js.map +1 -0
  213. package/dist/cjs/qds-select.cjs.entry.js +331 -0
  214. package/dist/cjs/qds-select.entry.cjs.js.map +1 -0
  215. package/dist/cjs/qds-standalone-link.cjs.entry.js +171 -0
  216. package/dist/cjs/qds-standalone-link.entry.cjs.js.map +1 -0
  217. package/dist/cjs/qds-switch.cjs.entry.js +221 -67
  218. package/dist/cjs/qds-switch.entry.cjs.js.map +1 -0
  219. package/dist/cjs/qds-tab.cjs.entry.js +280 -0
  220. package/dist/cjs/qds-tab.entry.cjs.js.map +1 -0
  221. package/dist/cjs/qds-tabbar.cjs.entry.js +528 -0
  222. package/dist/cjs/qds-tabbar.entry.cjs.js.map +1 -0
  223. package/dist/cjs/qds-table-cell.cjs.entry.js +88 -0
  224. package/dist/cjs/qds-table-cell.entry.cjs.js.map +1 -0
  225. package/dist/cjs/qds-table-head-cell.cjs.entry.js +92 -0
  226. package/dist/cjs/qds-table-head-cell.entry.cjs.js.map +1 -0
  227. package/dist/cjs/qds-table-row.cjs.entry.js +34 -0
  228. package/dist/cjs/qds-table-row.entry.cjs.js.map +1 -0
  229. package/dist/cjs/qds-table.cjs.entry.js +34 -0
  230. package/dist/cjs/qds-table.entry.cjs.js.map +1 -0
  231. package/dist/cjs/qds-tag.cjs.entry.js +110 -0
  232. package/dist/cjs/qds-tag.entry.cjs.js.map +1 -0
  233. package/dist/cjs/qds-textarea.cjs.entry.js +303 -156
  234. package/dist/cjs/qds-textarea.entry.cjs.js.map +1 -0
  235. package/dist/cjs/qds-title.cjs.entry.js +61 -52
  236. package/dist/cjs/qds-title.entry.cjs.js.map +1 -0
  237. package/dist/cjs/qds-tooltip.cjs.entry.js +380 -264
  238. package/dist/cjs/qds-tooltip.entry.cjs.js.map +1 -0
  239. package/dist/cjs/qds.cjs.js +18 -17
  240. package/dist/cjs/qds.cjs.js.map +1 -1
  241. package/dist/custom-elements.json +13254 -2143
  242. package/dist/docs.d.ts +344 -240
  243. package/dist/docs.json +13958 -3308
  244. package/dist/esm/app-globals-WylVyaRG.js +11 -0
  245. package/dist/esm/app-globals-WylVyaRG.js.map +1 -0
  246. package/dist/esm/controls-CZRW1LV_.js +28 -0
  247. package/dist/esm/controls-CZRW1LV_.js.map +1 -0
  248. package/dist/esm/{floating-ui.dom.esm-c2f3e549.js → floating-ui.dom-Bv2vPjgL.js} +557 -345
  249. package/dist/esm/floating-ui.dom-Bv2vPjgL.js.map +1 -0
  250. package/dist/esm/helpers-BIo9VDPx.js +3561 -0
  251. package/dist/esm/helpers-BIo9VDPx.js.map +1 -0
  252. package/dist/esm/index-Hg1Liloy.js +2364 -0
  253. package/dist/esm/index-Hg1Liloy.js.map +1 -0
  254. package/dist/esm/index.js +40 -30
  255. package/dist/esm/index.js.map +1 -1
  256. package/dist/esm/library-CBfntPWH.js +138 -0
  257. package/dist/esm/library-CBfntPWH.js.map +1 -0
  258. package/dist/esm/loader.js +10 -9
  259. package/dist/esm/loader.js.map +1 -1
  260. package/dist/esm/qds-action-item.entry.js +163 -0
  261. package/dist/esm/qds-action-item.entry.js.map +1 -0
  262. package/dist/esm/qds-avatar-media.entry.js +103 -0
  263. package/dist/esm/qds-avatar-media.entry.js.map +1 -0
  264. package/dist/esm/qds-avatar.entry.js +68 -0
  265. package/dist/esm/qds-avatar.entry.js.map +1 -0
  266. package/dist/esm/qds-badge-counter.qds-badge-indicator.entry.js.map +1 -0
  267. package/dist/esm/qds-badge-counter_2.entry.js +165 -0
  268. package/dist/esm/qds-breadcrumb-item.entry.js +132 -0
  269. package/dist/esm/qds-breadcrumb-item.entry.js.map +1 -0
  270. package/dist/esm/qds-button.entry.js +402 -91
  271. package/dist/esm/qds-button.entry.js.map +1 -1
  272. package/dist/esm/qds-checkbox.qds-radio.entry.js.map +1 -0
  273. package/dist/esm/qds-checkbox_2.entry.js +453 -0
  274. package/dist/esm/qds-chip.entry.js +283 -0
  275. package/dist/esm/qds-chip.entry.js.map +1 -0
  276. package/dist/esm/qds-dialog.entry.js +124 -75
  277. package/dist/esm/qds-dialog.entry.js.map +1 -1
  278. package/dist/esm/qds-divider.qds-icon-button.entry.js.map +1 -0
  279. package/dist/esm/qds-divider_2.entry.js +288 -0
  280. package/dist/esm/qds-dropdown.entry.js +461 -211
  281. package/dist/esm/qds-dropdown.entry.js.map +1 -1
  282. package/dist/esm/qds-form-message.entry.js +80 -25
  283. package/dist/esm/qds-form-message.entry.js.map +1 -1
  284. package/dist/esm/qds-icon-tab.entry.js +242 -0
  285. package/dist/esm/qds-icon-tab.entry.js.map +1 -0
  286. package/dist/esm/qds-icon.entry.js +92 -91
  287. package/dist/esm/qds-icon.entry.js.map +1 -1
  288. package/dist/esm/qds-inline-link.entry.js +139 -47
  289. package/dist/esm/qds-inline-link.entry.js.map +1 -1
  290. package/dist/esm/qds-input.entry.js +503 -186
  291. package/dist/esm/qds-input.entry.js.map +1 -1
  292. package/dist/esm/qds-label.entry.js +118 -25
  293. package/dist/esm/qds-label.entry.js.map +1 -1
  294. package/dist/esm/qds-list-item.entry.js +326 -0
  295. package/dist/esm/qds-list-item.entry.js.map +1 -0
  296. package/dist/esm/qds-loader.entry.js +124 -0
  297. package/dist/esm/qds-loader.entry.js.map +1 -0
  298. package/dist/esm/qds-menu-item.entry.js +212 -0
  299. package/dist/esm/qds-menu-item.entry.js.map +1 -0
  300. package/dist/esm/qds-mini-button.entry.js +128 -0
  301. package/dist/esm/qds-mini-button.entry.js.map +1 -0
  302. package/dist/esm/qds-progress-bar.entry.js +129 -0
  303. package/dist/esm/qds-progress-bar.entry.js.map +1 -0
  304. package/dist/esm/qds-select.entry.js +329 -0
  305. package/dist/esm/qds-select.entry.js.map +1 -0
  306. package/dist/esm/qds-standalone-link.entry.js +169 -0
  307. package/dist/esm/qds-standalone-link.entry.js.map +1 -0
  308. package/dist/esm/qds-switch.entry.js +221 -65
  309. package/dist/esm/qds-switch.entry.js.map +1 -1
  310. package/dist/esm/qds-tab.entry.js +278 -0
  311. package/dist/esm/qds-tab.entry.js.map +1 -0
  312. package/dist/esm/qds-tabbar.entry.js +526 -0
  313. package/dist/esm/qds-tabbar.entry.js.map +1 -0
  314. package/dist/esm/qds-table-cell.entry.js +86 -0
  315. package/dist/esm/qds-table-cell.entry.js.map +1 -0
  316. package/dist/esm/qds-table-head-cell.entry.js +90 -0
  317. package/dist/esm/qds-table-head-cell.entry.js.map +1 -0
  318. package/dist/esm/qds-table-row.entry.js +32 -0
  319. package/dist/esm/qds-table-row.entry.js.map +1 -0
  320. package/dist/esm/qds-table.entry.js +32 -0
  321. package/dist/esm/qds-table.entry.js.map +1 -0
  322. package/dist/esm/qds-tag.entry.js +108 -0
  323. package/dist/esm/qds-tag.entry.js.map +1 -0
  324. package/dist/esm/qds-textarea.entry.js +303 -154
  325. package/dist/esm/qds-textarea.entry.js.map +1 -1
  326. package/dist/esm/qds-title.entry.js +61 -50
  327. package/dist/esm/qds-title.entry.js.map +1 -1
  328. package/dist/esm/qds-tooltip.entry.js +380 -262
  329. package/dist/esm/qds-tooltip.entry.js.map +1 -1
  330. package/dist/esm/qds.js +18 -16
  331. package/dist/esm/qds.js.map +1 -1
  332. package/dist/types/components/action-item/action-item.d.ts +70 -0
  333. package/dist/types/components/avatar/avatar.d.ts +61 -0
  334. package/dist/types/components/avatar-media/avatar-media.d.ts +47 -0
  335. package/dist/types/components/badge-counter/badge-counter.d.ts +40 -0
  336. package/dist/types/components/badge-indicator/badge-indicator.d.ts +36 -0
  337. package/dist/types/components/breadcrumb-item/breadcrumb-item.d.ts +178 -0
  338. package/dist/types/components/button/button.d.ts +283 -198
  339. package/dist/types/components/checkbox/checkbox.d.ts +142 -124
  340. package/dist/types/components/chip/chip.d.ts +111 -0
  341. package/dist/types/components/controls.d.ts +4 -1
  342. package/dist/types/components/dialog/dialog.d.ts +32 -41
  343. package/dist/types/components/divider/divider.d.ts +14 -9
  344. package/dist/types/components/dropdown/dropdown.d.ts +117 -125
  345. package/dist/types/components/form-message/form-message.d.ts +35 -25
  346. package/dist/types/components/icon/icon.d.ts +23 -24
  347. package/dist/types/components/icon/library.d.ts +3 -3
  348. package/dist/types/components/icon/request.d.ts +5 -9
  349. package/dist/types/components/icon-button/icon-button.d.ts +122 -0
  350. package/dist/types/components/icon-tab/icon-tab.d.ts +112 -0
  351. package/dist/types/components/inline-link/inline-link.d.ts +209 -191
  352. package/dist/types/components/input/input.d.ts +441 -368
  353. package/dist/types/components/label/label.d.ts +37 -24
  354. package/dist/types/components/list-item/list-item.d.ts +122 -0
  355. package/dist/types/components/loader/loader.d.ts +32 -0
  356. package/dist/types/components/menu-item/menu-item.d.ts +75 -0
  357. package/dist/types/components/mini-button/mini-button.d.ts +82 -0
  358. package/dist/types/components/progress-bar/progress-bar.d.ts +60 -0
  359. package/dist/types/components/radio/radio.d.ts +94 -95
  360. package/dist/types/components/select/select.d.ts +209 -0
  361. package/dist/types/components/shared.d.ts +6 -0
  362. package/dist/types/components/standalone-link/standalone-link.d.ts +234 -0
  363. package/dist/types/components/switch/switch.d.ts +122 -107
  364. package/dist/types/components/tab/tab.d.ts +157 -0
  365. package/dist/types/components/tabbar/tabbar.d.ts +91 -0
  366. package/dist/types/components/table/table.d.ts +14 -0
  367. package/dist/types/components/table-cell/table-cell.d.ts +39 -0
  368. package/dist/types/components/table-head-cell/table-head-cell.d.ts +56 -0
  369. package/dist/types/components/table-row/table-row.d.ts +14 -0
  370. package/dist/types/components/tag/tag.d.ts +55 -0
  371. package/dist/types/components/textarea/textarea.d.ts +295 -300
  372. package/dist/types/components/title/title.d.ts +39 -32
  373. package/dist/types/components/tooltip/tooltip.d.ts +111 -136
  374. package/dist/types/components.d.ts +4590 -929
  375. package/dist/types/helpers.d.ts +46 -19
  376. package/dist/types/index.d.ts +2 -1
  377. package/dist/types/interface-overrides.d.ts +215 -0
  378. package/dist/types/qds-test.d.ts +22 -11
  379. package/dist/types/stencil-public-runtime.d.ts +109 -17
  380. package/dist/types/utils.d.ts +11 -4
  381. package/dist/vscode.html-custom-data.json +2543 -426
  382. package/hydrate/index.d.ts +73 -18
  383. package/hydrate/index.js +32000 -9062
  384. package/hydrate/index.mjs +33081 -0
  385. package/hydrate/package.json +7 -1
  386. package/loader/cdn.js +3 -4
  387. package/loader/index.cjs.js +3 -4
  388. package/loader/index.d.ts +4 -1
  389. package/loader/index.es2017.js +3 -4
  390. package/loader/index.js +3 -4
  391. package/package.json +23 -180
  392. package/styles/core.css +156 -38
  393. package/components/floating-ui.dom.esm.js.map +0 -1
  394. package/components/helpers.js +0 -175
  395. package/components/helpers.js.map +0 -1
  396. package/components/icon.js +0 -185
  397. package/components/icon.js.map +0 -1
  398. package/components/label.js +0 -55
  399. package/components/label.js.map +0 -1
  400. package/dist/cjs/floating-ui.dom.esm-7f1cac3e.js.map +0 -1
  401. package/dist/cjs/helpers-452256e8.js +0 -185
  402. package/dist/cjs/helpers-452256e8.js.map +0 -1
  403. package/dist/cjs/index-d181f952.js +0 -2039
  404. package/dist/cjs/index-d181f952.js.map +0 -1
  405. package/dist/cjs/library-ad8d9466.js +0 -72
  406. package/dist/cjs/library-ad8d9466.js.map +0 -1
  407. package/dist/cjs/qds-button.cjs.entry.js.map +0 -1
  408. package/dist/cjs/qds-checkbox.cjs.entry.js +0 -116
  409. package/dist/cjs/qds-checkbox.cjs.entry.js.map +0 -1
  410. package/dist/cjs/qds-dialog.cjs.entry.js.map +0 -1
  411. package/dist/cjs/qds-divider.cjs.entry.js +0 -33
  412. package/dist/cjs/qds-divider.cjs.entry.js.map +0 -1
  413. package/dist/cjs/qds-dropdown.cjs.entry.js.map +0 -1
  414. package/dist/cjs/qds-form-message.cjs.entry.js.map +0 -1
  415. package/dist/cjs/qds-icon.cjs.entry.js.map +0 -1
  416. package/dist/cjs/qds-inline-link.cjs.entry.js.map +0 -1
  417. package/dist/cjs/qds-input.cjs.entry.js.map +0 -1
  418. package/dist/cjs/qds-label.cjs.entry.js.map +0 -1
  419. package/dist/cjs/qds-radio.cjs.entry.js +0 -74
  420. package/dist/cjs/qds-radio.cjs.entry.js.map +0 -1
  421. package/dist/cjs/qds-switch.cjs.entry.js.map +0 -1
  422. package/dist/cjs/qds-textarea.cjs.entry.js.map +0 -1
  423. package/dist/cjs/qds-title.cjs.entry.js.map +0 -1
  424. package/dist/cjs/qds-tooltip.cjs.entry.js.map +0 -1
  425. package/dist/esm/floating-ui.dom.esm-c2f3e549.js.map +0 -1
  426. package/dist/esm/helpers-76b84f45.js +0 -175
  427. package/dist/esm/helpers-76b84f45.js.map +0 -1
  428. package/dist/esm/index-d7183092.js +0 -2009
  429. package/dist/esm/index-d7183092.js.map +0 -1
  430. package/dist/esm/library-f36d7d09.js +0 -68
  431. package/dist/esm/library-f36d7d09.js.map +0 -1
  432. package/dist/esm/polyfills/core-js.js +0 -11
  433. package/dist/esm/polyfills/dom.js +0 -79
  434. package/dist/esm/polyfills/es5-html-element.js +0 -1
  435. package/dist/esm/polyfills/index.js +0 -34
  436. package/dist/esm/polyfills/system.js +0 -6
  437. package/dist/esm/qds-checkbox.entry.js +0 -112
  438. package/dist/esm/qds-checkbox.entry.js.map +0 -1
  439. package/dist/esm/qds-divider.entry.js +0 -29
  440. package/dist/esm/qds-divider.entry.js.map +0 -1
  441. package/dist/esm/qds-radio.entry.js +0 -70
  442. package/dist/esm/qds-radio.entry.js.map +0 -1
  443. package/dist/types/components/create-story.d.ts +0 -5
  444. package/loader/package.json +0 -11
@@ -1,244 +1,593 @@
1
1
  /*!
2
- * SPDX-FileCopyrightText: © 2023 Schneider Electric
2
+ * SPDX-FileCopyrightText: © 2026 Schneider Electric
3
3
  *
4
- * SPDX-License-Identifier: LGPL-2.1-only
4
+ * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
- import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
7
- import { p as pickFocusEventAttributes, a as invariant, e as pickInputEventAttributes, i as inheritAriaAttributes, b as inheritAttributes } from './helpers.js';
6
+ import { p as proxyCustomElement, H, c as createEvent, h } from './p-D2489VzR.js';
7
+ import { a as invariant, p as pickFocusEventAttributes, j as pickInputEventAttributes, g as inheritAriaAttributes } from './p-eUDNu0SE.js';
8
+ import { V as VALID_STATE, C as CUSTOM_ERROR_FLAGS, N as NO_ERROR_FLAGS } from './p-CZRW1LV_.js';
9
+ import { d as defineCustomElement$3 } from './p-fKK7EmM2.js';
10
+ import { d as defineCustomElement$2 } from './p-D2BuSQre.js';
8
11
 
9
- const inputCss = ".sc-qds-input-h{box-sizing:border-box}[hidden].sc-qds-input-h{display:none !important}.sc-qds-input-h *.sc-qds-input,.sc-qds-input-h *.sc-qds-input::before,.sc-qds-input-h *.sc-qds-input::after{box-sizing:inherit}.sc-qds-input-h{display:inline-block}.input.sc-qds-input{-webkit-appearance:textfield;appearance:textfield;padding:0;background-color:var(--qds-theme-control-input-background);border:var(--qds-control-border-width) solid var(--qds-theme-control-border);border-radius:var(--qds-control-border-radius);color:var(--qds-theme-control-text-standard);gap:var(--qds-control-input-gap-internal);padding-inline:var(--qds-control-input-padding-horizontal);width:100%}.input[aria-invalid='true'].sc-qds-input:not(:focus){border-color:var(--qds-theme-feedback-result-failure)}.input[type='color'].sc-qds-input{-webkit-appearance:none;appearance:none;min-width:50px;padding-block:var(--qds-control-input-padding-horizontal);cursor:pointer}.input[type='color'].sc-qds-input::-webkit-color-swatch-wrapper{padding:0}.input[type='color'].sc-qds-input::-webkit-color-swatch{border:var(--qds-control-border-width) solid\n var(--qds-theme-control-border);border-radius:var(--qds-control-border-radius)}.input[type='color'].sc-qds-input::-moz-color-swatch{border:var(--qds-control-border-width) solid\n var(--qds-theme-control-border);border-radius:var(--qds-control-border-radius)}.input[type='color'].sc-qds-input:hover{background-color:var(--qds-theme-interactive-background-hover)}.input[type='color'].sc-qds-input:active{background-color:var(--qds-theme-interactive-background-pressed)}.input.sc-qds-input:disabled{opacity:var(--qds-theme-disabled);pointer-events:none}.input.sc-qds-input:focus-visible{outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width);outline-offset:var(--qds-focus-border-offset)}.input.sc-qds-input:placeholder-shown{color:var(--qds-theme-control-text-placeholder)}[data-size='small'].sc-qds-input{font:var(--qds-control-small-text);height:var(--qds-control-small-height)}[data-size='standard'].sc-qds-input{font:var(--qds-control-standard-text);height:var(--qds-control-standard-height)}[data-size='large'].sc-qds-input{font:var(--qds-control-large-text);height:var(--qds-control-large-height)}";
12
+ const inputCss = ":host([hidden]){display:none!important}:host{display:inline-block}@-moz-document url-prefix(){[type=date]~.qds-icon-container,[type=datetime-local]~.qds-icon-container,[type=month]~.qds-icon-container,[type=time]~.qds-icon-container,[type=week]~.qds-icon-container{display:none}}input[type=password]::-ms-reveal{display:none}.qds-container,.qds-input{letter-spacing:inherit;max-width:inherit;width:inherit;word-spacing:inherit}.qds-container{align-content:flex-start;align-items:center;box-sizing:border-box;display:grid;grid-template-areas:\"b\"}.qds-icon-container,.qds-input{grid-area:b}.qds-focus-ring{border-radius:max(1px,var(\n --qds-form-input-border-radius-top-left,var(--qds-form-input-border-radius)\n )) max(1px,var(\n --qds-form-input-border-radius-top-right,var(--qds-form-input-border-radius)\n )) max(1px,var(\n --qds-form-input-border-radius-bottom-right,var(--qds-form-input-border-radius)\n )) max(1px,var(\n --qds-form-input-border-radius-bottom-left,var(--qds-form-input-border-radius)\n ));box-shadow:0 0 0 var(--qds-focus-heavy-border-width) var(--qds-theme-focus-border);grid-area:b;height:calc(100% + var(--qds-form-input-border-width-default) - var(\n --qds-form-input-border-width-block-end,\n var(--qds-form-input-border-width-default)\n ));isolation:isolate;outline:var(--qds-theme-focus-border-contrast) solid var(--qds-focus-light-border-width);outline-offset:0;pointer-events:none;visibility:hidden;width:calc(100% + var(--qds-form-input-border-width-default) - var(\n --qds-form-input-border-width-inline-end,\n var(--qds-form-input-border-width-default)\n ))}[data-size=large]{font:var(--qds-form-large-text);min-height:var(--qds-form-input-large-height);padding-inline:var(--qds-form-input-large-padding-start) var(--qds-form-input-large-padding-end)}.qds-password-padding[data-size=large],[data-size=large][type=date],[data-size=large][type=datetime-local],[data-size=large][type=month],[data-size=large][type=time],[data-size=large][type=week]{padding-inline:var(--qds-form-input-large-padding-end) calc(var(--qds-form-input-large-padding-end) + var(--qds-form-input-large-height))}[data-size=large]~.qds-icon-container{padding-inline-end:var(--qds-form-input-large-padding-end)}[data-size=large][type=number]{padding-inline:var(--qds-form-input-large-padding-start) var(--qds-form-input-large-padding-end)}[data-size=large][type=file]{padding-block:var(--qds-form-input-large-padding-start) var(--qds-form-input-large-padding-end)}[data-size=large][type=file]::file-selector-button{font:var(--qds-form-large-text);margin-inline-end:var(--qds-control-large-gap-siblings-related);min-height:var(--qds-form-input-large-height);padding-inline:var(--qds-control-button-large-padding-horizontal)}[data-size=large][type=search]{padding-inline:var(--qds-form-input-large-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-large-padding-end) + var(--qds-form-input-large-gap-internal))}[data-size=large][type=search]~.qds-icon-container{gap:var(--qds-form-input-large-gap-internal)}.qds-custom-icon-padding[data-size=large]{padding-inline:var(--qds-form-input-large-padding-start) calc(var(--qds-form-input-large-padding-end) + var(--qds-form-input-large-height))}.qds-dual-icon-padding[data-size=large]{padding-inline:var(--qds-form-input-large-padding-start) calc(var(--qds-form-input-large-padding-end) + var(--qds-form-input-large-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-large-gap-internal))}.qds-dual-icon-padding[data-size=large]~.qds-icon-container{gap:var(--qds-form-input-large-gap-internal)}.qds-padding[data-size=large]{padding-inline:var(--qds-form-input-large-padding-start) var(--qds-form-input-large-padding-end)}[data-size=large]{@-moz-document url-prefix(){&[type=date],&[type=datetime-local],&[type=month],&[type=time],&[type=week]{padding-inline:var(--qds-form-input-large-padding-start) var(--qds-form-input-large-padding-end)}}}[data-size=standard]{font:var(--qds-form-standard-text);min-height:var(--qds-form-input-standard-height);padding-inline:var(--qds-form-input-standard-padding-start) var(--qds-form-input-standard-padding-end)}.qds-password-padding[data-size=standard],[data-size=standard][type=date],[data-size=standard][type=datetime-local],[data-size=standard][type=month],[data-size=standard][type=time],[data-size=standard][type=week]{padding-inline:var(--qds-form-input-standard-padding-start) calc(var(--qds-form-input-standard-padding-end) + var(--qds-form-input-standard-height))}[data-size=standard]~.qds-icon-container{padding-inline-end:var(--qds-form-input-standard-padding-end)}[data-size=standard][type=number]{padding-inline:var(--qds-form-input-standard-padding-start) var(--qds-form-input-standard-padding-end)}[data-size=standard][type=file]{padding-block:var(--qds-form-input-standard-padding-start) var(--qds-form-input-standard-padding-end)}[data-size=standard][type=file]::file-selector-button{font:var(--qds-form-standard-text);margin-inline-end:var(--qds-control-standard-gap-siblings-related);min-height:var(--qds-form-input-standard-height);padding-inline:var(--qds-control-button-standard-padding-horizontal)}[data-size=standard][type=search]{padding-inline:var(--qds-form-input-standard-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-standard-padding-end) + var(--qds-form-input-standard-gap-internal))}[data-size=standard][type=search]~.qds-icon-container{gap:var(--qds-form-input-standard-gap-internal)}.qds-custom-icon-padding[data-size=standard]{padding-inline:var(--qds-form-input-standard-padding-start) calc(var(--qds-form-input-standard-padding-end) + var(--qds-form-input-standard-height))}.qds-dual-icon-padding[data-size=standard]{padding-inline:var(--qds-form-input-standard-padding-start) calc(var(--qds-form-input-standard-padding-end) + var(--qds-form-input-standard-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-standard-gap-internal))}.qds-dual-icon-padding[data-size=standard]~.qds-icon-container{gap:var(--qds-form-input-standard-gap-internal)}.qds-padding[data-size=standard]{padding-inline:var(--qds-form-input-standard-padding-start) var(--qds-form-input-standard-padding-end)}[data-size=standard]{@-moz-document url-prefix(){&[type=date],&[type=datetime-local],&[type=month],&[type=time],&[type=week]{padding-inline:var(--qds-form-input-standard-padding-start) var(--qds-form-input-standard-padding-end)}}}[data-size=small]{font:var(--qds-form-small-text);min-height:var(--qds-form-input-small-height);padding-inline:var(--qds-form-input-small-padding-start) var(--qds-form-input-small-padding-end)}.qds-password-padding[data-size=small],[data-size=small][type=date],[data-size=small][type=datetime-local],[data-size=small][type=month],[data-size=small][type=time],[data-size=small][type=week]{padding-inline:var(--qds-form-input-small-padding-end) calc(var(--qds-form-input-small-padding-end) + var(--qds-form-input-small-height))}[data-size=small]~.qds-icon-container{padding-inline-end:var(--qds-form-input-small-padding-end)}[data-size=small][type=number]{padding-inline:var(--qds-form-input-small-padding-start) var(--qds-form-input-small-padding-end)}[data-size=small][type=file]{padding-block:var(--qds-form-input-small-padding-start) var(--qds-form-input-small-padding-end)}[data-size=small][type=file]::file-selector-button{font:var(--qds-form-small-text);margin-inline-end:var(--qds-control-small-gap-siblings-related);min-height:var(--qds-form-input-small-height);padding-inline:var(--qds-control-button-small-padding-horizontal)}[data-size=small][type=search]{padding-inline:var(--qds-form-input-small-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-small-padding-end) + var(--qds-form-input-small-gap-internal))}[data-size=small][type=search]~.qds-icon-container{gap:var(--qds-form-input-small-gap-internal)}.qds-custom-icon-padding[data-size=small]{padding-inline:var(--qds-form-input-small-padding-start) calc(var(--qds-form-input-small-padding-end) + var(--qds-form-input-small-height))}.qds-dual-icon-padding[data-size=small]{padding-inline:var(--qds-form-input-small-padding-start) calc(var(--qds-form-input-small-padding-end) + var(--qds-form-input-small-height) + var(--qds-control-mini-button-standard-size) + var(--qds-form-input-small-gap-internal))}.qds-dual-icon-padding[data-size=small]~.qds-icon-container{gap:var(--qds-form-input-small-gap-internal)}.qds-padding[data-size=small]{padding-inline:var(--qds-form-input-small-padding-start) var(--qds-form-input-small-padding-end)}[data-size=small]{@-moz-document url-prefix(){&[type=date],&[type=datetime-local],&[type=month],&[type=time],&[type=week]{padding-inline:var(--qds-form-input-small-padding-start) var(--qds-form-input-small-padding-end)}}}.qds-input{-webkit-appearance:textfield;appearance:textfield;background-color:var(--qds-theme-form-input-background-default);border-color:var(--qds-theme-form-input-border-default);border-radius:var(\n --qds-form-input-border-radius-top-left,var(--qds-form-input-border-radius)\n ) var(\n --qds-form-input-border-radius-top-right,var(--qds-form-input-border-radius)\n ) var(\n --qds-form-input-border-radius-bottom-right,var(--qds-form-input-border-radius)\n ) var(\n --qds-form-input-border-radius-bottom-left,var(--qds-form-input-border-radius)\n );border-style:solid;border-width:var(--qds-form-input-border-width-default) var(\n --qds-form-input-border-width-inline-end,var(--qds-form-input-border-width-default)\n ) var(\n --qds-form-input-border-width-block-end,var(--qds-form-input-border-width-default)\n ) var(--qds-form-input-border-width-default);box-sizing:border-box;color:var(--qds-theme-form-input-text-active);grid-area:b;padding-block:0}.qds-input.qds-hide~.qds-icon-container{display:none}.qds-input:disabled,.qds-input:disabled~.qds-icon-container{opacity:var(--qds-theme-disabled);pointer-events:none}.qds-input:focus-visible{outline:none}.qds-input:focus-visible~.qds-focus-ring{visibility:visible}.qds-input:read-only{background-color:var(--qds-theme-form-input-background-read-only);border-color:var(--qds-theme-form-input-border-disabled)}.qds-input::placeholder{color:var(--qds-theme-form-input-text-placeholder)}.qds-input:hover{background-color:var(--qds-theme-form-input-background-hover);border-color:var(--qds-theme-form-input-border-hover)}.qds-input:active{background-color:var(--qds-theme-form-input-background-active);color:var(--qds-theme-form-input-text-active)}.qds-input::-webkit-search-cancel-button,.qds-input:is([type=date],[type=datetime-local],[type=month],[type=time],[type=week])::-webkit-calendar-picker-indicator{display:none}.qds-input[type=file]::file-selector-button{background-color:initial;border:var(--qds-form-input-border-width-default) solid var(--qds-theme-form-input-border-default);border-radius:var(--qds-control-border-radius);color:var(--qds-theme-form-input-text-active)}.qds-input[type=file]::file-selector-button:hover{background-color:var(--qds-theme-interactive-background-hover)}.qds-input[type=file]::file-selector-button:active{background-color:var(--qds-theme-interactive-background-pressed)}.qds-input[type=color]{-webkit-appearance:none;appearance:none;cursor:pointer;min-width:50px;padding-block:var(--qds-form-input-standard-padding-end);padding-inline:var(--qds-form-input-standard-padding-end)}.qds-input[type=color]::-webkit-color-swatch-wrapper{padding:0}.qds-input[type=color]::-webkit-color-swatch{border:var(--qds-form-input-border-width-default) solid var(--qds-theme-form-input-border-default);border-radius:var(--qds-control-border-radius)}.qds-input[type=color]::-moz-color-swatch{border:var(--qds-form-input-border-width-default) solid var(--qds-theme-form-input-border-default);border-radius:var(--qds-control-border-radius)}.qds-input[type=color]:hover{background-color:var(--qds-theme-interactive-background-hover)}.qds-input[type=color]:active{background-color:var(--qds-theme-interactive-background-pressed)}.qds-input.qds-search-padding[data-size=standard]{padding-inline:var(--qds-form-input-standard-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-form-input-standard-padding-end))}.qds-input[data-size=standard][type=file]{height:auto}.qds-input.qds-search-padding[data-size=large]{padding-inline:var(--qds-form-input-large-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-form-input-large-padding-end))}.qds-input[data-size=large][type=file]{height:auto}.qds-input.qds-search-padding[data-size=small]{padding-inline:var(--qds-form-input-small-padding-end) calc(var(--qds-form-input-small-height) + var(--qds-form-input-small-padding-end))}.qds-input[data-size=small][type=file]{height:auto}.qds-input{@-moz-document url-prefix(){&[type=number]{appearance:none}}}.qds-input[data-status]{border-width:var(--qds-form-input-border-width-status) var(\n --qds-form-input-border-width-inline-end,var(--qds-form-input-border-width-status)\n ) var(\n --qds-form-input-border-width-block-end,var(--qds-form-input-border-width-status)\n ) var(--qds-form-input-border-width-status)}.qds-input[data-status=success]{border-color:var(--qds-theme-form-input-border-success)}.qds-input[data-status=warning]{border-color:var(--qds-theme-form-input-border-warning)}.qds-input:not(:focus):user-invalid,.qds-input[data-status=error]{border-color:var(--qds-theme-form-input-border-error)}.qds-icon-container{align-items:center;display:flex;justify-content:center;justify-self:end}";
10
13
 
11
- let autoIncrementingId = 1;
12
- const Input = /*@__PURE__*/ proxyCustomElement(class Input extends HTMLElement {
13
- constructor() {
14
- super();
15
- this.__registerHost();
16
- this.blurEmitter = createEvent(this, "qdsBlur", 2);
17
- this.changeEmitter = createEvent(this, "qdsChange", 6);
18
- this.focusEmitter = createEvent(this, "qdsFocus", 2);
19
- this.inputEmitter = createEvent(this, "qdsInput", 6);
20
- this.inheritedAttributes = {};
21
- this.ref = (input) => {
22
- this.input = input;
23
- };
24
- this.onBlur = (event) => {
25
- this.blurEmitter.emit(pickFocusEventAttributes(event));
26
- };
27
- this.onChange = () => {
28
- invariant(this.input);
29
- this.value = this.input.value;
30
- this.changeEmitter.emit();
31
- };
32
- this.onClick = (event) => {
33
- if (this.computedDisabled) {
34
- event.preventDefault();
35
- event.stopPropagation();
36
- }
37
- };
38
- this.onFocus = (event) => {
39
- this.focusEmitter.emit(pickFocusEventAttributes(event));
40
- };
41
- this.onInput = (event) => {
42
- invariant(this.input);
43
- this.value = this.input.value;
44
- this.inputEmitter.emit(pickInputEventAttributes(event));
45
- };
46
- this.onInvalid = () => {
47
- this.invalid = true;
48
- };
49
- this.invalid = undefined;
50
- this.size = 'standard';
51
- this.autoCapitalize = undefined;
52
- this.autoComplete = undefined;
53
- this.autoFocus = undefined;
54
- this.disabled = undefined;
55
- this.enterkeyhint = undefined;
56
- this.form = undefined;
57
- this.inputmode = undefined;
58
- this.max = undefined;
59
- this.maxLength = undefined;
60
- this.min = undefined;
61
- this.minLength = undefined;
62
- this.multiple = undefined;
63
- this.name = `qds-input-${autoIncrementingId}`;
64
- this.pattern = undefined;
65
- this.placeholder = undefined;
66
- this.readOnly = undefined;
67
- this.required = undefined;
68
- this.spellCheck = undefined;
69
- this.step = undefined;
70
- this.type = undefined;
71
- this.value = undefined;
72
- }
73
- get computedDisabled() {
74
- return this.disabled ?? false;
75
- }
76
- /**
77
- * Returns true if the element's value passes validity checks; otherwise,
78
- * returns false, fires an invalid event at the element, and (if the event
79
- * isn't canceled) reports the problem to the user.
80
- */
81
- async reportValidity() {
82
- invariant(this.input);
83
- return this.input.reportValidity();
84
- }
85
- /**
86
- * Selects the entire content of the `<qds-input>` element if the element's
87
- * content is selectable.
88
- */
89
- async select() {
90
- invariant(this.input);
91
- this.input.select();
92
- }
93
- /**
94
- * Sets a custom validity message for the input. If this message is not the
95
- * empty string, then the element is considered invalid.
96
- */
97
- async setCustomValidity(message) {
98
- invariant(this.input);
99
- this.input.setCustomValidity(message);
100
- this.invalid = !this.input.checkValidity();
101
- }
102
- /**
103
- * Sets the contents of the specified range of characters in the input element to a given string.
104
- *
105
- * @param replacement The string to insert.
106
- * @param start The 0-based index of the first character to replace. Defaults to the current selectionStart value (the start of the user's current selection).
107
- * @param end The 0-based index of the character _after_ the last character to replace. Defaults to the current selectionEnd value (the end of the user's current selection).
108
- * @param selectionMode A string defining how the selection should be set after the text has been replaced. Possible values:
109
- *
110
- * - `"select"` selects the newly inserted text.
111
- * - `"start"` moves the selection to just before the inserted text.
112
- * - `"end"` moves the selection to just after the inserted text.
113
- * - `"preserve"` attempts to preserve the selection.
114
- */
115
- async setRangeText(replacement, start, end, selectionMode = 'preserve') {
116
- invariant(this.input);
117
- this.input.setRangeText(replacement, start, end, selectionMode);
118
- if (this.value !== this.input.value) {
119
- this.value = this.input.value;
120
- this.inputEmitter.emit();
121
- this.changeEmitter.emit();
122
- }
123
- }
124
- /**
125
- * Selects the specified range of characters within the input.
126
- *
127
- * @param start The offset into the input for the start of the selection.
128
- * @param end The offset into the input for the end of the selection.
129
- * @param direction The direction in which the selection is performed.
130
- */
131
- async setSelectionRange(start, end, direction) {
132
- invariant(this.input);
133
- this.input.setSelectionRange(start, end, direction);
134
- }
135
- /**
136
- * Decrements the `value` by (`step` * n), where n defaults to 1 if not
137
- * specified.
138
- *
139
- * @param n Amount to decrement the value by.
140
- */
141
- async stepDown(n) {
142
- invariant(this.input);
143
- this.input.stepDown(n);
144
- }
145
- /**
146
- * Increments the `value` by (`step` * n), where n defaults to 1 if not
147
- * specified.
148
- *
149
- * @param n Amount to increment the value by.
150
- */
151
- async stepUp(n) {
152
- invariant(this.input);
153
- this.input.stepUp(n);
154
- }
155
- disabledChanged() {
156
- invariant(this.input);
157
- // Disabled inputs are always valid, so we need to recheck validity when
158
- // the state changes.
159
- this.input.disabled = this.computedDisabled;
160
- this.invalid = !this.input.checkValidity();
161
- }
162
- stepChanged() {
163
- invariant(this.input);
164
- // If step changes, the value may become invalid so we need to recheck
165
- // after the update. We set the new step imperatively so we don't have to
166
- // wait for the next render to report the updated validity.
167
- this.input.step = String(this.step);
168
- this.invalid = !this.input.checkValidity();
169
- }
170
- valueChanged() {
171
- invariant(this.input);
172
- this.invalid = !this.input.checkValidity();
173
- }
174
- componentWillLoad() {
175
- autoIncrementingId += 1;
176
- this.inheritedAttributes = {
177
- ...inheritAriaAttributes(this.element),
178
- ...inheritAttributes(this.element, ['tabindex']),
179
- };
180
- }
181
- render() {
182
- return (h("input", { "aria-invalid": this.invalid ?? false ? 'true' : 'false', autoCapitalize: this.autoCapitalize, autoComplete: this.autoComplete,
183
- // eslint-disable-next-line jsx-a11y/no-autofocus
184
- autoFocus: this.autoFocus, class: "input", "data-size": this.size, disabled: this.disabled, enterKeyHint: this.enterkeyhint, form: this.form, inputMode: this.inputmode, max: this.max, maxLength: this.maxLength, min: this.min, minLength: this.minLength, multiple: this.multiple, name: this.name, onBlur: this.onBlur, onChange: this.onChange, onClick: this.onClick, onFocus: this.onFocus, onInput: this.onInput, onInvalid: this.onInvalid, pattern: this.pattern, placeholder: this.placeholder, readOnly: this.readOnly, ref: this.ref, required: this.required, spellcheck: this.spellCheck, step: this.step, type: this.type, value: this.value ?? undefined, ...this.inheritedAttributes }));
185
- }
186
- get element() { return this; }
187
- static get watchers() { return {
188
- "disabled": ["disabledChanged"],
189
- "step": ["stepChanged"],
190
- "value": ["valueChanged"]
191
- }; }
192
- static get style() { return inputCss; }
193
- }, [2, "qds-input", {
194
- "invalid": [1540],
195
- "size": [513],
196
- "autoCapitalize": [1, "autocapitalize"],
197
- "autoComplete": [1, "autocomplete"],
198
- "autoFocus": [4, "autofocus"],
199
- "disabled": [1540],
200
- "enterkeyhint": [1],
201
- "form": [1],
202
- "inputmode": [1],
203
- "max": [8],
204
- "maxLength": [2, "maxlength"],
205
- "min": [8],
206
- "minLength": [2, "minlength"],
207
- "multiple": [4],
208
- "name": [1],
209
- "pattern": [1],
210
- "placeholder": [1],
211
- "readOnly": [4, "readonly"],
212
- "required": [4],
213
- "spellCheck": [4, "spellcheck"],
214
- "step": [8],
215
- "type": [1],
216
- "value": [1032],
217
- "reportValidity": [64],
218
- "select": [64],
219
- "setCustomValidity": [64],
220
- "setRangeText": [64],
221
- "setSelectionRange": [64],
222
- "stepDown": [64],
223
- "stepUp": [64]
224
- }]);
14
+ // SPDX-FileCopyrightText: © 2024 Schneider Electric
15
+ //
16
+ // SPDX-License-Identifier: Apache-2.0
17
+ var __classPrivateFieldGet = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
18
+ if (kind === "a" && !f)
19
+ throw new TypeError("Private accessor was defined without a getter");
20
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
21
+ throw new TypeError("Cannot read private member from an object whose class did not declare it");
22
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
23
+ };
24
+ var __classPrivateFieldSet = (undefined && undefined.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
25
+ if (kind === "m")
26
+ throw new TypeError("Private method is not writable");
27
+ if (kind === "a" && !f)
28
+ throw new TypeError("Private accessor was defined without a setter");
29
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
30
+ throw new TypeError("Cannot write private member to an object whose class did not declare it");
31
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
32
+ };
33
+ var _Input_instances, _Input_inheritedAttributes, _Input_input, _Input_computedDisabled_get, _Input_computedIconName_get, _Input_computedSize_get, _Input_computedValue_get, _Input_computedStatus_get, _Input_hasInteractiveIcon_get, _Input_iconClickHandler_get, _Input_computedType_get, _Input_computedInteractiveIconAriaLabel_get, _Input_renderClearableButton, _Input_renderSearchClearButton, _Input_renderInteractiveIconButton, _Input_renderSearchButton, _Input_togglePasswordVisibility, _Input_ref, _Input_getFiles, _Input_onBlur, _Input_onCancel, _Input_onSearch, _Input_onChange, _Input_handleClear, _Input_onClearableClick, _Input_onSearchClear, _Input_onFocus, _Input_onInput, _Input_defineGetter, _Input_clearValue;
34
+ const stopImmediatePropagation = (event) => {
35
+ event.stopImmediatePropagation();
36
+ };
37
+ const supportsSearchEvent = () => {
38
+ const input = document.createElement('input');
39
+ input.type = 'search';
40
+ return input.onsearch !== undefined;
41
+ };
42
+ const Input = /*@__PURE__*/ proxyCustomElement(class Input extends H {
43
+ constructor(registerHost) {
44
+ super();
45
+ if (registerHost !== false) {
46
+ this.__registerHost();
47
+ }
48
+ this.__attachShadow();
49
+ this.blurEmitter = createEvent(this, "qdsBlur", 2);
50
+ this.cancelEmitter = createEvent(this, "qdsCancel", 6);
51
+ this.searchEmitter = createEvent(this, "qdsSearch", 6);
52
+ this.changeEmitter = createEvent(this, "qdsChange", 6);
53
+ this.focusEmitter = createEvent(this, "qdsFocus", 2);
54
+ this.inputEmitter = createEvent(this, "qdsInput", 6);
55
+ this.internals = this.attachInternals();
56
+ _Input_instances.add(this);
57
+ /**
58
+ * Shows a clear button that allows the user to clear the input's value.
59
+ *
60
+ * For `search` inputs, the clear button is always shown when the input
61
+ * has a value, regardless of this property.
62
+ *
63
+ */
64
+ this.clearable = false;
65
+ /**
66
+ * @deprecated The no-icon property is deprecated and will be removed by September 2026.
67
+ *
68
+ * Hide the input type's icon.
69
+ *
70
+ * > **_NOTE:_** Due to browser limitations, the icon may not be hidden in
71
+ * all browsers.
72
+ */
73
+ this.noIcon = false;
74
+ /**
75
+ * The input's size.
76
+ *
77
+ * > **_NOTE:_** The native [`size` HTML attribute][size] is not supported.
78
+ * CSS `width` should be used instead if this functionality is needed.
79
+ *
80
+ * [size]: https://developer.mozilla.org/docs/Web/HTML/Attributes/size
81
+ */
82
+ this.size = 'standard';
83
+ /**
84
+ * Returns a file list for a `file` type input.
85
+ *
86
+ * @readonly
87
+ * @webnative
88
+ */
89
+ // eslint-disable-next-line unicorn/no-null
90
+ this.files = null;
91
+ /**
92
+ * The [`<form>`][] element to associate the input with (its form owner).
93
+ *
94
+ * The value of this attribute must be the id of a `<form>` in the same
95
+ * document. If this attribute is not set, the `<qds-input>` is associated
96
+ * with its ancestor `<form>` element, if any.
97
+ *
98
+ * This attribute lets you associate `<qds-input>` elements to `<form>`s
99
+ * anywhere in the document, not just inside a `<form>`. It can also override
100
+ * an ancestor `<form>` element.
101
+ *
102
+ * [`<form>`]: https://developer.mozilla.org/docs/Web/HTML/Element/form
103
+ *
104
+ * @readonly
105
+ * @webnative
106
+ */
107
+ // eslint-disable-next-line unicorn/no-null
108
+ this.form = null;
109
+ /**
110
+ * Returns a list of the [`<label>`][] elements associated with the
111
+ * `qds-input` element.
112
+ *
113
+ * [`<label>`]: https://developer.mozilla.org/docs/Web/HTML/Element/label
114
+ *
115
+ * @readonly
116
+ * @webnative
117
+ */
118
+ this.labels = {};
119
+ /**
120
+ * Get or set the selection direction of a text selection.
121
+ *
122
+ * > **_NOTE:_** This property has no effect when used as an attribute.
123
+ *
124
+ * @webnative
125
+ */
126
+ this.selectionDirection = null;
127
+ /**
128
+ * Get or set the ending position or offset of a text selection.
129
+ *
130
+ * > **_NOTE:_** This property has no effect when used as an attribute.
131
+ *
132
+ * @webnative
133
+ */
134
+ this.selectionEnd = null;
135
+ /**
136
+ * Get or set the starting position or offset of a text selection.
137
+ *
138
+ * > **_NOTE:_** This property has no effect when used as an attribute.
139
+ *
140
+ * @webnative
141
+ */
142
+ this.selectionStart = null;
143
+ /**
144
+ * The error message that would be shown to the user if the `<qds-input>`
145
+ * was to be checked for validity.
146
+ *
147
+ * @readonly
148
+ * @webnative
149
+ */
150
+ this.validationMessage = '';
151
+ /**
152
+ * The [`ValidityState`][] object for this `<qds-input>`.
153
+ *
154
+ * [`ValidityState`]: https://developer.mozilla.org/docs/Web/API/ValidityState
155
+ *
156
+ * @readonly
157
+ * @webnative
158
+ */
159
+ this.validity = VALID_STATE;
160
+ /**
161
+ * True if `<qds-input>` will be validated when the form is submitted; false
162
+ * otherwise.
163
+ *
164
+ * @readonly
165
+ * @webnative
166
+ */
167
+ this.willValidate = false;
168
+ this.isPasswordVisible = false;
169
+ _Input_inheritedAttributes.set(this, {});
170
+ _Input_input.set(this, void 0);
171
+ this.checkValidity = () => this.internals.checkValidity();
172
+ this.reportValidity = () => this.internals.reportValidity();
173
+ this.setCustomValidity = (error) => {
174
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
175
+ __classPrivateFieldGet(this, _Input_input, "f").setCustomValidity(error);
176
+ if (error)
177
+ this.internals.setValidity(CUSTOM_ERROR_FLAGS, error, __classPrivateFieldGet(this, _Input_input, "f"));
178
+ else
179
+ this.internals.setValidity(NO_ERROR_FLAGS);
180
+ };
181
+ this.select = () => {
182
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
183
+ __classPrivateFieldGet(this, _Input_input, "f").select();
184
+ };
185
+ this.getSelectionDirection = () => {
186
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
187
+ return __classPrivateFieldGet(this, _Input_input, "f").selectionDirection;
188
+ };
189
+ this.getSelectionStart = () => {
190
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
191
+ return __classPrivateFieldGet(this, _Input_input, "f").selectionStart;
192
+ };
193
+ this.getSelectionEnd = () => {
194
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
195
+ return __classPrivateFieldGet(this, _Input_input, "f").selectionEnd;
196
+ };
197
+ this.setRangeText = (replacement, start, end, selectionMode) => {
198
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
199
+ __classPrivateFieldGet(this, _Input_input, "f").setRangeText(replacement, start, end, selectionMode);
200
+ if (this.value !== __classPrivateFieldGet(this, _Input_input, "f").value) {
201
+ this.value = __classPrivateFieldGet(this, _Input_input, "f").value;
202
+ this.inputEmitter.emit();
203
+ this.changeEmitter.emit();
204
+ }
205
+ };
206
+ this.setSelectionRange = (start, end, direction) => {
207
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
208
+ __classPrivateFieldGet(this, _Input_input, "f").setSelectionRange(start, end, direction);
209
+ };
210
+ this.stepDown = (n) => {
211
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
212
+ __classPrivateFieldGet(this, _Input_input, "f").stepDown(n);
213
+ };
214
+ this.stepUp = (n) => {
215
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
216
+ __classPrivateFieldGet(this, _Input_input, "f").stepUp(n);
217
+ };
218
+ this.showPicker = () => {
219
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
220
+ __classPrivateFieldGet(this, _Input_input, "f").showPicker();
221
+ };
222
+ _Input_renderClearableButton.set(this, () => (h("qds-mini-button", { name: "clear", library: "core", text: "clear input", onClick: __classPrivateFieldGet(this, _Input_onClearableClick, "f"), onQdsFocus: stopImmediatePropagation })));
223
+ _Input_renderSearchClearButton.set(this, () => (h("qds-mini-button", { class: "qds-hide", name: "clear", library: "core", text: "clear input", onClick: __classPrivateFieldGet(this, _Input_onSearchClear, "f"), onQdsFocus: stopImmediatePropagation })));
224
+ _Input_renderInteractiveIconButton.set(this, () => (h("qds-mini-button", { name: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedIconName_get) ?? '', library: "core", text: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedInteractiveIconAriaLabel_get), onClick: __classPrivateFieldGet(this, _Input_instances, "a", _Input_iconClickHandler_get), onQdsFocus: stopImmediatePropagation })));
225
+ _Input_renderSearchButton.set(this, () => (h("qds-mini-button", { name: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedIconName_get) ?? '', library: "core", text: "search", onClick: __classPrivateFieldGet(this, _Input_onSearch, "f"), onQdsFocus: stopImmediatePropagation })));
226
+ _Input_togglePasswordVisibility.set(this, () => {
227
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
228
+ this.isPasswordVisible = !this.isPasswordVisible;
229
+ __classPrivateFieldGet(this, _Input_input, "f").type = __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedType_get);
230
+ });
231
+ _Input_ref.set(this, (input) => {
232
+ __classPrivateFieldSet(this, _Input_input, input, "f");
233
+ });
234
+ _Input_getFiles.set(this, () => {
235
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
236
+ return __classPrivateFieldGet(this, _Input_input, "f").files;
237
+ });
238
+ _Input_onBlur.set(this, (event) => {
239
+ this.blurEmitter.emit(pickFocusEventAttributes(event));
240
+ });
241
+ _Input_onCancel.set(this, () => {
242
+ this.cancelEmitter.emit();
243
+ });
244
+ _Input_onSearch.set(this, () => {
245
+ this.searchEmitter.emit();
246
+ });
247
+ _Input_onChange.set(this, () => {
248
+ this.changeEmitter.emit();
249
+ });
250
+ _Input_handleClear.set(this, () => {
251
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_clearValue).call(this);
252
+ __classPrivateFieldGet(this, _Input_onInput, "f").call(this, new InputEvent('input', { inputType: 'deleteContent' }));
253
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
254
+ if (document.activeElement !== __classPrivateFieldGet(this, _Input_input, "f"))
255
+ __classPrivateFieldGet(this, _Input_input, "f").focus();
256
+ });
257
+ _Input_onClearableClick.set(this, () => {
258
+ __classPrivateFieldGet(this, _Input_handleClear, "f").call(this);
259
+ });
260
+ _Input_onSearchClear.set(this, () => {
261
+ __classPrivateFieldGet(this, _Input_handleClear, "f").call(this);
262
+ this.searchEmitter.emit();
263
+ });
264
+ _Input_onFocus.set(this, (event) => {
265
+ this.focusEmitter.emit(pickFocusEventAttributes(event));
266
+ });
267
+ _Input_onInput.set(this, (event) => {
268
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
269
+ this.value = __classPrivateFieldGet(this, _Input_input, "f").value;
270
+ this.inputEmitter.emit(pickInputEventAttributes(event));
271
+ });
272
+ }
273
+ onClick(event) {
274
+ if (__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get))
275
+ event.stopImmediatePropagation();
276
+ }
277
+ onKeydown(event) {
278
+ if (__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get)) {
279
+ event.stopImmediatePropagation();
280
+ return;
281
+ }
282
+ if (event.key === 'Enter' && this.internals.form) {
283
+ this.internals.form.requestSubmit();
284
+ event.preventDefault();
285
+ }
286
+ if (event.key === 'Enter' && !supportsSearchEvent()) {
287
+ this.searchEmitter.emit();
288
+ }
289
+ }
290
+ ariaLabelChanged(newValue) {
291
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
292
+ __classPrivateFieldGet(this, _Input_input, "f").ariaLabel =
293
+ newValue ??
294
+ [...this.internals.labels]
295
+ .map((node) => {
296
+ // eslint-disable-next-line unicorn/prefer-dom-node-text-content
297
+ const text = node.innerText.trim();
298
+ return text === ''
299
+ ? (this.host.parentElement?.querySelector('qds-label')?.text ?? '')
300
+ : text;
301
+ })
302
+ .join(' ');
303
+ }
304
+ statusChanged() {
305
+ this.internals.ariaInvalid = (__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedStatus_get) === 'error').toString();
306
+ }
307
+ disabledChanged() {
308
+ if (__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get))
309
+ // eslint-disable-next-line unicorn/no-null
310
+ this.internals.setFormValue(null);
311
+ else
312
+ this.internals.setFormValue(__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedValue_get));
313
+ }
314
+ selectionDirectionChanged() {
315
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
316
+ __classPrivateFieldGet(this, _Input_input, "f").selectionDirection = this.selectionDirection;
317
+ }
318
+ selectionEndChanged() {
319
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
320
+ __classPrivateFieldGet(this, _Input_input, "f").selectionEnd = this.selectionEnd;
321
+ }
322
+ selectionStartChanged() {
323
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
324
+ __classPrivateFieldGet(this, _Input_input, "f").selectionStart = this.selectionStart;
325
+ }
326
+ tabindexChanged(newValue) {
327
+ const parsedValue = Number.parseInt(newValue, 10);
328
+ this.tabIndex =
329
+ parsedValue === 0 || Number.isNaN(parsedValue) ? undefined : parsedValue;
330
+ }
331
+ validationChanged() {
332
+ if (!__classPrivateFieldGet(this, _Input_input, "f"))
333
+ return;
334
+ if (__classPrivateFieldGet(this, _Input_input, "f").max !== this.max && this.max !== undefined)
335
+ __classPrivateFieldGet(this, _Input_input, "f").max = this.max.toString();
336
+ if (this.maxLength !== undefined)
337
+ __classPrivateFieldGet(this, _Input_input, "f").maxLength = this.maxLength;
338
+ if (__classPrivateFieldGet(this, _Input_input, "f").min !== this.min && this.min !== undefined)
339
+ __classPrivateFieldGet(this, _Input_input, "f").min = this.min.toString();
340
+ if (this.minLength !== undefined)
341
+ __classPrivateFieldGet(this, _Input_input, "f").minLength = this.minLength;
342
+ if (this.pattern !== undefined)
343
+ __classPrivateFieldGet(this, _Input_input, "f").pattern = this.pattern;
344
+ __classPrivateFieldGet(this, _Input_input, "f").required = this.required ?? false;
345
+ if (__classPrivateFieldGet(this, _Input_input, "f").step !== this.step && this.step !== undefined)
346
+ __classPrivateFieldGet(this, _Input_input, "f").step = this.step.toString();
347
+ __classPrivateFieldGet(this, _Input_input, "f").type = __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedType_get);
348
+ const { valid } = __classPrivateFieldGet(this, _Input_input, "f").validity;
349
+ if (valid)
350
+ this.internals.setValidity(NO_ERROR_FLAGS, undefined, __classPrivateFieldGet(this, _Input_input, "f"));
351
+ else
352
+ this.internals.setValidity(__classPrivateFieldGet(this, _Input_input, "f").validity, __classPrivateFieldGet(this, _Input_input, "f").validationMessage, __classPrivateFieldGet(this, _Input_input, "f"));
353
+ }
354
+ valueChanged() {
355
+ if (!__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get))
356
+ this.internals.setFormValue(__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedValue_get));
357
+ if ((__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedValue_get) === null || __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedValue_get) === '') &&
358
+ this.type === 'file') {
359
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_clearValue).call(this);
360
+ }
361
+ }
362
+ componentWillLoad() {
363
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'form', () => this.internals.form);
364
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'willValidate', () => this.internals.willValidate);
365
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'validity', () => this.internals.validity);
366
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'validationMessage', () => this.internals.validationMessage);
367
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'files', __classPrivateFieldGet(this, _Input_getFiles, "f"));
368
+ __classPrivateFieldGet(this, _Input_instances, "m", _Input_defineGetter).call(this, 'labels', () => this.internals.labels);
369
+ __classPrivateFieldSet(this, _Input_inheritedAttributes, inheritAriaAttributes(this.host), "f");
370
+ this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0');
371
+ this.statusChanged();
372
+ }
373
+ componentDidLoad() {
374
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
375
+ this.ariaLabelChanged(this.host.ariaLabel);
376
+ this.validationChanged();
377
+ this.valueChanged();
378
+ // FIXME: This event is supported by the native `<input>` element but not
379
+ // recognized by Stencil's type definitions, so it needs to be manually
380
+ // bound here.
381
+ __classPrivateFieldGet(this, _Input_input, "f").addEventListener('cancel', __classPrivateFieldGet(this, _Input_onCancel, "f"));
382
+ __classPrivateFieldGet(this, _Input_input, "f").addEventListener('search', __classPrivateFieldGet(this, _Input_onSearch, "f"));
383
+ }
384
+ disconnectedCallback() {
385
+ if (__classPrivateFieldGet(this, _Input_input, "f")) {
386
+ __classPrivateFieldGet(this, _Input_input, "f").removeEventListener('cancel', __classPrivateFieldGet(this, _Input_onCancel, "f"));
387
+ __classPrivateFieldGet(this, _Input_input, "f").removeEventListener('search', __classPrivateFieldGet(this, _Input_onSearch, "f"));
388
+ }
389
+ }
390
+ render() {
391
+ const hasValue = this.value !== null && this.value !== undefined && this.value !== '';
392
+ const isSearchType = this.type === 'search';
393
+ const isIconUnsupportedType = this.type === 'file' || this.type === 'color';
394
+ const shouldShowClearButton = hasValue && isSearchType;
395
+ const shouldShowClearableButton = hasValue &&
396
+ !isSearchType &&
397
+ !isIconUnsupportedType &&
398
+ this.clearable === true;
399
+ /* DEPRECATED: noIcon will be removed by September 2026 */
400
+ const shouldShowSearchButton = isSearchType && this.noIcon === false;
401
+ const shouldHideIcon = !isSearchType && this.noIcon === true;
402
+ const shouldRemoveSearchPadding = isSearchType && this.noIcon === true;
403
+ return (h("div", { key: '5fafd9f757ef2f22e8674646a8d39ea35ef5512d', class: "qds-container" }, h("input", { key: '28973fa020fad68133f42362becd41823fc97776', accept: this.accept, autoCapitalize: this.host.autocapitalize, autoComplete: this.autoComplete,
404
+ // eslint-disable-next-line jsx-a11y/no-autofocus
405
+ autoFocus: this.host.autofocus, capture: this.capture, class: {
406
+ 'qds-search-padding': shouldRemoveSearchPadding,
407
+ 'qds-input': true,
408
+ 'qds-hide': shouldHideIcon,
409
+ 'qds-padding': shouldHideIcon,
410
+ 'qds-password-padding': this.type === 'password' ||
411
+ (this.isPasswordVisible && this.type === 'text'),
412
+ 'qds-custom-icon-padding': shouldShowClearableButton && !__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedIconName_get),
413
+ 'qds-dual-icon-padding': shouldShowClearableButton && __classPrivateFieldGet(this, _Input_instances, "a", _Input_hasInteractiveIcon_get),
414
+ }, "data-status": __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedStatus_get), "data-size": __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedSize_get), disabled: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get), enterKeyHint: this.enterkeyhint, inputMode: this.inputmode, max: this.max, maxLength: this.maxLength, min: this.min, minLength: this.minLength, multiple: this.multiple, onBlur: __classPrivateFieldGet(this, _Input_onBlur, "f"), onChange: __classPrivateFieldGet(this, _Input_onChange, "f"), onFocus: __classPrivateFieldGet(this, _Input_onFocus, "f"), onInput: __classPrivateFieldGet(this, _Input_onInput, "f"), placeholder: this.placeholder, readOnly: this.readonly, ref: __classPrivateFieldGet(this, _Input_ref, "f"), spellcheck: this.host.spellcheck, step: this.step, tabIndex: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedDisabled_get) ? undefined : this.tabIndex, type: __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedType_get), value: this.value ?? '', ...__classPrivateFieldGet(this, _Input_inheritedAttributes, "f") }), h("div", { key: 'f566daf7b17d5c4fc9bd846744a14c71ac18b65a', class: "qds-focus-ring" }), shouldShowClearableButton && !__classPrivateFieldGet(this, _Input_instances, "a", _Input_computedIconName_get) && (h("div", { key: '397dc20c1680762a218100fd714249b75f8473ad', class: "qds-icon-container" }, __classPrivateFieldGet(this, _Input_renderClearableButton, "f").call(this))), __classPrivateFieldGet(this, _Input_instances, "a", _Input_computedIconName_get) && (h("div", { key: '5c500890ef26da34262829df4065f64e63b5089a', class: "qds-icon-container" }, shouldShowClearButton && __classPrivateFieldGet(this, _Input_renderSearchClearButton, "f").call(this), shouldShowClearableButton &&
415
+ __classPrivateFieldGet(this, _Input_instances, "a", _Input_hasInteractiveIcon_get) &&
416
+ __classPrivateFieldGet(this, _Input_renderClearableButton, "f").call(this), __classPrivateFieldGet(this, _Input_instances, "a", _Input_hasInteractiveIcon_get) && __classPrivateFieldGet(this, _Input_renderInteractiveIconButton, "f").call(this), shouldShowSearchButton && __classPrivateFieldGet(this, _Input_renderSearchButton, "f").call(this)))));
417
+ }
418
+ static get delegatesFocus() { return true; }
419
+ static get formAssociated() { return true; }
420
+ get host() { return this; }
421
+ static get watchers() { return {
422
+ "aria-label": ["ariaLabelChanged"],
423
+ "status": ["statusChanged"],
424
+ "disabled": ["disabledChanged"],
425
+ "selectionDirection": ["selectionDirectionChanged"],
426
+ "selectionEnd": ["selectionEndChanged"],
427
+ "selectionStart": ["selectionStartChanged"],
428
+ "tabindex": ["tabindexChanged"],
429
+ "max": ["validationChanged"],
430
+ "maxLength": ["validationChanged"],
431
+ "min": ["validationChanged"],
432
+ "minLength": ["validationChanged"],
433
+ "pattern": ["validationChanged"],
434
+ "required": ["validationChanged"],
435
+ "step": ["validationChanged"],
436
+ "type": ["validationChanged"],
437
+ "value": ["validationChanged", "valueChanged"]
438
+ }; }
439
+ static get style() { return inputCss; }
440
+ }, [337, "qds-input", {
441
+ "status": [1],
442
+ "readonly": [4],
443
+ "clearable": [4],
444
+ "noIcon": [4, "no-icon"],
445
+ "size": [1],
446
+ "accept": [1],
447
+ "autoComplete": [1, "autocomplete"],
448
+ "capture": [1],
449
+ "disabled": [4],
450
+ "enterkeyhint": [1],
451
+ "files": [16],
452
+ "form": [1],
453
+ "inputmode": [1],
454
+ "labels": [16],
455
+ "max": [8],
456
+ "maxLength": [2, "maxlength"],
457
+ "min": [8],
458
+ "minLength": [2, "minlength"],
459
+ "multiple": [4],
460
+ "name": [1],
461
+ "pattern": [1],
462
+ "placeholder": [1],
463
+ "required": [4],
464
+ "selectionDirection": [1025, "selection-direction"],
465
+ "selectionEnd": [1026, "selection-end"],
466
+ "selectionStart": [1026, "selection-start"],
467
+ "step": [8],
468
+ "type": [1],
469
+ "validationMessage": [1, "validation-message"],
470
+ "validity": [16],
471
+ "value": [1032],
472
+ "willValidate": [4, "will-validate"],
473
+ "tabIndex": [32],
474
+ "isPasswordVisible": [32]
475
+ }, [[0, "click", "onClick"], [0, "keydown", "onKeydown"]], {
476
+ "aria-label": ["ariaLabelChanged"],
477
+ "status": ["statusChanged"],
478
+ "disabled": ["disabledChanged"],
479
+ "selectionDirection": ["selectionDirectionChanged"],
480
+ "selectionEnd": ["selectionEndChanged"],
481
+ "selectionStart": ["selectionStartChanged"],
482
+ "tabindex": ["tabindexChanged"],
483
+ "max": ["validationChanged"],
484
+ "maxLength": ["validationChanged"],
485
+ "min": ["validationChanged"],
486
+ "minLength": ["validationChanged"],
487
+ "pattern": ["validationChanged"],
488
+ "required": ["validationChanged"],
489
+ "step": ["validationChanged"],
490
+ "type": ["validationChanged"],
491
+ "value": ["validationChanged", "valueChanged"]
492
+ }]);
493
+ _Input_inheritedAttributes = new WeakMap(), _Input_input = new WeakMap(), _Input_renderClearableButton = new WeakMap(), _Input_renderSearchClearButton = new WeakMap(), _Input_renderInteractiveIconButton = new WeakMap(), _Input_renderSearchButton = new WeakMap(), _Input_togglePasswordVisibility = new WeakMap(), _Input_ref = new WeakMap(), _Input_getFiles = new WeakMap(), _Input_onBlur = new WeakMap(), _Input_onCancel = new WeakMap(), _Input_onSearch = new WeakMap(), _Input_onChange = new WeakMap(), _Input_handleClear = new WeakMap(), _Input_onClearableClick = new WeakMap(), _Input_onSearchClear = new WeakMap(), _Input_onFocus = new WeakMap(), _Input_onInput = new WeakMap(), _Input_instances = new WeakSet(), _Input_computedDisabled_get = function _Input_computedDisabled_get() {
494
+ return this.host.matches(':disabled') || (this.disabled ?? false);
495
+ }, _Input_computedIconName_get = function _Input_computedIconName_get() {
496
+ if (this.type === 'password')
497
+ return this.isPasswordVisible
498
+ ? 'input-password-hide'
499
+ : 'input-password-show';
500
+ switch (this.type) {
501
+ case 'date':
502
+ case 'datetime-local':
503
+ case 'month':
504
+ case 'search':
505
+ case 'time':
506
+ case 'week': {
507
+ return `input-${this.type}`;
508
+ }
509
+ default: {
510
+ return undefined;
511
+ }
512
+ }
513
+ }, _Input_computedSize_get = function _Input_computedSize_get() {
514
+ switch (this.size) {
515
+ case 'standard':
516
+ case 'small':
517
+ case 'large': {
518
+ return this.size;
519
+ }
520
+ default: {
521
+ return 'standard';
522
+ }
523
+ }
524
+ }, _Input_computedValue_get = function _Input_computedValue_get() {
525
+ if (typeof this.value === 'number')
526
+ return this.value.toString();
527
+ // eslint-disable-next-line unicorn/no-null
528
+ return this.value === undefined ? null : this.value;
529
+ }, _Input_computedStatus_get = function _Input_computedStatus_get() {
530
+ switch (this.status) {
531
+ case 'error':
532
+ case 'success':
533
+ case 'warning': {
534
+ return this.status;
535
+ }
536
+ default: {
537
+ return undefined;
538
+ }
539
+ }
540
+ }, _Input_hasInteractiveIcon_get = function _Input_hasInteractiveIcon_get() {
541
+ return (typeof this.type === 'string' &&
542
+ ['month', 'time', 'date', 'datetime-local', 'week', 'password'].includes(this.type));
543
+ }, _Input_iconClickHandler_get = function _Input_iconClickHandler_get() {
544
+ return this.type === 'password'
545
+ ? __classPrivateFieldGet(this, _Input_togglePasswordVisibility, "f")
546
+ : this.showPicker;
547
+ }, _Input_computedType_get = function _Input_computedType_get() {
548
+ return this.type === 'password' && this.isPasswordVisible
549
+ ? 'text'
550
+ : (this.type ?? 'text');
551
+ }, _Input_computedInteractiveIconAriaLabel_get = function _Input_computedInteractiveIconAriaLabel_get() {
552
+ return this.type === 'password'
553
+ ? this.isPasswordVisible
554
+ ? 'Hide password'
555
+ : 'Show password'
556
+ : (this.type ?? '');
557
+ }, _Input_defineGetter = function _Input_defineGetter(p, get) {
558
+ Object.defineProperty(this.host, p, { enumerable: true, get });
559
+ }, _Input_clearValue = function _Input_clearValue() {
560
+ invariant(__classPrivateFieldGet(this, _Input_input, "f"));
561
+ __classPrivateFieldGet(this, _Input_input, "f").value = '';
562
+ };
225
563
  function defineCustomElement$1() {
226
- if (typeof customElements === "undefined") {
227
- return;
228
- }
229
- const components = ["qds-input"];
230
- components.forEach(tagName => { switch (tagName) {
231
- case "qds-input":
232
- if (!customElements.get(tagName)) {
233
- customElements.define(tagName, Input);
234
- }
235
- break;
236
- } });
564
+ if (typeof customElements === "undefined") {
565
+ return;
566
+ }
567
+ const components = ["qds-input", "qds-icon", "qds-mini-button"];
568
+ components.forEach(tagName => { switch (tagName) {
569
+ case "qds-input":
570
+ if (!customElements.get(tagName)) {
571
+ customElements.define(tagName, Input);
572
+ }
573
+ break;
574
+ case "qds-icon":
575
+ if (!customElements.get(tagName)) {
576
+ defineCustomElement$3();
577
+ }
578
+ break;
579
+ case "qds-mini-button":
580
+ if (!customElements.get(tagName)) {
581
+ defineCustomElement$2();
582
+ }
583
+ break;
584
+ } });
237
585
  }
238
586
 
239
587
  const QdsInput = Input;
240
588
  const defineCustomElement = defineCustomElement$1;
241
589
 
242
590
  export { QdsInput, defineCustomElement };
591
+ //# sourceMappingURL=qds-input.js.map
243
592
 
244
593
  //# sourceMappingURL=qds-input.js.map