@tectra-ng/ui 0.2.6 → 0.3.1

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 (341) hide show
  1. package/fesm2022/tectra-ng-ui-accordion.mjs +25 -7
  2. package/fesm2022/tectra-ng-ui-accordion.mjs.map +1 -1
  3. package/fesm2022/tectra-ng-ui-amount.mjs +8 -2
  4. package/fesm2022/tectra-ng-ui-amount.mjs.map +1 -1
  5. package/fesm2022/tectra-ng-ui-analog-clock.mjs +4 -2
  6. package/fesm2022/tectra-ng-ui-analog-clock.mjs.map +1 -1
  7. package/fesm2022/tectra-ng-ui-autocomplete.mjs +18 -3
  8. package/fesm2022/tectra-ng-ui-autocomplete.mjs.map +1 -1
  9. package/fesm2022/tectra-ng-ui-avatar.mjs +27 -4
  10. package/fesm2022/tectra-ng-ui-avatar.mjs.map +1 -1
  11. package/fesm2022/tectra-ng-ui-badge.mjs +8 -2
  12. package/fesm2022/tectra-ng-ui-badge.mjs.map +1 -1
  13. package/fesm2022/tectra-ng-ui-breadcrumb.mjs +19 -8
  14. package/fesm2022/tectra-ng-ui-breadcrumb.mjs.map +1 -1
  15. package/fesm2022/tectra-ng-ui-button.mjs +17 -4
  16. package/fesm2022/tectra-ng-ui-button.mjs.map +1 -1
  17. package/fesm2022/tectra-ng-ui-card.mjs +8 -2
  18. package/fesm2022/tectra-ng-ui-card.mjs.map +1 -1
  19. package/fesm2022/tectra-ng-ui-carousel.mjs +13 -2
  20. package/fesm2022/tectra-ng-ui-carousel.mjs.map +1 -1
  21. package/fesm2022/tectra-ng-ui-cascade-select.mjs +19 -3
  22. package/fesm2022/tectra-ng-ui-cascade-select.mjs.map +1 -1
  23. package/fesm2022/tectra-ng-ui-checkbox.mjs +19 -4
  24. package/fesm2022/tectra-ng-ui-checkbox.mjs.map +1 -1
  25. package/fesm2022/tectra-ng-ui-chip.mjs +13 -5
  26. package/fesm2022/tectra-ng-ui-chip.mjs.map +1 -1
  27. package/fesm2022/tectra-ng-ui-chips-input.mjs +23 -5
  28. package/fesm2022/tectra-ng-ui-chips-input.mjs.map +1 -1
  29. package/fesm2022/tectra-ng-ui-color-picker.mjs +15 -3
  30. package/fesm2022/tectra-ng-ui-color-picker.mjs.map +1 -1
  31. package/fesm2022/tectra-ng-ui-confirm.mjs +17 -2
  32. package/fesm2022/tectra-ng-ui-confirm.mjs.map +1 -1
  33. package/fesm2022/tectra-ng-ui-countdown.mjs +8 -2
  34. package/fesm2022/tectra-ng-ui-countdown.mjs.map +1 -1
  35. package/fesm2022/tectra-ng-ui-country-select.mjs +4 -0
  36. package/fesm2022/tectra-ng-ui-country-select.mjs.map +1 -1
  37. package/fesm2022/tectra-ng-ui-country.mjs +16 -3
  38. package/fesm2022/tectra-ng-ui-country.mjs.map +1 -1
  39. package/fesm2022/tectra-ng-ui-data-view.mjs +16 -3
  40. package/fesm2022/tectra-ng-ui-data-view.mjs.map +1 -1
  41. package/fesm2022/tectra-ng-ui-datepicker.mjs +22 -3
  42. package/fesm2022/tectra-ng-ui-datepicker.mjs.map +1 -1
  43. package/fesm2022/tectra-ng-ui-dialog.mjs +33 -5
  44. package/fesm2022/tectra-ng-ui-dialog.mjs.map +1 -1
  45. package/fesm2022/tectra-ng-ui-divider.mjs +4 -2
  46. package/fesm2022/tectra-ng-ui-divider.mjs.map +1 -1
  47. package/fesm2022/tectra-ng-ui-email-suggestion.mjs +8 -2
  48. package/fesm2022/tectra-ng-ui-email-suggestion.mjs.map +1 -1
  49. package/fesm2022/tectra-ng-ui-export.mjs +32 -6
  50. package/fesm2022/tectra-ng-ui-export.mjs.map +1 -1
  51. package/fesm2022/tectra-ng-ui-field.mjs +7 -2
  52. package/fesm2022/tectra-ng-ui-field.mjs.map +1 -1
  53. package/fesm2022/tectra-ng-ui-fieldset.mjs +8 -3
  54. package/fesm2022/tectra-ng-ui-fieldset.mjs.map +1 -1
  55. package/fesm2022/tectra-ng-ui-file-upload.mjs +24 -3
  56. package/fesm2022/tectra-ng-ui-file-upload.mjs.map +1 -1
  57. package/fesm2022/tectra-ng-ui-galleria.mjs +14 -3
  58. package/fesm2022/tectra-ng-ui-galleria.mjs.map +1 -1
  59. package/fesm2022/tectra-ng-ui-highlight-text.mjs +4 -2
  60. package/fesm2022/tectra-ng-ui-highlight-text.mjs.map +1 -1
  61. package/fesm2022/tectra-ng-ui-icon-field.mjs +25 -2
  62. package/fesm2022/tectra-ng-ui-icon-field.mjs.map +1 -1
  63. package/fesm2022/tectra-ng-ui-image.mjs +16 -3
  64. package/fesm2022/tectra-ng-ui-image.mjs.map +1 -1
  65. package/fesm2022/tectra-ng-ui-input-group.mjs +9 -0
  66. package/fesm2022/tectra-ng-ui-input-group.mjs.map +1 -1
  67. package/fesm2022/tectra-ng-ui-input-mask.mjs +4 -2
  68. package/fesm2022/tectra-ng-ui-input-mask.mjs.map +1 -1
  69. package/fesm2022/tectra-ng-ui-input-number.mjs +21 -4
  70. package/fesm2022/tectra-ng-ui-input-number.mjs.map +1 -1
  71. package/fesm2022/tectra-ng-ui-input-otp.mjs +8 -2
  72. package/fesm2022/tectra-ng-ui-input-otp.mjs.map +1 -1
  73. package/fesm2022/tectra-ng-ui-input.mjs +8 -2
  74. package/fesm2022/tectra-ng-ui-input.mjs.map +1 -1
  75. package/fesm2022/tectra-ng-ui-key-filter.mjs +4 -2
  76. package/fesm2022/tectra-ng-ui-key-filter.mjs.map +1 -1
  77. package/fesm2022/tectra-ng-ui-knob.mjs +11 -2
  78. package/fesm2022/tectra-ng-ui-knob.mjs.map +1 -1
  79. package/fesm2022/tectra-ng-ui-label.mjs +19 -1
  80. package/fesm2022/tectra-ng-ui-label.mjs.map +1 -1
  81. package/fesm2022/tectra-ng-ui-link.mjs +22 -4
  82. package/fesm2022/tectra-ng-ui-link.mjs.map +1 -1
  83. package/fesm2022/tectra-ng-ui-list-input.mjs +18 -2
  84. package/fesm2022/tectra-ng-ui-list-input.mjs.map +1 -1
  85. package/fesm2022/tectra-ng-ui-listbox.mjs +17 -3
  86. package/fesm2022/tectra-ng-ui-listbox.mjs.map +1 -1
  87. package/fesm2022/tectra-ng-ui-mention-textarea.mjs +12 -2
  88. package/fesm2022/tectra-ng-ui-mention-textarea.mjs.map +1 -1
  89. package/fesm2022/tectra-ng-ui-menu.mjs +26 -6
  90. package/fesm2022/tectra-ng-ui-menu.mjs.map +1 -1
  91. package/fesm2022/tectra-ng-ui-menubar.mjs +14 -3
  92. package/fesm2022/tectra-ng-ui-menubar.mjs.map +1 -1
  93. package/fesm2022/tectra-ng-ui-message.mjs +25 -5
  94. package/fesm2022/tectra-ng-ui-message.mjs.map +1 -1
  95. package/fesm2022/tectra-ng-ui-month-calendar.mjs +8 -2
  96. package/fesm2022/tectra-ng-ui-month-calendar.mjs.map +1 -1
  97. package/fesm2022/tectra-ng-ui-multiselect.mjs +20 -3
  98. package/fesm2022/tectra-ng-ui-multiselect.mjs.map +1 -1
  99. package/fesm2022/tectra-ng-ui-overlay-badge.mjs +8 -2
  100. package/fesm2022/tectra-ng-ui-overlay-badge.mjs.map +1 -1
  101. package/fesm2022/tectra-ng-ui-paginator.mjs +17 -3
  102. package/fesm2022/tectra-ng-ui-paginator.mjs.map +1 -1
  103. package/fesm2022/tectra-ng-ui-panel-menu.mjs +18 -8
  104. package/fesm2022/tectra-ng-ui-panel-menu.mjs.map +1 -1
  105. package/fesm2022/tectra-ng-ui-panel.mjs +13 -5
  106. package/fesm2022/tectra-ng-ui-panel.mjs.map +1 -1
  107. package/fesm2022/tectra-ng-ui-password.mjs +18 -3
  108. package/fesm2022/tectra-ng-ui-password.mjs.map +1 -1
  109. package/fesm2022/tectra-ng-ui-pill.mjs +13 -5
  110. package/fesm2022/tectra-ng-ui-pill.mjs.map +1 -1
  111. package/fesm2022/tectra-ng-ui-popover.mjs +12 -4
  112. package/fesm2022/tectra-ng-ui-popover.mjs.map +1 -1
  113. package/fesm2022/tectra-ng-ui-progress-bar.mjs +8 -2
  114. package/fesm2022/tectra-ng-ui-progress-bar.mjs.map +1 -1
  115. package/fesm2022/tectra-ng-ui-progress-spinner.mjs +8 -2
  116. package/fesm2022/tectra-ng-ui-progress-spinner.mjs.map +1 -1
  117. package/fesm2022/tectra-ng-ui-radio-button.mjs +14 -2
  118. package/fesm2022/tectra-ng-ui-radio-button.mjs.map +1 -1
  119. package/fesm2022/tectra-ng-ui-rating.mjs +16 -4
  120. package/fesm2022/tectra-ng-ui-rating.mjs.map +1 -1
  121. package/fesm2022/tectra-ng-ui-scroll-panel.mjs +4 -2
  122. package/fesm2022/tectra-ng-ui-scroll-panel.mjs.map +1 -1
  123. package/fesm2022/tectra-ng-ui-select.mjs +26 -3
  124. package/fesm2022/tectra-ng-ui-select.mjs.map +1 -1
  125. package/fesm2022/tectra-ng-ui-skeleton.mjs +11 -2
  126. package/fesm2022/tectra-ng-ui-skeleton.mjs.map +1 -1
  127. package/fesm2022/tectra-ng-ui-slider.mjs +4 -2
  128. package/fesm2022/tectra-ng-ui-slider.mjs.map +1 -1
  129. package/fesm2022/tectra-ng-ui-sparkline.mjs +8 -2
  130. package/fesm2022/tectra-ng-ui-sparkline.mjs.map +1 -1
  131. package/fesm2022/tectra-ng-ui-speed-dial.mjs +12 -2
  132. package/fesm2022/tectra-ng-ui-speed-dial.mjs.map +1 -1
  133. package/fesm2022/tectra-ng-ui-split-button.mjs +8 -2
  134. package/fesm2022/tectra-ng-ui-split-button.mjs.map +1 -1
  135. package/fesm2022/tectra-ng-ui-splitter.mjs +5 -2
  136. package/fesm2022/tectra-ng-ui-splitter.mjs.map +1 -1
  137. package/fesm2022/tectra-ng-ui-stat-tiles.mjs +19 -5
  138. package/fesm2022/tectra-ng-ui-stat-tiles.mjs.map +1 -1
  139. package/fesm2022/tectra-ng-ui-status-icon.mjs +17 -5
  140. package/fesm2022/tectra-ng-ui-status-icon.mjs.map +1 -1
  141. package/fesm2022/tectra-ng-ui-stepper.mjs +37 -7
  142. package/fesm2022/tectra-ng-ui-stepper.mjs.map +1 -1
  143. package/fesm2022/tectra-ng-ui-table.mjs +1180 -1262
  144. package/fesm2022/tectra-ng-ui-table.mjs.map +1 -1
  145. package/fesm2022/tectra-ng-ui-tabs.mjs +25 -4
  146. package/fesm2022/tectra-ng-ui-tabs.mjs.map +1 -1
  147. package/fesm2022/tectra-ng-ui-tag.mjs +19 -4
  148. package/fesm2022/tectra-ng-ui-tag.mjs.map +1 -1
  149. package/fesm2022/tectra-ng-ui-textarea.mjs +6 -2
  150. package/fesm2022/tectra-ng-ui-textarea.mjs.map +1 -1
  151. package/fesm2022/tectra-ng-ui-timeline.mjs +8 -2
  152. package/fesm2022/tectra-ng-ui-timeline.mjs.map +1 -1
  153. package/fesm2022/tectra-ng-ui-toast.mjs +20 -4
  154. package/fesm2022/tectra-ng-ui-toast.mjs.map +1 -1
  155. package/fesm2022/tectra-ng-ui-toggle-button.mjs +7 -5
  156. package/fesm2022/tectra-ng-ui-toggle-button.mjs.map +1 -1
  157. package/fesm2022/tectra-ng-ui-toggle-switch.mjs +6 -4
  158. package/fesm2022/tectra-ng-ui-toggle-switch.mjs.map +1 -1
  159. package/fesm2022/tectra-ng-ui-toolbar.mjs +4 -2
  160. package/fesm2022/tectra-ng-ui-toolbar.mjs.map +1 -1
  161. package/fesm2022/tectra-ng-ui-tooltip.mjs +5 -2
  162. package/fesm2022/tectra-ng-ui-tooltip.mjs.map +1 -1
  163. package/fesm2022/tectra-ng-ui-tree-select.mjs +23 -3
  164. package/fesm2022/tectra-ng-ui-tree-select.mjs.map +1 -1
  165. package/fesm2022/tectra-ng-ui-tree-table.mjs +107 -213
  166. package/fesm2022/tectra-ng-ui-tree-table.mjs.map +1 -1
  167. package/fesm2022/tectra-ng-ui-tree.mjs +20 -3
  168. package/fesm2022/tectra-ng-ui-tree.mjs.map +1 -1
  169. package/fesm2022/tectra-ng-ui-truncate-text.mjs +14 -3
  170. package/fesm2022/tectra-ng-ui-truncate-text.mjs.map +1 -1
  171. package/fesm2022/tectra-ng-ui-virtual-scroller.mjs +8 -3
  172. package/fesm2022/tectra-ng-ui-virtual-scroller.mjs.map +1 -1
  173. package/package.json +4 -4
  174. package/types/tectra-ng-ui-accordion.d.ts +4 -0
  175. package/types/tectra-ng-ui-accordion.d.ts.map +1 -1
  176. package/types/tectra-ng-ui-amount.d.ts +1 -0
  177. package/types/tectra-ng-ui-amount.d.ts.map +1 -1
  178. package/types/tectra-ng-ui-analog-clock.d.ts +1 -0
  179. package/types/tectra-ng-ui-analog-clock.d.ts.map +1 -1
  180. package/types/tectra-ng-ui-autocomplete.d.ts +1 -0
  181. package/types/tectra-ng-ui-autocomplete.d.ts.map +1 -1
  182. package/types/tectra-ng-ui-avatar.d.ts +3 -0
  183. package/types/tectra-ng-ui-avatar.d.ts.map +1 -1
  184. package/types/tectra-ng-ui-badge.d.ts +1 -0
  185. package/types/tectra-ng-ui-badge.d.ts.map +1 -1
  186. package/types/tectra-ng-ui-breadcrumb.d.ts +1 -0
  187. package/types/tectra-ng-ui-breadcrumb.d.ts.map +1 -1
  188. package/types/tectra-ng-ui-button.d.ts +1 -0
  189. package/types/tectra-ng-ui-button.d.ts.map +1 -1
  190. package/types/tectra-ng-ui-card.d.ts +1 -0
  191. package/types/tectra-ng-ui-card.d.ts.map +1 -1
  192. package/types/tectra-ng-ui-carousel.d.ts +1 -0
  193. package/types/tectra-ng-ui-carousel.d.ts.map +1 -1
  194. package/types/tectra-ng-ui-cascade-select.d.ts +1 -0
  195. package/types/tectra-ng-ui-cascade-select.d.ts.map +1 -1
  196. package/types/tectra-ng-ui-checkbox.d.ts +2 -0
  197. package/types/tectra-ng-ui-checkbox.d.ts.map +1 -1
  198. package/types/tectra-ng-ui-chip.d.ts +1 -0
  199. package/types/tectra-ng-ui-chip.d.ts.map +1 -1
  200. package/types/tectra-ng-ui-chips-input.d.ts +1 -0
  201. package/types/tectra-ng-ui-chips-input.d.ts.map +1 -1
  202. package/types/tectra-ng-ui-color-picker.d.ts +1 -0
  203. package/types/tectra-ng-ui-color-picker.d.ts.map +1 -1
  204. package/types/tectra-ng-ui-confirm.d.ts +2 -0
  205. package/types/tectra-ng-ui-confirm.d.ts.map +1 -1
  206. package/types/tectra-ng-ui-countdown.d.ts +1 -0
  207. package/types/tectra-ng-ui-countdown.d.ts.map +1 -1
  208. package/types/tectra-ng-ui-country-select.d.ts +1 -0
  209. package/types/tectra-ng-ui-country-select.d.ts.map +1 -1
  210. package/types/tectra-ng-ui-country.d.ts +1 -0
  211. package/types/tectra-ng-ui-country.d.ts.map +1 -1
  212. package/types/tectra-ng-ui-data-view.d.ts +2 -0
  213. package/types/tectra-ng-ui-data-view.d.ts.map +1 -1
  214. package/types/tectra-ng-ui-datepicker.d.ts +1 -0
  215. package/types/tectra-ng-ui-datepicker.d.ts.map +1 -1
  216. package/types/tectra-ng-ui-dialog.d.ts +7 -0
  217. package/types/tectra-ng-ui-dialog.d.ts.map +1 -1
  218. package/types/tectra-ng-ui-divider.d.ts +1 -0
  219. package/types/tectra-ng-ui-divider.d.ts.map +1 -1
  220. package/types/tectra-ng-ui-email-suggestion.d.ts +1 -0
  221. package/types/tectra-ng-ui-email-suggestion.d.ts.map +1 -1
  222. package/types/tectra-ng-ui-export.d.ts.map +1 -1
  223. package/types/tectra-ng-ui-field.d.ts +1 -0
  224. package/types/tectra-ng-ui-field.d.ts.map +1 -1
  225. package/types/tectra-ng-ui-fieldset.d.ts +1 -0
  226. package/types/tectra-ng-ui-fieldset.d.ts.map +1 -1
  227. package/types/tectra-ng-ui-file-upload.d.ts +1 -0
  228. package/types/tectra-ng-ui-file-upload.d.ts.map +1 -1
  229. package/types/tectra-ng-ui-galleria.d.ts +1 -0
  230. package/types/tectra-ng-ui-galleria.d.ts.map +1 -1
  231. package/types/tectra-ng-ui-highlight-text.d.ts +1 -0
  232. package/types/tectra-ng-ui-highlight-text.d.ts.map +1 -1
  233. package/types/tectra-ng-ui-icon-field.d.ts +6 -2
  234. package/types/tectra-ng-ui-icon-field.d.ts.map +1 -1
  235. package/types/tectra-ng-ui-image.d.ts +1 -0
  236. package/types/tectra-ng-ui-image.d.ts.map +1 -1
  237. package/types/tectra-ng-ui-input-group.d.ts +2 -0
  238. package/types/tectra-ng-ui-input-group.d.ts.map +1 -1
  239. package/types/tectra-ng-ui-input-mask.d.ts.map +1 -1
  240. package/types/tectra-ng-ui-input-number.d.ts +1 -0
  241. package/types/tectra-ng-ui-input-number.d.ts.map +1 -1
  242. package/types/tectra-ng-ui-input-otp.d.ts +1 -0
  243. package/types/tectra-ng-ui-input-otp.d.ts.map +1 -1
  244. package/types/tectra-ng-ui-input.d.ts +1 -0
  245. package/types/tectra-ng-ui-input.d.ts.map +1 -1
  246. package/types/tectra-ng-ui-key-filter.d.ts.map +1 -1
  247. package/types/tectra-ng-ui-knob.d.ts +1 -0
  248. package/types/tectra-ng-ui-knob.d.ts.map +1 -1
  249. package/types/tectra-ng-ui-label.d.ts +3 -0
  250. package/types/tectra-ng-ui-label.d.ts.map +1 -1
  251. package/types/tectra-ng-ui-link.d.ts +2 -0
  252. package/types/tectra-ng-ui-link.d.ts.map +1 -1
  253. package/types/tectra-ng-ui-list-input.d.ts +1 -0
  254. package/types/tectra-ng-ui-list-input.d.ts.map +1 -1
  255. package/types/tectra-ng-ui-listbox.d.ts +1 -0
  256. package/types/tectra-ng-ui-listbox.d.ts.map +1 -1
  257. package/types/tectra-ng-ui-mention-textarea.d.ts +1 -0
  258. package/types/tectra-ng-ui-mention-textarea.d.ts.map +1 -1
  259. package/types/tectra-ng-ui-menu.d.ts +4 -0
  260. package/types/tectra-ng-ui-menu.d.ts.map +1 -1
  261. package/types/tectra-ng-ui-menubar.d.ts +1 -0
  262. package/types/tectra-ng-ui-menubar.d.ts.map +1 -1
  263. package/types/tectra-ng-ui-message.d.ts +3 -0
  264. package/types/tectra-ng-ui-message.d.ts.map +1 -1
  265. package/types/tectra-ng-ui-month-calendar.d.ts +1 -0
  266. package/types/tectra-ng-ui-month-calendar.d.ts.map +1 -1
  267. package/types/tectra-ng-ui-multiselect.d.ts +1 -0
  268. package/types/tectra-ng-ui-multiselect.d.ts.map +1 -1
  269. package/types/tectra-ng-ui-overlay-badge.d.ts +1 -0
  270. package/types/tectra-ng-ui-overlay-badge.d.ts.map +1 -1
  271. package/types/tectra-ng-ui-paginator.d.ts +1 -0
  272. package/types/tectra-ng-ui-paginator.d.ts.map +1 -1
  273. package/types/tectra-ng-ui-panel-menu.d.ts +1 -0
  274. package/types/tectra-ng-ui-panel-menu.d.ts.map +1 -1
  275. package/types/tectra-ng-ui-panel.d.ts +1 -0
  276. package/types/tectra-ng-ui-panel.d.ts.map +1 -1
  277. package/types/tectra-ng-ui-password.d.ts +1 -0
  278. package/types/tectra-ng-ui-password.d.ts.map +1 -1
  279. package/types/tectra-ng-ui-pill.d.ts +1 -0
  280. package/types/tectra-ng-ui-pill.d.ts.map +1 -1
  281. package/types/tectra-ng-ui-popover.d.ts +2 -0
  282. package/types/tectra-ng-ui-popover.d.ts.map +1 -1
  283. package/types/tectra-ng-ui-progress-bar.d.ts +1 -0
  284. package/types/tectra-ng-ui-progress-bar.d.ts.map +1 -1
  285. package/types/tectra-ng-ui-progress-spinner.d.ts +1 -0
  286. package/types/tectra-ng-ui-progress-spinner.d.ts.map +1 -1
  287. package/types/tectra-ng-ui-radio-button.d.ts +2 -0
  288. package/types/tectra-ng-ui-radio-button.d.ts.map +1 -1
  289. package/types/tectra-ng-ui-rating.d.ts +1 -0
  290. package/types/tectra-ng-ui-rating.d.ts.map +1 -1
  291. package/types/tectra-ng-ui-scroll-panel.d.ts +1 -0
  292. package/types/tectra-ng-ui-scroll-panel.d.ts.map +1 -1
  293. package/types/tectra-ng-ui-select.d.ts +3 -1
  294. package/types/tectra-ng-ui-select.d.ts.map +1 -1
  295. package/types/tectra-ng-ui-skeleton.d.ts +2 -0
  296. package/types/tectra-ng-ui-skeleton.d.ts.map +1 -1
  297. package/types/tectra-ng-ui-slider.d.ts +1 -0
  298. package/types/tectra-ng-ui-slider.d.ts.map +1 -1
  299. package/types/tectra-ng-ui-sparkline.d.ts +1 -0
  300. package/types/tectra-ng-ui-sparkline.d.ts.map +1 -1
  301. package/types/tectra-ng-ui-speed-dial.d.ts +1 -0
  302. package/types/tectra-ng-ui-speed-dial.d.ts.map +1 -1
  303. package/types/tectra-ng-ui-split-button.d.ts +1 -0
  304. package/types/tectra-ng-ui-split-button.d.ts.map +1 -1
  305. package/types/tectra-ng-ui-splitter.d.ts +2 -0
  306. package/types/tectra-ng-ui-splitter.d.ts.map +1 -1
  307. package/types/tectra-ng-ui-stat-tiles.d.ts +2 -0
  308. package/types/tectra-ng-ui-stat-tiles.d.ts.map +1 -1
  309. package/types/tectra-ng-ui-status-icon.d.ts +1 -0
  310. package/types/tectra-ng-ui-status-icon.d.ts.map +1 -1
  311. package/types/tectra-ng-ui-stepper.d.ts +7 -0
  312. package/types/tectra-ng-ui-stepper.d.ts.map +1 -1
  313. package/types/tectra-ng-ui-table.d.ts +15 -2
  314. package/types/tectra-ng-ui-table.d.ts.map +1 -1
  315. package/types/tectra-ng-ui-tabs.d.ts +5 -0
  316. package/types/tectra-ng-ui-tabs.d.ts.map +1 -1
  317. package/types/tectra-ng-ui-tag.d.ts +2 -0
  318. package/types/tectra-ng-ui-tag.d.ts.map +1 -1
  319. package/types/tectra-ng-ui-textarea.d.ts +2 -0
  320. package/types/tectra-ng-ui-textarea.d.ts.map +1 -1
  321. package/types/tectra-ng-ui-timeline.d.ts +1 -0
  322. package/types/tectra-ng-ui-timeline.d.ts.map +1 -1
  323. package/types/tectra-ng-ui-toast.d.ts +1 -0
  324. package/types/tectra-ng-ui-toast.d.ts.map +1 -1
  325. package/types/tectra-ng-ui-toggle-button.d.ts +1 -0
  326. package/types/tectra-ng-ui-toggle-button.d.ts.map +1 -1
  327. package/types/tectra-ng-ui-toggle-switch.d.ts +1 -0
  328. package/types/tectra-ng-ui-toggle-switch.d.ts.map +1 -1
  329. package/types/tectra-ng-ui-toolbar.d.ts +1 -0
  330. package/types/tectra-ng-ui-toolbar.d.ts.map +1 -1
  331. package/types/tectra-ng-ui-tooltip.d.ts +2 -0
  332. package/types/tectra-ng-ui-tooltip.d.ts.map +1 -1
  333. package/types/tectra-ng-ui-tree-select.d.ts +1 -0
  334. package/types/tectra-ng-ui-tree-select.d.ts.map +1 -1
  335. package/types/tectra-ng-ui-tree-table.d.ts.map +1 -1
  336. package/types/tectra-ng-ui-tree.d.ts +1 -0
  337. package/types/tectra-ng-ui-tree.d.ts.map +1 -1
  338. package/types/tectra-ng-ui-truncate-text.d.ts +1 -0
  339. package/types/tectra-ng-ui-truncate-text.d.ts.map +1 -1
  340. package/types/tectra-ng-ui-virtual-scroller.d.ts +1 -0
  341. package/types/tectra-ng-ui-virtual-scroller.d.ts.map +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"tectra-ng-ui-knob.mjs","names":[],"sources":["../../../../packages/ui/knob/src/knob-templates.directive.ts","../../../../packages/ui/knob/src/knob.component.ts","../../../../packages/ui/knob/src/knob.component.html"],"sourcesContent":["import { Directive, TemplateRef, inject } from '@angular/core';\nimport { TxKnobValueContext } from './knob.types';\n\n@Directive({ selector: 'ng-template[txKnobValue]' })\nexport class TxKnobValueTemplate {\n readonly templateRef = inject<TemplateRef<TxKnobValueContext>>(TemplateRef);\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ElementRef, booleanAttribute, computed, contentChild, forwardRef, inject, input, numberAttribute, output, signal, viewChild } from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { TxFormControlBase, injectFieldInvalid } from '@tectra-ng/core/forms';\nimport { TxLocaleService } from '@tectra-ng/core/i18n';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { TectraDeepPartial, TectraKnobTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxKnobValueTemplate } from './knob-templates.directive';\nimport { TxKnobArc, TxKnobChangeEvent, TxKnobPart } from './knob.types';\n\nconst CENTER = 50;\n\n@Component({\n selector: 'tx-knob',\n imports: [NgTemplateOutlet],\n templateUrl: './knob.component.html',\n styleUrl: './knob.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => TxKnob), multi: true }],\n host: {\n class: 'tx-knob',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-arc]': 'arc()',\n '[class.tx-knob--dragging]': 'isDragging()',\n '[class.tx-knob--disabled]': 'isDisabled()',\n '[class.tx-knob--readonly]': 'readonly()',\n '[class.tx-knob--invalid]': 'isInvalid()',\n },\n})\nexport class TxKnob extends TxFormControlBase<number> {\n private localeService = inject(TxLocaleService);\n private lastFraction = 0;\n\n readonly min = input<number, unknown>(0, { transform: numberAttribute });\n readonly max = input<number, unknown>(100, { transform: numberAttribute });\n readonly step = input<number, unknown>(1, { transform: numberAttribute });\n readonly limit = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly size = input<number, unknown>(100, { transform: numberAttribute });\n readonly strokeWidth = input<number, unknown>(12, { transform: numberAttribute });\n readonly arc = input<TxKnobArc>('dial');\n readonly showValue = input<boolean, unknown>(true, { transform: booleanAttribute });\n readonly showHandle = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly valueTemplate = input<string>('{value}');\n readonly invalid = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n // eslint-disable-next-line @angular-eslint/no-input-rename\n readonly disabledInput = input<boolean, unknown>(false, { alias: 'disabled', transform: booleanAttribute });\n readonly readonly = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly ariaLabel = input<string | undefined>(undefined);\n readonly ariaLabelledBy = input<string | undefined>(undefined);\n readonly tabindex = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly dt = input<TectraDeepPartial<TectraKnobTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxKnobPart, TxKnob> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly changed = output<TxKnobChangeEvent>();\n\n readonly template = contentChild(TxKnobValueTemplate);\n readonly svg = viewChild.required<ElementRef<SVGSVGElement>>('svg');\n\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly isInvalid = injectFieldInvalid(this.invalid);\n readonly passThrough = injectPassThrough('knob', this, this.pt, this.ptOptions);\n\n readonly isDragging = signal(false);\n readonly isDisabled = computed(() => this.disabled() || this.disabledInput());\n readonly isEditable = computed(() => !this.isDisabled() && !this.readonly());\n readonly ceiling = computed(() => Math.min(this.max(), this.limit() ?? this.max()));\n readonly current = computed(() => this.clamp(this.value() ?? this.min()));\n readonly radius = computed(() => CENTER - this.strokeWidth() / 2 - (this.hasHandle() ? 3 : 0));\n readonly sweep = computed(() => (this.arc() === 'ring' ? 360 : 270));\n readonly start = computed(() => (this.arc() === 'ring' ? -90 : 135));\n readonly span = computed(() => (this.sweep() / 360) * 100);\n readonly hasHandle = computed(() => this.showHandle() ?? this.arc() === 'ring');\n readonly fraction = computed(() => this.fractionOf(this.current()));\n readonly limitFraction = computed(() => (this.limit() === undefined ? 1 : this.fractionOf(this.ceiling())));\n readonly rotate = computed(() => `rotate(${this.start()} ${CENTER} ${CENTER})`);\n readonly valueDash = computed(() => `${this.fraction() * this.span()} 100`);\n readonly rangeDash = computed(() => `${this.span()} 100`);\n readonly limitDash = computed(() => `0 ${this.limitFraction() * this.span()} ${(1 - this.limitFraction()) * this.span()} 100`);\n readonly handle = computed(() => this.point(this.fraction()));\n readonly text = computed(() => this.valueTemplate().replace('{value}', this.localeService.formatNumber(this.current())));\n readonly hostStyle = computed(() => ({\n ...toStyleObject(this.dt(), '--tx-knob'),\n width: `${this.size()}px`,\n height: `${this.size()}px`,\n ...this.passThrough().root?.style,\n }));\n\n readonly center = CENTER;\n\n onPointerDown(event: PointerEvent): void {\n if (!this.isEditable() || event.button !== 0) {\n return;\n }\n event.preventDefault();\n (event.currentTarget as Element).setPointerCapture?.(event.pointerId);\n (event.currentTarget as HTMLElement).focus();\n this.isDragging.set(true);\n this.lastFraction = this.fraction();\n this.moveTo(event, true);\n }\n\n onPointerMove(event: PointerEvent): void {\n if (this.isDragging()) {\n this.moveTo(event, false);\n }\n }\n\n onPointerUp(): void {\n if (this.isDragging()) {\n this.isDragging.set(false);\n this.markTouched();\n }\n }\n\n onKeydown(event: KeyboardEvent): void {\n if (!this.isEditable()) {\n return;\n }\n const value = this.current();\n const step = this.step();\n const moves: Record<string, number> = {\n ArrowRight: value + step,\n ArrowUp: value + step,\n ArrowLeft: value - step,\n ArrowDown: value - step,\n PageUp: value + step * 10,\n PageDown: value - step * 10,\n Home: this.min(),\n End: this.ceiling(),\n };\n if (event.key in moves) {\n event.preventDefault();\n this.commit(moves[event.key], event);\n }\n }\n\n onBlur(): void {\n this.markTouched();\n }\n\n private moveTo(event: PointerEvent, first: boolean): void {\n const rect = this.svg().nativeElement.getBoundingClientRect();\n if (!rect.width) {\n return;\n }\n const x = ((event.clientX - rect.left) / rect.width) * 100 - CENTER;\n const y = ((event.clientY - rect.top) / rect.height) * 100 - CENTER;\n const angle = (Math.atan2(y, x) * 180) / Math.PI;\n let relative = (angle - this.start() + 720) % 360;\n if (relative > this.sweep()) {\n relative = relative > this.sweep() + (360 - this.sweep()) / 2 ? 0 : this.sweep();\n }\n let fraction = relative / this.sweep();\n if (!first && this.arc() === 'ring' && Math.abs(fraction - this.lastFraction) > 0.5) {\n fraction = this.lastFraction > 0.5 ? 1 : 0;\n }\n this.lastFraction = fraction;\n this.commit(this.min() + fraction * (this.max() - this.min()), event);\n }\n\n private commit(raw: number, event: Event): void {\n const step = this.step();\n const snapped = Math.round((raw - this.min()) / step) * step + this.min();\n const value = Number(this.clamp(snapped).toFixed(decimals(step)));\n if (value !== this.value()) {\n this.updateValue(value);\n this.changed.emit({ value, originalEvent: event });\n }\n }\n\n private clamp(value: number): number {\n return Math.min(this.ceiling(), Math.max(this.min(), value));\n }\n\n private fractionOf(value: number): number {\n const range = this.max() - this.min();\n return range > 0 ? (value - this.min()) / range : 0;\n }\n\n private point(fraction: number): { x: number; y: number } {\n const angle = ((this.start() + fraction * this.sweep()) * Math.PI) / 180;\n return { x: CENTER + this.radius() * Math.cos(angle), y: CENTER + this.radius() * Math.sin(angle) };\n }\n}\n\nfunction decimals(value: number): number {\n const text = String(value);\n return text.includes('.') ? text.split('.')[1].length : 0;\n}\n","<div\n class=\"tx-knob__control\"\n role=\"slider\"\n [attr.tabindex]=\"isDisabled() ? -1 : (tabindex() ?? 0)\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-valuemin]=\"min()\"\n [attr.aria-valuemax]=\"ceiling()\"\n [attr.aria-valuenow]=\"current()\"\n [attr.aria-valuetext]=\"text()\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-disabled]=\"isDisabled() || null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n (pointerdown)=\"onPointerDown($event)\"\n (pointermove)=\"onPointerMove($event)\"\n (pointerup)=\"onPointerUp()\"\n (pointercancel)=\"onPointerUp()\"\n (keydown)=\"onKeydown($event)\"\n (blur)=\"onBlur()\"\n>\n <svg #svg class=\"tx-knob__svg\" viewBox=\"0 0 100 100\" aria-hidden=\"true\" [class]=\"passThrough().svg?.class\" [style]=\"passThrough().svg?.style\">\n <circle\n class=\"tx-knob__range\"\n pathLength=\"100\"\n fill=\"none\"\n [class]=\"passThrough().range?.class\"\n [style]=\"passThrough().range?.style\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"rangeDash()\"\n [attr.transform]=\"rotate()\"\n />\n @if (limit() !== undefined && limitFraction() < 1) {\n <circle\n class=\"tx-knob__limit\"\n pathLength=\"100\"\n fill=\"none\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"limitDash()\"\n [attr.transform]=\"rotate()\"\n />\n }\n @if (fraction() > 0) {\n <circle\n class=\"tx-knob__value\"\n pathLength=\"100\"\n fill=\"none\"\n [class]=\"passThrough().value?.class\"\n [style]=\"passThrough().value?.style\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"valueDash()\"\n [attr.transform]=\"rotate()\"\n />\n }\n @if (hasHandle()) {\n <circle\n class=\"tx-knob__handle\"\n [class]=\"passThrough().handle?.class\"\n [style]=\"passThrough().handle?.style\"\n [attr.cx]=\"handle().x\"\n [attr.cy]=\"handle().y\"\n [attr.r]=\"strokeWidth() / 2 + 2\"\n />\n }\n </svg>\n @if (showValue()) {\n <span class=\"tx-knob__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">\n @if (template(); as custom) {\n <ng-container [ngTemplateOutlet]=\"custom.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: current() }\" />\n } @else {\n {{ text() }}\n }\n </span>\n }\n</div>\n"],"mappings":";;;;;;;;;AAIA,IAAa,sBAAb,MAAa,oBAAmB;CACrB,cAAc,OAAwC,WAAW;CAD/D,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAmB,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAnB,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAAmB,cAAA;EAAA,UAAA;EAAA,UAAA;CAAA,CAAA;;AAAnB,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CA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MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,IAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,WAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,SAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,SAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,GAAA,iBAAA,mBAAmB,GAAA,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;EAAA,KAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CACS,OAAK,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;CAAA;AAAA,CAAA;AAiIpE,SAAS,SAAS,OAAa;CAC7B,MAAM,OAAO,OAAO,KAAK;CACzB,OAAO,KAAK,SAAS,GAAG,IAAI,KAAK,MAAM,GAAG,CAAC,CAAC,EAAE,CAAC,SAAS;AAC1D"}
