@infineon/infineon-design-system-stencil 37.3.0--canary.1950.5d11e48d4f0a54b6edf1ffbcc0d55a943f9c1f3c.0 → 37.3.0--canary.1950.e6e48a36e10af3e7865c21dc9be85dbd249383b3.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 (545) hide show
  1. package/dist/cjs/{framework-detection-94ac6f10.js → framework-detection-397e1236.js} +7 -3
  2. package/dist/cjs/framework-detection-397e1236.js.map +1 -0
  3. package/dist/cjs/ifx-accordion_2.cjs.entry.js +3 -3
  4. package/dist/cjs/ifx-accordion_2.cjs.entry.js.map +1 -1
  5. package/dist/cjs/ifx-alert_2.cjs.entry.js +2 -2
  6. package/dist/cjs/ifx-alert_2.cjs.entry.js.map +1 -1
  7. package/dist/cjs/ifx-badge.cjs.entry.js +3 -3
  8. package/dist/cjs/ifx-badge.cjs.entry.js.map +1 -1
  9. package/dist/cjs/ifx-basic-table.cjs.entry.js +3 -3
  10. package/dist/cjs/ifx-basic-table.cjs.entry.js.map +1 -1
  11. package/dist/cjs/ifx-breadcrumb.cjs.entry.js +3 -3
  12. package/dist/cjs/ifx-breadcrumb.cjs.entry.js.map +1 -1
  13. package/dist/cjs/ifx-button.cjs.entry.js +3 -3
  14. package/dist/cjs/ifx-button.cjs.entry.js.map +1 -1
  15. package/dist/cjs/ifx-card.cjs.entry.js +5 -5
  16. package/dist/cjs/ifx-card.cjs.entry.js.map +1 -1
  17. package/dist/cjs/ifx-checkbox-group.cjs.entry.js +3 -3
  18. package/dist/cjs/ifx-checkbox-group.cjs.entry.js.map +1 -1
  19. package/dist/cjs/ifx-checkbox.cjs.entry.js +5 -5
  20. package/dist/cjs/ifx-checkbox.cjs.entry.js.map +1 -1
  21. package/dist/cjs/ifx-chip_3.cjs.entry.js +12 -12
  22. package/dist/cjs/ifx-chip_3.cjs.entry.js.map +1 -1
  23. package/dist/cjs/ifx-content-switcher.cjs.entry.js +3 -3
  24. package/dist/cjs/ifx-content-switcher.cjs.entry.js.map +1 -1
  25. package/dist/cjs/ifx-date-picker.cjs.entry.js +4 -4
  26. package/dist/cjs/ifx-date-picker.cjs.entry.js.map +1 -1
  27. package/dist/cjs/ifx-dropdown.cjs.entry.js +3 -3
  28. package/dist/cjs/ifx-dropdown.cjs.entry.js.map +1 -1
  29. package/dist/cjs/ifx-file-upload.cjs.entry.js +4 -4
  30. package/dist/cjs/ifx-file-upload.cjs.entry.js.map +1 -1
  31. package/dist/cjs/ifx-footer.cjs.entry.js +6 -6
  32. package/dist/cjs/ifx-footer.cjs.entry.js.map +1 -1
  33. package/dist/cjs/ifx-icon-button.cjs.entry.js +3 -3
  34. package/dist/cjs/ifx-icon-button.cjs.entry.js.map +1 -1
  35. package/dist/cjs/ifx-icon.cjs.entry.js +3 -3
  36. package/dist/cjs/ifx-icon.cjs.entry.js.map +1 -1
  37. package/dist/cjs/ifx-indicator.cjs.entry.js +4 -4
  38. package/dist/cjs/ifx-indicator.cjs.entry.js.map +1 -1
  39. package/dist/cjs/ifx-link.cjs.entry.js +3 -3
  40. package/dist/cjs/ifx-link.cjs.entry.js.map +1 -1
  41. package/dist/cjs/ifx-modal.cjs.entry.js +4 -4
  42. package/dist/cjs/ifx-modal.cjs.entry.js.map +1 -1
  43. package/dist/cjs/ifx-multiselect_2.cjs.entry.js +2 -2
  44. package/dist/cjs/ifx-multiselect_2.cjs.entry.js.map +1 -1
  45. package/dist/cjs/ifx-navbar.cjs.entry.js +5 -5
  46. package/dist/cjs/ifx-navbar.cjs.entry.js.map +1 -1
  47. package/dist/cjs/ifx-notification.cjs.entry.js +4 -4
  48. package/dist/cjs/ifx-notification.cjs.entry.js.map +1 -1
  49. package/dist/cjs/ifx-progress-bar.cjs.entry.js +3 -3
  50. package/dist/cjs/ifx-progress-bar.cjs.entry.js.map +1 -1
  51. package/dist/cjs/ifx-radio-button-group.cjs.entry.js +3 -3
  52. package/dist/cjs/ifx-radio-button-group.cjs.entry.js.map +1 -1
  53. package/dist/cjs/ifx-radio-button.cjs.entry.js +4 -4
  54. package/dist/cjs/ifx-radio-button.cjs.entry.js.map +1 -1
  55. package/dist/cjs/ifx-search-bar.cjs.entry.js +3 -3
  56. package/dist/cjs/ifx-search-bar.cjs.entry.js.map +1 -1
  57. package/dist/cjs/ifx-search-field.cjs.entry.js +3 -3
  58. package/dist/cjs/ifx-search-field.cjs.entry.js.map +1 -1
  59. package/dist/cjs/ifx-segmented-control.cjs.entry.js +4 -4
  60. package/dist/cjs/ifx-segmented-control.cjs.entry.js.map +1 -1
  61. package/dist/cjs/ifx-select.cjs.entry.js +4 -4
  62. package/dist/cjs/ifx-select.cjs.entry.js.map +1 -1
  63. package/dist/cjs/ifx-sidebar.cjs.entry.js +7 -7
  64. package/dist/cjs/ifx-sidebar.cjs.entry.js.map +1 -1
  65. package/dist/cjs/ifx-slider.cjs.entry.js +4 -4
  66. package/dist/cjs/ifx-slider.cjs.entry.js.map +1 -1
  67. package/dist/cjs/ifx-spinner_2.cjs.entry.js +9 -9
  68. package/dist/cjs/ifx-spinner_2.cjs.entry.js.map +1 -1
  69. package/dist/cjs/ifx-status.cjs.entry.js +3 -3
  70. package/dist/cjs/ifx-status.cjs.entry.js.map +1 -1
  71. package/dist/cjs/ifx-stepper.cjs.entry.js +4 -4
  72. package/dist/cjs/ifx-stepper.cjs.entry.js.map +1 -1
  73. package/dist/cjs/ifx-switch.cjs.entry.js +3 -3
  74. package/dist/cjs/ifx-switch.cjs.entry.js.map +1 -1
  75. package/dist/cjs/ifx-table.cjs.entry.js +4 -4
  76. package/dist/cjs/ifx-table.cjs.entry.js.map +1 -1
  77. package/dist/cjs/ifx-tabs.cjs.entry.js +4 -4
  78. package/dist/cjs/ifx-tabs.cjs.entry.js.map +1 -1
  79. package/dist/cjs/ifx-tag.cjs.entry.js +3 -3
  80. package/dist/cjs/ifx-tag.cjs.entry.js.map +1 -1
  81. package/dist/cjs/ifx-textarea.cjs.entry.js +3 -3
  82. package/dist/cjs/ifx-textarea.cjs.entry.js.map +1 -1
  83. package/dist/cjs/ifx-tooltip.cjs.entry.js +6 -6
  84. package/dist/cjs/ifx-tooltip.cjs.entry.js.map +1 -1
  85. package/dist/cjs/ifx-tree-view.cjs.entry.js +3 -3
  86. package/dist/cjs/ifx-tree-view.cjs.entry.js.map +1 -1
  87. package/dist/collection/components/accordion/accordion.js +2 -2
  88. package/dist/collection/components/accordion/accordion.js.map +1 -1
  89. package/dist/collection/components/alert/alert.js +1 -1
  90. package/dist/collection/components/alert/alert.js.map +1 -1
  91. package/dist/collection/components/badge/badge.js +2 -2
  92. package/dist/collection/components/badge/badge.js.map +1 -1
  93. package/dist/collection/components/breadcrumb/breadcrumb.js +2 -2
  94. package/dist/collection/components/breadcrumb/breadcrumb.js.map +1 -1
  95. package/dist/collection/components/button/button.js +2 -2
  96. package/dist/collection/components/button/button.js.map +1 -1
  97. package/dist/collection/components/card/card.js +4 -4
  98. package/dist/collection/components/card/card.js.map +1 -1
  99. package/dist/collection/components/checkbox/checkbox.js +4 -4
  100. package/dist/collection/components/checkbox/checkbox.js.map +1 -1
  101. package/dist/collection/components/checkbox-group/checkbox-group.js +2 -2
  102. package/dist/collection/components/checkbox-group/checkbox-group.js.map +1 -1
  103. package/dist/collection/components/chip/chip.js +9 -9
  104. package/dist/collection/components/chip/chip.js.map +1 -1
  105. package/dist/collection/components/content-switcher/content-switcher.js +2 -2
  106. package/dist/collection/components/content-switcher/content-switcher.js.map +1 -1
  107. package/dist/collection/components/date-picker/date-picker.js +3 -3
  108. package/dist/collection/components/date-picker/date-picker.js.map +1 -1
  109. package/dist/collection/components/dropdown/dropdown.js +2 -2
  110. package/dist/collection/components/dropdown/dropdown.js.map +1 -1
  111. package/dist/collection/components/file-upload/file-upload.js +3 -3
  112. package/dist/collection/components/file-upload/file-upload.js.map +1 -1
  113. package/dist/collection/components/footer/footer.js +5 -5
  114. package/dist/collection/components/footer/footer.js.map +1 -1
  115. package/dist/collection/components/icon/infineonIconStencil.js +2 -2
  116. package/dist/collection/components/icon/infineonIconStencil.js.map +1 -1
  117. package/dist/collection/components/icon-button/icon-button.js +2 -2
  118. package/dist/collection/components/icon-button/icon-button.js.map +1 -1
  119. package/dist/collection/components/indicator/indicator.js +3 -3
  120. package/dist/collection/components/indicator/indicator.js.map +1 -1
  121. package/dist/collection/components/link/link.js +2 -2
  122. package/dist/collection/components/link/link.js.map +1 -1
  123. package/dist/collection/components/modal/modal.js +3 -3
  124. package/dist/collection/components/modal/modal.js.map +1 -1
  125. package/dist/collection/components/navigation/navbar/navbar.js +4 -4
  126. package/dist/collection/components/navigation/navbar/navbar.js.map +1 -1
  127. package/dist/collection/components/navigation/sidebar/sidebar.js +6 -6
  128. package/dist/collection/components/navigation/sidebar/sidebar.js.map +1 -1
  129. package/dist/collection/components/notification/notification.js +3 -3
  130. package/dist/collection/components/notification/notification.js.map +1 -1
  131. package/dist/collection/components/pagination/pagination.js +2 -2
  132. package/dist/collection/components/pagination/pagination.js.map +1 -1
  133. package/dist/collection/components/progress-bar/progress-bar.js +2 -2
  134. package/dist/collection/components/progress-bar/progress-bar.js.map +1 -1
  135. package/dist/collection/components/radio-button/radio-button.js +3 -3
  136. package/dist/collection/components/radio-button/radio-button.js.map +1 -1
  137. package/dist/collection/components/radio-button-group/radio-button-group.js +2 -2
  138. package/dist/collection/components/radio-button-group/radio-button-group.js.map +1 -1
  139. package/dist/collection/components/search-bar/search-bar.js +2 -2
  140. package/dist/collection/components/search-bar/search-bar.js.map +1 -1
  141. package/dist/collection/components/search-field/search-field.js +2 -2
  142. package/dist/collection/components/search-field/search-field.js.map +1 -1
  143. package/dist/collection/components/segmented-control/segmented-control.js +3 -3
  144. package/dist/collection/components/segmented-control/segmented-control.js.map +1 -1
  145. package/dist/collection/components/select/multi-select/multiselect.js +1 -1
  146. package/dist/collection/components/select/multi-select/multiselect.js.map +1 -1
  147. package/dist/collection/components/select/single-select/select.js +3 -3
  148. package/dist/collection/components/select/single-select/select.js.map +1 -1
  149. package/dist/collection/components/slider/slider.js +3 -3
  150. package/dist/collection/components/slider/slider.js.map +1 -1
  151. package/dist/collection/components/spinner/spinner.js +3 -3
  152. package/dist/collection/components/spinner/spinner.js.map +1 -1
  153. package/dist/collection/components/status/status.js +2 -2
  154. package/dist/collection/components/status/status.js.map +1 -1
  155. package/dist/collection/components/stepper/stepper.js +3 -3
  156. package/dist/collection/components/stepper/stepper.js.map +1 -1
  157. package/dist/collection/components/switch/switch.js +2 -2
  158. package/dist/collection/components/switch/switch.js.map +1 -1
  159. package/dist/collection/components/table-advanced-version/table.js +3 -3
  160. package/dist/collection/components/table-advanced-version/table.js.map +1 -1
  161. package/dist/collection/components/table-basic-version/table.js +2 -2
  162. package/dist/collection/components/table-basic-version/table.js.map +1 -1
  163. package/dist/collection/components/tabs/tabs.js +3 -3
  164. package/dist/collection/components/tabs/tabs.js.map +1 -1
  165. package/dist/collection/components/tag/tag.js +2 -2
  166. package/dist/collection/components/tag/tag.js.map +1 -1
  167. package/dist/collection/components/text-field/text-field.js +5 -5
  168. package/dist/collection/components/text-field/text-field.js.map +1 -1
  169. package/dist/collection/components/textarea/textarea.js +2 -2
  170. package/dist/collection/components/textarea/textarea.js.map +1 -1
  171. package/dist/collection/components/tooltip/tooltip.js +5 -5
  172. package/dist/collection/components/tooltip/tooltip.js.map +1 -1
  173. package/dist/collection/components/tree-view/tree-view.js +2 -2
  174. package/dist/collection/components/tree-view/tree-view.js.map +1 -1
  175. package/dist/collection/global/utils/tracking.js +6 -2
  176. package/dist/collection/global/utils/tracking.js.map +1 -1
  177. package/dist/components/ifx-accordion-item.js +1 -1
  178. package/dist/components/ifx-accordion.js +1 -1
  179. package/dist/components/ifx-alert.js +1 -1
  180. package/dist/components/ifx-badge.js +3 -3
  181. package/dist/components/ifx-badge.js.map +1 -1
  182. package/dist/components/ifx-basic-table.js +3 -3
  183. package/dist/components/ifx-basic-table.js.map +1 -1
  184. package/dist/components/ifx-breadcrumb-item-label.js +1 -1
  185. package/dist/components/ifx-breadcrumb.js +3 -3
  186. package/dist/components/ifx-breadcrumb.js.map +1 -1
  187. package/dist/components/ifx-button.js +1 -1
  188. package/dist/components/ifx-card.js +5 -5
  189. package/dist/components/ifx-card.js.map +1 -1
  190. package/dist/components/ifx-checkbox-group.js +4 -4
  191. package/dist/components/ifx-checkbox-group.js.map +1 -1
  192. package/dist/components/ifx-checkbox.js +1 -1
  193. package/dist/components/ifx-chip-item.js +1 -1
  194. package/dist/components/ifx-chip.js +1 -1
  195. package/dist/components/ifx-content-switcher.js +3 -3
  196. package/dist/components/ifx-content-switcher.js.map +1 -1
  197. package/dist/components/ifx-date-picker.js +5 -5
  198. package/dist/components/ifx-date-picker.js.map +1 -1
  199. package/dist/components/ifx-download.js +1 -1
  200. package/dist/components/ifx-dropdown-item.js +1 -1
  201. package/dist/components/ifx-dropdown-trigger-button.js +2 -2
  202. package/dist/components/ifx-dropdown.js +3 -3
  203. package/dist/components/ifx-dropdown.js.map +1 -1
  204. package/dist/components/ifx-faq.js +3 -3
  205. package/dist/components/ifx-file-upload.js +8 -8
  206. package/dist/components/ifx-file-upload.js.map +1 -1
  207. package/dist/components/ifx-filter-accordion.js +2 -2
  208. package/dist/components/ifx-filter-bar.js +2 -2
  209. package/dist/components/ifx-filter-search.js +2 -2
  210. package/dist/components/ifx-footer.js +6 -6
  211. package/dist/components/ifx-footer.js.map +1 -1
  212. package/dist/components/ifx-icon-button.js +1 -1
  213. package/dist/components/ifx-icon.js +1 -1
  214. package/dist/components/ifx-icons-preview.js +4 -4
  215. package/dist/components/ifx-indicator.js +1 -1
  216. package/dist/components/ifx-link.js +1 -1
  217. package/dist/components/ifx-list-entry.js +3 -3
  218. package/dist/components/ifx-list.js +2 -2
  219. package/dist/components/ifx-modal.js +6 -6
  220. package/dist/components/ifx-modal.js.map +1 -1
  221. package/dist/components/ifx-multiselect-option.js +1 -1
  222. package/dist/components/ifx-multiselect.js +1 -1
  223. package/dist/components/ifx-navbar-item.js +2 -2
  224. package/dist/components/ifx-navbar.js +6 -6
  225. package/dist/components/ifx-navbar.js.map +1 -1
  226. package/dist/components/ifx-notification.js +1 -1
  227. package/dist/components/ifx-overview-table.js +3 -3
  228. package/dist/components/ifx-pagination.js +1 -1
  229. package/dist/components/ifx-progress-bar.js +1 -1
  230. package/dist/components/ifx-radio-button-group.js +4 -4
  231. package/dist/components/ifx-radio-button-group.js.map +1 -1
  232. package/dist/components/ifx-radio-button.js +1 -1
  233. package/dist/components/ifx-search-bar.js +5 -5
  234. package/dist/components/ifx-search-bar.js.map +1 -1
  235. package/dist/components/ifx-search-field.js +1 -1
  236. package/dist/components/ifx-segment.js +1 -1
  237. package/dist/components/ifx-segmented-control.js +5 -5
  238. package/dist/components/ifx-segmented-control.js.map +1 -1
  239. package/dist/components/ifx-select.js +1 -1
  240. package/dist/components/ifx-set-filter.js +7 -7
  241. package/dist/components/ifx-sidebar-item.js +2 -2
  242. package/dist/components/ifx-sidebar.js +7 -7
  243. package/dist/components/ifx-sidebar.js.map +1 -1
  244. package/dist/components/ifx-slider.js +5 -5
  245. package/dist/components/ifx-slider.js.map +1 -1
  246. package/dist/components/ifx-spinner.js +1 -1
  247. package/dist/components/ifx-status.js +3 -3
  248. package/dist/components/ifx-status.js.map +1 -1
  249. package/dist/components/ifx-step.js +1 -1
  250. package/dist/components/ifx-stepper.js +4 -4
  251. package/dist/components/ifx-stepper.js.map +1 -1
  252. package/dist/components/ifx-switch.js +3 -3
  253. package/dist/components/ifx-switch.js.map +1 -1
  254. package/dist/components/ifx-table.js +13 -13
  255. package/dist/components/ifx-table.js.map +1 -1
  256. package/dist/components/ifx-tabs.js +5 -5
  257. package/dist/components/ifx-tabs.js.map +1 -1
  258. package/dist/components/ifx-tag.js +4 -4
  259. package/dist/components/ifx-tag.js.map +1 -1
  260. package/dist/components/ifx-template.js +1 -1
  261. package/dist/components/ifx-templates-ui.js +8 -8
  262. package/dist/components/ifx-text-field.js +1 -1
  263. package/dist/components/ifx-textarea.js +3 -3
  264. package/dist/components/ifx-textarea.js.map +1 -1
  265. package/dist/components/ifx-tooltip.js +7 -7
  266. package/dist/components/ifx-tooltip.js.map +1 -1
  267. package/dist/components/ifx-tree-view-item.js +2 -2
  268. package/dist/components/ifx-tree-view.js +3 -3
  269. package/dist/components/ifx-tree-view.js.map +1 -1
  270. package/dist/components/{p-2a273455.js → p-0ff93a3a.js} +7 -7
  271. package/dist/components/p-0ff93a3a.js.map +1 -0
  272. package/dist/components/{p-005e409a.js → p-16396948.js} +5 -5
  273. package/dist/components/p-16396948.js.map +1 -0
  274. package/dist/components/{p-fb9d6e9c.js → p-185e5fb9.js} +4 -4
  275. package/dist/components/p-185e5fb9.js.map +1 -0
  276. package/dist/components/{p-11689c8c.js → p-1970ebfe.js} +6 -6
  277. package/dist/components/{p-11689c8c.js.map → p-1970ebfe.js.map} +1 -1
  278. package/dist/components/{p-68ca5a7a.js → p-2ce5aa1a.js} +5 -5
  279. package/dist/components/p-2ce5aa1a.js.map +1 -0
  280. package/dist/components/{p-3fe4bed6.js → p-31390cf7.js} +4 -4
  281. package/dist/components/p-31390cf7.js.map +1 -0
  282. package/dist/components/{p-873fbd50.js → p-336d75f2.js} +6 -6
  283. package/dist/components/p-336d75f2.js.map +1 -0
  284. package/dist/components/{p-0ca6d587.js → p-4c8a61c6.js} +4 -4
  285. package/dist/components/p-4c8a61c6.js.map +1 -0
  286. package/dist/components/{p-92679cba.js → p-4fb68589.js} +8 -8
  287. package/dist/components/p-4fb68589.js.map +1 -0
  288. package/dist/components/{p-090b29e9.js → p-53b471ca.js} +3 -3
  289. package/dist/components/{p-090b29e9.js.map → p-53b471ca.js.map} +1 -1
  290. package/dist/components/{p-748e2394.js → p-6cf233ab.js} +6 -6
  291. package/dist/components/p-6cf233ab.js.map +1 -0
  292. package/dist/components/{p-94752ce5.js → p-8a62ef10.js} +7 -7
  293. package/dist/components/p-8a62ef10.js.map +1 -0
  294. package/dist/components/{p-44900e96.js → p-8b964494.js} +4 -4
  295. package/dist/components/p-8b964494.js.map +1 -0
  296. package/dist/components/{p-c1454cb6.js → p-93da473c.js} +3 -3
  297. package/dist/components/{p-c1454cb6.js.map → p-93da473c.js.map} +1 -1
  298. package/dist/components/{p-43aee8a3.js → p-9746abcc.js} +2 -2
  299. package/dist/components/{p-43aee8a3.js.map → p-9746abcc.js.map} +1 -1
  300. package/dist/components/{p-5f4d5dd9.js → p-bd56aa1d.js} +4 -4
  301. package/dist/components/p-bd56aa1d.js.map +1 -0
  302. package/dist/components/{p-c16d6ad7.js → p-d2fd824d.js} +13 -13
  303. package/dist/components/p-d2fd824d.js.map +1 -0
  304. package/dist/{esm/framework-detection-bbcf3ea1.js → components/p-e48e9f36.js} +7 -3
  305. package/dist/components/p-e48e9f36.js.map +1 -0
  306. package/dist/components/{p-a2d11841.js → p-eb02a6c6.js} +5 -5
  307. package/dist/components/p-eb02a6c6.js.map +1 -0
  308. package/dist/components/{p-bd59bc9d.js → p-f8b426b4.js} +5 -5
  309. package/dist/components/p-f8b426b4.js.map +1 -0
  310. package/dist/components/{p-0bcf1a8a.js → p-fb2d2a57.js} +7 -7
  311. package/dist/components/p-fb2d2a57.js.map +1 -0
  312. package/dist/components/{p-6b0dfd8c.js → p-fe075a11.js} +5 -5
  313. package/dist/components/p-fe075a11.js.map +1 -0
  314. package/dist/components/{p-50944189.js → p-fe24919e.js} +4 -4
  315. package/dist/components/p-fe24919e.js.map +1 -0
  316. package/dist/{components/p-1de6e751.js → esm/framework-detection-1b61c595.js} +7 -3
  317. package/dist/esm/framework-detection-1b61c595.js.map +1 -0
  318. package/dist/esm/ifx-accordion_2.entry.js +3 -3
  319. package/dist/esm/ifx-accordion_2.entry.js.map +1 -1
  320. package/dist/esm/ifx-alert_2.entry.js +2 -2
  321. package/dist/esm/ifx-alert_2.entry.js.map +1 -1
  322. package/dist/esm/ifx-badge.entry.js +3 -3
  323. package/dist/esm/ifx-badge.entry.js.map +1 -1
  324. package/dist/esm/ifx-basic-table.entry.js +3 -3
  325. package/dist/esm/ifx-basic-table.entry.js.map +1 -1
  326. package/dist/esm/ifx-breadcrumb.entry.js +3 -3
  327. package/dist/esm/ifx-breadcrumb.entry.js.map +1 -1
  328. package/dist/esm/ifx-button.entry.js +3 -3
  329. package/dist/esm/ifx-button.entry.js.map +1 -1
  330. package/dist/esm/ifx-card.entry.js +5 -5
  331. package/dist/esm/ifx-card.entry.js.map +1 -1
  332. package/dist/esm/ifx-checkbox-group.entry.js +3 -3
  333. package/dist/esm/ifx-checkbox-group.entry.js.map +1 -1
  334. package/dist/esm/ifx-checkbox.entry.js +5 -5
  335. package/dist/esm/ifx-checkbox.entry.js.map +1 -1
  336. package/dist/esm/ifx-chip_3.entry.js +12 -12
  337. package/dist/esm/ifx-chip_3.entry.js.map +1 -1
  338. package/dist/esm/ifx-content-switcher.entry.js +3 -3
  339. package/dist/esm/ifx-content-switcher.entry.js.map +1 -1
  340. package/dist/esm/ifx-date-picker.entry.js +4 -4
  341. package/dist/esm/ifx-date-picker.entry.js.map +1 -1
  342. package/dist/esm/ifx-dropdown.entry.js +3 -3
  343. package/dist/esm/ifx-dropdown.entry.js.map +1 -1
  344. package/dist/esm/ifx-file-upload.entry.js +4 -4
  345. package/dist/esm/ifx-file-upload.entry.js.map +1 -1
  346. package/dist/esm/ifx-footer.entry.js +6 -6
  347. package/dist/esm/ifx-footer.entry.js.map +1 -1
  348. package/dist/esm/ifx-icon-button.entry.js +3 -3
  349. package/dist/esm/ifx-icon-button.entry.js.map +1 -1
  350. package/dist/esm/ifx-icon.entry.js +3 -3
  351. package/dist/esm/ifx-icon.entry.js.map +1 -1
  352. package/dist/esm/ifx-indicator.entry.js +4 -4
  353. package/dist/esm/ifx-indicator.entry.js.map +1 -1
  354. package/dist/esm/ifx-link.entry.js +3 -3
  355. package/dist/esm/ifx-link.entry.js.map +1 -1
  356. package/dist/esm/ifx-modal.entry.js +4 -4
  357. package/dist/esm/ifx-modal.entry.js.map +1 -1
  358. package/dist/esm/ifx-multiselect_2.entry.js +2 -2
  359. package/dist/esm/ifx-multiselect_2.entry.js.map +1 -1
  360. package/dist/esm/ifx-navbar.entry.js +5 -5
  361. package/dist/esm/ifx-navbar.entry.js.map +1 -1
  362. package/dist/esm/ifx-notification.entry.js +4 -4
  363. package/dist/esm/ifx-notification.entry.js.map +1 -1
  364. package/dist/esm/ifx-progress-bar.entry.js +3 -3
  365. package/dist/esm/ifx-progress-bar.entry.js.map +1 -1
  366. package/dist/esm/ifx-radio-button-group.entry.js +3 -3
  367. package/dist/esm/ifx-radio-button-group.entry.js.map +1 -1
  368. package/dist/esm/ifx-radio-button.entry.js +4 -4
  369. package/dist/esm/ifx-radio-button.entry.js.map +1 -1
  370. package/dist/esm/ifx-search-bar.entry.js +3 -3
  371. package/dist/esm/ifx-search-bar.entry.js.map +1 -1
  372. package/dist/esm/ifx-search-field.entry.js +3 -3
  373. package/dist/esm/ifx-search-field.entry.js.map +1 -1
  374. package/dist/esm/ifx-segmented-control.entry.js +4 -4
  375. package/dist/esm/ifx-segmented-control.entry.js.map +1 -1
  376. package/dist/esm/ifx-select.entry.js +4 -4
  377. package/dist/esm/ifx-select.entry.js.map +1 -1
  378. package/dist/esm/ifx-sidebar.entry.js +7 -7
  379. package/dist/esm/ifx-sidebar.entry.js.map +1 -1
  380. package/dist/esm/ifx-slider.entry.js +4 -4
  381. package/dist/esm/ifx-slider.entry.js.map +1 -1
  382. package/dist/esm/ifx-spinner_2.entry.js +9 -9
  383. package/dist/esm/ifx-spinner_2.entry.js.map +1 -1
  384. package/dist/esm/ifx-status.entry.js +3 -3
  385. package/dist/esm/ifx-status.entry.js.map +1 -1
  386. package/dist/esm/ifx-stepper.entry.js +4 -4
  387. package/dist/esm/ifx-stepper.entry.js.map +1 -1
  388. package/dist/esm/ifx-switch.entry.js +3 -3
  389. package/dist/esm/ifx-switch.entry.js.map +1 -1
  390. package/dist/esm/ifx-table.entry.js +4 -4
  391. package/dist/esm/ifx-table.entry.js.map +1 -1
  392. package/dist/esm/ifx-tabs.entry.js +4 -4
  393. package/dist/esm/ifx-tabs.entry.js.map +1 -1
  394. package/dist/esm/ifx-tag.entry.js +3 -3
  395. package/dist/esm/ifx-tag.entry.js.map +1 -1
  396. package/dist/esm/ifx-textarea.entry.js +3 -3
  397. package/dist/esm/ifx-textarea.entry.js.map +1 -1
  398. package/dist/esm/ifx-tooltip.entry.js +6 -6
  399. package/dist/esm/ifx-tooltip.entry.js.map +1 -1
  400. package/dist/esm/ifx-tree-view.entry.js +3 -3
  401. package/dist/esm/ifx-tree-view.entry.js.map +1 -1
  402. package/dist/infineon-design-system-stencil/infineon-design-system-stencil.esm.js +1 -1
  403. package/dist/infineon-design-system-stencil/p-011c2645.entry.js +2 -0
  404. package/dist/infineon-design-system-stencil/p-011c2645.entry.js.map +1 -0
  405. package/dist/infineon-design-system-stencil/{p-f9089710.entry.js → p-0d4e0500.entry.js} +2 -2
  406. package/dist/infineon-design-system-stencil/{p-f9089710.entry.js.map → p-0d4e0500.entry.js.map} +1 -1
  407. package/dist/infineon-design-system-stencil/{p-60dba634.entry.js → p-189eff5e.entry.js} +2 -2
  408. package/dist/infineon-design-system-stencil/{p-60dba634.entry.js.map → p-189eff5e.entry.js.map} +1 -1
  409. package/dist/infineon-design-system-stencil/p-248b8ba3.entry.js +2 -0
  410. package/dist/infineon-design-system-stencil/p-248b8ba3.entry.js.map +1 -0
  411. package/dist/infineon-design-system-stencil/p-2ff821ac.entry.js +2 -0
  412. package/dist/infineon-design-system-stencil/p-2ff821ac.entry.js.map +1 -0
  413. package/dist/infineon-design-system-stencil/p-36ec25f0.entry.js +2 -0
  414. package/dist/infineon-design-system-stencil/p-36ec25f0.entry.js.map +1 -0
  415. package/dist/infineon-design-system-stencil/p-36f0bb56.entry.js +2 -0
  416. package/dist/infineon-design-system-stencil/p-36f0bb56.entry.js.map +1 -0
  417. package/dist/infineon-design-system-stencil/{p-fb97bbf9.entry.js → p-37566d76.entry.js} +2 -2
  418. package/dist/infineon-design-system-stencil/{p-fb97bbf9.entry.js.map → p-37566d76.entry.js.map} +1 -1
  419. package/dist/infineon-design-system-stencil/p-37ee3504.entry.js +2 -0
  420. package/dist/infineon-design-system-stencil/p-37ee3504.entry.js.map +1 -0
  421. package/dist/infineon-design-system-stencil/{p-16af7217.entry.js → p-40c5541c.entry.js} +2 -2
  422. package/dist/infineon-design-system-stencil/{p-16af7217.entry.js.map → p-40c5541c.entry.js.map} +1 -1
  423. package/dist/infineon-design-system-stencil/p-49c3813d.entry.js +2 -0
  424. package/dist/infineon-design-system-stencil/p-49c3813d.entry.js.map +1 -0
  425. package/dist/infineon-design-system-stencil/{p-d3667aa7.entry.js → p-4ca23650.entry.js} +2 -2
  426. package/dist/infineon-design-system-stencil/{p-d3667aa7.entry.js.map → p-4ca23650.entry.js.map} +1 -1
  427. package/dist/infineon-design-system-stencil/p-5a24901d.entry.js +2 -0
  428. package/dist/infineon-design-system-stencil/{p-c85100e2.entry.js.map → p-5a24901d.entry.js.map} +1 -1
  429. package/dist/infineon-design-system-stencil/{p-2ece3483.entry.js → p-611bef3f.entry.js} +2 -2
  430. package/dist/infineon-design-system-stencil/{p-2ece3483.entry.js.map → p-611bef3f.entry.js.map} +1 -1
  431. package/dist/infineon-design-system-stencil/{p-7e25af07.entry.js → p-668103e6.entry.js} +2 -2
  432. package/dist/infineon-design-system-stencil/{p-7e25af07.entry.js.map → p-668103e6.entry.js.map} +1 -1
  433. package/dist/infineon-design-system-stencil/{p-9a1e5214.entry.js → p-7778f282.entry.js} +2 -2
  434. package/dist/infineon-design-system-stencil/{p-9a1e5214.entry.js.map → p-7778f282.entry.js.map} +1 -1
  435. package/dist/infineon-design-system-stencil/p-7cb007df.entry.js +2 -0
  436. package/dist/infineon-design-system-stencil/p-7cb007df.entry.js.map +1 -0
  437. package/dist/infineon-design-system-stencil/{p-c5da068a.entry.js → p-85ff4fb9.entry.js} +2 -2
  438. package/dist/infineon-design-system-stencil/p-85ff4fb9.entry.js.map +1 -0
  439. package/dist/infineon-design-system-stencil/p-8967a8ad.entry.js +2 -0
  440. package/dist/infineon-design-system-stencil/p-8967a8ad.entry.js.map +1 -0
  441. package/dist/infineon-design-system-stencil/p-8ae53d18.entry.js +2 -0
  442. package/dist/infineon-design-system-stencil/{p-9378df78.entry.js.map → p-8ae53d18.entry.js.map} +1 -1
  443. package/dist/infineon-design-system-stencil/{p-3349781f.entry.js → p-8bb3b82d.entry.js} +2 -2
  444. package/dist/infineon-design-system-stencil/{p-3349781f.entry.js.map → p-8bb3b82d.entry.js.map} +1 -1
  445. package/dist/infineon-design-system-stencil/{p-90254dcf.entry.js → p-8f6bb201.entry.js} +2 -2
  446. package/dist/infineon-design-system-stencil/{p-90254dcf.entry.js.map → p-8f6bb201.entry.js.map} +1 -1
  447. package/dist/infineon-design-system-stencil/{p-6a6e4b86.entry.js → p-9c71b34d.entry.js} +2 -2
  448. package/dist/infineon-design-system-stencil/{p-6a6e4b86.entry.js.map → p-9c71b34d.entry.js.map} +1 -1
  449. package/dist/infineon-design-system-stencil/{p-03f8d0c7.entry.js → p-9fe1af9b.entry.js} +2 -2
  450. package/dist/infineon-design-system-stencil/{p-03f8d0c7.entry.js.map → p-9fe1af9b.entry.js.map} +1 -1
  451. package/dist/infineon-design-system-stencil/{p-d1148b13.entry.js → p-a37478a7.entry.js} +2 -2
  452. package/dist/infineon-design-system-stencil/{p-d1148b13.entry.js.map → p-a37478a7.entry.js.map} +1 -1
  453. package/dist/infineon-design-system-stencil/{p-2ab9ed7a.entry.js → p-abbe5f97.entry.js} +3 -3
  454. package/dist/infineon-design-system-stencil/{p-2ab9ed7a.entry.js.map → p-abbe5f97.entry.js.map} +1 -1
  455. package/dist/infineon-design-system-stencil/p-b03105f7.entry.js +2 -0
  456. package/dist/infineon-design-system-stencil/{p-b86e8f88.entry.js.map → p-b03105f7.entry.js.map} +1 -1
  457. package/dist/infineon-design-system-stencil/{p-2eda2c4f.entry.js → p-b067df98.entry.js} +2 -2
  458. package/dist/infineon-design-system-stencil/{p-2eda2c4f.entry.js.map → p-b067df98.entry.js.map} +1 -1
  459. package/dist/infineon-design-system-stencil/p-b7a57c47.entry.js +2 -0
  460. package/dist/infineon-design-system-stencil/{p-602008c0.entry.js.map → p-b7a57c47.entry.js.map} +1 -1
  461. package/dist/infineon-design-system-stencil/{p-d8013cae.entry.js → p-bde1fd50.entry.js} +2 -2
  462. package/dist/infineon-design-system-stencil/{p-d8013cae.entry.js.map → p-bde1fd50.entry.js.map} +1 -1
  463. package/dist/infineon-design-system-stencil/p-c8e1eec8.entry.js +2 -0
  464. package/dist/infineon-design-system-stencil/p-c8e1eec8.entry.js.map +1 -0
  465. package/dist/infineon-design-system-stencil/p-d1b342ad.entry.js +2 -0
  466. package/dist/infineon-design-system-stencil/p-d1b342ad.entry.js.map +1 -0
  467. package/dist/infineon-design-system-stencil/{p-adc34bfa.entry.js → p-d29f7237.entry.js} +2 -2
  468. package/dist/infineon-design-system-stencil/{p-adc34bfa.entry.js.map → p-d29f7237.entry.js.map} +1 -1
  469. package/dist/infineon-design-system-stencil/{p-1b08aa70.entry.js → p-d827e5fc.entry.js} +2 -2
  470. package/dist/infineon-design-system-stencil/{p-1b08aa70.entry.js.map → p-d827e5fc.entry.js.map} +1 -1
  471. package/dist/infineon-design-system-stencil/{p-ef3206e1.entry.js → p-db66c7bc.entry.js} +2 -2
  472. package/dist/infineon-design-system-stencil/p-db66c7bc.entry.js.map +1 -0
  473. package/dist/infineon-design-system-stencil/p-e48e9f36.js +2 -0
  474. package/dist/infineon-design-system-stencil/p-e48e9f36.js.map +1 -0
  475. package/dist/infineon-design-system-stencil/p-e4d630cb.entry.js +2 -0
  476. package/dist/infineon-design-system-stencil/{p-a92f4323.entry.js.map → p-e4d630cb.entry.js.map} +1 -1
  477. package/dist/infineon-design-system-stencil/{p-8514a92f.entry.js → p-e5c97dd1.entry.js} +2 -2
  478. package/dist/infineon-design-system-stencil/{p-8514a92f.entry.js.map → p-e5c97dd1.entry.js.map} +1 -1
  479. package/dist/infineon-design-system-stencil/p-e9739ad0.entry.js +2 -0
  480. package/dist/infineon-design-system-stencil/{p-b6a3631b.entry.js.map → p-e9739ad0.entry.js.map} +1 -1
  481. package/dist/infineon-design-system-stencil/{p-98892fbc.entry.js → p-eda4d2f4.entry.js} +2 -2
  482. package/dist/infineon-design-system-stencil/p-eda4d2f4.entry.js.map +1 -0
  483. package/dist/infineon-design-system-stencil/{p-4beb861d.entry.js → p-ef95e710.entry.js} +2 -2
  484. package/dist/infineon-design-system-stencil/{p-4beb861d.entry.js.map → p-ef95e710.entry.js.map} +1 -1
  485. package/dist/infineon-design-system-stencil/p-f4e32d42.entry.js +2 -0
  486. package/dist/infineon-design-system-stencil/{p-5c5df17a.entry.js.map → p-f4e32d42.entry.js.map} +1 -1
  487. package/dist/infineon-design-system-stencil/{p-5951b526.entry.js → p-f9b028ad.entry.js} +2 -2
  488. package/dist/infineon-design-system-stencil/{p-5951b526.entry.js.map → p-f9b028ad.entry.js.map} +1 -1
  489. package/dist/types/global/utils/tracking.d.ts +1 -1
  490. package/package.json +1 -1
  491. package/dist/cjs/framework-detection-94ac6f10.js.map +0 -1
  492. package/dist/components/p-005e409a.js.map +0 -1
  493. package/dist/components/p-0bcf1a8a.js.map +0 -1
  494. package/dist/components/p-0ca6d587.js.map +0 -1
  495. package/dist/components/p-1de6e751.js.map +0 -1
  496. package/dist/components/p-2a273455.js.map +0 -1
  497. package/dist/components/p-3fe4bed6.js.map +0 -1
  498. package/dist/components/p-44900e96.js.map +0 -1
  499. package/dist/components/p-50944189.js.map +0 -1
  500. package/dist/components/p-5f4d5dd9.js.map +0 -1
  501. package/dist/components/p-68ca5a7a.js.map +0 -1
  502. package/dist/components/p-6b0dfd8c.js.map +0 -1
  503. package/dist/components/p-748e2394.js.map +0 -1
  504. package/dist/components/p-873fbd50.js.map +0 -1
  505. package/dist/components/p-92679cba.js.map +0 -1
  506. package/dist/components/p-94752ce5.js.map +0 -1
  507. package/dist/components/p-a2d11841.js.map +0 -1
  508. package/dist/components/p-bd59bc9d.js.map +0 -1
  509. package/dist/components/p-c16d6ad7.js.map +0 -1
  510. package/dist/components/p-fb9d6e9c.js.map +0 -1
  511. package/dist/esm/framework-detection-bbcf3ea1.js.map +0 -1
  512. package/dist/infineon-design-system-stencil/p-1de6e751.js +0 -2
  513. package/dist/infineon-design-system-stencil/p-1de6e751.js.map +0 -1
  514. package/dist/infineon-design-system-stencil/p-2d97ec1a.entry.js +0 -2
  515. package/dist/infineon-design-system-stencil/p-2d97ec1a.entry.js.map +0 -1
  516. package/dist/infineon-design-system-stencil/p-30f3124c.entry.js +0 -2
  517. package/dist/infineon-design-system-stencil/p-30f3124c.entry.js.map +0 -1
  518. package/dist/infineon-design-system-stencil/p-3657e33e.entry.js +0 -2
  519. package/dist/infineon-design-system-stencil/p-3657e33e.entry.js.map +0 -1
  520. package/dist/infineon-design-system-stencil/p-3687b541.entry.js +0 -2
  521. package/dist/infineon-design-system-stencil/p-3687b541.entry.js.map +0 -1
  522. package/dist/infineon-design-system-stencil/p-4a7df058.entry.js +0 -2
  523. package/dist/infineon-design-system-stencil/p-4a7df058.entry.js.map +0 -1
  524. package/dist/infineon-design-system-stencil/p-5c5df17a.entry.js +0 -2
  525. package/dist/infineon-design-system-stencil/p-602008c0.entry.js +0 -2
  526. package/dist/infineon-design-system-stencil/p-608d419c.entry.js +0 -2
  527. package/dist/infineon-design-system-stencil/p-608d419c.entry.js.map +0 -1
  528. package/dist/infineon-design-system-stencil/p-7a894bcf.entry.js +0 -2
  529. package/dist/infineon-design-system-stencil/p-7a894bcf.entry.js.map +0 -1
  530. package/dist/infineon-design-system-stencil/p-9378df78.entry.js +0 -2
  531. package/dist/infineon-design-system-stencil/p-98892fbc.entry.js.map +0 -1
  532. package/dist/infineon-design-system-stencil/p-a16a3155.entry.js +0 -2
  533. package/dist/infineon-design-system-stencil/p-a16a3155.entry.js.map +0 -1
  534. package/dist/infineon-design-system-stencil/p-a92f4323.entry.js +0 -2
  535. package/dist/infineon-design-system-stencil/p-b1c006f4.entry.js +0 -2
  536. package/dist/infineon-design-system-stencil/p-b1c006f4.entry.js.map +0 -1
  537. package/dist/infineon-design-system-stencil/p-b6a3631b.entry.js +0 -2
  538. package/dist/infineon-design-system-stencil/p-b86e8f88.entry.js +0 -2
  539. package/dist/infineon-design-system-stencil/p-c5da068a.entry.js.map +0 -1
  540. package/dist/infineon-design-system-stencil/p-c85100e2.entry.js +0 -2
  541. package/dist/infineon-design-system-stencil/p-cede9c28.entry.js +0 -2
  542. package/dist/infineon-design-system-stencil/p-cede9c28.entry.js.map +0 -1
  543. package/dist/infineon-design-system-stencil/p-e0d49a9b.entry.js +0 -2
  544. package/dist/infineon-design-system-stencil/p-e0d49a9b.entry.js.map +0 -1
  545. package/dist/infineon-design-system-stencil/p-ef3206e1.entry.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"names":["fileUploadCss","IfxFileUploadStyle0","FileUpload","constructor","hostRef","this","dragAndDrop","required","disabled","maxFileSizeMB","allowedFileTypes","additionalAllowedFileTypes","label","labelRequiredError","labelBrowseFiles","labelDragAndDrop","labelUploadedFilesHeading","labelFileTooLarge","labelUnsupportedFileType","labelUploaded","labelUploadFailed","labelSupportedFormatsTemplate","labelFileSingular","labelFilePlural","labelMaxFilesInfo","labelMaxFilesExceeded","ariaLabelBrowseFiles","ariaLabelDropzone","ariaLabelFileInput","ariaLabelRemoveFile","ariaLabelCancelUpload","ariaLabelRetryUpload","ariaLabelUploadingStatus","ariaLabelUploadedStatus","ariaLabelUploadFailedStatus","internalId","Math","random","toString","substr","isDragOver","files","uploadTasks","rejectedSizeFiles","rejectedTypeFiles","requiredError","statusMessage","fileInputEl","extensionToMimeMap","jpg","jpeg","png","gif","svg","webp","pdf","doc","docx","xls","xlsx","ppt","pptx","txt","csv","json","mp3","wav","mp4","mov","webm","zip","rar","tar","gz","xml","html","css","js","maxFiles","_maxFiles","value","console","warn","undefined","validateRequired","length","_a","text","type","ifxFileUploadValidation","emit","valid","_b","pluralize","count","getNormalizedFileTypes","Array","isArray","JSON","parse","split","map","t","trim","getLabelFromMimeType","mime","ext","knownMime","Object","entries","toUpperCase","handleFileChange","event","input","target","processFiles","handleDrop","preventDefault","stopPropagation","dataTransfer","droppedFiles","from","allowedMimes","toLowerCase","filter","Boolean","getAdditionalMimeTypes","acceptedFiles","rejectedFiles","forEach","file","isValidType","includes","isValidSize","size","push","ifxFileUploadDrop","handleDragOver","handleDragLeave","fileList","selectedFiles","validFiles","rejectedSize","rejectedType","isDuplicate","some","existing","name","ifxFileUploadInvalid","reason","ifxFileUploadError","errorType","message","availableSlots","limitedFiles","slice","max","overflowFiles","startUpload","ifxFileUploadAdd","addedFiles","ifxFileUploadChange","replace","ifxFileUploadMaxFilesExceeded","attempted","retryUpload","taskIndex","findIndex","splice","ifxFileUploadRetry","ifxFileUploadStart","task","progress","intervalId","completed","uploadHandler","percent","min","then","ifxFileUploadComplete","every","ifxFileUploadAllComplete","catch","error","totalSize","fakeUploadSpeed","uploaded","window","setInterval","round","clearInterval","cancelUpload","_","i","f","ifxFileUploadAbort","removeFile","ifxFileUploadRemove","removedFile","clearRejectedFile","fileName","splitFileNameParts","dotIndex","lastIndexOf","base","substring","getFileIcon","extension","pop","formatSize","bytes","toFixed","getAcceptAttribute","extensionTypes","mimeTypes","join","getFormattedProgressText","uploadedSize","uploadedText","totalText","getSupportedFileText","extensions","allTypes","typesLabel","fileWord","maxFilesText","getFormattedFileTooLargeText","renderStatusMessage","h","class","icon","isInputDisabled","componentWillLoad","isNestedInIfxComponent","hostElement","framework","detectFramework","trackComponent","componentDidLoad","hasAttribute","showDemoStates","injectDemoState","dummyContent","fill","bigContent","uploading","File","failed","tooLarge","unsupported","triggerDemoValidation","render","key","htmlFor","renderDragAndDropArea","renderUploadArea","shape","variant","onClick","find","isUploading","isError","itemClass","uniqueKey","style","display","handleInputRef","el","click","id","ref","accept","multiple","onChange","e","triggerInputClick","onDragOver","onDragLeave","onDrop","role","tabIndex","height","overflow"],"sources":["src/components/file-upload/file-upload.scss?tag=ifx-file-upload&encapsulation=shadow","src/components/file-upload/file-upload.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n:host {\n // TODO remove\n font-family: var(--ifx-font-family, sans-serif);\n}\n\n.file-upload-wrapper {\n display: flex;\n flex-direction: column;\n\n &.disabled {\n pointer-events: none;\n\n label,\n .file-upload-info {\n color: tokens.$ifxColorEngineering500;\n }\n }\n}\n\n.file-upload-label {\n font-style: normal;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeM;\n line-height: tokens.$ifxLineHeightM;\n color: tokens.$ifxColorBaseBlack;\n\n .required {\n display: inline-block;\n margin-left: 4px;\n\n &.error {\n color: tokens.$ifxColorRed500;\n }\n }\n}\n\n.upload-dropzone {\n border: 1px dashed tokens.$ifxColorEngineering300;\n padding: tokens.$ifxSpace500;\n text-align: center;\n cursor: pointer;\n color: tokens.$ifxColorBaseBlack;\n transition: border-color 0.3s ease;\n border-radius: tokens.$ifxBorderRadius12;\n background: tokens.$ifxColorBaseWhite;\n\n ifx-icon {\n color: tokens.$ifxColorOcean500;\n }\n\n &:hover {\n border: 1px dashed tokens.$ifxColorEngineering400;\n }\n\n &.drag-over {\n border: 1px solid tokens.$ifxColorOcean500;\n background: tokens.$ifxColorEngineering100;\n\n &.error {\n border: 1px solid tokens.$ifxColorOcean500;\n }\n }\n\n &.error {\n border-color: tokens.$ifxColorRed500;\n }\n\n .disabled & {\n pointer-events: none;\n border-color: tokens.$ifxColorEngineering300;\n color: tokens.$ifxColorEngineering300;\n\n ifx-icon {\n color: tokens.$ifxColorEngineering300;\n }\n }\n}\n\n.upload-dropzone input {\n display: none;\n}\n\n.file-upload-info {\n font-style: normal;\n font-weight: tokens.$ifxFontWeightRegular;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n letter-spacing: tokens.$ifxLetterSpacingDefault;\n color: tokens.$ifxColorBaseBlack;\n margin: 0;\n margin-top: tokens.$ifxSpace50;\n}\n\n.file-upload-status {\n font-style: normal;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n letter-spacing: 0.2px;\n margin-top: tokens.$ifxSpace100;\n\n &.file-upload-status__error {\n display: flex;\n align-items: center;\n color: tokens.$ifxColorRed500;\n\n ifx-icon {\n position: relative;\n top: - tokens.$ifxSpace12;\n color: tokens.$ifxColorRed500;\n margin-right: tokens.$ifxSpace100;\n }\n }\n}\n\n.upload-heading {\n font: tokens.$ifxHeadingHeading06;\n margin-bottom: tokens.$ifxSpace100;\n}\n\n.file-list-wrapper {\n margin-top: tokens.$ifxSpace200;\n}\n\n.file-list {\n list-style: none;\n padding: 0;\n margin: 0;\n display: flex;\n flex-direction: column;\n gap: tokens.$ifxSpace200;\n}\n\n.file-item {\n border: 1px solid tokens.$ifxColorEngineering300;\n padding-top: tokens.$ifxSpace150;\n padding-right: tokens.$ifxSpace200;\n padding-bottom: tokens.$ifxSpace100;\n padding-left: tokens.$ifxSpace200;\n display: flex;\n gap: tokens.$ifxSpace100;\n}\n\n.file-info {\n width: 100%;\n min-width: 0;\n}\n\n.file-top-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: tokens.$ifxSpace200;\n margin-top: - tokens.$ifxSpace100;\n}\n\n.file-top-row ifx-icon {\n flex-shrink: 0;\n}\n\n.file-name-wrapper {\n display: flex;\n min-width: 0;\n max-width: 100%;\n white-space: nowrap;\n overflow: hidden;\n font-weight: tokens.$ifxFontWeightRegular;\n font-size: tokens.$ifxFontSizeS;\n}\n\n.file-name-base {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n flex-shrink: 1;\n min-width: 0;\n}\n\n.file-name-ext {\n flex-shrink: 0;\n margin-left: 0;\n}\n\n.file-middle-row {\n display: flex;\n align-items: center;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n flex-wrap: wrap;\n color: tokens.$ifxColorEngineering500;\n\n .file-status {\n margin-left: tokens.$ifxSpace150;\n\n ifx-icon {\n margin-right: tokens.$ifxSpace100;\n }\n }\n}\n\n.file-progress-row {\n margin-top: tokens.$ifxSpace50;\n}\n\n.file-progress-row ifx-progress-bar {\n width: 100%;\n}\n\n.upload-success {\n border-color: tokens.$ifxColorOcean500;\n\n .file-status {\n ifx-icon {\n position: relative;\n top: tokens.$ifxSpace12;\n color: tokens.$ifxColorGreen500;\n }\n }\n}\n\n.upload-failed {\n border-color: tokens.$ifxColorRed500;\n\n .file-status {\n color: tokens.$ifxColorRed500;\n margin-left: 0;\n }\n}\n","import { Component, h, State, Event, EventEmitter, Prop, Method, Element } from '@stencil/core';\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\n\ninterface UploadTask {\n file: File;\n progress: number;\n intervalId: number | null;\n completed: boolean;\n error?: boolean;\n}\n\nexport type FileUploadErrorReason =\n | 'network-error'\n | 'timeout'\n | 'file-too-large'\n | 'unsupported-type'\n | 'invalid-type'\n | 'custom'\n | (string & {});\n\n@Component({\n tag: 'ifx-file-upload',\n styleUrl: 'file-upload.scss',\n shadow: true\n})\nexport class FileUpload {\n @Element() hostElement: HTMLElement;\n\n @Prop() dragAndDrop: boolean = false;\n @Prop() required: boolean = false;\n @Prop() disabled: boolean = false;\n @Prop() maxFileSizeMB: number = 7;\n /** Default set of allowed file extensions (used internally). Can be extended using `additionalAllowedFileTypes`. */\n @Prop() allowedFileTypes: string | string[] = ['jpg', 'jpeg', 'png', 'pdf', 'mov', 'mp3', 'mp4'];\n @Prop() additionalAllowedFileTypes?: string | string[] = [];\n @Prop() uploadHandler?: (file: File, onProgress?: (progress: number) => void) => Promise<void>;\n\n private _maxFiles?: number;\n @Prop()\n get maxFiles(): number | undefined {\n return this._maxFiles;\n }\n set maxFiles(value: number | undefined) {\n if (typeof value === 'number' && value < 1) {\n console.warn('Invalid `maxFiles` value. Must be >= 1. Value ignored.');\n this._maxFiles = undefined;\n } else {\n this._maxFiles = value;\n }\n }\n\n @Prop() label: string = 'Label';\n @Prop() labelRequiredError: string = 'At least one file must be uploaded';\n @Prop() labelBrowseFiles: string = 'Browse files';\n @Prop() labelDragAndDrop: string = 'Drag & Drop or browse files to upload';\n @Prop() labelUploadedFilesHeading: string = 'Uploaded files';\n @Prop() labelFileTooLarge: string = 'Upload failed. Max file size: {{size}}MB.';\n @Prop() labelUnsupportedFileType: string = 'Unsupported file type.';\n @Prop() labelUploaded: string = 'Successfully uploaded';\n @Prop() labelUploadFailed: string = 'Upload failed. Please try again.';\n @Prop() labelSupportedFormatsTemplate: string = 'Supported file formats: {{types}}. Max file size: {{size}}MB.';\n @Prop() labelFileSingular: string = 'file';\n @Prop() labelFilePlural: string = 'files';\n @Prop() labelMaxFilesInfo?: string = 'Up to {{count}} {{files}}.';\n @Prop() labelMaxFilesExceeded: string = 'Upload limit exceeded. Only {{count}} {{files}} allowed.';\n\n @Prop() ariaLabelBrowseFiles: string = 'Browse files';\n @Prop() ariaLabelDropzone: string = 'Upload area. Click to browse or drag and drop files.';\n @Prop() ariaLabelFileInput: string = 'Upload file';\n @Prop() ariaLabelRemoveFile: string = 'Remove file';\n @Prop() ariaLabelCancelUpload: string = 'Cancel upload';\n @Prop() ariaLabelRetryUpload: string = 'Retry upload';\n @Prop() ariaLabelUploadingStatus: string = 'Upload in progress';\n @Prop() ariaLabelUploadedStatus: string = 'Upload completed';\n @Prop() ariaLabelUploadFailedStatus: string = 'Upload failed';\n\n private showDemoStates?: boolean;\n private internalId = `ifx-file-upload-${Math.random().toString(36).substr(2, 9)}`;\n\n @State() isDragOver: boolean = false;\n @State() files: File[] = [];\n @State() uploadTasks: UploadTask[] = [];\n @State() rejectedSizeFiles: string[] = [];\n @State() rejectedTypeFiles: string[] = [];\n @State() requiredError: boolean = false;\n @State() statusMessage: { type: 'error' | 'info' | 'success'; text: string } | null = null;\n\n\n @Event() ifxFileUploadAdd: EventEmitter<{ addedFiles: File[]; files: File[] }>;\n @Event() ifxFileUploadRemove: EventEmitter<{ removedFile: File; files: File[] }>;\n @Event() ifxFileUploadChange: EventEmitter<{ files: File[] }>;\n @Event() ifxFileUploadError: EventEmitter<{ errorType: string; file: File; message: string; reason?: string; }>;\n @Event() ifxFileUploadInvalid: EventEmitter<{ file: File; reason: string }>;\n @Event() ifxFileUploadStart: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadComplete: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadAllComplete: EventEmitter<{ files: File[] }>;\n @Event() ifxFileUploadAbort: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadDrop: EventEmitter<{ droppedFiles: File[]; acceptedFiles: File[]; rejectedFiles: File[] }>;\n @Event() ifxFileUploadClick: EventEmitter<void>;\n @Event() ifxFileUploadMaxFilesExceeded: EventEmitter<{ maxFiles: number; attempted: number }>;\n @Event() ifxFileUploadValidation: EventEmitter<{ valid: boolean }>;\n @Event() ifxFileUploadRetry: EventEmitter<{ file: File }>;\n\n private fileInputEl: HTMLInputElement | null = null;\n\n private extensionToMimeMap: Record<string, string> = {\n /**\n * Maps file extensions to MIME types.\n * This is only used for translating `allowedFileTypes` (extensions) into MIME types,\n * and for labeling in the UI. It does NOT define which files are globally allowed.\n */\n\n // Images\n jpg: 'image/jpeg',\n jpeg: 'image/jpeg',\n png: 'image/png',\n gif: 'image/gif',\n svg: 'image/svg+xml',\n webp: 'image/webp',\n\n // Documents\n pdf: 'application/pdf',\n doc: 'application/msword',\n docx: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\n xls: 'application/vnd.ms-excel',\n xlsx: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\n ppt: 'application/vnd.ms-powerpoint',\n pptx: 'application/vnd.openxmlformats-officedocument.presentationml.presentation',\n txt: 'text/plain',\n csv: 'text/csv',\n json: 'application/json',\n\n // Audio/Video\n mp3: 'audio/mpeg',\n wav: 'audio/wav',\n mp4: 'video/mp4',\n mov: 'video/quicktime',\n webm: 'video/webm',\n\n // Archive / Code\n zip: 'application/zip',\n rar: 'application/vnd.rar',\n tar: 'application/x-tar',\n gz: 'application/gzip',\n\n // Sonstiges\n xml: 'application/xml',\n html: 'text/html',\n css: 'text/css',\n js: 'application/javascript'\n };\n\n private validateRequired(): void {\n if (this.required && this.files.length === 0) {\n this.requiredError = true;\n\n if (this.statusMessage?.text !== this.labelRequiredError) {\n this.statusMessage = {\n type: 'error',\n text: this.labelRequiredError\n };\n }\n\n this.ifxFileUploadValidation.emit({ valid: false });\n } else {\n this.requiredError = false;\n\n if (this.statusMessage?.text === this.labelRequiredError) {\n this.statusMessage = null;\n }\n\n this.ifxFileUploadValidation.emit({ valid: true });\n }\n }\n\n private pluralize(count: number): string {\n return count === 1 ? this.labelFileSingular : this.labelFilePlural;\n }\n\n private getNormalizedFileTypes(): string[] {\n if (Array.isArray(this.allowedFileTypes)) {\n return this.allowedFileTypes;\n }\n try {\n return JSON.parse(this.allowedFileTypes);\n } catch {\n return this.allowedFileTypes.split(',').map(t => t.trim());\n }\n }\n\n private getLabelFromMimeType(mime: string): string {\n for (const [ext, knownMime] of Object.entries(this.extensionToMimeMap)) {\n if (knownMime === mime) {\n return ext.toUpperCase();\n }\n }\n return mime; // fallback: show raw MIME\n }\n\n handleFileChange(event: Event) {\n const input = event.target as HTMLInputElement;\n if (!input.files) return;\n this.processFiles(input.files);\n }\n\n handleDrop(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n event.stopPropagation();\n this.isDragOver = false;\n if (event.dataTransfer?.files) {\n const droppedFiles = Array.from(event.dataTransfer.files);\n const allowedMimes = [\n ...this.getNormalizedFileTypes()\n .map(ext => this.extensionToMimeMap[ext.toLowerCase()])\n .filter(Boolean),\n ...this.getAdditionalMimeTypes()\n ];\n\n const acceptedFiles: File[] = [];\n const rejectedFiles: File[] = [];\n\n droppedFiles.forEach(file => {\n const isValidType = allowedMimes.includes(file.type);\n const isValidSize = file.size <= this.maxFileSizeMB * 1024 * 1024;\n if (isValidType && isValidSize) acceptedFiles.push(file);\n else rejectedFiles.push(file);\n });\n\n this.ifxFileUploadDrop.emit({\n droppedFiles,\n acceptedFiles,\n rejectedFiles\n });\n\n this.processFiles(event.dataTransfer.files);\n }\n }\n\n handleDragOver(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n this.isDragOver = true;\n }\n\n handleDragLeave(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n this.isDragOver = false;\n }\n\n processFiles(fileList: FileList) {\n const selectedFiles = Array.from(fileList);\n const allowedMimes = [\n ...this.getNormalizedFileTypes()\n .map(ext => this.extensionToMimeMap[ext.toLowerCase()])\n .filter(Boolean),\n ...this.getAdditionalMimeTypes()\n ];\n\n const validFiles: File[] = [];\n const rejectedSize: string[] = [];\n const rejectedType: string[] = [];\n\n selectedFiles.forEach(file => {\n const isValidType = allowedMimes.includes(file.type);\n const isValidSize = file.size <= this.maxFileSizeMB * 1024 * 1024;\n const isDuplicate = this.files.some(existing =>\n existing.name === file.name && existing.size === file.size\n );\n\n if (isDuplicate) {\n this.ifxFileUploadInvalid.emit({ file, reason: 'duplicate' });\n this.ifxFileUploadError.emit({\n file,\n errorType: 'duplicate',\n message: `File \"${file.name}\" is already added`,\n reason: 'duplicate'\n });\n return;\n }\n\n if (isValidType && isValidSize) {\n validFiles.push(file);\n } else {\n if (!isValidType) {\n rejectedType.push(file.name);\n this.ifxFileUploadInvalid.emit({ file, reason: 'invalid-type' });\n }\n if (!isValidSize) {\n rejectedSize.push(file.name);\n this.ifxFileUploadInvalid.emit({ file, reason: 'invalid-size' });\n }\n this.ifxFileUploadError.emit({\n file,\n errorType: !isValidType ? 'invalid-type' : 'file-too-large',\n message: 'Invalid file rejected',\n reason: !isValidType ? 'unsupported-type' : 'file-too-large'\n });\n }\n });\n\n this.rejectedSizeFiles = [...this.rejectedSizeFiles, ...rejectedSize];\n this.rejectedTypeFiles = [...this.rejectedTypeFiles, ...rejectedType];\n\n if (this.maxFiles && this.files.length + validFiles.length > this.maxFiles) {\n const availableSlots = this.maxFiles - this.files.length;\n const limitedFiles = validFiles.slice(0, Math.max(availableSlots, 0));\n const overflowFiles = validFiles.slice(availableSlots);\n\n this.files = [...this.files, ...limitedFiles];\n\n limitedFiles.forEach(file => this.startUpload(file));\n\n if (limitedFiles.length > 0) {\n this.ifxFileUploadAdd.emit({ addedFiles: limitedFiles, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n }\n\n overflowFiles.forEach(file => {\n this.ifxFileUploadInvalid.emit({ file, reason: 'too-many-files' });\n this.ifxFileUploadError.emit({\n file,\n errorType: 'too-many-files',\n message: `Upload limit exceeded. Max ${this.maxFiles} files allowed.`,\n reason: 'too-many-files'\n });\n });\n\n if (overflowFiles.length > 0) {\n this.statusMessage = {\n type: 'error',\n text: this.labelMaxFilesExceeded\n .replace('{{count}}', this.maxFiles.toString())\n .replace('{{files}}', this.pluralize(this.maxFiles))\n };\n this.ifxFileUploadMaxFilesExceeded.emit({\n maxFiles: this.maxFiles,\n attempted: this.files.length + validFiles.length\n });\n }\n\n return;\n }\n\n\n validFiles.forEach(file => this.startUpload(file));\n this.files = [...this.files, ...validFiles];\n\n if (validFiles.length > 0) {\n this.ifxFileUploadAdd.emit({ addedFiles: validFiles, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n }\n\n this.validateRequired();\n }\n\n retryUpload(file: File) {\n const taskIndex = this.uploadTasks.findIndex(t => t.file.name === file.name);\n if (taskIndex !== -1) {\n this.uploadTasks.splice(taskIndex, 1);\n this.uploadTasks = [...this.uploadTasks];\n }\n this.ifxFileUploadRetry.emit({ file });\n this.startUpload(file);\n }\n\n startUpload(file: File) {\n this.ifxFileUploadStart.emit({ file });\n\n const task: UploadTask = {\n file,\n progress: 3, // Start with initial progress for better UX\n intervalId: null,\n completed: false,\n };\n\n this.uploadTasks = [...this.uploadTasks, task];\n\n if (this.uploadHandler) {\n this.uploadHandler(file, (percent: number) => {\n if (percent > task.progress) {\n task.progress = Math.min(100, percent);\n this.uploadTasks = [...this.uploadTasks];\n }\n }).then(() => {\n task.progress = 100;\n task.completed = true;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadComplete.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n\n if (this.uploadTasks.every(t => t.completed)) {\n this.ifxFileUploadAllComplete.emit({ files: this.files });\n }\n }).catch(() => {\n task.error = true;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadError.emit({\n file,\n errorType: 'upload-failed',\n message: 'Upload handler rejected file',\n reason: 'custom'\n });\n });\n } else {\n const totalSize = file.size;\n const fakeUploadSpeed = 100000;\n let uploaded = 0;\n\n task.intervalId = window.setInterval(() => {\n uploaded += fakeUploadSpeed / 5;\n const progress = Math.min(100, Math.round((uploaded / totalSize) * 100));\n task.progress = progress;\n this.uploadTasks = [...this.uploadTasks];\n\n if (progress >= 100) {\n clearInterval(task.intervalId!);\n task.completed = true;\n task.intervalId = null;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadComplete.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n\n if (this.uploadTasks.every(t => t.completed)) {\n this.ifxFileUploadAllComplete.emit({ files: this.files });\n }\n }\n }, 200);\n }\n\n this.uploadTasks = [...this.uploadTasks, task];\n }\n\n cancelUpload(file: File) {\n const taskIndex = this.uploadTasks.findIndex(t => t.file.name === file.name);\n if (taskIndex !== -1) {\n const task = this.uploadTasks[taskIndex];\n if (task?.intervalId !== null) {\n clearInterval(task.intervalId);\n }\n this.uploadTasks = this.uploadTasks.filter((_, i) => i !== taskIndex);\n }\n this.files = this.files.filter(f => f.name !== file.name);\n this.ifxFileUploadAbort.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n this.validateRequired();\n }\n\n removeFile(file: File) {\n this.uploadTasks = this.uploadTasks.filter(task => task.file.name !== file.name);\n this.files = this.files.filter(f => f.name !== file.name);\n this.ifxFileUploadRemove.emit({ removedFile: file, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n this.validateRequired();\n\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n\n if (\n this.maxFiles &&\n this.files.length < this.maxFiles &&\n this.statusMessage?.text !== this.labelRequiredError\n ) {\n this.statusMessage = null;\n }\n }\n\n\n clearRejectedFile(fileName: string, type: 'size' | 'type') {\n if (type === 'size') {\n this.rejectedSizeFiles = this.rejectedSizeFiles.filter(f => f !== fileName);\n } else {\n this.rejectedTypeFiles = this.rejectedTypeFiles.filter(f => f !== fileName);\n }\n\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n\n if (this.maxFiles && this.files.length < this.maxFiles) {\n this.statusMessage = null;\n }\n\n this.validateRequired();\n }\n\n splitFileNameParts(file: File): { base: string; ext: string } {\n const name = file.name;\n const dotIndex = name.lastIndexOf('.');\n if (dotIndex === -1) return { base: name, ext: '' };\n return {\n base: name.substring(0, dotIndex),\n ext: name.substring(dotIndex)\n };\n }\n\n getFileIcon(file: File): string {\n const extension = file.name.split('.').pop()?.toLowerCase();\n switch (extension) {\n case 'pdf': return 'file-pdf-16';\n case 'jpg':\n case 'jpeg': return 'file-jpg-16';\n case 'png': return 'file-png-16';\n case 'mov': return 'file-mov-16';\n case 'mp3': return 'file-mp3-16';\n case 'mp4': return 'file-mp4-16';\n default: return 'file-16';\n }\n }\n\n formatSize(bytes: number): string {\n if (bytes >= 1024 * 1024 * 1024) {\n return `${(bytes / (1024 * 1024 * 1024)).toFixed(1)} GB`;\n } else if (bytes >= 1024 * 1024) {\n return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;\n } else if (bytes >= 1024) {\n return `${(bytes / 1024).toFixed(0)} KB`;\n } else {\n return `${bytes} B`;\n }\n }\n\n getAcceptAttribute(): string {\n const extensionTypes = this.getNormalizedFileTypes().map(ext => '.' + ext.toLowerCase());\n const mimeTypes = this.getAdditionalMimeTypes();\n\n return [...extensionTypes, ...mimeTypes].join(',');\n }\n\n private getFormattedProgressText(task: UploadTask): string {\n const uploadedSize = Math.round((task.progress / 100) * task.file.size);\n const uploadedText = this.formatSize(uploadedSize);\n const totalText = this.formatSize(task.file.size);\n return `${uploadedText} / ${totalText} uploaded`;\n }\n\n private getAdditionalMimeTypes(): string[] {\n if (!this.additionalAllowedFileTypes) return [];\n if (Array.isArray(this.additionalAllowedFileTypes)) return this.additionalAllowedFileTypes;\n return this.additionalAllowedFileTypes.split(',').map(t => t.trim());\n }\n\n private getSupportedFileText(): string {\n const extensions = this.getNormalizedFileTypes().map(ext => ext.toUpperCase());\n const mimeTypes = this.getAdditionalMimeTypes().map(mime => this.getLabelFromMimeType(mime));\n const allTypes = [...extensions, ...mimeTypes];\n const typesLabel = allTypes.join(', ');\n\n let text = this.labelSupportedFormatsTemplate\n .replace('{{types}}', typesLabel)\n .replace('{{size}}', this.maxFileSizeMB.toString());\n\n if (this.labelMaxFilesInfo && this.maxFiles) {\n const fileWord = this.pluralize(this.maxFiles);\n const maxFilesText = this.labelMaxFilesInfo\n .replace('{{count}}', this.maxFiles.toString())\n .replace('{{files}}', fileWord);\n text += ` ${maxFilesText}`;\n }\n\n return text;\n }\n\n private getFormattedFileTooLargeText(): string {\n return this.labelFileTooLarge.replace('{{size}}', this.maxFileSizeMB.toString());\n }\n\n private renderStatusMessage() {\n if (!this.statusMessage) return null;\n\n return (\n <div class={`file-upload-status file-upload-status__${this.statusMessage.type}`}>\n {this.statusMessage.type === 'error' && (\n <ifx-icon icon=\"c-warning-16\"></ifx-icon>\n )}\n {this.statusMessage.text}\n </div>\n );\n }\n\n private isInputDisabled(): boolean {\n return this.disabled || (this.maxFiles !== undefined && this.files.length >= this.maxFiles);\n }\n\n componentWillLoad() { \n if(!isNestedInIfxComponent(this.hostElement)) { \n const framework = detectFramework();\n trackComponent('ifx-file-upload', { framework })\n }\n }\n\n componentDidLoad() {\n if (this.hostElement.hasAttribute('show-demo-states')) {\n this.showDemoStates = true;\n }\n\n if (this.showDemoStates) {\n this.injectDemoState();\n }\n }\n\n // Storybook Demo\n @Method()\n async injectDemoState() {\n const dummyContent = new Array(50000).fill('a').join(''); // ~50 KB\n const bigContent = dummyContent + dummyContent; // ~100 KB\n\n const uploading = new File([dummyContent], 'Image.jpg', { type: 'image/jpeg' }); // ~50 KB\n const uploaded = new File([bigContent], 'File.pdf', { type: 'application/pdf' }); // ~100 KB\n const failed = new File([dummyContent], 'Text.docx', { type: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' }); // ~50 KB\n const tooLarge = new File([bigContent + bigContent + bigContent], 'Video.mp4', { type: 'video/mp4' }); // ~300 KB\n const unsupported = new File(['demo'], 'Script.exe', { type: 'application/x-msdownload' }); // very small\n\n this.files = [uploaded, uploading, failed];\n this.uploadTasks = [\n { file: uploaded, progress: 100, intervalId: null, completed: true },\n { file: uploading, progress: 40, intervalId: null, completed: false },\n { file: failed, progress: 80, intervalId: null, completed: false, error: true }\n ];\n this.rejectedSizeFiles = [tooLarge.name];\n this.rejectedTypeFiles = [unsupported.name];\n }\n\n\n\n // Storybook Demo\n @Method()\n async triggerDemoValidation(): Promise<void> {\n this.validateRequired();\n }\n\n render() {\n return (\n <div\n class={{\n 'file-upload-wrapper': true,\n 'disabled': this.disabled\n }}\n >\n {this.label && (\n <label class=\"file-upload-label\" htmlFor={this.internalId}>\n {this.label}\n {this.required && (\n <span class={`required ${this.requiredError ? 'error' : ''}`}>*</span>\n )}\n </label>\n )}\n\n {this.dragAndDrop ? this.renderDragAndDropArea() : this.renderUploadArea()}\n\n {(this.files.length > 0 || this.rejectedSizeFiles.length > 0 || this.rejectedTypeFiles.length > 0) && (\n <div class=\"file-list-wrapper\">\n <div class=\"upload-heading\">{this.labelUploadedFilesHeading}</div>\n <ul class=\"file-list\">\n {this.rejectedSizeFiles.map(fileName => (\n <li class=\"file-item upload-failed\" key={`rejected-size-${fileName}`}>\n <div class=\"file-icon\">\n <ifx-icon icon=\"file-16\"></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{this.splitFileNameParts({ name: fileName } as File).base}</span>\n <span class=\"file-name-ext\">{this.splitFileNameParts({ name: fileName } as File).ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.clearRejectedFile(fileName, 'size')}\n ></ifx-icon-button>\n </div>\n </div>\n <div class=\"file-middle-row\">\n <span class=\"file-status\" aria-label={this.labelFileTooLarge.replace('{{size}}', this.maxFileSizeMB.toString())}>\n {this.getFormattedFileTooLargeText()}\n </span>\n </div>\n </div>\n </li>\n ))}\n\n {this.rejectedTypeFiles.map(fileName => (\n <li class=\"file-item upload-failed\" key={`rejected-type-${fileName}`}>\n <div class=\"file-icon\">\n <ifx-icon icon=\"file-16\"></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{this.splitFileNameParts({ name: fileName } as File).base}</span>\n <span class=\"file-name-ext\">{this.splitFileNameParts({ name: fileName } as File).ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.clearRejectedFile(fileName, 'type')}\n ></ifx-icon-button>\n </div>\n </div>\n <div class=\"file-middle-row\">\n <span class=\"file-status\" aria-label={this.labelUnsupportedFileType}>\n {this.labelUnsupportedFileType}\n </span>\n </div>\n </div>\n </li>\n ))}\n\n {this.files.map((file) => {\n const task = this.uploadTasks.find(t => t.file.name === file.name);\n const progress = task?.progress ?? 100;\n const isUploading = task && !task.completed;\n const isError = task?.error === true;\n const itemClass = isError ? 'file-item upload-failed' : isUploading ? 'file-item uploading' : 'file-item upload-success';\n const uniqueKey = `${file.name}-${file.size}`;\n const { base, ext } = this.splitFileNameParts(file);\n\n return (\n <li class={itemClass} key={uniqueKey}>\n <div class=\"file-icon\">\n <ifx-icon icon={this.getFileIcon(file)}></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{base}</span>\n <span class=\"file-name-ext\">{ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"refresh-16\"\n size=\"s\"\n aria-label={this.ariaLabelRetryUpload}\n onClick={() => this.retryUpload(file)}\n style={{ display: isError ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"cross-16\"\n size=\"s\"\n aria-label={this.ariaLabelCancelUpload}\n onClick={() => this.cancelUpload(file)}\n style={{ display: isUploading ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.removeFile(file)}\n style={{ display: !isUploading ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n </div>\n </div>\n\n <div class=\"file-middle-row\">\n {isUploading && task && !task.error && (\n <span class=\"file-uploading\" aria-label={this.ariaLabelUploadingStatus}>\n {this.getFormattedProgressText(task)}\n </span>\n )}\n {!isUploading && !isError && (\n <span>\n <span class=\"file-size\">{this.formatSize(file.size)}</span>\n <span class=\"file-status\" aria-label={this.ariaLabelUploadedStatus}>\n <ifx-icon icon=\"check-16\"></ifx-icon>\n {this.labelUploaded}\n </span>\n </span>\n )}\n {isError && (\n <span class=\"file-status\" aria-label={this.ariaLabelUploadFailedStatus}>\n {this.labelUploadFailed}\n </span>\n )}\n </div>\n\n {isUploading && task && !task.error && (\n <div class=\"file-progress-row\">\n <ifx-progress-bar\n size=\"s\"\n value={progress}\n show-label=\"true\"\n ></ifx-progress-bar>\n </div>\n )}\n </div>\n </li>\n );\n })}\n </ul>\n </div>\n )}\n </div>\n );\n }\n\n renderUploadArea() {\n const handleInputRef = (el: HTMLInputElement | null) => {\n this.fileInputEl = el;\n };\n\n return (\n <div class={{ 'upload-button': true }}>\n <ifx-button\n variant=\"secondary\"\n onClick={() => this.fileInputEl?.click()}\n disabled={this.isInputDisabled()}\n aria-label={this.ariaLabelBrowseFiles}\n >\n <ifx-icon icon=\"upload-16\"></ifx-icon>\n {this.labelBrowseFiles}\n </ifx-button>\n <input\n id={this.internalId}\n ref={handleInputRef}\n type=\"file\"\n accept={this.getAcceptAttribute()}\n multiple\n onChange={(e) => this.handleFileChange(e)}\n style={{ display: 'none' }}\n disabled={this.isInputDisabled()}\n aria-label={this.ariaLabelFileInput}\n />\n <p class=\"file-upload-info\">\n {this.getSupportedFileText()}\n </p>\n {this.renderStatusMessage()}\n </div>\n );\n }\n\n\n renderDragAndDropArea() {\n const handleInputRef = (el: HTMLInputElement | null) => {\n this.fileInputEl = el;\n };\n\n const triggerInputClick = () => {\n if (this.fileInputEl) {\n this.fileInputEl.click();\n }\n };\n\n return (\n <div class={{ 'disabled': this.isInputDisabled() }}>\n <div\n class={{ 'upload-dropzone': true, 'drag-over': this.isDragOver, 'error': this.requiredError }}\n onClick={triggerInputClick}\n onDragOver={(e) => this.handleDragOver(e)}\n onDragLeave={(e) => this.handleDragLeave(e)}\n onDrop={(e) => this.handleDrop(e)}\n role=\"button\"\n tabIndex={0}\n aria-label={this.ariaLabelDropzone}\n >\n <ifx-icon icon=\"upload-16\" class=\"custom-icon\"></ifx-icon>\n <p>{this.labelDragAndDrop}</p>\n <p class=\"file-upload-info\">\n {this.getSupportedFileText()}\n </p>\n <div style={{ height: '0px', overflow: 'hidden' }}>\n <input\n id={this.internalId}\n ref={handleInputRef}\n type=\"file\"\n accept={this.getAcceptAttribute()}\n multiple\n onChange={(e) => this.handleFileChange(e)}\n disabled={this.isInputDisabled()}\n aria-label={this.ari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","dragAndDrop","required","disabled","maxFileSizeMB","allowedFileTypes","additionalAllowedFileTypes","label","labelRequiredError","labelBrowseFiles","labelDragAndDrop","labelUploadedFilesHeading","labelFileTooLarge","labelUnsupportedFileType","labelUploaded","labelUploadFailed","labelSupportedFormatsTemplate","labelFileSingular","labelFilePlural","labelMaxFilesInfo","labelMaxFilesExceeded","ariaLabelBrowseFiles","ariaLabelDropzone","ariaLabelFileInput","ariaLabelRemoveFile","ariaLabelCancelUpload","ariaLabelRetryUpload","ariaLabelUploadingStatus","ariaLabelUploadedStatus","ariaLabelUploadFailedStatus","internalId","Math","random","toString","substr","isDragOver","files","uploadTasks","rejectedSizeFiles","rejectedTypeFiles","requiredError","statusMessage","fileInputEl","extensionToMimeMap","jpg","jpeg","png","gif","svg","webp","pdf","doc","docx","xls","xlsx","ppt","pptx","txt","csv","json","mp3","wav","mp4","mov","webm","zip","rar","tar","gz","xml","html","css","js","maxFiles","_maxFiles","value","console","warn","undefined","validateRequired","length","_a","text","type","ifxFileUploadValidation","emit","valid","_b","pluralize","count","getNormalizedFileTypes","Array","isArray","JSON","parse","split","map","t","trim","getLabelFromMimeType","mime","ext","knownMime","Object","entries","toUpperCase","handleFileChange","event","input","target","processFiles","handleDrop","preventDefault","stopPropagation","dataTransfer","droppedFiles","from","allowedMimes","toLowerCase","filter","Boolean","getAdditionalMimeTypes","acceptedFiles","rejectedFiles","forEach","file","isValidType","includes","isValidSize","size","push","ifxFileUploadDrop","handleDragOver","handleDragLeave","fileList","selectedFiles","validFiles","rejectedSize","rejectedType","isDuplicate","some","existing","name","ifxFileUploadInvalid","reason","ifxFileUploadError","errorType","message","availableSlots","limitedFiles","slice","max","overflowFiles","startUpload","ifxFileUploadAdd","addedFiles","ifxFileUploadChange","replace","ifxFileUploadMaxFilesExceeded","attempted","retryUpload","taskIndex","findIndex","splice","ifxFileUploadRetry","ifxFileUploadStart","task","progress","intervalId","completed","uploadHandler","percent","min","then","ifxFileUploadComplete","every","ifxFileUploadAllComplete","catch","error","totalSize","fakeUploadSpeed","uploaded","window","setInterval","round","clearInterval","cancelUpload","_","i","f","ifxFileUploadAbort","removeFile","ifxFileUploadRemove","removedFile","clearRejectedFile","fileName","splitFileNameParts","dotIndex","lastIndexOf","base","substring","getFileIcon","extension","pop","formatSize","bytes","toFixed","getAcceptAttribute","extensionTypes","mimeTypes","join","getFormattedProgressText","uploadedSize","uploadedText","totalText","getSupportedFileText","extensions","allTypes","typesLabel","fileWord","maxFilesText","getFormattedFileTooLargeText","renderStatusMessage","h","class","icon","isInputDisabled","componentWillLoad","isNestedInIfxComponent","hostElement","framework","detectFramework","trackComponent","componentDidLoad","hasAttribute","showDemoStates","injectDemoState","dummyContent","fill","bigContent","uploading","File","failed","tooLarge","unsupported","triggerDemoValidation","render","key","htmlFor","renderDragAndDropArea","renderUploadArea","shape","variant","onClick","find","isUploading","isError","itemClass","uniqueKey","style","display","handleInputRef","el","click","id","ref","accept","multiple","onChange","e","triggerInputClick","onDragOver","onDragLeave","onDrop","role","tabIndex","height","overflow"],"sources":["src/components/file-upload/file-upload.scss?tag=ifx-file-upload&encapsulation=shadow","src/components/file-upload/file-upload.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n:host {\n // TODO remove\n font-family: var(--ifx-font-family, sans-serif);\n}\n\n.file-upload-wrapper {\n display: flex;\n flex-direction: column;\n\n &.disabled {\n pointer-events: none;\n\n label,\n .file-upload-info {\n color: tokens.$ifxColorEngineering500;\n }\n }\n}\n\n.file-upload-label {\n font-style: normal;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeM;\n line-height: tokens.$ifxLineHeightM;\n color: tokens.$ifxColorBaseBlack;\n\n .required {\n display: inline-block;\n margin-left: 4px;\n\n &.error {\n color: tokens.$ifxColorRed500;\n }\n }\n}\n\n.upload-dropzone {\n border: 1px dashed tokens.$ifxColorEngineering300;\n padding: tokens.$ifxSpace500;\n text-align: center;\n cursor: pointer;\n color: tokens.$ifxColorBaseBlack;\n transition: border-color 0.3s ease;\n border-radius: tokens.$ifxBorderRadius12;\n background: tokens.$ifxColorBaseWhite;\n\n ifx-icon {\n color: tokens.$ifxColorOcean500;\n }\n\n &:hover {\n border: 1px dashed tokens.$ifxColorEngineering400;\n }\n\n &.drag-over {\n border: 1px solid tokens.$ifxColorOcean500;\n background: tokens.$ifxColorEngineering100;\n\n &.error {\n border: 1px solid tokens.$ifxColorOcean500;\n }\n }\n\n &.error {\n border-color: tokens.$ifxColorRed500;\n }\n\n .disabled & {\n pointer-events: none;\n border-color: tokens.$ifxColorEngineering300;\n color: tokens.$ifxColorEngineering300;\n\n ifx-icon {\n color: tokens.$ifxColorEngineering300;\n }\n }\n}\n\n.upload-dropzone input {\n display: none;\n}\n\n.file-upload-info {\n font-style: normal;\n font-weight: tokens.$ifxFontWeightRegular;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n letter-spacing: tokens.$ifxLetterSpacingDefault;\n color: tokens.$ifxColorBaseBlack;\n margin: 0;\n margin-top: tokens.$ifxSpace50;\n}\n\n.file-upload-status {\n font-style: normal;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n letter-spacing: 0.2px;\n margin-top: tokens.$ifxSpace100;\n\n &.file-upload-status__error {\n display: flex;\n align-items: center;\n color: tokens.$ifxColorRed500;\n\n ifx-icon {\n position: relative;\n top: - tokens.$ifxSpace12;\n color: tokens.$ifxColorRed500;\n margin-right: tokens.$ifxSpace100;\n }\n }\n}\n\n.upload-heading {\n font: tokens.$ifxHeadingHeading06;\n margin-bottom: tokens.$ifxSpace100;\n}\n\n.file-list-wrapper {\n margin-top: tokens.$ifxSpace200;\n}\n\n.file-list {\n list-style: none;\n padding: 0;\n margin: 0;\n display: flex;\n flex-direction: column;\n gap: tokens.$ifxSpace200;\n}\n\n.file-item {\n border: 1px solid tokens.$ifxColorEngineering300;\n padding-top: tokens.$ifxSpace150;\n padding-right: tokens.$ifxSpace200;\n padding-bottom: tokens.$ifxSpace100;\n padding-left: tokens.$ifxSpace200;\n display: flex;\n gap: tokens.$ifxSpace100;\n}\n\n.file-info {\n width: 100%;\n min-width: 0;\n}\n\n.file-top-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: tokens.$ifxSpace200;\n margin-top: - tokens.$ifxSpace100;\n}\n\n.file-top-row ifx-icon {\n flex-shrink: 0;\n}\n\n.file-name-wrapper {\n display: flex;\n min-width: 0;\n max-width: 100%;\n white-space: nowrap;\n overflow: hidden;\n font-weight: tokens.$ifxFontWeightRegular;\n font-size: tokens.$ifxFontSizeS;\n}\n\n.file-name-base {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n flex-shrink: 1;\n min-width: 0;\n}\n\n.file-name-ext {\n flex-shrink: 0;\n margin-left: 0;\n}\n\n.file-middle-row {\n display: flex;\n align-items: center;\n font-size: tokens.$ifxFontSizeXs;\n line-height: tokens.$ifxLineHeightXs;\n flex-wrap: wrap;\n color: tokens.$ifxColorEngineering500;\n\n .file-status {\n margin-left: tokens.$ifxSpace150;\n\n ifx-icon {\n margin-right: tokens.$ifxSpace100;\n }\n }\n}\n\n.file-progress-row {\n margin-top: tokens.$ifxSpace50;\n}\n\n.file-progress-row ifx-progress-bar {\n width: 100%;\n}\n\n.upload-success {\n border-color: tokens.$ifxColorOcean500;\n\n .file-status {\n ifx-icon {\n position: relative;\n top: tokens.$ifxSpace12;\n color: tokens.$ifxColorGreen500;\n }\n }\n}\n\n.upload-failed {\n border-color: tokens.$ifxColorRed500;\n\n .file-status {\n color: tokens.$ifxColorRed500;\n margin-left: 0;\n }\n}\n","import { Component, h, State, Event, EventEmitter, Prop, Method, Element } from '@stencil/core';\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\n\ninterface UploadTask {\n file: File;\n progress: number;\n intervalId: number | null;\n completed: boolean;\n error?: boolean;\n}\n\nexport type FileUploadErrorReason =\n | 'network-error'\n | 'timeout'\n | 'file-too-large'\n | 'unsupported-type'\n | 'invalid-type'\n | 'custom'\n | (string & {});\n\n@Component({\n tag: 'ifx-file-upload',\n styleUrl: 'file-upload.scss',\n shadow: true\n})\nexport class FileUpload {\n @Element() hostElement: HTMLElement;\n\n @Prop() dragAndDrop: boolean = false;\n @Prop() required: boolean = false;\n @Prop() disabled: boolean = false;\n @Prop() maxFileSizeMB: number = 7;\n /** Default set of allowed file extensions (used internally). Can be extended using `additionalAllowedFileTypes`. */\n @Prop() allowedFileTypes: string | string[] = ['jpg', 'jpeg', 'png', 'pdf', 'mov', 'mp3', 'mp4'];\n @Prop() additionalAllowedFileTypes?: string | string[] = [];\n @Prop() uploadHandler?: (file: File, onProgress?: (progress: number) => void) => Promise<void>;\n\n private _maxFiles?: number;\n @Prop()\n get maxFiles(): number | undefined {\n return this._maxFiles;\n }\n set maxFiles(value: number | undefined) {\n if (typeof value === 'number' && value < 1) {\n console.warn('Invalid `maxFiles` value. Must be >= 1. Value ignored.');\n this._maxFiles = undefined;\n } else {\n this._maxFiles = value;\n }\n }\n\n @Prop() label: string = 'Label';\n @Prop() labelRequiredError: string = 'At least one file must be uploaded';\n @Prop() labelBrowseFiles: string = 'Browse files';\n @Prop() labelDragAndDrop: string = 'Drag & Drop or browse files to upload';\n @Prop() labelUploadedFilesHeading: string = 'Uploaded files';\n @Prop() labelFileTooLarge: string = 'Upload failed. Max file size: {{size}}MB.';\n @Prop() labelUnsupportedFileType: string = 'Unsupported file type.';\n @Prop() labelUploaded: string = 'Successfully uploaded';\n @Prop() labelUploadFailed: string = 'Upload failed. Please try again.';\n @Prop() labelSupportedFormatsTemplate: string = 'Supported file formats: {{types}}. Max file size: {{size}}MB.';\n @Prop() labelFileSingular: string = 'file';\n @Prop() labelFilePlural: string = 'files';\n @Prop() labelMaxFilesInfo?: string = 'Up to {{count}} {{files}}.';\n @Prop() labelMaxFilesExceeded: string = 'Upload limit exceeded. Only {{count}} {{files}} allowed.';\n\n @Prop() ariaLabelBrowseFiles: string = 'Browse files';\n @Prop() ariaLabelDropzone: string = 'Upload area. Click to browse or drag and drop files.';\n @Prop() ariaLabelFileInput: string = 'Upload file';\n @Prop() ariaLabelRemoveFile: string = 'Remove file';\n @Prop() ariaLabelCancelUpload: string = 'Cancel upload';\n @Prop() ariaLabelRetryUpload: string = 'Retry upload';\n @Prop() ariaLabelUploadingStatus: string = 'Upload in progress';\n @Prop() ariaLabelUploadedStatus: string = 'Upload completed';\n @Prop() ariaLabelUploadFailedStatus: string = 'Upload failed';\n\n private showDemoStates?: boolean;\n private internalId = `ifx-file-upload-${Math.random().toString(36).substr(2, 9)}`;\n\n @State() isDragOver: boolean = false;\n @State() files: File[] = [];\n @State() uploadTasks: UploadTask[] = [];\n @State() rejectedSizeFiles: string[] = [];\n @State() rejectedTypeFiles: string[] = [];\n @State() requiredError: boolean = false;\n @State() statusMessage: { type: 'error' | 'info' | 'success'; text: string } | null = null;\n\n\n @Event() ifxFileUploadAdd: EventEmitter<{ addedFiles: File[]; files: File[] }>;\n @Event() ifxFileUploadRemove: EventEmitter<{ removedFile: File; files: File[] }>;\n @Event() ifxFileUploadChange: EventEmitter<{ files: File[] }>;\n @Event() ifxFileUploadError: EventEmitter<{ errorType: string; file: File; message: string; reason?: string; }>;\n @Event() ifxFileUploadInvalid: EventEmitter<{ file: File; reason: string }>;\n @Event() ifxFileUploadStart: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadComplete: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadAllComplete: EventEmitter<{ files: File[] }>;\n @Event() ifxFileUploadAbort: EventEmitter<{ file: File }>;\n @Event() ifxFileUploadDrop: EventEmitter<{ droppedFiles: File[]; acceptedFiles: File[]; rejectedFiles: File[] }>;\n @Event() ifxFileUploadClick: EventEmitter<void>;\n @Event() ifxFileUploadMaxFilesExceeded: EventEmitter<{ maxFiles: number; attempted: number }>;\n @Event() ifxFileUploadValidation: EventEmitter<{ valid: boolean }>;\n @Event() ifxFileUploadRetry: EventEmitter<{ file: File }>;\n\n private fileInputEl: HTMLInputElement | null = null;\n\n private extensionToMimeMap: Record<string, string> = {\n /**\n * Maps file extensions to MIME types.\n * This is only used for translating `allowedFileTypes` (extensions) into MIME types,\n * and for labeling in the UI. It does NOT define which files are globally allowed.\n */\n\n // Images\n jpg: 'image/jpeg',\n jpeg: 'image/jpeg',\n png: 'image/png',\n gif: 'image/gif',\n svg: 'image/svg+xml',\n webp: 'image/webp',\n\n // Documents\n pdf: 'application/pdf',\n doc: 'application/msword',\n docx: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\n xls: 'application/vnd.ms-excel',\n xlsx: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\n ppt: 'application/vnd.ms-powerpoint',\n pptx: 'application/vnd.openxmlformats-officedocument.presentationml.presentation',\n txt: 'text/plain',\n csv: 'text/csv',\n json: 'application/json',\n\n // Audio/Video\n mp3: 'audio/mpeg',\n wav: 'audio/wav',\n mp4: 'video/mp4',\n mov: 'video/quicktime',\n webm: 'video/webm',\n\n // Archive / Code\n zip: 'application/zip',\n rar: 'application/vnd.rar',\n tar: 'application/x-tar',\n gz: 'application/gzip',\n\n // Sonstiges\n xml: 'application/xml',\n html: 'text/html',\n css: 'text/css',\n js: 'application/javascript'\n };\n\n private validateRequired(): void {\n if (this.required && this.files.length === 0) {\n this.requiredError = true;\n\n if (this.statusMessage?.text !== this.labelRequiredError) {\n this.statusMessage = {\n type: 'error',\n text: this.labelRequiredError\n };\n }\n\n this.ifxFileUploadValidation.emit({ valid: false });\n } else {\n this.requiredError = false;\n\n if (this.statusMessage?.text === this.labelRequiredError) {\n this.statusMessage = null;\n }\n\n this.ifxFileUploadValidation.emit({ valid: true });\n }\n }\n\n private pluralize(count: number): string {\n return count === 1 ? this.labelFileSingular : this.labelFilePlural;\n }\n\n private getNormalizedFileTypes(): string[] {\n if (Array.isArray(this.allowedFileTypes)) {\n return this.allowedFileTypes;\n }\n try {\n return JSON.parse(this.allowedFileTypes);\n } catch {\n return this.allowedFileTypes.split(',').map(t => t.trim());\n }\n }\n\n private getLabelFromMimeType(mime: string): string {\n for (const [ext, knownMime] of Object.entries(this.extensionToMimeMap)) {\n if (knownMime === mime) {\n return ext.toUpperCase();\n }\n }\n return mime; // fallback: show raw MIME\n }\n\n handleFileChange(event: Event) {\n const input = event.target as HTMLInputElement;\n if (!input.files) return;\n this.processFiles(input.files);\n }\n\n handleDrop(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n event.stopPropagation();\n this.isDragOver = false;\n if (event.dataTransfer?.files) {\n const droppedFiles = Array.from(event.dataTransfer.files);\n const allowedMimes = [\n ...this.getNormalizedFileTypes()\n .map(ext => this.extensionToMimeMap[ext.toLowerCase()])\n .filter(Boolean),\n ...this.getAdditionalMimeTypes()\n ];\n\n const acceptedFiles: File[] = [];\n const rejectedFiles: File[] = [];\n\n droppedFiles.forEach(file => {\n const isValidType = allowedMimes.includes(file.type);\n const isValidSize = file.size <= this.maxFileSizeMB * 1024 * 1024;\n if (isValidType && isValidSize) acceptedFiles.push(file);\n else rejectedFiles.push(file);\n });\n\n this.ifxFileUploadDrop.emit({\n droppedFiles,\n acceptedFiles,\n rejectedFiles\n });\n\n this.processFiles(event.dataTransfer.files);\n }\n }\n\n handleDragOver(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n this.isDragOver = true;\n }\n\n handleDragLeave(event: DragEvent) {\n if (this.disabled) return;\n event.preventDefault();\n this.isDragOver = false;\n }\n\n processFiles(fileList: FileList) {\n const selectedFiles = Array.from(fileList);\n const allowedMimes = [\n ...this.getNormalizedFileTypes()\n .map(ext => this.extensionToMimeMap[ext.toLowerCase()])\n .filter(Boolean),\n ...this.getAdditionalMimeTypes()\n ];\n\n const validFiles: File[] = [];\n const rejectedSize: string[] = [];\n const rejectedType: string[] = [];\n\n selectedFiles.forEach(file => {\n const isValidType = allowedMimes.includes(file.type);\n const isValidSize = file.size <= this.maxFileSizeMB * 1024 * 1024;\n const isDuplicate = this.files.some(existing =>\n existing.name === file.name && existing.size === file.size\n );\n\n if (isDuplicate) {\n this.ifxFileUploadInvalid.emit({ file, reason: 'duplicate' });\n this.ifxFileUploadError.emit({\n file,\n errorType: 'duplicate',\n message: `File \"${file.name}\" is already added`,\n reason: 'duplicate'\n });\n return;\n }\n\n if (isValidType && isValidSize) {\n validFiles.push(file);\n } else {\n if (!isValidType) {\n rejectedType.push(file.name);\n this.ifxFileUploadInvalid.emit({ file, reason: 'invalid-type' });\n }\n if (!isValidSize) {\n rejectedSize.push(file.name);\n this.ifxFileUploadInvalid.emit({ file, reason: 'invalid-size' });\n }\n this.ifxFileUploadError.emit({\n file,\n errorType: !isValidType ? 'invalid-type' : 'file-too-large',\n message: 'Invalid file rejected',\n reason: !isValidType ? 'unsupported-type' : 'file-too-large'\n });\n }\n });\n\n this.rejectedSizeFiles = [...this.rejectedSizeFiles, ...rejectedSize];\n this.rejectedTypeFiles = [...this.rejectedTypeFiles, ...rejectedType];\n\n if (this.maxFiles && this.files.length + validFiles.length > this.maxFiles) {\n const availableSlots = this.maxFiles - this.files.length;\n const limitedFiles = validFiles.slice(0, Math.max(availableSlots, 0));\n const overflowFiles = validFiles.slice(availableSlots);\n\n this.files = [...this.files, ...limitedFiles];\n\n limitedFiles.forEach(file => this.startUpload(file));\n\n if (limitedFiles.length > 0) {\n this.ifxFileUploadAdd.emit({ addedFiles: limitedFiles, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n }\n\n overflowFiles.forEach(file => {\n this.ifxFileUploadInvalid.emit({ file, reason: 'too-many-files' });\n this.ifxFileUploadError.emit({\n file,\n errorType: 'too-many-files',\n message: `Upload limit exceeded. Max ${this.maxFiles} files allowed.`,\n reason: 'too-many-files'\n });\n });\n\n if (overflowFiles.length > 0) {\n this.statusMessage = {\n type: 'error',\n text: this.labelMaxFilesExceeded\n .replace('{{count}}', this.maxFiles.toString())\n .replace('{{files}}', this.pluralize(this.maxFiles))\n };\n this.ifxFileUploadMaxFilesExceeded.emit({\n maxFiles: this.maxFiles,\n attempted: this.files.length + validFiles.length\n });\n }\n\n return;\n }\n\n\n validFiles.forEach(file => this.startUpload(file));\n this.files = [...this.files, ...validFiles];\n\n if (validFiles.length > 0) {\n this.ifxFileUploadAdd.emit({ addedFiles: validFiles, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n }\n\n this.validateRequired();\n }\n\n retryUpload(file: File) {\n const taskIndex = this.uploadTasks.findIndex(t => t.file.name === file.name);\n if (taskIndex !== -1) {\n this.uploadTasks.splice(taskIndex, 1);\n this.uploadTasks = [...this.uploadTasks];\n }\n this.ifxFileUploadRetry.emit({ file });\n this.startUpload(file);\n }\n\n startUpload(file: File) {\n this.ifxFileUploadStart.emit({ file });\n\n const task: UploadTask = {\n file,\n progress: 3, // Start with initial progress for better UX\n intervalId: null,\n completed: false,\n };\n\n this.uploadTasks = [...this.uploadTasks, task];\n\n if (this.uploadHandler) {\n this.uploadHandler(file, (percent: number) => {\n if (percent > task.progress) {\n task.progress = Math.min(100, percent);\n this.uploadTasks = [...this.uploadTasks];\n }\n }).then(() => {\n task.progress = 100;\n task.completed = true;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadComplete.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n\n if (this.uploadTasks.every(t => t.completed)) {\n this.ifxFileUploadAllComplete.emit({ files: this.files });\n }\n }).catch(() => {\n task.error = true;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadError.emit({\n file,\n errorType: 'upload-failed',\n message: 'Upload handler rejected file',\n reason: 'custom'\n });\n });\n } else {\n const totalSize = file.size;\n const fakeUploadSpeed = 100000;\n let uploaded = 0;\n\n task.intervalId = window.setInterval(() => {\n uploaded += fakeUploadSpeed / 5;\n const progress = Math.min(100, Math.round((uploaded / totalSize) * 100));\n task.progress = progress;\n this.uploadTasks = [...this.uploadTasks];\n\n if (progress >= 100) {\n clearInterval(task.intervalId!);\n task.completed = true;\n task.intervalId = null;\n this.uploadTasks = [...this.uploadTasks];\n this.ifxFileUploadComplete.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n\n if (this.uploadTasks.every(t => t.completed)) {\n this.ifxFileUploadAllComplete.emit({ files: this.files });\n }\n }\n }, 200);\n }\n\n this.uploadTasks = [...this.uploadTasks, task];\n }\n\n cancelUpload(file: File) {\n const taskIndex = this.uploadTasks.findIndex(t => t.file.name === file.name);\n if (taskIndex !== -1) {\n const task = this.uploadTasks[taskIndex];\n if (task?.intervalId !== null) {\n clearInterval(task.intervalId);\n }\n this.uploadTasks = this.uploadTasks.filter((_, i) => i !== taskIndex);\n }\n this.files = this.files.filter(f => f.name !== file.name);\n this.ifxFileUploadAbort.emit({ file });\n this.ifxFileUploadChange.emit({ files: this.files });\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n this.validateRequired();\n }\n\n removeFile(file: File) {\n this.uploadTasks = this.uploadTasks.filter(task => task.file.name !== file.name);\n this.files = this.files.filter(f => f.name !== file.name);\n this.ifxFileUploadRemove.emit({ removedFile: file, files: this.files });\n this.ifxFileUploadChange.emit({ files: this.files });\n this.validateRequired();\n\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n\n if (\n this.maxFiles &&\n this.files.length < this.maxFiles &&\n this.statusMessage?.text !== this.labelRequiredError\n ) {\n this.statusMessage = null;\n }\n }\n\n\n clearRejectedFile(fileName: string, type: 'size' | 'type') {\n if (type === 'size') {\n this.rejectedSizeFiles = this.rejectedSizeFiles.filter(f => f !== fileName);\n } else {\n this.rejectedTypeFiles = this.rejectedTypeFiles.filter(f => f !== fileName);\n }\n\n if (this.fileInputEl) {\n this.fileInputEl.value = '';\n }\n\n if (this.maxFiles && this.files.length < this.maxFiles) {\n this.statusMessage = null;\n }\n\n this.validateRequired();\n }\n\n splitFileNameParts(file: File): { base: string; ext: string } {\n const name = file.name;\n const dotIndex = name.lastIndexOf('.');\n if (dotIndex === -1) return { base: name, ext: '' };\n return {\n base: name.substring(0, dotIndex),\n ext: name.substring(dotIndex)\n };\n }\n\n getFileIcon(file: File): string {\n const extension = file.name.split('.').pop()?.toLowerCase();\n switch (extension) {\n case 'pdf': return 'file-pdf-16';\n case 'jpg':\n case 'jpeg': return 'file-jpg-16';\n case 'png': return 'file-png-16';\n case 'mov': return 'file-mov-16';\n case 'mp3': return 'file-mp3-16';\n case 'mp4': return 'file-mp4-16';\n default: return 'file-16';\n }\n }\n\n formatSize(bytes: number): string {\n if (bytes >= 1024 * 1024 * 1024) {\n return `${(bytes / (1024 * 1024 * 1024)).toFixed(1)} GB`;\n } else if (bytes >= 1024 * 1024) {\n return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;\n } else if (bytes >= 1024) {\n return `${(bytes / 1024).toFixed(0)} KB`;\n } else {\n return `${bytes} B`;\n }\n }\n\n getAcceptAttribute(): string {\n const extensionTypes = this.getNormalizedFileTypes().map(ext => '.' + ext.toLowerCase());\n const mimeTypes = this.getAdditionalMimeTypes();\n\n return [...extensionTypes, ...mimeTypes].join(',');\n }\n\n private getFormattedProgressText(task: UploadTask): string {\n const uploadedSize = Math.round((task.progress / 100) * task.file.size);\n const uploadedText = this.formatSize(uploadedSize);\n const totalText = this.formatSize(task.file.size);\n return `${uploadedText} / ${totalText} uploaded`;\n }\n\n private getAdditionalMimeTypes(): string[] {\n if (!this.additionalAllowedFileTypes) return [];\n if (Array.isArray(this.additionalAllowedFileTypes)) return this.additionalAllowedFileTypes;\n return this.additionalAllowedFileTypes.split(',').map(t => t.trim());\n }\n\n private getSupportedFileText(): string {\n const extensions = this.getNormalizedFileTypes().map(ext => ext.toUpperCase());\n const mimeTypes = this.getAdditionalMimeTypes().map(mime => this.getLabelFromMimeType(mime));\n const allTypes = [...extensions, ...mimeTypes];\n const typesLabel = allTypes.join(', ');\n\n let text = this.labelSupportedFormatsTemplate\n .replace('{{types}}', typesLabel)\n .replace('{{size}}', this.maxFileSizeMB.toString());\n\n if (this.labelMaxFilesInfo && this.maxFiles) {\n const fileWord = this.pluralize(this.maxFiles);\n const maxFilesText = this.labelMaxFilesInfo\n .replace('{{count}}', this.maxFiles.toString())\n .replace('{{files}}', fileWord);\n text += ` ${maxFilesText}`;\n }\n\n return text;\n }\n\n private getFormattedFileTooLargeText(): string {\n return this.labelFileTooLarge.replace('{{size}}', this.maxFileSizeMB.toString());\n }\n\n private renderStatusMessage() {\n if (!this.statusMessage) return null;\n\n return (\n <div class={`file-upload-status file-upload-status__${this.statusMessage.type}`}>\n {this.statusMessage.type === 'error' && (\n <ifx-icon icon=\"c-warning-16\"></ifx-icon>\n )}\n {this.statusMessage.text}\n </div>\n );\n }\n\n private isInputDisabled(): boolean {\n return this.disabled || (this.maxFiles !== undefined && this.files.length >= this.maxFiles);\n }\n\n componentWillLoad() { \n if(!isNestedInIfxComponent(this.hostElement)) { \n const framework = detectFramework();\n trackComponent('ifx-file-upload', framework)\n }\n }\n\n componentDidLoad() {\n if (this.hostElement.hasAttribute('show-demo-states')) {\n this.showDemoStates = true;\n }\n\n if (this.showDemoStates) {\n this.injectDemoState();\n }\n }\n\n // Storybook Demo\n @Method()\n async injectDemoState() {\n const dummyContent = new Array(50000).fill('a').join(''); // ~50 KB\n const bigContent = dummyContent + dummyContent; // ~100 KB\n\n const uploading = new File([dummyContent], 'Image.jpg', { type: 'image/jpeg' }); // ~50 KB\n const uploaded = new File([bigContent], 'File.pdf', { type: 'application/pdf' }); // ~100 KB\n const failed = new File([dummyContent], 'Text.docx', { type: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' }); // ~50 KB\n const tooLarge = new File([bigContent + bigContent + bigContent], 'Video.mp4', { type: 'video/mp4' }); // ~300 KB\n const unsupported = new File(['demo'], 'Script.exe', { type: 'application/x-msdownload' }); // very small\n\n this.files = [uploaded, uploading, failed];\n this.uploadTasks = [\n { file: uploaded, progress: 100, intervalId: null, completed: true },\n { file: uploading, progress: 40, intervalId: null, completed: false },\n { file: failed, progress: 80, intervalId: null, completed: false, error: true }\n ];\n this.rejectedSizeFiles = [tooLarge.name];\n this.rejectedTypeFiles = [unsupported.name];\n }\n\n\n\n // Storybook Demo\n @Method()\n async triggerDemoValidation(): Promise<void> {\n this.validateRequired();\n }\n\n render() {\n return (\n <div\n class={{\n 'file-upload-wrapper': true,\n 'disabled': this.disabled\n }}\n >\n {this.label && (\n <label class=\"file-upload-label\" htmlFor={this.internalId}>\n {this.label}\n {this.required && (\n <span class={`required ${this.requiredError ? 'error' : ''}`}>*</span>\n )}\n </label>\n )}\n\n {this.dragAndDrop ? this.renderDragAndDropArea() : this.renderUploadArea()}\n\n {(this.files.length > 0 || this.rejectedSizeFiles.length > 0 || this.rejectedTypeFiles.length > 0) && (\n <div class=\"file-list-wrapper\">\n <div class=\"upload-heading\">{this.labelUploadedFilesHeading}</div>\n <ul class=\"file-list\">\n {this.rejectedSizeFiles.map(fileName => (\n <li class=\"file-item upload-failed\" key={`rejected-size-${fileName}`}>\n <div class=\"file-icon\">\n <ifx-icon icon=\"file-16\"></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{this.splitFileNameParts({ name: fileName } as File).base}</span>\n <span class=\"file-name-ext\">{this.splitFileNameParts({ name: fileName } as File).ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.clearRejectedFile(fileName, 'size')}\n ></ifx-icon-button>\n </div>\n </div>\n <div class=\"file-middle-row\">\n <span class=\"file-status\" aria-label={this.labelFileTooLarge.replace('{{size}}', this.maxFileSizeMB.toString())}>\n {this.getFormattedFileTooLargeText()}\n </span>\n </div>\n </div>\n </li>\n ))}\n\n {this.rejectedTypeFiles.map(fileName => (\n <li class=\"file-item upload-failed\" key={`rejected-type-${fileName}`}>\n <div class=\"file-icon\">\n <ifx-icon icon=\"file-16\"></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{this.splitFileNameParts({ name: fileName } as File).base}</span>\n <span class=\"file-name-ext\">{this.splitFileNameParts({ name: fileName } as File).ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.clearRejectedFile(fileName, 'type')}\n ></ifx-icon-button>\n </div>\n </div>\n <div class=\"file-middle-row\">\n <span class=\"file-status\" aria-label={this.labelUnsupportedFileType}>\n {this.labelUnsupportedFileType}\n </span>\n </div>\n </div>\n </li>\n ))}\n\n {this.files.map((file) => {\n const task = this.uploadTasks.find(t => t.file.name === file.name);\n const progress = task?.progress ?? 100;\n const isUploading = task && !task.completed;\n const isError = task?.error === true;\n const itemClass = isError ? 'file-item upload-failed' : isUploading ? 'file-item uploading' : 'file-item upload-success';\n const uniqueKey = `${file.name}-${file.size}`;\n const { base, ext } = this.splitFileNameParts(file);\n\n return (\n <li class={itemClass} key={uniqueKey}>\n <div class=\"file-icon\">\n <ifx-icon icon={this.getFileIcon(file)}></ifx-icon>\n </div>\n <div class=\"file-info\">\n <div class=\"file-top-row\">\n <span class=\"file-name-wrapper\">\n <span class=\"file-name-base\">{base}</span>\n <span class=\"file-name-ext\">{ext}</span>\n </span>\n <div class=\"file-actions\">\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"refresh-16\"\n size=\"s\"\n aria-label={this.ariaLabelRetryUpload}\n onClick={() => this.retryUpload(file)}\n style={{ display: isError ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"cross-16\"\n size=\"s\"\n aria-label={this.ariaLabelCancelUpload}\n onClick={() => this.cancelUpload(file)}\n style={{ display: isUploading ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n <ifx-icon-button\n shape=\"square\"\n variant=\"tertiary\"\n icon=\"delete-forever-16\"\n size=\"s\"\n aria-label={this.ariaLabelRemoveFile}\n onClick={() => this.removeFile(file)}\n style={{ display: !isUploading ? 'inline-flex' : 'none' }}\n ></ifx-icon-button>\n </div>\n </div>\n\n <div class=\"file-middle-row\">\n {isUploading && task && !task.error && (\n <span class=\"file-uploading\" aria-label={this.ariaLabelUploadingStatus}>\n {this.getFormattedProgressText(task)}\n </span>\n )}\n {!isUploading && !isError && (\n <span>\n <span class=\"file-size\">{this.formatSize(file.size)}</span>\n <span class=\"file-status\" aria-label={this.ariaLabelUploadedStatus}>\n <ifx-icon icon=\"check-16\"></ifx-icon>\n {this.labelUploaded}\n </span>\n </span>\n )}\n {isError && (\n <span class=\"file-status\" aria-label={this.ariaLabelUploadFailedStatus}>\n {this.labelUploadFailed}\n </span>\n )}\n </div>\n\n {isUploading && task && !task.error && (\n <div class=\"file-progress-row\">\n <ifx-progress-bar\n size=\"s\"\n value={progress}\n show-label=\"true\"\n ></ifx-progress-bar>\n </div>\n )}\n </div>\n </li>\n );\n })}\n </ul>\n </div>\n )}\n </div>\n );\n }\n\n renderUploadArea() {\n const handleInputRef = (el: HTMLInputElement | null) => {\n this.fileInputEl = el;\n };\n\n return (\n <div class={{ 'upload-button': true }}>\n <ifx-button\n variant=\"secondary\"\n onClick={() => this.fileInputEl?.click()}\n disabled={this.isInputDisabled()}\n aria-label={this.ariaLabelBrowseFiles}\n >\n <ifx-icon icon=\"upload-16\"></ifx-icon>\n {this.labelBrowseFiles}\n </ifx-button>\n <input\n id={this.internalId}\n ref={handleInputRef}\n type=\"file\"\n accept={this.getAcceptAttribute()}\n multiple\n onChange={(e) => this.handleFileChange(e)}\n style={{ display: 'none' }}\n disabled={this.isInputDisabled()}\n aria-label={this.ariaLabelFileInput}\n />\n <p class=\"file-upload-info\">\n {this.getSupportedFileText()}\n </p>\n {this.renderStatusMessage()}\n </div>\n );\n }\n\n\n renderDragAndDropArea() {\n const handleInputRef = (el: HTMLInputElement | null) => {\n this.fileInputEl = el;\n };\n\n const triggerInputClick = () => {\n if (this.fileInputEl) {\n this.fileInputEl.click();\n }\n };\n\n return (\n <div class={{ 'disabled': this.isInputDisabled() }}>\n <div\n class={{ 'upload-dropzone': true, 'drag-over': this.isDragOver, 'error': this.requiredError }}\n onClick={triggerInputClick}\n onDragOver={(e) => this.handleDragOver(e)}\n onDragLeave={(e) => this.handleDragLeave(e)}\n onDrop={(e) => this.handleDrop(e)}\n role=\"button\"\n tabIndex={0}\n aria-label={this.ariaLabelDropzone}\n >\n <ifx-icon icon=\"upload-16\" class=\"custom-icon\"></ifx-icon>\n <p>{this.labelDragAndDrop}</p>\n <p class=\"file-upload-info\">\n {this.getSupportedFileText()}\n </p>\n <div style={{ height: '0px', overflow: 'hidden' }}>\n <input\n id={this.internalId}\n ref={handleInputRef}\n type=\"file\"\n accept={this.getAcceptAttribute()}\n multiple\n onChange={(e) => this.handleFileChange(e)}\n disabled={this.isInputDisabled()}\n aria-label={this.ariaLabelFileInput}\n />\n </div>\n </div>\n {this.renderStatusMessage()}\n </div>\n );\n }\n\n}\n"],"mappings":"wIAAA,MAAMA,EAAgB,+0FACtB,MAAAC,EAAeD,E,MC0BFE,EAAU,MALvB,WAAAC,CAAAC,G,g0BAQUC,KAAAC,YAAuB,MACvBD,KAAAE,SAAoB,MACpBF,KAAAG,SAAoB,MACpBH,KAAAI,cAAwB,EAExBJ,KAAAK,iBAAsC,CAAC,MAAO,OAAQ,MAAO,MAAO,MAAO,MAAO,OAClFL,KAAAM,2BAAiD,GAiBjDN,KAAAO,MAAgB,QAChBP,KAAAQ,mBAA6B,qCAC7BR,KAAAS,iBAA2B,eAC3BT,KAAAU,iBAA2B,wCAC3BV,KAAAW,0BAAoC,iBACpCX,KAAAY,kBAA4B,4CAC5BZ,KAAAa,yBAAmC,yBACnCb,KAAAc,cAAwB,wBACxBd,K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I,MAASlL,KAAKwC,eAC9EqN,QAASiB,EACTC,WAAaF,GAAM7Q,KAAKoI,eAAeyI,GACvCG,YAAcH,GAAM7Q,KAAKqI,gBAAgBwI,GACzCI,OAASJ,GAAM7Q,KAAK+G,WAAW8J,GAC/BK,KAAK,SACLC,SAAU,EAAC,aACCnR,KAAKsB,mBAEjByM,EAAA,YAAUE,KAAK,YAAYD,MAAM,gBACjCD,EAAA,SAAI/N,KAAKU,kBACTqN,EAAA,KAAGC,MAAM,oBACNhO,KAAKuN,wBAERQ,EAAA,OAAKoC,MAAO,CAAEiB,OAAQ,MAAOC,SAAU,WACrCtD,EAAA,SACEyC,GAAIxQ,KAAK8B,WACT2O,IAAKJ,EACLlL,KAAK,OACLuL,OAAQ1Q,KAAK+M,qBACb4D,SAAQ,KACRC,SAAWC,GAAM7Q,KAAK0G,iBAAiBmK,GACvC1Q,SAAUH,KAAKkO,kBAAiB,aACpBlO,KAAKuB,uBAItBvB,KAAK8N,sB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as e,h as i,g as t}from"./p-b7a462e5.js";import{d as n,t as l}from"./p-1de6e751.js";import{i as o}from"./p-1ecafb97.js";import{c as r}from"./p-5cdc6210.js";const s=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}:host{display:inline-flex}.link{display:inline-flex;align-items:center;font-weight:400;font-size:1rem;text-decoration:none;color:#0A8276;gap:8px;line-height:1.6;font-family:var(--ifx-font-family)}.link:hover{cursor:pointer}.link:focus{outline-width:2px;outline-style:solid;outline-color:#0A8276;outline-offset:4px;border-radius:3px}.link.bold{font-weight:600}.link.bold:hover{text-decoration:underline}.link.bold:active{color:#08665C;font-style:normal;font-weight:600;text-decoration:underline}.link.underlined{text-decoration:underline;text-decoration-color:#0A8276;color:#1D1D1D;text-underline-offset:8px}.link.underlined:hover{color:#0A8276}.link.underlined:active{color:#0A8276}.link.underlined:disabled,.link.underlined.disabled{text-decoration-color:#BFBBBB}.link.title{text-decoration:none;font-weight:600;color:#1D1D1D}.link.title:hover{color:#0A8276}.link.title:active{color:#08665C}.link.menu{font-weight:400;font-style:normal;line-height:26px;color:#1D1D1D}.link.menu:hover{color:#0A8276}.link.menu:active{color:#08665C}.link.small{font-size:0.875rem}.link.medium{font-size:1rem}.link.large{font-size:1.125rem}.link.extraLarge{font-size:1.25rem}.link.underline{text-decoration:underline}.link:disabled,.link.disabled{color:#BFBBBB;cursor:default;pointer-events:none}';const a=s;const d=class{constructor(i){e(this,i);this.href=undefined;this.target="_self";this.variant="bold";this.disabled=false;this.internalHref="";this.internalTarget="";this.internalVariant=""}setInternalStates(){if(this.href){this.internalHref=this.href.trim()}else{this.internalHref=undefined}this.internalTarget=this.target.trim();this.internalVariant=this.variant.trim().toLowerCase()}componentWillRender(){this.setInternalStates()}handleKeyDown(e){if(this.disabled){e.preventDefault()}else if(e.key==="Enter"){e.preventDefault()}}componentWillLoad(){if(!o(this.el)){const e=n();l("ifx-link",{framework:e})}}render(){return i("a",{key:"ae3f167fd745c5dca89096d1797c9524974a1e2e",role:"link","aria-label":this.ariaLabel,"aria-disabled":this.disabled||!this.internalHref,href:this.disabled?undefined:this.internalHref,download:this.download,target:this.internalTarget,class:this.linkClassNames()},i("slot",{key:"2f6673cd24334beb36a1bff5c875ced5a469ca66"}))}getSizeClass(){const e=this.size==="s"?"small":null;const i=this.size==="m"?"medium":null;const t=this.size==="l"?"large":null;const n=this.size==="xl"?"extraLarge":null;if(e){return e}else if(i){return i}else if(t){return t}else if(n&&this.internalVariant==="underlined"){return"large"}else if(n&&this.internalVariant!=="underlined"){return n}else return""}getVariantClass(){const e=this.internalVariant==="bold"?"bold":null;const i=this.internalVariant==="title"?"title":null;const t=this.internalVariant==="underlined"?"underlined":null;const n=this.internalVariant==="menu"?"menu":null;if(e){return e}else if(i){return i}else if(t){return t}else if(n){return n}else return e}linkClassNames(){return r("link","primary",this.getVariantClass(),this.getSizeClass(),this.disabled?"disabled":"")}get el(){return t(this)}};d.style=a;export{d as ifx_link};
