@taiga-ui/kit 4.52.0-canary.ece97e9 → 4.52.0-canary.efbd0d4

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 (397) hide show
  1. package/README.md +1 -1
  2. package/components/avatar/avatar-labeled.component.d.ts +3 -3
  3. package/components/avatar/avatar-stack.component.d.ts +2 -2
  4. package/components/badge/badge.options.d.ts +1 -3
  5. package/components/badge-notification/badge-notification.component.d.ts +2 -3
  6. package/components/badge-notification/badge-notification.options.d.ts +1 -3
  7. package/components/badged-content/badged-content.directive.d.ts +2 -2
  8. package/components/block/block.options.d.ts +1 -3
  9. package/components/breadcrumbs/breadcrumbs.component.d.ts +6 -7
  10. package/components/breadcrumbs/breadcrumbs.options.d.ts +1 -3
  11. package/components/button-loading/button-loading.component.d.ts +5 -5
  12. package/components/calendar-range/calendar-range.component.d.ts +0 -1
  13. package/components/calendar-range/day-range-period.d.ts +2 -1
  14. package/components/carousel/carousel.component.d.ts +15 -18
  15. package/components/carousel/carousel.directive.d.ts +5 -4
  16. package/components/chip/chip.options.d.ts +1 -3
  17. package/components/combo-box/combo-box.d.ts +5 -0
  18. package/components/combo-box/combo-box.directive.d.ts +7 -9
  19. package/components/combo-box/index.d.ts +1 -0
  20. package/components/compass/compass.component.d.ts +2 -2
  21. package/components/confirm/confirm.component.d.ts +4 -3
  22. package/components/confirm/confirm.service.d.ts +1 -1
  23. package/components/copy/copy.component.d.ts +3 -4
  24. package/components/copy/copy.directive.d.ts +2 -4
  25. package/components/data-list-wrapper/data-list-group-wrapper.component.d.ts +2 -2
  26. package/components/data-list-wrapper/data-list-wrapper.component.d.ts +14 -22
  27. package/components/data-list-wrapper/{data-list-wrapper.module.d.ts → data-list-wrapper.d.ts} +1 -2
  28. package/components/data-list-wrapper/index.d.ts +1 -1
  29. package/components/drawer/drawer.component.d.ts +3 -4
  30. package/components/files/file/file.component.d.ts +16 -29
  31. package/components/files/file/file.options.d.ts +1 -1
  32. package/components/files/files/files.component.d.ts +5 -8
  33. package/components/files/input-files/input-files.component.d.ts +2 -2
  34. package/components/files/input-files/input-files.content.d.ts +7 -8
  35. package/components/files/input-files/input-files.directive.d.ts +2 -2
  36. package/components/files/input-files/input-files.options.d.ts +1 -3
  37. package/components/filter/filter.component.d.ts +9 -11
  38. package/components/fullscreen/fullscreen.component.d.ts +5 -8
  39. package/components/index.d.ts +0 -3
  40. package/components/input-chip/input-chip.component.d.ts +9 -8
  41. package/components/input-chip/input-chip.d.ts +5 -1
  42. package/components/input-chip/input-chip.directive.d.ts +7 -12
  43. package/components/input-color/index.d.ts +1 -0
  44. package/components/input-color/input-color.component.d.ts +4 -4
  45. package/components/input-color/input-color.d.ts +5 -0
  46. package/components/input-date/input-date.d.ts +4 -1
  47. package/components/input-date/input-date.directive.d.ts +12 -14
  48. package/components/input-date/input-date.options.d.ts +3 -3
  49. package/components/input-date-multi/input-date-multi.d.ts +1 -2
  50. package/components/input-date-multi/input-date-multi.directive.d.ts +10 -14
  51. package/components/input-date-range/input-date-range.d.ts +4 -1
  52. package/components/input-date-range/input-date-range.directive.d.ts +5 -8
  53. package/components/input-date-range/input-date-range.options.d.ts +2 -2
  54. package/components/input-date-time/input-date-time.d.ts +4 -1
  55. package/components/input-date-time/input-date-time.directive.d.ts +6 -6
  56. package/components/input-date-time/input-date-time.options.d.ts +2 -2
  57. package/components/input-month/input-month.d.ts +4 -1
  58. package/components/input-month/input-month.directive.d.ts +6 -5
  59. package/components/input-month-range/input-month-range.d.ts +4 -1
  60. package/components/input-month-range/input-month-range.directive.d.ts +6 -5
  61. package/components/input-number/input-number.d.ts +4 -1
  62. package/components/input-number/input-number.directive.d.ts +5 -7
  63. package/components/input-number/input-number.options.d.ts +2 -3
  64. package/components/input-number/step/input-number-step.component.d.ts +2 -1
  65. package/components/input-phone/index.d.ts +1 -0
  66. package/components/input-phone/input-phone.d.ts +5 -0
  67. package/components/input-phone/input-phone.directive.d.ts +7 -7
  68. package/components/input-phone-international/index.d.ts +1 -0
  69. package/components/input-phone-international/input-phone-international.component.d.ts +9 -8
  70. package/components/input-phone-international/input-phone-international.d.ts +5 -0
  71. package/components/input-phone-international/input-phone-international.options.d.ts +1 -3
  72. package/components/input-pin/index.d.ts +1 -0
  73. package/components/input-pin/input-pin.component.d.ts +3 -3
  74. package/components/input-pin/input-pin.d.ts +5 -0
  75. package/components/input-range/index.d.ts +0 -1
  76. package/components/input-range/input-range.component.d.ts +5 -4
  77. package/components/input-slider/input-slider.d.ts +4 -1
  78. package/components/input-slider/input-slider.directive.d.ts +1 -1
  79. package/components/input-time/input-time.component.d.ts +1 -3
  80. package/components/input-time/input-time.d.ts +4 -1
  81. package/components/input-time/input-time.directive.d.ts +4 -4
  82. package/components/input-year/input-year.d.ts +4 -1
  83. package/components/input-year/input-year.directive.d.ts +5 -5
  84. package/components/input-year/input-year.options.d.ts +2 -2
  85. package/components/like/like.options.d.ts +1 -1
  86. package/components/line-clamp/line-clamp-box.component.d.ts +1 -1
  87. package/components/line-clamp/line-clamp.options.d.ts +1 -3
  88. package/components/multi-select/multi-select-group/multi-select-group.component.d.ts +4 -6
  89. package/components/notification-middle/notification-middle.component.d.ts +2 -2
  90. package/components/notification-middle/notification-middle.directive.d.ts +4 -3
  91. package/components/notification-middle/notification-middle.service.d.ts +7 -3
  92. package/components/pagination/pagination.component.d.ts +22 -52
  93. package/components/pagination/pagination.options.d.ts +3 -6
  94. package/components/preview/dialog/preview-dialog.component.d.ts +2 -2
  95. package/components/preview/dialog/preview-dialog.directive.d.ts +3 -3
  96. package/components/preview/dialog/preview-dialog.service.d.ts +5 -2
  97. package/components/preview/index.d.ts +1 -0
  98. package/components/preview/pagination/preview-pagination.component.d.ts +2 -1
  99. package/components/preview/preview.component.d.ts +1 -1
  100. package/components/preview/preview.d.ts +2 -1
  101. package/{tokens/preview-icons.d.ts → components/preview/preview.options.d.ts} +1 -3
  102. package/components/preview/zoom/preview-zoom.component.d.ts +3 -1
  103. package/components/progress/progress-bar/progress-bar.component.d.ts +3 -4
  104. package/components/progress/progress.options.d.ts +1 -3
  105. package/components/pulse/pulse.component.d.ts +2 -2
  106. package/components/push/push-alert.component.d.ts +2 -2
  107. package/components/push/push.options.d.ts +4 -3
  108. package/components/push/push.service.d.ts +2 -2
  109. package/components/radio/radio.component.d.ts +1 -1
  110. package/components/radio-list/radio-list.component.d.ts +5 -3
  111. package/components/rating/rating.component.d.ts +1 -1
  112. package/components/rating/rating.options.d.ts +1 -3
  113. package/components/routable-dialog/generate-dialogable-route.d.ts +1 -1
  114. package/components/segmented/segmented.component.d.ts +4 -6
  115. package/components/segmented/segmented.directive.d.ts +6 -7
  116. package/components/select/native-select/native-select.component.d.ts +4 -4
  117. package/components/select/select.d.ts +4 -1
  118. package/components/select/select.directive.d.ts +4 -3
  119. package/components/slider/slider.options.d.ts +1 -6
  120. package/components/stepper/step.component.d.ts +6 -8
  121. package/components/stepper/stepper.component.d.ts +6 -11
  122. package/components/switch/switch.component.d.ts +1 -0
  123. package/components/tabs/tabs.options.d.ts +1 -6
  124. package/components/textarea/index.d.ts +2 -1
  125. package/components/textarea/textarea.component.d.ts +4 -4
  126. package/components/textarea/textarea.d.ts +6 -0
  127. package/components/textarea/textarea.directive.d.ts +13 -0
  128. package/components/toast/toast.component.d.ts +4 -4
  129. package/components/toast/toast.options.d.ts +4 -3
  130. package/components/toast/toast.service.d.ts +2 -2
  131. package/components/tree/components/tree-item-content/tree-item-content.component.d.ts +7 -0
  132. package/components/tree/misc/tree.constants.d.ts +0 -3
  133. package/components/tree/misc/tree.tokens.d.ts +1 -6
  134. package/directives/appearance-proxy/appearance-proxy.directive.d.ts +10 -0
  135. package/directives/appearance-proxy/index.d.ts +1 -0
  136. package/directives/button-select/button-select.directive.d.ts +3 -2
  137. package/directives/data-list-dropdown-manager/data-list-dropdown-manager.directive.d.ts +5 -5
  138. package/directives/fade/fade.directive.d.ts +5 -6
  139. package/directives/fluid-typography/fluid-typography.options.d.ts +1 -3
  140. package/directives/highlight/highlight.directive.d.ts +4 -4
  141. package/directives/index.d.ts +1 -1
  142. package/directives/password/password.directive.d.ts +1 -1
  143. package/directives/present/present.directive.d.ts +2 -4
  144. package/directives/tooltip/tooltip.directive.d.ts +1 -1
  145. package/directives/unfinished-validator/unfinished-validator.directive.d.ts +2 -2
  146. package/directives/unmask-handler/unmask-handler.directive.d.ts +3 -3
  147. package/fesm2022/taiga-ui-kit-components-accordion.mjs +8 -9
  148. package/fesm2022/taiga-ui-kit-components-accordion.mjs.map +1 -1
  149. package/fesm2022/taiga-ui-kit-components-action-bar.mjs +7 -7
  150. package/fesm2022/taiga-ui-kit-components-action-bar.mjs.map +1 -1
  151. package/fesm2022/taiga-ui-kit-components-avatar.mjs +34 -48
  152. package/fesm2022/taiga-ui-kit-components-avatar.mjs.map +1 -1
  153. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs +11 -18
  154. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs.map +1 -1
  155. package/fesm2022/taiga-ui-kit-components-badge.mjs +11 -15
  156. package/fesm2022/taiga-ui-kit-components-badge.mjs.map +1 -1
  157. package/fesm2022/taiga-ui-kit-components-badged-content.mjs +9 -12
  158. package/fesm2022/taiga-ui-kit-components-badged-content.mjs.map +1 -1
  159. package/fesm2022/taiga-ui-kit-components-block.mjs +11 -15
  160. package/fesm2022/taiga-ui-kit-components-block.mjs.map +1 -1
  161. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +18 -37
  162. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs.map +1 -1
  163. package/fesm2022/taiga-ui-kit-components-button-loading.mjs +18 -26
  164. package/fesm2022/taiga-ui-kit-components-button-loading.mjs.map +1 -1
  165. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +5 -13
  166. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs.map +1 -1
  167. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +23 -23
  168. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
  169. package/fesm2022/taiga-ui-kit-components-carousel.mjs +64 -114
  170. package/fesm2022/taiga-ui-kit-components-carousel.mjs.map +1 -1
  171. package/fesm2022/taiga-ui-kit-components-checkbox.mjs +5 -6
  172. package/fesm2022/taiga-ui-kit-components-checkbox.mjs.map +1 -1
  173. package/fesm2022/taiga-ui-kit-components-chip.mjs +11 -15
  174. package/fesm2022/taiga-ui-kit-components-chip.mjs.map +1 -1
  175. package/fesm2022/taiga-ui-kit-components-combo-box.mjs +40 -45
  176. package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
  177. package/fesm2022/taiga-ui-kit-components-comment.mjs +7 -7
  178. package/fesm2022/taiga-ui-kit-components-compass.mjs +9 -11
  179. package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
  180. package/fesm2022/taiga-ui-kit-components-confirm.mjs +10 -12
  181. package/fesm2022/taiga-ui-kit-components-confirm.mjs.map +1 -1
  182. package/fesm2022/taiga-ui-kit-components-copy.mjs +19 -33
  183. package/fesm2022/taiga-ui-kit-components-copy.mjs.map +1 -1
  184. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +24 -85
  185. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs.map +1 -1
  186. package/fesm2022/taiga-ui-kit-components-drawer.mjs +15 -32
  187. package/fesm2022/taiga-ui-kit-components-drawer.mjs.map +1 -1
  188. package/fesm2022/taiga-ui-kit-components-files.mjs +111 -239
  189. package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
  190. package/fesm2022/taiga-ui-kit-components-filter.mjs +20 -34
  191. package/fesm2022/taiga-ui-kit-components-filter.mjs.map +1 -1
  192. package/fesm2022/taiga-ui-kit-components-fullscreen.mjs +23 -42
  193. package/fesm2022/taiga-ui-kit-components-fullscreen.mjs.map +1 -1
  194. package/fesm2022/taiga-ui-kit-components-input-chip.mjs +63 -77
  195. package/fesm2022/taiga-ui-kit-components-input-chip.mjs.map +1 -1
  196. package/fesm2022/taiga-ui-kit-components-input-color.mjs +24 -13
  197. package/fesm2022/taiga-ui-kit-components-input-color.mjs.map +1 -1
  198. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +35 -51
  199. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs.map +1 -1
  200. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs +30 -36
  201. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs.map +1 -1
  202. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +32 -29
  203. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs.map +1 -1
  204. package/fesm2022/taiga-ui-kit-components-input-date.mjs +45 -48
  205. package/fesm2022/taiga-ui-kit-components-input-date.mjs.map +1 -1
  206. package/fesm2022/taiga-ui-kit-components-input-inline.mjs +3 -3
  207. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +26 -23
  208. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
  209. package/fesm2022/taiga-ui-kit-components-input-month.mjs +32 -23
  210. package/fesm2022/taiga-ui-kit-components-input-month.mjs.map +1 -1
  211. package/fesm2022/taiga-ui-kit-components-input-number.mjs +53 -50
  212. package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
  213. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +50 -42
  214. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
  215. package/fesm2022/taiga-ui-kit-components-input-phone.mjs +29 -19
  216. package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
  217. package/fesm2022/taiga-ui-kit-components-input-pin.mjs +18 -9
  218. package/fesm2022/taiga-ui-kit-components-input-pin.mjs.map +1 -1
  219. package/fesm2022/taiga-ui-kit-components-input-range.mjs +18 -16
  220. package/fesm2022/taiga-ui-kit-components-input-range.mjs.map +1 -1
  221. package/fesm2022/taiga-ui-kit-components-input-slider.mjs +15 -10
  222. package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
  223. package/fesm2022/taiga-ui-kit-components-input-time.mjs +38 -40
  224. package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
  225. package/fesm2022/taiga-ui-kit-components-input-year.mjs +27 -19
  226. package/fesm2022/taiga-ui-kit-components-input-year.mjs.map +1 -1
  227. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +12 -14
  228. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs.map +1 -1
  229. package/fesm2022/taiga-ui-kit-components-like.mjs +4 -4
  230. package/fesm2022/taiga-ui-kit-components-like.mjs.map +1 -1
  231. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +18 -23
  232. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs.map +1 -1
  233. package/fesm2022/taiga-ui-kit-components-message.mjs +7 -8
  234. package/fesm2022/taiga-ui-kit-components-message.mjs.map +1 -1
  235. package/fesm2022/taiga-ui-kit-components-multi-select.mjs +30 -40
  236. package/fesm2022/taiga-ui-kit-components-multi-select.mjs.map +1 -1
  237. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +37 -26
  238. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs.map +1 -1
  239. package/fesm2022/taiga-ui-kit-components-pager.mjs +6 -8
  240. package/fesm2022/taiga-ui-kit-components-pager.mjs.map +1 -1
  241. package/fesm2022/taiga-ui-kit-components-pagination.mjs +59 -140
  242. package/fesm2022/taiga-ui-kit-components-pagination.mjs.map +1 -1
  243. package/fesm2022/taiga-ui-kit-components-pin.mjs +7 -7
  244. package/fesm2022/taiga-ui-kit-components-pin.mjs.map +1 -1
  245. package/fesm2022/taiga-ui-kit-components-preview.mjs +68 -48
  246. package/fesm2022/taiga-ui-kit-components-preview.mjs.map +1 -1
  247. package/fesm2022/taiga-ui-kit-components-progress.mjs +36 -45
  248. package/fesm2022/taiga-ui-kit-components-progress.mjs.map +1 -1
  249. package/fesm2022/taiga-ui-kit-components-pulse.mjs +7 -11
  250. package/fesm2022/taiga-ui-kit-components-pulse.mjs.map +1 -1
  251. package/fesm2022/taiga-ui-kit-components-push.mjs +22 -23
  252. package/fesm2022/taiga-ui-kit-components-push.mjs.map +1 -1
  253. package/fesm2022/taiga-ui-kit-components-radio-list.mjs +8 -8
  254. package/fesm2022/taiga-ui-kit-components-radio-list.mjs.map +1 -1
  255. package/fesm2022/taiga-ui-kit-components-radio.mjs +8 -9
  256. package/fesm2022/taiga-ui-kit-components-radio.mjs.map +1 -1
  257. package/fesm2022/taiga-ui-kit-components-range.mjs +8 -11
  258. package/fesm2022/taiga-ui-kit-components-range.mjs.map +1 -1
  259. package/fesm2022/taiga-ui-kit-components-rating.mjs +7 -12
  260. package/fesm2022/taiga-ui-kit-components-rating.mjs.map +1 -1
  261. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs +11 -7
  262. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs.map +1 -1
  263. package/fesm2022/taiga-ui-kit-components-segmented.mjs +32 -59
  264. package/fesm2022/taiga-ui-kit-components-segmented.mjs.map +1 -1
  265. package/fesm2022/taiga-ui-kit-components-select.mjs +52 -29
  266. package/fesm2022/taiga-ui-kit-components-select.mjs.map +1 -1
  267. package/fesm2022/taiga-ui-kit-components-slider.mjs +23 -33
  268. package/fesm2022/taiga-ui-kit-components-slider.mjs.map +1 -1
  269. package/fesm2022/taiga-ui-kit-components-status.mjs +6 -6
  270. package/fesm2022/taiga-ui-kit-components-stepper.mjs +45 -79
  271. package/fesm2022/taiga-ui-kit-components-stepper.mjs.map +1 -1
  272. package/fesm2022/taiga-ui-kit-components-switch.mjs +10 -6
  273. package/fesm2022/taiga-ui-kit-components-switch.mjs.map +1 -1
  274. package/fesm2022/taiga-ui-kit-components-tabs.mjs +28 -36
  275. package/fesm2022/taiga-ui-kit-components-tabs.mjs.map +1 -1
  276. package/fesm2022/taiga-ui-kit-components-textarea.mjs +51 -52
  277. package/fesm2022/taiga-ui-kit-components-textarea.mjs.map +1 -1
  278. package/fesm2022/taiga-ui-kit-components-tiles.mjs +14 -15
  279. package/fesm2022/taiga-ui-kit-components-tiles.mjs.map +1 -1
  280. package/fesm2022/taiga-ui-kit-components-toast.mjs +27 -28
  281. package/fesm2022/taiga-ui-kit-components-toast.mjs.map +1 -1
  282. package/fesm2022/taiga-ui-kit-components-tree.mjs +55 -58
  283. package/fesm2022/taiga-ui-kit-components-tree.mjs.map +1 -1
  284. package/fesm2022/taiga-ui-kit-components.mjs +0 -3
  285. package/fesm2022/taiga-ui-kit-components.mjs.map +1 -1
  286. package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs +27 -0
  287. package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs.map +1 -0
  288. package/fesm2022/taiga-ui-kit-directives-button-close.mjs +3 -4
  289. package/fesm2022/taiga-ui-kit-directives-button-close.mjs.map +1 -1
  290. package/fesm2022/taiga-ui-kit-directives-button-group.mjs +7 -7
  291. package/fesm2022/taiga-ui-kit-directives-button-group.mjs.map +1 -1
  292. package/fesm2022/taiga-ui-kit-directives-button-select.mjs +18 -10
  293. package/fesm2022/taiga-ui-kit-directives-button-select.mjs.map +1 -1
  294. package/fesm2022/taiga-ui-kit-directives-chevron.mjs +10 -9
  295. package/fesm2022/taiga-ui-kit-directives-chevron.mjs.map +1 -1
  296. package/fesm2022/taiga-ui-kit-directives-connected.mjs +6 -7
  297. package/fesm2022/taiga-ui-kit-directives-connected.mjs.map +1 -1
  298. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs +25 -53
  299. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs.map +1 -1
  300. package/fesm2022/taiga-ui-kit-directives-fade.mjs +25 -34
  301. package/fesm2022/taiga-ui-kit-directives-fade.mjs.map +1 -1
  302. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs +6 -12
  303. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs.map +1 -1
  304. package/fesm2022/taiga-ui-kit-directives-highlight.mjs +16 -21
  305. package/fesm2022/taiga-ui-kit-directives-highlight.mjs.map +1 -1
  306. package/fesm2022/taiga-ui-kit-directives-password.mjs +10 -9
  307. package/fesm2022/taiga-ui-kit-directives-password.mjs.map +1 -1
  308. package/fesm2022/taiga-ui-kit-directives-present.mjs +10 -18
  309. package/fesm2022/taiga-ui-kit-directives-present.mjs.map +1 -1
  310. package/fesm2022/taiga-ui-kit-directives-sensitive.mjs +6 -6
  311. package/fesm2022/taiga-ui-kit-directives-shimmer.mjs +6 -6
  312. package/fesm2022/taiga-ui-kit-directives-skeleton.mjs +7 -6
  313. package/fesm2022/taiga-ui-kit-directives-skeleton.mjs.map +1 -1
  314. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +9 -9
  315. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs.map +1 -1
  316. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +8 -11
  317. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs.map +1 -1
  318. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs +10 -15
  319. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs.map +1 -1
  320. package/fesm2022/taiga-ui-kit-directives.mjs +1 -1
  321. package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs +43 -0
  322. package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs.map +1 -0
  323. package/fesm2022/taiga-ui-kit-pipes-emails.mjs +3 -4
  324. package/fesm2022/taiga-ui-kit-pipes-emails.mjs.map +1 -1
  325. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs +12 -25
  326. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs.map +1 -1
  327. package/fesm2022/taiga-ui-kit-pipes-flag.mjs +30 -0
  328. package/fesm2022/taiga-ui-kit-pipes-flag.mjs.map +1 -0
  329. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs +4 -5
  330. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs.map +1 -1
  331. package/fesm2022/taiga-ui-kit-pipes-initials.mjs +28 -0
  332. package/fesm2022/taiga-ui-kit-pipes-initials.mjs.map +1 -0
  333. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +10 -9
  334. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs.map +1 -1
  335. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs +3 -4
  336. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs.map +1 -1
  337. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs +3 -4
  338. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs.map +1 -1
  339. package/fesm2022/taiga-ui-kit-pipes.mjs +3 -0
  340. package/fesm2022/taiga-ui-kit-pipes.mjs.map +1 -1
  341. package/fesm2022/taiga-ui-kit-tokens.mjs +4 -123
  342. package/fesm2022/taiga-ui-kit-tokens.mjs.map +1 -1
  343. package/fesm2022/taiga-ui-kit-utils.mjs +3 -15
  344. package/fesm2022/taiga-ui-kit-utils.mjs.map +1 -1
  345. package/package.json +66 -67
  346. package/pipes/auto-color/auto-color.pipe.d.ts +13 -0
  347. package/pipes/auto-color/index.d.ts +1 -0
  348. package/pipes/filter-by-input/filter-by-input.pipe.d.ts +2 -2
  349. package/pipes/flag/flag.pipe.d.ts +14 -0
  350. package/pipes/flag/index.d.ts +1 -0
  351. package/pipes/index.d.ts +3 -0
  352. package/pipes/initials/index.d.ts +1 -0
  353. package/pipes/initials/initials.pipe.d.ts +7 -0
  354. package/pipes/sort-countries/sort-countries.pipe.d.ts +4 -3
  355. package/pipes/stringify-content/stringify-content.pipe.d.ts +2 -3
  356. package/styles/components/avatar.less +14 -14
  357. package/styles/components/badge.less +3 -3
  358. package/styles/components/block.less +4 -4
  359. package/styles/components/chip.less +3 -3
  360. package/styles/components/comment.less +1 -1
  361. package/styles/components/message.less +1 -1
  362. package/styles/components/pin.less +3 -3
  363. package/styles/components/switch.less +2 -2
  364. package/styles/components/toast.less +1 -1
  365. package/tokens/i18n.d.ts +1 -0
  366. package/tokens/index.d.ts +0 -7
  367. package/utils/index.d.ts +0 -2
  368. package/components/elastic-container/elastic-container.component.d.ts +0 -8
  369. package/components/elastic-container/elastic-container.directive.d.ts +0 -7
  370. package/components/elastic-container/index.d.ts +0 -2
  371. package/components/floating-container/floating-container.directive.d.ts +0 -7
  372. package/components/floating-container/index.d.ts +0 -1
  373. package/components/input-range/input-range.d.ts +0 -3
  374. package/components/slides/index.d.ts +0 -1
  375. package/components/slides/slides.directive.d.ts +0 -11
  376. package/components/textarea/textarea-limit.directive.d.ts +0 -26
  377. package/directives/lazy-loading/index.d.ts +0 -2
  378. package/directives/lazy-loading/lazy-loading.directive.d.ts +0 -18
  379. package/directives/lazy-loading/lazy-loading.service.d.ts +0 -12
  380. package/fesm2022/taiga-ui-kit-components-elastic-container.mjs +0 -78
  381. package/fesm2022/taiga-ui-kit-components-elastic-container.mjs.map +0 -1
  382. package/fesm2022/taiga-ui-kit-components-floating-container.mjs +0 -37
  383. package/fesm2022/taiga-ui-kit-components-floating-container.mjs.map +0 -1
  384. package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs +0 -64
  385. package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs.map +0 -1
  386. package/fesm2022/taiga-ui-kit-components-slides.mjs +0 -49
  387. package/fesm2022/taiga-ui-kit-components-slides.mjs.map +0 -1
  388. package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs +0 -81
  389. package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs.map +0 -1
  390. package/tokens/calendar-date-stream.d.ts +0 -10
  391. package/tokens/date-inputs-value-transformers.d.ts +0 -19
  392. package/tokens/input-date-options.d.ts +0 -15
  393. package/tokens/items-handlers.d.ts +0 -26
  394. package/tokens/mobile-calendar.d.ts +0 -6
  395. package/tokens/month-formatter.d.ts +0 -5
  396. package/utils/phone.d.ts +0 -3
  397. package/utils/toggle-day.d.ts +0 -2