1
+ {"version":3,"file":"tectra-ng-ui-knob.mjs","names":[],"sources":["../../../../packages/ui/knob/src/knob-templates.directive.ts","../../../../packages/ui/knob/src/knob.icons.ts","../../../../packages/ui/knob/src/knob.theme.ts","../../../../packages/ui/knob/src/knob.component.ts","../../../../packages/ui/knob/src/knob.component.html"],"sourcesContent":["import { Directive, TemplateRef, inject } from '@angular/core';\nimport { TxKnobValueContext } from './knob.types';\n\n@Directive({ selector: 'ng-template[txKnobValue]' })\nexport class TxKnobValueTemplate {\n readonly templateRef = inject<TemplateRef<TxKnobValueContext>>(TemplateRef);\n}\n","import { TxIconSet, txIconText } from '@tectra-ng/icons';\n\nexport const KNOB_ICON_DEFAULTS: TxIconSet = {\n text: txIconText,\n};\n","import { formFieldTokens, knobTokens } from '@tectra-ng/themes';\n\nexport const KNOB_THEME = {\n formField: formFieldTokens,\n knob: knobTokens,\n};\n","import { NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ElementRef, booleanAttribute, computed, contentChild, forwardRef, inject, input, numberAttribute, output, signal, viewChild } from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { injectPassThrough, injectTokens, injectUnstyled, TxPassThrough, TxPassThroughOptions } from '@tectra-ng/core/config';\nimport { TxFormControlBase, injectFieldInvalid } from '@tectra-ng/core/forms';\nimport { TxLocaleService } from '@tectra-ng/core/i18n';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { TectraDeepPartial, TectraKnobTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxKnobValueTemplate } from './knob-templates.directive';\nimport { TxKnobArc, TxKnobChangeEvent, TxKnobPart } from './knob.types';\nimport { provideTxIconDefaults } from '@tectra-ng/icons';\nimport { KNOB_ICON_DEFAULTS } from './knob.icons';\nimport { KNOB_THEME } from './knob.theme';\n\nconst CENTER = 50;\n\n@Component({\n selector: 'tx-knob',\n imports: [NgTemplateOutlet],\n templateUrl: './knob.component.html',\n styleUrl: './knob.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => TxKnob), multi: true }],\n host: {\n class: 'tx-knob',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-arc]': 'arc()',\n '[class.tx-knob--dragging]': 'isDragging()',\n '[class.tx-knob--disabled]': 'isDisabled()',\n '[class.tx-knob--readonly]': 'readonly()',\n '[class.tx-knob--invalid]': 'isInvalid()',\n },\n viewProviders: [provideTxIconDefaults(KNOB_ICON_DEFAULTS)],\n})\nexport class TxKnob extends TxFormControlBase<number> {\n private readonly knobTheme = injectTokens(KNOB_THEME);\n\n private localeService = inject(TxLocaleService);\n private lastFraction = 0;\n\n readonly min = input<number, unknown>(0, { transform: numberAttribute });\n readonly max = input<number, unknown>(100, { transform: numberAttribute });\n readonly step = input<number, unknown>(1, { transform: numberAttribute });\n readonly limit = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly size = input<number, unknown>(100, { transform: numberAttribute });\n readonly strokeWidth = input<number, unknown>(12, { transform: numberAttribute });\n readonly arc = input<TxKnobArc>('dial');\n readonly showValue = input<boolean, unknown>(true, { transform: booleanAttribute });\n readonly showHandle = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly valueTemplate = input<string>('{value}');\n readonly invalid = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n // eslint-disable-next-line @angular-eslint/no-input-rename\n readonly disabledInput = input<boolean, unknown>(false, { alias: 'disabled', transform: booleanAttribute });\n readonly readonly = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly ariaLabel = input<string | undefined>(undefined);\n readonly ariaLabelledBy = input<string | undefined>(undefined);\n readonly tabindex = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly dt = input<TectraDeepPartial<TectraKnobTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxKnobPart, TxKnob> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly changed = output<TxKnobChangeEvent>();\n\n readonly template = contentChild(TxKnobValueTemplate);\n readonly svg = viewChild.required<ElementRef<SVGSVGElement>>('svg');\n\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly isInvalid = injectFieldInvalid(this.invalid);\n readonly passThrough = injectPassThrough('knob', this, this.pt, this.ptOptions);\n\n readonly isDragging = signal(false);\n readonly isDisabled = computed(() => this.disabled() || this.disabledInput());\n readonly isEditable = computed(() => !this.isDisabled() && !this.readonly());\n readonly ceiling = computed(() => Math.min(this.max(), this.limit() ?? this.max()));\n readonly current = computed(() => this.clamp(this.value() ?? this.min()));\n readonly radius = computed(() => CENTER - this.strokeWidth() / 2 - (this.hasHandle() ? 3 : 0));\n readonly sweep = computed(() => (this.arc() === 'ring' ? 360 : 270));\n readonly start = computed(() => (this.arc() === 'ring' ? -90 : 135));\n readonly span = computed(() => (this.sweep() / 360) * 100);\n readonly hasHandle = computed(() => this.showHandle() ?? this.arc() === 'ring');\n readonly fraction = computed(() => this.fractionOf(this.current()));\n readonly limitFraction = computed(() => (this.limit() === undefined ? 1 : this.fractionOf(this.ceiling())));\n readonly rotate = computed(() => `rotate(${this.start()} ${CENTER} ${CENTER})`);\n readonly valueDash = computed(() => `${this.fraction() * this.span()} 100`);\n readonly rangeDash = computed(() => `${this.span()} 100`);\n readonly limitDash = computed(() => `0 ${this.limitFraction() * this.span()} ${(1 - this.limitFraction()) * this.span()} 100`);\n readonly handle = computed(() => this.point(this.fraction()));\n readonly text = computed(() => this.valueTemplate().replace('{value}', this.localeService.formatNumber(this.current())));\n readonly hostStyle = computed(() => ({\n ...toStyleObject(this.dt(), '--tx-knob'),\n width: `${this.size()}px`,\n height: `${this.size()}px`,\n ...this.passThrough().root?.style,\n }));\n\n readonly center = CENTER;\n\n onPointerDown(event: PointerEvent): void {\n if (!this.isEditable() || event.button !== 0) {\n return;\n }\n event.preventDefault();\n (event.currentTarget as Element).setPointerCapture?.(event.pointerId);\n (event.currentTarget as HTMLElement).focus();\n this.isDragging.set(true);\n this.lastFraction = this.fraction();\n this.moveTo(event, true);\n }\n\n onPointerMove(event: PointerEvent): void {\n if (this.isDragging()) {\n this.moveTo(event, false);\n }\n }\n\n onPointerUp(): void {\n if (this.isDragging()) {\n this.isDragging.set(false);\n this.markTouched();\n }\n }\n\n onKeydown(event: KeyboardEvent): void {\n if (!this.isEditable()) {\n return;\n }\n const value = this.current();\n const step = this.step();\n const moves: Record<string, number> = {\n ArrowRight: value + step,\n ArrowUp: value + step,\n ArrowLeft: value - step,\n ArrowDown: value - step,\n PageUp: value + step * 10,\n PageDown: value - step * 10,\n Home: this.min(),\n End: this.ceiling(),\n };\n if (event.key in moves) {\n event.preventDefault();\n this.commit(moves[event.key], event);\n }\n }\n\n onBlur(): void {\n this.markTouched();\n }\n\n private moveTo(event: PointerEvent, first: boolean): void {\n const rect = this.svg().nativeElement.getBoundingClientRect();\n if (!rect.width) {\n return;\n }\n const x = ((event.clientX - rect.left) / rect.width) * 100 - CENTER;\n const y = ((event.clientY - rect.top) / rect.height) * 100 - CENTER;\n const angle = (Math.atan2(y, x) * 180) / Math.PI;\n let relative = (angle - this.start() + 720) % 360;\n if (relative > this.sweep()) {\n relative = relative > this.sweep() + (360 - this.sweep()) / 2 ? 0 : this.sweep();\n }\n let fraction = relative / this.sweep();\n if (!first && this.arc() === 'ring' && Math.abs(fraction - this.lastFraction) > 0.5) {\n fraction = this.lastFraction > 0.5 ? 1 : 0;\n }\n this.lastFraction = fraction;\n this.commit(this.min() + fraction * (this.max() - this.min()), event);\n }\n\n private commit(raw: number, event: Event): void {\n const step = this.step();\n const snapped = Math.round((raw - this.min()) / step) * step + this.min();\n const value = Number(this.clamp(snapped).toFixed(decimals(step)));\n if (value !== this.value()) {\n this.updateValue(value);\n this.changed.emit({ value, originalEvent: event });\n }\n }\n\n private clamp(value: number): number {\n return Math.min(this.ceiling(), Math.max(this.min(), value));\n }\n\n private fractionOf(value: number): number {\n const range = this.max() - this.min();\n return range > 0 ? (value - this.min()) / range : 0;\n }\n\n private point(fraction: number): { x: number; y: number } {\n const angle = ((this.start() + fraction * this.sweep()) * Math.PI) / 180;\n return { x: CENTER + this.radius() * Math.cos(angle), y: CENTER + this.radius() * Math.sin(angle) };\n }\n}\n\nfunction decimals(value: number): number {\n const text = String(value);\n return text.includes('.') ? text.split('.')[1].length : 0;\n}\n","<div\n class=\"tx-knob__control\"\n role=\"slider\"\n [attr.tabindex]=\"isDisabled() ? -1 : (tabindex() ?? 0)\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-valuemin]=\"min()\"\n [attr.aria-valuemax]=\"ceiling()\"\n [attr.aria-valuenow]=\"current()\"\n [attr.aria-valuetext]=\"text()\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-disabled]=\"isDisabled() || null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n (pointerdown)=\"onPointerDown($event)\"\n (pointermove)=\"onPointerMove($event)\"\n (pointerup)=\"onPointerUp()\"\n (pointercancel)=\"onPointerUp()\"\n (keydown)=\"onKeydown($event)\"\n (blur)=\"onBlur()\"\n>\n <svg #svg class=\"tx-knob__svg\" viewBox=\"0 0 100 100\" aria-hidden=\"true\" [class]=\"passThrough().svg?.class\" [style]=\"passThrough().svg?.style\">\n <circle\n class=\"tx-knob__range\"\n pathLength=\"100\"\n fill=\"none\"\n [class]=\"passThrough().range?.class\"\n [style]=\"passThrough().range?.style\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"rangeDash()\"\n [attr.transform]=\"rotate()\"\n />\n @if (limit() !== undefined && limitFraction() < 1) {\n <circle\n class=\"tx-knob__limit\"\n pathLength=\"100\"\n fill=\"none\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"limitDash()\"\n [attr.transform]=\"rotate()\"\n />\n }\n @if (fraction() > 0) {\n <circle\n class=\"tx-knob__value\"\n pathLength=\"100\"\n fill=\"none\"\n [class]=\"passThrough().value?.class\"\n [style]=\"passThrough().value?.style\"\n [attr.cx]=\"center\"\n [attr.cy]=\"center\"\n [attr.r]=\"radius()\"\n [attr.stroke-width]=\"strokeWidth()\"\n [attr.stroke-dasharray]=\"valueDash()\"\n [attr.transform]=\"rotate()\"\n />\n }\n @if (hasHandle()) {\n <circle\n class=\"tx-knob__handle\"\n [class]=\"passThrough().handle?.class\"\n [style]=\"passThrough().handle?.style\"\n [attr.cx]=\"handle().x\"\n [attr.cy]=\"handle().y\"\n [attr.r]=\"strokeWidth() / 2 + 2\"\n />\n }\n </svg>\n @if (showValue()) {\n <span class=\"tx-knob__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">\n @if (template(); as custom) {\n <ng-container [ngTemplateOutlet]=\"custom.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: current() }\" />\n } @else {\n {{ text() }}\n }\n </span>\n }\n</div>\n"],"mappings":";;;;;;;;;;AAIA,IAAa,sBAAb,MAAa,oBAAmB;CACrB,cAAc,OAAwC,WAAW;CAD/D,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAmB,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAnB,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAAmB,cAAA;EAAA,UAAA;EAAA,UAAA;CAAA,CAAA;;AAAnB,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAmB,YAAA,CAAA;EAD/B,MAAA;EAAU,MAAA,CAAA,EAAE,UAAU,2BAA0B,CAAE;;;ACDnD,MAAa,qBAAgC,EAC3C,MAAM,WACP;ACFD,MAAa,aAAa;CACxB,WAAW;CACX,MAAM;AACP;ACSD,MAAM,SAAS;AAsBf,IAAa,SAAb,MAAa,eAAe,kBAAyB;CAClC,YAAY,aAAa,UAAU;CAE5C,gBAAgB,OAAO,eAAe;CACtC,eAAe;CAEd,MAAM,MAAuB,GAAC;EAAA,GAAA,YAAA,EAAA,WAAA,MAAA,+BAAA,CAAA;EAAI,WAAW;CAAe,CAAA;CAC5D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AA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,SAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,SAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,GAAA,iBAAA,mBAAmB,GAAA,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;EAAA,KAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CACS,OAAK,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;CAAA;AAAA,CAAA;AAiIpE,SAAS,SAAS,OAAa;CAC7B,MAAM,OAAO,OAAO,KAAK;CACzB,OAAO,KAAK,SAAS,GAAG,IAAI,KAAK,MAAM,GAAG,CAAC,CAAC,EAAE,CAAC,SAAS;AAC1D"}
@@ -1,7 +1,17 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import { ChangeDetectionStrategy, Component, booleanAttribute, input } from "@angular/core";
3
- import { TxIcon } from "@tectra-ng/icons";
3
+ import { TxIcon, provideTxIconDefaults, txIconInfoCircle } from "@tectra-ng/icons";
4
+ import { injectTokens } from "@tectra-ng/core/config";
5
+ import { fieldTokens, floatLabelTokens, iftaLabelTokens, labelTokens } from "@tectra-ng/themes";
6
+ const LABEL_ICON_DEFAULTS = { "info-circle": txIconInfoCircle };
7
+ const LABEL_THEME = {
8
+ field: fieldTokens,
9
+ floatLabel: floatLabelTokens,
10
+ iftaLabel: iftaLabelTokens,
11
+ label: labelTokens
12
+ };
4
13
  var TxLabel = class TxLabel {
14
+ labelTheme = injectTokens(LABEL_THEME);
5
15
  for = input(void 0, ...ngDevMode ? [{ debugName: "for" }] : /* istanbul ignore next */ []);
6
16
  required = input(false, {
7
17
  ...ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {},
@@ -91,6 +101,7 @@ var TxLabel = class TxLabel {
91
101
  selector: "tx-icon",
92
102
  inputs: ["name"]
93
103
  }],
104
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
94
105
  changeDetection: i0.ChangeDetectionStrategy.OnPush
95
106
  });
96
107
  };
