@testgorilla/tgo-ui 11.22.3 → 12.0.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 (225) hide show
  1. package/fesm2022/testgorilla-tgo-ui-components-accordion.mjs +335 -229
  2. package/fesm2022/testgorilla-tgo-ui-components-accordion.mjs.map +1 -1
  3. package/fesm2022/testgorilla-tgo-ui-components-ai-audio-circle.mjs +547 -465
  4. package/fesm2022/testgorilla-tgo-ui-components-ai-audio-circle.mjs.map +1 -1
  5. package/fesm2022/testgorilla-tgo-ui-components-ai-caveat.mjs +160 -75
  6. package/fesm2022/testgorilla-tgo-ui-components-ai-caveat.mjs.map +1 -1
  7. package/fesm2022/testgorilla-tgo-ui-components-ai-feedback.mjs +678 -278
  8. package/fesm2022/testgorilla-tgo-ui-components-ai-feedback.mjs.map +1 -1
  9. package/fesm2022/testgorilla-tgo-ui-components-alert-banner.mjs +337 -274
  10. package/fesm2022/testgorilla-tgo-ui-components-alert-banner.mjs.map +1 -1
  11. package/fesm2022/testgorilla-tgo-ui-components-audio-waveform.mjs +351 -192
  12. package/fesm2022/testgorilla-tgo-ui-components-audio-waveform.mjs.map +1 -1
  13. package/fesm2022/testgorilla-tgo-ui-components-autocomplete-v2.mjs +1950 -960
  14. package/fesm2022/testgorilla-tgo-ui-components-autocomplete-v2.mjs.map +1 -1
  15. package/fesm2022/testgorilla-tgo-ui-components-autocomplete.mjs +1206 -1044
  16. package/fesm2022/testgorilla-tgo-ui-components-autocomplete.mjs.map +1 -1
  17. package/fesm2022/testgorilla-tgo-ui-components-avatar.mjs +328 -182
  18. package/fesm2022/testgorilla-tgo-ui-components-avatar.mjs.map +1 -1
  19. package/fesm2022/testgorilla-tgo-ui-components-badge.mjs +383 -203
  20. package/fesm2022/testgorilla-tgo-ui-components-badge.mjs.map +1 -1
  21. package/fesm2022/testgorilla-tgo-ui-components-breadcrumb.mjs +553 -261
  22. package/fesm2022/testgorilla-tgo-ui-components-breadcrumb.mjs.map +1 -1
  23. package/fesm2022/testgorilla-tgo-ui-components-button.mjs +709 -739
  24. package/fesm2022/testgorilla-tgo-ui-components-button.mjs.map +1 -1
  25. package/fesm2022/testgorilla-tgo-ui-components-card.mjs +219 -184
  26. package/fesm2022/testgorilla-tgo-ui-components-card.mjs.map +1 -1
  27. package/fesm2022/testgorilla-tgo-ui-components-checkbox.mjs +515 -458
  28. package/fesm2022/testgorilla-tgo-ui-components-checkbox.mjs.map +1 -1
  29. package/fesm2022/testgorilla-tgo-ui-components-checklist.mjs +423 -162
  30. package/fesm2022/testgorilla-tgo-ui-components-checklist.mjs.map +1 -1
  31. package/fesm2022/testgorilla-tgo-ui-components-core.mjs +10784 -10996
  32. package/fesm2022/testgorilla-tgo-ui-components-core.mjs.map +1 -1
  33. package/fesm2022/testgorilla-tgo-ui-components-datepicker.mjs +810 -533
  34. package/fesm2022/testgorilla-tgo-ui-components-datepicker.mjs.map +1 -1
  35. package/fesm2022/testgorilla-tgo-ui-components-device-control.mjs +473 -116
  36. package/fesm2022/testgorilla-tgo-ui-components-device-control.mjs.map +1 -1
  37. package/fesm2022/testgorilla-tgo-ui-components-dialog.mjs +1149 -540
  38. package/fesm2022/testgorilla-tgo-ui-components-dialog.mjs.map +1 -1
  39. package/fesm2022/testgorilla-tgo-ui-components-divider.mjs +148 -84
  40. package/fesm2022/testgorilla-tgo-ui-components-divider.mjs.map +1 -1
  41. package/fesm2022/testgorilla-tgo-ui-components-donut-chart.mjs +239 -142
  42. package/fesm2022/testgorilla-tgo-ui-components-donut-chart.mjs.map +1 -1
  43. package/fesm2022/testgorilla-tgo-ui-components-dropdown.mjs +599 -467
  44. package/fesm2022/testgorilla-tgo-ui-components-dropdown.mjs.map +1 -1
  45. package/fesm2022/testgorilla-tgo-ui-components-elevation-shadow.mjs +126 -70
  46. package/fesm2022/testgorilla-tgo-ui-components-elevation-shadow.mjs.map +1 -1
  47. package/fesm2022/testgorilla-tgo-ui-components-empty-state.mjs +324 -329
  48. package/fesm2022/testgorilla-tgo-ui-components-empty-state.mjs.map +1 -1
  49. package/fesm2022/testgorilla-tgo-ui-components-field.mjs +969 -648
  50. package/fesm2022/testgorilla-tgo-ui-components-field.mjs.map +1 -1
  51. package/fesm2022/testgorilla-tgo-ui-components-file-upload.mjs +553 -419
  52. package/fesm2022/testgorilla-tgo-ui-components-file-upload.mjs.map +1 -1
  53. package/fesm2022/testgorilla-tgo-ui-components-filter-button.mjs +847 -452
  54. package/fesm2022/testgorilla-tgo-ui-components-filter-button.mjs.map +1 -1
  55. package/fesm2022/testgorilla-tgo-ui-components-gaussian-chart.mjs +398 -302
  56. package/fesm2022/testgorilla-tgo-ui-components-gaussian-chart.mjs.map +1 -1
  57. package/fesm2022/testgorilla-tgo-ui-components-icon-label.mjs +162 -95
  58. package/fesm2022/testgorilla-tgo-ui-components-icon-label.mjs.map +1 -1
  59. package/fesm2022/testgorilla-tgo-ui-components-icon.mjs +1825 -1795
  60. package/fesm2022/testgorilla-tgo-ui-components-icon.mjs.map +1 -1
  61. package/fesm2022/testgorilla-tgo-ui-components-infinite-scroll-table.mjs +1018 -672
  62. package/fesm2022/testgorilla-tgo-ui-components-infinite-scroll-table.mjs.map +1 -1
  63. package/fesm2022/testgorilla-tgo-ui-components-inline-field.mjs +758 -368
  64. package/fesm2022/testgorilla-tgo-ui-components-inline-field.mjs.map +1 -1
  65. package/fesm2022/testgorilla-tgo-ui-components-logo.mjs +204 -212
  66. package/fesm2022/testgorilla-tgo-ui-components-logo.mjs.map +1 -1
  67. package/fesm2022/testgorilla-tgo-ui-components-media-card.mjs +183 -48
  68. package/fesm2022/testgorilla-tgo-ui-components-media-card.mjs.map +1 -1
  69. package/fesm2022/testgorilla-tgo-ui-components-media-dialog.mjs +243 -79
  70. package/fesm2022/testgorilla-tgo-ui-components-media-dialog.mjs.map +1 -1
  71. package/fesm2022/testgorilla-tgo-ui-components-multi-input.mjs +751 -361
  72. package/fesm2022/testgorilla-tgo-ui-components-multi-input.mjs.map +1 -1
  73. package/fesm2022/testgorilla-tgo-ui-components-navbar.mjs +1122 -385
  74. package/fesm2022/testgorilla-tgo-ui-components-navbar.mjs.map +1 -1
  75. package/fesm2022/testgorilla-tgo-ui-components-overflow-menu.mjs +689 -413
  76. package/fesm2022/testgorilla-tgo-ui-components-overflow-menu.mjs.map +1 -1
  77. package/fesm2022/testgorilla-tgo-ui-components-page-header.mjs +227 -92
  78. package/fesm2022/testgorilla-tgo-ui-components-page-header.mjs.map +1 -1
  79. package/fesm2022/testgorilla-tgo-ui-components-paginator.mjs +174 -113
  80. package/fesm2022/testgorilla-tgo-ui-components-paginator.mjs.map +1 -1
  81. package/fesm2022/testgorilla-tgo-ui-components-password-criteria.mjs +367 -165
  82. package/fesm2022/testgorilla-tgo-ui-components-password-criteria.mjs.map +1 -1
  83. package/fesm2022/testgorilla-tgo-ui-components-password-strength.mjs +253 -118
  84. package/fesm2022/testgorilla-tgo-ui-components-password-strength.mjs.map +1 -1
  85. package/fesm2022/testgorilla-tgo-ui-components-phone-input.mjs +730 -444
  86. package/fesm2022/testgorilla-tgo-ui-components-phone-input.mjs.map +1 -1
  87. package/fesm2022/testgorilla-tgo-ui-components-popover.mjs +533 -221
  88. package/fesm2022/testgorilla-tgo-ui-components-popover.mjs.map +1 -1
  89. package/fesm2022/testgorilla-tgo-ui-components-popup-tip.mjs +274 -76
  90. package/fesm2022/testgorilla-tgo-ui-components-popup-tip.mjs.map +1 -1
  91. package/fesm2022/testgorilla-tgo-ui-components-progress-bar.mjs +184 -124
  92. package/fesm2022/testgorilla-tgo-ui-components-progress-bar.mjs.map +1 -1
  93. package/fesm2022/testgorilla-tgo-ui-components-prompt.mjs +1223 -574
  94. package/fesm2022/testgorilla-tgo-ui-components-prompt.mjs.map +1 -1
  95. package/fesm2022/testgorilla-tgo-ui-components-radial-progress.mjs +249 -160
  96. package/fesm2022/testgorilla-tgo-ui-components-radial-progress.mjs.map +1 -1
  97. package/fesm2022/testgorilla-tgo-ui-components-radio-button.mjs +447 -439
  98. package/fesm2022/testgorilla-tgo-ui-components-radio-button.mjs.map +1 -1
  99. package/fesm2022/testgorilla-tgo-ui-components-rating.mjs +226 -150
  100. package/fesm2022/testgorilla-tgo-ui-components-rating.mjs.map +1 -1
  101. package/fesm2022/testgorilla-tgo-ui-components-scale-table.mjs +255 -67
  102. package/fesm2022/testgorilla-tgo-ui-components-scale-table.mjs.map +1 -1
  103. package/fesm2022/testgorilla-tgo-ui-components-scale.mjs +205 -162
  104. package/fesm2022/testgorilla-tgo-ui-components-scale.mjs.map +1 -1
  105. package/fesm2022/testgorilla-tgo-ui-components-segmented-bar.mjs +245 -153
  106. package/fesm2022/testgorilla-tgo-ui-components-segmented-bar.mjs.map +1 -1
  107. package/fesm2022/testgorilla-tgo-ui-components-segmented-button.mjs +274 -140
  108. package/fesm2022/testgorilla-tgo-ui-components-segmented-button.mjs.map +1 -1
  109. package/fesm2022/testgorilla-tgo-ui-components-segmented-toggle.mjs +319 -147
  110. package/fesm2022/testgorilla-tgo-ui-components-segmented-toggle.mjs.map +1 -1
  111. package/fesm2022/testgorilla-tgo-ui-components-selectable-card.mjs +286 -84
  112. package/fesm2022/testgorilla-tgo-ui-components-selectable-card.mjs.map +1 -1
  113. package/fesm2022/testgorilla-tgo-ui-components-side-navigation.mjs +660 -208
  114. package/fesm2022/testgorilla-tgo-ui-components-side-navigation.mjs.map +1 -1
  115. package/fesm2022/testgorilla-tgo-ui-components-side-panel.mjs +579 -320
  116. package/fesm2022/testgorilla-tgo-ui-components-side-panel.mjs.map +1 -1
  117. package/fesm2022/testgorilla-tgo-ui-components-side-sheet.mjs +419 -200
  118. package/fesm2022/testgorilla-tgo-ui-components-side-sheet.mjs.map +1 -1
  119. package/fesm2022/testgorilla-tgo-ui-components-skeleton.mjs +132 -80
  120. package/fesm2022/testgorilla-tgo-ui-components-skeleton.mjs.map +1 -1
  121. package/fesm2022/testgorilla-tgo-ui-components-slider.mjs +741 -390
  122. package/fesm2022/testgorilla-tgo-ui-components-slider.mjs.map +1 -1
  123. package/fesm2022/testgorilla-tgo-ui-components-snackbar.mjs +455 -329
  124. package/fesm2022/testgorilla-tgo-ui-components-snackbar.mjs.map +1 -1
  125. package/fesm2022/testgorilla-tgo-ui-components-spider-chart.mjs +543 -514
  126. package/fesm2022/testgorilla-tgo-ui-components-spider-chart.mjs.map +1 -1
  127. package/fesm2022/testgorilla-tgo-ui-components-spinner.mjs +193 -104
  128. package/fesm2022/testgorilla-tgo-ui-components-spinner.mjs.map +1 -1
  129. package/fesm2022/testgorilla-tgo-ui-components-stepper.mjs +760 -524
  130. package/fesm2022/testgorilla-tgo-ui-components-stepper.mjs.map +1 -1
  131. package/fesm2022/testgorilla-tgo-ui-components-table.mjs +714 -415
  132. package/fesm2022/testgorilla-tgo-ui-components-table.mjs.map +1 -1
  133. package/fesm2022/testgorilla-tgo-ui-components-tabs.mjs +847 -438
  134. package/fesm2022/testgorilla-tgo-ui-components-tabs.mjs.map +1 -1
  135. package/fesm2022/testgorilla-tgo-ui-components-tag.mjs +535 -275
  136. package/fesm2022/testgorilla-tgo-ui-components-tag.mjs.map +1 -1
  137. package/fesm2022/testgorilla-tgo-ui-components-toggle.mjs +316 -246
  138. package/fesm2022/testgorilla-tgo-ui-components-toggle.mjs.map +1 -1
  139. package/fesm2022/testgorilla-tgo-ui-components-tooltip.mjs +404 -284
  140. package/fesm2022/testgorilla-tgo-ui-components-tooltip.mjs.map +1 -1
  141. package/fesm2022/testgorilla-tgo-ui-components-universal-skills.mjs +664 -383
  142. package/fesm2022/testgorilla-tgo-ui-components-universal-skills.mjs.map +1 -1
  143. package/fesm2022/testgorilla-tgo-ui-components-validation-error.mjs +201 -112
  144. package/fesm2022/testgorilla-tgo-ui-components-validation-error.mjs.map +1 -1
  145. package/fesm2022/testgorilla-tgo-ui-components-write-with-ai.mjs +1014 -458
  146. package/fesm2022/testgorilla-tgo-ui-components-write-with-ai.mjs.map +1 -1
  147. package/fesm2022/testgorilla-tgo-ui.mjs +147 -155
  148. package/fesm2022/testgorilla-tgo-ui.mjs.map +1 -1
  149. package/mcp/catalog.json +1 -1
  150. package/package.json +16 -17
  151. package/projects/tgo-canopy-ui/theme/_palette.scss +23 -18
  152. package/types/testgorilla-tgo-ui-components-accordion.d.ts +214 -158
  153. package/types/testgorilla-tgo-ui-components-ai-audio-circle.d.ts +93 -69
  154. package/types/testgorilla-tgo-ui-components-ai-caveat.d.ts +37 -34
  155. package/types/testgorilla-tgo-ui-components-ai-feedback.d.ts +126 -86
  156. package/types/testgorilla-tgo-ui-components-alert-banner.d.ts +260 -185
  157. package/types/testgorilla-tgo-ui-components-audio-waveform.d.ts +96 -67
  158. package/types/testgorilla-tgo-ui-components-autocomplete-v2.d.ts +455 -256
  159. package/types/testgorilla-tgo-ui-components-autocomplete.d.ts +545 -390
  160. package/types/testgorilla-tgo-ui-components-avatar.d.ts +128 -102
  161. package/types/testgorilla-tgo-ui-components-badge.d.ts +191 -139
  162. package/types/testgorilla-tgo-ui-components-breadcrumb.d.ts +100 -62
  163. package/types/testgorilla-tgo-ui-components-button.d.ts +479 -340
  164. package/types/testgorilla-tgo-ui-components-card.d.ts +153 -114
  165. package/types/testgorilla-tgo-ui-components-checkbox.d.ts +299 -223
  166. package/types/testgorilla-tgo-ui-components-checklist.d.ts +149 -97
  167. package/types/testgorilla-tgo-ui-components-core.d.ts +307 -295
  168. package/types/testgorilla-tgo-ui-components-datepicker.d.ts +404 -299
  169. package/types/testgorilla-tgo-ui-components-device-control.d.ts +151 -81
  170. package/types/testgorilla-tgo-ui-components-dialog.d.ts +442 -329
  171. package/types/testgorilla-tgo-ui-components-divider.d.ts +64 -51
  172. package/types/testgorilla-tgo-ui-components-donut-chart.d.ts +41 -37
  173. package/types/testgorilla-tgo-ui-components-dropdown.d.ts +335 -241
  174. package/types/testgorilla-tgo-ui-components-elevation-shadow.d.ts +48 -43
  175. package/types/testgorilla-tgo-ui-components-empty-state.d.ts +317 -215
  176. package/types/testgorilla-tgo-ui-components-field.d.ts +559 -388
  177. package/types/testgorilla-tgo-ui-components-file-upload.d.ts +230 -168
  178. package/types/testgorilla-tgo-ui-components-filter-button.d.ts +263 -206
  179. package/types/testgorilla-tgo-ui-components-gaussian-chart.d.ts +107 -94
  180. package/types/testgorilla-tgo-ui-components-icon-label.d.ts +84 -61
  181. package/types/testgorilla-tgo-ui-components-icon.d.ts +137 -110
  182. package/types/testgorilla-tgo-ui-components-infinite-scroll-table.d.ts +429 -303
  183. package/types/testgorilla-tgo-ui-components-inline-field.d.ts +338 -254
  184. package/types/testgorilla-tgo-ui-components-logo.d.ts +119 -101
  185. package/types/testgorilla-tgo-ui-components-media-card.d.ts +51 -35
  186. package/types/testgorilla-tgo-ui-components-media-dialog.d.ts +40 -45
  187. package/types/testgorilla-tgo-ui-components-multi-input.d.ts +283 -194
  188. package/types/testgorilla-tgo-ui-components-navbar.d.ts +326 -208
  189. package/types/testgorilla-tgo-ui-components-overflow-menu.d.ts +276 -204
  190. package/types/testgorilla-tgo-ui-components-page-header.d.ts +67 -50
  191. package/types/testgorilla-tgo-ui-components-paginator.d.ts +103 -70
  192. package/types/testgorilla-tgo-ui-components-password-criteria.d.ts +67 -58
  193. package/types/testgorilla-tgo-ui-components-password-strength.d.ts +66 -57
  194. package/types/testgorilla-tgo-ui-components-phone-input.d.ts +217 -175
  195. package/types/testgorilla-tgo-ui-components-popover.d.ts +94 -53
  196. package/types/testgorilla-tgo-ui-components-popup-tip.d.ts +81 -44
  197. package/types/testgorilla-tgo-ui-components-progress-bar.d.ts +115 -84
  198. package/types/testgorilla-tgo-ui-components-prompt.d.ts +315 -219
  199. package/types/testgorilla-tgo-ui-components-radial-progress.d.ts +146 -107
  200. package/types/testgorilla-tgo-ui-components-radio-button.d.ts +296 -219
  201. package/types/testgorilla-tgo-ui-components-rating.d.ts +134 -95
  202. package/types/testgorilla-tgo-ui-components-scale-table.d.ts +67 -47
  203. package/types/testgorilla-tgo-ui-components-scale.d.ts +91 -66
  204. package/types/testgorilla-tgo-ui-components-segmented-bar.d.ts +118 -89
  205. package/types/testgorilla-tgo-ui-components-segmented-button.d.ts +107 -80
  206. package/types/testgorilla-tgo-ui-components-segmented-toggle.d.ts +138 -105
  207. package/types/testgorilla-tgo-ui-components-selectable-card.d.ts +90 -56
  208. package/types/testgorilla-tgo-ui-components-side-navigation.d.ts +183 -107
  209. package/types/testgorilla-tgo-ui-components-side-panel.d.ts +156 -145
  210. package/types/testgorilla-tgo-ui-components-side-sheet.d.ts +98 -89
  211. package/types/testgorilla-tgo-ui-components-skeleton.d.ts +50 -33
  212. package/types/testgorilla-tgo-ui-components-slider.d.ts +278 -198
  213. package/types/testgorilla-tgo-ui-components-snackbar.d.ts +211 -159
  214. package/types/testgorilla-tgo-ui-components-spider-chart.d.ts +140 -121
  215. package/types/testgorilla-tgo-ui-components-spinner.d.ts +93 -72
  216. package/types/testgorilla-tgo-ui-components-stepper.d.ts +480 -338
  217. package/types/testgorilla-tgo-ui-components-table.d.ts +280 -233
  218. package/types/testgorilla-tgo-ui-components-tabs.d.ts +282 -183
  219. package/types/testgorilla-tgo-ui-components-tag.d.ts +266 -193
  220. package/types/testgorilla-tgo-ui-components-toggle.d.ts +180 -132
  221. package/types/testgorilla-tgo-ui-components-tooltip.d.ts +142 -105
  222. package/types/testgorilla-tgo-ui-components-universal-skills.d.ts +165 -144
  223. package/types/testgorilla-tgo-ui-components-validation-error.d.ts +70 -51
  224. package/types/testgorilla-tgo-ui-components-write-with-ai.d.ts +210 -133
  225. package/types/testgorilla-tgo-ui.d.ts +52 -45
