@taiga-ui/kit 5.0.0-canary.cf66fed → 5.0.0-canary.d205016

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 (312) hide show
  1. package/components/accordion/accordion.component.d.ts +4 -1
  2. package/components/accordion/accordion.directive.d.ts +1 -0
  3. package/components/calendar-month/calendar-month.component.d.ts +11 -18
  4. package/components/calendar-range/calendar-range.component.d.ts +17 -22
  5. package/components/combo-box/combo-box.directive.d.ts +1 -0
  6. package/components/copy/button-copy.component.d.ts +17 -0
  7. package/components/copy/copy.component.d.ts +3 -1
  8. package/components/copy/copy.d.ts +2 -1
  9. package/components/copy/copy.directive.d.ts +5 -2
  10. package/components/copy/copy.options.d.ts +8 -4
  11. package/components/copy/index.d.ts +1 -0
  12. package/components/counter/counter.component.d.ts +17 -0
  13. package/components/counter/counter.options.d.ts +14 -0
  14. package/components/counter/index.d.ts +2 -0
  15. package/components/files/input-files/input-files.component.d.ts +4 -1
  16. package/components/filter/filter.component.d.ts +1 -1
  17. package/components/index.d.ts +3 -4
  18. package/components/input-chip/input-chip.component.d.ts +5 -0
  19. package/components/input-chip/input-chip.directive.d.ts +1 -1
  20. package/components/input-date/input-date.directive.d.ts +3 -2
  21. package/components/input-date/input-date.options.d.ts +2 -4
  22. package/components/input-date-multi/input-date-multi.directive.d.ts +1 -1
  23. package/components/input-date-time/input-date-time.component.d.ts +2 -2
  24. package/components/input-month/input-month.directive.d.ts +1 -1
  25. package/components/input-month/input-month.options.d.ts +1 -7
  26. package/components/input-month-range/input-month-range.directive.d.ts +1 -1
  27. package/components/input-month-range/input-month-range.options.d.ts +1 -3
  28. package/components/input-number/index.d.ts +1 -0
  29. package/components/input-number/input-number.directive.d.ts +1 -0
  30. package/components/input-number/number-mask.directive.d.ts +1 -1
  31. package/components/input-number/step/input-number-step.component.d.ts +3 -5
  32. package/components/input-number/step/input-number-step.service.d.ts +12 -0
  33. package/components/input-phone/input-phone.directive.d.ts +1 -1
  34. package/components/input-range/input-range.component.d.ts +1 -1
  35. package/components/input-slider/input-slider.d.ts +1 -1
  36. package/components/input-time/input-time.directive.d.ts +1 -1
  37. package/components/input-time/input-time.options.d.ts +1 -3
  38. package/components/input-year/input-year.directive.d.ts +1 -1
  39. package/components/line-clamp/line-clamp-box.component.d.ts +2 -0
  40. package/components/line-clamp/line-clamp.component.d.ts +5 -3
  41. package/components/multi-select/multi-select-group/multi-select-group.directive.d.ts +1 -0
  42. package/components/multi-select/multi-select-native/multi-select-native.component.d.ts +1 -1
  43. package/components/progress/progress-bar/progress-color-segments.directive.d.ts +2 -2
  44. package/components/radio-list/radio-list.component.d.ts +1 -5
  45. package/components/range/range.component.d.ts +2 -2
  46. package/components/select/native-select/native-select.component.d.ts +1 -1
  47. package/components/select/select-option/select-option.component.d.ts +1 -1
  48. package/components/shrink-wrap/index.d.ts +3 -0
  49. package/components/shrink-wrap/shrink-wrap.component.d.ts +5 -0
  50. package/components/shrink-wrap/shrink-wrap.d.ts +3 -0
  51. package/components/shrink-wrap/shrink-wrap.directive.d.ts +6 -0
  52. package/components/stepper/step.component.d.ts +1 -1
  53. package/components/switch/switch.component.d.ts +1 -1
  54. package/components/switch/switch.options.d.ts +1 -1
  55. package/components/tabs/tabs-with-more.component.d.ts +3 -3
  56. package/components/textarea/textarea.directive.d.ts +1 -1
  57. package/components/timeline/index.d.ts +3 -0
  58. package/components/timeline/timeline-item.component.d.ts +14 -0
  59. package/components/timeline/timeline.component.d.ts +16 -0
  60. package/components/timeline/timeline.d.ts +3 -0
  61. package/components/toast/toast.directive.d.ts +4 -1
  62. package/components/tree/components/tree/tree.component.d.ts +1 -3
  63. package/directives/password/password.options.d.ts +18 -5
  64. package/fesm2022/taiga-ui-kit-components-accordion.mjs +20 -10
  65. package/fesm2022/taiga-ui-kit-components-accordion.mjs.map +1 -1
  66. package/fesm2022/taiga-ui-kit-components-action-bar.mjs +5 -5
  67. package/fesm2022/taiga-ui-kit-components-action-bar.mjs.map +1 -1
  68. package/fesm2022/taiga-ui-kit-components-avatar.mjs +24 -23
  69. package/fesm2022/taiga-ui-kit-components-avatar.mjs.map +1 -1
  70. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs +4 -4
  71. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs.map +1 -1
  72. package/fesm2022/taiga-ui-kit-components-badge.mjs +8 -7
  73. package/fesm2022/taiga-ui-kit-components-badge.mjs.map +1 -1
  74. package/fesm2022/taiga-ui-kit-components-badged-content.mjs +7 -7
  75. package/fesm2022/taiga-ui-kit-components-badged-content.mjs.map +1 -1
  76. package/fesm2022/taiga-ui-kit-components-block.mjs +8 -7
  77. package/fesm2022/taiga-ui-kit-components-block.mjs.map +1 -1
  78. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +5 -5
  79. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs.map +1 -1
  80. package/fesm2022/taiga-ui-kit-components-button-loading.mjs +3 -3
  81. package/fesm2022/taiga-ui-kit-components-button-loading.mjs.map +1 -1
  82. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +36 -48
  83. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs.map +1 -1
  84. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +68 -100
  85. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
  86. package/fesm2022/taiga-ui-kit-components-chip.mjs +9 -8
  87. package/fesm2022/taiga-ui-kit-components-chip.mjs.map +1 -1
  88. package/fesm2022/taiga-ui-kit-components-combo-box.mjs +9 -5
  89. package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
  90. package/fesm2022/taiga-ui-kit-components-comment.mjs +12 -8
  91. package/fesm2022/taiga-ui-kit-components-comment.mjs.map +1 -1
  92. package/fesm2022/taiga-ui-kit-components-compass.mjs +8 -4
  93. package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
  94. package/fesm2022/taiga-ui-kit-components-confirm.mjs +7 -7
  95. package/fesm2022/taiga-ui-kit-components-confirm.mjs.map +1 -1
  96. package/fesm2022/taiga-ui-kit-components-copy.mjs +93 -28
  97. package/fesm2022/taiga-ui-kit-components-copy.mjs.map +1 -1
  98. package/fesm2022/taiga-ui-kit-components-counter.mjs +66 -0
  99. package/fesm2022/taiga-ui-kit-components-counter.mjs.map +1 -0
  100. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +7 -7
  101. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs.map +1 -1
  102. package/fesm2022/taiga-ui-kit-components-drawer.mjs +4 -4
  103. package/fesm2022/taiga-ui-kit-components-drawer.mjs.map +1 -1
  104. package/fesm2022/taiga-ui-kit-components-files.mjs +37 -30
  105. package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
  106. package/fesm2022/taiga-ui-kit-components-filter.mjs +5 -4
  107. package/fesm2022/taiga-ui-kit-components-filter.mjs.map +1 -1
  108. package/fesm2022/taiga-ui-kit-components-fullscreen.mjs +3 -3
  109. package/fesm2022/taiga-ui-kit-components-fullscreen.mjs.map +1 -1
  110. package/fesm2022/taiga-ui-kit-components-input-chip.mjs +21 -15
  111. package/fesm2022/taiga-ui-kit-components-input-chip.mjs.map +1 -1
  112. package/fesm2022/taiga-ui-kit-components-input-color.mjs +8 -7
  113. package/fesm2022/taiga-ui-kit-components-input-color.mjs.map +1 -1
  114. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +11 -11
  115. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs.map +1 -1
  116. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs +6 -5
  117. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs.map +1 -1
  118. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +10 -8
  119. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs.map +1 -1
  120. package/fesm2022/taiga-ui-kit-components-input-date.mjs +35 -24
  121. package/fesm2022/taiga-ui-kit-components-input-date.mjs.map +1 -1
  122. package/fesm2022/taiga-ui-kit-components-input-inline.mjs +5 -4
  123. package/fesm2022/taiga-ui-kit-components-input-inline.mjs.map +1 -1
  124. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +10 -6
  125. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
  126. package/fesm2022/taiga-ui-kit-components-input-month.mjs +17 -20
  127. package/fesm2022/taiga-ui-kit-components-input-month.mjs.map +1 -1
  128. package/fesm2022/taiga-ui-kit-components-input-number.mjs +83 -56
  129. package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
  130. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +5 -5
  131. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
  132. package/fesm2022/taiga-ui-kit-components-input-phone.mjs +6 -6
  133. package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
  134. package/fesm2022/taiga-ui-kit-components-input-pin.mjs +4 -4
  135. package/fesm2022/taiga-ui-kit-components-input-pin.mjs.map +1 -1
  136. package/fesm2022/taiga-ui-kit-components-input-range.mjs +4 -4
  137. package/fesm2022/taiga-ui-kit-components-input-range.mjs.map +1 -1
  138. package/fesm2022/taiga-ui-kit-components-input-slider.mjs +9 -8
  139. package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
  140. package/fesm2022/taiga-ui-kit-components-input-time.mjs +15 -13
  141. package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
  142. package/fesm2022/taiga-ui-kit-components-input-year.mjs +11 -9
  143. package/fesm2022/taiga-ui-kit-components-input-year.mjs.map +1 -1
  144. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +14 -14
  145. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs.map +1 -1
  146. package/fesm2022/taiga-ui-kit-components-like.mjs +6 -5
  147. package/fesm2022/taiga-ui-kit-components-like.mjs.map +1 -1
  148. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +24 -13
  149. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs.map +1 -1
  150. package/fesm2022/taiga-ui-kit-components-message.mjs +8 -7
  151. package/fesm2022/taiga-ui-kit-components-message.mjs.map +1 -1
  152. package/fesm2022/taiga-ui-kit-components-multi-select.mjs +27 -20
  153. package/fesm2022/taiga-ui-kit-components-multi-select.mjs.map +1 -1
  154. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +11 -11
  155. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs.map +1 -1
  156. package/fesm2022/taiga-ui-kit-components-pager.mjs +3 -3
  157. package/fesm2022/taiga-ui-kit-components-pager.mjs.map +1 -1
  158. package/fesm2022/taiga-ui-kit-components-pagination.mjs +4 -4
  159. package/fesm2022/taiga-ui-kit-components-pagination.mjs.map +1 -1
  160. package/fesm2022/taiga-ui-kit-components-pin.mjs +9 -7
  161. package/fesm2022/taiga-ui-kit-components-pin.mjs.map +1 -1
  162. package/fesm2022/taiga-ui-kit-components-preview.mjs +37 -34
  163. package/fesm2022/taiga-ui-kit-components-preview.mjs.map +1 -1
  164. package/fesm2022/taiga-ui-kit-components-progress.mjs +38 -49
  165. package/fesm2022/taiga-ui-kit-components-progress.mjs.map +1 -1
  166. package/fesm2022/taiga-ui-kit-components-pulse.mjs +3 -3
  167. package/fesm2022/taiga-ui-kit-components-pulse.mjs.map +1 -1
  168. package/fesm2022/taiga-ui-kit-components-push.mjs +15 -14
  169. package/fesm2022/taiga-ui-kit-components-push.mjs.map +1 -1
  170. package/fesm2022/taiga-ui-kit-components-radio-list.mjs +9 -7
  171. package/fesm2022/taiga-ui-kit-components-radio-list.mjs.map +1 -1
  172. package/fesm2022/taiga-ui-kit-components-range.mjs +24 -23
  173. package/fesm2022/taiga-ui-kit-components-range.mjs.map +1 -1
  174. package/fesm2022/taiga-ui-kit-components-rating.mjs +4 -4
  175. package/fesm2022/taiga-ui-kit-components-rating.mjs.map +1 -1
  176. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs +3 -3
  177. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs.map +1 -1
  178. package/fesm2022/taiga-ui-kit-components-segmented.mjs +10 -9
  179. package/fesm2022/taiga-ui-kit-components-segmented.mjs.map +1 -1
  180. package/fesm2022/taiga-ui-kit-components-select.mjs +21 -23
  181. package/fesm2022/taiga-ui-kit-components-select.mjs.map +1 -1
  182. package/fesm2022/taiga-ui-kit-components-shrink-wrap.mjs +40 -0
  183. package/fesm2022/taiga-ui-kit-components-shrink-wrap.mjs.map +1 -0
  184. package/fesm2022/taiga-ui-kit-components-status.mjs +9 -7
  185. package/fesm2022/taiga-ui-kit-components-status.mjs.map +1 -1
  186. package/fesm2022/taiga-ui-kit-components-stepper.mjs +8 -8
  187. package/fesm2022/taiga-ui-kit-components-stepper.mjs.map +1 -1
  188. package/fesm2022/taiga-ui-kit-components-switch.mjs +6 -5
  189. package/fesm2022/taiga-ui-kit-components-switch.mjs.map +1 -1
  190. package/fesm2022/taiga-ui-kit-components-tabs.mjs +40 -35
  191. package/fesm2022/taiga-ui-kit-components-tabs.mjs.map +1 -1
  192. package/fesm2022/taiga-ui-kit-components-textarea.mjs +17 -16
  193. package/fesm2022/taiga-ui-kit-components-textarea.mjs.map +1 -1
  194. package/fesm2022/taiga-ui-kit-components-tiles.mjs +16 -14
  195. package/fesm2022/taiga-ui-kit-components-tiles.mjs.map +1 -1
  196. package/fesm2022/taiga-ui-kit-components-timeline.mjs +68 -0
  197. package/fesm2022/taiga-ui-kit-components-timeline.mjs.map +1 -0
  198. package/fesm2022/taiga-ui-kit-components-toast.mjs +29 -24
  199. package/fesm2022/taiga-ui-kit-components-toast.mjs.map +1 -1
  200. package/fesm2022/taiga-ui-kit-components-tree.mjs +24 -24
  201. package/fesm2022/taiga-ui-kit-components-tree.mjs.map +1 -1
  202. package/fesm2022/taiga-ui-kit-components.mjs +3 -4
  203. package/fesm2022/taiga-ui-kit-components.mjs.map +1 -1
  204. package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs +3 -3
  205. package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs.map +1 -1
  206. package/fesm2022/taiga-ui-kit-directives-button-group.mjs +12 -8
  207. package/fesm2022/taiga-ui-kit-directives-button-group.mjs.map +1 -1
  208. package/fesm2022/taiga-ui-kit-directives-button-select.mjs +3 -3
  209. package/fesm2022/taiga-ui-kit-directives-button-select.mjs.map +1 -1
  210. package/fesm2022/taiga-ui-kit-directives-chevron.mjs +8 -7
  211. package/fesm2022/taiga-ui-kit-directives-chevron.mjs.map +1 -1
  212. package/fesm2022/taiga-ui-kit-directives-connected.mjs +12 -8
  213. package/fesm2022/taiga-ui-kit-directives-connected.mjs.map +1 -1
  214. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs +3 -3
  215. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs.map +1 -1
  216. package/fesm2022/taiga-ui-kit-directives-fade.mjs +9 -7
  217. package/fesm2022/taiga-ui-kit-directives-fade.mjs.map +1 -1
  218. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs +4 -4
  219. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs.map +1 -1
  220. package/fesm2022/taiga-ui-kit-directives-highlight.mjs +3 -3
  221. package/fesm2022/taiga-ui-kit-directives-highlight.mjs.map +1 -1
  222. package/fesm2022/taiga-ui-kit-directives-password.mjs +4 -10
  223. package/fesm2022/taiga-ui-kit-directives-password.mjs.map +1 -1
  224. package/fesm2022/taiga-ui-kit-directives-present.mjs +3 -3
  225. package/fesm2022/taiga-ui-kit-directives-present.mjs.map +1 -1
  226. package/fesm2022/taiga-ui-kit-directives-sensitive.mjs +9 -7
  227. package/fesm2022/taiga-ui-kit-directives-sensitive.mjs.map +1 -1
  228. package/fesm2022/taiga-ui-kit-directives-shimmer.mjs +8 -7
  229. package/fesm2022/taiga-ui-kit-directives-shimmer.mjs.map +1 -1
  230. package/fesm2022/taiga-ui-kit-directives-skeleton.mjs +8 -8
  231. package/fesm2022/taiga-ui-kit-directives-skeleton.mjs.map +1 -1
  232. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +8 -7
  233. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs.map +1 -1
  234. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +3 -3
  235. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs.map +1 -1
  236. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs +3 -3
  237. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs.map +1 -1
  238. package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs +3 -3
  239. package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs.map +1 -1
  240. package/fesm2022/taiga-ui-kit-pipes-emails.mjs +3 -3
  241. package/fesm2022/taiga-ui-kit-pipes-emails.mjs.map +1 -1
  242. package/fesm2022/taiga-ui-kit-pipes-flag.mjs +3 -3
  243. package/fesm2022/taiga-ui-kit-pipes-flag.mjs.map +1 -1
  244. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs +4 -4
  245. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs.map +1 -1
  246. package/fesm2022/taiga-ui-kit-pipes-initials.mjs +3 -3
  247. package/fesm2022/taiga-ui-kit-pipes-initials.mjs.map +1 -1
  248. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +3 -3
  249. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs.map +1 -1
  250. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs +3 -3
  251. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs.map +1 -1
  252. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs +3 -3
  253. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs.map +1 -1
  254. package/fesm2022/taiga-ui-kit-pipes.mjs +0 -1
  255. package/fesm2022/taiga-ui-kit-pipes.mjs.map +1 -1
  256. package/fesm2022/taiga-ui-kit-tokens.mjs.map +1 -1
  257. package/fesm2022/taiga-ui-kit-utils.mjs +1 -5
  258. package/fesm2022/taiga-ui-kit-utils.mjs.map +1 -1
  259. package/package.json +64 -59
  260. package/pipes/index.d.ts +0 -1
  261. package/tokens/i18n.d.ts +0 -1
  262. package/utils/index.d.ts +0 -1
  263. package/components/carousel/carousel-autoscroll.directive.d.ts +0 -6
  264. package/components/carousel/carousel-buttons.directive.d.ts +0 -5
  265. package/components/carousel/carousel-scroll.directive.d.ts +0 -7
  266. package/components/carousel/carousel.component.d.ts +0 -34
  267. package/components/carousel/carousel.d.ts +0 -7
  268. package/components/carousel/carousel.directive.d.ts +0 -16
  269. package/components/carousel/index.d.ts +0 -6
  270. package/components/checkbox/checkbox.component.d.ts +0 -10
  271. package/components/checkbox/checkbox.options.d.ts +0 -10
  272. package/components/checkbox/index.d.ts +0 -2
  273. package/components/radio/index.d.ts +0 -4
  274. package/components/radio/radio.component.d.ts +0 -18
  275. package/components/radio/radio.d.ts +0 -3
  276. package/components/radio/radio.directive.d.ts +0 -8
  277. package/components/radio/radio.options.d.ts +0 -7
  278. package/components/slider/helpers/key-steps.d.ts +0 -27
  279. package/components/slider/helpers/slider-key-steps.directive.d.ts +0 -32
  280. package/components/slider/helpers/slider-readonly.directive.d.ts +0 -15
  281. package/components/slider/helpers/slider-thumb-label.component.d.ts +0 -13
  282. package/components/slider/index.d.ts +0 -6
  283. package/components/slider/slider.component.d.ts +0 -22
  284. package/components/slider/slider.d.ts +0 -5
  285. package/fesm2022/taiga-ui-kit-components-carousel.mjs +0 -211
  286. package/fesm2022/taiga-ui-kit-components-carousel.mjs.map +0 -1
  287. package/fesm2022/taiga-ui-kit-components-checkbox.mjs +0 -36
  288. package/fesm2022/taiga-ui-kit-components-checkbox.mjs.map +0 -1
  289. package/fesm2022/taiga-ui-kit-components-radio.mjs +0 -91
  290. package/fesm2022/taiga-ui-kit-components-radio.mjs.map +0 -1
  291. package/fesm2022/taiga-ui-kit-components-slider.mjs +0 -337
  292. package/fesm2022/taiga-ui-kit-components-slider.mjs.map +0 -1
  293. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs +0 -60
  294. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs.map +0 -1
  295. package/pipes/filter-by-input/filter-by-input.pipe.d.ts +0 -21
  296. package/pipes/filter-by-input/index.d.ts +0 -1
  297. package/styles/components/avatar.less +0 -188
  298. package/styles/components/badge.less +0 -127
  299. package/styles/components/block.less +0 -118
  300. package/styles/components/checkbox.less +0 -84
  301. package/styles/components/chip.less +0 -139
  302. package/styles/components/comment.less +0 -64
  303. package/styles/components/compass.less +0 -49
  304. package/styles/components/like.less +0 -67
  305. package/styles/components/message.less +0 -33
  306. package/styles/components/pin.less +0 -164
  307. package/styles/components/progress-bar.less +0 -117
  308. package/styles/components/radio.less +0 -59
  309. package/styles/components/status.less +0 -40
  310. package/styles/components/switch.less +0 -103
  311. package/styles/components/toast.less +0 -44
  312. package/utils/is-flat.d.ts +0 -1