@@ -120,6 +131,7 @@ i0.ɵɵngDeclareClassMetadata({
120
131
  class: "tx-label",
121
132
  "[class.tx-label--subtle]": "subtle()"
122
133
  },
134
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
123
135
  styles: [":host{display:block;margin-bottom:var(--tx-label-margin-bottom)}.tx-label__text{display:inline-flex;align-items:center;gap:var(--tx-label-gap);color:var(--tx-label-color);font-family:var(--tx-font-family);font-size:var(--tx-label-font-size);font-weight:var(--tx-label-font-weight);line-height:1.3}:host(.tx-label--subtle) .tx-label__text{color:var(--tx-label-subtle-color);font-size:var(--tx-label-subtle-font-size);font-weight:var(--tx-label-subtle-font-weight)}.tx-label__required{color:var(--tx-label-required-color)}.tx-label__hint{display:inline-flex;color:var(--tx-label-hint-color);font-size:.9em;cursor:help}.tx-label__hint:focus-visible{border-radius:var(--tx-radius-xs);outline:2px solid var(--tx-focus-ring-color);outline-offset:1px}\n"]
124
136
  }]
125
137
  }],
@@ -167,6 +179,7 @@ i0.ɵɵngDeclareClassMetadata({
167
179
  }
168
180
  });