@@ -1 +1 @@
1
- {"version":3,"file":"testgorilla-tgo-ui-components-button.mjs","sources":["../../../components/button/color-contrast.ts","../../../components/button/button.component.ts","../../../components/button/button.component.html","../../../components/button/button.component.module.ts","../../../components/button/testgorilla-tgo-ui-components-button.ts"],"sourcesContent":["/**\n * Function for adjusting the lightness of a color based on different events (hover, pressed, disabled).\n * Accepts a hex color, transforms it to HSL, and based on color's L and event darkens or lightens it.\n * Used to manage different colors based on application configuration\n *\n * @param hexColor color in hex format\n * @param typeEvent interaction event\n * @param theme\n */\ntype LightnessEvent = 'hover' | 'pressed' | 'disabled';\n\n/** Lightness band of a colour, in percent. `null` = exactly on a 30/70 boundary (no adjustment). */\nconst lightnessBand = (lightness: number): 'high' | 'low' | 'mid' | null => {\n if (lightness > 70) {\n return 'high';\n }\n if (lightness < 30) {\n return 'low';\n }\n if (lightness < 70 && lightness > 30) {\n return 'mid';\n }\n return null;\n};\n\n/** Lightness delta (in percent points) for the `new` theme. */\nconst getNewThemeDelta = (lightness: number, typeEvent: LightnessEvent): number => {\n if (typeEvent !== 'hover' && typeEvent !== 'pressed') {\n return 0;\n }\n const band = lightnessBand(lightness);\n return band === 'low' ? 10 : band ? -10 : 0;\n};\n\n/** Lightness delta (in percent points) for the `classic` theme. */\nconst getClassicThemeDelta = (lightness: number, typeEvent: LightnessEvent): number => {\n const deltasByEvent: Record<LightnessEvent, { high: number; low: number; mid: number }> = {\n hover: { high: -10, low: 10, mid: -10 },\n pressed: { high: -20, low: 30, mid: -20 },\n disabled: { high: 10, low: 50, mid: 20 },\n };\n const band = lightnessBand(lightness);\n if (!band) {\n return 0;\n }\n // typeEvent is LightnessEvent at compile time, but callers may pass an\n // out-of-range button state at runtime (matches the original no-op behaviour).\n const eventDeltas: { high: number; low: number; mid: number } | undefined = deltasByEvent[typeEvent];\n return eventDeltas ? eventDeltas[band] : 0;\n};\n\nexport const adjustLightness = (\n hexColor: string,\n typeEvent: LightnessEvent,\n theme: 'new' | 'classic' = 'new'\n): string => {\n const hexRegex = /^#(?:[0-9A-F]{3}|[0-9A-F]{6})$/i;\n if (hexColor && !hexRegex.test(hexColor)) {\n throw new Error('Invalid HEX color format');\n }\n\n const hslColor = hexToHsl(hexColor);\n const lightness = hslColor.l * 100;\n const delta = theme === 'new' ? getNewThemeDelta(lightness, typeEvent) : getClassicThemeDelta(lightness, typeEvent);\n hslColor.l = clamp(hslColor.l + delta / 100);\n\n return hslToHex(hslColor);\n};\n\n/**\n * Transforms hex color to HSL in object variation.\n * @param hexColor string value with hex color\n */\nexport const hexToHsl = (hexColor: string): { h: number; s: number; l: number } => {\n const rgbColor = parseInt(hexColor.slice(1), 16);\n /* eslint-disable no-bitwise -- standard RGB channel extraction from a packed 24-bit integer */\n const r = ((rgbColor >> 16) & 255) / 255;\n const g = ((rgbColor >> 8) & 255) / 255;\n const b = (rgbColor & 255) / 255;\n /* eslint-enable no-bitwise */\n\n const max = Math.max(r, g, b);\n const min = Math.min(r, g, b);\n\n let h = 0;\n let s;\n const l = (max + min) / 2;\n\n if (max === min) {\n h = s = 0; // grayscale\n } else {\n const d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n\n h /= 6;\n }\n\n return { h, s, l };\n};\n\n/**\n * Transforms HSL color, represented as an object and transforms it to hex string.\n * @param hslColor accepts the HSL color like an object.\n */\nexport const hslToHex = (hslColor: { h: number; s: number; l: number }): string => {\n const { h, s, l } = hslColor;\n\n const hueToRgb = (p: number, q: number, t: number): number => {\n let tNorm = t;\n if (tNorm < 0) {\n tNorm += 1;\n }\n if (tNorm > 1) {\n tNorm -= 1;\n }\n if (tNorm < 1 / 6) {\n return p + (q - p) * 6 * tNorm;\n }\n if (tNorm < 1 / 2) {\n return q;\n }\n if (tNorm < 2 / 3) {\n return p + (q - p) * (2 / 3 - tNorm) * 6;\n }\n return p;\n };\n\n const qBase = l < 0.5 ? l * (1 + s) : l + s - l * s;\n const pBase = 2 * l - qBase;\n\n const r = hueToRgb(pBase, qBase, h + 1 / 3);\n const g = hueToRgb(pBase, qBase, h);\n const b = hueToRgb(pBase, qBase, h - 1 / 3);\n\n // eslint-disable-next-line no-bitwise -- standard RGB channel packing into a 24-bit integer\n const rgbColor = (Math.round(r * 255) << 16) | (Math.round(g * 255) << 8) | Math.round(b * 255);\n\n return `#${rgbColor.toString(16).padStart(6, '0')}`;\n};\n\n/**\n * Restricts the value to be within the range [0, 1].\n * @param value\n */\nconst clamp = (value: number): number => Math.min(Math.max(value, 0), 1);\n","/* eslint-disable @angular-eslint/use-lifecycle-interface */\nimport { FocusOrigin } from '@angular/cdk/a11y';\nimport { NgClass, NgStyle, AsyncPipe } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n AfterViewInit,\n booleanAttribute,\n Component,\n ElementRef,\n EventEmitter,\n HostBinding,\n Inject,\n Input,\n OnInit,\n Optional,\n Output,\n SimpleChanges,\n ViewChild,\n} from '@angular/core';\nimport { MatButton } from '@angular/material/button';\nimport { MatProgressSpinner } from '@angular/material/progress-spinner';\nimport { TooltipPosition, MatTooltip } from '@angular/material/tooltip';\n\nimport { BadgeComponent } from '@testgorilla/tgo-ui/components/badge';\nimport { ApplicationTheme, Color, EllipseTextDirective, UiTranslatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { IconName, IconComponentModule, tgoIcons, tgoRebrandIcons } from '@testgorilla/tgo-ui/components/icon';\n\nimport {\n ButtonBadgeConfig,\n ButtonColor,\n ButtonIconPosition,\n ButtonSize,\n ButtonState,\n ButtonType,\n IconButtonSize,\n LinkUrlTarget,\n} from './button.model';\nimport { adjustLightness } from './color-contrast';\n\n@Component({\n selector: 'ui-button',\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './button.component.html',\n styleUrls: ['./button.component.scss'],\n imports: [\n MatTooltip,\n NgClass,\n BadgeComponent,\n MatButton,\n NgStyle,\n MatProgressSpinner,\n IconComponentModule,\n EllipseTextDirective,\n AsyncPipe,\n UiTranslatePipe,\n ],\n})\nexport class ButtonComponent implements OnInit, AfterViewInit {\n @HostBinding('style.pointer-events')\n get enabled(): string {\n return this.disabled ? 'none' : 'all';\n }\n\n @ViewChild('tooltipElement') tooltipElement: ElementRef<HTMLElement>;\n\n /**\n * Define button height\n *\n * @type {ButtonSize}\n * @memberof ButtonComponent\n */\n @Input() size: ButtonSize = 'big';\n /**\n * Background color of the button while in active state\n *\n * @type {ButtonColor}\n * @memberof ButtonComponent\n */\n @HostBinding('attr.btn-variant')\n @Input()\n variant: ButtonColor = 'primary';\n\n /**\n * Text content to appear on the button\n *\n * @memberof ButtonComponent\n */\n @Input() label = '';\n\n /**\n * Positioning of the icon (when existant)\n *\n * @type {ButtonIconPosition}\n * @memberof ButtonComponent\n */\n @Input() iconPosition?: ButtonIconPosition = 'right';\n\n /**\n * Define if button has only icon without text\n *\n * @memberof ButtonComponent\n */\n @Input() justIcon = false;\n\n /**\n * Name of ui-icon\n *\n * @type {IconName}\n * @memberof ButtonComponent\n */\n @Input() iconName: IconName | undefined;\n\n /**\n * Name of a second ui-icon rendered after the label, in addition to `iconName`.\n * Pair it with `iconPosition=\"left\"` to show a leading and a trailing icon at once.\n *\n * @type {IconName}\n * @memberof ButtonComponent\n */\n @Input() trailingIconName: IconName | undefined;\n\n /**\n * Renders the trailing icon filled, independently of `iconFilled`.\n *\n * @memberof ButtonComponent\n */\n @Input() trailingIconFilled = false;\n\n /**\n * Indicator if the button should be disabled\n *\n * @memberof ButtonComponent\n */\n @Input() disabled = false;\n\n /**\n * Indicator if the loading icon should be shown\n *\n * @memberof ButtonComponent\n */\n @Input() loading = false;\n\n /**\n * Show a small inline spinner to the left of the label while keeping the\n * label visible. Pair with `disabled` to make the button non-interactive.\n * If `loading` is also true, `loading` takes precedence.\n *\n * @memberof ButtonComponent\n */\n @Input() loadingWithLabel = false;\n\n /**\n * Indicator of the button width\n *\n * @memberof ButtonComponent\n */\n @Input() fullWidth = false;\n\n /**\n * Url of button if it is a link\n *\n * @memberof ButtonComponent\n */\n @Input() url?: string;\n\n /**\n * Url's target of button if it is a link\n *\n * @type {@type {LinkUrlTarget}}\n * @memberof ButtonComponent\n */\n @Input() urlTarget?: LinkUrlTarget;\n\n /**\n * Button value\n *\n * @memberof ButtonComponent\n */\n @Input() value?: string;\n\n /**\n * @property tooltip\n * @description The tooltip that is displayed on hover. Required for icon-button type\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() tooltip = '';\n\n /**\n * @property isPremium\n * @description The icon that is displayed for Premium button\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() isPremium = false;\n\n /**\n * The type of the button.\n *\n * @type {ButtonType}\n * @memberof ButtonComponent\n * @default 'button'\n */\n @Input() type: ButtonType = 'button';\n\n /**\n * Color of the button.\n * Defaults to Test Gorilla primary color.\n *\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() companyColor: string | null = '';\n\n /**\n * Config for the button badge variation\n * @type {ButtonBadgeConfig}\n * @property badgeType Type of badge on the button\n * @property badgeLabel Label text for the badge\n * @property badgeNotificationAmount The amount for notification in the badge\n */\n @Input() buttonBadgeConfig: ButtonBadgeConfig | undefined;\n\n /**\n *\n * Defines the application theme where buttons is used\n *\n * @type {ApplicationTheme}\n * @memberof ButtonComponent\n */\n @HostBinding('attr.theme')\n @Input()\n applicationTheme: ApplicationTheme = 'light';\n\n /** The premium marker reads as the warning badge does, so the two are recognisably the same signal. */\n protected readonly premiumMarkerColor = Color.BLACK;\n\n /**\n *\n * Disabled button scale on click\n *\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() disabledScaleOnClick = false;\n\n /**\n * A string representing the ARIA label for accessibility.\n * This label is used to provide an accessible name for the input element.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaLabel: string;\n\n /**\n * Whether the button controls a disclosure widget that is currently expanded.\n * Set to `true` for an expanded disclosure, `false` for collapsed, or leave\n * undefined when the button is not a disclosure trigger.\n * @memberof ButtonComponent\n */\n @Input() ariaExpanded?: boolean;\n\n /**\n * The id of the element controlled by this button (used together with\n * `ariaExpanded` for disclosure semantics).\n * @memberof ButtonComponent\n */\n @Input() ariaControls?: string;\n\n /**\n * Whether the button is a toggle button currently in the pressed state.\n * Use `true` / `false` for two-state toggles. Leave undefined when the\n * button is not a toggle.\n * @memberof ButtonComponent\n */\n @Input() ariaPressed?: boolean;\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() ariaRequired = false;\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaLabelledby = '';\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaDescribedby = '';\n\n /**\n * Prevents default button click behavior\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input({ transform: booleanAttribute }) preventDefault = false;\n\n /**\n * Ghost variant with white background\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input({ transform: booleanAttribute }) hasBackground = false;\n\n /**\n * Sets tooltip position\n *\n * @type {TooltipPosition}\n * @memberof ButtonComponent\n */\n @Input() tooltipPosition: TooltipPosition = 'below';\n\n @Input() role = 'button';\n\n @Input() iconFilled = false;\n\n @Input() testId: string | null = null;\n\n @Output() buttonClickEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n @Output() buttonHoverEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n @ViewChild('buttonElement', { static: false }) buttonElement: MatButton;\n\n get isDisabled(): boolean {\n return this.disabled;\n }\n\n @HostBinding('style.--color')\n get compColor() {\n return this.getCompanyColor;\n }\n\n classCss: string;\n styleCss: Record<string, string>;\n isButtonLink: boolean;\n isLabel: boolean;\n buttonState: ButtonState;\n hover = false;\n iconButtonSize: IconButtonSize = '40';\n allowButtonTypeForPremium: ButtonColor[] = [\n 'secondary',\n 'secondary-inverted',\n 'primary',\n 'ghost',\n 'outlined',\n 'destructive',\n 'icon-button',\n ];\n isFilledIcon: boolean;\n coloredIcons = ['Google-in-line', 'Google', 'Google-filled', 'Linkedin-brand-filled', 'Linkedin-brand-in-line'];\n labelEllipsis = false;\n icon: IconName = '';\n trailingIcon: IconName = '';\n\n private static nextAriaLabelledId = 0;\n ariaLabelledbyId = '';\n\n get typeIncluded(): boolean {\n return this.allowButtonTypeForPremium.includes(this.variant);\n }\n\n constructor(\n @Optional() @Inject('CANOPYUI_DEFAULT_APPLICATION_THEME') private readonly defaultAppTheme: ApplicationTheme\n ) {\n if (defaultAppTheme) {\n this.applicationTheme = defaultAppTheme;\n }\n }\n\n ngOnInit(): void {\n this.classCss = this.setCssClass();\n this.styleCss = this.setCssStyle();\n this.isButtonLink = this.showButtonLink();\n this.isLabel = this.showLabel();\n this.createAriaLabelledById();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes['disabled']) {\n this.buttonState = 'default';\n }\n if (!this.applicationTheme) {\n this.applicationTheme = 'light';\n }\n if (changes['type']) {\n this.isButtonLink = this.showButtonLink();\n }\n if (changes['loading']) {\n this.isLabel = this.showLabel();\n }\n if (changes['iconName']) {\n this.icon = changes['iconName'].currentValue as IconName;\n }\n if (changes['trailingIconName']) {\n this.trailingIcon = changes['trailingIconName'].currentValue as IconName;\n }\n if (this.hasCssAffectingChange(changes)) {\n this.classCss = this.setCssClass();\n this.styleCss = this.setCssStyle();\n }\n if (this.isIconButtonSizeChange(changes)) {\n this.iconButtonSize = this.setIconButtonSize();\n }\n\n this.isFilledIcon = this.isFilledIconVariant();\n }\n\n private hasCssAffectingChange(changes: SimpleChanges): boolean {\n return Boolean(\n changes['type'] ||\n changes['fullWidth'] ||\n changes['iconName'] ||\n changes['trailingIconName'] ||\n changes['trailingIconFilled'] ||\n changes['justIcon'] ||\n changes['iconPosition'] ||\n changes['disabled'] ||\n changes['companyColor'] ||\n changes['variant'] ||\n changes['applicationTheme']\n );\n }\n\n private isIconButtonSizeChange(changes: SimpleChanges): boolean {\n return (\n changes['variant']?.currentValue === 'icon-button' ||\n (changes['variant']?.currentValue === 'menuTrigger' && this.applicationTheme !== 'classic')\n );\n }\n\n private isFilledIconVariant(): boolean {\n return (\n this.applicationTheme !== 'classic' &&\n (this.variant === 'primary' ||\n this.variant === 'secondary' ||\n this.variant === 'secondary-inverted' ||\n this.variant === 'linkedin')\n );\n }\n\n ngAfterViewInit(): void {\n this.tooltipElement.nativeElement.onclick = ev => {\n ev.preventDefault();\n ev.stopPropagation();\n };\n }\n\n buttonClick(event: Event): void {\n if (this.preventDefault) {\n event.preventDefault();\n event.stopPropagation();\n }\n this.buttonClickEvent.emit(event);\n }\n\n buttonHover(event: Event): void {\n if (event.type === 'mouseenter') {\n this.hover = true;\n this.buttonHoverEvent.emit(event);\n this.buttonState = 'hover';\n if (this.shouldChangeFilledStatus && this.icon) {\n this.icon = this.getIconName(this.iconName as IconName, '-filled');\n }\n if (this.trailingIcon && this.canToggleFilled(this.trailingIcon)) {\n this.trailingIcon = this.getIconName(this.trailingIconName as IconName, '-filled');\n }\n } else {\n this.hover = false;\n if (this.shouldChangeFilledStatus && this.icon) {\n this.icon = this.iconName as IconName;\n }\n if (this.trailingIcon && this.canToggleFilled(this.trailingIcon)) {\n this.trailingIcon = this.trailingIconName as IconName;\n }\n this.buttonState = 'default';\n }\n\n this.styleCss = this.setCssStyle();\n }\n\n //Show or hide label\n showLabel(): boolean {\n return !this.loading;\n }\n\n //Set css class according inputs\n setCssClass(): string {\n const width = this.fullWidth ? 'full-width' : '';\n const hasIcon = this.iconName === null ? '' : 'icon';\n const justIcon = this.justIcon || this.variant === 'icon-button' ? 'only-icon' : '';\n const iconPosition = this.iconPosition ?? '';\n const disabled = this.disabled && this.variant === 'primary' ? 'primary-disabled' : '';\n const variant = this.variant === 'ghost' && this.applicationTheme === 'classic' ? 'outlined' : this.variant;\n const companyColor = this.companyColor ? 'has-company-color' : '';\n return `${this.size} ${iconPosition} ${variant} ${width} ${hasIcon} ${justIcon} ${disabled} ${companyColor} ${this.applicationTheme}-theme`;\n }\n\n setCssStyle(): Record<string, string> {\n this.buttonState = this.disabled ? 'disabled' : this.buttonState;\n return (\n this.getInteractiveStyle() ??\n this.getClassicInteractiveStyle() ??\n this.getCompanyColorStyle() ??\n this.getGhostBackgroundStyle() ??\n {}\n );\n }\n\n private get isColorVariant(): boolean {\n return this.variant === 'primary' || this.variant === 'text' || this.variant === 'text-inline';\n }\n\n private get isTextVariant(): boolean {\n return this.variant === 'text' || this.variant === 'text-inline';\n }\n\n private getInteractiveStyle(): Record<string, string> | null {\n if (this.buttonState !== 'hover' && this.buttonState !== 'pressed') {\n return null;\n }\n if (!this.isColorVariant || this.applicationTheme === 'classic') {\n return null;\n }\n const styleObj: Record<string, string> = {};\n styleObj[this.variant === 'primary' ? 'background-color' : 'color'] = adjustLightness(\n this.getCompanyColor,\n this.buttonState\n );\n if (this.isTextVariant) {\n styleObj['--active-color'] = this.companyColor\n ? adjustLightness(this.getCompanyColor, this.buttonState)\n : '#666666';\n }\n return styleObj;\n }\n\n private getClassicInteractiveStyle(): Record<string, string> | null {\n if (this.buttonState === 'default') {\n return null;\n }\n if (!this.isColorVariant || this.applicationTheme !== 'classic') {\n return null;\n }\n return {\n [this.variant === 'primary' ? 'background-color' : 'color']: adjustLightness(\n this.getCompanyColor,\n this.buttonState,\n 'classic'\n ),\n };\n }\n\n private getCompanyColorStyle(): Record<string, string> | null {\n const isCompanyColorVariant =\n this.variant === 'link' || this.variant === 'tertiary' || this.variant === 'icon-button';\n if (!(this.getCompanyColor && isCompanyColorVariant)) {\n return null;\n }\n return { color: this.getCompanyColor };\n }\n\n private getGhostBackgroundStyle(): Record<string, string> | null {\n return this.hasBackground ? { '--ghost-background': '#ffffff' } : null;\n }\n\n //Show or hide spinner\n get showSpinner(): boolean {\n const isNotTab = this.variant !== 'tab';\n const isNotLink = this.variant !== 'link';\n const isLoading = this.loading === true;\n return isLoading && isNotTab && isNotLink;\n }\n\n //Show or hide the inline spinner that sits next to the label\n get showInlineSpinner(): boolean {\n return (\n this.loadingWithLabel && !this.loading && this.variant !== 'tab' && this.variant !== 'link' && !this.justIcon\n );\n }\n\n //Show button with <button> or <a> tag\n showButtonLink(): boolean {\n return this.variant !== 'link';\n }\n\n setIconButtonSize(): IconButtonSize {\n return this.size === 'big' ? '40' : this.size === 'small' ? '24' : '32';\n }\n\n onPressed(ev: Event): void {\n if (ev.type === 'mousedown') {\n this.buttonState = 'pressed';\n } else {\n this.buttonState = this.hover ? 'hover' : 'default';\n }\n\n this.styleCss = this.setCssStyle();\n }\n\n focus(origin?: FocusOrigin): void {\n this.buttonElement.focus(origin);\n }\n\n get getCompanyColor(): string {\n return (\n // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing -- empty companyColor ('' is the default) falls back to the theme colour\n this.companyColor ||\n (this.variant === 'text' || this.variant === 'text-inline'\n ? this.applicationTheme === 'dark'\n ? '#ffffff'\n : '#242424'\n : this.applicationTheme === 'classic'\n ? '#46A997'\n : '#D410AA')\n );\n }\n\n get shouldChangeFilledStatus(): boolean {\n return this.canToggleFilled(this.icon);\n }\n\n /**\n * Whether this specific icon may be swapped to its filled variant on hover. Takes the icon as an\n * argument because a button can render two, and a brand icon in one slot must not freeze the other.\n */\n canToggleFilled(icon: IconName): boolean {\n return (\n this.applicationTheme !== 'classic' &&\n this.variant !== 'primary' &&\n this.variant !== 'secondary' &&\n this.variant !== 'linkedin' &&\n !this.coloredIcons.includes(icon)\n );\n }\n\n onKeydown(event: KeyboardEvent): void {\n if (event.key === ' ') {\n event.preventDefault();\n const target = event.target as HTMLElement;\n target.click();\n }\n\n if (event.key === 'Enter' || event.key === ' ') {\n this.buttonState = 'pressed';\n this.styleCss = this.setCssStyle();\n }\n }\n\n onKeyup(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n this.buttonState = this.hover ? 'hover' : 'default';\n this.styleCss = this.setCssStyle();\n }\n }\n\n onLabelEllipsisChange(state: boolean): void {\n this.labelEllipsis = state;\n }\n\n getIconName(iconName: string, defaultValue: string): IconName {\n if (iconName.includes('filled')) {\n return iconName.replace(/filled/, 'in-line') as IconName;\n } else if (iconName.includes('in-line')) {\n return iconName.replace(/in-line/, 'filled') as IconName;\n }\n // Only append when the result is a real icon; otherwise it falls outside the IconName union.\n const suffixed = iconName + defaultValue;\n return this.isKnownIconName(suffixed) ? suffixed : (iconName as IconName);\n }\n\n private isKnownIconName(name: string): name is IconName {\n return (tgoRebrandIcons as readonly string[]).includes(name) || (tgoIcons as readonly string[]).includes(name);\n }\n\n private createAriaLabelledById(): void {\n const labelledByValue = this.variant === 'link' ? 'labelledby-link' : 'labelledby';\n this.ariaLabelledbyId = `${labelledByValue}-uiButton-${++ButtonComponent.nextAriaLabelledId}`;\n }\n}\n","<div\n #tooltipElement\n class=\"tooltip\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n></div>\n<div\n class=\"button-wrapper\"\n [ngClass]=\"{\n 'full-width': fullWidth,\n 'rounded-icon': applicationTheme !== 'classic' && icon && !label,\n link: !isButtonLink,\n }\"\n>\n <div\n class=\"button-container\"\n [ngClass]=\"{\n disabled: disabled,\n 'button-scale': buttonState === 'pressed' && applicationTheme !== 'classic' && !disabledScaleOnClick,\n }\"\n >\n @if (isPremium && typeIncluded) {\n <span class=\"right-top premium-marker\">\n <ui-icon name=\"Premium-in-line\" size=\"16\" [color]=\"premiumMarkerColor\"></ui-icon>\n </span>\n }\n @if (buttonBadgeConfig?.badgeType) {\n <ui-badge\n id=\"badge\"\n [rebrandColor]=\"buttonBadgeConfig?.rebrandColor ?? 'brand'\"\n [variant]=\"buttonBadgeConfig!.badgeType!\"\n [label]=\"buttonBadgeConfig?.badgeLabel ?? ''\"\n [notificationsAmount]=\"buttonBadgeConfig?.badgeNotificationAmount ?? 0\"\n class=\"right-top\"\n [ngClass]=\"[\n buttonBadgeConfig?.badgeType === 'primary' ? 'badge-primary' : '',\n buttonBadgeConfig?.badgeType === 'notification' ? 'badge-notification' : '',\n variant,\n ]\"\n ></ui-badge>\n }\n @if (isButtonLink) {\n <button\n [style]=\"'--icon-button-size:' + iconButtonSize + 'px'\"\n [ngClass]=\"classCss\"\n [ngStyle]=\"styleCss\"\n [disabled]=\"disabled\"\n (click)=\"buttonClick($event)\"\n (mouseleave)=\"buttonHover($event)\"\n (mouseenter)=\"buttonHover($event)\"\n (mousedown)=\"onPressed($event)\"\n (mouseup)=\"onPressed($event)\"\n (keydown)=\"onKeydown($event)\"\n (keyup)=\"onKeyup($event)\"\n [attr.aria-required]=\"ariaRequired\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledbyId\"\n [attr.aria-describedby]=\"'describedby'\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"ariaExpanded\"\n [attr.aria-controls]=\"ariaControls\"\n [attr.aria-pressed]=\"ariaPressed\"\n [attr.data-testid]=\"testId\"\n [type]=\"type\"\n [disableRipple]=\"applicationTheme !== 'classic'\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n [matTooltipPosition]=\"tooltipPosition\"\n #buttonElement\n [attr.role]=\"role\"\n mat-flat-button\n >\n <span id=\"describedby\" [style.display]=\"'none'\">\n {{ isPremium ? label + ' ' + ('BUTTON.PREMIUM_FEATURE' | uiTranslate | async) : ariaDescribedby }}\n </span>\n <span [id]=\"ariaLabelledbyId\" [style.display]=\"'none'\">\n {{ ariaLabelledby }}\n </span>\n @if (showSpinner) {\n <span class=\"spinner-wrapper\">\n <mat-spinner class=\"position-spinner\" aria-label=\"loading\" mode=\"indeterminate\" diameter=\"24\"></mat-spinner>\n </span>\n } @else {\n @if (justIcon && !!icon) {\n <span class=\"icon-only-wrapper\">\n <span class=\"icon only\" role=\"label\">\n <ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n [size]=\"size === 'small' ? '16' : '24'\"\n ></ui-icon>\n </span>\n </span>\n }\n @if (!justIcon) {\n <span class=\"icon-label-wrapper\" [ngClass]=\"{ 'center-text': iconName === '' }\">\n @if (showInlineSpinner) {\n <span class=\"icon inline-spinner\" aria-hidden=\"true\">\n <mat-spinner\n aria-label=\"loading\"\n mode=\"indeterminate\"\n [diameter]=\"size === 'small' ? 16 : 20\"\n ></mat-spinner>\n </span>\n }\n @if (iconPosition === 'left' && !!iconName && !showInlineSpinner) {\n <span class=\"icon\" aria-hidden=\"true\">\n <ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n [size]=\"size === 'small' ? '16' : '24'\"\n ></ui-icon>\n </span>\n }\n @if (isLabel) {\n <span\n class=\"label\"\n id=\"label\"\n uiEllipseText\n [isMultiline]=\"true\"\n (onChangeTextState)=\"onLabelEllipsisChange($event)\"\n >\n {{ label }}\n </span>\n }\n @if (iconPosition === 'right' && !!icon) {\n <span class=\"icon\" aria-hidden=\"true\"\n ><ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [size]=\"size === 'small' ? '16' : '24'\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n ></ui-icon\n ></span>\n }\n @if (!!trailingIcon && !showInlineSpinner) {\n <span class=\"icon trailing\" aria-hidden=\"true\"\n ><ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"trailingIcon\"\n [filled]=\"isFilledIcon || trailingIconFilled\"\n [size]=\"size === 'small' ? '16' : '24'\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n ></ui-icon\n ></span>\n }\n </span>\n }\n }\n </button>\n }\n @if (!isButtonLink) {\n <a\n #buttonElement\n [ngClass]=\"classCss\"\n [ngStyle]=\"styleCss\"\n [disabled]=\"disabled\"\n (click)=\"buttonClick($event)\"\n (mouseenter)=\"buttonHover($event)\"\n (mouseleave)=\"buttonHover($event)\"\n (mousedown)=\"onPressed($event)\"\n (mouseup)=\"onPressed($event)\"\n (keydown)=\"onKeydown($event)\"\n (keyup)=\"onKeyup($event)\"\n [disableRipple]=\"true\"\n [attr.aria-required]=\"ariaRequired\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledbyId\"\n [attr.aria-describedby]=\"'describedby-link'\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"ariaExpanded\"\n [attr.aria-controls]=\"ariaControls\"\n [attr.aria-pressed]=\"ariaPressed\"\n [attr.data-testid]=\"testId\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n role=\"link\"\n [href]=\"url\"\n [target]=\"urlTarget\"\n mat-flat-button\n >\n <span id=\"describedby-link\" [style.display]=\"'none'\">\n {{ ariaDescribedby }}\n </span>\n <span [id]=\"ariaLabelledbyId\" [style.display]=\"'none'\">\n {{ ariaLabelledby }}\n </span>\n <span class=\"icon-label-wrapper\">\n {{ label }}\n </span>\n </a>\n }\n </div>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatTooltipModule } from '@angular/material/tooltip';\n\nimport { BadgeComponentModule } from '@testgorilla/tgo-ui/components/badge';\nimport { EllipseTextDirective, UiTranslatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\n\nimport { ButtonComponent } from './button.component';\n\n@NgModule({\n imports: [\n CommonModule,\n MatButtonModule,\n IconComponentModule,\n MatProgressSpinnerModule,\n MatTooltipModule,\n BadgeComponentModule,\n EllipseTextDirective,\n MatRadioModule,\n UiTranslatePipe,\n ButtonComponent,\n ],\n exports: [ButtonComponent],\n providers: [],\n})\nexport class ButtonComponentModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAWA;AACA,MAAM,aAAa,GAAG,CAAC,SAAiB,KAAmC;AACzE,IAAA,IAAI,SAAS,GAAG,EAAE,EAAE;AAClB,QAAA,OAAO,MAAM;IACf;AACA,IAAA,IAAI,SAAS,GAAG,EAAE,EAAE;AAClB,QAAA,OAAO,KAAK;IACd;IACA,IAAI,SAAS,GAAG,EAAE,IAAI,SAAS,GAAG,EAAE,EAAE;AACpC,QAAA,OAAO,KAAK;IACd;AACA,IAAA,OAAO,IAAI;AACb,CAAC;AAED;AACA,MAAM,gBAAgB,GAAG,CAAC,SAAiB,EAAE,SAAyB,KAAY;IAChF,IAAI,SAAS,KAAK,OAAO,IAAI,SAAS,KAAK,SAAS,EAAE;AACpD,QAAA,OAAO,CAAC;IACV;AACA,IAAA,MAAM,IAAI,GAAG,aAAa,CAAC,SAAS,CAAC;IACrC,OAAO,IAAI,KAAK,KAAK,GAAG,EAAE,GAAG,IAAI,GAAG,CAAC,EAAE,GAAG,CAAC;AAC7C,CAAC;AAED;AACA,MAAM,oBAAoB,GAAG,CAAC,SAAiB,EAAE,SAAyB,KAAY;AACpF,IAAA,MAAM,aAAa,GAAuE;AACxF,QAAA,KAAK,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE;AACvC,QAAA,OAAO,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE;AACzC,QAAA,QAAQ,EAAE,EAAE,IAAI,EAAE,EAAE,E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AO,EAAE;wBACP,YAAY;wBACZ,eAAe;wBACf,mBAAmB;wBACnB,wBAAwB;wBACxB,gBAAgB;wBAChB,oBAAoB;wBACpB,oBAAoB;wBACpB,cAAc;wBACd,eAAe;wBACf,eAAe;AAChB,qBAAA;oBACD,OAAO,EAAE,CAAC,eAAe,CAAC;AAC1B,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;AC5BD;;AAEG;;"}
1
+ {"version":3,"file":"testgorilla-tgo-ui-components-button.mjs","names":[],"sources":["../../../components/button/color-contrast.ts","../../../components/button/button.component.ts","../../../components/button/button.component.html","../../../components/button/button.component.module.ts"],"sourcesContent":["/**\n * Function for adjusting the lightness of a color based on different events (hover, pressed, disabled).\n * Accepts a hex color, transforms it to HSL, and based on color's L and event darkens or lightens it.\n * Used to manage different colors based on application configuration\n *\n * @param hexColor color in hex format\n * @param typeEvent interaction event\n * @param theme\n */\ntype LightnessEvent = 'hover' | 'pressed' | 'disabled';\n\n/** Lightness band of a colour, in percent. `null` = exactly on a 30/70 boundary (no adjustment). */\nconst lightnessBand = (lightness: number): 'high' | 'low' | 'mid' | null => {\n if (lightness > 70) {\n return 'high';\n }\n if (lightness < 30) {\n return 'low';\n }\n if (lightness < 70 && lightness > 30) {\n return 'mid';\n }\n return null;\n};\n\n/** Lightness delta (in percent points) for the `new` theme. */\nconst getNewThemeDelta = (lightness: number, typeEvent: LightnessEvent): number => {\n if (typeEvent !== 'hover' && typeEvent !== 'pressed') {\n return 0;\n }\n const band = lightnessBand(lightness);\n return band === 'low' ? 10 : band ? -10 : 0;\n};\n\n/** Lightness delta (in percent points) for the `classic` theme. */\nconst getClassicThemeDelta = (lightness: number, typeEvent: LightnessEvent): number => {\n const deltasByEvent: Record<LightnessEvent, { high: number; low: number; mid: number }> = {\n hover: { high: -10, low: 10, mid: -10 },\n pressed: { high: -20, low: 30, mid: -20 },\n disabled: { high: 10, low: 50, mid: 20 },\n };\n const band = lightnessBand(lightness);\n if (!band) {\n return 0;\n }\n // typeEvent is LightnessEvent at compile time, but callers may pass an\n // out-of-range button state at runtime (matches the original no-op behaviour).\n const eventDeltas: { high: number; low: number; mid: number } | undefined = deltasByEvent[typeEvent];\n return eventDeltas ? eventDeltas[band] : 0;\n};\n\nexport const adjustLightness = (\n hexColor: string,\n typeEvent: LightnessEvent,\n theme: 'new' | 'classic' = 'new'\n): string => {\n const hexRegex = /^#(?:[0-9A-F]{3}|[0-9A-F]{6})$/i;\n if (hexColor && !hexRegex.test(hexColor)) {\n throw new Error('Invalid HEX color format');\n }\n\n const hslColor = hexToHsl(hexColor);\n const lightness = hslColor.l * 100;\n const delta = theme === 'new' ? getNewThemeDelta(lightness, typeEvent) : getClassicThemeDelta(lightness, typeEvent);\n hslColor.l = clamp(hslColor.l + delta / 100);\n\n return hslToHex(hslColor);\n};\n\n/**\n * Transforms hex color to HSL in object variation.\n * @param hexColor string value with hex color\n */\nexport const hexToHsl = (hexColor: string): { h: number; s: number; l: number } => {\n const rgbColor = parseInt(hexColor.slice(1), 16);\n /* eslint-disable no-bitwise -- standard RGB channel extraction from a packed 24-bit integer */\n const r = ((rgbColor >> 16) & 255) / 255;\n const g = ((rgbColor >> 8) & 255) / 255;\n const b = (rgbColor & 255) / 255;\n /* eslint-enable no-bitwise */\n\n const max = Math.max(r, g, b);\n const min = Math.min(r, g, b);\n\n let h = 0;\n let s;\n const l = (max + min) / 2;\n\n if (max === min) {\n h = s = 0; // grayscale\n } else {\n const d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n\n h /= 6;\n }\n\n return { h, s, l };\n};\n\n/**\n * Transforms HSL color, represented as an object and transforms it to hex string.\n * @param hslColor accepts the HSL color like an object.\n */\nexport const hslToHex = (hslColor: { h: number; s: number; l: number }): string => {\n const { h, s, l } = hslColor;\n\n const hueToRgb = (p: number, q: number, t: number): number => {\n let tNorm = t;\n if (tNorm < 0) {\n tNorm += 1;\n }\n if (tNorm > 1) {\n tNorm -= 1;\n }\n if (tNorm < 1 / 6) {\n return p + (q - p) * 6 * tNorm;\n }\n if (tNorm < 1 / 2) {\n return q;\n }\n if (tNorm < 2 / 3) {\n return p + (q - p) * (2 / 3 - tNorm) * 6;\n }\n return p;\n };\n\n const qBase = l < 0.5 ? l * (1 + s) : l + s - l * s;\n const pBase = 2 * l - qBase;\n\n const r = hueToRgb(pBase, qBase, h + 1 / 3);\n const g = hueToRgb(pBase, qBase, h);\n const b = hueToRgb(pBase, qBase, h - 1 / 3);\n\n // eslint-disable-next-line no-bitwise -- standard RGB channel packing into a 24-bit integer\n const rgbColor = (Math.round(r * 255) << 16) | (Math.round(g * 255) << 8) | Math.round(b * 255);\n\n return `#${rgbColor.toString(16).padStart(6, '0')}`;\n};\n\n/**\n * Restricts the value to be within the range [0, 1].\n * @param value\n */\nconst clamp = (value: number): number => Math.min(Math.max(value, 0), 1);\n","/* eslint-disable @angular-eslint/use-lifecycle-interface */\nimport { FocusOrigin } from '@angular/cdk/a11y';\nimport { NgClass, NgStyle, AsyncPipe } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n AfterViewInit,\n booleanAttribute,\n Component,\n ElementRef,\n EventEmitter,\n HostBinding,\n Inject,\n Input,\n OnInit,\n Optional,\n Output,\n SimpleChanges,\n ViewChild,\n} from '@angular/core';\nimport { MatButton } from '@angular/material/button';\nimport { MatProgressSpinner } from '@angular/material/progress-spinner';\nimport { TooltipPosition, MatTooltip } from '@angular/material/tooltip';\n\nimport { BadgeComponent } from '@testgorilla/tgo-ui/components/badge';\nimport { ApplicationTheme, Color, EllipseTextDirective, UiTranslatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { IconName, IconComponentModule, tgoIcons, tgoRebrandIcons } from '@testgorilla/tgo-ui/components/icon';\n\nimport {\n ButtonBadgeConfig,\n ButtonColor,\n ButtonIconPosition,\n ButtonSize,\n ButtonState,\n ButtonType,\n IconButtonSize,\n LinkUrlTarget,\n} from './button.model';\nimport { adjustLightness } from './color-contrast';\n\n@Component({\n selector: 'ui-button',\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './button.component.html',\n styleUrls: ['./button.component.scss'],\n imports: [\n MatTooltip,\n NgClass,\n BadgeComponent,\n MatButton,\n NgStyle,\n MatProgressSpinner,\n IconComponentModule,\n EllipseTextDirective,\n AsyncPipe,\n UiTranslatePipe,\n ],\n})\nexport class ButtonComponent implements OnInit, AfterViewInit {\n @HostBinding('style.pointer-events')\n get enabled(): string {\n return this.disabled ? 'none' : 'all';\n }\n\n @ViewChild('tooltipElement') tooltipElement: ElementRef<HTMLElement>;\n\n /**\n * Define button height\n *\n * @type {ButtonSize}\n * @memberof ButtonComponent\n */\n @Input() size: ButtonSize = 'big';\n /**\n * Background color of the button while in active state\n *\n * @type {ButtonColor}\n * @memberof ButtonComponent\n */\n @HostBinding('attr.btn-variant')\n @Input()\n variant: ButtonColor = 'primary';\n\n /**\n * Text content to appear on the button\n *\n * @memberof ButtonComponent\n */\n @Input() label = '';\n\n /**\n * Positioning of the icon (when existant)\n *\n * @type {ButtonIconPosition}\n * @memberof ButtonComponent\n */\n @Input() iconPosition?: ButtonIconPosition = 'right';\n\n /**\n * Define if button has only icon without text\n *\n * @memberof ButtonComponent\n */\n @Input() justIcon = false;\n\n /**\n * Name of ui-icon\n *\n * @type {IconName}\n * @memberof ButtonComponent\n */\n @Input() iconName: IconName | undefined;\n\n /**\n * Name of a second ui-icon rendered after the label, in addition to `iconName`.\n * Pair it with `iconPosition=\"left\"` to show a leading and a trailing icon at once.\n *\n * @type {IconName}\n * @memberof ButtonComponent\n */\n @Input() trailingIconName: IconName | undefined;\n\n /**\n * Renders the trailing icon filled, independently of `iconFilled`.\n *\n * @memberof ButtonComponent\n */\n @Input() trailingIconFilled = false;\n\n /**\n * Indicator if the button should be disabled\n *\n * @memberof ButtonComponent\n */\n @Input() disabled = false;\n\n /**\n * Indicator if the loading icon should be shown\n *\n * @memberof ButtonComponent\n */\n @Input() loading = false;\n\n /**\n * Show a small inline spinner to the left of the label while keeping the\n * label visible. Pair with `disabled` to make the button non-interactive.\n * If `loading` is also true, `loading` takes precedence.\n *\n * @memberof ButtonComponent\n */\n @Input() loadingWithLabel = false;\n\n /**\n * Indicator of the button width\n *\n * @memberof ButtonComponent\n */\n @Input() fullWidth = false;\n\n /**\n * Url of button if it is a link\n *\n * @memberof ButtonComponent\n */\n @Input() url?: string;\n\n /**\n * Url's target of button if it is a link\n *\n * @type {@type {LinkUrlTarget}}\n * @memberof ButtonComponent\n */\n @Input() urlTarget?: LinkUrlTarget;\n\n /**\n * Button value\n *\n * @memberof ButtonComponent\n */\n @Input() value?: string;\n\n /**\n * @property tooltip\n * @description The tooltip that is displayed on hover. Required for icon-button type\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() tooltip = '';\n\n /**\n * @property isPremium\n * @description The icon that is displayed for Premium button\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() isPremium = false;\n\n /**\n * The type of the button.\n *\n * @type {ButtonType}\n * @memberof ButtonComponent\n * @default 'button'\n */\n @Input() type: ButtonType = 'button';\n\n /**\n * Color of the button.\n * Defaults to Test Gorilla primary color.\n *\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() companyColor: string | null = '';\n\n /**\n * Config for the button badge variation\n * @type {ButtonBadgeConfig}\n * @property badgeType Type of badge on the button\n * @property badgeLabel Label text for the badge\n * @property badgeNotificationAmount The amount for notification in the badge\n */\n @Input() buttonBadgeConfig: ButtonBadgeConfig | undefined;\n\n /**\n *\n * Defines the application theme where buttons is used\n *\n * @type {ApplicationTheme}\n * @memberof ButtonComponent\n */\n @HostBinding('attr.theme')\n @Input()\n applicationTheme: ApplicationTheme = 'light';\n\n /** The premium marker reads as the warning badge does, so the two are recognisably the same signal. */\n protected readonly premiumMarkerColor = Color.BLACK;\n\n /**\n *\n * Disabled button scale on click\n *\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() disabledScaleOnClick = false;\n\n /**\n * A string representing the ARIA label for accessibility.\n * This label is used to provide an accessible name for the input element.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaLabel: string;\n\n /**\n * Whether the button controls a disclosure widget that is currently expanded.\n * Set to `true` for an expanded disclosure, `false` for collapsed, or leave\n * undefined when the button is not a disclosure trigger.\n * @memberof ButtonComponent\n */\n @Input() ariaExpanded?: boolean;\n\n /**\n * The id of the element controlled by this button (used together with\n * `ariaExpanded` for disclosure semantics).\n * @memberof ButtonComponent\n */\n @Input() ariaControls?: string;\n\n /**\n * Whether the button is a toggle button currently in the pressed state.\n * Use `true` / `false` for two-state toggles. Leave undefined when the\n * button is not a toggle.\n * @memberof ButtonComponent\n */\n @Input() ariaPressed?: boolean;\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input() ariaRequired = false;\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaLabelledby = '';\n\n /**\n * A string representing the ARIA requirement for accessibility.\n * This attribute is used to indicate whether an input field is required for form submission.\n * @type {string}\n * @memberof ButtonComponent\n */\n @Input() ariaDescribedby = '';\n\n /**\n * Prevents default button click behavior\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input({ transform: booleanAttribute }) preventDefault = false;\n\n /**\n * Ghost variant with white background\n * @type {boolean}\n * @memberof ButtonComponent\n */\n @Input({ transform: booleanAttribute }) hasBackground = false;\n\n /**\n * Sets tooltip position\n *\n * @type {TooltipPosition}\n * @memberof ButtonComponent\n */\n @Input() tooltipPosition: TooltipPosition = 'below';\n\n @Input() role = 'button';\n\n @Input() iconFilled = false;\n\n @Input() testId: string | null = null;\n\n @Output() buttonClickEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n @Output() buttonHoverEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n @ViewChild('buttonElement', { static: false }) buttonElement: MatButton;\n\n get isDisabled(): boolean {\n return this.disabled;\n }\n\n @HostBinding('style.--color')\n get compColor() {\n return this.getCompanyColor;\n }\n\n classCss: string;\n styleCss: Record<string, string>;\n isButtonLink: boolean;\n isLabel: boolean;\n buttonState: ButtonState;\n hover = false;\n iconButtonSize: IconButtonSize = '40';\n allowButtonTypeForPremium: ButtonColor[] = [\n 'secondary',\n 'secondary-inverted',\n 'primary',\n 'ghost',\n 'outlined',\n 'destructive',\n 'icon-button',\n ];\n isFilledIcon: boolean;\n coloredIcons = ['Google-in-line', 'Google', 'Google-filled', 'Linkedin-brand-filled', 'Linkedin-brand-in-line'];\n labelEllipsis = false;\n icon: IconName = '';\n trailingIcon: IconName = '';\n\n private static nextAriaLabelledId = 0;\n ariaLabelledbyId = '';\n\n get typeIncluded(): boolean {\n return this.allowButtonTypeForPremium.includes(this.variant);\n }\n\n constructor(\n @Optional() @Inject('CANOPYUI_DEFAULT_APPLICATION_THEME') private readonly defaultAppTheme: ApplicationTheme\n ) {\n if (defaultAppTheme) {\n this.applicationTheme = defaultAppTheme;\n }\n }\n\n ngOnInit(): void {\n this.classCss = this.setCssClass();\n this.styleCss = this.setCssStyle();\n this.isButtonLink = this.showButtonLink();\n this.isLabel = this.showLabel();\n this.createAriaLabelledById();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes['disabled']) {\n this.buttonState = 'default';\n }\n if (!this.applicationTheme) {\n this.applicationTheme = 'light';\n }\n if (changes['type']) {\n this.isButtonLink = this.showButtonLink();\n }\n if (changes['loading']) {\n this.isLabel = this.showLabel();\n }\n if (changes['iconName']) {\n this.icon = changes['iconName'].currentValue as IconName;\n }\n if (changes['trailingIconName']) {\n this.trailingIcon = changes['trailingIconName'].currentValue as IconName;\n }\n if (this.hasCssAffectingChange(changes)) {\n this.classCss = this.setCssClass();\n this.styleCss = this.setCssStyle();\n }\n if (this.isIconButtonSizeChange(changes)) {\n this.iconButtonSize = this.setIconButtonSize();\n }\n\n this.isFilledIcon = this.isFilledIconVariant();\n }\n\n private hasCssAffectingChange(changes: SimpleChanges): boolean {\n return Boolean(\n changes['type'] ||\n changes['fullWidth'] ||\n changes['iconName'] ||\n changes['trailingIconName'] ||\n changes['trailingIconFilled'] ||\n changes['justIcon'] ||\n changes['iconPosition'] ||\n changes['disabled'] ||\n changes['companyColor'] ||\n changes['variant'] ||\n changes['applicationTheme']\n );\n }\n\n private isIconButtonSizeChange(changes: SimpleChanges): boolean {\n return (\n changes['variant']?.currentValue === 'icon-button' ||\n (changes['variant']?.currentValue === 'menuTrigger' && this.applicationTheme !== 'classic')\n );\n }\n\n private isFilledIconVariant(): boolean {\n return (\n this.applicationTheme !== 'classic' &&\n (this.variant === 'primary' ||\n this.variant === 'secondary' ||\n this.variant === 'secondary-inverted' ||\n this.variant === 'linkedin')\n );\n }\n\n ngAfterViewInit(): void {\n this.tooltipElement.nativeElement.onclick = ev => {\n ev.preventDefault();\n ev.stopPropagation();\n };\n }\n\n buttonClick(event: Event): void {\n if (this.preventDefault) {\n event.preventDefault();\n event.stopPropagation();\n }\n this.buttonClickEvent.emit(event);\n }\n\n buttonHover(event: Event): void {\n if (event.type === 'mouseenter') {\n this.hover = true;\n this.buttonHoverEvent.emit(event);\n this.buttonState = 'hover';\n if (this.shouldChangeFilledStatus && this.icon) {\n this.icon = this.getIconName(this.iconName as IconName, '-filled');\n }\n if (this.trailingIcon && this.canToggleFilled(this.trailingIcon)) {\n this.trailingIcon = this.getIconName(this.trailingIconName as IconName, '-filled');\n }\n } else {\n this.hover = false;\n if (this.shouldChangeFilledStatus && this.icon) {\n this.icon = this.iconName as IconName;\n }\n if (this.trailingIcon && this.canToggleFilled(this.trailingIcon)) {\n this.trailingIcon = this.trailingIconName as IconName;\n }\n this.buttonState = 'default';\n }\n\n this.styleCss = this.setCssStyle();\n }\n\n //Show or hide label\n showLabel(): boolean {\n return !this.loading;\n }\n\n //Set css class according inputs\n setCssClass(): string {\n const width = this.fullWidth ? 'full-width' : '';\n const hasIcon = this.iconName === null ? '' : 'icon';\n const justIcon = this.justIcon || this.variant === 'icon-button' ? 'only-icon' : '';\n const iconPosition = this.iconPosition ?? '';\n const disabled = this.disabled && this.variant === 'primary' ? 'primary-disabled' : '';\n const variant = this.variant === 'ghost' && this.applicationTheme === 'classic' ? 'outlined' : this.variant;\n const companyColor = this.companyColor ? 'has-company-color' : '';\n return `${this.size} ${iconPosition} ${variant} ${width} ${hasIcon} ${justIcon} ${disabled} ${companyColor} ${this.applicationTheme}-theme`;\n }\n\n setCssStyle(): Record<string, string> {\n this.buttonState = this.disabled ? 'disabled' : this.buttonState;\n return (\n this.getInteractiveStyle() ??\n this.getClassicInteractiveStyle() ??\n this.getCompanyColorStyle() ??\n this.getGhostBackgroundStyle() ??\n {}\n );\n }\n\n private get isColorVariant(): boolean {\n return this.variant === 'primary' || this.variant === 'text' || this.variant === 'text-inline';\n }\n\n private get isTextVariant(): boolean {\n return this.variant === 'text' || this.variant === 'text-inline';\n }\n\n private getInteractiveStyle(): Record<string, string> | null {\n if (this.buttonState !== 'hover' && this.buttonState !== 'pressed') {\n return null;\n }\n if (!this.isColorVariant || this.applicationTheme === 'classic') {\n return null;\n }\n const styleObj: Record<string, string> = {};\n styleObj[this.variant === 'primary' ? 'background-color' : 'color'] = adjustLightness(\n this.getCompanyColor,\n this.buttonState\n );\n if (this.isTextVariant) {\n styleObj['--active-color'] = this.companyColor\n ? adjustLightness(this.getCompanyColor, this.buttonState)\n : '#666666';\n }\n return styleObj;\n }\n\n private getClassicInteractiveStyle(): Record<string, string> | null {\n if (this.buttonState === 'default') {\n return null;\n }\n if (!this.isColorVariant || this.applicationTheme !== 'classic') {\n return null;\n }\n return {\n [this.variant === 'primary' ? 'background-color' : 'color']: adjustLightness(\n this.getCompanyColor,\n this.buttonState,\n 'classic'\n ),\n };\n }\n\n private getCompanyColorStyle(): Record<string, string> | null {\n const isCompanyColorVariant =\n this.variant === 'link' || this.variant === 'tertiary' || this.variant === 'icon-button';\n if (!(this.getCompanyColor && isCompanyColorVariant)) {\n return null;\n }\n return { color: this.getCompanyColor };\n }\n\n private getGhostBackgroundStyle(): Record<string, string> | null {\n return this.hasBackground ? { '--ghost-background': '#ffffff' } : null;\n }\n\n //Show or hide spinner\n get showSpinner(): boolean {\n const isNotTab = this.variant !== 'tab';\n const isNotLink = this.variant !== 'link';\n const isLoading = this.loading === true;\n return isLoading && isNotTab && isNotLink;\n }\n\n //Show or hide the inline spinner that sits next to the label\n get showInlineSpinner(): boolean {\n return (\n this.loadingWithLabel && !this.loading && this.variant !== 'tab' && this.variant !== 'link' && !this.justIcon\n );\n }\n\n //Show button with <button> or <a> tag\n showButtonLink(): boolean {\n return this.variant !== 'link';\n }\n\n setIconButtonSize(): IconButtonSize {\n return this.size === 'big' ? '40' : this.size === 'small' ? '24' : '32';\n }\n\n onPressed(ev: Event): void {\n if (ev.type === 'mousedown') {\n this.buttonState = 'pressed';\n } else {\n this.buttonState = this.hover ? 'hover' : 'default';\n }\n\n this.styleCss = this.setCssStyle();\n }\n\n focus(origin?: FocusOrigin): void {\n this.buttonElement.focus(origin);\n }\n\n get getCompanyColor(): string {\n return (\n // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing -- empty companyColor ('' is the default) falls back to the theme colour\n this.companyColor ||\n (this.variant === 'text' || this.variant === 'text-inline'\n ? this.applicationTheme === 'dark'\n ? '#ffffff'\n : '#242424'\n : this.applicationTheme === 'classic'\n ? '#46A997'\n : '#D410AA')\n );\n }\n\n get shouldChangeFilledStatus(): boolean {\n return this.canToggleFilled(this.icon);\n }\n\n /**\n * Whether this specific icon may be swapped to its filled variant on hover. Takes the icon as an\n * argument because a button can render two, and a brand icon in one slot must not freeze the other.\n */\n canToggleFilled(icon: IconName): boolean {\n return (\n this.applicationTheme !== 'classic' &&\n this.variant !== 'primary' &&\n this.variant !== 'secondary' &&\n this.variant !== 'linkedin' &&\n !this.coloredIcons.includes(icon)\n );\n }\n\n onKeydown(event: KeyboardEvent): void {\n if (event.key === ' ') {\n event.preventDefault();\n const target = event.target as HTMLElement;\n target.click();\n }\n\n if (event.key === 'Enter' || event.key === ' ') {\n this.buttonState = 'pressed';\n this.styleCss = this.setCssStyle();\n }\n }\n\n onKeyup(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n this.buttonState = this.hover ? 'hover' : 'default';\n this.styleCss = this.setCssStyle();\n }\n }\n\n onLabelEllipsisChange(state: boolean): void {\n this.labelEllipsis = state;\n }\n\n getIconName(iconName: string, defaultValue: string): IconName {\n if (iconName.includes('filled')) {\n return iconName.replace(/filled/, 'in-line') as IconName;\n } else if (iconName.includes('in-line')) {\n return iconName.replace(/in-line/, 'filled') as IconName;\n }\n // Only append when the result is a real icon; otherwise it falls outside the IconName union.\n const suffixed = iconName + defaultValue;\n return this.isKnownIconName(suffixed) ? suffixed : (iconName as IconName);\n }\n\n private isKnownIconName(name: string): name is IconName {\n return (tgoRebrandIcons as readonly string[]).includes(name) || (tgoIcons as readonly string[]).includes(name);\n }\n\n private createAriaLabelledById(): void {\n const labelledByValue = this.variant === 'link' ? 'labelledby-link' : 'labelledby';\n this.ariaLabelledbyId = `${labelledByValue}-uiButton-${++ButtonComponent.nextAriaLabelledId}`;\n }\n}\n","<div\n #tooltipElement\n class=\"tooltip\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n></div>\n<div\n class=\"button-wrapper\"\n [ngClass]=\"{\n 'full-width': fullWidth,\n 'rounded-icon': applicationTheme !== 'classic' && icon && !label,\n link: !isButtonLink,\n }\"\n>\n <div\n class=\"button-container\"\n [ngClass]=\"{\n disabled: disabled,\n 'button-scale': buttonState === 'pressed' && applicationTheme !== 'classic' && !disabledScaleOnClick,\n }\"\n >\n @if (isPremium && typeIncluded) {\n <span class=\"right-top premium-marker\">\n <ui-icon name=\"Premium-in-line\" size=\"16\" [color]=\"premiumMarkerColor\"></ui-icon>\n </span>\n }\n @if (buttonBadgeConfig?.badgeType) {\n <ui-badge\n id=\"badge\"\n [rebrandColor]=\"buttonBadgeConfig?.rebrandColor ?? 'brand'\"\n [variant]=\"buttonBadgeConfig!.badgeType!\"\n [label]=\"buttonBadgeConfig?.badgeLabel ?? ''\"\n [notificationsAmount]=\"buttonBadgeConfig?.badgeNotificationAmount ?? 0\"\n class=\"right-top\"\n [ngClass]=\"[\n buttonBadgeConfig?.badgeType === 'primary' ? 'badge-primary' : '',\n buttonBadgeConfig?.badgeType === 'notification' ? 'badge-notification' : '',\n variant,\n ]\"\n ></ui-badge>\n }\n @if (isButtonLink) {\n <button\n [style]=\"'--icon-button-size:' + iconButtonSize + 'px'\"\n [ngClass]=\"classCss\"\n [ngStyle]=\"styleCss\"\n [disabled]=\"disabled\"\n (click)=\"buttonClick($event)\"\n (mouseleave)=\"buttonHover($event)\"\n (mouseenter)=\"buttonHover($event)\"\n (mousedown)=\"onPressed($event)\"\n (mouseup)=\"onPressed($event)\"\n (keydown)=\"onKeydown($event)\"\n (keyup)=\"onKeyup($event)\"\n [attr.aria-required]=\"ariaRequired\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledbyId\"\n [attr.aria-describedby]=\"'describedby'\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"ariaExpanded\"\n [attr.aria-controls]=\"ariaControls\"\n [attr.aria-pressed]=\"ariaPressed\"\n [attr.data-testid]=\"testId\"\n [type]=\"type\"\n [disableRipple]=\"applicationTheme !== 'classic'\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n [matTooltipPosition]=\"tooltipPosition\"\n #buttonElement\n [attr.role]=\"role\"\n mat-flat-button\n >\n <span id=\"describedby\" [style.display]=\"'none'\">\n {{ isPremium ? label + ' ' + ('BUTTON.PREMIUM_FEATURE' | uiTranslate | async) : ariaDescribedby }}\n </span>\n <span [id]=\"ariaLabelledbyId\" [style.display]=\"'none'\">\n {{ ariaLabelledby }}\n </span>\n @if (showSpinner) {\n <span class=\"spinner-wrapper\">\n <mat-spinner class=\"position-spinner\" aria-label=\"loading\" mode=\"indeterminate\" diameter=\"24\"></mat-spinner>\n </span>\n } @else {\n @if (justIcon && !!icon) {\n <span class=\"icon-only-wrapper\">\n <span class=\"icon only\" role=\"label\">\n <ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n [size]=\"size === 'small' ? '16' : '24'\"\n ></ui-icon>\n </span>\n </span>\n }\n @if (!justIcon) {\n <span class=\"icon-label-wrapper\" [ngClass]=\"{ 'center-text': iconName === '' }\">\n @if (showInlineSpinner) {\n <span class=\"icon inline-spinner\" aria-hidden=\"true\">\n <mat-spinner\n aria-label=\"loading\"\n mode=\"indeterminate\"\n [diameter]=\"size === 'small' ? 16 : 20\"\n ></mat-spinner>\n </span>\n }\n @if (iconPosition === 'left' && !!iconName && !showInlineSpinner) {\n <span class=\"icon\" aria-hidden=\"true\">\n <ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n [size]=\"size === 'small' ? '16' : '24'\"\n ></ui-icon>\n </span>\n }\n @if (isLabel) {\n <span\n class=\"label\"\n id=\"label\"\n uiEllipseText\n [isMultiline]=\"true\"\n (onChangeTextState)=\"onLabelEllipsisChange($event)\"\n >\n {{ label }}\n </span>\n }\n @if (iconPosition === 'right' && !!icon) {\n <span class=\"icon\" aria-hidden=\"true\"\n ><ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"icon\"\n [filled]=\"isFilledIcon || iconFilled\"\n [size]=\"size === 'small' ? '16' : '24'\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n ></ui-icon\n ></span>\n }\n @if (!!trailingIcon && !showInlineSpinner) {\n <span class=\"icon trailing\" aria-hidden=\"true\"\n ><ui-icon\n [color]=\"variant === 'ghost-ai' ? 'ai' : 'inherit'\"\n [applicationTheme]=\"applicationTheme\"\n [name]=\"trailingIcon\"\n [filled]=\"isFilledIcon || trailingIconFilled\"\n [size]=\"size === 'small' ? '16' : '24'\"\n [useFullIconName]=\"variant === 'primary' || variant === 'secondary' || variant === 'linkedin'\"\n ></ui-icon\n ></span>\n }\n </span>\n }\n }\n </button>\n }\n @if (!isButtonLink) {\n <a\n #buttonElement\n [ngClass]=\"classCss\"\n [ngStyle]=\"styleCss\"\n [disabled]=\"disabled\"\n (click)=\"buttonClick($event)\"\n (mouseenter)=\"buttonHover($event)\"\n (mouseleave)=\"buttonHover($event)\"\n (mousedown)=\"onPressed($event)\"\n (mouseup)=\"onPressed($event)\"\n (keydown)=\"onKeydown($event)\"\n (keyup)=\"onKeyup($event)\"\n [disableRipple]=\"true\"\n [attr.aria-required]=\"ariaRequired\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledbyId\"\n [attr.aria-describedby]=\"'describedby-link'\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"ariaExpanded\"\n [attr.aria-controls]=\"ariaControls\"\n [attr.aria-pressed]=\"ariaPressed\"\n [attr.data-testid]=\"testId\"\n [matTooltip]=\"tooltip ? tooltip : labelEllipsis ? label : ''\"\n [matTooltipClass]=\"applicationTheme\"\n role=\"link\"\n [href]=\"url\"\n [target]=\"urlTarget\"\n mat-flat-button\n >\n <span id=\"describedby-link\" [style.display]=\"'none'\">\n {{ ariaDescribedby }}\n </span>\n <span [id]=\"ariaLabelledbyId\" [style.display]=\"'none'\">\n {{ ariaLabelledby }}\n </span>\n <span class=\"icon-label-wrapper\">\n {{ label }}\n </span>\n </a>\n }\n </div>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatTooltipModule } from '@angular/material/tooltip';\n\nimport { BadgeComponentModule } from '@testgorilla/tgo-ui/components/badge';\nimport { EllipseTextDirective, UiTranslatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\n\nimport { ButtonComponent } from './button.component';\n\n@NgModule({\n imports: [\n CommonModule,\n MatButtonModule,\n IconComponentModule,\n MatProgressSpinnerModule,\n MatTooltipModule,\n BadgeComponentModule,\n EllipseTextDirective,\n MatRadioModule,\n UiTranslatePipe,\n ButtonComponent,\n ],\n exports: [ButtonComponent],\n providers: [],\n})\nexport class ButtonComponentModule {}\n"],"mappings":";;;;;;;;;;;AAYA,MAAM,iBAAiB,cAAoD;CACzE,IAAI,YAAY,IACd,OAAO;CAET,IAAI,YAAY,IACd,OAAO;CAET,IAAI,YAAY,MAAM,YAAY,IAChC,OAAO;CAET,OAAO;AACT;AAGA,MAAM,oBAAoB,WAAmB,cAAqC;CAChF,IAAI,cAAc,WAAW,cAAc,WACzC,OAAO;CAET,MAAM,OAAO,cAAc,SAAS;CACpC,OAAO,SAAS,QAAQ,KAAK,OAAO,MAAM;AAC5C;AAGA,MAAM,wBAAwB,WAAmB,cAAqC;CACpF,MAAM,gBAAoF;EACxF,OAAO;GAAE,MAAM;GAAK,KAAK;GAAI,KAAK;EAAG;EACrC,SAAS;GAAE,MAAM;GAAK,KAAK;GAAI,KAAK;EAAG;EACvC,UAAU;GAAE,MAAM;GAAI,KAAK;GAAI,KAAK;EAAE;CACvC;CACD,MAAM,O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