2
- //# sourceMappingURL=p-1b08aa70.entry.js.map
1
+ import{r as e,h as i,g as t}from"./p-b7a462e5.js";import{d as n,t as l}from"./p-e48e9f36.js";import{i as o}from"./p-1ecafb97.js";import{c as r}from"./p-5cdc6210.js";const s=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}:host{display:inline-flex}.link{display:inline-flex;align-items:center;font-weight:400;font-size:1rem;text-decoration:none;color:#0A8276;gap:8px;line-height:1.6;font-family:var(--ifx-font-family)}.link:hover{cursor:pointer}.link:focus{outline-width:2px;outline-style:solid;outline-color:#0A8276;outline-offset:4px;border-radius:3px}.link.bold{font-weight:600}.link.bold:hover{text-decoration:underline}.link.bold:active{color:#08665C;font-style:normal;font-weight:600;text-decoration:underline}.link.underlined{text-decoration:underline;text-decoration-color:#0A8276;color:#1D1D1D;text-underline-offset:8px}.link.underlined:hover{color:#0A8276}.link.underlined:active{color:#0A8276}.link.underlined:disabled,.link.underlined.disabled{text-decoration-color:#BFBBBB}.link.title{text-decoration:none;font-weight:600;color:#1D1D1D}.link.title:hover{color:#0A8276}.link.title:active{color:#08665C}.link.menu{font-weight:400;font-style:normal;line-height:26px;color:#1D1D1D}.link.menu:hover{color:#0A8276}.link.menu:active{color:#08665C}.link.small{font-size:0.875rem}.link.medium{font-size:1rem}.link.large{font-size:1.125rem}.link.extraLarge{font-size:1.25rem}.link.underline{text-decoration:underline}.link:disabled,.link.disabled{color:#BFBBBB;cursor:default;pointer-events:none}';const a=s;const d=class{constructor(i){e(this,i);this.href=undefined;this.target="_self";this.variant="bold";this.disabled=false;this.internalHref="";this.internalTarget="";this.internalVariant=""}setInternalStates(){if(this.href){this.internalHref=this.href.trim()}else{this.internalHref=undefined}this.internalTarget=this.target.trim();this.internalVariant=this.variant.trim().toLowerCase()}componentWillRender(){this.setInternalStates()}handleKeyDown(e){if(this.disabled){e.preventDefault()}else if(e.key==="Enter"){e.preventDefault()}}componentWillLoad(){if(!o(this.el)){const e=n();l("ifx-link",e)}}render(){return i("a",{key:"50e6c71c8bea66f21bb620ddf7b9543b4d1b3b1e",role:"link","aria-label":this.ariaLabel,"aria-disabled":this.disabled||!this.internalHref,href:this.disabled?undefined:this.internalHref,download:this.download,target:this.internalTarget,class:this.linkClassNames()},i("slot",{key:"aa6e0c7c70dfcf03abb6233afe29591703e34ebd"}))}getSizeClass(){const e=this.size==="s"?"small":null;const i=this.size==="m"?"medium":null;const t=this.size==="l"?"large":null;const n=this.size==="xl"?"extraLarge":null;if(e){return e}else if(i){return i}else if(t){return t}else if(n&&this.internalVariant==="underlined"){return"large"}else if(n&&this.internalVariant!=="underlined"){return n}else return""}getVariantClass(){const e=this.internalVariant==="bold"?"bold":null;const i=this.internalVariant==="title"?"title":null;const t=this.internalVariant==="underlined"?"underlined":null;const n=this.internalVariant==="menu"?"menu":null;if(e){return e}else if(i){return i}else if(t){return t}else if(n){return n}else return e}linkClassNames(){return r("link","primary",this.getVariantClass(),this.getSizeClass(),this.disabled?"disabled":"")}get el(){return t(this)}};d.style=a;export{d as ifx_link};
2
+ //# sourceMappingURL=p-d827e5fc.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["linkCss","IfxLinkStyle0","Link","constructor","hostRef","this","href","undefined","target","variant","disabled","internalHref","internalTarget","internalVariant","setInternalStates","trim","toLowerCase","componentWillRender","handleKeyDown","event","preventDefault","key","componentWillLoad","isNestedInIfxComponent","el","framework","detectFramework","trackComponent","render","h","role","ariaLabel","download","class","linkClassNames","getSizeClass","small","size","medium","large","extraLarge","getVariantClass","bold","title","underlined","menu","classNames"],"sources":["src/components/link/link.scss?tag=ifx-link&encapsulation=shadow","src/components/link/link.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n:host {\n display: inline-flex;\n}\n\n.link {\n display: inline-flex;\n align-items: center;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeM;\n text-decoration: none;\n color: tokens.$ifxColorOcean500;\n gap: tokens.$ifxSpace100;\n line-height: 1.6;\n font-family: var(--ifx-font-family); // tokens.$ifxFontFamilyBody;\n\n\n\n &:hover { \n cursor: pointer;\n }\n\n &:focus {\n outline-width: 2px;\n outline-style: solid;\n outline-color: #0A8276;\n outline-offset: 4px;\n border-radius: 3px;\n }\n\n &.bold {\n font-weight: tokens.$ifxFontWeightSemibold;\n\n &:hover {\n text-decoration: underline;\n }\n\n &:active {\n color: #08665C;\n font-style: normal;\n font-weight: 600;\n text-decoration: underline;\n }\n\n }\n\n &.underlined {\n text-decoration: underline;\n text-decoration-color: tokens.$ifxColorOcean500;\n color: #1D1D1D;\n text-underline-offset: 8px;\n \n &:hover {\n color: tokens.$ifxColorOcean500;;\n }\n \n &:active {\n color: #0A8276;\n }\n\n &:disabled,\n &.disabled {\n text-decoration-color: tokens.$ifxColorEngineering300;\n }\n }\n\n &.title {\n text-decoration: none;\n font-weight: tokens.$ifxFontWeightSemibold;\n color: #1D1D1D;\n\n &:hover {\n color: tokens.$ifxColorOcean500;\n }\n\n &:active {\n color: #08665C;\n }\n }\n\n &.menu {\n font-weight: 400;\n font-style: normal;\n line-height: 26px;\n color: #1D1D1D;\n\n &:hover {\n color: tokens.$ifxColorOcean500;\n }\n\n &:active {\n color: #08665C;\n }\n }\n\n &.small {\n font-size: tokens.$ifxFontSizeS;\n }\n\n &.medium {\n font-size: tokens.$ifxFontSizeM;\n }\n\n &.large {\n font-size: tokens.$ifxFontSizeL;\n }\n\n &.extraLarge {\n font-size: tokens.$ifxFontSizeXl;\n }\n\n &.underline {\n text-decoration: underline;\n }\n\n &:disabled,\n &.disabled {\n color: tokens.$ifxColorEngineering300;\n cursor: default;\n pointer-events: none;\n }\n\n}","import { Component, Prop, h, State, Element } from \"@stencil/core\";\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\nimport classNames from 'classnames';\n \n@Component({\n tag: 'ifx-link',\n styleUrl: 'link.scss',\n shadow: true\n})\n\nexport class Link {\n @Element() el;\n @Prop() href: string = undefined;\n @Prop() target: string = '_self';\n @Prop() variant: string = 'bold';\n @Prop() size: string;\n @Prop() disabled: boolean = false;\n @Prop() download: string;\n @Prop() ariaLabel: string | null;\n @State() internalHref: string ='';\n @State() internalTarget: string = '';\n @State() internalVariant: string = '';\n\n setInternalStates() {\n if(this.href){\n this.internalHref = this.href.trim();\n }else{\n this.internalHref = undefined;\n }\n this.internalTarget = this.target.trim();\n this.internalVariant = this.variant.trim().toLowerCase();\n }\n\n componentWillRender(){\n this.setInternalStates();\n }\n\n handleKeyDown(event: KeyboardEvent) {\n if (this.disabled) {\n event.preventDefault();\n } else if (event.key === 'Enter') {\n event.preventDefault();\n }\n }\n\n componentWillLoad() { \n if(!isNestedInIfxComponent(this.el)) { \n const framework = detectFramework();\n trackComponent('ifx-link', { framework })\n }\n }\n\n render() {\n return (\n <a\n role=\"link\"\n aria-label={this.ariaLabel}\n aria-disabled={this.disabled || !this.internalHref}\n href={this.disabled ? undefined : this.internalHref}\n download={this.download}\n target={this.internalTarget}\n class={this.linkClassNames()}>\n <slot></slot>\n </a>)\n }\n\n getSizeClass() {\n const small = this.size === 's' ? 'small' : null;\n const medium = this.size === 'm' ? 'medium' : null;\n const large = this.size === 'l' ? 'large' : null;\n const extraLarge = this.size === 'xl' ? 'extraLarge' : null;\n\n if (small) {\n return small;\n } else if (medium) {\n return medium;\n } else if (large) {\n return large;\n } else if (extraLarge && this.internalVariant === 'underlined') {\n return 'large';\n } else if (extraLarge && this.internalVariant !== 'underlined') {\n return extraLarge;\n } else return \"\";\n }\n\n getVariantClass() {\n const bold = this.internalVariant === 'bold' ? 'bold' : null;\n const title = this.internalVariant === 'title' ? 'title' : null;\n const underlined = this.internalVariant === 'underlined' ? 'underlined' : null;\n const menu = this.internalVariant === 'menu' ? 'menu' : null;\n\n if (bold) {\n return bold\n } else if (title) {\n return title;\n } else if (underlined) {\n return underlined;\n } else if (menu) {\n return menu;\n } else return bold;\n }\n\n linkClassNames() {\n return classNames(\n 'link',\n 'primary',\n this.getVariantClass(),\n this.getSizeClass(),\n this.disabled ? 'disabled' : '',\n );\n }\n}"],"mappings":"qKAAA,MAAMA,EAAU,6zCAChB,MAAAC,EAAeD,E,MCWFE,EAAI,MANjB,WAAAC,CAAAC,G,UAQUC,KAAAC,KAAeC,UACfF,KAAAG,OAAiB,QACjBH,KAAAI,QAAkB,OAElBJ,KAAAK,SAAoB,MAGnBL,KAAAM,aAAsB,GACtBN,KAAAO,eAAyB,GACzBP,KAAAQ,gBAA0B,E,CAEnC,iBAAAC,GACE,GAAGT,KAAKC,KAAK,CACXD,KAAKM,aAAeN,KAAKC,KAAKS,M,KAC3B,CACHV,KAAKM,aAAeJ,S,CAEtBF,KAAKO,eAAiBP,KAAKG,OAAOO,OAClCV,KAAKQ,gBAAkBR,KAAKI,QAAQM,OAAOC,a,CAG7C,mBAAAC,GACEZ,KAAKS,mB,CAGP,aAAAI,CAAcC,GACZ,GAAId,KAAKK,SAAU,CACjBS,EAAMC,gB,MACD,GAAID,EAAME,MAAQ,QAAS,CAChCF,EAAMC,gB,EAIV,iBAAAE,GACE,IAAIC,EAAuBlB,KAAKmB,IAAK,CACnC,MAAMC,EAAYC,IAClBC,EAAe,WAAY,CAAEF,a,EAIjC,MAAAG,GACE,OACEC,EAAA,KAAAR,IAAA,2CACES,KAAK,OAAM,aACCzB,KAAK0B,UAAS,gBACX1B,KAAKK,WAAaL,KAAKM,aACtCL,KAAMD,KAAKK,SAAWH,UAAYF,KAAKM,aACvCqB,SAAU3B,KAAK2B,SACfxB,OAAQH,KAAKO,eACbqB,MAAO5B,KAAK6B,kBACZL,EAAA,QAAAR,IAAA,6C,CAIN,YAAAc,GACE,MAAMC,EAAQ/B,KAAKgC,OAAS,IAAM,QAAU,KAC5C,MAAMC,EAASjC,KAAKgC,OAAS,IAAM,SAAW,KAC9C,MAAME,EAAQlC,KAAKgC,OAAS,IAAM,QAAU,KAC5C,MAAMG,EAAanC,KAAKgC,OAAS,KAAO,aAAe,KAEvD,GAAID,EAAO,CACT,OAAOA,C,MACF,GAAIE,EAAQ,CACjB,OAAOA,C,MACF,GAAIC,EAAO,CAChB,OAAOA,C,MACF,GAAIC,GAAcnC,KAAKQ,kBAAoB,aAAc,CAC9D,MAAO,O,MACF,GAAI2B,GAAcnC,KAAKQ,kBAAoB,aAAc,CAC9D,OAAO2B,C,MACF,MAAO,E,CAGhB,eAAAC,GACE,MAAMC,EAAOrC,KAAKQ,kBAAoB,OAAS,OAAS,KACxD,MAAM8B,EAAQtC,KAAKQ,kBAAoB,QAAU,QAAU,KAC3D,MAAM+B,EAAavC,KAAKQ,kBAAoB,aAAe,aAAe,KAC1E,MAAMgC,EAAOxC,KAAKQ,kBAAoB,OAAS,OAAS,KAExD,GAAI6B,EAAM,CACR,OAAOA,C,MACF,GAAIC,EAAO,CAChB,OAAOA,C,MACF,GAAIC,EAAY,CACrB,OAAOA,C,MACF,GAAIC,EAAM,CACf,OAAOA,C,MACF,OAAOH,C,CAGhB,cAAAR,GACE,OAAOY,EACL,OACA,UACAzC,KAAKoC,kBACLpC,KAAK8B,eACL9B,KAAKK,SAAW,WAAa,G","ignoreList":[]}
1
+ {"version":3,"names":["linkCss","IfxLinkStyle0","Link","constructor","hostRef","this","href","undefined","target","variant","disabled","internalHref","internalTarget","internalVariant","setInternalStates","trim","toLowerCase","componentWillRender","handleKeyDown","event","preventDefault","key","componentWillLoad","isNestedInIfxComponent","el","framework","detectFramework","trackComponent","render","h","role","ariaLabel","download","class","linkClassNames","getSizeClass","small","size","medium","large","extraLarge","getVariantClass","bold","title","underlined","menu","classNames"],"sources":["src/components/link/link.scss?tag=ifx-link&encapsulation=shadow","src/components/link/link.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n:host {\n display: inline-flex;\n}\n\n.link {\n display: inline-flex;\n align-items: center;\n font-weight: 400;\n font-size: tokens.$ifxFontSizeM;\n text-decoration: none;\n color: tokens.$ifxColorOcean500;\n gap: tokens.$ifxSpace100;\n line-height: 1.6;\n font-family: var(--ifx-font-family); // tokens.$ifxFontFamilyBody;\n\n\n\n &:hover { \n cursor: pointer;\n }\n\n &:focus {\n outline-width: 2px;\n outline-style: solid;\n outline-color: #0A8276;\n outline-offset: 4px;\n border-radius: 3px;\n }\n\n &.bold {\n font-weight: tokens.$ifxFontWeightSemibold;\n\n &:hover {\n text-decoration: underline;\n }\n\n &:active {\n color: #08665C;\n font-style: normal;\n font-weight: 600;\n text-decoration: underline;\n }\n\n }\n\n &.underlined {\n text-decoration: underline;\n text-decoration-color: tokens.$ifxColorOcean500;\n color: #1D1D1D;\n text-underline-offset: 8px;\n \n &:hover {\n color: tokens.$ifxColorOcean500;;\n }\n \n &:active {\n color: #0A8276;\n }\n\n &:disabled,\n &.disabled {\n text-decoration-color: tokens.$ifxColorEngineering300;\n }\n }\n\n &.title {\n text-decoration: none;\n font-weight: tokens.$ifxFontWeightSemibold;\n color: #1D1D1D;\n\n &:hover {\n color: tokens.$ifxColorOcean500;\n }\n\n &:active {\n color: #08665C;\n }\n }\n\n &.menu {\n font-weight: 400;\n font-style: normal;\n line-height: 26px;\n color: #1D1D1D;\n\n &:hover {\n color: tokens.$ifxColorOcean500;\n }\n\n &:active {\n color: #08665C;\n }\n }\n\n &.small {\n font-size: tokens.$ifxFontSizeS;\n }\n\n &.medium {\n font-size: tokens.$ifxFontSizeM;\n }\n\n &.large {\n font-size: tokens.$ifxFontSizeL;\n }\n\n &.extraLarge {\n font-size: tokens.$ifxFontSizeXl;\n }\n\n &.underline {\n text-decoration: underline;\n }\n\n &:disabled,\n &.disabled {\n color: tokens.$ifxColorEngineering300;\n cursor: default;\n pointer-events: none;\n }\n\n}","import { Component, Prop, h, State, Element } from \"@stencil/core\";\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\nimport classNames from 'classnames';\n \n@Component({\n tag: 'ifx-link',\n styleUrl: 'link.scss',\n shadow: true\n})\n\nexport class Link {\n @Element() el;\n @Prop() href: string = undefined;\n @Prop() target: string = '_self';\n @Prop() variant: string = 'bold';\n @Prop() size: string;\n @Prop() disabled: boolean = false;\n @Prop() download: string;\n @Prop() ariaLabel: string | null;\n @State() internalHref: string ='';\n @State() internalTarget: string = '';\n @State() internalVariant: string = '';\n\n setInternalStates() {\n if(this.href){\n this.internalHref = this.href.trim();\n }else{\n this.internalHref = undefined;\n }\n this.internalTarget = this.target.trim();\n this.internalVariant = this.variant.trim().toLowerCase();\n }\n\n componentWillRender(){\n this.setInternalStates();\n }\n\n handleKeyDown(event: KeyboardEvent) {\n if (this.disabled) {\n event.preventDefault();\n } else if (event.key === 'Enter') {\n event.preventDefault();\n }\n }\n\n componentWillLoad() { \n if(!isNestedInIfxComponent(this.el)) { \n const framework = detectFramework();\n trackComponent('ifx-link', framework)\n }\n }\n\n render() {\n return (\n <a\n role=\"link\"\n aria-label={this.ariaLabel}\n aria-disabled={this.disabled || !this.internalHref}\n href={this.disabled ? undefined : this.internalHref}\n download={this.download}\n target={this.internalTarget}\n class={this.linkClassNames()}>\n <slot></slot>\n </a>)\n }\n\n getSizeClass() {\n const small = this.size === 's' ? 'small' : null;\n const medium = this.size === 'm' ? 'medium' : null;\n const large = this.size === 'l' ? 'large' : null;\n const extraLarge = this.size === 'xl' ? 'extraLarge' : null;\n\n if (small) {\n return small;\n } else if (medium) {\n return medium;\n } else if (large) {\n return large;\n } else if (extraLarge && this.internalVariant === 'underlined') {\n return 'large';\n } else if (extraLarge && this.internalVariant !== 'underlined') {\n return extraLarge;\n } else return \"\";\n }\n\n getVariantClass() {\n const bold = this.internalVariant === 'bold' ? 'bold' : null;\n const title = this.internalVariant === 'title' ? 'title' : null;\n const underlined = this.internalVariant === 'underlined' ? 'underlined' : null;\n const menu = this.internalVariant === 'menu' ? 'menu' : null;\n\n if (bold) {\n return bold\n } else if (title) {\n return title;\n } else if (underlined) {\n return underlined;\n } else if (menu) {\n return menu;\n } else return bold;\n }\n\n linkClassNames() {\n return classNames(\n 'link',\n 'primary',\n this.getVariantClass(),\n this.getSizeClass(),\n this.disabled ? 'disabled' : '',\n );\n }\n}"],"mappings":"qKAAA,MAAMA,EAAU,6zCAChB,MAAAC,EAAeD,E,MCWFE,EAAI,MANjB,WAAAC,CAAAC,G,UAQUC,KAAAC,KAAeC,UACfF,KAAAG,OAAiB,QACjBH,KAAAI,QAAkB,OAElBJ,KAAAK,SAAoB,MAGnBL,KAAAM,aAAsB,GACtBN,KAAAO,eAAyB,GACzBP,KAAAQ,gBAA0B,E,CAEnC,iBAAAC,GACE,GAAGT,KAAKC,KAAK,CACXD,KAAKM,aAAeN,KAAKC,KAAKS,M,KAC3B,CACHV,KAAKM,aAAeJ,S,CAEtBF,KAAKO,eAAiBP,KAAKG,OAAOO,OAClCV,KAAKQ,gBAAkBR,KAAKI,QAAQM,OAAOC,a,CAG7C,mBAAAC,GACEZ,KAAKS,mB,CAGP,aAAAI,CAAcC,GACZ,GAAId,KAAKK,SAAU,CACjBS,EAAMC,gB,MACD,GAAID,EAAME,MAAQ,QAAS,CAChCF,EAAMC,gB,EAIV,iBAAAE,GACE,IAAIC,EAAuBlB,KAAKmB,IAAK,CACnC,MAAMC,EAAYC,IAClBC,EAAe,WAAYF,E,EAI/B,MAAAG,GACE,OACEC,EAAA,KAAAR,IAAA,2CACES,KAAK,OAAM,aACCzB,KAAK0B,UAAS,gBACX1B,KAAKK,WAAaL,KAAKM,aACtCL,KAAMD,KAAKK,SAAWH,UAAYF,KAAKM,aACvCqB,SAAU3B,KAAK2B,SACfxB,OAAQH,KAAKO,eACbqB,MAAO5B,KAAK6B,kBACZL,EAAA,QAAAR,IAAA,6C,CAIN,YAAAc,GACE,MAAMC,EAAQ/B,KAAKgC,OAAS,IAAM,QAAU,KAC5C,MAAMC,EAASjC,KAAKgC,OAAS,IAAM,SAAW,KAC9C,MAAME,EAAQlC,KAAKgC,OAAS,IAAM,QAAU,KAC5C,MAAMG,EAAanC,KAAKgC,OAAS,KAAO,aAAe,KAEvD,GAAID,EAAO,CACT,OAAOA,C,MACF,GAAIE,EAAQ,CACjB,OAAOA,C,MACF,GAAIC,EAAO,CAChB,OAAOA,C,MACF,GAAIC,GAAcnC,KAAKQ,kBAAoB,aAAc,CAC9D,MAAO,O,MACF,GAAI2B,GAAcnC,KAAKQ,kBAAoB,aAAc,CAC9D,OAAO2B,C,MACF,MAAO,E,CAGhB,eAAAC,GACE,MAAMC,EAAOrC,KAAKQ,kBAAoB,OAAS,OAAS,KACxD,MAAM8B,EAAQtC,KAAKQ,kBAAoB,QAAU,QAAU,KAC3D,MAAM+B,EAAavC,KAAKQ,kBAAoB,aAAe,aAAe,KAC1E,MAAMgC,EAAOxC,KAAKQ,kBAAoB,OAAS,OAAS,KAExD,GAAI6B,EAAM,CACR,OAAOA,C,MACF,GAAIC,EAAO,CAChB,OAAOA,C,MACF,GAAIC,EAAY,CACrB,OAAOA,C,MACF,GAAIC,EAAM,CACf,OAAOA,C,MACF,OAAOH,C,CAGhB,cAAAR,GACE,OAAOY,EACL,OACA,UACAzC,KAAKoC,kBACLpC,KAAK8B,eACL9B,KAAKK,SAAW,WAAa,G","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as t,h as o,g as i}from"./p-b7a462e5.js";import{d as e,t as s}from"./p-1de6e751.js";import{i as a}from"./p-1ecafb97.js";import{c as l}from"./p-e459974a.js";const d=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}:host{display:inline-flex}.tooltip__container{display:inline-flex;flex-direction:column;position:relative;font-family:var(--ifx-font-family)}.tooltip-extended,.tooltip-compact,.tooltip-dismissible{background-color:#1D1D1D;border:1px solid black;z-index:1080;display:none;transition:opacity 0.3s;position:absolute;font-size:14px;font-style:normal;font-weight:400;line-height:20px;color:#FFFFFF;width:max-content;box-sizing:border-box;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere;}.visible.tooltip-extended,.visible.tooltip-compact,.visible.tooltip-dismissible{display:flex !important;align-items:start}.tooltip-dismissible .close-button{all:unset;cursor:pointer;position:relative;order:2;margin-top:12px;margin-right:12px;line-height:0px}.tooltip-dismissible .tooltip-dismissible-content{display:flex;flex-direction:column;gap:12px;padding:12px;flex-grow:1;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere}.tooltip-dismissible .tooltip-dismissible-header,.tooltip-dismissible .tooltip-dismissible-body{font-size:14px;font-style:normal;line-height:20px}.tooltip-dismissible .tooltip-dismissible-header{font-weight:600}.tooltip-dismissible .tooltip-dismissible-body{font-weight:400}.tooltip-compact{padding:4px 8px;text-align:center;flex-grow:1}.tooltip-extended{align-items:center;padding:12px;gap:10px}.tooltip-extended .extended_icon{display:flex;align-self:flex-start;align-items:center;cursor:pointer}.tooltip-extended .tooltip-extended-content{display:flex;flex-direction:column;gap:12px;flex-grow:1;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere}.tooltip-extended .tooltip-extended-header,.tooltip-extended .tooltip-extended-body{font-size:14px;font-style:normal;line-height:20px}.tooltip-extended .tooltip-extended-header{font-weight:600}.tooltip-extended .tooltip-extended-body{font-weight:400}.tooltip__container .tooltip-arrow-svg{position:absolute;width:8px;height:8px}[data-placement=top].tooltip-extended>.tooltip-arrow-svg,[data-placement=top].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;left:50%;transform:rotate(180deg) translateX(-50%)}[data-placement=top-start].tooltip-extended>.tooltip-arrow-svg,[data-placement=top-start].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top-start].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;left:10px;transform:rotate(180deg)}[data-placement=top-end].tooltip-extended>.tooltip-arrow-svg,[data-placement=top-end].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top-end].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;right:10px;transform:rotate(180deg)}[data-placement=bottom].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom].tooltip-compact>.tooltip-arrow-svg{top:-7px;left:50%;transform:translateX(-50%)}[data-placement=bottom-start].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom-start].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom-start].tooltip-compact>.tooltip-arrow-svg{top:-7px;left:10px}[data-placement=bottom-end].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom-end].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom-end].tooltip-compact>.tooltip-arrow-svg{top:-7px;right:10px}[data-placement=left].tooltip-extended>.tooltip-arrow-svg,[data-placement=left].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=left].tooltip-compact>.tooltip-arrow-svg{right:-3px;top:50%;transform:rotate(90deg) translateY(-50%) translateX(-50%)}[data-placement=right].tooltip-extended>.tooltip-arrow-svg,[data-placement=right].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=right].tooltip-compact>.tooltip-arrow-svg{left:-3px;top:50%;transform:rotate(270deg) translateY(-50%) translateX(50%)}.tooltip-compact{min-width:28px !important;max-width:145px !important}.tooltip-dismissible{min-width:145px !important;max-width:310px !important}.tooltip-extended{min-width:145px !important;max-width:310px !important}';const p=d;const n=class{constructor(o){t(this,o);this.tooltipVisible=false;this.header="";this.text="";this.position="auto";this.internalPosition="auto";this.variant="compact";this.popperInstance=null;this.onMouseEnter=()=>{var t,o;(t=this.popperInstance)===null||t===void 0?void 0:t.setOptions((t=>Object.assign(Object.assign({},t),{modifiers:[...t.modifiers,{name:"eventListeners",enabled:true}]})));this.initializePopper();this.tooltipVisible=true;this.tooltipEl.style.display="block";(o=this.popperInstance)===null||o===void 0?void 0:o.update()};this.onMouseLeave=()=>{this.tooltipVisible=false;this.tooltipEl.style.display="none"};this.onClick=()=>{var t;if(this.variant.toLowerCase()==="dismissible"){this.initializePopper();this.tooltipVisible=!this.tooltipVisible;this.tooltipEl.style.display=this.tooltipVisible?"block":"none";(t=this.popperInstance)===null||t===void 0?void 0:t.update()}};this.onDismissClick=()=>{this.tooltipVisible=false;this.tooltipEl.style.display="none"}}componentWillLoad(){if(!a(this.el)){const t=e();s("ifx-tooltip",{framework:t})}if(this.variant.toLowerCase().trim()===""){this.variant="compact"}}componentDidLoad(){const t=this.el.shadowRoot.querySelector(".tooltip__container").firstChild;if(this.variant.toLowerCase()==="compact"||this.variant.toLowerCase()==="extended"){t.addEventListener("mouseenter",this.onMouseEnter);t.addEventListener("mouseleave",this.onMouseLeave)}else{t.addEventListener("click",this.onClick)}}initializePopper(){if(this.popperInstance)return;this.referenceEl=this.el;if(this.variant.toLowerCase()==="compact"){this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-compact")}else if(this.variant.toLowerCase()==="dismissible"){this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-dismissible")}else{this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-extended")}const t=this.position==="auto"?this.determineBestPosition():this.position;this.internalPosition=t;if(this.tooltipEl&&this.referenceEl){this.popperInstance=l(this.referenceEl,this.tooltipEl,{placement:this.internalPosition,modifiers:[{name:"offset",options:{offset:[0,8]}},{name:"arrow",options:{element:".tooltip-arrow-svg"}}]})}this.tooltipEl.setAttribute("data-placement",t)}determineBestPosition(){const t=this.referenceEl.getBoundingClientRect();const o=window.scrollY;const i=window.scrollX;const e=t.top+o+t.height/2;const s=t.left+i+t.width/2;if(this.position==="auto"){if(e>window.innerHeight/2){if(s>window.innerWidth/2){return"top-end"}else{return"top-start"}}else{if(s>window.innerWidth/2){return"bottom-end"}else{return"bottom-start"}}}else{return this.position}}positionChanged(t){var o;this.internalPosition=t;(o=this.popperInstance)===null||o===void 0?void 0:o.destroy();this.popperInstance=null}disconnectedCallback(){var t;(t=this.popperInstance)===null||t===void 0?void 0:t.destroy()}render(){const t={"tooltip-dismissible":true,visible:this.tooltipVisible};const i={"tooltip-compact":true,visible:this.tooltipVisible};const e={"tooltip-extended":true,visible:this.tooltipVisible};return o("div",{key:"548d5bb1bbae1502354e95e0d12e0e46b81ad0d7","aria-label":"a tooltip showing important information","aria-value":this.header,class:"tooltip__container"},o("slot",{key:"a4428f551c6b12e6de9af66ceb0c10897c7277bc"}),this.variant.toLowerCase()==="dismissible"&&o("div",{key:"fc1eee7841b07a9b82c21d278d24a95f726ae8ac",class:t},o("button",{key:"0f732d85ba3a7f23fd8e4924b7dcd71955aafda4","aria-label":"Close Tooltip",class:"close-button",onClick:this.onDismissClick},o("ifx-icon",{key:"bb475ac7fb7772ebaeab9a69dda7686c6a0817d6",icon:"cross16"})),o("div",{key:"fff353c721d41376e4e98b140e78e7e8fab439ea",class:"tooltip-dismissible-content"},this.header&&o("div",{key:"d649b77edf879b5bd66d9b629044612139c5d79f",class:"tooltip-dismissible-header"},this.header),o("div",{key:"8c920bdad461f7d505ba7b8af7edae163159c556",class:"tooltip-dismissible-body"},this.text)),o("svg",{key:"1b5f9bf5eab288ed09d789b5038a3b09da97021b",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"7a0b80def7176b595bd5907b5e7a7b881e90a7d8",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))),this.variant.toLowerCase()==="compact"&&o("div",{key:"e0a61077eeacd753e68b4752fe3c37ec9aad4f78",class:i},this.text,o("svg",{key:"cb0a0af0055b219b520f0a0eb250ed235ce8aa87",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"d4b260869cc0c8211484eb25d9f57ad342a68978",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))),this.variant.toLowerCase()==="extended"&&o("div",{key:"7879f9a7c500273eacf9bde9f6294ce5afdbe033",class:e},o("slot",{key:"f2daac352ef7614e15117e5f4453fa3070a04ccd",name:"icon"},this.icon?o("div",{class:"extended_icon"},o("ifx-icon",{icon:this.icon})):o("svg",{class:"extended_icon",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24"},o("path",{stroke:"#fff","stroke-linecap":"round","stroke-linejoin":"round",d:"M20.5 2.5h-16a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-16a2 2 0 0 0-2-2Z"}),o("path",{stroke:"#fff",d:"M19 17H6l2.5-4 2.097 2.516.405.486.379-.506 4.118-5.49.003-.002L19 17Z"}),o("path",{fill:"#fff",d:"M10 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"}))),o("div",{key:"c40c607d29fadce2ec710f8a18dd3488bd5dbdbc",class:"tooltip-extended-content"},this.header&&o("div",{key:"33f48c44bc1d59b9844bdecde9369d46894f0824",class:"tooltip-extended-header"},this.header),o("div",{key:"7404a6ade38526ddc888af5a53c45bb742898ce2",class:"tooltip-extended-body"},this.text)),o("svg",{key:"4030165bf576de2b17285e77dbef9a5ce92f11df",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"3d7001d8a44aaefd4cc8803592fb9e1911906e03",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))))}get el(){return i(this)}static get watchers(){return{position:["positionChanged"]}}};n.style=p;export{n as ifx_tooltip};
2
- //# sourceMappingURL=p-ef3206e1.entry.js.map
1
+ import{r as t,h as o,g as i}from"./p-b7a462e5.js";import{d as e,t as s}from"./p-e48e9f36.js";import{i as a}from"./p-1ecafb97.js";import{c as l}from"./p-e459974a.js";const d=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}:host{display:inline-flex}.tooltip__container{display:inline-flex;flex-direction:column;position:relative;font-family:var(--ifx-font-family)}.tooltip-extended,.tooltip-compact,.tooltip-dismissible{background-color:#1D1D1D;border:1px solid black;z-index:1080;display:none;transition:opacity 0.3s;position:absolute;font-size:14px;font-style:normal;font-weight:400;line-height:20px;color:#FFFFFF;width:max-content;box-sizing:border-box;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere;}.visible.tooltip-extended,.visible.tooltip-compact,.visible.tooltip-dismissible{display:flex !important;align-items:start}.tooltip-dismissible .close-button{all:unset;cursor:pointer;position:relative;order:2;margin-top:12px;margin-right:12px;line-height:0px}.tooltip-dismissible .tooltip-dismissible-content{display:flex;flex-direction:column;gap:12px;padding:12px;flex-grow:1;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere}.tooltip-dismissible .tooltip-dismissible-header,.tooltip-dismissible .tooltip-dismissible-body{font-size:14px;font-style:normal;line-height:20px}.tooltip-dismissible .tooltip-dismissible-header{font-weight:600}.tooltip-dismissible .tooltip-dismissible-body{font-weight:400}.tooltip-compact{padding:4px 8px;text-align:center;flex-grow:1}.tooltip-extended{align-items:center;padding:12px;gap:10px}.tooltip-extended .extended_icon{display:flex;align-self:flex-start;align-items:center;cursor:pointer}.tooltip-extended .tooltip-extended-content{display:flex;flex-direction:column;gap:12px;flex-grow:1;white-space:pre-wrap;word-wrap:break-word;overflow-wrap:anywhere}.tooltip-extended .tooltip-extended-header,.tooltip-extended .tooltip-extended-body{font-size:14px;font-style:normal;line-height:20px}.tooltip-extended .tooltip-extended-header{font-weight:600}.tooltip-extended .tooltip-extended-body{font-weight:400}.tooltip__container .tooltip-arrow-svg{position:absolute;width:8px;height:8px}[data-placement=top].tooltip-extended>.tooltip-arrow-svg,[data-placement=top].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;left:50%;transform:rotate(180deg) translateX(-50%)}[data-placement=top-start].tooltip-extended>.tooltip-arrow-svg,[data-placement=top-start].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top-start].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;left:10px;transform:rotate(180deg)}[data-placement=top-end].tooltip-extended>.tooltip-arrow-svg,[data-placement=top-end].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=top-end].tooltip-compact>.tooltip-arrow-svg{bottom:-7px;right:10px;transform:rotate(180deg)}[data-placement=bottom].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom].tooltip-compact>.tooltip-arrow-svg{top:-7px;left:50%;transform:translateX(-50%)}[data-placement=bottom-start].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom-start].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom-start].tooltip-compact>.tooltip-arrow-svg{top:-7px;left:10px}[data-placement=bottom-end].tooltip-extended>.tooltip-arrow-svg,[data-placement=bottom-end].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=bottom-end].tooltip-compact>.tooltip-arrow-svg{top:-7px;right:10px}[data-placement=left].tooltip-extended>.tooltip-arrow-svg,[data-placement=left].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=left].tooltip-compact>.tooltip-arrow-svg{right:-3px;top:50%;transform:rotate(90deg) translateY(-50%) translateX(-50%)}[data-placement=right].tooltip-extended>.tooltip-arrow-svg,[data-placement=right].tooltip-dismissible>.tooltip-arrow-svg,[data-placement=right].tooltip-compact>.tooltip-arrow-svg{left:-3px;top:50%;transform:rotate(270deg) translateY(-50%) translateX(50%)}.tooltip-compact{min-width:28px !important;max-width:145px !important}.tooltip-dismissible{min-width:145px !important;max-width:310px !important}.tooltip-extended{min-width:145px !important;max-width:310px !important}';const p=d;const n=class{constructor(o){t(this,o);this.tooltipVisible=false;this.header="";this.text="";this.position="auto";this.internalPosition="auto";this.variant="compact";this.popperInstance=null;this.onMouseEnter=()=>{var t,o;(t=this.popperInstance)===null||t===void 0?void 0:t.setOptions((t=>Object.assign(Object.assign({},t),{modifiers:[...t.modifiers,{name:"eventListeners",enabled:true}]})));this.initializePopper();this.tooltipVisible=true;this.tooltipEl.style.display="block";(o=this.popperInstance)===null||o===void 0?void 0:o.update()};this.onMouseLeave=()=>{this.tooltipVisible=false;this.tooltipEl.style.display="none"};this.onClick=()=>{var t;if(this.variant.toLowerCase()==="dismissible"){this.initializePopper();this.tooltipVisible=!this.tooltipVisible;this.tooltipEl.style.display=this.tooltipVisible?"block":"none";(t=this.popperInstance)===null||t===void 0?void 0:t.update()}};this.onDismissClick=()=>{this.tooltipVisible=false;this.tooltipEl.style.display="none"}}componentWillLoad(){if(!a(this.el)){const t=e();s("ifx-tooltip",t)}if(this.variant.toLowerCase().trim()===""){this.variant="compact"}}componentDidLoad(){const t=this.el.shadowRoot.querySelector(".tooltip__container").firstChild;if(this.variant.toLowerCase()==="compact"||this.variant.toLowerCase()==="extended"){t.addEventListener("mouseenter",this.onMouseEnter);t.addEventListener("mouseleave",this.onMouseLeave)}else{t.addEventListener("click",this.onClick)}}initializePopper(){if(this.popperInstance)return;this.referenceEl=this.el;if(this.variant.toLowerCase()==="compact"){this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-compact")}else if(this.variant.toLowerCase()==="dismissible"){this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-dismissible")}else{this.tooltipEl=this.el.shadowRoot.querySelector(".tooltip-extended")}const t=this.position==="auto"?this.determineBestPosition():this.position;this.internalPosition=t;if(this.tooltipEl&&this.referenceEl){this.popperInstance=l(this.referenceEl,this.tooltipEl,{placement:this.internalPosition,modifiers:[{name:"offset",options:{offset:[0,8]}},{name:"arrow",options:{element:".tooltip-arrow-svg"}}]})}this.tooltipEl.setAttribute("data-placement",t)}determineBestPosition(){const t=this.referenceEl.getBoundingClientRect();const o=window.scrollY;const i=window.scrollX;const e=t.top+o+t.height/2;const s=t.left+i+t.width/2;if(this.position==="auto"){if(e>window.innerHeight/2){if(s>window.innerWidth/2){return"top-end"}else{return"top-start"}}else{if(s>window.innerWidth/2){return"bottom-end"}else{return"bottom-start"}}}else{return this.position}}positionChanged(t){var o;this.internalPosition=t;(o=this.popperInstance)===null||o===void 0?void 0:o.destroy();this.popperInstance=null}disconnectedCallback(){var t;(t=this.popperInstance)===null||t===void 0?void 0:t.destroy()}render(){const t={"tooltip-dismissible":true,visible:this.tooltipVisible};const i={"tooltip-compact":true,visible:this.tooltipVisible};const e={"tooltip-extended":true,visible:this.tooltipVisible};return o("div",{key:"25d2c329b7784d96128dd851e75098e4cfb6da84","aria-label":"a tooltip showing important information","aria-value":this.header,class:"tooltip__container"},o("slot",{key:"a29d04ca80a0d148f415abd6b63af62f392849f3"}),this.variant.toLowerCase()==="dismissible"&&o("div",{key:"22ad260c5d46278e4f7ebdaafc3cc7876a331e4c",class:t},o("button",{key:"9ff17a1b56c1f19c3e3bb22cf6b92745c26614e2","aria-label":"Close Tooltip",class:"close-button",onClick:this.onDismissClick},o("ifx-icon",{key:"79dce9dff1b8f5f97254b55599cb653bfe587e73",icon:"cross16"})),o("div",{key:"641a69f72552427b5410276e7eff401a7903c3bf",class:"tooltip-dismissible-content"},this.header&&o("div",{key:"edb6683ee0251272d012d0034972606539d8e763",class:"tooltip-dismissible-header"},this.header),o("div",{key:"0d0301a012751009182c381dbfa2d09795115c8f",class:"tooltip-dismissible-body"},this.text)),o("svg",{key:"85a78b47d577caf95e9384f9b05c63acee200af9",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"47c8b8a64c81db908031715a0bded22195e89654",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))),this.variant.toLowerCase()==="compact"&&o("div",{key:"9673576e1dd4001929af8df58325ef504c8209cb",class:i},this.text,o("svg",{key:"3ac78682948105642df9779921396be8ddaef4e0",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"eabf5f7a8d69def4f94e80fbab9a2ec5deaaf36b",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))),this.variant.toLowerCase()==="extended"&&o("div",{key:"a5d3445fb94dcff603ccbcfea4a705da338e9df0",class:e},o("slot",{key:"eeaf6a5de965dcb7d39a9057d75fa7d1e20b0c87",name:"icon"},this.icon?o("div",{class:"extended_icon"},o("ifx-icon",{icon:this.icon})):o("svg",{class:"extended_icon",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24"},o("path",{stroke:"#fff","stroke-linecap":"round","stroke-linejoin":"round",d:"M20.5 2.5h-16a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-16a2 2 0 0 0-2-2Z"}),o("path",{stroke:"#fff",d:"M19 17H6l2.5-4 2.097 2.516.405.486.379-.506 4.118-5.49.003-.002L19 17Z"}),o("path",{fill:"#fff",d:"M10 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"}))),o("div",{key:"e392cf5a0989977582f3df3bcf0d6674e55da32e",class:"tooltip-extended-content"},this.header&&o("div",{key:"8fce83d556f681a33d0087ac77c5572a2d8a2f50",class:"tooltip-extended-header"},this.header),o("div",{key:"b80466a0b9ec4c423a0025f0e99b6b576a1a8f90",class:"tooltip-extended-body"},this.text)),o("svg",{key:"995d3900d983bf75645cba86f80aa5fd80190991",class:"tooltip-arrow-svg",width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o("path",{key:"67e30041c8e3644d229536ccd1cf4cecf5a4eefe",id:"Indicator",d:"M6 0L12 8L0 8L6 0Z",fill:"#1D1D1D"}))))}get el(){return i(this)}static get watchers(){return{position:["positionChanged"]}}};n.style=p;export{n as ifx_tooltip};
2
+ //# sourceMappingURL=p-db66c7bc.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["tooltipCss","IfxTooltipStyle0","Tooltip","constructor","hostRef","this","tooltipVisible","header","text","position","internalPosition","variant","popperInstance","onMouseEnter","_a","setOptions","options","Object","assign","modifiers","name","enabled","initializePopper","tooltipEl","style","display","_b","update","onMouseLeave","onClick","toLowerCase","onDismissClick","componentWillLoad","isNestedInIfxComponent","el","framework","detectFramework","trackComponent","trim","componentDidLoad","slotElement","shadowRoot","querySelector","firstChild","addEventListener","referenceEl","effectivePosition","determineBestPosition","createPopper","placement","offset","element","setAttribute","rect","getBoundingClientRect","yOffset","window","scrollY","xOffset","scrollX","verticalHalfwayPoint","top","height","horizontalHalfwayPoint","left","width","innerHeight","innerWidth","positionChanged","newVal","destroy","disconnectedCallback","render","tooltipDismissible","visible","tooltipCompact","tooltipExtended","h","key","class","icon","viewBox","fill","xmlns","id","d","stroke"],"sources":["src/components/tooltip/tooltip.scss?tag=ifx-tooltip&encapsulation=shadow","src/components/tooltip/tooltip.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n:host {\n display: inline-flex;\n}\n\n.tooltip__container {\n display: inline-flex;\n flex-direction: column;\n position: relative;\n font-family: var(--ifx-font-family); // tokens.$ifxFontFamilyBody;\n\n\n\n}\n\n%tooltip-common {\n background-color: tokens.$ifxColorBaseBlack;\n border: 1px solid black;\n z-index: 1080;\n display: none;\n transition: opacity 0.3s;\n position: absolute;\n font-size: 14px;\n font-style: normal;\n font-weight: 400;\n line-height: 20px;\n color: tokens.$ifxColorBaseWhite;\n width: max-content;\n box-sizing: border-box;\n\n white-space: pre-wrap; /* wraps text at spaces and within words */\n word-wrap: break-word; /* breaks text within a word if necessary */\n overflow-wrap: anywhere; /* breaks text at arbitrary points when needed */\n\n &.visible {\n display: flex !important;\n align-items: start;\n //min-width: 100px;\n //width: auto;\n }\n}\n\n\n\n.tooltip-dismissible {\n @extend %tooltip-common;\n\n .close-button {\n all: unset;\n //position: absolute;\n //top: tokens.$ifxSpace150;\n //right: tokens.$ifxSpace150;\n cursor: pointer;\n position: relative;\n order: 2;\n margin-top: 12px;\n margin-right: 12px;\n line-height: 0px;\n }\n\n .tooltip-dismissible-content {\n display: flex;\n flex-direction: column;\n gap: tokens.$ifxSpace150;\n padding: tokens.$ifxSpace150;\n flex-grow: 1;\n white-space: pre-wrap;\n word-wrap: break-word;\n overflow-wrap: anywhere;\n\n }\n\n .tooltip-dismissible-header,\n .tooltip-dismissible-body {\n font-size: 14px;\n font-style: normal;\n line-height: 20px;\n }\n\n .tooltip-dismissible-header {\n font-weight: tokens.$ifxFontWeightSemibold;\n }\n\n .tooltip-dismissible-body {\n font-weight: tokens.$ifxFontWeightRegular;\n }\n}\n\n.tooltip-compact {\n @extend %tooltip-common;\n padding: 4px 8px;\n text-align: center;\n flex-grow: 1;\n}\n\n\n.tooltip-extended {\n @extend %tooltip-common;\n //padding-left: 36px; // Added this line, adjust as per your icon width\n //padding-left: tokens.$ifxSpace150; // Added this line, adjust as per your icon width\n align-items: center;\n padding: tokens.$ifxSpace150;\n gap: 10px;\n\n .extended_icon {\n display: flex;\n align-self: flex-start;\n align-items: center;\n //padding-top: tokens.$ifxSpace150;\n cursor: pointer;\n }\n\n\n\n .tooltip-extended-content {\n display: flex;\n flex-direction: column;\n gap: tokens.$ifxSpace150;\n //padding: tokens.$ifxSpace150;\n flex-grow: 1;\n white-space: pre-wrap;\n word-wrap: break-word;\n overflow-wrap: anywhere;\n }\n\n .tooltip-extended-header,\n .tooltip-extended-body {\n font-size: 14px;\n font-style: normal;\n line-height: 20px;\n }\n\n .tooltip-extended-header {\n font-weight: tokens.$ifxFontWeightSemibold;\n }\n\n .tooltip-extended-body {\n font-weight: tokens.$ifxFontWeightRegular;\n }\n}\n\n\n.tooltip__container .tooltip-arrow-svg {\n position: absolute;\n width: 8px;\n height: 8px;\n}\n\n\n%tooltip-arrow-positions {\n\n // For 'top' placement\n &[data-placement=\"top\"]>.tooltip-arrow-svg {\n bottom: -7px;\n left: 50%;\n transform: rotate(180deg) translateX(-50%);\n }\n\n // For 'top-start' placement\n &[data-placement=\"top-start\"]>.tooltip-arrow-svg {\n bottom: -7px;\n left: 10px; // Adjust as needed\n transform: rotate(180deg)\n }\n\n // For 'top-end' placement\n &[data-placement=\"top-end\"]>.tooltip-arrow-svg {\n bottom: -7px;\n right: 10px; // Adjust as needed\n transform: rotate(180deg);\n }\n\n // For 'bottom' placement\n &[data-placement=\"bottom\"]>.tooltip-arrow-svg {\n top: -7px;\n left: 50%;\n transform: translateX(-50%);\n }\n\n // For 'bottom-start' placement\n &[data-placement=\"bottom-start\"]>.tooltip-arrow-svg {\n top: -7px;\n left: 10px; // Adjust as needed\n }\n\n // For 'bottom-end' placement\n &[data-placement=\"bottom-end\"]>.tooltip-arrow-svg {\n top: -7px;\n right: 10px; // Adjust as needed\n }\n\n // For 'left' placement\n &[data-placement=\"left\"]>.tooltip-arrow-svg {\n right: -3px;\n top: 50%;\n transform: rotate(90deg) translateY(-50%) translateX(-50%);\n }\n\n // For 'right' placement\n &[data-placement=\"right\"]>.tooltip-arrow-svg {\n left: -3px;\n top: 50%;\n transform: rotate(270deg) translateY(-50%) translateX(50%);\n }\n}\n\n\n.tooltip-compact {\n @extend %tooltip-arrow-positions;\n min-width: 28px !important;\n max-width: 145px !important;\n}\n\n.tooltip-dismissible {\n @extend %tooltip-arrow-positions;\n min-width: 145px !important;\n max-width: 310px !important;\n}\n\n.tooltip-extended {\n @extend %tooltip-arrow-positions;\n min-width: 145px !important;\n max-width: 310px !important;\n}\n","import { Component, Prop, h, Element, State, Watch } from '@stencil/core';\nimport { createPopper } from '@popperjs/core';\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\n\n@Component({\n tag: 'ifx-tooltip',\n styleUrl: 'tooltip.scss',\n shadow: true\n})\nexport class Tooltip {\n\n @Element() el: HTMLElement;\n @State() tooltipVisible: boolean = false;\n @Prop() header: string = '';\n @Prop() text: string = '';\n @Prop() position: 'bottom-start' | 'top-start' | 'left' | 'bottom-end' | 'top-end' | 'right' | 'bottom' | 'top' | 'auto' = 'auto';\n @State() internalPosition: 'bottom-start' | 'top-start' | 'left' | 'bottom-end' | 'top-end' | 'right' | 'bottom' | 'top' | 'auto' = 'auto';\n\n @Prop() variant: 'compact' | 'dismissible' | 'extended' = 'compact';\n @Prop() icon: string;\n\n tooltipEl: HTMLElement;\n referenceEl: HTMLElement;\n popperInstance: any = null;\n\n\n componentWillLoad() { \n if(!isNestedInIfxComponent(this.el)) { \n const framework = detectFramework();\n trackComponent('ifx-tooltip', framework)\n }\n if(this.variant.toLowerCase().trim() === \"\") { \n this.variant = 'compact'\n }\n }\n \n componentDidLoad() {\n const slotElement = this.el.shadowRoot.querySelector('.tooltip__container').firstChild;\n \n if(this.variant.toLowerCase() === 'compact' || this.variant.toLowerCase() === 'extended') {\n slotElement.addEventListener('mouseenter', this.onMouseEnter)\n slotElement.addEventListener('mouseleave', this.onMouseLeave)\n }else{\n slotElement.addEventListener('click', this.onClick);\n }\n\n }\n\n initializePopper() {\n if (this.popperInstance) return;\n\n this.referenceEl = this.el;\n this.tooltipEl;\n if (this.variant.toLowerCase() === 'compact') {\n this.tooltipEl = this.el.shadowRoot.querySelector('.tooltip-compact');\n }\n else if (this.variant.toLowerCase() === 'dismissible') {\n this.tooltipEl = this.el.shadowRoot.querySelector('.tooltip-dismissible');\n }\n else {\n this.tooltipEl = this.el.shadowRoot.querySelector('.tooltip-extended');\n\n }\n\n const effectivePosition = this.position === 'auto' ? this.determineBestPosition() : this.position;\n\n // Set the internalPosition\n this.internalPosition = effectivePosition;\n\n if (this.tooltipEl && this.referenceEl) {\n\n this.popperInstance = createPopper(this.referenceEl, this.tooltipEl, {\n placement: this.internalPosition,\n modifiers: [\n {\n name: 'offset',\n options: {\n offset: [0, 8] // this offset should be adjusted to ensure the tooltip doesn't overlap its reference element\n }\n },\n {\n name: 'arrow',\n options: {\n element: '.tooltip-arrow-svg'\n }\n }\n ]\n });\n\n }\n\n // Add this line to set the 'data-placement' attribute on the tooltip\n this.tooltipEl.setAttribute('data-placement', effectivePosition);\n\n\n }\n\n determineBestPosition() {\n // This is a simplified version, you can enhance this based on available viewport space.\n const rect = this.referenceEl.getBoundingClientRect();\n const yOffset = window.scrollY; // Get current scroll position\n const xOffset = window.scrollX; // Get current horizontal scroll position\n\n const verticalHalfwayPoint = rect.top + yOffset + rect.height / 2;\n const horizontalHalfwayPoint = rect.left + xOffset + rect.width / 2;\n\n if (this.position === 'auto') {\n if (verticalHalfwayPoint > window.innerHeight / 2) {\n if (horizontalHalfwayPoint > window.innerWidth / 2) {\n return 'top-end';\n } else {\n return 'top-start';\n }\n } else {\n if (horizontalHalfwayPoint > window.innerWidth / 2) {\n return 'bottom-end';\n } else {\n return 'bottom-start';\n }\n }\n } else {\n return this.position;\n }\n }\n\n @Watch('position')\n positionChanged(newVal: any) {\n this.internalPosition = newVal;\n this.popperInstance?.destroy();\n this.popperInstance = null; // Force re-initialization on next mouse enter\n }\n\n\n\n onMouseEnter = () => {\n // Enable the event listeners immediately\n this.popperInstance?.setOptions((options) => ({\n ...options,\n modifiers: [\n ...options.modifiers,\n { name: 'eventListeners', enabled: true },\n ],\n }));\n\n // Initialize the popper instance\n this.initializePopper();\n\n // Make the tooltip visible\n this.tooltipVisible = true;\n this.tooltipEl.style.display = 'block';\n\n // Update the popper instance immediately after initialization\n this.popperInstance?.update();\n }\n\n\n onMouseLeave = () => {\n this.tooltipVisible = false;\n this.tooltipEl.style.display = 'none';\n\n }\n\n disconnectedCallback() {\n this.popperInstance?.destroy();\n }\n\n onClick = () => {\n if (this.variant.toLowerCase() === 'dismissible') {\n this.initializePopper();\n this.tooltipVisible = !this.tooltipVisible;\n this.tooltipEl.style.display = this.tooltipVisible ? 'block' : 'none';\n this.popperInstance?.update();\n }\n }\n\n onDismissClick = () => {\n this.tooltipVisible = false;\n this.tooltipEl.style.display = 'none';\n }\n\n render() {\n const tooltipDismissible = {\n 'tooltip-dismissible': true,\n 'visible': this.tooltipVisible,\n };\n\n const tooltipCompact = {\n 'tooltip-compact': true,\n 'visible': this.tooltipVisible,\n };\n\n const tooltipExtended = {\n 'tooltip-extended': true,\n 'visible': this.tooltipVisible,\n };\n\n return (\n <div aria-label=\"a tooltip showing important information\" aria-value={this.header} class=\"tooltip__container\" >\n <slot></slot>\n\n {this.variant.toLowerCase() === 'dismissible' && <div class={tooltipDismissible}>\n <button aria-label=\"Close Tooltip\" class=\"close-button\" onClick={this.onDismissClick}>\n <ifx-icon icon=\"cross16\"></ifx-icon>\n </button>\n <div class=\"tooltip-dismissible-content\">\n {this.header && <div class=\"tooltip-dismissible-header\">{this.header}</div>}\n <div class=\"tooltip-dismissible-body\">{this.text}</div>\n </div>\n <svg class=\"tooltip-arrow-svg\" width=\"12\" height=\"8\" viewBox=\"0 0 12 8\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path id=\"Indicator\" d=\"M6 0L12 8L0 8L6 0Z\" fill=\"#1D1D1D\" />\n </svg>\n </div>\n }\n {this.variant.toLowerCase() === 'compact' &&\n <div class={tooltipCompact}>\n {this.text}\n <svg class=\"tooltip-arrow-svg\" width=\"12\" height=\"8\" viewBox=\"0 0 12 8\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path id=\"Indicator\" d=\"M6 0L12 8L0 8L6 0Z\" fill=\"#1D1D1D\" />\n </svg>\n </div>\n }\n {this.variant.toLowerCase() === 'extended' &&\n <div class={tooltipExtended}>\n <slot name=\"icon\">\n {this.icon ? <div class=\"extended_icon\"><ifx-icon icon={this.icon}></ifx-icon></div> :\n <svg class=\"extended_icon\" xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" fill=\"none\" viewBox=\"0 0 24 24\">\n <path stroke=\"#fff\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M20.5 2.5h-16a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-16a2 2 0 0 0-2-2Z\" />\n <path stroke=\"#fff\" d=\"M19 17H6l2.5-4 2.097 2.516.405.486.379-.506 4.118-5.49.003-.002L19 17Z\" />\n <path fill=\"#fff\" d=\"M10 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z\" />\n </svg>\n }\n </slot>\n <div class=\"tooltip-extended-content\">\n {this.header && <div class=\"tooltip-extended-header\">{this.header}</div>}\n <div class=\"tooltip-extended-body\">{this.text}</div>\n </div>\n <svg class=\"tooltip-arrow-svg\" width=\"12\" height=\"8\" viewBox=\"0 0 12 8\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path id=\"Indicator\" d=\"M6 0L12 8L0 8L6 0Z\" fill=\"#1D1D1D\" />\n </svg>\n </div >\n }\n </div>\n );\n }\n\n\n}"],"mappings":"qKAAA,MAAMA,EAAa,w/HACnB,MAAAC,EAAeD,E,MCUFE,EAAO,MALpB,WAAAC,CAAAC,G,UAQWC,KAAAC,eAA0B,MAC3BD,KAAAE,OAAiB,GACjBF,KAAAG,KAAe,GACfH,KAAAI,SAAmH,OAClHJ,KAAAK,iBAA2H,OAE5HL,KAAAM,QAAkD,UAK1DN,KAAAO,eAAsB,KA+GtBP,KAAAQ,aAAe,K,SAEbC,EAAAT,KAAKO,kBAAc,MAAAE,SAAA,SAAAA,EAAEC,YAAYC,GAAOC,OAAAC,OAAAD,OAAAC,OAAA,GACnCF,GAAO,CACVG,UAAW,IACNH,EAAQG,UACX,CAAEC,KAAM,iBAAkBC,QAAS,WAKvChB,KAAKiB,mBAGLjB,KAAKC,eAAiB,KACtBD,KAAKkB,UAAUC,MAAMC,QAAU,SAG/BC,EAAArB,KAAKO,kBAAc,MAAAc,SAAA,SAAAA,EAAEC,QAAQ,EAI/BtB,KAAAuB,aAAe,KACbvB,KAAKC,eAAiB,MACtBD,KAAKkB,UAAUC,MAAMC,QAAU,MAAM,EAQvCpB,KAAAwB,QAAU,K,MACR,GAAIxB,KAAKM,QAAQmB,gBAAkB,cAAe,CAChDzB,KAAKiB,mBACLjB,KAAKC,gBAAkBD,KAAKC,eAC5BD,KAAKkB,UAAUC,MAAMC,QAAUpB,KAAKC,eA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,MAAM,4BACR1E,KAAKE,QAAUsE,EAAA,OAAAC,IAAA,2CAAKC,MAAM,2BAA2B1E,KAAKE,QAC3DsE,EAAA,OAAAC,IAAA,2CAAKC,MAAM,yBAAyB1E,KAAKG,OAE3CqE,EAAA,OAAAC,IAAA,2CAAKC,MAAM,oBAAoBd,MAAM,KAAKH,OAAO,IAAImB,QAAQ,WAAWC,KAAK,OAAOC,MAAM,8BACxFN,EAAA,QAAAC,IAAA,2CAAMM,GAAG,YAAYC,EAAE,qBAAqBH,KAAK,c","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ function n(){(function(n,t,o,e,i){if(typeof window.btntConfig!=="object"){window.btntConfig={domain:"https://ssgtm.infineon.com",withCookies:true,maxBatchSize:10}}if(window["btnt"])return;window["btnt"]=function(n){if(typeof n!=="object"){n={}}if(typeof window.btntQueue!=="object"){window.btntQueue=[]}window.btntQueue.push(n)};e=n.createElement(t);i=n.getElementsByTagName(t)[0];e.async=1;e.src=window.btntConfig.domain+"/btnt.js";i.parentNode.insertBefore(e,i)})(document,"script")}function t(t,o){if(!window.btnt)n();window.btnt({event_name:"component_initialized",component_name:t,environment:o})}const o=()=>{const n=window;if(!!n.React||!!document.querySelector("[data-reactroot], [data-reactid]")||Array.from(document.querySelectorAll("*")).some((n=>n._reactRootContainer!==undefined||Object.keys(n).some((n=>n.startsWith("__reactContainer")))))){return"React"}if(!!n.getAllAngularRootElements||!!document.querySelector("[ng-version], [ng-app], [data-ng-app], [ng-controller], [data-ng-controller], [ng-repeat], [data-ng-repeat]")||!!document.querySelector('script[src*="angular.js"], script[src*="angular.min.js"]')){return"Angular"}if(!!n.__VUE__){return"Vue"}return"vanilla"};export{o as d,t};
2
+ //# sourceMappingURL=p-e48e9f36.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["initializeTracking","t","r","_kk","n","pp","window","btntConfig","domain","withCookies","maxBatchSize","z","btntQueue","push","createElement","getElementsByTagName","async","src","parentNode","insertBefore","document","trackComponent","componentName","environment","btnt","event_name","component_name","detectFramework","win","React","querySelector","Array","from","querySelectorAll","some","e","_reactRootContainer","undefined","Object","keys","k","startsWith","getAllAngularRootElements","__VUE__"],"sources":["src/global/utils/tracking.ts","src/global/utils/framework-detection.ts"],"sourcesContent":["declare global {\n interface Window {\n btntConfig?: any;\n btntQueue?: any[];\n btnt?: (data: object) => void; \n }\n}\n\nfunction initializeTracking() { \n (function (t, r, _kk, n, pp) {\n if (typeof window.btntConfig !== \"object\") {\n window.btntConfig = {\n domain: \"https://ssgtm.infineon.com\",\n withCookies: true,\n maxBatchSize: 10\n };\n }\n\n if (window[\"btnt\"]) return;\n\n window[\"btnt\"] = function (z) {\n if (typeof z !== \"object\") {\n z = {};\n }\n if (typeof window.btntQueue !== \"object\") {\n window.btntQueue = [];\n }\n window.btntQueue.push(z);\n };\n\n n = t.createElement(r);\n pp = t.getElementsByTagName(r)[0];\n n.async = 1;\n n.src = window.btntConfig.domain + \"/btnt.js\";\n pp.parentNode.insertBefore(n, pp);\n \n })(document, \"script\", );\n }\n\n export function trackComponent(componentName: string, environment: string) {\n if (!window.btnt) initializeTracking();\n \n window.btnt({\n event_name: \"component_initialized\",\n component_name: componentName,\n environment: environment\n });\n } \n\n export default trackComponent","export const detectFramework = (): string => {\n const win = window as any;\n\n if(!!win.React || !!document.querySelector('[data-reactroot], [data-reactid]') ||\n Array.from(document.querySelectorAll('*')).some((e: any) => e._reactRootContainer !== undefined || Object.keys(e).some(k => k.startsWith('__reactContainer')))\n ) { \n return 'React'\n }\n \n \n if(!!win.getAllAngularRootElements || \n !!document.querySelector('[ng-version], [ng-app], [data-ng-app], [ng-controller], [data-ng-controller], [ng-repeat], [data-ng-repeat]') ||\n !!document.querySelector('script[src*=\"angular.js\"], script[src*=\"angular.min.js\"]')\n) {\n return 'Angular'\n}\n \n\n if(!!win.__VUE__) {\n return 'Vue'\n }\n\n return 'vanilla'\n};"],"mappings":"AAQA,SAASA,KACL,SAAWC,EAAGC,EAAGC,EAAKC,EAAGC,GACvB,UAAWC,OAAOC,aAAe,SAAU,CACzCD,OAAOC,WAAa,CACpBC,OAAQ,6BACRC,YAAa,KACbC,aAAc,G,CAIhB,GAAIJ,OAAO,QAAS,OAEpBA,OAAO,QAAU,SAAUK,GACzB,UAAWA,IAAM,SAAU,CACzBA,EAAI,E,CAEN,UAAWL,OAAOM,YAAc,SAAU,CACxCN,OAAOM,UAAY,E,CAErBN,OAAOM,UAAUC,KAAKF,E,EAGxBP,EAAIH,EAAEa,cAAcZ,GACpBG,EAAKJ,EAAEc,qBAAqBb,GAAG,GAC/BE,EAAEY,MAAQ,EACVZ,EAAEa,IAAMX,OAAOC,WAAWC,OAAS,WACnCH,EAAGa,WAAWC,aAAaf,EAAGC,EAE/B,EA3BD,CA2BGe,SAAU,SACf,C,SAEgBC,EAAeC,EAAuBC,GACtD,IAAKjB,OAAOkB,KAAMxB,IAElBM,OAAOkB,KAAK,CACVC,WAAY,wBACZC,eAAgBJ,EAChBC,YAAaA,GAEhB,C,MC/CYI,EAAkB,KAC7B,MAAMC,EAAMtB,OAEZ,KAAKsB,EAAIC,SAAWT,SAASU,cAAc,qCAC1CC,MAAMC,KAAKZ,SAASa,iBAAiB,MAAMC,MAAMC,GAAWA,EAAEC,sBAAwBC,WAAaC,OAAOC,KAAKJ,GAAGD,MAAKM,GAAKA,EAAEC,WAAW,wBACxI,CACA,MAAO,O,CAIT,KAAKb,EAAIc,6BACNtB,SAASU,cAAc,kHACvBV,SAASU,cAAc,4DAC1B,CACA,MAAO,S,CAIP,KAAKF,EAAIe,QAAS,CAChB,MAAO,K,CAGT,MAAO,SAAS,S","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as t,h as i,g as o}from"./p-b7a462e5.js";import{d as r,t as a}from"./p-e48e9f36.js";import{i as e}from"./p-1ecafb97.js";const n=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}.radio-button-group-container{display:flex;flex-direction:column}.radio-button-group{display:flex;font-family:var(--ifx-font-family);gap:8px}.radio-button-group.horizontal{flex-direction:row;column-gap:12px}.radio-button-group.vertical{flex-direction:column;row-gap:12px}.group-label{font:400 0.75rem/1rem "Source Sans 3";margin-bottom:8px;text-align:left;text-underline-position:from-font;text-decoration-skip-ink:none}.caption{margin-top:8px;align-self:flex-start;display:flex;width:100%;column-gap:8px;justify-content:space-between;align-items:center}.caption.default{color:#1D1D1D}.caption.error{color:#CD002F}.caption-text{font:400 0.75rem/1rem "Source Sans 3";flex:1;text-align:left;text-underline-position:from-font;text-decoration-skip-ink:none}.caption-icon{flex:0;display:flex}';const s=n;const c=class{constructor(i){t(this,i);this.errorStates=new Map;this.alignment="vertical";this.groupLabelText="Group Label Text";this.hasErrors=false;this.handleSlotChange=()=>{this.initializeState()}}handleRadioButtonError(t){const i=t.target;if(i.tagName==="ifx-radio-button"){this.errorStates.set(i,t.detail);this.updateHasErrors()}}async setGroupError(t){const i=Array.from(this.el.querySelectorAll("ifx-radio-button"));i.forEach((i=>{i.error=t}))}componentWillLoad(){if(!e(this.el)){const t=r();a("ifx-radio-button-group",t)}this.initializeState()}initializeState(){this.errorStates.clear();const t=Array.from(this.el.querySelectorAll("ifx-radio-button"));t.forEach((t=>{if(!this.errorStates.has(t)){this.errorStates.set(t,t.error||false)}}));this.updateHasErrors()}updateHasErrors(){this.hasErrors=Array.from(this.errorStates.values()).some((t=>t))}render(){return i("div",{key:"1aadf70d79446d417d55f286267db42b192d9728",class:"radio-button-group-container"},this.showGroupLabel?i("div",{class:"group-label"},this.groupLabelText," *"):"",i("div",{key:"4dd5ce464afe4f28f644762046b797db63d1f296",class:`radio-button-group ${this.alignment} ${this.size}`},i("slot",{key:"4a65d2e56526f5dfb7967abd1c51a2c85afb8e4e",onSlotchange:this.handleSlotChange})),this.showCaption?i("div",{class:`caption ${this.hasErrors?"error":"default"}`},this.showCaptionIcon?i("div",{class:"caption-icon"},i("ifx-icon",{icon:"c-info-16"})):"",i("div",{class:"caption-text"},this.captionText)):"")}static get formAssociated(){return true}get el(){return o(this)}};c.style=s;export{c as ifx_radio_button_group};
2
+ //# sourceMappingURL=p-e4d630cb.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["radioButtonGroupCss","IfxRadioButtonGroupStyle0","RadioButtonGroup","constructor","hostRef","this","errorStates","Map","alignment","groupLabelText","hasErrors","handleSlotChange","initializeState","handleRadioButtonError","event","radioButton","target","tagName","set","detail","updateHasErrors","setGroupError","error","radioButtons","Array","from","el","querySelectorAll","forEach","componentWillLoad","isNestedInIfxComponent","framework","detectFramework","trackComponent","clear","has","values","some","render","h","key","class","showGroupLabel","size","onSlotchange","showCaption","showCaptionIcon","icon","captionText"],"sources":["src/components/radio-button-group/radio-button-group.scss?tag=ifx-radio-button-group&encapsulation=shadow","src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n.radio-button-group-container {\n display: flex;\n flex-direction: column;\n}\n\n.radio-button-group {\n display: flex;\n font-family: var(--ifx-font-family); // tokens.$ifxFontFamilyBody;\n\n\n gap: tokens.$ifxSpace100;\n\n &.horizontal {\n flex-direction: row;\n column-gap: tokens.$ifxSpace150;\n }\n\n &.vertical {\n flex-direction: column;\n row-gap: tokens.$ifxSpace150;\n }\n}\n\n.group-label {\n font: tokens.$ifxBodyBody05;\n margin-bottom: tokens.$ifxSpace100;\n text-align: left;\n text-underline-position: from-font;\n text-decoration-skip-ink: none;\n}\n\n.caption {\n margin-top: tokens.$ifxSpace100;\n align-self: flex-start;\n display: flex;\n width: 100%;\n column-gap: tokens.$ifxSpace100;\n justify-content: space-between;\n align-items: center;\n\n &.default {\n color: tokens.$ifxColorBaseBlack;\n }\n\n &.error {\n color: tokens.$ifxColorRed500;\n }\n}\n\n.caption-text {\n font: tokens.$ifxBodyBody05;\n flex: 1;\n text-align: left;\n text-underline-position: from-font;\n text-decoration-skip-ink: none;\n}\n\n.caption-icon {\n flex:0;\n display: flex;\n}","import { Component, State, Prop, h, Element, Listen, Method } from '@stencil/core';\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\n\n@Component({\n tag: 'ifx-radio-button-group',\n styleUrl: 'radio-button-group.scss',\n shadow: true,\n formAssociated: true\n})\n\nexport class RadioButtonGroup {\n private errorStates: Map<HTMLElement, boolean> = new Map();\n\n @Element() el: HTMLElement;\n @Prop() alignment: 'horizontal' | 'vertical' = 'vertical';\n @Prop() size: string;\n @Prop() showGroupLabel: boolean;\n @Prop() groupLabelText: string = 'Group Label Text';\n @Prop() showCaption: boolean;\n @Prop() captionText: string;\n @Prop() showCaptionIcon: boolean;\n @State() hasErrors: boolean = false;\n \n @Listen('ifxError')\n handleRadioButtonError(event: CustomEvent) {\n const radioButton = event.target as HTMLElement;\n if (radioButton.tagName === 'ifx-radio-button') {\n this.errorStates.set(radioButton, event.detail);\n this.updateHasErrors();\n }\n }\n\n // Method to set the error state of all radio-butttons in the group\n @Method()\n async setGroupError(error: boolean) {\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n (radioButton as any).error = error;\n });\n }\n\n componentWillLoad() {\n if(!isNestedInIfxComponent(this.el)) { \n const framework = detectFramework();\n trackComponent('ifx-radio-button-group', { framework })\n }\n this.initializeState();\n }\n\n handleSlotChange = () => {\n this.initializeState();\n };\n\n private initializeState() {\n this.errorStates.clear();\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n if (!this.errorStates.has(radioButton)) {\n this.errorStates.set(radioButton, (radioButton as any).error || false);\n }\n });\n this.updateHasErrors();\n }\n\n private updateHasErrors() {\n this.hasErrors = Array.from(this.errorStates.values()).some((error) => error);\n }\n\n render() {\n return (\n <div class='radio-button-group-container'>\n {this.showGroupLabel ? <div class='group-label'>{this.groupLabelText} *</div> : ''}\n <div class={`radio-button-group ${this.alignment} ${this.size}`}>\n <slot onSlotchange={this.handleSlotChange} ></slot>\n </div>\n {this.showCaption ? (\n <div class={`caption ${this.hasErrors ? 'error' : 'default'}`}>\n {this.showCaptionIcon ? <div class='caption-icon'><ifx-icon icon=\"c-info-16\">\n </ifx-icon></div> : ''}\n <div class='caption-text'>{this.captionText}</div>\n </div>) : ''}\n </div>\n );\n }\n}"],"mappings":"iIAAA,MAAMA,EAAsB,m1BAC5B,MAAAC,EAAeD,E,MCWFE,EAAgB,MAP7B,WAAAC,CAAAC,G,UAQYC,KAAAC,YAAyC,IAAIC,IAG7CF,KAAAG,UAAuC,WAGvCH,KAAAI,eAAyB,mBAIxBJ,KAAAK,UAAqB,MA4B9BL,KAAAM,iBAAmB,KACfN,KAAKO,iBAAiB,C,CA1B1B,sBAAAC,CAAuBC,GACnB,MAAMC,EAAcD,EAAME,OAC1B,GAAID,EAAYE,UAAY,mBAAoB,CAC5CZ,KAAKC,YAAYY,IAAIH,EAAaD,EAAMK,QACxCd,KAAKe,iB,EAMX,mBAAMC,CAAcC,GAClB,MAAMC,EAAeC,MAAMC,KAAKpB,KAAKqB,GAAGC,iBAAiB,qBACzDJ,EAAaK,SAASb,IACnBA,EAAoBO,MAAQA,CAAK,G,CAIxC,iBAAAO,GACI,IAAIC,EAAuBzB,KAAKqB,IAAK,CACjC,MAAMK,EAAYC,IAClBC,EAAe,yBAA0B,CAAEF,a,CAE/C1B,KAAKO,iB,CAOD,eAAAA,GACJP,KAAKC,YAAY4B,QACjB,MAAMX,EAAeC,MAAMC,KAAKpB,KAAKqB,GAAGC,iBAAiB,qBACzDJ,EAAaK,SAASb,IAClB,IAAKV,KAAKC,YAAY6B,IAAIpB,GAAc,CACpCV,KAAKC,YAAYY,IAAIH,EAAcA,EAAoBO,OAAS,M,KAGxEjB,KAAKe,iB,CAGD,eAAAA,GACJf,KAAKK,UAAYc,MAAMC,KAAKpB,KAAKC,YAAY8B,UAAUC,MAAMf,GAAUA,G,CAG3E,MAAAgB,GACI,OACIC,EAAA,OAAAC,IAAA,2CAAKC,MAAM,gCACNpC,KAAKqC,eAAiBH,EAAA,OAAKE,MAAM,eAAepC,KAAKI,eAAc,MAAY,GAChF8B,EAAA,OAAAC,IAAA,2CAAKC,MAAO,sBAAsBpC,KAAKG,aAAaH,KAAKsC,QACrDJ,EAAA,QAAAC,IAAA,2CAAMI,aAAcvC,KAAKM,oBAE5BN,KAAKwC,YACFN,EAAA,OAAKE,MAAO,WAAWpC,KAAKK,UAAY,QAAU,aAC7CL,KAAKyC,gBAAkBP,EAAA,OAAKE,MAAM,gBAAeF,EAAA,YAAUQ,KAAK,eAC7C,GACpBR,EAAA,OAAKE,MAAM,gBAAgBpC,KAAK2C,cAC1B,G","ignoreList":[]}
1
+ {"version":3,"names":["radioButtonGroupCss","IfxRadioButtonGroupStyle0","RadioButtonGroup","constructor","hostRef","this","errorStates","Map","alignment","groupLabelText","hasErrors","handleSlotChange","initializeState","handleRadioButtonError","event","radioButton","target","tagName","set","detail","updateHasErrors","setGroupError","error","radioButtons","Array","from","el","querySelectorAll","forEach","componentWillLoad","isNestedInIfxComponent","framework","detectFramework","trackComponent","clear","has","values","some","render","h","key","class","showGroupLabel","size","onSlotchange","showCaption","showCaptionIcon","icon","captionText"],"sources":["src/components/radio-button-group/radio-button-group.scss?tag=ifx-radio-button-group&encapsulation=shadow","src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["@use \"~@infineon/design-system-tokens/dist/tokens\";\n@use \"../../global/font.scss\";\n\n.radio-button-group-container {\n display: flex;\n flex-direction: column;\n}\n\n.radio-button-group {\n display: flex;\n font-family: var(--ifx-font-family); // tokens.$ifxFontFamilyBody;\n\n\n gap: tokens.$ifxSpace100;\n\n &.horizontal {\n flex-direction: row;\n column-gap: tokens.$ifxSpace150;\n }\n\n &.vertical {\n flex-direction: column;\n row-gap: tokens.$ifxSpace150;\n }\n}\n\n.group-label {\n font: tokens.$ifxBodyBody05;\n margin-bottom: tokens.$ifxSpace100;\n text-align: left;\n text-underline-position: from-font;\n text-decoration-skip-ink: none;\n}\n\n.caption {\n margin-top: tokens.$ifxSpace100;\n align-self: flex-start;\n display: flex;\n width: 100%;\n column-gap: tokens.$ifxSpace100;\n justify-content: space-between;\n align-items: center;\n\n &.default {\n color: tokens.$ifxColorBaseBlack;\n }\n\n &.error {\n color: tokens.$ifxColorRed500;\n }\n}\n\n.caption-text {\n font: tokens.$ifxBodyBody05;\n flex: 1;\n text-align: left;\n text-underline-position: from-font;\n text-decoration-skip-ink: none;\n}\n\n.caption-icon {\n flex:0;\n display: flex;\n}","import { Component, State, Prop, h, Element, Listen, Method } from '@stencil/core';\nimport { trackComponent } from '../../global/utils/tracking';\nimport { isNestedInIfxComponent } from '../../global/utils/dom-utils';\nimport { detectFramework } from '../../global/utils/framework-detection';\n\n@Component({\n tag: 'ifx-radio-button-group',\n styleUrl: 'radio-button-group.scss',\n shadow: true,\n formAssociated: true\n})\n\nexport class RadioButtonGroup {\n private errorStates: Map<HTMLElement, boolean> = new Map();\n\n @Element() el: HTMLElement;\n @Prop() alignment: 'horizontal' | 'vertical' = 'vertical';\n @Prop() size: string;\n @Prop() showGroupLabel: boolean;\n @Prop() groupLabelText: string = 'Group Label Text';\n @Prop() showCaption: boolean;\n @Prop() captionText: string;\n @Prop() showCaptionIcon: boolean;\n @State() hasErrors: boolean = false;\n \n @Listen('ifxError')\n handleRadioButtonError(event: CustomEvent) {\n const radioButton = event.target as HTMLElement;\n if (radioButton.tagName === 'ifx-radio-button') {\n this.errorStates.set(radioButton, event.detail);\n this.updateHasErrors();\n }\n }\n\n // Method to set the error state of all radio-butttons in the group\n @Method()\n async setGroupError(error: boolean) {\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n (radioButton as any).error = error;\n });\n }\n\n componentWillLoad() {\n if(!isNestedInIfxComponent(this.el)) { \n const framework = detectFramework();\n trackComponent('ifx-radio-button-group', framework)\n }\n this.initializeState();\n }\n\n handleSlotChange = () => {\n this.initializeState();\n };\n\n private initializeState() {\n this.errorStates.clear();\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n if (!this.errorStates.has(radioButton)) {\n this.errorStates.set(radioButton, (radioButton as any).error || false);\n }\n });\n this.updateHasErrors();\n }\n\n private updateHasErrors() {\n this.hasErrors = Array.from(this.errorStates.values()).some((error) => error);\n }\n\n render() {\n return (\n <div class='radio-button-group-container'>\n {this.showGroupLabel ? <div class='group-label'>{this.groupLabelText} *</div> : ''}\n <div class={`radio-button-group ${this.alignment} ${this.size}`}>\n <slot onSlotchange={this.handleSlotChange} ></slot>\n </div>\n {this.showCaption ? (\n <div class={`caption ${this.hasErrors ? 'error' : 'default'}`}>\n {this.showCaptionIcon ? <div class='caption-icon'><ifx-icon icon=\"c-info-16\">\n </ifx-icon></div> : ''}\n <div class='caption-text'>{this.captionText}</div>\n </div>) : ''}\n </div>\n );\n }\n}"],"mappings":"iIAAA,MAAMA,EAAsB,m1BAC5B,MAAAC,EAAeD,E,MCWFE,EAAgB,MAP7B,WAAAC,CAAAC,G,UAQYC,KAAAC,YAAyC,IAAIC,IAG7CF,KAAAG,UAAuC,WAGvCH,KAAAI,eAAyB,mBAIxBJ,KAAAK,UAAqB,MA4B9BL,KAAAM,iBAAmB,KACfN,KAAKO,iBAAiB,C,CA1B1B,sBAAAC,CAAuBC,GACnB,MAAMC,EAAcD,EAAME,OAC1B,GAAID,EAAYE,UAAY,mBAAoB,CAC5CZ,KAAKC,YAAYY,IAAIH,EAAaD,EAAMK,QACxCd,KAAKe,iB,EAMX,mBAAMC,CAAcC,GAClB,MAAMC,EAAeC,MAAMC,KAAKpB,KAAKqB,GAAGC,iBAAiB,qBACzDJ,EAAaK,SAASb,IACnBA,EAAoBO,MAAQA,CAAK,G,CAIxC,iBAAAO,GACI,IAAIC,EAAuBzB,KAAKqB,IAAK,CACjC,MAAMK,EAAYC,IAClBC,EAAe,yBAA0BF,E,CAE7C1B,KAAKO,iB,CAOD,eAAAA,GACJP,KAAKC,YAAY4B,QACjB,MAAMX,EAAeC,MAAMC,KAAKpB,KAAKqB,GAAGC,iBAAiB,qBACzDJ,EAAaK,SAASb,IAClB,IAAKV,KAAKC,YAAY6B,IAAIpB,GAAc,CACpCV,KAAKC,YAAYY,IAAIH,EAAcA,EAAoBO,OAAS,M,KAGxEjB,KAAKe,iB,CAGD,eAAAA,GACJf,KAAKK,UAAYc,MAAMC,KAAKpB,KAAKC,YAAY8B,UAAUC,MAAMf,GAAUA,G,CAG3E,MAAAgB,GACI,OACIC,EAAA,OAAAC,IAAA,2CAAKC,MAAM,gCACNpC,KAAKqC,eAAiBH,EAAA,OAAKE,MAAM,eAAepC,KAAKI,eAAc,MAAY,GAChF8B,EAAA,OAAAC,IAAA,2CAAKC,MAAO,sBAAsBpC,KAAKG,aAAaH,KAAKsC,QACrDJ,EAAA,QAAAC,IAAA,2CAAMI,aAAcvC,KAAKM,oBAE5BN,KAAKwC,YACFN,EAAA,OAAKE,MAAO,WAAWpC,KAAKK,UAAY,QAAU,aAC7CL,KAAKyC,gBAAkBP,EAAA,OAAKE,MAAM,gBAAeF,EAAA,YAAUQ,KAAK,eAC7C,GACpBR,EAAA,OAAKE,MAAM,gBAAgBpC,KAAK2C,cAC1B,G","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as i,h as o,a as t,g as a}from"./p-b7a462e5.js";import{d as n,t as e}from"./p-1de6e751.js";import{i as f}from"./p-1ecafb97.js";const r=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}.ifx-notification__wrapper{display:flex;flex-direction:row;align-items:center;padding:8px 16px;background-color:#FFFFFF;font-family:var(--ifx-font-family);color:#1D1D1D;border:1px solid #EEEDED}.ifx-notification__wrapper.ifx-notification__wrapper--success{border-left:4px solid #4CA460}.ifx-notification__wrapper.ifx-notification__wrapper--success .ifx-notification__icon{color:#4CA460}.ifx-notification__wrapper.ifx-notification__wrapper--locked{border-left:4px solid #E16B25}.ifx-notification__wrapper.ifx-notification__wrapper--locked .ifx-notification__icon{color:#E16B25}.ifx-notification__wrapper.ifx-notification__wrapper--error{border-left:4px solid #CD002F}.ifx-notification__wrapper.ifx-notification__wrapper--error .ifx-notification__icon{color:#CD002F}.ifx-notification__wrapper.ifx-notification__wrapper--neutral{border-left:4px solid #0A8276}.ifx-notification__wrapper.ifx-notification__wrapper--neutral .ifx-notification__icon{color:#0A8276}.ifx-notification__wrapper .ifx-notification__icon{margin-right:8px;display:flex;align-self:center}.ifx-notification__wrapper .ifx-notification__body{display:flex;flex-direction:row;flex-grow:1;font-size:0.875rem}.ifx-notification__wrapper .ifx-notification__body .ifx-notification__slot{flex-grow:1;display:inline-flex;align-items:center}.ifx-notification__wrapper .ifx-notification__link{font-size:0.875rem}@media (max-width: 576px){.ifx-notification__wrapper .ifx-notification__icon{align-self:flex-start}.ifx-notification__wrapper .ifx-notification__body{flex-direction:column}.ifx-notification__wrapper .ifx-notification__link{margin-top:8px}}';const c=r;const _=class{constructor(o){i(this,o);this.variant="success";this.linkTarget="_blank"}componentWillLoad(){if(!f(this.el)){const i=n();e("ifx-notification",{framework:i})}}getClassName(){switch(this.variant){case"success":return"ifx-notification__wrapper--success";case"locked":return"ifx-notification__wrapper--locked";case"error":return"ifx-notification__wrapper--error";case"neutral":return"ifx-notification__wrapper--neutral";default:return"ifx-notification__wrapper--success"}}render(){return o(t,{key:"a8883f3277991129cacf9ef1ec4eb9c75465ac60"},o("div",{key:"983419d2ac1d40a2d6b996662ada759671de91a1",class:"ifx-notification__wrapper "+this.getClassName()},o("div",{key:"ac24661674d950fb618b030cf52f42c3b8cd72b0",class:"ifx-notification__icon"},o("ifx-icon",{key:"63507ae856969e465cad9ce46259c0611f1ba0ae",icon:this.icon})),o("div",{key:"c000dc5e099e8328168b6c04ade316267fa08a15",class:"ifx-notification__body"},o("div",{key:"bca7b0101212433beb22e1d33b750798fae65a11",class:"ifx-notification__slot"},o("slot",{key:"ae218fa3c4c79d1628fc169ec58b1a189d87f407"})),this.linkText&&this.linkHref&&o("div",{key:"8e23cde71b571622e67f01744c63b9dda235ab4e",class:"ifx-notification__link"},o("ifx-link",{key:"cc3888fc3b8d1c2a7d7fab08282bf663eabce2e9",href:this.linkHref,target:this.linkTarget},this.linkText,o("ifx-icon",{key:"9695cd432d19b0ef0ebce0a5f3db0b007d2a09ea",icon:"arrow-right-16"}))))))}get el(){return a(this)}};_.style=c;export{_ as ifx_notification};
2
- //# sourceMappingURL=p-8514a92f.entry.js.map
1
+ import{r as i,h as o,a as t,g as f}from"./p-b7a462e5.js";import{d as a,t as n}from"./p-e48e9f36.js";import{i as e}from"./p-1ecafb97.js";const r=':root{--ifx-font-family:"Source Sans 3", "Arial, sans-serif"}.ifx-notification__wrapper{display:flex;flex-direction:row;align-items:center;padding:8px 16px;background-color:#FFFFFF;font-family:var(--ifx-font-family);color:#1D1D1D;border:1px solid #EEEDED}.ifx-notification__wrapper.ifx-notification__wrapper--success{border-left:4px solid #4CA460}.ifx-notification__wrapper.ifx-notification__wrapper--success .ifx-notification__icon{color:#4CA460}.ifx-notification__wrapper.ifx-notification__wrapper--locked{border-left:4px solid #E16B25}.ifx-notification__wrapper.ifx-notification__wrapper--locked .ifx-notification__icon{color:#E16B25}.ifx-notification__wrapper.ifx-notification__wrapper--error{border-left:4px solid #CD002F}.ifx-notification__wrapper.ifx-notification__wrapper--error .ifx-notification__icon{color:#CD002F}.ifx-notification__wrapper.ifx-notification__wrapper--neutral{border-left:4px solid #0A8276}.ifx-notification__wrapper.ifx-notification__wrapper--neutral .ifx-notification__icon{color:#0A8276}.ifx-notification__wrapper .ifx-notification__icon{margin-right:8px;display:flex;align-self:center}.ifx-notification__wrapper .ifx-notification__body{display:flex;flex-direction:row;flex-grow:1;font-size:0.875rem}.ifx-notification__wrapper .ifx-notification__body .ifx-notification__slot{flex-grow:1;display:inline-flex;align-items:center}.ifx-notification__wrapper .ifx-notification__link{font-size:0.875rem}@media (max-width: 576px){.ifx-notification__wrapper .ifx-notification__icon{align-self:flex-start}.ifx-notification__wrapper .ifx-notification__body{flex-direction:column}.ifx-notification__wrapper .ifx-notification__link{margin-top:8px}}';const c=r;const _=class{constructor(o){i(this,o);this.variant="success";this.linkTarget="_blank"}componentWillLoad(){if(!e(this.el)){const i=a();n("ifx-notification",i)}}getClassName(){switch(this.variant){case"success":return"ifx-notification__wrapper--success";case"locked":return"ifx-notification__wrapper--locked";case"error":return"ifx-notification__wrapper--error";case"neutral":return"ifx-notification__wrapper--neutral";default:return"ifx-notification__wrapper--success"}}render(){return o(t,{key:"c17bf027743a67188f8f2d5939c32d1291cd5d17"},o("div",{key:"5b94bafadb00ff880d921968aebabdc1dc4a046a",class:"ifx-notification__wrapper "+this.getClassName()},o("div",{key:"883a1fa61c49c3cb9851a76f0b6e6ab40e08a578",class:"ifx-notification__icon"},o("ifx-icon",{key:"966365d2eae1eaeaef8cdbd9c656d56cc6d09ee1",icon:this.icon})),o("div",{key:"50a4c1af8864397efd1cd7b7c04444fdb3860eaf",class:"ifx-notification__body"},o("div",{key:"587eddd49c9006fed4dcf588b0ba04f17ca88677",class:"ifx-notification__slot"},o("slot",{key:"83e4cac618bad6c4e0e52297214013cd8f6c268e"})),this.linkText&&this.linkHref&&o("div",{key:"5e477f0dbc503f0cff2fbe0c72673939e41f7222",class:"ifx-notification__link"},o("ifx-link",{key:"4609e684a086bacb401ba57f011f064679c5f094",href:this.linkHref,target:this.linkTarget},this.linkText,o("ifx-icon",{key:"2b9bce01568ad57abc570fbcfaf401380c97c8ba",icon:"arrow-right-16"}))))))}get el(){return f(this)}};_.style=c;export{_ as ifx_notification};
2
+ //# sourceMappingURL=p-e5c97dd1.entry.js.map