169
181
  var TxFloatLabel = class TxFloatLabel {
182
+ labelTheme = injectTokens(LABEL_THEME);
170
183
  variant = input("over", ...ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []);
171
184
  static ɵfac = i0.ɵɵngDeclareFactory({
172
185
  minVersion: "12.0.0",
@@ -197,6 +210,7 @@ var TxFloatLabel = class TxFloatLabel {
197
210
  template: "<ng-content />",
198
211
  isInline: true,
199
212
  styles: [":host{position:relative;display:flex;flex-direction:column;align-items:flex-start;align-self:start}:host([data-variant=in]){--tx-field-padding-top: var(--tx-float-label-in-input-padding-top);--tx-field-padding-bottom: var(--tx-float-label-in-input-padding-bottom)}:host ::ng-deep>label{position:absolute;top:50%;left:var(--tx-float-label-position-x);z-index:1;max-width:calc(100% - 2 * var(--tx-float-label-position-x));overflow:hidden;margin:0;color:var(--tx-float-label-color);font-family:var(--tx-font-family);font-size:var(--tx-float-label-font-size);font-weight:var(--tx-float-label-font-weight);line-height:1.2;text-overflow:ellipsis;white-space:nowrap;transform:translateY(-50%);transition-property:top,transform,font-size,color,background-color,padding;transition-duration:var(--tx-float-label-transition-duration);pointer-events:none}:host ::ng-deep>textarea~label{top:var(--tx-float-label-position-y);transform:none}:host ::ng-deep>.tx-input:not(:focus)::placeholder,:host ::ng-deep>tx-password:not(:focus-within) .tx-input::placeholder,:host ::ng-deep>tx-input-number:not(:focus-within) .tx-input::placeholder,:host ::ng-deep>tx-datepicker:not(:focus-within,.tx-datepicker--open) .tx-input::placeholder,:host ::ng-deep>tx-select:not(.tx-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-multiselect:not(.tx-multiselect--open) .tx-select__value--placeholder,:host ::ng-deep>tx-tree-select:not(.tx-tree-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-cascade-select:not(.tx-cascade-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-select:not(.tx-select--open,:focus-within) .tx-select__input::placeholder,:host ::ng-deep>tx-autocomplete:not(:focus-within) .tx-select__input::placeholder,:host ::ng-deep>tx-chips-input:not(:focus-within) .tx-chips-input__input::placeholder{color:transparent}:host ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{font-size:var(--tx-float-label-active-font-size);font-weight:var(--tx-float-label-active-font-weight)}:host([data-variant=over]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:var(--tx-float-label-over-active-top);color:var(--tx-float-label-active-color);transform:none}:host([data-variant=in]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:var(--tx-float-label-in-active-top);transform:none}:host([data-variant=on]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:0;padding:var(--tx-float-label-on-active-padding);border-radius:var(--tx-float-label-on-border-radius);background:var(--tx-float-label-on-active-background);transform:translateY(-50%)}:host ::ng-deep>:is(.tx-input:focus,tx-select.tx-select--open,tx-select:focus-within,tx-multiselect.tx-multiselect--open,tx-multiselect:focus-within,tx-autocomplete:focus-within,tx-chips-input:focus-within,tx-tree-select:focus-within,tx-cascade-select:focus-within,tx-password:focus-within,tx-input-number:focus-within,tx-datepicker:focus-within,tx-datepicker.tx-datepicker--open)~label{color:var(--tx-float-label-focus-color)}:host ::ng-deep>:is(.tx-input--invalid,tx-select.tx-select--invalid,tx-multiselect.tx-multiselect--invalid,tx-autocomplete.tx-autocomplete--invalid,tx-chips-input.tx-chips-input--invalid,tx-tree-select.tx-tree-select--invalid,tx-cascade-select.tx-cascade-select--invalid,tx-password.tx-password--invalid,tx-input-number.tx-input-number--invalid,tx-datepicker.tx-datepicker--invalid)~label{color:var(--tx-float-label-invalid-color)}\n"],
213
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
200
214
  changeDetection: i0.ChangeDetectionStrategy.OnPush
201
215
  });
202
216
  };
@@ -215,6 +229,7 @@ i0.ɵɵngDeclareClassMetadata({
215
229
  class: "tx-float-label",
216
230
  "[attr.data-variant]": "variant()"
217
231
  },
232
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
218
233
  styles: [":host{position:relative;display:flex;flex-direction:column;align-items:flex-start;align-self:start}:host([data-variant=in]){--tx-field-padding-top: var(--tx-float-label-in-input-padding-top);--tx-field-padding-bottom: var(--tx-float-label-in-input-padding-bottom)}:host ::ng-deep>label{position:absolute;top:50%;left:var(--tx-float-label-position-x);z-index:1;max-width:calc(100% - 2 * var(--tx-float-label-position-x));overflow:hidden;margin:0;color:var(--tx-float-label-color);font-family:var(--tx-font-family);font-size:var(--tx-float-label-font-size);font-weight:var(--tx-float-label-font-weight);line-height:1.2;text-overflow:ellipsis;white-space:nowrap;transform:translateY(-50%);transition-property:top,transform,font-size,color,background-color,padding;transition-duration:var(--tx-float-label-transition-duration);pointer-events:none}:host ::ng-deep>textarea~label{top:var(--tx-float-label-position-y);transform:none}:host ::ng-deep>.tx-input:not(:focus)::placeholder,:host ::ng-deep>tx-password:not(:focus-within) .tx-input::placeholder,:host ::ng-deep>tx-input-number:not(:focus-within) .tx-input::placeholder,:host ::ng-deep>tx-datepicker:not(:focus-within,.tx-datepicker--open) .tx-input::placeholder,:host ::ng-deep>tx-select:not(.tx-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-multiselect:not(.tx-multiselect--open) .tx-select__value--placeholder,:host ::ng-deep>tx-tree-select:not(.tx-tree-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-cascade-select:not(.tx-cascade-select--open) .tx-select__value--placeholder,:host ::ng-deep>tx-select:not(.tx-select--open,:focus-within) .tx-select__input::placeholder,:host ::ng-deep>tx-autocomplete:not(:focus-within) .tx-select__input::placeholder,:host ::ng-deep>tx-chips-input:not(:focus-within) .tx-chips-input__input::placeholder{color:transparent}:host ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{font-size:var(--tx-float-label-active-font-size);font-weight:var(--tx-float-label-active-font-weight)}:host([data-variant=over]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:var(--tx-float-label-over-active-top);color:var(--tx-float-label-active-color);transform:none}:host([data-variant=in]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:var(--tx-float-label-in-active-top);transform:none}:host([data-variant=on]) ::ng-deep>:is(.tx-input--filled,.tx-input:focus,tx-select.tx-select--filled,tx-select.tx-select--open,tx-multiselect.tx-multiselect--filled,tx-multiselect.tx-multiselect--open,tx-autocomplete.tx-autocomplete--filled,tx-autocomplete:focus-within,tx-chips-input.tx-chips-input--filled,tx-chips-input:focus-within,tx-tree-select.tx-tree-select--filled,tx-tree-select.tx-tree-select--open,tx-cascade-select.tx-cascade-select--filled,tx-cascade-select.tx-cascade-select--open,tx-password.tx-password--filled,tx-password:focus-within,tx-input-number.tx-input-number--filled,tx-input-number:focus-within,tx-datepicker.tx-datepicker--filled,tx-datepicker.tx-datepicker--open,tx-datepicker:focus-within)~label{top:0;padding:var(--tx-float-label-on-active-padding);border-radius:var(--tx-float-label-on-border-radius);background:var(--tx-float-label-on-active-background);transform:translateY(-50%)}:host ::ng-deep>:is(.tx-input:focus,tx-select.tx-select--open,tx-select:focus-within,tx-multiselect.tx-multiselect--open,tx-multiselect:focus-within,tx-autocomplete:focus-within,tx-chips-input:focus-within,tx-tree-select:focus-within,tx-cascade-select:focus-within,tx-password:focus-within,tx-input-number:focus-within,tx-datepicker:focus-within,tx-datepicker.tx-datepicker--open)~label{color:var(--tx-float-label-focus-color)}:host ::ng-deep>:is(.tx-input--invalid,tx-select.tx-select--invalid,tx-multiselect.tx-multiselect--invalid,tx-autocomplete.tx-autocomplete--invalid,tx-chips-input.tx-chips-input--invalid,tx-tree-select.tx-tree-select--invalid,tx-cascade-select.tx-cascade-select--invalid,tx-password.tx-password--invalid,tx-input-number.tx-input-number--invalid,tx-datepicker.tx-datepicker--invalid)~label{color:var(--tx-float-label-invalid-color)}\n"]
219
234
  }]