@@ -1,21 +1,19 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Input, ChangeDetectionStrategy, ViewEncapsulation, Component } from '@angular/core';
2
+ import { input, ChangeDetectionStrategy, ViewEncapsulation, Component } from '@angular/core';
3
3
 
4
4
  class TuiCompass {
5
5
  constructor() {
6
- this.degrees = NaN;
6
+ this.degrees = input(NaN);
7
7
  }
8
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCompass, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
9
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiCompass, isStandalone: true, selector: "tui-compass", inputs: { degrees: "degrees" }, host: { properties: { "style.--t-degrees.deg": "degrees" } }, ngImport: i0, template: '', isInline: true, styles: ["tui-compass{position:relative;display:inline-block;color:var(--tui-background-accent-1);border-radius:50%;inline-size:1rem;block-size:1rem;border:.1875rem solid var(--tui-background-base);box-shadow:0 0 .1875rem #0000004d;transform-style:preserve-3d}tui-compass:before{content:\"\";position:absolute;top:0;left:.125rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');transform:rotate(var(--t-degrees)) translateY(-.625rem) translateZ(-1rem);inline-size:.75rem;block-size:1rem;background:currentColor}tui-compass:after{position:absolute;top:0;left:0;bottom:0;right:0;content:\"\";border-radius:inherit;background:currentColor linear-gradient(-45deg,rgba(0,0,0,.2),transparent)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
8
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCompass, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
9
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.17", type: TuiCompass, isStandalone: true, selector: "tui-compass", inputs: { degrees: { classPropertyName: "degrees", publicName: "degrees", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "style.--t-degrees.deg": "degrees()" } }, ngImport: i0, template: '', isInline: true, styles: ["tui-compass{position:relative;display:inline-block;color:var(--tui-background-accent-1);border-radius:50%;inline-size:1rem;block-size:1rem;border:.1875rem solid var(--tui-background-base);box-shadow:0 0 .1875rem #0000004d;transform-style:preserve-3d}tui-compass:before{content:\"\";position:absolute;top:0;left:.125rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');transform:rotate(var(--t-degrees)) translateY(-.625rem) translateZ(-1rem);inline-size:.75rem;block-size:1rem;background:currentColor}tui-compass:after{position:absolute;inset:0;content:\"\";border-radius:inherit;background:currentColor linear-gradient(-45deg,rgba(0,0,0,.2),transparent)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
10
10
  }
11
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCompass, decorators: [{
11
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCompass, decorators: [{
12
12
  type: Component,
13
- args: [{ standalone: true, selector: 'tui-compass', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
14
- '[style.--t-degrees.deg]': 'degrees',
15
- }, styles: ["tui-compass{position:relative;display:inline-block;color:var(--tui-background-accent-1);border-radius:50%;inline-size:1rem;block-size:1rem;border:.1875rem solid var(--tui-background-base);box-shadow:0 0 .1875rem #0000004d;transform-style:preserve-3d}tui-compass:before{content:\"\";position:absolute;top:0;left:.125rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');transform:rotate(var(--t-degrees)) translateY(-.625rem) translateZ(-1rem);inline-size:.75rem;block-size:1rem;background:currentColor}tui-compass:after{position:absolute;top:0;left:0;bottom:0;right:0;content:\"\";border-radius:inherit;background:currentColor linear-gradient(-45deg,rgba(0,0,0,.2),transparent)}\n"] }]
16
- }], propDecorators: { degrees: [{
17
- type: Input
18
- }] } });
13
+ args: [{ selector: 'tui-compass', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
14
+ '[style.--t-degrees.deg]': 'degrees()',
15
+ }, styles: ["tui-compass{position:relative;display:inline-block;color:var(--tui-background-accent-1);border-radius:50%;inline-size:1rem;block-size:1rem;border:.1875rem solid var(--tui-background-base);box-shadow:0 0 .1875rem #0000004d;transform-style:preserve-3d}tui-compass:before{content:\"\";position:absolute;top:0;left:.125rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 8.99993C4 8 8 8 12 8.99993C9.91509 5.73239 8.5 3 6 0C3.5 3 2 5.5 0 8.99993Z\"/></svg>');transform:rotate(var(--t-degrees)) translateY(-.625rem) translateZ(-1rem);inline-size:.75rem;block-size:1rem;background:currentColor}tui-compass:after{position:absolute;inset:0;content:\"\";border-radius:inherit;background:currentColor linear-gradient(-45deg,rgba(0,0,0,.2),transparent)}\n"] }]
16
+ }] });
19
17
 