@@ -1,8 +0,0 @@
1
- import { type TuiIdentityMatcher } from '@taiga-ui/cdk/types';
2
- import * as i0 from "@angular/core";
3
- export declare class TuiRadioDirective<T> {
4
- readonly identityMatcher: import("@angular/core").InputSignal<TuiIdentityMatcher<T>>;
5
- constructor();
6
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiRadioDirective<any>, never>;
7
- static ɵdir: i0.ɵɵDirectiveDeclaration<TuiRadioDirective<any>, "input[type=\"radio\"][tuiRadio][identityMatcher]", never, { "identityMatcher": { "alias": "identityMatcher"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
8
- }
@@ -1,7 +0,0 @@
1
- import { type TuiStringHandler } from '@taiga-ui/cdk/types';
2
- import { type TuiSizeS } from '@taiga-ui/core/types';
3
- export interface TuiRadioOptions {
4
- readonly appearance: TuiStringHandler<HTMLInputElement>;
5
- readonly size: TuiSizeS;
6
- }
7
- export declare const TUI_RADIO_OPTIONS: import("@angular/core").InjectionToken<TuiRadioOptions>, tuiRadioOptionsProvider: (item: Partial<TuiRadioOptions> | (() => Partial<TuiRadioOptions>)) => import("@angular/core").FactoryProvider;
@@ -1,27 +0,0 @@
1
- import { type TuiValueTransformer } from '@taiga-ui/cdk/classes';
2
- /**
3
- * Used as a limit for eliminating JS issues with floating point math
4
- */
5
- export declare const TUI_FLOATING_PRECISION = 7;
6
- /**
7
- * Steps for splitting sliders into different linear dependencies.
8
- * Each element of the array has the form [percent, value]
9
- *
10
- * Thus, to set a field from 50,000 to 30,000,000 in steps:
11
- * 1) From 50 000 to 200 000 by 5000 per step (30 steps)
12
- * 2) From 200 000 to 1 000 000 by 50 000 per step (16 steps)
13
- * 3) From 1 000 000 to 30 000 000 by 500 000 per step (58 steps)
14
- *
15
- * You need to pass the following keyStep (where 104 = 30 + 16 + 58 is the total number of steps):
16
- * [
17
- * [0, 50_000],
18
- * [100 / 104 * 30, 200_000],
19
- * [100 / 104 * (30 + 16), 1_000_000],
20
- * [100, 30_000_000],
21
- * ];
22
- *
23
- */
24
- export type TuiKeySteps = [[0, number], ...Array<[number, number]>, [100, number]];
25
- export declare function tuiPercentageToKeyStepValue(valuePercentage: number, keySteps: TuiKeySteps): number;
26
- export declare function tuiKeyStepValueToPercentage(value: number, keySteps: TuiKeySteps): number;
27
- export declare function tuiCreateKeyStepsTransformer(keySteps: TuiKeySteps): TuiValueTransformer<number, number>;
@@ -1,32 +0,0 @@
1
- import { type OnInit } from '@angular/core';
2
- import { TuiControl, type TuiValueTransformer } from '@taiga-ui/cdk/classes';
3
- import { TuiSliderComponent } from '../slider.component';
4
- import { type TuiKeySteps } from './key-steps';
5
- import * as i0 from "@angular/core";
6
- export declare class TuiSliderKeyStepsBase implements OnInit {
7
- private readonly injector;
8
- private readonly control;
9
- protected readonly min: import("@angular/core").WritableSignal<number | undefined>;
10
- protected readonly max: import("@angular/core").WritableSignal<number | undefined>;
11
- protected readonly sync: import("@angular/core").EffectRef;
12
- slider: TuiSliderComponent;
13
- readonly step: import("@angular/core").InputSignal<number>;
14
- readonly keySteps: import("@angular/core").InputSignal<[[0, number], ...[number, number][], [100, number]] | undefined>;
15
- readonly transformer: import("@angular/core").WritableSignal<TuiValueTransformer<number, number> | undefined>;
16
- controlValue: import("@angular/core").Signal<number | undefined>;
17
- readonly totalSteps: import("@angular/core").Signal<number>;
18
- ngOnInit(): void;
19
- takeStep(coefficient: number): number;
20
- toSliderValue(fraction: number): number;
21
- setControlValue(controlValue: number): void;
22
- getControlValue(): number;
23
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiSliderKeyStepsBase, never>;
24
- static ɵdir: i0.ɵɵDirectiveDeclaration<TuiSliderKeyStepsBase, "input[tuiSlider][keySteps]", never, { "step": { "alias": "step"; "required": false; "isSignal": true; }; "keySteps": { "alias": "keySteps"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
25
- }
26
- export declare class TuiSliderKeySteps extends TuiControl<number> {
27
- protected readonly base: TuiSliderKeyStepsBase;
28
- set keySteps(steps: TuiKeySteps | null | undefined);
29
- protected setValue(sliderValue: number): void;
30
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiSliderKeySteps, never>;
31
- static ɵdir: i0.ɵɵDirectiveDeclaration<TuiSliderKeySteps, "input[tuiSlider][keySteps][ngModel],input[tuiSlider][keySteps][formControl],input[tuiSlider][keySteps][formControlName]", never, { "keySteps": { "alias": "keySteps"; "required": false; }; }, {}, never, never, true, never>;
32
- }
@@ -1,15 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- /**
3
- * Native <input type='range' readonly> doesn't work.
4
- * This directive imitates this native behaviour.
5
- */
6
- export declare class TuiSliderReadonly {
7
- private readonly el;
8
- private readonly doc;
9
- readonly readonly: import("@angular/core").InputSignalWithTransform<boolean, any>;
10
- constructor();
11
- protected preventEvent(event: Event): void;
12
- protected preventKeyboardInteraction(event: KeyboardEvent): void;
13
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiSliderReadonly, never>;
14
- static ɵdir: i0.ɵɵDirectiveDeclaration<TuiSliderReadonly, "input[tuiSlider][readonly]", never, { "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
15
- }
@@ -1,13 +0,0 @@
1
- import { type AfterContentInit } from '@angular/core';
2
- import { NgControl } from '@angular/forms';
3
- import { TuiSliderComponent } from '../slider.component';
4
- import * as i0 from "@angular/core";
5
- export declare class TuiSliderThumbLabel implements AfterContentInit {
6
- protected readonly slider: import("@angular/core").Signal<TuiSliderComponent | undefined>;
7
- protected readonly control: import("@angular/core").Signal<NgControl | undefined>;
8
- ngAfterContentInit(): void;
9
- protected get ratio(): number;
10
- protected get ghostStart(): number;
11
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiSliderThumbLabel, never>;
12
- static ɵcmp: i0.ɵɵComponentDeclaration<TuiSliderThumbLabel, "[tuiSliderThumbLabel]", never, {}, {}, ["slider", "control"], ["*", "input[type=range]"], true, never>;
13
- }
@@ -1,6 +0,0 @@
1
- export * from './helpers/key-steps';
2
- export * from './helpers/slider-key-steps.directive';
3
- export * from './helpers/slider-readonly.directive';
4
- export * from './helpers/slider-thumb-label.component';
5
- export * from './slider';
6
- export * from './slider.component';
@@ -1,22 +0,0 @@
1
- import { TuiSliderKeyStepsBase } from './helpers/slider-key-steps.directive';
2
- import * as i0 from "@angular/core";
3
- export declare class TuiSliderComponent {
4
- private readonly control;
5
- protected readonly ticksGradient: import("@angular/core").Signal<string>;
6
- readonly segments: import("@angular/core").InputSignalWithTransform<readonly number[], number | readonly number[]>;
7
- readonly el: HTMLInputElement;
8
- readonly keySteps: TuiSliderKeyStepsBase | null;
9
- constructor();
10
- get valueRatio(): number;
11
- get min(): number;
12
- set min(x: number);
13
- get max(): number;
14
- set max(x: number);
15
- get step(): number;
16
- set step(x: number);
17
- get value(): number;
18
- set value(newValue: number);
19
- protected getTicksGradient(segments: readonly number[]): string;
20
- static ɵfac: i0.ɵɵFactoryDeclaration<TuiSliderComponent, never>;
21
- static ɵcmp: i0.ɵɵComponentDeclaration<TuiSliderComponent, "input[type=range][tuiSlider]", never, { "segments": { "alias": "segments"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
22
- }
@@ -1,5 +0,0 @@
1
- import { TuiSliderKeySteps, TuiSliderKeyStepsBase } from './helpers/slider-key-steps.directive';
2
- import { TuiSliderReadonly } from './helpers/slider-readonly.directive';
3
- import { TuiSliderThumbLabel } from './helpers/slider-thumb-label.component';
4
- import { TuiSliderComponent } from './slider.component';
5
- export declare const TuiSlider: readonly [typeof TuiSliderComponent, typeof TuiSliderThumbLabel, typeof TuiSliderKeyStepsBase, typeof TuiSliderKeySteps, typeof TuiSliderReadonly];
@@ -1,211 +0,0 @@
1
- import { TuiItem } from '@taiga-ui/cdk/directives/item';
2
- import { isPlatformServer, NgTemplateOutlet } from '@angular/common';
3
- import * as i0 from '@angular/core';
4
- import { inject, PLATFORM_ID, NgZone, input, Directive, signal, computed, contentChildren, TemplateRef, effect, model, output, ChangeDetectionStrategy, Component } from '@angular/core';
5
- import * as i2 from '@ng-web-apis/intersection-observer';
6
- import { WaIntersectionObserver } from '@ng-web-apis/intersection-observer';
7
- import { WA_IS_MOBILE } from '@ng-web-apis/platform';
8
- import { TuiPan } from '@taiga-ui/cdk/directives/pan';
9
- import { TuiSwipe, TUI_SWIPE_OPTIONS } from '@taiga-ui/cdk/directives/swipe';
10
- import { tuiInjectElement } from '@taiga-ui/cdk/utils/dom';
11
- import { tuiClamp } from '@taiga-ui/cdk/utils/math';
12
- import { WA_PAGE_VISIBILITY } from '@ng-web-apis/common';
13
- import { TUI_FALSE_HANDLER, TUI_TRUE_HANDLER } from '@taiga-ui/cdk/constants';
14
- import { tuiTypedFromEvent, tuiIfMap, tuiZoneOptimized, tuiZonefreeScheduler } from '@taiga-ui/cdk/observables';
15
- import { Observable, Subject, merge, map, EMPTY, combineLatest, interval, filter, throttleTime, tap } from 'rxjs';
16
- import { outputFromObservable } from '@angular/core/rxjs-interop';
17
- import { tuiButtonOptionsProvider } from '@taiga-ui/core/components/button';
18
-
19
- class TuiCarouselDirective extends Observable {
20
- constructor() {
21
- super((subscriber) => this.output$.subscribe(subscriber));
22
- this.el = tuiInjectElement();
23
- this.platform = inject(PLATFORM_ID);
24
- this.visible$ = inject(WA_PAGE_VISIBILITY);
25
- this.zone = inject(NgZone);
26
- this.trigger$ = new Subject();
27
- this.running$ = merge(tuiTypedFromEvent(this.el, 'mouseenter').pipe(map(TUI_FALSE_HANDLER)), tuiTypedFromEvent(this.el, 'touchstart').pipe(map(TUI_FALSE_HANDLER)), tuiTypedFromEvent(this.el, 'touchend').pipe(map(TUI_TRUE_HANDLER)), tuiTypedFromEvent(this.el, 'mouseleave').pipe(map(TUI_TRUE_HANDLER)), this.visible$);
28
- this.duration = input(0);
29
- this.output$ = isPlatformServer(this.platform)
30
- ? EMPTY
31
- : combineLatest([
32
- this.trigger$.pipe(map(() => this.duration())),
33
- this.running$,
34
- ]).pipe(tuiIfMap(([duration]) => interval(duration).pipe(tuiZoneOptimized(this.zone)), (values) => values.every(Boolean)));
35
- }
36
- restart() {
37
- this.trigger$.next();
38
- }
39
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
40
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiCarouselDirective, isStandalone: true, inputs: { duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0 }); }
41
- }
42
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselDirective, decorators: [{
43
- type: Directive
44
- }], ctorParameters: () => [] });
45
-
46
- class TuiCarouselAutoscroll {
47
- constructor() {
48
- this.tuiCarouselAutoscroll = outputFromObservable(inject(TuiCarouselDirective));
49
- }
50
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselAutoscroll, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
51
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.18", type: TuiCarouselAutoscroll, isStandalone: true, selector: "[tuiCarouselAutoscroll]", outputs: { tuiCarouselAutoscroll: "tuiCarouselAutoscroll" }, ngImport: i0 }); }
52
- }
53
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselAutoscroll, decorators: [{
54
- type: Directive,
55
- args: [{ selector: '[tuiCarouselAutoscroll]' }]
56
- }] });
57
-
58
- class TuiCarouselScroll {
59
- constructor() {
60
- this.el = tuiInjectElement();
61
- this.tuiCarouselScroll = outputFromObservable(tuiTypedFromEvent(this.el, 'wheel').pipe(filter(({ deltaX }) => Math.abs(deltaX) > 20), throttleTime(500, tuiZonefreeScheduler()), map(({ deltaX }) => Math.sign(deltaX)), tap(() => {
62
- // So we always have space to scroll and overflow-behavior saves us from back nav
63
- this.el.scrollLeft = 10;
64
- })));
65
- }
66
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselScroll, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
67
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.18", type: TuiCarouselScroll, isStandalone: true, selector: "[tuiCarouselScroll]", outputs: { tuiCarouselScroll: "tuiCarouselScroll" }, ngImport: i0 }); }
68
- }
69
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselScroll, decorators: [{
70
- type: Directive,
71
- args: [{ selector: '[tuiCarouselScroll]' }]
72
- }] });
73
-
74
- class TuiCarouselComponent {
75
- constructor() {
76
- this.el = tuiInjectElement();
77
- this.isMobile = inject(WA_IS_MOBILE);
78
- this.directive = inject(TuiCarouselDirective);
79
- this.translate = signal(0);
80
- this.transitioned = signal(true);
81
- this.transform = computed(() => `translateX(${100 * this.x()}%)`);
82
- this.items = contentChildren(TuiItem, { read: TemplateRef });
83
- this.computedDraggable = computed(() => this.isMobile || this.draggable());
84
- this.computedTranslate = computed(() => -this.index() / this.itemsCount());
85
- this.x = computed(() => this.transitioned() ? this.computedTranslate() : this.translate());
86
- this.resetDuration = effect(() => {
87
- this.index();
88
- this.directive.restart();
89
- });
90
- this.draggable = input(false);
91
- this.itemsCount = input(1);
92
- this.index = model(0);
93
- this.shift = output();
94
- }
95
- next() {
96
- if (this.index() !== this.items().length - this.itemsCount()) {
97
- this.updateIndex(this.index() + 1);
98
- }
99
- }
100
- prev() {
101
- this.updateIndex(this.index() - 1);
102
- }
103
- onTransitioned(transitioned) {
104
- this.transitioned.set(transitioned);
105
- if (!transitioned) {
106
- this.translate.set(this.computedTranslate());
107
- }
108
- this.onShift();
109
- }
110
- isDisabled(index) {
111
- return index < this.index() || index >= this.index() + this.itemsCount();
112
- }
113
- onIntersection(ratio, index) {
114
- if (ratio && ratio >= 0.5 && !this.transitioned()) {
115
- this.updateIndex(this.index() < index ? index - this.itemsCount() + 1 : index);
116
- }
117
- }
118
- onScroll(delta) {
119
- if (!this.isMobile) {
120
- this.onSwipe(delta > 0 ? 'left' : 'right');
121
- }
122
- }
123
- onPan(x) {
124
- if (!this.computedDraggable()) {
125
- return;
126
- }
127
- const min = 1 - this.items().length / this.itemsCount();
128
- this.translate.set(tuiClamp(x / this.el.clientWidth + this.translate(), min, 0));
129
- this.onShift();
130
- }
131
- onSwipe(direction) {
132
- if (direction === 'left') {
133
- this.next();
134
- }
135
- else if (direction === 'right') {
136
- this.prev();
137
- }
138
- }
139
- onAutoscroll() {
140
- this.updateIndex(this.index() === this.items().length - 1 ? 0 : this.index() + 1);
141
- }
142
- onShift() {
143
- this.shift.emit(Math.abs((this.x() % 1) + 0.5) * 2);
144
- }
145
- updateIndex(index) {
146
- this.index.set(tuiClamp(index, 0, this.items().length - 1));
147
- }
148
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
149
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiCarouselComponent, isStandalone: true, selector: "tui-carousel", inputs: { draggable: { classPropertyName: "draggable", publicName: "draggable", isSignal: true, isRequired: false, transformFunction: null }, itemsCount: { classPropertyName: "itemsCount", publicName: "itemsCount", isSignal: true, isRequired: false, transformFunction: null }, index: { classPropertyName: "index", publicName: "index", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { index: "indexChange", shift: "shift" }, host: { listeners: { "touchstart": "onTransitioned(false)", "touchend": "onTransitioned(true)", "mousedown": "onTransitioned(false)", "document:mouseup.zoneless": "onTransitioned(true)" }, properties: { "class._transitioned": "transitioned()", "class._draggable": "draggable()" } }, providers: [{ provide: TUI_SWIPE_OPTIONS, useValue: { timeout: 200, threshold: 30 } }], queries: [{ propertyName: "items", predicate: TuiItem, read: TemplateRef, isSignal: true }], hostDirectives: [{ directive: TuiCarouselDirective, inputs: ["duration", "duration"] }], ngImport: i0, template: "<div\n class=\"t-scroller\"\n (tuiCarouselScroll)=\"onScroll($event)\"\n>\n <div\n waIntersectionObserver\n waIntersectionThreshold=\"0.5\"\n class=\"t-wrapper\"\n >\n <div\n class=\"t-items\"\n [style.transform]=\"transform()\"\n (tuiCarouselAutoscroll)=\"onAutoscroll()\"\n (tuiPan)=\"onPan($event[0])\"\n (tuiSwipe)=\"onSwipe($event.direction)\"\n >\n @for (item of items(); track $index) {\n <fieldset\n class=\"t-item\"\n [disabled]=\"isDisabled($index)\"\n [style.flex-basis.%]=\"100 / itemsCount()\"\n [style.max-width.%]=\"100 / itemsCount()\"\n [style.min-width.%]=\"100 / itemsCount()\"\n (waIntersectionObservee)=\"$event[0] && onIntersection($event[0].intersectionRatio, $index)\"\n >\n <ng-container [ngTemplateOutlet]=\"item\" />\n </fieldset>\n }\n </div>\n </div>\n</div>\n\n<ng-content />\n", styles: [":host{position:relative;display:block;overflow:hidden}:host._draggable{-webkit-user-select:none;user-select:none}:host._draggable:hover{cursor:grab}:host._draggable:active{cursor:grabbing}.t-items{display:flex}:host._transitioned .t-items{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out}::ng-deep [tuiCarouselButtons] [tuiIconButton]{border-radius:100%}.t-item{display:flex;flex-direction:column;justify-content:center;padding:var(--tui-carousel-padding, 0 1.25rem);flex:1;min-inline-size:100%;max-inline-size:100%;box-sizing:border-box;border:none;margin:0}.t-wrapper{position:sticky;left:0;right:0;min-inline-size:100%;overflow:hidden}.t-scroller{scrollbar-width:none;-ms-overflow-style:none;display:flex;overflow:auto;overscroll-behavior-x:none;touch-action:pan-y}.t-scroller::-webkit-scrollbar,.t-scroller::-webkit-scrollbar-thumb{display:none}.t-scroller:before,.t-scroller:after{content:\"\";display:block;min-inline-size:1rem}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: TuiCarouselAutoscroll, selector: "[tuiCarouselAutoscroll]", outputs: ["tuiCarouselAutoscroll"] }, { kind: "directive", type: TuiCarouselScroll, selector: "[tuiCarouselScroll]", outputs: ["tuiCarouselScroll"] }, { kind: "directive", type: TuiPan, selector: "[tuiPan]", outputs: ["tuiPan"] }, { kind: "directive", type: TuiSwipe, selector: "[tuiSwipe]", outputs: ["tuiSwipe"] }, { kind: "directive", type: i2.WaIntersectionObserverDirective, selector: "[waIntersectionObserver]", inputs: ["waIntersectionRootMargin", "waIntersectionThreshold"], exportAs: ["IntersectionObserver"] }, { kind: "directive", type: i2.WaIntersectionObservee, selector: "[waIntersectionObservee]", outputs: ["waIntersectionObservee"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
150
- }
151
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselComponent, decorators: [{
152
- type: Component,
153
- args: [{ selector: 'tui-carousel', imports: [
154
- NgTemplateOutlet,
155
- TuiCarouselAutoscroll,
156
- TuiCarouselScroll,
157
- TuiPan,
158
- TuiSwipe,
159
- WaIntersectionObserver,
160
- ], changeDetection: ChangeDetectionStrategy.OnPush, providers: [{ provide: TUI_SWIPE_OPTIONS, useValue: { timeout: 200, threshold: 30 } }], hostDirectives: [
161
- {
162
- directive: TuiCarouselDirective,
163
- inputs: ['duration'],
164
- },
165
- ], host: {
166
- '[class._transitioned]': 'transitioned()',
167
- '[class._draggable]': 'draggable()',
168
- '(touchstart)': 'onTransitioned(false)',
169
- '(touchend)': 'onTransitioned(true)',
170
- '(mousedown)': 'onTransitioned(false)',
171
- '(document:mouseup.zoneless)': 'onTransitioned(true)',
172
- }, template: "<div\n class=\"t-scroller\"\n (tuiCarouselScroll)=\"onScroll($event)\"\n>\n <div\n waIntersectionObserver\n waIntersectionThreshold=\"0.5\"\n class=\"t-wrapper\"\n >\n <div\n class=\"t-items\"\n [style.transform]=\"transform()\"\n (tuiCarouselAutoscroll)=\"onAutoscroll()\"\n (tuiPan)=\"onPan($event[0])\"\n (tuiSwipe)=\"onSwipe($event.direction)\"\n >\n @for (item of items(); track $index) {\n <fieldset\n class=\"t-item\"\n [disabled]=\"isDisabled($index)\"\n [style.flex-basis.%]=\"100 / itemsCount()\"\n [style.max-width.%]=\"100 / itemsCount()\"\n [style.min-width.%]=\"100 / itemsCount()\"\n (waIntersectionObservee)=\"$event[0] && onIntersection($event[0].intersectionRatio, $index)\"\n >\n <ng-container [ngTemplateOutlet]=\"item\" />\n </fieldset>\n }\n </div>\n </div>\n</div>\n\n<ng-content />\n", styles: [":host{position:relative;display:block;overflow:hidden}:host._draggable{-webkit-user-select:none;user-select:none}:host._draggable:hover{cursor:grab}:host._draggable:active{cursor:grabbing}.t-items{display:flex}:host._transitioned .t-items{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out}::ng-deep [tuiCarouselButtons] [tuiIconButton]{border-radius:100%}.t-item{display:flex;flex-direction:column;justify-content:center;padding:var(--tui-carousel-padding, 0 1.25rem);flex:1;min-inline-size:100%;max-inline-size:100%;box-sizing:border-box;border:none;margin:0}.t-wrapper{position:sticky;left:0;right:0;min-inline-size:100%;overflow:hidden}.t-scroller{scrollbar-width:none;-ms-overflow-style:none;display:flex;overflow:auto;overscroll-behavior-x:none;touch-action:pan-y}.t-scroller::-webkit-scrollbar,.t-scroller::-webkit-scrollbar-thumb{display:none}.t-scroller:before,.t-scroller:after{content:\"\";display:block;min-inline-size:1rem}\n"] }]
173
- }] });
174
-
175
- class TuiCarouselButtons {
176
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselButtons, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
177
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.18", type: TuiCarouselButtons, isStandalone: true, selector: "[tuiCarouselButtons]", providers: [
178
- tuiButtonOptionsProvider({
179
- appearance: 'secondary',
180
- size: 'm',
181
- }),
182
- ], ngImport: i0 }); }
183
- }
184
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCarouselButtons, decorators: [{
185
- type: Directive,
186
- args: [{
187
- selector: '[tuiCarouselButtons]',
188
- providers: [
189
- tuiButtonOptionsProvider({
190
- appearance: 'secondary',
191
- size: 'm',
192
- }),
193
- ],
194
- }]
195
- }] });
196
-
197
- const TuiCarousel = [
198
- TuiItem,
199
- TuiCarouselComponent,
200
- TuiCarouselDirective,
201
- TuiCarouselAutoscroll,
202
- TuiCarouselButtons,
203
- TuiCarouselScroll,
204
- ];
205
-
206
- /**
207
- * Generated bundle index. Do not edit.
208
- */
209
-
210
- export { TuiCarousel, TuiCarouselAutoscroll, TuiCarouselButtons, TuiCarouselComponent, TuiCarouselDirective, TuiCarouselScroll };
211
- //# sourceMappingURL=taiga-ui-kit-components-carousel.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-components-carousel.mjs","sources":["../../../projects/kit/components/carousel/carousel.directive.ts","../../../projects/kit/components/carousel/carousel-autoscroll.directive.ts","../../../projects/kit/components/carousel/carousel-scroll.directive.ts","../../../projects/kit/components/carousel/carousel.component.ts","../../../projects/kit/components/carousel/carousel.template.html","../../../projects/kit/components/carousel/carousel-buttons.directive.ts","../../../projects/kit/components/carousel/carousel.ts","../../../projects/kit/components/carousel/taiga-ui-kit-components-carousel.ts"],"sourcesContent":["import {isPlatformServer} from '@angular/common';\nimport {Directive, inject, input, NgZone, PLATFORM_ID} from '@angular/core';\nimport {WA_PAGE_VISIBILITY} from '@ng-web-apis/common';\nimport {TUI_FALSE_HANDLER, TUI_TRUE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {tuiIfMap, tuiTypedFromEvent, tuiZoneOptimized} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {combineLatest, EMPTY, interval, map, merge, Observable, Subject} from 'rxjs';\n\n@Directive()\nexport class TuiCarouselDirective extends Observable<unknown> {\n private readonly el = tuiInjectElement();\n private readonly platform = inject(PLATFORM_ID);\n private readonly visible$ = inject(WA_PAGE_VISIBILITY);\n private readonly zone = inject(NgZone);\n private readonly trigger$ = new Subject<void>();\n private readonly running$ = merge(\n tuiTypedFromEvent(this.el, 'mouseenter').pipe(map(TUI_FALSE_HANDLER)),\n tuiTypedFromEvent(this.el, 'touchstart').pipe(map(TUI_FALSE_HANDLER)),\n tuiTypedFromEvent(this.el, 'touchend').pipe(map(TUI_TRUE_HANDLER)),\n tuiTypedFromEvent(this.el, 'mouseleave').pipe(map(TUI_TRUE_HANDLER)),\n this.visible$,\n );\n\n public readonly duration = input(0);\n\n protected readonly output$ = isPlatformServer(this.platform)\n ? EMPTY\n : combineLatest([\n this.trigger$.pipe(map(() => this.duration())),\n this.running$,\n ]).pipe(\n tuiIfMap(\n ([duration]) => interval(duration).pipe(tuiZoneOptimized(this.zone)),\n (values) => values.every(Boolean),\n ),\n );\n\n constructor() {\n super((subscriber) => this.output$.subscribe(subscriber));\n }\n\n public restart(): void {\n this.trigger$.next();\n }\n}\n","import {Directive, inject} from '@angular/core';\nimport {outputFromObservable} from '@angular/core/rxjs-interop';\n\nimport {TuiCarouselDirective} from './carousel.directive';\n\n@Directive({selector: '[tuiCarouselAutoscroll]'})\nexport class TuiCarouselAutoscroll {\n public readonly tuiCarouselAutoscroll = outputFromObservable(\n inject(TuiCarouselDirective),\n );\n}\n","import {Directive} from '@angular/core';\nimport {outputFromObservable} from '@angular/core/rxjs-interop';\nimport {tuiTypedFromEvent, tuiZonefreeScheduler} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {filter, map, tap, throttleTime} from 'rxjs';\n\n@Directive({selector: '[tuiCarouselScroll]'})\nexport class TuiCarouselScroll {\n private readonly el = tuiInjectElement();\n\n public readonly tuiCarouselScroll = outputFromObservable(\n tuiTypedFromEvent(this.el, 'wheel').pipe(\n filter(({deltaX}) => Math.abs(deltaX) > 20),\n throttleTime(500, tuiZonefreeScheduler()),\n map(({deltaX}) => Math.sign(deltaX)),\n tap(() => {\n // So we always have space to scroll and overflow-behavior saves us from back nav\n this.el.scrollLeft = 10;\n }),\n ),\n );\n}\n","import {NgTemplateOutlet} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChildren,\n effect,\n inject,\n input,\n model,\n output,\n signal,\n TemplateRef,\n} from '@angular/core';\nimport {WaIntersectionObserver} from '@ng-web-apis/intersection-observer';\nimport {WA_IS_MOBILE} from '@ng-web-apis/platform';\nimport {TuiItem} from '@taiga-ui/cdk/directives/item';\nimport {TuiPan} from '@taiga-ui/cdk/directives/pan';\nimport {\n TUI_SWIPE_OPTIONS,\n TuiSwipe,\n type TuiSwipeDirection,\n} from '@taiga-ui/cdk/directives/swipe';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\n\nimport {TuiCarouselDirective} from './carousel.directive';\nimport {TuiCarouselAutoscroll} from './carousel-autoscroll.directive';\nimport {TuiCarouselScroll} from './carousel-scroll.directive';\n\n@Component({\n selector: 'tui-carousel',\n imports: [\n NgTemplateOutlet,\n TuiCarouselAutoscroll,\n TuiCarouselScroll,\n TuiPan,\n TuiSwipe,\n WaIntersectionObserver,\n ],\n templateUrl: './carousel.template.html',\n styleUrl: './carousel.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{provide: TUI_SWIPE_OPTIONS, useValue: {timeout: 200, threshold: 30}}],\n hostDirectives: [\n {\n directive: TuiCarouselDirective,\n inputs: ['duration'],\n },\n ],\n host: {\n '[class._transitioned]': 'transitioned()',\n '[class._draggable]': 'draggable()',\n '(touchstart)': 'onTransitioned(false)',\n '(touchend)': 'onTransitioned(true)',\n '(mousedown)': 'onTransitioned(false)',\n '(document:mouseup.zoneless)': 'onTransitioned(true)',\n },\n})\nexport class TuiCarouselComponent {\n private readonly el = tuiInjectElement();\n private readonly isMobile = inject(WA_IS_MOBILE);\n private readonly directive = inject(TuiCarouselDirective);\n private readonly translate = signal(0);\n\n protected readonly transitioned = signal(true);\n protected readonly transform = computed(() => `translateX(${100 * this.x()}%)`);\n protected readonly items = contentChildren(TuiItem, {read: TemplateRef});\n protected readonly computedDraggable = computed(\n () => this.isMobile || this.draggable(),\n );\n\n protected readonly computedTranslate = computed(\n () => -this.index() / this.itemsCount(),\n );\n\n protected readonly x = computed(() =>\n this.transitioned() ? this.computedTranslate() : this.translate(),\n );\n\n protected readonly resetDuration = effect(() => {\n this.index();\n this.directive.restart();\n });\n\n public readonly draggable = input(false);\n public readonly itemsCount = input(1);\n public readonly index = model(0);\n public readonly shift = output<number>();\n\n public next(): void {\n if (this.index() !== this.items().length - this.itemsCount()) {\n this.updateIndex(this.index() + 1);\n }\n }\n\n public prev(): void {\n this.updateIndex(this.index() - 1);\n }\n\n protected onTransitioned(transitioned: boolean): void {\n this.transitioned.set(transitioned);\n\n if (!transitioned) {\n this.translate.set(this.computedTranslate());\n }\n\n this.onShift();\n }\n\n protected isDisabled(index: number): boolean {\n return index < this.index() || index >= this.index() + this.itemsCount();\n }\n\n protected onIntersection(ratio: number, index: number): void {\n if (ratio && ratio >= 0.5 && !this.transitioned()) {\n this.updateIndex(\n this.index() < index ? index - this.itemsCount() + 1 : index,\n );\n }\n }\n\n protected onScroll(delta: number): void {\n if (!this.isMobile) {\n this.onSwipe(delta > 0 ? 'left' : 'right');\n }\n }\n\n protected onPan(x: number): void {\n if (!this.computedDraggable()) {\n return;\n }\n\n const min = 1 - this.items().length / this.itemsCount();\n\n this.translate.set(tuiClamp(x / this.el.clientWidth + this.translate(), min, 0));\n this.onShift();\n }\n\n protected onSwipe(direction: TuiSwipeDirection): void {\n if (direction === 'left') {\n this.next();\n } else if (direction === 'right') {\n this.prev();\n }\n }\n\n protected onAutoscroll(): void {\n this.updateIndex(this.index() === this.items().length - 1 ? 0 : this.index() + 1);\n }\n\n protected onShift(): void {\n this.shift.emit(Math.abs((this.x() % 1) + 0.5) * 2);\n }\n\n private updateIndex(index: number): void {\n this.index.set(tuiClamp(index, 0, this.items().length - 1));\n }\n}\n","<div\n class=\"t-scroller\"\n (tuiCarouselScroll)=\"onScroll($event)\"\n>\n <div\n waIntersectionObserver\n waIntersectionThreshold=\"0.5\"\n class=\"t-wrapper\"\n >\n <div\n class=\"t-items\"\n [style.transform]=\"transform()\"\n (tuiCarouselAutoscroll)=\"onAutoscroll()\"\n (tuiPan)=\"onPan($event[0])\"\n (tuiSwipe)=\"onSwipe($event.direction)\"\n >\n @for (item of items(); track $index) {\n <fieldset\n class=\"t-item\"\n [disabled]=\"isDisabled($index)\"\n [style.flex-basis.%]=\"100 / itemsCount()\"\n [style.max-width.%]=\"100 / itemsCount()\"\n [style.min-width.%]=\"100 / itemsCount()\"\n (waIntersectionObservee)=\"$event[0] && onIntersection($event[0].intersectionRatio, $index)\"\n >\n <ng-container [ngTemplateOutlet]=\"item\" />\n </fieldset>\n }\n </div>\n </div>\n</div>\n\n<ng-content />\n","import {Directive} from '@angular/core';\nimport {tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\n\n@Directive({\n selector: '[tuiCarouselButtons]',\n providers: [\n tuiButtonOptionsProvider({\n appearance: 'secondary',\n size: 'm',\n }),\n ],\n})\nexport class TuiCarouselButtons {}\n","import {TuiItem} from '@taiga-ui/cdk/directives/item';\n\nimport {TuiCarouselComponent} from './carousel.component';\nimport {TuiCarouselDirective} from './carousel.directive';\nimport {TuiCarouselAutoscroll} from './carousel-autoscroll.directive';\nimport {TuiCarouselButtons} from './carousel-buttons.directive';\nimport {TuiCarouselScroll} from './carousel-scroll.directive';\n\nexport const TuiCarousel = [\n TuiItem,\n TuiCarouselComponent,\n TuiCarouselDirective,\n TuiCarouselAutoscroll,\n TuiCarouselButtons,\n TuiCarouselScroll,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AASM,MAAO,oBAAqB,SAAQ,UAAmB,CAAA;AA4BzD,IAAA,WAAA,GAAA;AACI,QAAA,KAAK,CAAC,CAAC,UAAU,KAAK,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC;QA5B5C,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AACvB,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,WAAW,CAAC;AAC9B,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,kBAAkB,CAAC;AACrC,QAAA,IAAA,CAAA,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC;AACrB,QAAA,IAAA,CAAA,QAAQ,GAAG,IAAI,OAAO,EAAQ;AAC9B,QAAA,I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A,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,kBAAkB,EAPhB,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,sBAAA,EAAA,SAAA,EAAA;AACP,YAAA,wBAAwB,CAAC;AACrB,gBAAA,UAAU,EAAE,WAAW;AACvB,gBAAA,IAAI,EAAE,GAAG;aACZ,CAAC;AACL,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAEQ,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAT9B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,sBAAsB;AAChC,oBAAA,SAAS,EAAE;AACP,wBAAA,wBAAwB,CAAC;AACrB,4BAAA,UAAU,EAAE,WAAW;AACvB,4BAAA,IAAI,EAAE,GAAG;yBACZ,CAAC;AACL,qBAAA;AACJ,iBAAA;;;ACHY,MAAA,WAAW,GAAG;IACvB,OAAO;IACP,oBAAoB;IACpB,oBAAoB;IACpB,qBAAqB;IACrB,kBAAkB;IAClB,iBAAiB;;;ACdrB;;AAEG;;;;"}
@@ -1,36 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { computed, ChangeDetectionStrategy, ViewEncapsulation, Component } from '@angular/core';
3
- import { tuiCreateOptions, tuiProvide } from '@taiga-ui/cdk/utils/di';
4
- import * as i1 from '@taiga-ui/core/directives/icons';
5
- import { tuiIconStart, tuiIconEnd, TuiIcons } from '@taiga-ui/core/directives/icons';
6
- import { TuiRadioComponent, TUI_RADIO_OPTIONS } from '@taiga-ui/kit/components/radio';
7
-
8
- const [TUI_CHECKBOX_OPTIONS, tuiCheckboxOptionsProvider] = tuiCreateOptions({
9
- size: 'm',
10
- appearance: (el) => el.checked || el.indeterminate ? 'primary' : 'outline-grayscale',
11
- icons: {
12
- checked: () => '@tui.check',
13
- indeterminate: () => '@tui.minus',
14
- },
15
- });
16
-
17
- class TuiCheckbox extends TuiRadioComponent {
18
- constructor() {
19
- super(...arguments);
20
- this.check = tuiIconStart(computed(() => this.options.icons.checked(this.size())));
21
- this.indeterminate = tuiIconEnd(computed(() => this.options.icons.indeterminate(this.size())));
22
- }
23
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCheckbox, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
24
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: TuiCheckbox, isStandalone: true, selector: "input[type=\"checkbox\"][tuiCheckbox]", providers: [tuiProvide(TUI_RADIO_OPTIONS, TUI_CHECKBOX_OPTIONS)], usesInheritance: true, hostDirectives: [{ directive: i1.TuiIcons }], ngImport: i0, template: '', isInline: true, styles: ["[tuiCheckbox]{--t-size: 1.5rem;--t-radius: var(--tui-radius-s);inline-size:var(--t-size);block-size:var(--t-size);border-radius:var(--t-radius);cursor:pointer;margin:0;flex-shrink:0}[tuiCheckbox]:before{position:absolute;block-size:100%;inline-size:100%;font-size:1rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"></svg>');transform:scale(0);transition:transform var(--tui-duration) ease-in-out,mask 0s var(--tui-duration) ease-in-out}[tuiCheckbox]:after{display:none}[tuiCheckbox]:disabled._readonly._readonly{opacity:1;pointer-events:none}[tuiCheckbox]:checked:before,[tuiCheckbox]:indeterminate:before{-webkit-mask-image:var(--t-icon-start);mask-image:var(--t-icon-start);transform:scale(1);transition:transform var(--tui-duration) ease-in-out,mask 0s ease-in-out;transition-duration:inherit}[tuiCheckbox]:indeterminate:before{-webkit-mask-image:var(--t-icon-end);mask-image:var(--t-icon-end)}[tuiCheckbox][data-size=s]{--t-size: 1rem;--t-radius: var(--tui-radius-xs)}[tuiCheckbox][data-size=s]:before{font-size:.875rem}[tuiCheckbox]:invalid:not([data-mode]),[tuiCheckbox][data-mode~=invalid]{color:#fff}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
25
- }
26
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiCheckbox, decorators: [{
27
- type: Component,
28
- args: [{ selector: 'input[type="checkbox"][tuiCheckbox]', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiProvide(TUI_RADIO_OPTIONS, TUI_CHECKBOX_OPTIONS)], hostDirectives: [TuiIcons], styles: ["[tuiCheckbox]{--t-size: 1.5rem;--t-radius: var(--tui-radius-s);inline-size:var(--t-size);block-size:var(--t-size);border-radius:var(--t-radius);cursor:pointer;margin:0;flex-shrink:0}[tuiCheckbox]:before{position:absolute;block-size:100%;inline-size:100%;font-size:1rem;-webkit-mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"></svg>');mask-image:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\"></svg>');transform:scale(0);transition:transform var(--tui-duration) ease-in-out,mask 0s var(--tui-duration) ease-in-out}[tuiCheckbox]:after{display:none}[tuiCheckbox]:disabled._readonly._readonly{opacity:1;pointer-events:none}[tuiCheckbox]:checked:before,[tuiCheckbox]:indeterminate:before{-webkit-mask-image:var(--t-icon-start);mask-image:var(--t-icon-start);transform:scale(1);transition:transform var(--tui-duration) ease-in-out,mask 0s ease-in-out;transition-duration:inherit}[tuiCheckbox]:indeterminate:before{-webkit-mask-image:var(--t-icon-end);mask-image:var(--t-icon-end)}[tuiCheckbox][data-size=s]{--t-size: 1rem;--t-radius: var(--tui-radius-xs)}[tuiCheckbox][data-size=s]:before{font-size:.875rem}[tuiCheckbox]:invalid:not([data-mode]),[tuiCheckbox][data-mode~=invalid]{color:#fff}\n"] }]
29
- }] });
30
-
31
- /**
32
- * Generated bundle index. Do not edit.
33
- */
34
-
35
- export { TUI_CHECKBOX_OPTIONS, TuiCheckbox, tuiCheckboxOptionsProvider };
36
- //# sourceMappingURL=taiga-ui-kit-components-checkbox.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-components-checkbox.mjs","sources":["../../../projects/kit/components/checkbox/checkbox.options.ts","../../../projects/kit/components/checkbox/checkbox.component.ts","../../../projects/kit/components/checkbox/taiga-ui-kit-components-checkbox.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeS} from '@taiga-ui/core/types';\nimport {type TuiRadioOptions} from '@taiga-ui/kit/components/radio';\n\nexport interface TuiCheckboxOptions extends TuiRadioOptions {\n readonly icons: Readonly<{\n checked: TuiStringHandler<TuiSizeS>;\n indeterminate: TuiStringHandler<TuiSizeS>;\n }>;\n}\n\nexport const [TUI_CHECKBOX_OPTIONS, tuiCheckboxOptionsProvider] =\n tuiCreateOptions<TuiCheckboxOptions>({\n size: 'm',\n appearance: (el) =>\n el.checked || el.indeterminate ? 'primary' : 'outline-grayscale',\n icons: {\n checked: () => '@tui.check',\n indeterminate: () => '@tui.minus',\n },\n });\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/di';\nimport {tuiIconEnd, TuiIcons, tuiIconStart} from '@taiga-ui/core/directives/icons';\nimport {TUI_RADIO_OPTIONS, TuiRadioComponent} from '@taiga-ui/kit/components/radio';\n\nimport {TUI_CHECKBOX_OPTIONS, type TuiCheckboxOptions} from './checkbox.options';\n\n@Component({\n selector: 'input[type=\"checkbox\"][tuiCheckbox]',\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/checkbox.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiProvide(TUI_RADIO_OPTIONS, TUI_CHECKBOX_OPTIONS)],\n hostDirectives: [TuiIcons],\n})\nexport class TuiCheckbox extends TuiRadioComponent<TuiCheckboxOptions> {\n protected readonly check = tuiIconStart(\n computed(() => this.options.icons.checked(this.size())),\n );\n\n protected readonly indeterminate = tuiIconEnd(\n computed(() => this.options.icons.indeterminate(this.size())),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;MAYa,CAAC,oBAAoB,EAAE,0BAA0B,CAAC,GAC3D,gBAAgB,CAAqB;AACjC,IAAA,IAAI,EAAE,GAAG;IACT,UAAU,EAAE,CAAC,EAAE,KACX,EAAE,CAAC,OAAO,IAAI,EAAE,CAAC,aAAa,GAAG,SAAS,GAAG,mBAAmB;AACpE,IAAA,KAAK,EAAE;AACH,QAAA,OAAO,EAAE,MAAM,YAAY;AAC3B,QAAA,aAAa,EAAE,MAAM,YAAY;AACpC,KAAA;AACJ,CAAA;;ACAC,MAAO,WAAY,SAAQ,iBAAqC,CAAA;AATtE,IAAA,WAAA,GAAA;;QAUuB,IAAK,CAAA,KAAA,GAAG,YAAY,CACnC,QAAQ,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAC1D;QAEkB,IAAa,CAAA,aAAA,GAAG,UAAU,CACzC,QAAQ,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAChE;AACJ;+GARY,WAAW,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAX,WAAW,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,uCAAA,EAAA,SAAA,EAHT,CAAC,UAAU,CAAC,iBAAiB,EAAE,oBAAoB,CAAC,CAAC,EAAA,eAAA,EAAA,IAAA,EAAA,cAAA,EAAA,CAAA,EAAA,SAAA,EAAA,EAAA,CAAA,QAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAJtD,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,qtCAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAOH,WAAW,EAAA,UAAA,EAAA,CAAA;kBATvB,SAAS;+BACI,qCAAqC,EAAA,QAAA,EACrC,EAAE,EAEG,aAAA,EAAA,iBAAiB,CAAC,IAAI,EAAA,eAAA,EACpB,uBAAuB,CAAC,MAAM,EAAA,SAAA,EACpC,CAAC,UAAU,CAAC,iBAAiB,EAAE,oBAAoB,CAAC,CAAC,EAAA,cAAA,EAChD,CAAC,QAAQ,CAAC,EAAA,MAAA,EAAA,CAAA,qtCAAA,CAAA,EAAA;;;ACnB9B;;AAEG;;;;"}
@@ -1,91 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { inject, DestroyRef, input, ChangeDetectionStrategy, ViewEncapsulation, Component, Directive } from '@angular/core';
3
- import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
4
- import { NgControl, NgModel, RadioControlValueAccessor } from '@angular/forms';
5
- import * as i2 from '@taiga-ui/cdk/directives/native-validator';
6
- import { TuiNativeValidator } from '@taiga-ui/cdk/directives/native-validator';
7
- import { tuiControlValue } from '@taiga-ui/cdk/observables';
8
- import { tuiInjectElement } from '@taiga-ui/cdk/utils/dom';
9
- import * as i1 from '@taiga-ui/core/directives/appearance';
10
- import { tuiAppearance, TuiAppearance } from '@taiga-ui/core/directives/appearance';
11
- import { distinctUntilChanged } from 'rxjs';
12
- import { tuiCreateOptions } from '@taiga-ui/cdk/utils/di';
13
- import { TUI_DEFAULT_IDENTITY_MATCHER } from '@taiga-ui/cdk/constants';
14
-
15
- const [TUI_RADIO_OPTIONS, tuiRadioOptionsProvider] = tuiCreateOptions({
16
- size: 'm',
17
- appearance: ({ checked }) => (checked ? 'primary' : 'outline-grayscale'),
18
- });
19
-
20
- class TuiRadioComponent {
21
- constructor() {
22
- this.destroyRef = inject(DestroyRef);
23
- this.el = tuiInjectElement();
24
- this.options = inject(TUI_RADIO_OPTIONS);
25
- this.appearance = tuiAppearance(this.options.appearance(this.el));
26
- this.control = inject(NgControl, { self: true, optional: true });
27
- this.size = input(this.options.size);
28
- }
29
- ngOnInit() {
30
- tuiControlValue(this.control)
31
- .pipe(distinctUntilChanged(), takeUntilDestroyed(this.destroyRef))
32
- .subscribe((value) => {
33
- // https://github.com/angular/angular/issues/14988
34
- const fix = this.control instanceof NgModel && value == null
35
- ? this.control.model
36
- : value;
37
- this.el.indeterminate = fix == null && this.el.matches('[tuiCheckbox]');
38
- this.ngDoCheck();
39
- });
40
- }
41
- ngDoCheck() {
42
- this.appearance.set(this.options.appearance(this.el));
43
- }
44
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRadioComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
45
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.18", type: TuiRadioComponent, isStandalone: true, selector: "input[type=\"radio\"][tuiRadio]", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "disabled": "!control || control.disabled", "attr.data-size": "size()", "class._readonly": "!control" } }, hostDirectives: [{ directive: i1.TuiAppearance, inputs: ["tuiAppearanceState", "tuiAppearanceState", "tuiAppearanceFocus", "tuiAppearanceFocus", "tuiAppearanceMode", "tuiAppearanceMode"] }, { directive: i2.TuiNativeValidator }], ngImport: i0, template: '', isInline: true, styles: ["[tuiRadio]{--t-size: 1.5rem;transition-property:background,box-shadow;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;inline-size:var(--t-size);block-size:var(--t-size);cursor:pointer;margin:0;flex-shrink:0;border-radius:100%;color:var(--tui-text-primary-on-accent-1)}[tuiRadio]:disabled._readonly._readonly{opacity:1}[tuiRadio]:before{position:absolute;inset:0;content:\"\";margin:auto;border-radius:100%;background:currentColor;transform:scale(0);transition-property:transform}[tuiRadio]:checked:before{transform:scale(.5)}[tuiRadio][data-size=s]{--t-size: 1rem}[tuiRadio]:invalid:not([data-mode]),[tuiRadio][data-mode~=invalid]{color:#fff}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
46
- }
47
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRadioComponent, decorators: [{
48
- type: Component,
49
- args: [{ selector: 'input[type="radio"][tuiRadio]', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [
50
- {
51
- directive: TuiAppearance,
52
- inputs: ['tuiAppearanceState', 'tuiAppearanceFocus', 'tuiAppearanceMode'],
53
- },
54
- TuiNativeValidator,
55
- ], host: {
56
- '[disabled]': '!control || control.disabled',
57
- '[attr.data-size]': 'size()',
58
- '[class._readonly]': '!control',
59
- }, styles: ["[tuiRadio]{--t-size: 1.5rem;transition-property:background,box-shadow;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;inline-size:var(--t-size);block-size:var(--t-size);cursor:pointer;margin:0;flex-shrink:0;border-radius:100%;color:var(--tui-text-primary-on-accent-1)}[tuiRadio]:disabled._readonly._readonly{opacity:1}[tuiRadio]:before{position:absolute;inset:0;content:\"\";margin:auto;border-radius:100%;background:currentColor;transform:scale(0);transition-property:transform}[tuiRadio]:checked:before{transform:scale(.5)}[tuiRadio][data-size=s]{--t-size: 1rem}[tuiRadio]:invalid:not([data-mode]),[tuiRadio][data-mode~=invalid]{color:#fff}\n"] }]
60
- }] });
61
-
62
- class TuiRadioDirective {
63
- constructor() {
64
- this.identityMatcher = input(TUI_DEFAULT_IDENTITY_MATCHER);
65
- const accessor = inject(RadioControlValueAccessor);
66
- const writeValue = accessor.writeValue.bind(accessor);
67
- accessor.writeValue = (value) => {
68
- if (this.identityMatcher()(value, accessor.value)) {
69
- writeValue(accessor.value);
70
- }
71
- else {
72
- writeValue(value);
73
- }
74
- };
75
- }
76
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRadioDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
77
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiRadioDirective, isStandalone: true, selector: "input[type=\"radio\"][tuiRadio][identityMatcher]", inputs: { identityMatcher: { classPropertyName: "identityMatcher", publicName: "identityMatcher", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
78
- }
79
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRadioDirective, decorators: [{
80
- type: Directive,
81
- args: [{ selector: 'input[type="radio"][tuiRadio][identityMatcher]' }]
82
- }], ctorParameters: () => [] });
83
-
84
- const TuiRadio = [TuiRadioComponent, TuiRadioDirective];
85
-
86
- /**
87
- * Generated bundle index. Do not edit.
88
- */
89
-
90
- export { TUI_RADIO_OPTIONS, TuiRadio, TuiRadioComponent, TuiRadioDirective, tuiRadioOptionsProvider };
91
- //# sourceMappingURL=taiga-ui-kit-components-radio.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-components-radio.mjs","sources":["../../../projects/kit/components/radio/radio.options.ts","../../../projects/kit/components/radio/radio.component.ts","../../../projects/kit/components/radio/radio.directive.ts","../../../projects/kit/components/radio/radio.ts","../../../projects/kit/components/radio/taiga-ui-kit-components-radio.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiRadioOptions {\n readonly appearance: TuiStringHandler<HTMLInputElement>;\n readonly size: TuiSizeS;\n}\n\nexport const [TUI_RADIO_OPTIONS, tuiRadioOptionsProvider] =\n tuiCreateOptions<TuiRadioOptions>({\n size: 'm',\n appearance: ({checked}) => (checked ? 'primary' : 'outline-grayscale'),\n });\n","import {\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n type DoCheck,\n inject,\n input,\n type OnInit,\n ViewEncapsulation,\n} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {NgControl, NgModel} from '@angular/forms';\nimport {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';\nimport {tuiControlValue} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiAppearance, tuiAppearance} from '@taiga-ui/core/directives/appearance';\nimport {distinctUntilChanged} from 'rxjs';\n\nimport {TUI_RADIO_OPTIONS, type TuiRadioOptions} from './radio.options';\n\n@Component({\n selector: 'input[type=\"radio\"][tuiRadio]',\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/radio.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [\n {\n directive: TuiAppearance,\n inputs: ['tuiAppearanceState', 'tuiAppearanceFocus', 'tuiAppearanceMode'],\n },\n TuiNativeValidator,\n ],\n host: {\n '[disabled]': '!control || control.disabled',\n '[attr.data-size]': 'size()',\n '[class._readonly]': '!control',\n },\n})\nexport class TuiRadioComponent<T extends TuiRadioOptions> implements DoCheck, OnInit {\n private readonly destroyRef = inject(DestroyRef);\n\n protected readonly el = tuiInjectElement<HTMLInputElement>();\n protected readonly options = inject<T>(TUI_RADIO_OPTIONS);\n protected readonly appearance = tuiAppearance(this.options.appearance(this.el));\n protected readonly control = inject(NgControl, {self: true, optional: true});\n\n public readonly size = input(this.options.size);\n\n public ngOnInit(): void {\n tuiControlValue(this.control)\n .pipe(distinctUntilChanged(), takeUntilDestroyed(this.destroyRef))\n .subscribe((value) => {\n // https://github.com/angular/angular/issues/14988\n const fix =\n this.control instanceof NgModel && value == null\n ? this.control.model\n : value;\n\n this.el.indeterminate = fix == null && this.el.matches('[tuiCheckbox]');\n this.ngDoCheck();\n });\n }\n\n public ngDoCheck(): void {\n this.appearance.set(this.options.appearance(this.el));\n }\n}\n","import {Directive, inject, input} from '@angular/core';\nimport {RadioControlValueAccessor} from '@angular/forms';\nimport {TUI_DEFAULT_IDENTITY_MATCHER} from '@taiga-ui/cdk/constants';\nimport {type TuiIdentityMatcher} from '@taiga-ui/cdk/types';\n\n@Directive({selector: 'input[type=\"radio\"][tuiRadio][identityMatcher]'})\nexport class TuiRadioDirective<T> {\n public readonly identityMatcher = input<TuiIdentityMatcher<T>>(\n TUI_DEFAULT_IDENTITY_MATCHER,\n );\n\n constructor() {\n const accessor = inject(RadioControlValueAccessor);\n const writeValue = accessor.writeValue.bind(accessor);\n\n accessor.writeValue = (value: T) => {\n if (this.identityMatcher()(value, accessor.value)) {\n writeValue(accessor.value);\n } else {\n writeValue(value);\n }\n };\n }\n}\n","import {TuiRadioComponent} from './radio.component';\nimport {TuiRadioDirective} from './radio.directive';\n\nexport const TuiRadio = [TuiRadioComponent, TuiRadioDirective] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;MASa,CAAC,iBAAiB,EAAE,uBAAuB,CAAC,GACrD,gBAAgB,CAAkB;AAC9B,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,UAAU,EAAE,CAAC,EAAC,OAAO,EAAC,MAAM,OAAO,GAAG,SAAS,GAAG,mBAAmB,CAAC;AACzE,CAAA;;MC0BQ,iBAAiB,CAAA;AAnB9B,IAAA,WAAA,GAAA;AAoBqB,QAAA,IAAA,CAAA,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC;QAE7B,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