220
235
  }],
@@ -228,6 +243,7 @@ i0.ɵɵngDeclareClassMetadata({
228
243
  }] }
229
244
  });
230
245
  var TxIftaLabel = class TxIftaLabel {
246
+ labelTheme = injectTokens(LABEL_THEME);
231
247
  static ɵfac = i0.ɵɵngDeclareFactory({
232
248
  minVersion: "12.0.0",
233
249
  version: "22.2.5",
@@ -247,6 +263,7 @@ var TxIftaLabel = class TxIftaLabel {
247
263
  template: "<ng-content />",
248
264
  isInline: true,
249
265
  styles: [":host{--tx-field-padding-top: var(--tx-ifta-label-input-padding-top);--tx-field-padding-bottom: var(--tx-ifta-label-input-padding-bottom);position:relative;display:flex;flex-direction:column;align-items:flex-start;align-self:start}:host ::ng-deep>label{position:absolute;top:var(--tx-ifta-label-top);left:var(--tx-ifta-label-position-x);z-index:1;margin:0;color:var(--tx-ifta-label-color);font-family:var(--tx-font-family);font-size:var(--tx-ifta-label-font-size);font-weight:var(--tx-ifta-label-font-weight);line-height:1.2;transition:color var(--tx-ifta-label-transition-duration);pointer-events:none}:host ::ng-deep>:is(.tx-input:focus,tx-select.tx-select--open,tx-select:focus-within,tx-multiselect.tx-multiselect--open,tx-multiselect:focus-within,tx-autocomplete:focus-within,tx-datepicker:focus-within,tx-datepicker.tx-datepicker--open)~label{color:var(--tx-ifta-label-focus-color)}:host ::ng-deep>:is(.tx-input--invalid,tx-select.tx-select--invalid,tx-multiselect.tx-multiselect--invalid,tx-autocomplete.tx-autocomplete--invalid,tx-datepicker.tx-datepicker--invalid)~label{color:var(--tx-ifta-label-invalid-color)}\n"],
266
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
250
267
  changeDetection: i0.ChangeDetectionStrategy.OnPush
251
268
  });
252
269
  };
@@ -262,6 +279,7 @@ i0.ɵɵngDeclareClassMetadata({
262
279
  template: "<ng-content />",
263
280
  changeDetection: ChangeDetectionStrategy.OnPush,
264
281
  host: { class: "tx-ifta-label" },
282
+ viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],
265
283
  styles: [":host{--tx-field-padding-top: var(--tx-ifta-label-input-padding-top);--tx-field-padding-bottom: var(--tx-ifta-label-input-padding-bottom);position:relative;display:flex;flex-direction:column;align-items:flex-start;align-self:start}:host ::ng-deep>label{position:absolute;top:var(--tx-ifta-label-top);left:var(--tx-ifta-label-position-x);z-index:1;margin:0;color:var(--tx-ifta-label-color);font-family:var(--tx-font-family);font-size:var(--tx-ifta-label-font-size);font-weight:var(--tx-ifta-label-font-weight);line-height:1.2;transition:color var(--tx-ifta-label-transition-duration);pointer-events:none}:host ::ng-deep>:is(.tx-input:focus,tx-select.tx-select--open,tx-select:focus-within,tx-multiselect.tx-multiselect--open,tx-multiselect:focus-within,tx-autocomplete:focus-within,tx-datepicker:focus-within,tx-datepicker.tx-datepicker--open)~label{color:var(--tx-ifta-label-focus-color)}:host ::ng-deep>:is(.tx-input--invalid,tx-select.tx-select--invalid,tx-multiselect.tx-multiselect--invalid,tx-autocomplete.tx-autocomplete--invalid,tx-datepicker.tx-datepicker--invalid)~label{color:var(--tx-ifta-label-invalid-color)}\n"]
266
284
  }]
267
285
  }]
@@ -1 +1 @@
1
- {"version":3,"file":"tectra-ng-ui-label.mjs","names":[],"sources":["../../../../packages/ui/label/src/label.component.ts","../../../../packages/ui/label/src/float-label.component.ts","../../../../packages/ui/label/src/ifta-label.component.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, booleanAttribute, input } from '@angular/core';\nimport { TxIcon } from '@tectra-ng/icons';\n\n@Component({\n selector: 'tx-label',\n imports: [TxIcon],\n template: `\n <label class=\"tx-label__text\" [attr.for]=\"for() ?? null\">\n <ng-content />@if (colon()) {:}\n @if (required()) {\n <span class=\"tx-label__required\" aria-hidden=\"true\">*</span>\n }\n @if (tooltip(); as tooltip) {\n <span class=\"tx-label__hint\" role=\"img\" tabindex=\"0\" [title]=\"tooltip\" [attr.aria-label]=\"tooltip\"><tx-icon [name]=\"'info-circle'\" /></span>\n }\n </label>\n `,\n styleUrl: './label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-label', '[class.tx-label--subtle]': 'subtle()' },\n})\nexport class TxLabel {\n readonly for = input<string | undefined>(undefined);\n readonly required = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly colon = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly subtle = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly tooltip = input<string | undefined>(undefined);\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { TxFloatLabelVariant } from './label.types';\n\n@Component({\n selector: 'tx-float-label',\n template: '<ng-content />',\n styleUrl: './float-label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-float-label', '[attr.data-variant]': 'variant()' },\n})\nexport class TxFloatLabel {\n readonly variant = input<TxFloatLabelVariant>('over');\n}\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\n\n@Component({\n selector: 'tx-ifta-label',\n template: '<ng-content />',\n styleUrl: './ifta-label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-ifta-label' },\n})\nexport class TxIftaLabel {}\n"],"mappings":";;;AAqBA,IAAa,UAAb,MAAa,QAAO;CACT,MAAM,MAA0B,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,MAAA,CAAA,+BAAA,CAAA,CAAA;CAC1C,WAAW,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,WAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACvE,QAAQ,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,QAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACpE,SAAS,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,SAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACrE,UAAU,MAA0B,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,UAAA,CAAA,+BAAA,CAAA,CAAA;CAL5C,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAO,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAP,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAAO,cAAA;EAAA,UAAA;EAAA,QAAA;GAAA,KAAA;IAAA,mBAAA;IAAA,YAAA;IAAA,UAAA;IAAA,YAAA;IAAA,mBAAA;GAAA;GAAA,UAAA;IAAA,m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/src/label.icons.ts","../../../../packages/ui/label/src/label.theme.ts","../../../../packages/ui/label/src/label.component.ts","../../../../packages/ui/label/src/float-label.component.ts","../../../../packages/ui/label/src/ifta-label.component.ts"],"sourcesContent":["import { TxIconSet, txIconInfoCircle } from '@tectra-ng/icons';\n\nexport const LABEL_ICON_DEFAULTS: TxIconSet = {\n 'info-circle': txIconInfoCircle,\n};\n","import { fieldTokens, floatLabelTokens, iftaLabelTokens, labelTokens } from '@tectra-ng/themes';\n\nexport const LABEL_THEME = {\n field: fieldTokens,\n floatLabel: floatLabelTokens,\n iftaLabel: iftaLabelTokens,\n label: labelTokens,\n};\n","import { ChangeDetectionStrategy, Component, booleanAttribute, input } from '@angular/core';\nimport { provideTxIconDefaults, TxIcon } from '@tectra-ng/icons';\nimport { LABEL_ICON_DEFAULTS } from './label.icons';\nimport { injectTokens } from '@tectra-ng/core/config';\nimport { LABEL_THEME } from './label.theme';\n\n@Component({\n selector: 'tx-label',\n imports: [TxIcon],\n template: `\n <label class=\"tx-label__text\" [attr.for]=\"for() ?? null\">\n <ng-content />@if (colon()) {:}\n @if (required()) {\n <span class=\"tx-label__required\" aria-hidden=\"true\">*</span>\n }\n @if (tooltip(); as tooltip) {\n <span class=\"tx-label__hint\" role=\"img\" tabindex=\"0\" [title]=\"tooltip\" [attr.aria-label]=\"tooltip\"><tx-icon [name]=\"'info-circle'\" /></span>\n }\n </label>\n `,\n styleUrl: './label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-label', '[class.tx-label--subtle]': 'subtle()' },\n viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],\n})\nexport class TxLabel {\n private readonly labelTheme = injectTokens(LABEL_THEME);\n\n readonly for = input<string | undefined>(undefined);\n readonly required = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly colon = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly subtle = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly tooltip = input<string | undefined>(undefined);\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { TxFloatLabelVariant } from './label.types';\nimport { provideTxIconDefaults } from '@tectra-ng/icons';\nimport { LABEL_ICON_DEFAULTS } from './label.icons';\nimport { injectTokens } from '@tectra-ng/core/config';\nimport { LABEL_THEME } from './label.theme';\n\n@Component({\n selector: 'tx-float-label',\n template: '<ng-content />',\n styleUrl: './float-label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-float-label', '[attr.data-variant]': 'variant()' },\n viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],\n})\nexport class TxFloatLabel {\n private readonly labelTheme = injectTokens(LABEL_THEME);\n\n readonly variant = input<TxFloatLabelVariant>('over');\n}\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\nimport { provideTxIconDefaults } from '@tectra-ng/icons';\nimport { LABEL_ICON_DEFAULTS } from './label.icons';\nimport { injectTokens } from '@tectra-ng/core/config';\nimport { LABEL_THEME } from './label.theme';\n\n@Component({\n selector: 'tx-ifta-label',\n template: '<ng-content />',\n styleUrl: './ifta-label.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { class: 'tx-ifta-label' },\n viewProviders: [provideTxIconDefaults(LABEL_ICON_DEFAULTS)],\n})\nexport class TxIftaLabel {\n private readonly labelTheme = injectTokens(LABEL_THEME);\n}\n"],"mappings":";;;;;AAEA,MAAa,sBAAiC,EAC5C,eAAe,iBAChB;ACFD,MAAa,cAAc;CACzB,OAAO;CACP,YAAY;CACZ,WAAW;CACX,OAAO;AACR;ACkBD,IAAa,UAAb,MAAa,QAAO;CACD,aAAa,aAAa,WAAW;CAE7C,MAAM,MAA0B,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,MAAA,CAAA,+BAAA,CAAA,CAAA;CAC1C,WAAW,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,WAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACvE,QAAQ,M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AO;IAAkB,uBAAuB;GAAW;GAAE,eACtD,CAAC,sBAAsB,mBAAmB,CAAC;GAAC,QAAA,CAAA,q5LAAA;EAAA,CAAA;;;;;;;;;;;ACC7D,IAAa,cAAb,MAAa,YAAW;CACL,aAAa,aAAa,WAAW;CAD3C,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAW,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAX,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAAW,cAAA;EAAA,UAAA;EAAA,MAAA,EAAA,gBAAA,gBAAA;EAAA,UAAA;EAAA,UANZ;EAAgB,UAAA;EAAA,QAAA,CAAA,qmCAAA;EAAA,eAIX,CAAC,sBAAsB,mBAAmB,CAAC;EAAC,iBAAA,GAAA,wBAAA;CAAA,CAAA;;AAEhD,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAW,YAAA,CAAA;EARvB,MAAA;EACW,MAAA,CAAA;GAAA,UAAA;GAAe,UACf;GAAgB,iBAET,wBAAwB;GAAM,MACzC,EAAE,OAAO,gBAAe;GAAE,eACjB,CAAC,sBAAsB,mBAAmB,CAAC;GAAC,QAAA,CAAA,qmCAAA;EAAA,CAAA"}
@@ -2,14 +2,27 @@ import { NgClass, NgTemplateOutlet } from "@angular/common";
2
2
  import * as i0 from "@angular/core";