20
18
  /**
21
19
  * Generated bundle index. Do not edit.
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-compass.mjs","sources":["../../../projects/kit/components/compass/compass.component.ts","../../../projects/kit/components/compass/taiga-ui-kit-components-compass.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Input,\n ViewEncapsulation,\n} from '@angular/core';\n\n@Component({\n standalone: true,\n selector: 'tui-compass',\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/compass.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[style.--t-degrees.deg]': 'degrees',\n },\n})\nexport class TuiCompass {\n @Input()\n public degrees = NaN;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAkBa,UAAU,CAAA;AAXvB,IAAA,WAAA,GAAA;QAaW,IAAO,CAAA,OAAA,GAAG,GAAG;AACvB;+GAHY,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAV,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,UAAU,qKART,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,o+BAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAQH,UAAU,EAAA,UAAA,EAAA,CAAA;kBAXtB,SAAS;AACM,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA,IAAI,EACN,QAAA,EAAA,aAAa,EACb,QAAA,EAAA,EAAE,EAEG,aAAA,EAAA,iBAAiB,CAAC,IAAI,EACpB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACzC,IAAA,EAAA;AACF,wBAAA,yBAAyB,EAAE,SAAS;AACvC,qBAAA,EAAA,MAAA,EAAA,CAAA,o+BAAA,CAAA,EAAA;8BAIM,OAAO,EAAA,CAAA;sBADb;;;ACnBL;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-kit-components-compass.mjs","sources":["../../../projects/kit/components/compass/compass.component.ts","../../../projects/kit/components/compass/taiga-ui-kit-components-compass.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n input,\n ViewEncapsulation,\n} from '@angular/core';\n\n@Component({\n selector: 'tui-compass',\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/compass.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[style.--t-degrees.deg]': 'degrees()',\n },\n})\nexport class TuiCompass {\n public readonly degrees = input(NaN);\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAiBa,UAAU,CAAA;AAVvB,IAAA,WAAA,GAAA;AAWoB,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,GAAG,CAAC;AACvC;+GAFY,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAV,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,UAAU,iRART,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,88BAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAQH,UAAU,EAAA,UAAA,EAAA,CAAA;kBAVtB,SAAS;+BACI,aAAa,EAAA,QAAA,EACb,EAAE,EAAA,aAAA,EAEG,iBAAiB,CAAC,IAAI,EACpB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACzC,IAAA,EAAA;AACF,wBAAA,yBAAyB,EAAE,WAAW;AACzC,qBAAA,EAAA,MAAA,EAAA,CAAA,88BAAA,CAAA,EAAA;;;ACfL;;AAEG;;;;"}
@@ -1,15 +1,13 @@
1
1
  import * as i0 from '@angular/core';
2
- import { inject, ChangeDetectionStrategy, Component, Injectable } from '@angular/core';
2
+ import { inject, ChangeDetectionStrategy, Component, InjectionToken, Injectable } from '@angular/core';
3
3
  import { TuiAutoFocus } from '@taiga-ui/cdk/directives/auto-focus';
4
4
  import { TUI_IS_MOBILE } from '@taiga-ui/cdk/tokens';
5
- import { tuiCreateToken } from '@taiga-ui/cdk/utils/miscellaneous';
6
5
  import { TuiButton } from '@taiga-ui/core/components/button';
7
6
  import { TUI_CONFIRM_WORDS } from '@taiga-ui/kit/tokens';
8
7
  import { injectContext, PolymorpheusOutlet, PolymorpheusComponent } from '@taiga-ui/polymorpheus';
9
- import { TuiDialogService } from '@taiga-ui/core/components/dialog';
8
+ import { TuiDialogService } from '@taiga-ui/core/portals/dialog';
10
9
  import { defer, of } from 'rxjs';
11
10
 
12
- // TODO: Remove selector in v5
13
11
  class TuiConfirm {
14
12
  constructor() {
15
13
  this.isMobile = inject(TUI_IS_MOBILE);
@@ -19,15 +17,15 @@ class TuiConfirm {
19
17
  get appearance() {
20
18
  return this.isMobile ? 'secondary' : 'flat';
21
19
  }
22
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiConfirm, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
23
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiConfirm, isStandalone: true, selector: "tui-confirm", ngImport: i0, template: "<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n", styles: [":host{display:block}.t-content:not(:empty){margin-block-end:.875rem;overflow-wrap:break-word}.t-buttons{display:flex;justify-content:flex-end;flex-wrap:wrap-reverse;margin:.375rem -.375rem -.375rem}.t-button{margin:.375rem;white-space:nowrap}:host-context(tui-root._mobile) .t-button{flex:1;overflow:visible}:host-context(tui-dialog[new]){margin-block-start:-.75rem}:host-context(tui-dialog[new]) .t-button{margin:0}:host-context(tui-dialog[new]) .t-buttons{margin-block-end:0;margin-inline-end:0;margin-inline-start:0}:host-context(tui-dialog[new]) .t-buttons:first-child{margin-block-start:2rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAutoFocus, selector: "[tuiAutoFocus]", inputs: ["tuiAutoFocus"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
20
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiConfirm, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
21
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: TuiConfirm, isStandalone: true, selector: "ng-component", ngImport: i0, template: "<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n", styles: [":host{display:block}.t-content:not(:empty){margin-block-end:.875rem;overflow-wrap:break-word}.t-buttons{display:flex;justify-content:flex-end;flex-wrap:wrap-reverse;margin:.375rem -.375rem -.375rem}.t-button{margin:.375rem;white-space:nowrap}:host-context(tui-root._mobile) .t-button{flex:1;overflow:visible}:host-context(tui-dialog){margin-block-start:-.75rem}:host-context(tui-dialog) .t-button{margin:0}:host-context(tui-dialog) .t-buttons{margin-block-end:0;margin-inline-end:0;margin-inline-start:0}:host-context(tui-dialog) .t-buttons:first-child{margin-block-start:2rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAutoFocus, selector: "[tuiAutoFocus]", inputs: ["tuiAutoFocus"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
24
22
  }
25
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiConfirm, decorators: [{
23
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiConfirm, decorators: [{
26
24
  type: Component,
27
- args: [{ selector: 'tui-confirm', imports: [PolymorpheusOutlet, TuiAutoFocus, TuiButton], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n", styles: [":host{display:block}.t-content:not(:empty){margin-block-end:.875rem;overflow-wrap:break-word}.t-buttons{display:flex;justify-content:flex-end;flex-wrap:wrap-reverse;margin:.375rem -.375rem -.375rem}.t-button{margin:.375rem;white-space:nowrap}:host-context(tui-root._mobile) .t-button{flex:1;overflow:visible}:host-context(tui-dialog[new]){margin-block-start:-.75rem}:host-context(tui-dialog[new]) .t-button{margin:0}:host-context(tui-dialog[new]) .t-buttons{margin-block-end:0;margin-inline-end:0;margin-inline-start:0}:host-context(tui-dialog[new]) .t-buttons:first-child{margin-block-start:2rem}\n"] }]
25
+ args: [{ imports: [PolymorpheusOutlet, TuiAutoFocus, TuiButton], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n", styles: [":host{display:block}.t-content:not(:empty){margin-block-end:.875rem;overflow-wrap:break-word}.t-buttons{display:flex;justify-content:flex-end;flex-wrap:wrap-reverse;margin:.375rem -.375rem -.375rem}.t-button{margin:.375rem;white-space:nowrap}:host-context(tui-root._mobile) .t-button{flex:1;overflow:visible}:host-context(tui-dialog){margin-block-start:-.75rem}:host-context(tui-dialog) .t-button{margin:0}:host-context(tui-dialog) .t-buttons{margin-block-end:0;margin-inline-end:0;margin-inline-start:0}:host-context(tui-dialog) .t-buttons:first-child{margin-block-start:2rem}\n"] }]
28
26
  }] });
29
27
  const TUI_CONFIRM = new PolymorpheusComponent(TuiConfirm);
30
- const TUI_CONFIRM_DIALOG = tuiCreateToken(TUI_CONFIRM);
28
+ const TUI_CONFIRM_DIALOG = new InjectionToken(ngDevMode ? 'TUI_CONFIRM_DIALOG' : '', { factory: () => TUI_CONFIRM });
31
29
 
32
30
  class TuiConfirmService {
33
31
  constructor() {
@@ -46,10 +44,10 @@ class TuiConfirmService {
46
44
  ? this.dialogs.open(this.component, { size: 's', ...options })
47
45
  : of(true));
48
46
  }
49
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiConfirmService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
50
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiConfirmService }); }
47
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiConfirmService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
48
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiConfirmService }); }
51
49
  }
52
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiConfirmService, decorators: [{
50
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiConfirmService, decorators: [{
53
51
  type: Injectable
54
52
  }] });
55
53
 
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-confirm.mjs","sources":["../../../projects/kit/components/confirm/confirm.component.ts","../../../projects/kit/components/confirm/confirm.template.html","../../../projects/kit/components/confirm/confirm.service.ts","../../../projects/kit/components/confirm/taiga-ui-kit-components-confirm.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {TuiAutoFocus} from '@taiga-ui/cdk/directives/auto-focus';\nimport {TUI_IS_MOBILE} from '@taiga-ui/cdk/tokens';\nimport {tuiCreateToken} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {type TuiDialogContext} from '@taiga-ui/core/components/dialog';\nimport {TUI_CONFIRM_WORDS} from '@taiga-ui/kit/tokens';\nimport {\n injectContext,\n PolymorpheusComponent,\n type PolymorpheusContent,\n PolymorpheusOutlet,\n} from '@taiga-ui/polymorpheus';\n\nexport interface TuiConfirmData {\n readonly content?: PolymorpheusContent;\n readonly no?: string;\n readonly yes?: string;\n readonly appearance?: string;\n}\n\n// TODO: Remove selector in v5\n@Component({\n selector: 'tui-confirm',\n imports: [PolymorpheusOutlet, TuiAutoFocus, TuiButton],\n templateUrl: './confirm.template.html',\n styleUrl: './confirm.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiConfirm {\n private readonly isMobile = inject(TUI_IS_MOBILE);\n protected readonly words = inject(TUI_CONFIRM_WORDS);\n\n public readonly context =\n injectContext<TuiDialogContext<boolean, TuiConfirmData | undefined>>();\n\n protected get appearance(): string {\n return this.isMobile ? 'secondary' : 'flat';\n }\n}\n\nexport const TUI_CONFIRM = new PolymorpheusComponent(TuiConfirm);\nexport const TUI_CONFIRM_DIALOG =\n tuiCreateToken<PolymorpheusContent<TuiDialogContext<boolean, unknown>>>(TUI_CONFIRM);\n","<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n","import {inject, Injectable} from '@angular/core';\nimport {type TuiDialogOptions, TuiDialogService} from '@taiga-ui/core/components/dialog';\nimport {defer, type Observable, of} from 'rxjs';\n\nimport {TUI_CONFIRM_DIALOG, type TuiConfirmData} from './confirm.component';\n\n@Injectable()\nexport class TuiConfirmService {\n private readonly dialogs = inject(TuiDialogService);\n private readonly component = inject(TUI_CONFIRM_DIALOG);\n private dirty = false;\n\n public markAsDirty(): void {\n this.dirty = true;\n }\n\n public markAsPristine(): void {\n this.dirty = false;\n }\n\n public withConfirm<T = TuiConfirmData>(\n options: Partial<TuiDialogOptions<NoInfer<T>>>,\n ): Observable<boolean> {\n return defer(() =>\n this.dirty\n ? this.dialogs.open<boolean>(this.component, {size: 's', ...options})\n : of(true),\n );\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAqBA;MAQa,UAAU,CAAA;AAPvB,IAAA,WAAA,GAAA;AAQqB,QAAA,IAAA,CAAA,QAAQ,GAA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iB,CAAA;AAD9B,IAAA,WAAA,GAAA;AAEqB,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,gBAAgB,CAAC;AAClC,QAAA,IAAA,CAAA,SAAS,GAAG,MAAM,CAAC,kBAAkB,CAAC;QAC/C,IAAK,CAAA,KAAA,GAAG,KAAK;AAmBxB;IAjBU,WAAW,GAAA;AACd,QAAA,IAAI,CAAC,KAAK,GAAG,IAAI;;IAGd,cAAc,GAAA;AACjB,QAAA,IAAI,CAAC,KAAK,GAAG,KAAK;;AAGf,IAAA,WAAW,CACd,OAA8C,EAAA;AAE9C,QAAA,OAAO,KAAK,CAAC,MACT,IAAI,CAAC;AACD,cAAE,IAAI,CAAC,OAAO,CAAC,IAAI,CAAU,IAAI,CAAC,SAAS,EAAE,EAAC,IAAI,EAAE,GAAG,EAAE,GAAG,OAAO,EAAC;AACpE,cAAE,EAAE,CAAC,IAAI,CAAC,CACjB;;+GApBI,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;mHAAjB,iBAAiB,EAAA,CAAA,CAAA;;4FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAD7B;;;ACND;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-kit-components-confirm.mjs","sources":["../../../projects/kit/components/confirm/confirm.component.ts","../../../projects/kit/components/confirm/confirm.template.html","../../../projects/kit/components/confirm/confirm.service.ts","../../../projects/kit/components/confirm/taiga-ui-kit-components-confirm.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, inject, InjectionToken} from '@angular/core';\nimport {TuiAutoFocus} from '@taiga-ui/cdk/directives/auto-focus';\nimport {TUI_IS_MOBILE} from '@taiga-ui/cdk/tokens';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {type TuiDialogContext} from '@taiga-ui/core/portals/dialog';\nimport {TUI_CONFIRM_WORDS} from '@taiga-ui/kit/tokens';\nimport {\n injectContext,\n PolymorpheusComponent,\n type PolymorpheusContent,\n PolymorpheusOutlet,\n} from '@taiga-ui/polymorpheus';\n\nexport interface TuiConfirmData {\n readonly content?: PolymorpheusContent;\n readonly no?: string;\n readonly yes?: string;\n readonly appearance?: string;\n}\n\n@Component({\n imports: [PolymorpheusOutlet, TuiAutoFocus, TuiButton],\n templateUrl: './confirm.template.html',\n styleUrl: './confirm.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiConfirm {\n private readonly isMobile = inject(TUI_IS_MOBILE);\n protected readonly words = inject(TUI_CONFIRM_WORDS);\n\n public readonly context =\n injectContext<TuiDialogContext<boolean, TuiConfirmData | undefined>>();\n\n protected get appearance(): string {\n return this.isMobile ? 'secondary' : 'flat';\n }\n}\n\nexport const TUI_CONFIRM = new PolymorpheusComponent(TuiConfirm);\nexport const TUI_CONFIRM_DIALOG = new InjectionToken<\n PolymorpheusContent<TuiDialogContext<boolean, unknown>>\n>(ngDevMode ? 'TUI_CONFIRM_DIALOG' : '', {factory: () => TUI_CONFIRM});\n","<p\n *polymorpheusOutlet=\"context.data?.content as text\"\n class=\"t-content\"\n [innerHTML]=\"text\"\n></p>\n<footer class=\"t-buttons\">\n <button\n size=\"m\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"appearance\"\n (click)=\"context.completeWith(false)\"\n >\n {{ context.data?.no || words().no }}\n </button>\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"context.data?.appearance || 'primary'\"\n (click)=\"context.completeWith(true)\"\n >\n {{ context.data?.yes || words().yes }}\n </button>\n</footer>\n","import {inject, Injectable} from '@angular/core';\nimport {type TuiDialogOptions, TuiDialogService} from '@taiga-ui/core/portals/dialog';\nimport {defer, type Observable, of} from 'rxjs';\n\nimport {TUI_CONFIRM_DIALOG, type TuiConfirmData} from './confirm.component';\n\n@Injectable()\nexport class TuiConfirmService {\n private readonly dialogs = inject(TuiDialogService);\n private readonly component = inject(TUI_CONFIRM_DIALOG);\n private dirty = false;\n\n public markAsDirty(): void {\n this.dirty = true;\n }\n\n public markAsPristine(): void {\n this.dirty = false;\n }\n\n public withConfirm<T = TuiConfirmData>(\n options: Partial<TuiDialogOptions<NoInfer<T>>>,\n ): Observable<boolean> {\n return defer(() =>\n this.dirty\n ? this.dialogs.open<boolean>(this.component, {size: 's', ...options})\n : of(true),\n );\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;MA0Ba,UAAU,CAAA;AANvB,IAAA,WAAA,GAAA;AAOqB,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,aAAa,CAAC;AAC9B,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,iBAAiB,CAAC;QAEpC,IAAO,CAAA,OAAA,GACnB,aAAa,EAAyD;AAK7E;AAHG,IAAA,IAAc,UAAU,GAAA;QACpB,OAAO,IAAI,CAAC,QAAQ,GAAG,WAAW,GAAG,MAAM;;+GARtC,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAV,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,UAAU,wEC1BvB,4tBA4BA,EAAA,MAAA,EAAA,CAAA,qkBAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EDPc,kBAAkB,EAAE,QAAA,EAAA,sBAAA,EAAA,MAAA,EAAA,CAAA,oBAAA,EAAA,2BAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,YAAY,qFAAE,SAAS,EAAA,QAAA,EAAA,uEAAA,EAAA,MAAA,EAAA,CAAA,MAAA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AAA;kBAD7B;;;ACND;;AAEG;;;;"}
@@ -1,18 +1,18 @@
1
1
  import * as i1 from '@angular/cdk/clipboard';
2
2
  import { ClipboardModule } from '@angular/cdk/clipboard';
3
3
  import * as i0 from '@angular/core';
4
- import { inject, Input, ChangeDetectionStrategy, Component, Directive } from '@angular/core';
4
+ import { inject, input, ChangeDetectionStrategy, Component, Directive } from '@angular/core';
5
5
  import { toSignal, toObservable } from '@angular/core/rxjs-interop';
6
6
  import { TUI_FALSE_HANDLER } from '@taiga-ui/cdk/constants';
7
- import { tuiIsString, tuiDirectiveBinding } from '@taiga-ui/cdk/utils/miscellaneous';
7
+ import { tuiIsString } from '@taiga-ui/cdk/utils/miscellaneous';
8
8
  import { TuiButton } from '@taiga-ui/core/components/button';
9
9
  import { TuiIcon } from '@taiga-ui/core/components/icon';
10
10
  import { TUI_NOTIFICATION_OPTIONS } from '@taiga-ui/core/components/notification';
11
- import * as i2 from '@taiga-ui/core/directives/hint';
12
- import { TuiHint, TuiHintDirective } from '@taiga-ui/core/directives/hint';
11
+ import * as i2 from '@taiga-ui/core/portals/hint';
12
+ import { TuiHint, TuiHintDirective } from '@taiga-ui/core/portals/hint';
13
13
  import { TUI_COPY_TEXTS } from '@taiga-ui/kit/tokens';
14
14
  import { BehaviorSubject, switchMap, timer, map, startWith, Subject } from 'rxjs';
15
- import { tuiCreateOptions } from '@taiga-ui/cdk/utils/di';
15
+ import { tuiCreateOptions, tuiDirectiveBinding } from '@taiga-ui/cdk/utils/di';
16
16
  import { DOCUMENT } from '@angular/common';
17
17
  import { TuiTextfieldComponent, tuiTextfieldIcon } from '@taiga-ui/core/components/textfield';
18
18
  import * as i1$1 from '@taiga-ui/core/directives/appearance';
@@ -27,30 +27,23 @@ class TuiCopyComponent {
27
27
  this.copied$ = new BehaviorSubject(false);
28
28
  this.texts = inject(TUI_COPY_TEXTS);
29
29
  this.hint = toSignal(this.copied$.pipe(switchMap((copied) => timer(2000).pipe(map(TUI_FALSE_HANDLER), startWith(copied)))));
30
- this.size = 'm';
31
- }
32
- get icon() {
33
- return tuiIsString(this.options.icon)
34
- ? this.options.icon
35
- : this.options.icon(this.size);
30
+ this.size = input('m');
36
31
  }
37
32
  get check() {
38
33
  return tuiIsString(this.notification.icon)
39
34
  ? this.notification.icon
40
35
  : this.notification.icon('positive');
41
36
  }
42
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCopyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
43
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiCopyComponent, isStandalone: true, selector: "tui-copy", inputs: { size: "size" }, host: { listeners: { "pointerdown": "copied$.next(false)" }, properties: { "attr.data-size": "size" } }, ngImport: i0, template: "<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"icon\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n", styles: [":host{cursor:pointer}:host[data-size=m]{--t-size: min( calc(1em + 1px) , 1rem)}:host[data-size=l]{--t-size: max(calc(1em / 1.57), min(max(calc(1em / 1.18), 1.25rem), 1.5rem))}@media (hover: hover) and (pointer: fine){:host:hover .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}:host:hover .t-button{opacity:1}}:host:has(.t-button:focus-visible) .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}.t-content{transition-property:opacity,mask;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;mask:linear-gradient(to var(--tui-inline-start),transparent calc(1.25 * var(--t-size)),black calc(2 * var(--t-size))) no-repeat,linear-gradient(to var(--tui-inline-end),black,black calc(2 * var(--t-size)),transparent calc(2 * var(--t-size))) no-repeat;-webkit-mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0;mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0}.t-button{opacity:0;border-radius:0;font-size:inherit!important;margin-inline-start:calc(-1 * var(--t-size));--t-size: inherit}.t-button:before{font-size:var(--t-size)}.t-button:focus-visible{opacity:1}.t-icon{font-size:1rem;margin-inline-end:.25rem;vertical-align:sub;color:var(--tui-text-positive)}\n"], dependencies: [{ kind: "ngmodule", type: ClipboardModule }, { kind: "directive", type: i1.CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: i2.TuiHintDirective, selector: "[tuiHint]:not(ng-container):not(ng-template)", inputs: ["tuiHint", "tuiHintContext", "tuiHintAppearance"], outputs: ["tuiHintVisible"] }, { kind: "directive", type: i2.TuiHintManual, selector: "[tuiHint][tuiHintManual]", inputs: ["tuiHintManual"] }, { kind: "component", type: TuiIcon, selector: "tui-icon:not([tuiBadge])", inputs: ["background"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
37
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCopyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
38
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.17", type: TuiCopyComponent, isStandalone: true, selector: "tui-copy", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "pointerdown": "copied$.next(false)" }, properties: { "attr.data-size": "size()" } }, ngImport: i0, template: "<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"options.icon(size())\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n", styles: [":host{cursor:pointer}:host[data-size=m]{--t-size: min( calc(1em + 1px) , 1rem)}:host[data-size=l]{--t-size: max(calc(1em / 1.57), min(max(calc(1em / 1.18), 1.25rem), 1.5rem))}@media (hover: hover) and (pointer: fine){:host:hover .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}:host:hover .t-button{opacity:1}}:host:has(.t-button:focus-visible) .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}.t-content{transition-property:opacity,mask;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;mask:linear-gradient(to var(--tui-inline-start),transparent calc(1.25 * var(--t-size)),black calc(2 * var(--t-size))) no-repeat,linear-gradient(to var(--tui-inline-end),black,black calc(2 * var(--t-size)),transparent calc(2 * var(--t-size))) no-repeat;-webkit-mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0;mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0}.t-button{position:sticky;inset-inline-start:0;opacity:0;border-radius:0;font-size:inherit!important;margin-inline-start:calc(-1 * var(--t-size));--t-size: inherit}.t-button:before{font-size:var(--t-size)}.t-button:focus-visible{opacity:1}.t-icon{font-size:1rem;margin-inline-end:.25rem;vertical-align:sub;color:var(--tui-text-positive)}\n"], dependencies: [{ kind: "ngmodule", type: ClipboardModule }, { kind: "directive", type: i1.CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: i2.TuiHintDirective, selector: "[tuiHint]:not(ng-container):not(ng-template)", inputs: ["tuiHint", "tuiHintContext", "tuiHintAppearance"], outputs: ["tuiHintVisible"] }, { kind: "directive", type: i2.TuiHintManual, selector: "[tuiHint][tuiHintManual]", inputs: ["tuiHintManual"] }, { kind: "component", type: TuiIcon, selector: "tui-icon:not([tuiBadge])", inputs: ["background"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
44
39
  }
45
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCopyComponent, decorators: [{
40
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCopyComponent, decorators: [{
46
41
  type: Component,
47
42
  args: [{ selector: 'tui-copy', imports: [ClipboardModule, TuiButton, TuiHint, TuiIcon], changeDetection: ChangeDetectionStrategy.OnPush, host: {
48
- '[attr.data-size]': 'size',
43
+ '[attr.data-size]': 'size()',
49
44
  '(pointerdown)': 'copied$.next(false)',
50
- }, template: "<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"icon\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n", styles: [":host{cursor:pointer}:host[data-size=m]{--t-size: min( calc(1em + 1px) , 1rem)}:host[data-size=l]{--t-size: max(calc(1em / 1.57), min(max(calc(1em / 1.18), 1.25rem), 1.5rem))}@media (hover: hover) and (pointer: fine){:host:hover .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}:host:hover .t-button{opacity:1}}:host:has(.t-button:focus-visible) .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}.t-content{transition-property:opacity,mask;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;mask:linear-gradient(to var(--tui-inline-start),transparent calc(1.25 * var(--t-size)),black calc(2 * var(--t-size))) no-repeat,linear-gradient(to var(--tui-inline-end),black,black calc(2 * var(--t-size)),transparent calc(2 * var(--t-size))) no-repeat;-webkit-mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0;mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0}.t-button{opacity:0;border-radius:0;font-size:inherit!important;margin-inline-start:calc(-1 * var(--t-size));--t-size: inherit}.t-button:before{font-size:var(--t-size)}.t-button:focus-visible{opacity:1}.t-icon{font-size:1rem;margin-inline-end:.25rem;vertical-align:sub;color:var(--tui-text-positive)}\n"] }]
51
- }], propDecorators: { size: [{
52
- type: Input
53
- }] } });
45
+ }, template: "<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"options.icon(size())\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n", styles: [":host{cursor:pointer}:host[data-size=m]{--t-size: min( calc(1em + 1px) , 1rem)}:host[data-size=l]{--t-size: max(calc(1em / 1.57), min(max(calc(1em / 1.18), 1.25rem), 1.5rem))}@media (hover: hover) and (pointer: fine){:host:hover .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}:host:hover .t-button{opacity:1}}:host:has(.t-button:focus-visible) .t-content{opacity:var(--tui-disabled-opacity);-webkit-mask-position:0;mask-position:0}.t-content{transition-property:opacity,mask;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;mask:linear-gradient(to var(--tui-inline-start),transparent calc(1.25 * var(--t-size)),black calc(2 * var(--t-size))) no-repeat,linear-gradient(to var(--tui-inline-end),black,black calc(2 * var(--t-size)),transparent calc(2 * var(--t-size))) no-repeat;-webkit-mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0;mask-position:calc(var(--tui-inline) * 2 * var(--t-size)),0}.t-button{position:sticky;inset-inline-start:0;opacity:0;border-radius:0;font-size:inherit!important;margin-inline-start:calc(-1 * var(--t-size));--t-size: inherit}.t-button:before{font-size:var(--t-size)}.t-button:focus-visible{opacity:1}.t-icon{font-size:1rem;margin-inline-end:.25rem;vertical-align:sub;color:var(--tui-text-positive)}\n"] }]
46
+ }] });
54
47
 
55
48
  class TuiCopyDirective {
56
49
  constructor() {
@@ -60,28 +53,23 @@ class TuiCopyDirective {
60
53
  this.icons = tuiTextfieldIcon(TUI_COPY_OPTIONS);
61
54
  this.copyTexts = inject(TUI_COPY_TEXTS);
62
55
  this.hint = tuiDirectiveBinding(TuiHintDirective, 'content', toSignal(toObservable(inject(TUI_COPY_TEXTS)).pipe(switchMap(([copy, copied]) => this.copied$.pipe(switchMap(() => timer(3000).pipe(map(() => copy), startWith(copied))), startWith(copy)))), { initialValue: '' }));
63
- this.tuiCopy = '';
64
- }
65
- get disabled() {
66
- return !this.textfield.input?.nativeElement.value;
67
56
  }
68
57
  copy() {
69
- this.textfield.input?.nativeElement.select();
58
+ this.textfield.input()?.nativeElement.select();
70
59
  this.doc.execCommand('copy');
71
60
  this.copied$.next();
72
61
  }
73
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCopyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
74
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiCopyDirective, isStandalone: true, selector: "tui-icon[tuiCopy]", inputs: { tuiCopy: "tuiCopy" }, host: { listeners: { "click": "copy()" }, properties: { "style.pointer-events": "disabled ? \"none\" : null", "style.opacity": "disabled ? \"var(--tui-disabled-opacity)\" : null", "style.border-width.rem": "textfield.options.size() === \"l\" ? null : 0.25" }, styleAttribute: "cursor: pointer" }, providers: [
62
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCopyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
63
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.17", type: TuiCopyDirective, isStandalone: true, selector: "tui-icon[tuiCopy]", host: { listeners: { "click": "copy()" }, properties: { "style.pointer-events": "textfield.value() ? null : \"none\"", "style.opacity": "textfield.value() ? null : \"var(--tui-disabled-opacity)\"", "style.border-width.rem": "textfield.options.size() === \"l\" ? null : 0.25" }, styleAttribute: "cursor: pointer" }, providers: [
75
64
  {
76
65
  provide: TUI_APPEARANCE_OPTIONS,
77
66
  useValue: { appearance: 'icon' },
78
67
  },
79
68
  ], hostDirectives: [{ directive: i1$1.TuiWithAppearance }, { directive: i2.TuiHintDirective, inputs: ["tuiHintAppearance", "tuiHintAppearance", "tuiHintContext", "tuiHintContext"] }], ngImport: i0 }); }
80
69
  }
81
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiCopyDirective, decorators: [{
70
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiCopyDirective, decorators: [{
82
71
  type: Directive,
83
72
  args: [{
84
- standalone: true,
85
73
  selector: 'tui-icon[tuiCopy]',
86
74
  providers: [
87
75
  {
@@ -99,14 +87,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
99
87
  host: {
100
88
  style: 'cursor: pointer',
101
89
  '(click)': 'copy()',
102
- '[style.pointer-events]': 'disabled ? "none" : null',
103
- '[style.opacity]': 'disabled ? "var(--tui-disabled-opacity)" : null',
90
+ '[style.pointer-events]': 'textfield.value() ? null : "none"',
91
+ '[style.opacity]': 'textfield.value() ? null : "var(--tui-disabled-opacity)"',
104
92
  '[style.border-width.rem]': 'textfield.options.size() === "l" ? null : 0.25',
105
93
  },
106
94
  }]
107
- }], propDecorators: { tuiCopy: [{
108
- type: Input
109
- }] } });
95
+ }] });
110
96
 
111
97
  const TuiCopy = [TuiCopyComponent, TuiCopyDirective];
112
98
 
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-copy.mjs","sources":["../../../projects/kit/components/copy/copy.options.ts","../../../projects/kit/components/copy/copy.component.ts","../../../projects/kit/components/copy/copy.template.html","../../../projects/kit/components/copy/copy.directive.ts","../../../projects/kit/components/copy/copy.ts","../../../projects/kit/components/copy/index.ts","../../../projects/kit/components/copy/taiga-ui-kit-components-copy.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiCopyOptions {\n readonly icon: TuiStringHandler<TuiSizeL | TuiSizeS>;\n}\n\nexport const [TUI_COPY_OPTIONS, tuiCopyOptionsProvider] =\n tuiCreateOptions<TuiCopyOptions>({icon: () => '@tui.copy'});\n","import {ClipboardModule} from '@angular/cdk/clipboard';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {TUI_FALSE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiIcon} from '@taiga-ui/core/components/icon';\nimport {TUI_NOTIFICATION_OPTIONS} from '@taiga-ui/core/components/notification';\nimport {TuiHint} from '@taiga-ui/core/directives/hint';\nimport {type TuiSizeL} from '@taiga-ui/core/types';\nimport {TUI_COPY_TEXTS} from '@taiga-ui/kit/tokens';\nimport {BehaviorSubject, map, startWith, switchMap, timer} from 'rxjs';\n\nimport {TUI_COPY_OPTIONS} from './copy.options';\n\n@Component({\n selector: 'tui-copy',\n imports: [ClipboardModule, TuiButton, TuiHint, TuiIcon],\n templateUrl: './copy.template.html',\n styleUrl: './copy.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.data-size]': 'size',\n '(pointerdown)': 'copied$.next(false)',\n },\n})\nexport class TuiCopyComponent {\n protected readonly notification = inject(TUI_NOTIFICATION_OPTIONS);\n protected readonly options = inject(TUI_COPY_OPTIONS);\n protected readonly copied$ = new BehaviorSubject<boolean>(false);\n protected readonly texts = inject(TUI_COPY_TEXTS);\n protected readonly hint = toSignal(\n this.copied$.pipe(\n switchMap((copied) =>\n timer(2000).pipe(map(TUI_FALSE_HANDLER), startWith(copied)),\n ),\n ),\n );\n\n @Input()\n public size: TuiSizeL = 'm';\n\n protected get icon(): string {\n return tuiIsString(this.options.icon)\n ? this.options.icon\n : this.options.icon(this.size);\n }\n\n protected get check(): string {\n return tuiIsString(this.notification.icon)\n ? this.notification.icon\n : this.notification.icon('positive');\n }\n}\n","<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"icon\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n","import {DOCUMENT} from '@angular/common';\nimport {Directive, inject, Input} from '@angular/core';\nimport {toObservable, toSignal} from '@angular/core/rxjs-interop';\nimport {tuiDirectiveBinding} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {\n TuiTextfieldComponent,\n tuiTextfieldIcon,\n} from '@taiga-ui/core/components/textfield';\nimport {\n TUI_APPEARANCE_OPTIONS,\n TuiWithAppearance,\n} from '@taiga-ui/core/directives/appearance';\nimport {TuiHintDirective} from '@taiga-ui/core/directives/hint';\nimport {TUI_COPY_TEXTS} from '@taiga-ui/kit/tokens';\nimport {map, startWith, Subject, switchMap, timer} from 'rxjs';\n\nimport {TUI_COPY_OPTIONS} from './copy.options';\n\n@Directive({\n standalone: true,\n selector: 'tui-icon[tuiCopy]',\n providers: [\n {\n provide: TUI_APPEARANCE_OPTIONS,\n useValue: {appearance: 'icon'},\n },\n ],\n hostDirectives: [\n TuiWithAppearance,\n {\n directive: TuiHintDirective,\n inputs: ['tuiHintAppearance', 'tuiHintContext'],\n },\n ],\n host: {\n style: 'cursor: pointer',\n '(click)': 'copy()',\n '[style.pointer-events]': 'disabled ? \"none\" : null',\n '[style.opacity]': 'disabled ? \"var(--tui-disabled-opacity)\" : null',\n '[style.border-width.rem]': 'textfield.options.size() === \"l\" ? null : 0.25',\n },\n})\nexport class TuiCopyDirective {\n private readonly copied$ = new Subject<void>();\n private readonly doc = inject(DOCUMENT);\n\n protected readonly textfield = inject(TuiTextfieldComponent);\n protected readonly icons = tuiTextfieldIcon(TUI_COPY_OPTIONS);\n protected readonly copyTexts = inject(TUI_COPY_TEXTS);\n\n protected readonly hint = tuiDirectiveBinding(\n TuiHintDirective,\n 'content',\n toSignal(\n toObservable(inject(TUI_COPY_TEXTS)).pipe(\n switchMap(([copy, copied]) =>\n this.copied$.pipe(\n switchMap(() =>\n timer(3000).pipe(\n map(() => copy),\n startWith(copied),\n ),\n ),\n startWith(copy),\n ),\n ),\n ),\n {initialValue: ''},\n ),\n );\n\n @Input()\n public tuiCopy = '';\n\n protected get disabled(): boolean {\n return !this.textfield.input?.nativeElement.value;\n }\n\n protected copy(): void {\n this.textfield.input?.nativeElement.select();\n this.doc.execCommand('copy');\n this.copied$.next();\n }\n}\n","import {TuiCopyComponent} from './copy.component';\nimport {TuiCopyDirective} from './copy.directive';\n\nexport const TuiCopy = [TuiCopyComponent, TuiCopyDirective] as const;\n","// TODO: Move to components in v5\nexport * from './copy';\nexport * from './copy.component';\nexport * from './copy.directive';\nexport * from './copy.options';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;;;AAQa,MAAA,CAAC,gBAAgB,EAAE,sBAAsB,CAAC,GACnD,gBAAgB,CAAiB,EAAC,IAAI,EAAE,MAAM,WAAW,EAAC;;MCiBjD,gBAAgB,CA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E,qBAAA;AACJ,iBAAA;8BA+BU,OAAO,EAAA,CAAA;sBADb;;;MCpEQ,OAAO,GAAG,CAAC,gBAAgB,EAAE,gBAAgB;;ACH1D;;ACAA;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-kit-components-copy.mjs","sources":["../../../projects/kit/components/copy/copy.options.ts","../../../projects/kit/components/copy/copy.component.ts","../../../projects/kit/components/copy/copy.template.html","../../../projects/kit/components/copy/copy.directive.ts","../../../projects/kit/components/copy/copy.ts","../../../projects/kit/components/copy/index.ts","../../../projects/kit/components/copy/taiga-ui-kit-components-copy.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiCopyOptions {\n readonly icon: TuiStringHandler<TuiSizeL | TuiSizeS>;\n}\n\nexport const [TUI_COPY_OPTIONS, tuiCopyOptionsProvider] =\n tuiCreateOptions<TuiCopyOptions>({icon: () => '@tui.copy'});\n","import {ClipboardModule} from '@angular/cdk/clipboard';\nimport {ChangeDetectionStrategy, Component, inject, input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {TUI_FALSE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiIcon} from '@taiga-ui/core/components/icon';\nimport {TUI_NOTIFICATION_OPTIONS} from '@taiga-ui/core/components/notification';\nimport {TuiHint} from '@taiga-ui/core/portals/hint';\nimport {type TuiSizeL} from '@taiga-ui/core/types';\nimport {TUI_COPY_TEXTS} from '@taiga-ui/kit/tokens';\nimport {BehaviorSubject, map, startWith, switchMap, timer} from 'rxjs';\n\nimport {TUI_COPY_OPTIONS} from './copy.options';\n\n@Component({\n selector: 'tui-copy',\n imports: [ClipboardModule, TuiButton, TuiHint, TuiIcon],\n templateUrl: './copy.template.html',\n styleUrl: './copy.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.data-size]': 'size()',\n '(pointerdown)': 'copied$.next(false)',\n },\n})\nexport class TuiCopyComponent {\n protected readonly notification = inject(TUI_NOTIFICATION_OPTIONS);\n protected readonly options = inject(TUI_COPY_OPTIONS);\n protected readonly copied$ = new BehaviorSubject<boolean>(false);\n protected readonly texts = inject(TUI_COPY_TEXTS);\n protected readonly hint = toSignal(\n this.copied$.pipe(\n switchMap((copied) =>\n timer(2000).pipe(map(TUI_FALSE_HANDLER), startWith(copied)),\n ),\n ),\n );\n\n public readonly size = input<TuiSizeL>('m');\n\n protected get check(): string {\n return tuiIsString(this.notification.icon)\n ? this.notification.icon\n : this.notification.icon('positive');\n }\n}\n","<span\n #content\n tuiHintAppearance=\"dark\"\n tuiHintDirection=\"top\"\n class=\"t-content\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [tuiHint]=\"template\"\n [tuiHintManual]=\"!!hint()\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n>\n <ng-content />\n</span>\n<button\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [attr.aria-label]=\"texts()[0]\"\n [cdkCopyToClipboard]=\"content.textContent ?? ''\"\n [iconStart]=\"options.icon(size())\"\n (cdkCopyToClipboardCopied)=\"copied$.next($event)\"\n></button>\n<ng-template #template>\n <tui-icon\n class=\"t-icon\"\n [icon]=\"check\"\n />\n {{ texts()[1] }}\n</ng-template>\n","import {DOCUMENT} from '@angular/common';\nimport {Directive, inject} from '@angular/core';\nimport {toObservable, toSignal} from '@angular/core/rxjs-interop';\nimport {tuiDirectiveBinding} from '@taiga-ui/cdk/utils/di';\nimport {\n TuiTextfieldComponent,\n tuiTextfieldIcon,\n} from '@taiga-ui/core/components/textfield';\nimport {\n TUI_APPEARANCE_OPTIONS,\n TuiWithAppearance,\n} from '@taiga-ui/core/directives/appearance';\nimport {TuiHintDirective} from '@taiga-ui/core/portals/hint';\nimport {TUI_COPY_TEXTS} from '@taiga-ui/kit/tokens';\nimport {map, startWith, Subject, switchMap, timer} from 'rxjs';\n\nimport {TUI_COPY_OPTIONS} from './copy.options';\n\n@Directive({\n selector: 'tui-icon[tuiCopy]',\n providers: [\n {\n provide: TUI_APPEARANCE_OPTIONS,\n useValue: {appearance: 'icon'},\n },\n ],\n hostDirectives: [\n TuiWithAppearance,\n {\n directive: TuiHintDirective,\n inputs: ['tuiHintAppearance', 'tuiHintContext'],\n },\n ],\n host: {\n style: 'cursor: pointer',\n '(click)': 'copy()',\n '[style.pointer-events]': 'textfield.value() ? null : \"none\"',\n '[style.opacity]': 'textfield.value() ? null : \"var(--tui-disabled-opacity)\"',\n '[style.border-width.rem]': 'textfield.options.size() === \"l\" ? null : 0.25',\n },\n})\nexport class TuiCopyDirective {\n private readonly copied$ = new Subject<void>();\n private readonly doc = inject(DOCUMENT);\n\n protected readonly textfield = inject(TuiTextfieldComponent);\n protected readonly icons = tuiTextfieldIcon(TUI_COPY_OPTIONS);\n protected readonly copyTexts = inject(TUI_COPY_TEXTS);\n protected readonly hint = tuiDirectiveBinding(\n TuiHintDirective,\n 'content',\n toSignal(\n toObservable(inject(TUI_COPY_TEXTS)).pipe(\n switchMap(([copy, copied]) =>\n this.copied$.pipe(\n switchMap(() =>\n timer(3000).pipe(\n map(() => copy),\n startWith(copied),\n ),\n ),\n startWith(copy),\n ),\n ),\n ),\n {initialValue: ''},\n ),\n );\n\n protected copy(): void {\n this.textfield.input()?.nativeElement.select();\n this.doc.execCommand('copy');\n this.copied$.next();\n }\n}\n","import {TuiCopyComponent} from './copy.component';\nimport {TuiCopyDirective} from './copy.directive';\n\nexport const TuiCopy = [TuiCopyComponent, TuiCopyDirective] as const;\n","// TODO: Move to components in v5\nexport * from './copy';\nexport * from './copy.component';\nexport * from './copy.directive';\nexport * from './copy.options';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';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,sBAAsB;AAC/B,gBAAA,QAAQ,EAAE,EAAC,UAAU,EAAE,MAAM,EAAC;AACjC,aAAA;AACJ,SAAA,EAAA,cAAA,EAAA,CAAA,EAAA,SAAA,EAAAA,IAAA,CAAA,iBAAA,EAAA,EAAA,EAAA,SAAA,EAAA,EAAA,CAAA,gBAAA,EAAA,MAAA,EAAA,CAAA,mBAAA,EAAA,mBAAA,EAAA,gBAAA,EAAA,gBAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAgBQ,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAvB5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,mBAAmB;AAC7B,oBAAA,SAAS,EAAE;AACP,wBAAA;AACI,4BAAA,OAAO,EAAE,sBAAsB;AAC/B,4BAAA,QAAQ,EAAE,EAAC,UAAU,EAAE,MAAM,EAAC;AACjC,yBAAA;AACJ,qBAAA;AACD,oBAAA,cAAc,EAAE;wBACZ,iBAAiB;AACjB,wBAAA;AACI,4BAAA,SAAS,EAAE,gBAAgB;AAC3B,4BAAA,MAAM,EAAE,CAAC,mBAAmB,EAAE,gBAAgB,CAAC;AAClD,yBAAA;AACJ,qBAAA;AACD,oBAAA,IAAI,EAAE;AACF,wBAAA,KAAK,EAAE,iBAAiB;AACxB,wBAAA,SAAS,EAAE,QAAQ;AACnB,wBAAA,wBAAwB,EAAE,mCAAmC;AAC7D,wBAAA,iBAAiB,EAAE,0DAA0D;AAC7E,wBAAA,0BAA0B,EAAE,gDAAgD;AAC/E,qBAAA;AACJ,iBAAA;;;MCrCY,OAAO,GAAG,CAAC,gBAAgB,EAAE,gBAAgB;;ACH1D;;ACAA;;AAEG;;;;"}
@@ -1,115 +1,54 @@
1
1
  import * as i0 from '@angular/core';
2
- import { signal, inject, EventEmitter, computed, isSignal, ViewChild, Input, Output, forwardRef, ViewChildren, ChangeDetectionStrategy, Component } from '@angular/core';
3
- import { TuiElement } from '@taiga-ui/cdk/directives/element';
2
+ import { inject, viewChild, computed, input, output, ChangeDetectionStrategy, Component } from '@angular/core';
4
3
  import * as i1 from '@taiga-ui/core/components/data-list';
5
- import { tuiInjectDataListSize, TuiDataListComponent, TuiOption, TuiOptionWithValue, tuiAsDataListAccessor, TuiDataList, TuiDataListDirective } from '@taiga-ui/core/components/data-list';
4
+ import { TuiDataListComponent, tuiInjectDataListSize, TuiDataList } from '@taiga-ui/core/components/data-list';
6
5
  import { TuiLoader } from '@taiga-ui/core/components/loader';
7
- import { TuiMultiSelectGroupDirective, TuiMultiSelectGroupComponent } from '@taiga-ui/kit/components/multi-select';
6
+ import { tuiAsAuxiliary } from '@taiga-ui/core/tokens';
7
+ import * as i2 from '@taiga-ui/kit/components/multi-select';
8
+ import { TuiMultiSelectGroupDirective, TuiMultiSelect } from '@taiga-ui/kit/components/multi-select';
8
9
  import { PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
9
- import { EMPTY_QUERY } from '@taiga-ui/cdk/constants';
10
- import { tuiInjectElement } from '@taiga-ui/cdk/utils/dom';
11
- import { tuiIsFocused } from '@taiga-ui/cdk/utils/focus';
12
- import { tuiIsPresent } from '@taiga-ui/cdk/utils/miscellaneous';
13
10
  import { TUI_ITEMS_HANDLERS } from '@taiga-ui/core/directives/items-handlers';
14
- import { TUI_ITEMS_HANDLERS as TUI_ITEMS_HANDLERS$1 } from '@taiga-ui/kit/tokens';
15
11
 
16
12
  class TuiDataListWrapperComponent {
17
13
  constructor() {
18
- this.datalist = signal(null);
19
- this.itemsHandlers = inject(TUI_ITEMS_HANDLERS);
20
- // TODO(v5): delete
21
- this.itemsHandlersLegacy = inject(TUI_ITEMS_HANDLERS$1);
22
- // TODO(v5): delete
23
- this.legacyOptionsQuery = EMPTY_QUERY;
24
- // TODO(v5): delete
25
- this.optionsQuery = EMPTY_QUERY;
26
- this.newOptionMode = tuiInjectElement().hasAttribute('new');
27
- this.items = [];
28
- this.disabledItemHandler = this.newOptionMode
29
- ? this.itemsHandlers?.disabledItemHandler()
30
- : this.itemsHandlersLegacy.disabledItemHandler;
31
- this.size = tuiInjectDataListSize();
32
- this.itemClick = new EventEmitter();
14
+ this.handlers = inject(TUI_ITEMS_HANDLERS);
15
+ this.datalist = viewChild((TuiDataListComponent));
16
+ this.content = computed(() => this.itemContent() ?? (({ $implicit }) => this.handlers.stringify()($implicit)));
33
17
  this.options = computed(() => this.datalist()?.options() ?? []);
34
- this.itemContent = ({ $implicit }) => this.newOptionMode
35
- ? this.itemsHandlers.stringify()($implicit)
36
- : this.itemsHandlersLegacy.stringify($implicit);
37
- }
38
- getContext($implicit, { nativeElement }) {
39
- return { $implicit, active: tuiIsFocused(nativeElement) };
40
- }
41
- // TODO(v5): delete
42
- getOptions(includeDisabled = false) {
43
- return [
44
- ...this.legacyOptionsQuery, // TODO(v5): delete
45
- ...this.optionsQuery,
46
- ]
47
- .filter(({ disabled }) => includeDisabled || !disabled)
48
- .map(({ value }) => (isSignal(value) ? value() : value))
49
- .filter(tuiIsPresent);
50
- }
51
- // TODO(v5): use signal `viewChild`
52
- set datalistSetter(x) {
53
- this.datalist.set(x);
18
+ this.items = input([]);
19
+ this.emptyContent = input();
20
+ this.size = input(tuiInjectDataListSize());
21
+ this.itemContent = input();
22
+ this.itemClick = output();
54
23
  }
55
24
  $cast(items) {
56
25
  return items;
57
26
  }
58
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDataListWrapperComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
59
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiDataListWrapperComponent, isStandalone: true, selector: "tui-data-list-wrapper:not([labels]), tui-data-list-wrapper:not([labels])[new]", inputs: { items: "items", disabledItemHandler: "disabledItemHandler", emptyContent: "emptyContent", size: "size", itemContent: "itemContent" }, outputs: { itemClick: "itemClick" }, providers: [tuiAsDataListAccessor(TuiDataListWrapperComponent)], viewQueries: [{ propertyName: "datalistSetter", first: true, predicate: TuiDataListComponent, descendants: true }, { propertyName: "legacyOptionsQuery", predicate: i0.forwardRef(() => TuiOption), descendants: true }, { propertyName: "optionsQuery", predicate: i0.forwardRef(() => TuiOptionWithValue), descendants: true }], ngImport: i0, template: "@if (items) {\n <tui-data-list\n [emptyContent]=\"emptyContent\"\n [size]=\"size\"\n >\n @if (newOptionMode) {\n @for (item of $cast(items); track item) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\">\n {{ text }}\n </ng-container>\n </button>\n }\n } @else {\n @for (item of $cast(items); track item) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <span class=\"t-content\">\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\">\n {{ text }}\n </ng-container>\n </span>\n </button>\n }\n }\n <!-- TODO(v5): delete fallback -->\n </tui-data-list>\n} @else {\n <tui-loader\n automation-id=\"tui-data-list-wrapper__loader\"\n class=\"t-loader\"\n />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i1.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "component", type: i1.TuiOption, selector: "button[tuiOption]:not([new]), a[tuiOption]:not([new]), label[tuiOption]:not([new])", inputs: ["disabled", "value"] }, { kind: "directive", type: i1.TuiOptionNew, selector: "button[tuiOption][new], a[tuiOption][new], label[tuiOption][new]", inputs: ["disabled"] }, { kind: "directive", type: i1.TuiOptionWithValue, selector: "button[tuiOption][value][new], a[tuiOption][value][new], label[tuiOption][value][new]", inputs: ["disabled", "value"] }, { kind: "directive", type: TuiElement, selector: "[tuiElement]", exportAs: ["elementRef"] }, { kind: "component", type: TuiLoader, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "loading"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
27
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiDataListWrapperComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
28
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiDataListWrapperComponent, isStandalone: true, selector: "tui-data-list-wrapper:not([labels])", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, emptyContent: { classPropertyName: "emptyContent", publicName: "emptyContent", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, itemContent: { classPropertyName: "itemContent", publicName: "itemContent", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { itemClick: "itemClick" }, providers: [tuiAsAuxiliary(TuiDataListWrapperComponent)], viewQueries: [{ propertyName: "datalist", first: true, predicate: (TuiDataListComponent), descendants: true, isSignal: true }], ngImport: i0, template: "@if (items()) {\n <tui-data-list\n [emptyContent]=\"emptyContent()\"\n [size]=\"size()\"\n >\n @for (item of $cast(items()); track item) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i1.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "directive", type: i1.TuiOption, selector: "button[tuiOption], a[tuiOption], label[tuiOption]", inputs: ["disabled"] }, { kind: "directive", type: i1.TuiOptionWithValue, selector: "button[tuiOption][value], a[tuiOption][value], label[tuiOption][value]", inputs: ["disabled", "value"] }, { kind: "component", type: TuiLoader, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "loading"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
60
29
  }
61
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDataListWrapperComponent, decorators: [{
30
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiDataListWrapperComponent, decorators: [{
62
31
  type: Component,
63
- args: [{ selector: 'tui-data-list-wrapper:not([labels]), tui-data-list-wrapper:not([labels])[new]', imports: [PolymorpheusOutlet, TuiDataList, TuiElement, TuiLoader], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiAsDataListAccessor(TuiDataListWrapperComponent)], template: "@if (items) {\n <tui-data-list\n [emptyContent]=\"emptyContent\"\n [size]=\"size\"\n >\n @if (newOptionMode) {\n @for (item of $cast(items); track item) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\">\n {{ text }}\n </ng-container>\n </button>\n }\n } @else {\n @for (item of $cast(items); track item) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <span class=\"t-content\">\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\">\n {{ text }}\n </ng-container>\n </span>\n </button>\n }\n }\n <!-- TODO(v5): delete fallback -->\n </tui-data-list>\n} @else {\n <tui-loader\n automation-id=\"tui-data-list-wrapper__loader\"\n class=\"t-loader\"\n />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"] }]
64
- }], propDecorators: { legacyOptionsQuery: [{
65
- type: ViewChildren,
66
- args: [forwardRef(() => TuiOption)]
67
- }], optionsQuery: [{
68
- type: ViewChildren,
69
- args: [forwardRef(() => TuiOptionWithValue)]
70
- }], items: [{
71
- type: Input
72
- }], disabledItemHandler: [{
73
- type: Input
74
- }], emptyContent: [{
75
- type: Input
76
- }], size: [{
77
- type: Input
78
- }], itemClick: [{
79
- type: Output
80
- }], itemContent: [{
81
- type: Input
82
- }], datalistSetter: [{
83
- type: ViewChild,
84
- args: [TuiDataListComponent]
85
- }] } });
32
+ args: [{ selector: 'tui-data-list-wrapper:not([labels])', imports: [PolymorpheusOutlet, TuiDataList, TuiLoader], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiAsAuxiliary(TuiDataListWrapperComponent)], template: "@if (items()) {\n <tui-data-list\n [emptyContent]=\"emptyContent()\"\n [size]=\"size()\"\n >\n @for (item of $cast(items()); track item) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"] }]
33
+ }] });
86
34
 
87
35
  class TuiDataListGroupWrapperComponent extends TuiDataListWrapperComponent {
88
36
  constructor() {
89
37
  super(...arguments);
90
38
  this.multi = inject(TuiMultiSelectGroupDirective, { optional: true });
91
- this.labels = [];
39
+ this.labels = input([]);
92
40
  }
93
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDataListGroupWrapperComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
94
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiDataListGroupWrapperComponent, isStandalone: true, selector: "tui-data-list-wrapper[labels]", inputs: { labels: "labels" }, providers: [tuiAsDataListAccessor(TuiDataListGroupWrapperComponent)], usesInheritance: true, ngImport: i0, template: "@if (items) {\n <tui-data-list\n [emptyContent]=\"emptyContent\"\n [size]=\"size\"\n >\n @for (group of items; track group) {\n @if (multi) {\n <tui-opt-group\n tuiMultiSelectGroup\n [label]=\"labels[$index] || ''\"\n >\n @if (newOptionMode) {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n <!-- TODO(v5): delete fallback -->\n } @else {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n }\n </tui-opt-group>\n } @else {\n <tui-opt-group [label]=\"labels[$index]\">\n @if (newOptionMode) {\n @for (item of group; track item) {\n <button\n #elementRef=\"elementRef\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n <!-- TODO(v5): delete fallback -->\n } @else {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n }\n </tui-opt-group>\n }\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i1.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "component", type: i1.TuiOption, selector: "button[tuiOption]:not([new]), a[tuiOption]:not([new]), label[tuiOption]:not([new])", inputs: ["disabled", "value"] }, { kind: "directive", type: i1.TuiOptionNew, selector: "button[tuiOption][new], a[tuiOption][new], label[tuiOption][new]", inputs: ["disabled"] }, { kind: "directive", type: i1.TuiOptionWithValue, selector: "button[tuiOption][value][new], a[tuiOption][value][new], label[tuiOption][value][new]", inputs: ["disabled", "value"] }, { kind: "directive", type: i1.TuiOptGroup, selector: "tui-opt-group", inputs: ["label"] }, { kind: "directive", type: TuiElement, selector: "[tuiElement]", exportAs: ["elementRef"] }, { kind: "component", type: TuiLoader, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "loading"] }, { kind: "component", type: TuiMultiSelectGroupComponent, selector: "tui-opt-group[tuiMultiSelectGroup]", inputs: ["label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
41
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiDataListGroupWrapperComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
42
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiDataListGroupWrapperComponent, isStandalone: true, selector: "tui-data-list-wrapper[labels]", inputs: { labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null } }, providers: [tuiAsAuxiliary(TuiDataListGroupWrapperComponent)], usesInheritance: true, ngImport: i0, template: "@if (items()) {\n <tui-data-list\n [emptyContent]=\"emptyContent()\"\n [size]=\"size()\"\n >\n @for (group of items(); track group) {\n @if (multi) {\n <tui-opt-group\n tuiMultiSelectGroup\n [label]=\"labels()[$index] || ''\"\n >\n @for (item of group; track $index) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-opt-group>\n } @else {\n <tui-opt-group [label]=\"labels()[$index]\">\n @for (item of group; track item) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-opt-group>\n }\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i1.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "directive", type: i1.TuiOption, selector: "button[tuiOption], a[tuiOption], label[tuiOption]", inputs: ["disabled"] }, { kind: "directive", type: i1.TuiOptionWithValue, selector: "button[tuiOption][value], a[tuiOption][value], label[tuiOption][value]", inputs: ["disabled", "value"] }, { kind: "directive", type: i1.TuiOptGroup, selector: "tui-opt-group", inputs: ["label"] }, { kind: "component", type: TuiLoader, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "loading"] }, { kind: "component", type: i2.TuiMultiSelectGroupComponent, selector: "tui-opt-group[tuiMultiSelectGroup]", inputs: ["label"] }, { kind: "directive", type: i2.TuiMultiSelectGroupDirective, selector: "[tuiMultiSelectGroup]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
95
43
  }
96
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDataListGroupWrapperComponent, decorators: [{
44
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiDataListGroupWrapperComponent, decorators: [{
97
45
  type: Component,
98
- args: [{ selector: 'tui-data-list-wrapper[labels]', imports: [
99
- PolymorpheusOutlet,
100
- TuiDataList,
101
- TuiElement,
102
- TuiLoader,
103
- TuiMultiSelectGroupComponent,
104
- ], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiAsDataListAccessor(TuiDataListGroupWrapperComponent)], template: "@if (items) {\n <tui-data-list\n [emptyContent]=\"emptyContent\"\n [size]=\"size\"\n >\n @for (group of items; track group) {\n @if (multi) {\n <tui-opt-group\n tuiMultiSelectGroup\n [label]=\"labels[$index] || ''\"\n >\n @if (newOptionMode) {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n <!-- TODO(v5): delete fallback -->\n } @else {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n }\n </tui-opt-group>\n } @else {\n <tui-opt-group [label]=\"labels[$index]\">\n @if (newOptionMode) {\n @for (item of group; track item) {\n <button\n #elementRef=\"elementRef\"\n new\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n <!-- TODO(v5): delete fallback -->\n } @else {\n @for (item of group; track $index) {\n <button\n #elementRef=\"elementRef\"\n automation-id=\"tui-data-list-wrapper__option\"\n tuiElement\n tuiOption\n type=\"button\"\n [disabled]=\"disabledItemHandler(item)\"\n [value]=\"item\"\n (click)=\"itemClick.emit(item)\"\n >\n <ng-container\n *polymorpheusOutlet=\"itemContent as text; context: getContext(item, elementRef)\"\n >\n {{ text }}\n </ng-container>\n </button>\n }\n }\n </tui-opt-group>\n }\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"] }]
105
- }], propDecorators: { labels: [{
106
- type: Input
107
- }] } });
46
+ args: [{ selector: 'tui-data-list-wrapper[labels]', imports: [PolymorpheusOutlet, TuiDataList, TuiLoader, TuiMultiSelect], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiAsAuxiliary(TuiDataListGroupWrapperComponent)], template: "@if (items()) {\n <tui-data-list\n [emptyContent]=\"emptyContent()\"\n [size]=\"size()\"\n >\n @for (group of items(); track group) {\n @if (multi) {\n <tui-opt-group\n tuiMultiSelectGroup\n [label]=\"labels()[$index] || ''\"\n >\n @for (item of group; track $index) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-opt-group>\n } @else {\n <tui-opt-group [label]=\"labels()[$index]\">\n @for (item of group; track item) {\n <button\n tuiOption\n type=\"button\"\n [disabled]=\"handlers.disabledItemHandler()(item)\"\n [value]=\"item\"\n (click.capture)=\"itemClick.emit(item)\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: item}\">\n {{ text }}\n </ng-container>\n </button>\n }\n </tui-opt-group>\n }\n }\n </tui-data-list>\n} @else {\n <tui-loader class=\"t-loader\" />\n}\n", styles: [":host{display:block}.t-content{flex:1;min-inline-size:0}.t-loader{margin:.75rem 0}\n"] }]
47
+ }] });
108
48
 
109
49
  const TuiDataListWrapper = [
110
50
  TuiDataListWrapperComponent,
111
51
  TuiDataListGroupWrapperComponent,
112
- TuiDataListDirective,
113
52
  ];
114
53
 
115
54
  /**