3
3
  import { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, booleanAttribute, computed, inject, input, output, signal } from "@angular/core";
4
4
  import { RouterLink, RouterLinkActive } from "@angular/router";
5
- import { injectPassThrough, injectUnstyled } from "@tectra-ng/core/config";
5
+ import { injectPassThrough, injectTokens, injectUnstyled } from "@tectra-ng/core/config";
6
6
  import { injectTranslations } from "@tectra-ng/core/i18n";
7
7
  import { optionalBoolean, optionalNumber } from "@tectra-ng/core/utils";
8
- import { TxIcon, TxIconRegistry } from "@tectra-ng/icons";
9
- import { toStyleObject } from "@tectra-ng/themes";
8
+ import { TxIcon, injectTxIcons, provideTxIconDefaults, txIconArrowUpRight, txIconCheck, txIconCopy, txIconLink, txIconPhone, txIconText } from "@tectra-ng/icons";
9
+ import { iconLinkTokens, linkTokens, toStyleObject } from "@tectra-ng/themes";
10
10
  import { TxHighlightText } from "@tectra-ng/ui/highlight-text";
11
+ const LINK_ICON_DEFAULTS = {
12
+ "arrow-up-right": txIconArrowUpRight,
13
+ check: txIconCheck,
14
+ copy: txIconCopy,
15
+ link: txIconLink,
16
+ phone: txIconPhone,
17
+ text: txIconText
18
+ };
19
+ const LINK_THEME = {
20
+ iconLink: iconLinkTokens,
21
+ link: linkTokens
22
+ };
11
23
  var TxIconLink = class TxIconLink {
12
- txIconRegistry = inject(TxIconRegistry);
24
+ linkTheme = injectTokens(LINK_THEME);
25
+ txIconRegistry = injectTxIcons();
13
26
  icon = input(void 0, ...ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []);
14
27
  text = input("", ...ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []);
15
28
  routerLink = input(void 0, ...ngDevMode ? [{ debugName: "routerLink" }] : /* istanbul ignore next */ []);
@@ -191,6 +204,7 @@ var TxIconLink = class TxIconLink {
191
204
  inputs: ["name"]
192
205
  }
193
206
  ],
207
+ viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],
194
208
  changeDetection: i0.ChangeDetectionStrategy.OnPush
195
209
  });
196
210
  };
@@ -217,6 +231,7 @@ i0.ɵɵngDeclareClassMetadata({
217
231
  "[style]": "hostStyle()",
218
232
  "[attr.data-styled]": "!isUnstyled() || null"
219
233
  },
234
+ viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],
220
235
  template: "<ng-template #content>\n @if (icon(); as icon) {\n @if (iconName(); as name) {\n <tx-icon class=\"tx-icon-link__icon\" [name]=\"name\" [class]=\"passThrough().icon?.class\" [style]=\"passThrough().icon?.style\" />\n } @else {\n <span class=\"tx-icon-link__icon\" aria-hidden=\"true\" [class]=\"icon\" [ngClass]=\"passThrough().icon?.class ?? null\" [style]=\"passThrough().icon?.style\"></span>\n }\n }\n <span class=\"tx-icon-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">{{ text() }}<ng-content /></span>\n @if (opensNewTab()) {\n <span class=\"tx-icon-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a\n class=\"tx-icon-link__anchor\"\n [routerLink]=\"$any(commands)\"\n routerLinkActive=\"tx-icon-link__anchor--active\"\n ariaCurrentWhenActive=\"page\"\n [routerLinkActiveOptions]=\"{ exact: exact() }\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else if (href()) {\n <a\n class=\"tx-icon-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <button type=\"button\" class=\"tx-icon-link__anchor\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </button>\n}\n",
221
236
  styles: [":host{display:inline-flex;min-width:0}.tx-icon-link__anchor{display:inline-flex;align-items:center;min-width:0}.tx-icon-link__text{min-width:0}.tx-icon-link__hint{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}:host([data-styled]) .tx-icon-link__anchor{gap:var(--tx-icon-link-gap);padding:var(--tx-icon-link-padding-y) var(--tx-icon-link-padding-x);border:none;border-radius:var(--tx-icon-link-border-radius);background:transparent;color:var(--tx-icon-link-color);font-family:inherit;font-size:var(--tx-icon-link-font-size);font-weight:var(--tx-icon-link-font-weight);text-decoration:none;cursor:pointer;transition:color var(--tx-motion-duration),background-color var(--tx-motion-duration)}:host([data-styled]) .tx-icon-link__anchor:hover{background:var(--tx-icon-link-hover-background);color:var(--tx-icon-link-hover-color)}:host([data-styled]) .tx-icon-link__anchor:focus-visible{outline:2px solid var(--tx-icon-link-focus-ring-color);outline-offset:1px}:host([data-styled]) .tx-icon-link__anchor--active,:host([data-styled]) .tx-icon-link__anchor--active:hover{background:var(--tx-icon-link-active-background);color:var(--tx-icon-link-active-color)}:host([data-styled]) .tx-icon-link__icon{flex-shrink:0;font-size:var(--tx-icon-link-icon-size)}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-icon-link__anchor{transition:none}}\n"]
222
237
  }]
@@ -307,6 +322,7 @@ i0.ɵɵngDeclareClassMetadata({
307
322
  const COPIED_FOR = 1600;
308
323
  const PROTOCOL = /^[a-z][a-z\d+.-]*:/i;
309
324
  var TxLink = class TxLink {
325
+ linkTheme = injectTokens(LINK_THEME);
310
326
  document = inject(DOCUMENT);
311
327
  timer = null;
312
328
  link = input("", ...ngDevMode ? [{ debugName: "link" }] : /* istanbul ignore next */ []);
@@ -552,6 +568,7 @@ var TxLink = class TxLink {
552
568
  ]
553
569
  }
554
570
  ],
571
+ viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],
555
572
  changeDetection: i0.ChangeDetectionStrategy.OnPush
556
573
  });
557
574
  };
@@ -578,6 +595,7 @@ i0.ɵɵngDeclareClassMetadata({
578
595
  "[attr.data-styled]": "!isUnstyled() || null",
579
596
  "[attr.data-type]": "type()"
580
597
  },
598
+ viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],
581
599
  template: "<ng-template #content>\n <span class=\"tx-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">\n <tx-highlight-text [text]=\"displayText()\" [highlight]=\"highlight()\" />\n </span>\n @if (showExternal()) {\n <tx-icon class=\"tx-link__external\" name=\"arrow-up-right\" [class]=\"passThrough().external?.class\" [style]=\"passThrough().external?.style\" />\n }\n @if (opensNewTab()) {\n <span class=\"tx-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a class=\"tx-link__anchor\" [routerLink]=\"$any(commands)\" [attr.title]=\"fullTitle()\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <a\n class=\"tx-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [attr.title]=\"fullTitle()\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n}\n@if (copyable() && link()) {\n <button\n type=\"button\"\n class=\"tx-link__copy\"\n [class.tx-link__copy--done]=\"isCopied()\"\n [class]=\"passThrough().copy?.class\"\n [style]=\"passThrough().copy?.style\"\n [attr.aria-label]=\"isCopied() ? translations().copied : copyLabel()\"\n [title]=\"isCopied() ? translations().copied : copyLabel()\"\n (click)=\"copy()\"\n >\n <span class=\"tx-copy-swap\" [class.tx-copy-swap--done]=\"isCopied()\"><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--idle\" name=\"copy\" /><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--done\" name=\"check\" /></span>\n </button>\n}\n",
582
600
  styles: [":host{display:inline-flex;align-items:center;max-width:100%;min-width:0;vertical-align:bottom}.tx-link__anchor{min-width:0;overflow-wrap:anywhere}.tx-link__hint{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}:host([data-styled]){gap:var(--tx-link-gap);font-family:inherit}:host([data-styled]) .tx-link__anchor{border-radius:2px;color:var(--tx-link-color);text-decoration:underline;text-decoration-color:transparent;text-underline-offset:var(--tx-link-underline-offset);cursor:pointer;transition:color var(--tx-motion-duration) var(--tx-motion-easing),text-decoration-color var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-link__anchor:hover{color:var(--tx-link-hover-color);text-decoration-color:currentColor}:host([data-styled]) .tx-link__anchor:focus-visible{outline:2px solid var(--tx-link-focus-ring-color);outline-offset:2px}:host([data-styled]) .tx-link__external{margin-inline-start:.25em;vertical-align:-.05em;font-size:var(--tx-link-external-icon-size);opacity:.7}:host([data-styled]) .tx-link__copy{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--tx-link-copy-size);height:var(--tx-link-copy-size);padding:0;border:none;border-radius:var(--tx-radius-sm);background:transparent;color:var(--tx-link-copy-color);font-size:var(--tx-link-copy-icon-size);cursor:pointer;transition:color var(--tx-motion-duration),background-color var(--tx-motion-duration)}:host([data-styled]) .tx-link__copy:hover{background:var(--tx-link-copy-hover-background);color:var(--tx-link-copy-hover-color)}:host([data-styled]) .tx-link__copy:focus-visible{outline:2px solid var(--tx-link-focus-ring-color);outline-offset:1px}:host([data-styled]) .tx-link__copy--done,:host([data-styled]) .tx-link__copy--done:hover{color:var(--tx-link-copied-color)}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-link__copy{transition:none}}.tx-copy-swap{display:inline-grid;place-items:center}.tx-copy-swap__icon{grid-area:1/1;transition:opacity var(--tx-motion-duration) ease,transform var(--tx-motion-duration) cubic-bezier(.34,1.56,.64,1)}.tx-copy-swap__icon--done{opacity:0;transform:scale(.4) rotate(-45deg)}.tx-copy-swap--done .tx-copy-swap__icon--idle{opacity:0;transform:scale(.4) rotate(45deg)}.tx-copy-swap--done .tx-copy-swap__icon--done{opacity:1;transform:none}@media(prefers-reduced-motion:reduce){.tx-copy-swap__icon{transition:none}}\n"]
583
601
  }]
@@ -1 +1 @@
1
- {"version":3,"file":"tectra-ng-ui-link.mjs","names":[],"sources":["../../../../packages/ui/link/src/icon-link.component.ts","../../../../packages/ui/link/src/icon-link.component.html","../../../../packages/ui/link/src/link.component.ts","../../../../packages/ui/link/src/link.component.html"],"sourcesContent":["import { NgClass, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, booleanAttribute, computed, inject, input } from '@angular/core';\nimport { RouterLink, RouterLinkActive } from '@angular/router';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean } from '@tectra-ng/core/utils';\nimport { TxIcon, TxIconName, TxIconRegistry } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraIconLinkTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxIconLinkPart, TxLinkCommands } from './link.types';\n\n@Component({\n selector: 'tx-icon-link',\n imports: [NgClass, NgTemplateOutlet, RouterLink, RouterLinkActive, TxIcon],\n templateUrl: './icon-link.component.html',\n styleUrl: './icon-link.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-icon-link',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n },\n})\nexport class TxIconLink {\n private txIconRegistry = inject(TxIconRegistry);\n\n readonly icon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly text = input<string>('');\n readonly routerLink = input<TxLinkCommands>(undefined);\n readonly href = input<string | null | undefined>(undefined);\n readonly target = input<string | undefined>(undefined);\n readonly exact = input<boolean, unknown>(true, { transform: booleanAttribute });\n readonly dt = input<TectraDeepPartial<TectraIconLinkTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxIconLinkPart, TxIconLink> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('iconLink', this, this.pt, this.ptOptions);\n readonly iconName = computed(() => {\n const icon = this.icon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly resolvedTarget = computed(() => this.target() ?? '_blank');\n readonly opensNewTab = computed(() => !this.routerLink() && !!this.href() && this.resolvedTarget() === '_blank');\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-icon-link'), ...this.passThrough().root?.style }));\n}\n","<ng-template #content>\n @if (icon(); as icon) {\n @if (iconName(); as name) {\n <tx-icon class=\"tx-icon-link__icon\" [name]=\"name\" [class]=\"passThrough().icon?.class\" [style]=\"passThrough().icon?.style\" />\n } @else {\n <span class=\"tx-icon-link__icon\" aria-hidden=\"true\" [class]=\"icon\" [ngClass]=\"passThrough().icon?.class ?? null\" [style]=\"passThrough().icon?.style\"></span>\n }\n }\n <span class=\"tx-icon-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">{{ text() }}<ng-content /></span>\n @if (opensNewTab()) {\n <span class=\"tx-icon-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a\n class=\"tx-icon-link__anchor\"\n [routerLink]=\"$any(commands)\"\n routerLinkActive=\"tx-icon-link__anchor--active\"\n ariaCurrentWhenActive=\"page\"\n [routerLinkActiveOptions]=\"{ exact: exact() }\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else if (href()) {\n <a\n class=\"tx-icon-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <button type=\"button\" class=\"tx-icon-link__anchor\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </button>\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, booleanAttribute, computed, inject, input, output, signal } from '@angular/core';\nimport { RouterLink } from '@angular/router';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { TxIcon } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraLinkTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxHighlightTerms, TxHighlightText } from '@tectra-ng/ui/highlight-text';\nimport { TxLinkCommands, TxLinkPart, TxLinkType } from './link.types';\n\nconst COPIED_FOR = 1600;\nconst PROTOCOL = /^[a-z][a-z\\d+.-]*:/i;\n\n@Component({\n selector: 'tx-link',\n imports: [NgTemplateOutlet, RouterLink, TxIcon, TxHighlightText],\n templateUrl: './link.component.html',\n styleUrl: './link.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-link',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-type]': 'type()',\n },\n})\nexport class TxLink {\n private document = inject(DOCUMENT);\n private timer: ReturnType<typeof setTimeout> | null = null;\n\n readonly link = input<string | null | undefined>('');\n readonly type = input<TxLinkType>('url');\n readonly linkText = input<string | null | undefined>(undefined);\n readonly highlight = input<TxHighlightTerms>('');\n readonly maxLength = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly routerLink = input<TxLinkCommands>(undefined);\n readonly target = input<string | undefined>(undefined);\n readonly external = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly copyable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly dt = input<TectraDeepPartial<TectraLinkTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxLinkPart, TxLink> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly copied = output<string>();\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('link', this, this.pt, this.ptOptions);\n readonly isCopied = signal(false);\n\n readonly value = computed(() => (this.link() ?? '').trim());\n readonly fullText = computed(() => this.linkText() || this.value());\n readonly isTruncated = computed(() => {\n const max = this.maxLength();\n return max !== undefined && max > 0 && this.fullText().length > max;\n });\n readonly displayText = computed(() => (this.isTruncated() ? `${this.fullText().slice(0, this.maxLength()).trimEnd()}…` : this.fullText()));\n readonly fullTitle = computed(() => (this.isTruncated() ? this.fullText() : null));\n readonly href = computed(() => {\n const value = this.value();\n switch (this.type()) {\n case 'email':\n return `mailto:${value}`;\n case 'phone':\n return `tel:${value.replace(/[^\\d+]/g, '')}`;\n default:\n return PROTOCOL.test(value) || value.startsWith('/') ? value : `https://${value}`;\n }\n });\n readonly resolvedTarget = computed(() => this.target() ?? (this.type() === 'url' ? '_blank' : null));\n readonly opensNewTab = computed(() => !this.routerLink() && this.resolvedTarget() === '_blank');\n readonly showExternal = computed(() => this.external() ?? this.opensNewTab());\n readonly copyLabel = computed(() => {\n const translations = this.translations();\n return { url: translations.copyLink, email: translations.copyEmail, phone: translations.copyPhone }[this.type()];\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-link'), ...this.passThrough().root?.style }));\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.timer && clearTimeout(this.timer));\n }\n\n copy(): void {\n const text = this.value();\n this.document.defaultView?.navigator.clipboard?.writeText(text);\n this.copied.emit(text);\n this.isCopied.set(true);\n if (this.timer) {\n clearTimeout(this.timer);\n }\n this.timer = setTimeout(() => this.isCopied.set(false), COPIED_FOR);\n }\n}\n","<ng-template #content>\n <span class=\"tx-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">\n <tx-highlight-text [text]=\"displayText()\" [highlight]=\"highlight()\" />\n </span>\n @if (showExternal()) {\n <tx-icon class=\"tx-link__external\" name=\"arrow-up-right\" [class]=\"passThrough().external?.class\" [style]=\"passThrough().external?.style\" />\n }\n @if (opensNewTab()) {\n <span class=\"tx-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a class=\"tx-link__anchor\" [routerLink]=\"$any(commands)\" [attr.title]=\"fullTitle()\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <a\n class=\"tx-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [attr.title]=\"fullTitle()\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n}\n@if (copyable() && link()) {\n <button\n type=\"button\"\n class=\"tx-link__copy\"\n [class.tx-link__copy--done]=\"isCopied()\"\n [class]=\"passThrough().copy?.class\"\n [style]=\"passThrough().copy?.style\"\n [attr.aria-label]=\"isCopied() ? translations().copied : copyLabel()\"\n [title]=\"isCopied() ? translations().copied : copyLabel()\"\n (click)=\"copy()\"\n >\n <span class=\"tx-copy-swap\" [class.tx-copy-swap--done]=\"isCopied()\"><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--idle\" name=\"copy\" /><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--done\" name=\"check\" /></span>\n </button>\n}\n"],"mappings":";;;;;;;;;;AAuBA,IAAa,aAAb,MAAa,WAAU;CACb,iBAAiB,OAAO,cAAc;CAErC,OAAO,MAA8C,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CAC/D,OAAO,MAAc,IAAG,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+B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A,UAAA;IAAA,YAAA;IAAA,mBAAA;GAAA;EAAA;EAAA,SAAA,EAAA,QAAA,SAAA;EAAA,MAAA;GAAA,YAAA;IAAA,SAAA;IAAA,SAAA;IAAA,oBAAA;IAAA,kBAAA;GAAA;GAAA,gBAAA;EAAA;EAAA,UAAA;EAAA,UC5BnB;EA2CA,QAAA,CAAA,i5EAAA;EAAA,cAAA;GAAA;IAAA,MAAA;IAAA,MD3BY;IAAgB,UAAA;IAAA,QAAA;KAAA;KAAA;KAAA;IAAA;GAAA;GAAA;IAAA,MAAA;IAAA,MAAE;IAAU,UAAA;IAAA,QAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;IAAA;GAAA;GAAA;IAAA,MAAA;IAAA,MAAE;IAAM,UAAA;IAAA,QAAA,CAAA,MAAA;GAAA;GAAA;IAAA,MAAA;IAAA,MAAE;IAAe,UAAA;IAAA,QAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;IAAA;GAAA;EAAA;EAAA,iBAAA,GAAA,wBAAA;CAAA,CAAA;;AAYpD,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAM,YAAA,CAAA;EAdlB,MAAA;EACW,MAAA,CAAA;GAAA,UAAA;GAAS,SACV;IAAC;IAAkB;IAAY;IAAQ;GAAe;GAAC,iBAG/C,wBAAwB;GAAM,MACzC;IACJ,OAAO;IACP,WAAW;IACX,WAAW;IACX,sBAAsB;IACtB,oBAAoB;GACrB;GAAA,UAAA;GAAA,QAAA,CAAA,i5EAAA;EAAA,CAAA"}
1
+ {"version":3,"file":"tectra-ng-ui-link.mjs","names":[],"sources":["../../../../packages/ui/link/src/link.icons.ts","../../../../packages/ui/link/src/link.theme.ts","../../../../packages/ui/link/src/icon-link.component.ts","../../../../packages/ui/link/src/icon-link.component.html","../../../../packages/ui/link/src/link.component.ts","../../../../packages/ui/link/src/link.component.html"],"sourcesContent":["import { TxIconSet, txIconArrowUpRight, txIconCheck, txIconCopy, txIconLink, txIconPhone, txIconText } from '@tectra-ng/icons';\n\nexport const LINK_ICON_DEFAULTS: TxIconSet = {\n 'arrow-up-right': txIconArrowUpRight,\n check: txIconCheck,\n copy: txIconCopy,\n link: txIconLink,\n phone: txIconPhone,\n text: txIconText,\n};\n","import { iconLinkTokens, linkTokens } from '@tectra-ng/themes';\n\nexport const LINK_THEME = {\n iconLink: iconLinkTokens,\n link: linkTokens,\n};\n","import { NgClass, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, booleanAttribute, computed, input } from '@angular/core';\nimport { RouterLink, RouterLinkActive } from '@angular/router';\nimport { injectPassThrough, injectTokens, injectUnstyled, TxPassThrough, TxPassThroughOptions } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean } from '@tectra-ng/core/utils';\nimport { injectTxIcons, provideTxIconDefaults, TxIcon, TxIconName } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraIconLinkTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxIconLinkPart, TxLinkCommands } from './link.types';\nimport { LINK_ICON_DEFAULTS } from './link.icons';\nimport { LINK_THEME } from './link.theme';\n\n@Component({\n selector: 'tx-icon-link',\n imports: [NgClass, NgTemplateOutlet, RouterLink, RouterLinkActive, TxIcon],\n templateUrl: './icon-link.component.html',\n styleUrl: './icon-link.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-icon-link',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n },\n viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],\n})\nexport class TxIconLink {\n private readonly linkTheme = injectTokens(LINK_THEME);\n\n private txIconRegistry = injectTxIcons();\n\n readonly icon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly text = input<string>('');\n readonly routerLink = input<TxLinkCommands>(undefined);\n readonly href = input<string | null | undefined>(undefined);\n readonly target = input<string | undefined>(undefined);\n readonly exact = input<boolean, unknown>(true, { transform: booleanAttribute });\n readonly dt = input<TectraDeepPartial<TectraIconLinkTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxIconLinkPart, TxIconLink> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('iconLink', this, this.pt, this.ptOptions);\n readonly iconName = computed(() => {\n const icon = this.icon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly resolvedTarget = computed(() => this.target() ?? '_blank');\n readonly opensNewTab = computed(() => !this.routerLink() && !!this.href() && this.resolvedTarget() === '_blank');\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-icon-link'), ...this.passThrough().root?.style }));\n}\n","<ng-template #content>\n @if (icon(); as icon) {\n @if (iconName(); as name) {\n <tx-icon class=\"tx-icon-link__icon\" [name]=\"name\" [class]=\"passThrough().icon?.class\" [style]=\"passThrough().icon?.style\" />\n } @else {\n <span class=\"tx-icon-link__icon\" aria-hidden=\"true\" [class]=\"icon\" [ngClass]=\"passThrough().icon?.class ?? null\" [style]=\"passThrough().icon?.style\"></span>\n }\n }\n <span class=\"tx-icon-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">{{ text() }}<ng-content /></span>\n @if (opensNewTab()) {\n <span class=\"tx-icon-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a\n class=\"tx-icon-link__anchor\"\n [routerLink]=\"$any(commands)\"\n routerLinkActive=\"tx-icon-link__anchor--active\"\n ariaCurrentWhenActive=\"page\"\n [routerLinkActiveOptions]=\"{ exact: exact() }\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else if (href()) {\n <a\n class=\"tx-icon-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <button type=\"button\" class=\"tx-icon-link__anchor\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </button>\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, booleanAttribute, computed, inject, input, output, signal } from '@angular/core';\nimport { RouterLink } from '@angular/router';\nimport { injectPassThrough, injectTokens, injectUnstyled, TxPassThrough, TxPassThroughOptions } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { provideTxIconDefaults, TxIcon } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraLinkTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxHighlightTerms, TxHighlightText } from '@tectra-ng/ui/highlight-text';\nimport { TxLinkCommands, TxLinkPart, TxLinkType } from './link.types';\nimport { LINK_ICON_DEFAULTS } from './link.icons';\nimport { LINK_THEME } from './link.theme';\n\nconst COPIED_FOR = 1600;\nconst PROTOCOL = /^[a-z][a-z\\d+.-]*:/i;\n\n@Component({\n selector: 'tx-link',\n imports: [NgTemplateOutlet, RouterLink, TxIcon, TxHighlightText],\n templateUrl: './link.component.html',\n styleUrl: './link.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-link',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-type]': 'type()',\n },\n viewProviders: [provideTxIconDefaults(LINK_ICON_DEFAULTS)],\n})\nexport class TxLink {\n private readonly linkTheme = injectTokens(LINK_THEME);\n\n private document = inject(DOCUMENT);\n private timer: ReturnType<typeof setTimeout> | null = null;\n\n readonly link = input<string | null | undefined>('');\n readonly type = input<TxLinkType>('url');\n readonly linkText = input<string | null | undefined>(undefined);\n readonly highlight = input<TxHighlightTerms>('');\n readonly maxLength = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly routerLink = input<TxLinkCommands>(undefined);\n readonly target = input<string | undefined>(undefined);\n readonly external = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly copyable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly dt = input<TectraDeepPartial<TectraLinkTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxLinkPart, TxLink> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly copied = output<string>();\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('link', this, this.pt, this.ptOptions);\n readonly isCopied = signal(false);\n\n readonly value = computed(() => (this.link() ?? '').trim());\n readonly fullText = computed(() => this.linkText() || this.value());\n readonly isTruncated = computed(() => {\n const max = this.maxLength();\n return max !== undefined && max > 0 && this.fullText().length > max;\n });\n readonly displayText = computed(() => (this.isTruncated() ? `${this.fullText().slice(0, this.maxLength()).trimEnd()}…` : this.fullText()));\n readonly fullTitle = computed(() => (this.isTruncated() ? this.fullText() : null));\n readonly href = computed(() => {\n const value = this.value();\n switch (this.type()) {\n case 'email':\n return `mailto:${value}`;\n case 'phone':\n return `tel:${value.replace(/[^\\d+]/g, '')}`;\n default:\n return PROTOCOL.test(value) || value.startsWith('/') ? value : `https://${value}`;\n }\n });\n readonly resolvedTarget = computed(() => this.target() ?? (this.type() === 'url' ? '_blank' : null));\n readonly opensNewTab = computed(() => !this.routerLink() && this.resolvedTarget() === '_blank');\n readonly showExternal = computed(() => this.external() ?? this.opensNewTab());\n readonly copyLabel = computed(() => {\n const translations = this.translations();\n return { url: translations.copyLink, email: translations.copyEmail, phone: translations.copyPhone }[this.type()];\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-link'), ...this.passThrough().root?.style }));\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.timer && clearTimeout(this.timer));\n }\n\n copy(): void {\n const text = this.value();\n this.document.defaultView?.navigator.clipboard?.writeText(text);\n this.copied.emit(text);\n this.isCopied.set(true);\n if (this.timer) {\n clearTimeout(this.timer);\n }\n this.timer = setTimeout(() => this.isCopied.set(false), COPIED_FOR);\n }\n}\n","<ng-template #content>\n <span class=\"tx-link__text\" [class]=\"passThrough().text?.class\" [style]=\"passThrough().text?.style\">\n <tx-highlight-text [text]=\"displayText()\" [highlight]=\"highlight()\" />\n </span>\n @if (showExternal()) {\n <tx-icon class=\"tx-link__external\" name=\"arrow-up-right\" [class]=\"passThrough().external?.class\" [style]=\"passThrough().external?.style\" />\n }\n @if (opensNewTab()) {\n <span class=\"tx-link__hint\">({{ translations().opensInNewTab }})</span>\n }\n</ng-template>\n\n@if (routerLink(); as commands) {\n <a class=\"tx-link__anchor\" [routerLink]=\"$any(commands)\" [attr.title]=\"fullTitle()\" [class]=\"passThrough().anchor?.class\" [style]=\"passThrough().anchor?.style\">\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n} @else {\n <a\n class=\"tx-link__anchor\"\n [href]=\"href()\"\n [attr.target]=\"resolvedTarget()\"\n [attr.rel]=\"opensNewTab() ? 'noopener noreferrer' : null\"\n [attr.title]=\"fullTitle()\"\n [class]=\"passThrough().anchor?.class\"\n [style]=\"passThrough().anchor?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </a>\n}\n@if (copyable() && link()) {\n <button\n type=\"button\"\n class=\"tx-link__copy\"\n [class.tx-link__copy--done]=\"isCopied()\"\n [class]=\"passThrough().copy?.class\"\n [style]=\"passThrough().copy?.style\"\n [attr.aria-label]=\"isCopied() ? translations().copied : copyLabel()\"\n [title]=\"isCopied() ? translations().copied : copyLabel()\"\n (click)=\"copy()\"\n >\n <span class=\"tx-copy-swap\" [class.tx-copy-swap--done]=\"isCopied()\"><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--idle\" name=\"copy\" /><tx-icon class=\"tx-copy-swap__icon tx-copy-swap__icon--done\" name=\"check\" /></span>\n </button>\n}\n"],"mappings":";;;;;;;;;;AAEA,MAAa,qBAAgC;CAC3C,kBAAkB;CAClB,OAAO;CACP,MAAM;CACN,MAAM;CACN,OAAO;CACP,MAAM;AACP;ACPD,MAAa,aAAa;CACxB,UAAU;CACV,MAAM;AACP;ACqBD,IAAa,aAAb,MAAa,WAAU;CACJ,YAAY,aAAa,UAAU;CAE5C,iBAAiB,cAAa;CAE7B,OAAO,MAA8C,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CAC/D,OAAO,MAAc,IAAG,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CACxB,aAAa,MAAsB,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,aAAA,CAAA,+BAAA,CAAA,CAAA;CAC7C,OAAO,MAAiC,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CAClD,SAAS,MAA0B,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,SAAA,CAAA,+BAAA,CAAA,CAAA;CAC7C,QAAQ,MAAwB,MAAI;EAAA,GAAA,YAAA,EAAA,WAAA,QAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACnE,KAAK,MAA2D,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,KAAA,CAAA,+BAAA,CAAA,CAAA;CAC1E,KAAK,MAA6D,QA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KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;IAAA;GAAA;GAAA;IAAA,MAAA;IAAA,MAAE;IAAM,UAAA;IAAA,QAAA,CAAA,MAAA;GAAA;GAAA;IAAA,MAAA;IAAA,MAAE;IAAe,UAAA;IAAA,QAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;KAAA;IAAA;GAAA;EAAA;EAAA,eAWhD,CAAC,sBAAsB,kBAAkB,CAAC;EAAC,iBAAA,GAAA,wBAAA;CAAA,CAAA;;AAE/C,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAM,YAAA,CAAA;EAflB,MAAA;EACW,MAAA,CAAA;GAAA,UAAA;GAAS,SACV;IAAC;IAAkB;IAAY;IAAQ;GAAe;GAAC,iBAG/C,wBAAwB;GAAM,MACzC;IACJ,OAAO;IACP,WAAW;IACX,WAAW;IACX,sBAAsB;IACtB,oBAAoB;GACrB;GAAA,eACc,CAAC,sBAAsB,kBAAkB,CAAC;GAAC,UAAA;GAAA,QAAA,CAAA,i5EAAA;EAAA,CAAA"}
@@ -2,11 +2,12 @@ import * as i0 from "@angular/core";
2
2
  import { ChangeDetectionStrategy, Component, booleanAttribute, computed, forwardRef, inject, input, model, numberAttribute, output, viewChild } from "@angular/core";
3
3
  import { NG_VALUE_ACCESSOR } from "@angular/forms";
4
4
  import { uniqueId } from "@tectra-ng/core/a11y";
5
- import { injectPassThrough, injectUnstyled } from "@tectra-ng/core/config";
5
+ import { injectPassThrough, injectTokens, injectUnstyled } from "@tectra-ng/core/config";
6
6
  import { TxFormControlBase, injectFieldInvalid } from "@tectra-ng/core/forms";
7
7
  import { TxLocaleService } from "@tectra-ng/core/i18n";
8
8
  import { optionalBoolean } from "@tectra-ng/core/utils";
9
- import { toStyleObject } from "@tectra-ng/themes";
9
+ import { provideTxIconDefaults, txIconClone, txIconEnvelope, txIconExclamationCircle, txIconGlobe, txIconLink, txIconList, txIconSparkles, txIconText, txIconTimes } from "@tectra-ng/icons";
10
+ import { listInputTokens, toStyleObject } from "@tectra-ng/themes";
10
11
  import { TxButton } from "@tectra-ng/ui/button";
11
12
  import { TxPill } from "@tectra-ng/ui/pill";
12
13
  import { TxTooltip } from "@tectra-ng/ui/tooltip";
@@ -69,6 +70,18 @@ function txParseList(text, parser, separator = TX_LIST_INPUT_WORDS) {
69
70
  duplicates
70
71
  };
71
72
  }
73
+ const LIST_INPUT_ICON_DEFAULTS = {
74
+ clone: txIconClone,
75
+ envelope: txIconEnvelope,
76
+ "exclamation-circle": txIconExclamationCircle,
77
+ globe: txIconGlobe,
78
+ link: txIconLink,
79
+ list: txIconList,
80
+ sparkles: txIconSparkles,
81
+ text: txIconText,
82
+ times: txIconTimes
83
+ };
84
+ const LIST_INPUT_THEME = { listInput: listInputTokens };
72
85
  const LINE_BREAK = "\n";
73
86
  const TEXTS = {
74
87
  domain: {
@@ -97,6 +110,7 @@ const TEXTS = {
97
110
  }
98
111
  };
99
112
  var TxListInput = class TxListInput extends TxFormControlBase {
113
+ listInputTheme = injectTokens(LIST_INPUT_THEME);
100
114
  locale = inject(TxLocaleService);
101
115
  text = model("", ...ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []);
102
116
  type = input("text", ...ngDevMode ? [{ debugName: "type" }] : /* istanbul ignore next */ []);
@@ -467,6 +481,7 @@ var TxListInput = class TxListInput extends TxFormControlBase {
467
481
  exportAs: ["txTooltip"]
468
482
  }
469
483
  ],
484
+ viewProviders: [provideTxIconDefaults(LIST_INPUT_ICON_DEFAULTS)],
470
485
  changeDetection: i0.ChangeDetectionStrategy.OnPush
471
486
  });
472
487
  };
@@ -503,6 +518,7 @@ i0.ɵɵngDeclareClassMetadata({
503
518
  "[class.tx-list-input--invalid]": "isInvalid()",
504
519
  "[class.tx-list-input--filled]": "!!text()"
505
520
  },
521
+ viewProviders: [provideTxIconDefaults(LIST_INPUT_ICON_DEFAULTS)],
506
522
  template: "<textarea\n #field\n class=\"tx-list-input__field\"\n spellcheck=\"false\"\n autocomplete=\"off\"\n [attr.id]=\"inputId() ?? null\"\n [rows]=\"rows()\"\n [placeholder]=\"placeholderText()\"\n [value]=\"text()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"readonly()\"\n [class]=\"passThrough().field?.class\"\n [style]=\"passThrough().field?.style\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-describedby]=\"statusId\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n (input)=\"onInput($event)\"\n (blur)=\"onBlur()\"\n></textarea>\n\n<div class=\"tx-list-input__footer\" [class]=\"passThrough().footer?.class\" [style]=\"passThrough().footer?.style\">\n <div class=\"tx-list-input__stats\" [id]=\"statusId\" [class]=\"passThrough().stats?.class\" [style]=\"passThrough().stats?.style\">\n @if (isEmpty()) {\n <span class=\"tx-list-input__hint\">{{ hintText() }}</span>\n } @else {\n <tx-pill tone=\"primary\" [icon]=\"texts().icon\" [value]=\"countText()\" [unstyled]=\"isUnstyled()\" />\n @if (parsed().duplicates) {\n <tx-pill tone=\"warn\" icon=\"clone\" [value]=\"duplicatesText()\" [unstyled]=\"isUnstyled()\" />\n }\n @if (parsed().invalid.length) {\n <tx-pill tone=\"danger\" icon=\"exclamation-circle\" [value]=\"invalidCountText()\" [unstyled]=\"isUnstyled()\" />\n }\n }\n </div>\n @if (!readonly()) {\n <div class=\"tx-list-input__actions\" [class]=\"passThrough().actions?.class\" [style]=\"passThrough().actions?.style\">\n @if (canCleanUp()) {\n <button\n type=\"button\"\n txButton\n icon=\"sparkles\"\n [text]=\"true\"\n [label]=\"translations().listInputCleanUp\"\n [disabled]=\"isDisabled()\"\n [txTooltip]=\"translations().listInputCleanUpHint\"\n [unstyled]=\"isUnstyled()\"\n (click)=\"cleanUp()\"\n ></button>\n }\n @if (text()) {\n <button\n type=\"button\"\n txButton\n icon=\"times\"\n severity=\"secondary\"\n [text]=\"true\"\n [label]=\"translations().clear\"\n [disabled]=\"isDisabled()\"\n [unstyled]=\"isUnstyled()\"\n (click)=\"clear()\"\n ></button>\n }\n </div>\n }\n</div>\n\n@if (parsed().invalid.length) {\n <div class=\"tx-list-input__invalid\" [class]=\"passThrough().invalid?.class\" [style]=\"passThrough().invalid?.style\">\n <span class=\"tx-list-input__invalid-title\">{{ translations().listInputInvalid }}</span>\n @for (item of invalidPreview(); track item) {\n <tx-pill tone=\"danger\" size=\"small\" [value]=\"item\" [unstyled]=\"isUnstyled()\" />\n }\n @if (invalidHidden()) {\n <span class=\"tx-list-input__hint\">{{ moreText() }}</span>\n }\n </div>\n}\n",
507
523
  styles: [":host{display:flex;flex-direction:column}.tx-list-input__field{display:block;width:100%;box-sizing:border-box;resize:vertical}.tx-list-input__footer{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between}.tx-list-input__stats{display:flex;flex-wrap:wrap;align-items:center;min-width:0}.tx-list-input__actions{display:flex;align-items:center;margin-inline-start:auto}.tx-list-input__invalid{display:flex;flex-wrap:wrap;align-items:center}:host([data-styled]){overflow:hidden;border:var(--tx-list-input-border-width) solid var(--tx-list-input-border-color);border-radius:var(--tx-list-input-border-radius);background:var(--tx-list-input-background);transition:border-color var(--tx-list-input-transition-duration) ease,box-shadow var(--tx-list-input-transition-duration) ease}:host([data-styled]):focus-within{border-color:var(--tx-list-input-focus-border-color);box-shadow:0 0 0 calc(var(--tx-list-input-focus-border-width) - var(--tx-list-input-border-width)) var(--tx-list-input-focus-border-color)}:host([data-styled]) .tx-list-input__field{min-height:var(--tx-list-input-field-min-height);margin:0;padding:var(--tx-list-input-field-padding);border:0;border-radius:0;outline:none;background:transparent;box-shadow:none;color:var(--tx-list-input-field-color);font-family:var(--tx-list-input-field-font-family);font-size:var(--tx-list-input-field-font-size);line-height:var(--tx-list-input-field-line-height)}:host([data-styled]) .tx-list-input__field::placeholder{color:var(--tx-list-input-field-placeholder-color)}:host([data-styled]) .tx-list-input__footer{gap:var(--tx-list-input-footer-gap);padding:var(--tx-list-input-footer-padding);border-top:1px solid var(--tx-list-input-footer-border-color);background:var(--tx-list-input-footer-background)}:host([data-styled]) .tx-list-input__stats{gap:var(--tx-list-input-footer-stats-gap);padding-inline-start:var(--tx-list-input-footer-stats-padding-start)}:host([data-styled]) .tx-list-input__actions{gap:var(--tx-list-input-footer-actions-gap)}:host([data-styled]) .tx-list-input__hint{color:var(--tx-list-input-hint-color);font-size:var(--tx-list-input-hint-font-size)}:host([data-styled]) .tx-list-input__invalid{gap:var(--tx-list-input-unrecognized-gap);padding:var(--tx-list-input-unrecognized-padding);border-top:1px solid var(--tx-list-input-unrecognized-border-color)}:host([data-styled]) .tx-list-input__invalid-title{margin-inline-end:var(--tx-list-input-unrecognized-title-gap);color:var(--tx-list-input-unrecognized-title-color);font-size:var(--tx-list-input-unrecognized-title-font-size);font-weight:var(--tx-list-input-unrecognized-title-font-weight)}:host([data-styled].tx-list-input--invalid){border-color:var(--tx-list-input-invalid-border-color)}:host([data-styled].tx-list-input--invalid:focus-within){box-shadow:0 0 0 calc(var(--tx-list-input-focus-border-width) - var(--tx-list-input-border-width)) var(--tx-list-input-invalid-border-color)}:host([data-styled].tx-list-input--disabled){opacity:var(--tx-list-input-disabled-opacity)}@media(prefers-reduced-motion:reduce){:host([data-styled]){transition:none}}\n"]
508
524
  }]