@taiga-ui/kit 4.52.0-canary.24b31eb → 4.52.0-canary.2fa3dd5

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 (268) hide show
  1. package/README.md +1 -1
  2. package/components/action-bar/action-bar.component.d.ts +5 -7
  3. package/components/action-bar/index.d.ts +0 -2
  4. package/components/badge/badge.options.d.ts +1 -3
  5. package/components/badge-notification/badge-notification.options.d.ts +1 -3
  6. package/components/block/block.options.d.ts +1 -3
  7. package/components/breadcrumbs/breadcrumbs.options.d.ts +1 -3
  8. package/components/calendar-month/calendar-month.component.d.ts +1 -1
  9. package/components/calendar-range/calendar-range.component.d.ts +1 -2
  10. package/components/chip/chip.options.d.ts +1 -3
  11. package/components/confirm/confirm.component.d.ts +2 -2
  12. package/components/copy/copy.component.d.ts +1 -1
  13. package/components/copy/copy.directive.d.ts +1 -0
  14. package/components/data-list-wrapper/data-list-group-wrapper.component.d.ts +2 -0
  15. package/components/files/file/file.options.d.ts +1 -1
  16. package/components/files/files/files.component.d.ts +2 -2
  17. package/components/files/input-files/input-files.options.d.ts +1 -3
  18. package/components/index.d.ts +0 -1
  19. package/components/input-number/input-number.directive.d.ts +5 -9
  20. package/components/input-number/step/input-number-step.component.d.ts +1 -1
  21. package/components/input-phone-international/input-phone-international.component.d.ts +3 -3
  22. package/components/input-phone-international/input-phone-international.options.d.ts +1 -3
  23. package/components/input-pin/input-pin.component.d.ts +1 -1
  24. package/components/input-range/input-range.component.d.ts +4 -7
  25. package/components/input-slider/input-slider.directive.d.ts +0 -1
  26. package/components/input-time/input-time.directive.d.ts +6 -8
  27. package/components/line-clamp/line-clamp.component.d.ts +8 -10
  28. package/components/line-clamp/line-clamp.options.d.ts +1 -3
  29. package/components/multi-select/multi-select-group/multi-select-group.component.d.ts +1 -1
  30. package/components/multi-select/multi-select-option/multi-select-option.component.d.ts +1 -1
  31. package/components/notification-middle/notification-middle.component.d.ts +2 -2
  32. package/components/notification-middle/notification-middle.directive.d.ts +4 -3
  33. package/components/notification-middle/notification-middle.service.d.ts +7 -3
  34. package/components/pagination/index.d.ts +1 -0
  35. package/components/pagination/pagination.component.d.ts +3 -2
  36. package/components/pagination/pagination.options.d.ts +10 -0
  37. package/components/preview/dialog/preview-dialog.component.d.ts +2 -2
  38. package/components/preview/dialog/preview-dialog.directive.d.ts +3 -3
  39. package/components/preview/dialog/preview-dialog.service.d.ts +5 -2
  40. package/components/preview/pagination/preview-pagination.component.d.ts +1 -1
  41. package/components/preview/preview.component.d.ts +1 -1
  42. package/components/preview/zoom/preview-zoom.component.d.ts +1 -1
  43. package/components/progress/progress-bar/progress-color-segments.directive.d.ts +4 -4
  44. package/components/progress/progress.options.d.ts +1 -3
  45. package/components/push/push-alert.component.d.ts +4 -3
  46. package/components/push/push.component.d.ts +1 -1
  47. package/components/push/push.directive.d.ts +4 -6
  48. package/components/push/push.options.d.ts +4 -8
  49. package/components/push/push.service.d.ts +6 -2
  50. package/components/range/range-change.directive.d.ts +1 -2
  51. package/components/range/range.component.d.ts +16 -24
  52. package/components/rating/rating.options.d.ts +1 -3
  53. package/components/select/native-select/native-select.component.d.ts +4 -5
  54. package/components/slider/helpers/key-steps.d.ts +1 -2
  55. package/components/slider/helpers/slider-key-steps.directive.d.ts +12 -21
  56. package/components/slider/slider.options.d.ts +1 -6
  57. package/components/tabs/tabs-with-more.component.d.ts +1 -1
  58. package/components/tabs/tabs.options.d.ts +1 -6
  59. package/components/textarea/textarea-limit.directive.d.ts +4 -5
  60. package/components/toast/toast.component.d.ts +4 -3
  61. package/components/toast/toast.options.d.ts +8 -7
  62. package/components/toast/toast.service.d.ts +10 -9
  63. package/components/tree/components/tree-item-content/tree-item-content.component.d.ts +8 -1
  64. package/components/tree/misc/tree.constants.d.ts +0 -3
  65. package/components/tree/misc/tree.tokens.d.ts +1 -6
  66. package/directives/button-close/button-close.directive.d.ts +2 -1
  67. package/directives/button-select/button-select.directive.d.ts +3 -3
  68. package/directives/fluid-typography/fluid-typography.directive.d.ts +3 -6
  69. package/directives/fluid-typography/fluid-typography.options.d.ts +1 -3
  70. package/fesm2022/taiga-ui-kit-components-accordion.mjs +1 -2
  71. package/fesm2022/taiga-ui-kit-components-accordion.mjs.map +1 -1
  72. package/fesm2022/taiga-ui-kit-components-action-bar.mjs +20 -36
  73. package/fesm2022/taiga-ui-kit-components-action-bar.mjs.map +1 -1
  74. package/fesm2022/taiga-ui-kit-components-avatar.mjs +3 -3
  75. package/fesm2022/taiga-ui-kit-components-avatar.mjs.map +1 -1
  76. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs +4 -9
  77. package/fesm2022/taiga-ui-kit-components-badge-notification.mjs.map +1 -1
  78. package/fesm2022/taiga-ui-kit-components-badge.mjs +6 -10
  79. package/fesm2022/taiga-ui-kit-components-badge.mjs.map +1 -1
  80. package/fesm2022/taiga-ui-kit-components-badged-content.mjs +0 -1
  81. package/fesm2022/taiga-ui-kit-components-badged-content.mjs.map +1 -1
  82. package/fesm2022/taiga-ui-kit-components-block.mjs +4 -8
  83. package/fesm2022/taiga-ui-kit-components-block.mjs.map +1 -1
  84. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +6 -12
  85. package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs.map +1 -1
  86. package/fesm2022/taiga-ui-kit-components-button-loading.mjs +3 -3
  87. package/fesm2022/taiga-ui-kit-components-button-loading.mjs.map +1 -1
  88. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +3 -6
  89. package/fesm2022/taiga-ui-kit-components-calendar-month.mjs.map +1 -1
  90. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +4 -5
  91. package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
  92. package/fesm2022/taiga-ui-kit-components-carousel.mjs +3 -9
  93. package/fesm2022/taiga-ui-kit-components-carousel.mjs.map +1 -1
  94. package/fesm2022/taiga-ui-kit-components-checkbox.mjs +1 -1
  95. package/fesm2022/taiga-ui-kit-components-checkbox.mjs.map +1 -1
  96. package/fesm2022/taiga-ui-kit-components-chip.mjs +6 -10
  97. package/fesm2022/taiga-ui-kit-components-chip.mjs.map +1 -1
  98. package/fesm2022/taiga-ui-kit-components-combo-box.mjs +5 -6
  99. package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
  100. package/fesm2022/taiga-ui-kit-components-comment.mjs.map +1 -1
  101. package/fesm2022/taiga-ui-kit-components-compass.mjs +3 -3
  102. package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
  103. package/fesm2022/taiga-ui-kit-components-confirm.mjs +3 -5
  104. package/fesm2022/taiga-ui-kit-components-confirm.mjs.map +1 -1
  105. package/fesm2022/taiga-ui-kit-components-copy.mjs +6 -6
  106. package/fesm2022/taiga-ui-kit-components-copy.mjs.map +1 -1
  107. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +11 -3
  108. package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs.map +1 -1
  109. package/fesm2022/taiga-ui-kit-components-drawer.mjs.map +1 -1
  110. package/fesm2022/taiga-ui-kit-components-elastic-container.mjs +0 -1
  111. package/fesm2022/taiga-ui-kit-components-elastic-container.mjs.map +1 -1
  112. package/fesm2022/taiga-ui-kit-components-files.mjs +17 -24
  113. package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
  114. package/fesm2022/taiga-ui-kit-components-filter.mjs.map +1 -1
  115. package/fesm2022/taiga-ui-kit-components-floating-container.mjs +2 -2
  116. package/fesm2022/taiga-ui-kit-components-floating-container.mjs.map +1 -1
  117. package/fesm2022/taiga-ui-kit-components-fullscreen.mjs.map +1 -1
  118. package/fesm2022/taiga-ui-kit-components-input-chip.mjs +0 -2
  119. package/fesm2022/taiga-ui-kit-components-input-chip.mjs.map +1 -1
  120. package/fesm2022/taiga-ui-kit-components-input-color.mjs.map +1 -1
  121. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +3 -8
  122. package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs.map +1 -1
  123. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs +0 -1
  124. package/fesm2022/taiga-ui-kit-components-input-date-range.mjs.map +1 -1
  125. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +3 -5
  126. package/fesm2022/taiga-ui-kit-components-input-date-time.mjs.map +1 -1
  127. package/fesm2022/taiga-ui-kit-components-input-date.mjs +9 -17
  128. package/fesm2022/taiga-ui-kit-components-input-date.mjs.map +1 -1
  129. package/fesm2022/taiga-ui-kit-components-input-inline.mjs +2 -3
  130. package/fesm2022/taiga-ui-kit-components-input-inline.mjs.map +1 -1
  131. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +3 -5
  132. package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
  133. package/fesm2022/taiga-ui-kit-components-input-month.mjs +3 -5
  134. package/fesm2022/taiga-ui-kit-components-input-month.mjs.map +1 -1
  135. package/fesm2022/taiga-ui-kit-components-input-number.mjs +22 -46
  136. package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
  137. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +12 -15
  138. package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
  139. package/fesm2022/taiga-ui-kit-components-input-phone.mjs +3 -5
  140. package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
  141. package/fesm2022/taiga-ui-kit-components-input-pin.mjs.map +1 -1
  142. package/fesm2022/taiga-ui-kit-components-input-range.mjs +7 -14
  143. package/fesm2022/taiga-ui-kit-components-input-range.mjs.map +1 -1
  144. package/fesm2022/taiga-ui-kit-components-input-slider.mjs +9 -15
  145. package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
  146. package/fesm2022/taiga-ui-kit-components-input-time.mjs +29 -35
  147. package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
  148. package/fesm2022/taiga-ui-kit-components-input-year.mjs +2 -4
  149. package/fesm2022/taiga-ui-kit-components-input-year.mjs.map +1 -1
  150. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +2 -4
  151. package/fesm2022/taiga-ui-kit-components-items-with-more.mjs.map +1 -1
  152. package/fesm2022/taiga-ui-kit-components-like.mjs +1 -1
  153. package/fesm2022/taiga-ui-kit-components-like.mjs.map +1 -1
  154. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +25 -67
  155. package/fesm2022/taiga-ui-kit-components-line-clamp.mjs.map +1 -1
  156. package/fesm2022/taiga-ui-kit-components-message.mjs +0 -1
  157. package/fesm2022/taiga-ui-kit-components-message.mjs.map +1 -1
  158. package/fesm2022/taiga-ui-kit-components-multi-select.mjs +12 -14
  159. package/fesm2022/taiga-ui-kit-components-multi-select.mjs.map +1 -1
  160. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +31 -20
  161. package/fesm2022/taiga-ui-kit-components-notification-middle.mjs.map +1 -1
  162. package/fesm2022/taiga-ui-kit-components-pager.mjs.map +1 -1
  163. package/fesm2022/taiga-ui-kit-components-pagination.mjs +20 -10
  164. package/fesm2022/taiga-ui-kit-components-pagination.mjs.map +1 -1
  165. package/fesm2022/taiga-ui-kit-components-pin.mjs +2 -2
  166. package/fesm2022/taiga-ui-kit-components-pin.mjs.map +1 -1
  167. package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs +23 -15
  168. package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs.map +1 -1
  169. package/fesm2022/taiga-ui-kit-components-preview.mjs +36 -29
  170. package/fesm2022/taiga-ui-kit-components-preview.mjs.map +1 -1
  171. package/fesm2022/taiga-ui-kit-components-progress.mjs +41 -33
  172. package/fesm2022/taiga-ui-kit-components-progress.mjs.map +1 -1
  173. package/fesm2022/taiga-ui-kit-components-pulse.mjs +1 -1
  174. package/fesm2022/taiga-ui-kit-components-pulse.mjs.map +1 -1
  175. package/fesm2022/taiga-ui-kit-components-push.mjs +40 -47
  176. package/fesm2022/taiga-ui-kit-components-push.mjs.map +1 -1
  177. package/fesm2022/taiga-ui-kit-components-radio-list.mjs +2 -2
  178. package/fesm2022/taiga-ui-kit-components-radio-list.mjs.map +1 -1
  179. package/fesm2022/taiga-ui-kit-components-radio.mjs +3 -4
  180. package/fesm2022/taiga-ui-kit-components-radio.mjs.map +1 -1
  181. package/fesm2022/taiga-ui-kit-components-range.mjs +36 -80
  182. package/fesm2022/taiga-ui-kit-components-range.mjs.map +1 -1
  183. package/fesm2022/taiga-ui-kit-components-rating.mjs +3 -8
  184. package/fesm2022/taiga-ui-kit-components-rating.mjs.map +1 -1
  185. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs +7 -3
  186. package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs.map +1 -1
  187. package/fesm2022/taiga-ui-kit-components-segmented.mjs +3 -4
  188. package/fesm2022/taiga-ui-kit-components-segmented.mjs.map +1 -1
  189. package/fesm2022/taiga-ui-kit-components-select.mjs +35 -40
  190. package/fesm2022/taiga-ui-kit-components-select.mjs.map +1 -1
  191. package/fesm2022/taiga-ui-kit-components-slider.mjs +59 -67
  192. package/fesm2022/taiga-ui-kit-components-slider.mjs.map +1 -1
  193. package/fesm2022/taiga-ui-kit-components-slides.mjs.map +1 -1
  194. package/fesm2022/taiga-ui-kit-components-status.mjs.map +1 -1
  195. package/fesm2022/taiga-ui-kit-components-stepper.mjs.map +1 -1
  196. package/fesm2022/taiga-ui-kit-components-switch.mjs +1 -1
  197. package/fesm2022/taiga-ui-kit-components-switch.mjs.map +1 -1
  198. package/fesm2022/taiga-ui-kit-components-tabs.mjs +7 -17
  199. package/fesm2022/taiga-ui-kit-components-tabs.mjs.map +1 -1
  200. package/fesm2022/taiga-ui-kit-components-textarea.mjs +7 -16
  201. package/fesm2022/taiga-ui-kit-components-textarea.mjs.map +1 -1
  202. package/fesm2022/taiga-ui-kit-components-tiles.mjs +2 -3
  203. package/fesm2022/taiga-ui-kit-components-tiles.mjs.map +1 -1
  204. package/fesm2022/taiga-ui-kit-components-toast.mjs +39 -40
  205. package/fesm2022/taiga-ui-kit-components-toast.mjs.map +1 -1
  206. package/fesm2022/taiga-ui-kit-components-tree.mjs +34 -39
  207. package/fesm2022/taiga-ui-kit-components-tree.mjs.map +1 -1
  208. package/fesm2022/taiga-ui-kit-components.mjs +0 -1
  209. package/fesm2022/taiga-ui-kit-components.mjs.map +1 -1
  210. package/fesm2022/taiga-ui-kit-directives-button-close.mjs +13 -5
  211. package/fesm2022/taiga-ui-kit-directives-button-close.mjs.map +1 -1
  212. package/fesm2022/taiga-ui-kit-directives-button-group.mjs.map +1 -1
  213. package/fesm2022/taiga-ui-kit-directives-button-select.mjs +14 -13
  214. package/fesm2022/taiga-ui-kit-directives-button-select.mjs.map +1 -1
  215. package/fesm2022/taiga-ui-kit-directives-chevron.mjs.map +1 -1
  216. package/fesm2022/taiga-ui-kit-directives-connected.mjs +0 -1
  217. package/fesm2022/taiga-ui-kit-directives-connected.mjs.map +1 -1
  218. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs +0 -1
  219. package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs.map +1 -1
  220. package/fesm2022/taiga-ui-kit-directives-fade.mjs.map +1 -1
  221. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs +12 -25
  222. package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs.map +1 -1
  223. package/fesm2022/taiga-ui-kit-directives-highlight.mjs +0 -1
  224. package/fesm2022/taiga-ui-kit-directives-highlight.mjs.map +1 -1
  225. package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs +0 -1
  226. package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs.map +1 -1
  227. package/fesm2022/taiga-ui-kit-directives-password.mjs +2 -6
  228. package/fesm2022/taiga-ui-kit-directives-password.mjs.map +1 -1
  229. package/fesm2022/taiga-ui-kit-directives-present.mjs +0 -1
  230. package/fesm2022/taiga-ui-kit-directives-present.mjs.map +1 -1
  231. package/fesm2022/taiga-ui-kit-directives-sensitive.mjs.map +1 -1
  232. package/fesm2022/taiga-ui-kit-directives-shimmer.mjs.map +1 -1
  233. package/fesm2022/taiga-ui-kit-directives-skeleton.mjs.map +1 -1
  234. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +2 -2
  235. package/fesm2022/taiga-ui-kit-directives-tooltip.mjs.map +1 -1
  236. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +1 -2
  237. package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs.map +1 -1
  238. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs +0 -1
  239. package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs.map +1 -1
  240. package/fesm2022/taiga-ui-kit-pipes-emails.mjs +0 -1
  241. package/fesm2022/taiga-ui-kit-pipes-emails.mjs.map +1 -1
  242. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs +0 -1
  243. package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs.map +1 -1
  244. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs +0 -1
  245. package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs.map +1 -1
  246. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +2 -2
  247. package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs.map +1 -1
  248. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs +0 -1
  249. package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs.map +1 -1
  250. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs +0 -1
  251. package/fesm2022/taiga-ui-kit-pipes-stringify.mjs.map +1 -1
  252. package/fesm2022/taiga-ui-kit-tokens.mjs +5 -18
  253. package/fesm2022/taiga-ui-kit-tokens.mjs.map +1 -1
  254. package/package.json +14 -14
  255. package/styles/components/badge.less +1 -0
  256. package/styles/components/chip.less +12 -1
  257. package/tokens/i18n.d.ts +25 -26
  258. package/tokens/items-handlers.d.ts +1 -7
  259. package/tokens/preview-icons.d.ts +1 -3
  260. package/components/action-bar/action-bar.d.ts +0 -3
  261. package/components/action-bar/action-bar.directive.d.ts +0 -6
  262. package/components/pdf-viewer/index.d.ts +0 -4
  263. package/components/pdf-viewer/pdf-viewer.component.d.ts +0 -12
  264. package/components/pdf-viewer/pdf-viewer.directive.d.ts +0 -7
  265. package/components/pdf-viewer/pdf-viewer.options.d.ts +0 -13
  266. package/components/pdf-viewer/pdf-viewer.service.d.ts +0 -13
  267. package/fesm2022/taiga-ui-kit-components-pdf-viewer.mjs +0 -83
  268. package/fesm2022/taiga-ui-kit-components-pdf-viewer.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-pagination.mjs","sources":["../../../projects/kit/components/pagination/pagination.component.ts","../../../projects/kit/components/pagination/pagination.template.html","../../../projects/kit/components/pagination/taiga-ui-kit-components-pagination.ts"],"sourcesContent":["import {AsyncPipe} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n Output,\n type QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {EMPTY_QUERY} from '@taiga-ui/cdk/constants';\nimport {TuiLet} from '@taiga-ui/cdk/directives/let';\nimport {TuiRepeatTimes} from '@taiga-ui/cdk/directives/repeat-times';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TUI_SPIN_ICONS} from '@taiga-ui/core/tokens';\nimport {\n type TuiHorizontalDirection,\n type TuiSizeL,\n type TuiSizeS,\n type TuiSizeXS,\n} from '@taiga-ui/core/types';\nimport {TUI_PAGINATION_TEXTS} from '@taiga-ui/kit/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nconst DOTS_LENGTH = 1;\nconst ACTIVE_ITEM_LENGTH = 1;\n\n@Component({\n selector: 'tui-pagination',\n imports: [AsyncPipe, PolymorpheusOutlet, TuiButton, TuiLet, TuiRepeatTimes],\n templateUrl: './pagination.template.html',\n styleUrls: ['./pagination.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPagination {\n @ViewChildren('element', {read: ElementRef})\n private readonly els: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n private readonly el = tuiInjectElement();\n\n protected readonly texts$ = inject(TUI_PAGINATION_TEXTS);\n protected readonly icons = inject(TUI_SPIN_ICONS);\n\n @Input()\n public length = 1;\n\n @Input()\n public focusable = true;\n\n @Input()\n public size: TuiSizeL | TuiSizeS = 'l';\n\n @Input()\n public readonly disabled = false;\n\n /**\n * Amount of visible pages around active page\n */\n @Input()\n public activePadding = 1;\n\n /**\n * Amount of visible pages at the edges\n */\n @Input()\n public sidePadding = 1;\n\n /**\n * Customization for page number display.\n */\n @Input()\n public content: PolymorpheusContent<TuiContext<number>>;\n\n /**\n * Active page index\n */\n @Input()\n public index = 0;\n\n @Output()\n public readonly indexChange = new EventEmitter<number>();\n\n public get nativeFocusableElement(): HTMLElement | null {\n if (this.disabled) {\n return null;\n }\n\n let activeElementIndex = 0;\n const {elementsLength} = this;\n\n for (let i = 0; i < elementsLength; i++) {\n const itemIndex = this.getItemIndexByElementIndex(i);\n\n if (itemIndex) {\n activeElementIndex++;\n }\n\n if (itemIndex === this.index) {\n break;\n }\n }\n\n return (\n this.els.find((_, index) => index === activeElementIndex)?.nativeElement ??\n null\n );\n }\n\n public get focused(): boolean {\n return tuiIsFocusedIn(this.el);\n }\n\n public get arrowIsDisabledLeft(): boolean {\n return this.index === 0;\n }\n\n public get arrowIsDisabledRight(): boolean {\n return this.reverseIndex === 0;\n }\n\n /**\n * Number of items in a container.\n */\n protected get elementsLength(): number {\n return this.itemsFit ? this.length : this.maxElementsLength;\n }\n\n protected get buttonSize(): TuiSizeXS {\n return this.size === 'm' ? 'xs' : 's';\n }\n\n protected elementIsFocusable(index: number): boolean {\n return this.index === index && !this.focused;\n }\n\n /**\n * Get index by element index\n * @param elementIndex\n * @returns index or null (for '…')\n */\n protected getItemIndexByElementIndex(elementIndex: number): number | null {\n if (this.size === 's') {\n return elementIndex;\n }\n\n if (elementIndex < this.sidePadding) {\n return elementIndex;\n }\n\n if (elementIndex === this.sidePadding && this.hasCollapsedItems(this.index)) {\n return null;\n }\n\n const reverseElementIndex = this.lastElementIndex - elementIndex;\n\n if (\n reverseElementIndex === this.sidePadding &&\n this.hasCollapsedItems(this.reverseIndex)\n ) {\n return null;\n }\n\n if (reverseElementIndex < this.sidePadding) {\n return this.lastIndex - reverseElementIndex;\n }\n\n const computedIndex = this.index - this.maxHalfLength + elementIndex;\n\n return tuiClamp(\n computedIndex,\n elementIndex,\n this.lastIndex - reverseElementIndex,\n );\n }\n\n protected getElementMode(index: number): string {\n const fallback = this.size === 's' ? 'secondary' : 'flat';\n\n return this.index === index ? 'primary' : fallback;\n }\n\n protected onElementClick(index: number): void {\n this.updateIndex(index);\n }\n\n protected onElementKeyDownArrowLeft(element: HTMLElement): void {\n if (element === this.els.first.nativeElement) {\n return;\n }\n\n const previous = this.els.find(\n (_, index, array) => array[index + 1]?.nativeElement === element,\n );\n\n previous?.nativeElement.focus();\n }\n\n protected onElementKeyDownArrowRight(element: HTMLElement): void {\n if (element === this.els.last.nativeElement) {\n return;\n }\n\n const next = this.els.find(\n (_, index, array) => array[index - 1]?.nativeElement === element,\n );\n\n next?.nativeElement.focus();\n }\n\n protected onArrowClick(direction: TuiHorizontalDirection): void {\n this.tryChangeTo(direction);\n this.focusActive();\n }\n\n /**\n * Active index from the end\n */\n private get reverseIndex(): number {\n return this.lastIndex - this.index;\n }\n\n /**\n * Max number of elements in half (not counting the middle one).\n */\n private get maxHalfLength(): number {\n return this.sidePadding + DOTS_LENGTH + this.activePadding;\n }\n\n /**\n * Is there '...' anywhere\n */\n private get itemsFit(): boolean {\n return this.length <= this.maxElementsLength;\n }\n\n /**\n * Max number of elements\n */\n private get maxElementsLength(): number {\n return this.maxHalfLength * 2 + ACTIVE_ITEM_LENGTH;\n }\n\n private get lastIndex(): number {\n return this.length - 1;\n }\n\n private get lastElementIndex(): number {\n return this.elementsLength - 1;\n }\n\n /**\n * Are there collapsed items at that index\n * @param index\n * @returns there are collapsed items\n */\n private hasCollapsedItems(index: number): boolean {\n return !this.itemsFit && index > this.maxHalfLength;\n }\n\n private tryChangeTo(direction: TuiHorizontalDirection): void {\n this.updateIndex(\n tuiClamp(this.index + (direction === 'right' ? 1 : -1), 0, this.lastIndex),\n );\n }\n\n private focusActive(): void {\n const {nativeFocusableElement} = this;\n\n if (nativeFocusableElement) {\n nativeFocusableElement.focus();\n }\n }\n\n private updateIndex(index: number): void {\n if (this.index === index) {\n return;\n }\n\n this.index = index;\n this.indexChange.emit(index);\n }\n}\n","<div class=\"t-content\">\n @if (size !== 's') {\n @if (texts$ | async; as texts) {\n <button\n appearance=\"flat\"\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [disabled]=\"arrowIsDisabledLeft\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts[0] }}\n </button>\n <ng-container *tuiRepeatTimes=\"let elementIndex of elementsLength\">\n <ng-container *tuiLet=\"getItemIndexByElementIndex(elementIndex) as index\">\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled\"\n [size]=\"buttonSize\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container\n *polymorpheusOutlet=\"content || index + 1 as text; context: {$implicit: index}\"\n >\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-dots\"\n [class.t-dots_small]=\"size === 'm'\"\n ></div>\n }\n </ng-container>\n </ng-container>\n <button\n appearance=\"flat\"\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [disabled]=\"arrowIsDisabledRight\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts[1] }}\n </button>\n }\n } @else {\n <button\n *tuiRepeatTimes=\"let indexItem of length\"\n #element\n tuiButton\n type=\"button\"\n class=\"t-button t-button_small\"\n [appearance]=\"getElementMode(indexItem)\"\n [disabled]=\"disabled\"\n [tabIndex]=\"elementIsFocusable(indexItem) ? 0 : -1\"\n (click)=\"onElementClick(indexItem)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n {{ indexItem + 1 }}\n </button>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AA8BA,MAAM,WAAW,GAAG,CAAC;AACrB,MAAM,kBAAkB,GAAG,CAAC;MASf,aAAa,CAAA;AAP1B,IAAA,WAAA,GAAA;QASqB,IAAG,CAAA,GAAA,GAAuC,WAAW;QAErD,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAErB,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,oBAAoB,CAAC;AACrC,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,cAAc,CAAC;QAG1C,IAAM,CAAA,MAAA,GAAG,CAAC;QAGV,IAAS,CAAA,SAAA,GAAG,IAAI;QAGhB,IAAI,CAAA,IAAA,GAAwB,GAAG;QAGtB,IAAQ,CAAA,QAAA,GAAG,KAAK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AAE,MAAM,EAAE,cAAc,CAAC,EAG1D,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,+5GAAA,EAAA,MAAA,EAAA,CAAA,6nCAAA,CAAA,EAAA;8BAI9B,GAAG,EAAA,CAAA;sBADnB,YAAY;AAAC,gBAAA,IAAA,EAAA,CAAA,SAAS,EAAE,EAAC,IAAI,EAAE,UAAU,EAAC;gBASpC,MAAM,EAAA,CAAA;sBADZ;gBAIM,SAAS,EAAA,CAAA;sBADf;gBAIM,IAAI,EAAA,CAAA;sBADV;gBAIe,QAAQ,EAAA,CAAA;sBADvB;gBAOM,aAAa,EAAA,CAAA;sBADnB;gBAOM,WAAW,EAAA,CAAA;sBADjB;gBAOM,OAAO,EAAA,CAAA;sBADb;gBAOM,KAAK,EAAA,CAAA;sBADX;gBAIe,WAAW,EAAA,CAAA;sBAD1B;;;AErFL;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-kit-components-pagination.mjs","sources":["../../../projects/kit/components/pagination/pagination.options.ts","../../../projects/kit/components/pagination/pagination.component.ts","../../../projects/kit/components/pagination/pagination.template.html","../../../projects/kit/components/pagination/taiga-ui-kit-components-pagination.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 TuiPaginationOptions {\n readonly appearance: TuiStringHandler<{\n isActive: boolean;\n size: TuiSizeL | TuiSizeS;\n }>;\n readonly defaultSize: TuiSizeL | TuiSizeS;\n}\n\nexport const [TUI_PAGINATION_OPTIONS, tuiPaginationOptionsProvider] =\n tuiCreateOptions<TuiPaginationOptions>({\n appearance: ({isActive, size}) => {\n const fallback = size === 's' ? 'secondary' : 'flat';\n\n return isActive ? 'primary' : fallback;\n },\n defaultSize: 'l',\n });\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n Output,\n type QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {EMPTY_QUERY} from '@taiga-ui/cdk/constants';\nimport {TuiRepeatTimes} from '@taiga-ui/cdk/directives/repeat-times';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TUI_SPIN_ICONS} from '@taiga-ui/core/tokens';\nimport {\n type TuiHorizontalDirection,\n type TuiSizeL,\n type TuiSizeS,\n type TuiSizeXS,\n} from '@taiga-ui/core/types';\nimport {TUI_PAGINATION_TEXTS} from '@taiga-ui/kit/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_PAGINATION_OPTIONS} from './pagination.options';\n\nconst DOTS_LENGTH = 1;\nconst ACTIVE_ITEM_LENGTH = 1;\n\n@Component({\n selector: 'tui-pagination',\n imports: [PolymorpheusOutlet, TuiButton, TuiRepeatTimes],\n templateUrl: './pagination.template.html',\n styleUrl: './pagination.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPagination {\n @ViewChildren('element', {read: ElementRef})\n private readonly els: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n private readonly el = tuiInjectElement();\n\n protected readonly texts = inject(TUI_PAGINATION_TEXTS);\n protected readonly icons = inject(TUI_SPIN_ICONS);\n protected readonly options = inject(TUI_PAGINATION_OPTIONS);\n\n @Input()\n public length = 1;\n\n @Input()\n public focusable = true;\n\n @Input()\n public size: TuiSizeL | TuiSizeS = this.options.defaultSize;\n\n @Input()\n public readonly disabled = false;\n\n /**\n * Amount of visible pages around active page\n */\n @Input()\n public activePadding = 1;\n\n /**\n * Amount of visible pages at the edges\n */\n @Input()\n public sidePadding = 1;\n\n /**\n * Customization for page number display.\n */\n @Input()\n public content: PolymorpheusContent<TuiContext<number>>;\n\n /**\n * Active page index\n */\n @Input()\n public index = 0;\n\n @Output()\n public readonly indexChange = new EventEmitter<number>();\n\n public get nativeFocusableElement(): HTMLElement | null {\n if (this.disabled) {\n return null;\n }\n\n let activeElementIndex = 0;\n const {elementsLength} = this;\n\n for (let i = 0; i < elementsLength; i++) {\n const itemIndex = this.getItemIndexByElementIndex(i);\n\n if (itemIndex) {\n activeElementIndex++;\n }\n\n if (itemIndex === this.index) {\n break;\n }\n }\n\n return (\n this.els.find((_, index) => index === activeElementIndex)?.nativeElement ??\n null\n );\n }\n\n public get focused(): boolean {\n return tuiIsFocusedIn(this.el);\n }\n\n public get arrowIsDisabledLeft(): boolean {\n return this.index === 0;\n }\n\n public get arrowIsDisabledRight(): boolean {\n return this.reverseIndex === 0;\n }\n\n /**\n * Number of items in a container.\n */\n protected get elementsLength(): number {\n return this.itemsFit ? this.length : this.maxElementsLength;\n }\n\n protected get buttonSize(): TuiSizeXS {\n return this.size === 'm' ? 'xs' : 's';\n }\n\n protected elementIsFocusable(index: number): boolean {\n return this.index === index && !this.focused;\n }\n\n /**\n * Get index by element index\n * @param elementIndex\n * @returns index or null (for '…')\n */\n protected getItemIndexByElementIndex(elementIndex: number): number | null {\n if (this.size === 's') {\n return elementIndex;\n }\n\n if (elementIndex < this.sidePadding) {\n return elementIndex;\n }\n\n if (elementIndex === this.sidePadding && this.hasCollapsedItems(this.index)) {\n return null;\n }\n\n const reverseElementIndex = this.lastElementIndex - elementIndex;\n\n if (\n reverseElementIndex === this.sidePadding &&\n this.hasCollapsedItems(this.reverseIndex)\n ) {\n return null;\n }\n\n if (reverseElementIndex < this.sidePadding) {\n return this.lastIndex - reverseElementIndex;\n }\n\n const computedIndex = this.index - this.maxHalfLength + elementIndex;\n\n return tuiClamp(\n computedIndex,\n elementIndex,\n this.lastIndex - reverseElementIndex,\n );\n }\n\n protected getElementMode(index = -1): string {\n return this.options.appearance({\n isActive: this.index === index,\n size: this.size,\n });\n }\n\n protected onElementClick(index: number): void {\n this.updateIndex(index);\n }\n\n protected onElementKeyDownArrowLeft(element: HTMLElement): void {\n if (element === this.els.first.nativeElement) {\n return;\n }\n\n const previous = this.els.find(\n (_, index, array) => array[index + 1]?.nativeElement === element,\n );\n\n previous?.nativeElement.focus();\n }\n\n protected onElementKeyDownArrowRight(element: HTMLElement): void {\n if (element === this.els.last.nativeElement) {\n return;\n }\n\n const next = this.els.find(\n (_, index, array) => array[index - 1]?.nativeElement === element,\n );\n\n next?.nativeElement.focus();\n }\n\n protected onArrowClick(direction: TuiHorizontalDirection): void {\n this.tryChangeTo(direction);\n this.focusActive();\n }\n\n /**\n * Active index from the end\n */\n private get reverseIndex(): number {\n return this.lastIndex - this.index;\n }\n\n /**\n * Max number of elements in half (not counting the middle one).\n */\n private get maxHalfLength(): number {\n return this.sidePadding + DOTS_LENGTH + this.activePadding;\n }\n\n /**\n * Is there '...' anywhere\n */\n private get itemsFit(): boolean {\n return this.length <= this.maxElementsLength;\n }\n\n /**\n * Max number of elements\n */\n private get maxElementsLength(): number {\n return this.maxHalfLength * 2 + ACTIVE_ITEM_LENGTH;\n }\n\n private get lastIndex(): number {\n return this.length - 1;\n }\n\n private get lastElementIndex(): number {\n return this.elementsLength - 1;\n }\n\n /**\n * Are there collapsed items at that index\n * @param index\n * @returns there are collapsed items\n */\n private hasCollapsedItems(index: number): boolean {\n return !this.itemsFit && index > this.maxHalfLength;\n }\n\n private tryChangeTo(direction: TuiHorizontalDirection): void {\n this.updateIndex(\n tuiClamp(this.index + (direction === 'right' ? 1 : -1), 0, this.lastIndex),\n );\n }\n\n private focusActive(): void {\n const {nativeFocusableElement} = this;\n\n if (nativeFocusableElement) {\n nativeFocusableElement.focus();\n }\n }\n\n private updateIndex(index: number): void {\n if (this.index === index) {\n return;\n }\n\n this.index = index;\n this.indexChange.emit(index);\n }\n}\n","<div class=\"t-content\">\n @if (size !== 's') {\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledLeft\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[0] }}\n </button>\n <ng-container *tuiRepeatTimes=\"let elementIndex of elementsLength\">\n @let index = getItemIndexByElementIndex(elementIndex);\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled\"\n [size]=\"buttonSize\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container *polymorpheusOutlet=\"content || index + 1 as text; context: {$implicit: index}\">\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-dots\"\n [class.t-dots_small]=\"size === 'm'\"\n ></div>\n }\n </ng-container>\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledRight\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[1] }}\n </button>\n } @else {\n <button\n *tuiRepeatTimes=\"let indexItem of length\"\n #element\n tuiButton\n type=\"button\"\n class=\"t-button t-button_small\"\n [appearance]=\"getElementMode(indexItem)\"\n [disabled]=\"disabled\"\n [tabIndex]=\"elementIsFocusable(indexItem) ? 0 : -1\"\n (click)=\"onElementClick(indexItem)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n {{ indexItem + 1 }}\n </button>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAYa,CAAC,sBAAsB,EAAE,4BAA4B,CAAC,GAC/D,gBAAgB,CAAuB;IACnC,UAAU,EAAE,CAAC,EAAC,QAAQ,EAAE,IAAI,EAAC,KAAI;AAC7B,QAAA,MAAM,QAAQ,GAAG,IAAI,KAAK,GAAG,GAAG,WAAW,GAAG,MAAM;QAEpD,OAAO,QAAQ,GAAG,SAAS,GAAG,QAAQ;KACzC;AACD,IAAA,WAAW,EAAE,GAAG;AACnB,CAAA;;ACUL,MAAM,WAAW,GAAG,CAAC;AACrB,MAAM,kBAAkB,GAAG,CAAC;MASf,aAAa,CAAA;AAP1B,IAAA,WAAA,GAAA;QASqB,IAAG,CAAA,GAAA,GAAuC,WAAW;QAErD,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAErB,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,oBAAoB,CAAC;AACpC,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,cAAc,CAAC;AAC9B,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,sBAAsB,CAAC;QAGpD,IAAM,CAAA,MAAA,GAAG,CAAC;QAGV,IAAS,CAAA,SAAA,GAAG,IAAI;AAGhB,QAAA,IAAA,CAAA,IAAI,GAAwB,IAAI,CAAC,OAAO,CAAC,WAAW;QAG3C,IAAQ,CAAA,QAAA,GAAG,KAAK;AAEhC;;AAEG;QAEI,IAAa,CAAA,aAAA,GAAG,CAAC;AAExB;;AAEG;QAEI,IAAW,CAAA,WAAA,GAAG,CAAC;AAQtB;;AAEG;QAEI,IAAK,CAAA,KAAA,GAAG,CAAC;AAGA,QAAA,IAAA,CAAA,WAAW,GAAG,IAAI,YAAY,EAAU;AA0M3D;AAxMG,IAAA,IAAW,sBAAsB,GAAA;AAC7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cdk/utils/miscellaneous';
4
4
 
5
5
  class Styles {
6
6
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: Styles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
7
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: Styles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-pin" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiPin]{--t-size: 2rem;transition-property:width,height,border,margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;inline-size:var(--t-size);block-size:var(--t-size);align-items:stretch;flex-direction:column;justify-content:center;text-align:center;border-radius:100%;font:var(--tui-font-text-s);font-weight:700;box-sizing:border-box;color:var(--tui-text-primary-on-accent-2);background:var(--tui-background-accent-2);box-shadow:0 0 0 .125rem var(--tui-background-elevation-2);border:0 solid var(--tui-background-accent-2);transform:translate(-50%,-50%)}[tuiPin]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:empty{--t-size: .75rem}[tuiPin]:empty:before{display:none}[tuiPin]>input{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;border-radius:100%}[tuiPin]>img{max-block-size:100%;box-sizing:border-box;border-radius:100%;background:var(--tui-background-base)}[tuiPin]>tui-icon{transition-property:width,height;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;font-size:1.25rem;align-self:center}[tuiPin]:has(:checked){--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]:has(:checked)>img{padding:.125rem}[tuiPin]:has(:checked)>tui-icon{font-size:2.125rem}[tuiPin]:has(:checked):before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]:has(:checked):after{top:4.5rem;opacity:1}[tuiPin]._open{--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]._open>img{padding:.125rem}[tuiPin]._open>tui-icon{font-size:2.125rem}[tuiPin]._open:before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]._open:after{top:4.5rem;opacity:1}[tuiPin]:before{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;right:-.25rem;bottom:-.625rem;box-sizing:border-box;border-width:2.2rem 2rem;border-style:solid;border-color:inherit;opacity:0;transform:scale(.57) translate(-1.875rem,-1.875rem);transform-origin:top left;pointer-events:none;mask:url('data:image/svg+xml,<svg width=\"60\" height=\"66\" viewBox=\"0 0 60 66\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 30.0917C0 13.4726 13.4313 0 30.0002 0C46.5687 0 60 13.4726 60 30.0917C60 44.2105 50.4927 56.0529 37.4162 59.2986C32.5552 60.5551 31.0408 65.275 31.0408 65.275C30.8892 65.697 30.4909 66 30.0183 66C29.5453 66 29.147 65.697 28.9938 65.275C28.9938 65.275 27.481 60.5551 22.6199 59.2986C9.46433 56.0206 0 43.5901 0 30.0917ZM30 57.75C45.3259 57.75 57.75 45.3259 57.75 30C57.75 14.6741 45.3259 2.25 30 2.25C14.6741 2.25 2.25 14.6741 2.25 30C2.25 45.3259 14.6741 57.75 30 57.75Z\" /></svg>') no-repeat}[tuiPin]:after{transition-property:top,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;border:.1875rem solid currentColor;border-color:inherit;border-radius:100%;box-sizing:border-box;box-shadow:inherit;transform:translate(-50%,-50%);opacity:0}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
7
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: Styles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-pin" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiPin]{--t-size: 2rem;transition-property:width,height,border,margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;inline-size:var(--t-size);block-size:var(--t-size);align-items:stretch;flex-direction:column;justify-content:center;text-align:center;border-radius:100%;font:var(--tui-font-text-s);font-weight:700;box-sizing:border-box;color:var(--tui-text-primary-on-accent-2);background:var(--tui-background-accent-2);box-shadow:0 0 0 .125rem var(--tui-background-elevation-2);border:0 solid var(--tui-background-accent-2);transform:translate(-50%,-50%)}[tuiPin]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:empty{--t-size: .75rem}[tuiPin]:empty:before{display:none}[tuiPin]>input{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;border-radius:100%}[tuiPin]>img{max-block-size:100%;box-sizing:border-box;border-radius:100%;background:var(--tui-background-base)}[tuiPin]>tui-icon{transition-property:width,height;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;font-size:1.25rem;align-self:center}[tuiPin]:has(:checked){--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]:has(:checked)>img{padding:.125rem}[tuiPin]:has(:checked)>tui-icon{font-size:2.125rem}[tuiPin]:has(:checked):before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]:has(:checked):after{top:4.5rem;opacity:1}[tuiPin]._open{--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]._open>img{padding:.125rem}[tuiPin]._open>tui-icon{font-size:2.125rem}[tuiPin]._open:before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]._open:after{top:4.5rem;opacity:1}[tuiPin]:before{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;right:-.25rem;bottom:-.625rem;box-sizing:border-box;border-width:2.2rem 2rem;border-style:solid;border-color:inherit;opacity:0;transform:scale(.57) translate(-1.875rem,-1.875rem);transform-origin:top left;pointer-events:none;mask:url('data:image/svg+xml,<svg width=\"60\" height=\"66\" viewBox=\"0 0 60 66\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 30.0917C0 13.4726 13.4313 0 30.0002 0C46.5687 0 60 13.4726 60 30.0917C60 44.2105 50.4927 56.0529 37.4162 59.2986C32.5552 60.5551 31.0408 65.275 31.0408 65.275C30.8892 65.697 30.4909 66 30.0183 66C29.5453 66 29.147 65.697 28.9938 65.275C28.9938 65.275 27.481 60.5551 22.6199 59.2986C9.46433 56.0206 0 43.5901 0 30.0917ZM30 57.75C45.3259 57.75 57.75 45.3259 57.75 30C57.75 14.6741 45.3259 2.25 30 2.25C14.6741 2.25 2.25 14.6741 2.25 30C2.25 45.3259 14.6741 57.75 30 57.75Z\" /></svg>') no-repeat}[tuiPin]:after{transition-property:top,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;border:.1875rem solid currentColor;border-color:inherit;border-radius:100%;box-sizing:border-box;box-shadow:inherit;transform:translate(-50%,-50%);opacity:0}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
8
8
  }
9
9
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: Styles, decorators: [{
10
10
  type: Component,
11
- args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'tui-pin' }, styles: ["[tuiPin]{--t-size: 2rem;transition-property:width,height,border,margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;inline-size:var(--t-size);block-size:var(--t-size);align-items:stretch;flex-direction:column;justify-content:center;text-align:center;border-radius:100%;font:var(--tui-font-text-s);font-weight:700;box-sizing:border-box;color:var(--tui-text-primary-on-accent-2);background:var(--tui-background-accent-2);box-shadow:0 0 0 .125rem var(--tui-background-elevation-2);border:0 solid var(--tui-background-accent-2);transform:translate(-50%,-50%)}[tuiPin]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:empty{--t-size: .75rem}[tuiPin]:empty:before{display:none}[tuiPin]>input{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;border-radius:100%}[tuiPin]>img{max-block-size:100%;box-sizing:border-box;border-radius:100%;background:var(--tui-background-base)}[tuiPin]>tui-icon{transition-property:width,height;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;font-size:1.25rem;align-self:center}[tuiPin]:has(:checked){--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]:has(:checked)>img{padding:.125rem}[tuiPin]:has(:checked)>tui-icon{font-size:2.125rem}[tuiPin]:has(:checked):before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]:has(:checked):after{top:4.5rem;opacity:1}[tuiPin]._open{--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]._open>img{padding:.125rem}[tuiPin]._open>tui-icon{font-size:2.125rem}[tuiPin]._open:before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]._open:after{top:4.5rem;opacity:1}[tuiPin]:before{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;right:-.25rem;bottom:-.625rem;box-sizing:border-box;border-width:2.2rem 2rem;border-style:solid;border-color:inherit;opacity:0;transform:scale(.57) translate(-1.875rem,-1.875rem);transform-origin:top left;pointer-events:none;mask:url('data:image/svg+xml,<svg width=\"60\" height=\"66\" viewBox=\"0 0 60 66\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 30.0917C0 13.4726 13.4313 0 30.0002 0C46.5687 0 60 13.4726 60 30.0917C60 44.2105 50.4927 56.0529 37.4162 59.2986C32.5552 60.5551 31.0408 65.275 31.0408 65.275C30.8892 65.697 30.4909 66 30.0183 66C29.5453 66 29.147 65.697 28.9938 65.275C28.9938 65.275 27.481 60.5551 22.6199 59.2986C9.46433 56.0206 0 43.5901 0 30.0917ZM30 57.75C45.3259 57.75 57.75 45.3259 57.75 30C57.75 14.6741 45.3259 2.25 30 2.25C14.6741 2.25 2.25 14.6741 2.25 30C2.25 45.3259 14.6741 57.75 30 57.75Z\" /></svg>') no-repeat}[tuiPin]:after{transition-property:top,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;border:.1875rem solid currentColor;border-color:inherit;border-radius:100%;box-sizing:border-box;box-shadow:inherit;transform:translate(-50%,-50%);opacity:0}\n"] }]
11
+ args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'tui-pin' }, styles: ["[tuiPin]{--t-size: 2rem;transition-property:width,height,border,margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;inline-size:var(--t-size);block-size:var(--t-size);align-items:stretch;flex-direction:column;justify-content:center;text-align:center;border-radius:100%;font:var(--tui-font-text-s);font-weight:700;box-sizing:border-box;color:var(--tui-text-primary-on-accent-2);background:var(--tui-background-accent-2);box-shadow:0 0 0 .125rem var(--tui-background-elevation-2);border:0 solid var(--tui-background-accent-2);transform:translate(-50%,-50%)}[tuiPin]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiPin]:empty{--t-size: .75rem}[tuiPin]:empty:before{display:none}[tuiPin]>input{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;border-radius:100%}[tuiPin]>img{max-block-size:100%;box-sizing:border-box;border-radius:100%;background:var(--tui-background-base)}[tuiPin]>tui-icon{transition-property:width,height;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;font-size:1.25rem;align-self:center}[tuiPin]:has(:checked){--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]:has(:checked)>img{padding:.125rem}[tuiPin]:has(:checked)>tui-icon{font-size:2.125rem}[tuiPin]:has(:checked):before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]:has(:checked):after{top:4.5rem;opacity:1}[tuiPin]._open{--t-size: 3.5rem;font:var(--tui-font-text-m);font-weight:700;border-width:0;margin-block-start:-2.75rem}[tuiPin]._open>img{padding:.125rem}[tuiPin]._open>tui-icon{font-size:2.125rem}[tuiPin]._open:before{transform:scale(.99) translate(-1.875rem,-1.875rem);opacity:1}[tuiPin]._open:after{top:4.5rem;opacity:1}[tuiPin]:before{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;right:-.25rem;bottom:-.625rem;box-sizing:border-box;border-width:2.2rem 2rem;border-style:solid;border-color:inherit;opacity:0;transform:scale(.57) translate(-1.875rem,-1.875rem);transform-origin:top left;pointer-events:none;mask:url('data:image/svg+xml,<svg width=\"60\" height=\"66\" viewBox=\"0 0 60 66\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0 30.0917C0 13.4726 13.4313 0 30.0002 0C46.5687 0 60 13.4726 60 30.0917C60 44.2105 50.4927 56.0529 37.4162 59.2986C32.5552 60.5551 31.0408 65.275 31.0408 65.275C30.8892 65.697 30.4909 66 30.0183 66C29.5453 66 29.147 65.697 28.9938 65.275C28.9938 65.275 27.481 60.5551 22.6199 59.2986C9.46433 56.0206 0 43.5901 0 30.0917ZM30 57.75C45.3259 57.75 57.75 45.3259 57.75 30C57.75 14.6741 45.3259 2.25 30 2.25C14.6741 2.25 2.25 14.6741 2.25 30C2.25 45.3259 14.6741 57.75 30 57.75Z\" /></svg>') no-repeat}[tuiPin]:after{transition-property:top,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;top:50%;left:50%;border:.1875rem solid currentColor;border-color:inherit;border-radius:100%;box-sizing:border-box;box-shadow:inherit;transform:translate(-50%,-50%);opacity:0}\n"] }]
12
12
  }] });
13
13
  class TuiPin {
14
14
  constructor() {
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-pin.mjs","sources":["../../../projects/kit/components/pin/pin.directive.ts","../../../projects/kit/components/pin/taiga-ui-kit-components-pin.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n template: '',\n styles: ['@import \"@taiga-ui/kit/styles/components/pin.less\";'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-pin'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiPin]',\n host: {\n tuiPin: '',\n '[class._open]': 'open()',\n },\n})\nexport class TuiPin {\n protected readonly nothing = tuiWithStyles(Styles);\n\n public readonly open = input<boolean | ''>('', {alias: 'tuiPin'});\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AASA,MAOM,MAAM,CAAA;+GAA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AAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,EAAA,UAAA,EAAA,EAAA,aAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAN,MAAM,EAAA,UAAA,EAAA,CAAA;kBAPlB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,UAAU;AACpB,oBAAA,IAAI,EAAE;AACF,wBAAA,MAAM,EAAE,EAAE;AACV,wBAAA,eAAe,EAAE,QAAQ;AAC5B,qBAAA;AACJ,iBAAA;;;ACxBD;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-kit-components-pin.mjs","sources":["../../../projects/kit/components/pin/pin.directive.ts","../../../projects/kit/components/pin/taiga-ui-kit-components-pin.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/pin.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-pin'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiPin]',\n host: {\n tuiPin: '',\n '[class._open]': 'open()',\n },\n})\nexport class TuiPin {\n protected readonly nothing = tuiWithStyles(Styles);\n\n public readonly open = input<boolean | ''>('', {alias: 'tuiPin'});\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AASA,MAOM,MAAM,CAAA;+GAAN,MAAM,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAN,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA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N,MAAM,EAAA,UAAA,EAAA,CAAA;kBAPlB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,UAAU;AACpB,oBAAA,IAAI,EAAE;AACF,wBAAA,MAAM,EAAE,EAAE;AACV,wBAAA,eAAe,EAAE,QAAQ;AAC5B,qBAAA;AACJ,iBAAA;;;ACxBD;;AAEG;;;;"}
@@ -3,9 +3,9 @@ import { ChangeDetectionStrategy, ViewEncapsulation, Component, Injectable, Dire
3
3
  import * as i1 from '@taiga-ui/cdk/directives/animated';
4
4
  import { TuiAnimated } from '@taiga-ui/cdk/directives/animated';
5
5
  import { injectContext, PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
6
- import { TuiPopoverDirective } from '@taiga-ui/cdk/directives/popover';
7
- import { TuiPopoverService, tuiAsPopover } from '@taiga-ui/cdk/services';
8
- import { TUI_DIALOGS } from '@taiga-ui/core/components/dialog';
6
+ import * as i1$1 from '@taiga-ui/cdk/portals';
7
+ import { tuiAsPortal, TuiPortalDirective } from '@taiga-ui/cdk/portals';
8
+ import { TuiModalService } from '@taiga-ui/core/components/modal';
9
9
 
10
10
  class TuiPreviewDialog {
11
11
  constructor() {
@@ -16,7 +16,7 @@ class TuiPreviewDialog {
16
16
  <ng-container *polymorpheusOutlet="context.content as text; context: context">
17
17
  {{ text }}
18
18
  </ng-container>
19
- `, isInline: true, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
19
+ `, isInline: true, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
20
20
  }
21
21
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialog, decorators: [{
22
22
  type: Component,
@@ -26,33 +26,41 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
26
26
  </ng-container>
27
27
  `, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiAnimated], host: {
28
28
  '(document:keydown.esc.prevent)': 'context.$implicit.complete()',
29
- }, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"] }]
29
+ }, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"] }]
30
30
  }] });
31
31
 
32
- class TuiPreviewDialogService extends TuiPopoverService {
32
+ class TuiPreviewDialogService extends TuiModalService {
33
+ constructor() {
34
+ super(...arguments);
35
+ this.options = {};
36
+ this.content = TuiPreviewDialog;
37
+ }
33
38
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
34
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, providedIn: 'root', useFactory: () => new TuiPreviewDialogService(TUI_DIALOGS, TuiPreviewDialog) }); }
39
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, providedIn: 'root' }); }
35
40
  }
36
41
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, decorators: [{
37
42
  type: Injectable,
38
43
  args: [{
39
44
  providedIn: 'root',
40
- useFactory: () => new TuiPreviewDialogService(TUI_DIALOGS, TuiPreviewDialog),
41
45
  }]
42
46
  }] });
43
47
 
44
- class TuiPreviewDialogDirective extends TuiPopoverDirective {
45
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
46
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewDialogDirective, isStandalone: true, selector: "ng-template[tuiPreviewDialog]", inputs: { open: ["tuiPreviewDialog", "open"] }, outputs: { openChange: "tuiPreviewDialogChange" }, providers: [tuiAsPopover(TuiPreviewDialogService)], usesInheritance: true, ngImport: i0 }); }
48
+ class TuiPreviewDialogDirective {
49
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
50
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewDialogDirective, isStandalone: true, selector: "ng-template[tuiPreviewDialog]", providers: [tuiAsPortal(TuiPreviewDialogService)], hostDirectives: [{ directive: i1$1.TuiPortalDirective, inputs: ["open", "tuiPreviewDialog"], outputs: ["openChange", "tuiPreviewDialogChange"] }], ngImport: i0 }); }
47
51
  }
48
52
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, decorators: [{
49
53
  type: Directive,
50
54
  args: [{
51
- standalone: true,
52
55
  selector: 'ng-template[tuiPreviewDialog]',
53
- inputs: ['open: tuiPreviewDialog'],
54
- outputs: ['openChange: tuiPreviewDialogChange'],
55
- providers: [tuiAsPopover(TuiPreviewDialogService)],
56
+ providers: [tuiAsPortal(TuiPreviewDialogService)],
57
+ hostDirectives: [
58
+ {
59
+ directive: TuiPortalDirective,
60
+ inputs: ['open: tuiPreviewDialog'],
61
+ outputs: ['openChange: tuiPreviewDialogChange'],
62
+ },
63
+ ],
56
64
  }]
57
65
  }] });
58
66
 
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-kit-components-preview-dialog.mjs","sources":["../../../projects/kit/components/preview/dialog/preview-dialog.component.ts","../../../projects/kit/components/preview/dialog/preview-dialog.service.ts","../../../projects/kit/components/preview/dialog/preview-dialog.directive.ts","../../../projects/kit/components/preview/dialog/taiga-ui-kit-components-preview-dialog.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, ViewEncapsulation} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPopover} from '@taiga-ui/cdk/services';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n selector: 'tui-preview-dialog',\n imports: [PolymorpheusOutlet],\n template: `\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n {{ text }}\n </ng-container>\n `,\n styleUrls: ['./preview-dialog.style.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated],\n host: {\n '(document:keydown.esc.prevent)': 'context.$implicit.complete()',\n },\n})\nexport class TuiPreviewDialog {\n protected readonly context = injectContext<TuiPopover<void, void>>();\n}\n","import {Injectable} from '@angular/core';\nimport {TuiPopoverService} from '@taiga-ui/cdk/services';\nimport {TUI_DIALOGS} from '@taiga-ui/core/components/dialog';\n\nimport {TuiPreviewDialog} from './preview-dialog.component';\n\n@Injectable({\n providedIn: 'root',\n useFactory: () => new TuiPreviewDialogService(TUI_DIALOGS, TuiPreviewDialog),\n})\nexport class TuiPreviewDialogService extends TuiPopoverService<unknown> {}\n","import {Directive} from '@angular/core';\nimport {TuiPopoverDirective} from '@taiga-ui/cdk/directives/popover';\nimport {tuiAsPopover} from '@taiga-ui/cdk/services';\n\nimport {TuiPreviewDialogService} from './preview-dialog.service';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiPreviewDialog]',\n inputs: ['open: tuiPreviewDialog'],\n outputs: ['openChange: tuiPreviewDialogChange'],\n providers: [tuiAsPopover(TuiPreviewDialogService)],\n})\nexport class TuiPreviewDialogDirective extends TuiPopoverDirective<unknown> {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAqBa,gBAAgB,CAAA;AAhB7B,IAAA,WAAA,GAAA;QAiBuB,IAAO,CAAA,OAAA,GAAG,aAAa,EAA0B;AACvE;+GAFY,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAhB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UA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view-dialog.mjs","sources":["../../../projects/kit/components/preview/dialog/preview-dialog.component.ts","../../../projects/kit/components/preview/dialog/preview-dialog.service.ts","../../../projects/kit/components/preview/dialog/preview-dialog.directive.ts","../../../projects/kit/components/preview/dialog/taiga-ui-kit-components-preview-dialog.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, ViewEncapsulation} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext} from '@taiga-ui/cdk/portals';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n selector: 'tui-preview-dialog',\n imports: [PolymorpheusOutlet],\n template: `\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n {{ text }}\n </ng-container>\n `,\n styleUrl: './preview-dialog.style.less',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated],\n host: {\n '(document:keydown.esc.prevent)': 'context.$implicit.complete()',\n },\n})\nexport class TuiPreviewDialog {\n protected readonly context = injectContext<TuiPortalContext<void>>();\n}\n","import {Injectable} from '@angular/core';\nimport {TuiModalService} from '@taiga-ui/core/components/modal';\n\nimport {TuiPreviewDialog} from './preview-dialog.component';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class TuiPreviewDialogService extends TuiModalService<unknown> {\n protected readonly options = {};\n protected readonly content = TuiPreviewDialog;\n}\n","import {Directive} from '@angular/core';\nimport {tuiAsPortal, TuiPortalDirective} from '@taiga-ui/cdk/portals';\n\nimport {TuiPreviewDialogService} from './preview-dialog.service';\n\n@Directive({\n selector: 'ng-template[tuiPreviewDialog]',\n providers: [tuiAsPortal(TuiPreviewDialogService)],\n hostDirectives: [\n {\n directive: TuiPortalDirective,\n inputs: ['open: tuiPreviewDialog'],\n outputs: ['openChange: tuiPreviewDialogChange'],\n },\n ],\n})\nexport class TuiPreviewDialogDirective {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n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QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FASxC,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAXrC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,+BAA+B;AACzC,oBAAA,SAAS,EAAE,CAAC,WAAW,CAAC,uBAAuB,CAAC,CAAC;AACjD,oBAAA,cAAc,EAAE;AACZ,wBAAA;AACI,4BAAA,SAAS,EAAE,kBAAkB;4BAC7B,MAAM,EAAE,CAAC,wBAAwB,CAAC;4BAClC,OAAO,EAAE,CAAC,oCAAoC,CAAC;AAClD,yBAAA;AACJ,qBAAA;AACJ,iBAAA;;;ACfD;;AAEG;;;;"}
@@ -4,12 +4,12 @@ import { tuiButtonOptionsProvider, TuiButton } from '@taiga-ui/core/components/b
4
4
  import * as i1 from '@taiga-ui/cdk/directives/animated';
5
5
  import { TuiAnimated } from '@taiga-ui/cdk/directives/animated';
6
6
  import { injectContext, PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
7
- import { TuiPopoverDirective } from '@taiga-ui/cdk/directives/popover';
8
- import { TuiPopoverService, tuiAsPopover } from '@taiga-ui/cdk/services';
9
- import { TUI_DIALOGS } from '@taiga-ui/core/components/dialog';
10
- import { AsyncPipe, PercentPipe } from '@angular/common';
7
+ import * as i1$1 from '@taiga-ui/cdk/portals';
8
+ import { tuiAsPortal, TuiPortalDirective } from '@taiga-ui/cdk/portals';
9
+ import { TuiModalService } from '@taiga-ui/core/components/modal';
11
10
  import { tuiClamp, tuiRound } from '@taiga-ui/cdk/utils/math';
12
11
  import { TUI_PREVIEW_ICONS, TUI_PAGINATION_TEXTS, TUI_PREVIEW_ZOOM_TEXTS, TUI_PREVIEW_TEXTS } from '@taiga-ui/kit/tokens';
12
+ import { AsyncPipe, PercentPipe } from '@angular/common';
13
13
  import { WaMutationObserver } from '@ng-web-apis/mutation-observer';
14
14
  import { WaResizeObserver } from '@ng-web-apis/resize-observer';
15
15
  import { TUI_FALSE_HANDLER } from '@taiga-ui/cdk/constants';
@@ -21,7 +21,7 @@ import { tuiPx } from '@taiga-ui/cdk/utils/miscellaneous';
21
21
  import * as i2 from '@taiga-ui/core/directives/hint';
22
22
  import { TuiHint } from '@taiga-ui/core/directives/hint';
23
23
  import { switchMap, merge, of, timer, map, startWith, BehaviorSubject, combineLatest } from 'rxjs';
24
- import * as i1$1 from '@angular/forms';
24
+ import * as i1$2 from '@angular/forms';
25
25
  import { FormsModule } from '@angular/forms';
26
26
  import * as i3 from '@taiga-ui/kit/components/slider';
27
27
  import { TuiSlider } from '@taiga-ui/kit/components/slider';
@@ -38,7 +38,6 @@ class TuiPreviewAction {
38
38
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewAction, decorators: [{
39
39
  type: Directive,
40
40
  args: [{
41
- standalone: true,
42
41
  selector: '[tuiPreviewAction]',
43
42
  providers: [
44
43
  tuiButtonOptionsProvider({
@@ -61,7 +60,7 @@ class TuiPreviewDialog {
61
60
  <ng-container *polymorpheusOutlet="context.content as text; context: context">
62
61
  {{ text }}
63
62
  </ng-container>
64
- `, isInline: true, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
63
+ `, isInline: true, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
65
64
  }
66
65
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialog, decorators: [{
67
66
  type: Component,
@@ -71,40 +70,48 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
71
70
  </ng-container>
72
71
  `, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiAnimated], host: {
73
72
  '(document:keydown.esc.prevent)': 'context.$implicit.complete()',
74
- }, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:matches(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not(:disabled):not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"] }]
73
+ }, styles: ["tui-preview-dialog{inline-size:100%;block-size:100%;overflow:hidden}tui-preview-dialog.tui-enter,tui-preview-dialog.tui-leave{animation-name:tuiFade,tuiSlide}[tuiAppearance][data-appearance=preview-action]{background:#686868f5;color:#fff}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):hover:not(:disabled):not([data-state]){background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action][data-state=hover]{background:#9f9f9fdb}@media (hover: hover) and (pointer: fine){[tuiAppearance][data-appearance=preview-action][tuiWrapper]:hover:not(._no-hover),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=hover]{background:#9f9f9fdb}}[tuiAppearance][data-appearance=preview-action]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled):active:not([data-state]){background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][data-state=active]{background:#9f9f9fbf}[tuiAppearance][data-appearance=preview-action][tuiWrapper]:active:not(._no-active),[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active],[tuiAppearance][data-appearance=preview-action][tuiWrapper][data-state=active]:hover{background:#9f9f9fbf}\n"] }]
75
74
  }] });
76
75
 
77
- class TuiPreviewDialogService extends TuiPopoverService {
76
+ class TuiPreviewDialogService extends TuiModalService {
77
+ constructor() {
78
+ super(...arguments);
79
+ this.options = {};
80
+ this.content = TuiPreviewDialog;
81
+ }
78
82
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
79
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, providedIn: 'root', useFactory: () => new TuiPreviewDialogService(TUI_DIALOGS, TuiPreviewDialog) }); }
83
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, providedIn: 'root' }); }
80
84
  }
81
85
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogService, decorators: [{
82
86
  type: Injectable,
83
87
  args: [{
84
88
  providedIn: 'root',
85
- useFactory: () => new TuiPreviewDialogService(TUI_DIALOGS, TuiPreviewDialog),
86
89
  }]
87
90
  }] });
88
91
 
89
- class TuiPreviewDialogDirective extends TuiPopoverDirective {
90
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
91
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewDialogDirective, isStandalone: true, selector: "ng-template[tuiPreviewDialog]", inputs: { open: ["tuiPreviewDialog", "open"] }, outputs: { openChange: "tuiPreviewDialogChange" }, providers: [tuiAsPopover(TuiPreviewDialogService)], usesInheritance: true, ngImport: i0 }); }
92
+ class TuiPreviewDialogDirective {
93
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
94
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewDialogDirective, isStandalone: true, selector: "ng-template[tuiPreviewDialog]", providers: [tuiAsPortal(TuiPreviewDialogService)], hostDirectives: [{ directive: i1$1.TuiPortalDirective, inputs: ["open", "tuiPreviewDialog"], outputs: ["openChange", "tuiPreviewDialogChange"] }], ngImport: i0 }); }
92
95
  }
93
96
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewDialogDirective, decorators: [{
94
97
  type: Directive,
95
98
  args: [{
96
- standalone: true,
97
99
  selector: 'ng-template[tuiPreviewDialog]',
98
- inputs: ['open: tuiPreviewDialog'],
99
- outputs: ['openChange: tuiPreviewDialogChange'],
100
- providers: [tuiAsPopover(TuiPreviewDialogService)],
100
+ providers: [tuiAsPortal(TuiPreviewDialogService)],
101
+ hostDirectives: [
102
+ {
103
+ directive: TuiPortalDirective,
104
+ inputs: ['open: tuiPreviewDialog'],
105
+ outputs: ['openChange: tuiPreviewDialogChange'],
106
+ },
107
+ ],
101
108
  }]
102
109
  }] });
103
110
 
104
111
  class TuiPreviewPagination {
105
112
  constructor() {
106
113
  this.icons = inject(TUI_PREVIEW_ICONS);
107
- this.texts$ = inject(TUI_PAGINATION_TEXTS);
114
+ this.paginationTexts = inject(TUI_PAGINATION_TEXTS);
108
115
  this.length = 1;
109
116
  this.index = 0;
110
117
  this.indexChange = new EventEmitter();
@@ -126,14 +133,14 @@ class TuiPreviewPagination {
126
133
  this.indexChange.emit(index);
127
134
  }
128
135
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewPagination, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
129
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPreviewPagination, isStandalone: true, selector: "tui-preview-pagination", inputs: { length: "length", index: "index" }, outputs: { indexChange: "indexChange" }, host: { listeners: { "document:keydown.arrowRight.prevent": "onArrowClick(1)", "document:keydown.arrowLeft.prevent": "onArrowClick(-1)" } }, ngImport: i0, template: "@if (texts$ | async; as texts) {\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_left\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.prev\"\n (click)=\"onArrowClick(-1)\"\n >\n {{ texts[0] }}\n </button>\n {{ index + 1 }}/{{ length }}\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_right\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.next\"\n (click)=\"onArrowClick(1)\"\n >\n {{ texts[1] }}\n </button>\n}\n", styles: [":host{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:6.25rem}.t-arrow{transform:scaleX(var(--tui-inline))}.t-arrow_left{border-top-right-radius:0;border-bottom-right-radius:0}.t-arrow_right{border-top-left-radius:0;border-bottom-left-radius:0}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
136
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewPagination, isStandalone: true, selector: "tui-preview-pagination", inputs: { length: "length", index: "index" }, outputs: { indexChange: "indexChange" }, host: { listeners: { "document:keydown.arrowRight.prevent": "onArrowClick(1)", "document:keydown.arrowLeft.prevent": "onArrowClick(-1)" } }, ngImport: i0, template: "@let texts = paginationTexts();\n<button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_left\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.prev\"\n (click)=\"onArrowClick(-1)\"\n>\n {{ texts[0] }}\n</button>\n{{ index + 1 }}/{{ length }}\n<button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_right\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.next\"\n (click)=\"onArrowClick(1)\"\n>\n {{ texts[1] }}\n</button>\n", styles: [":host{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:6.25rem}.t-arrow{transform:scaleX(var(--tui-inline))}.t-arrow_left{border-top-right-radius:0;border-bottom-right-radius:0}.t-arrow_right{border-top-left-radius:0;border-bottom-left-radius:0}\n"], dependencies: [{ kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
130
137
  }
131
138
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewPagination, decorators: [{
132
139
  type: Component,
133
- args: [{ selector: 'tui-preview-pagination', imports: [AsyncPipe, TuiButton, TuiPreviewAction], changeDetection: ChangeDetectionStrategy.OnPush, host: {
140
+ args: [{ selector: 'tui-preview-pagination', imports: [TuiButton, TuiPreviewAction], changeDetection: ChangeDetectionStrategy.OnPush, host: {
134
141
  '(document:keydown.arrowRight.prevent)': 'onArrowClick(1)',
135
142
  '(document:keydown.arrowLeft.prevent)': 'onArrowClick(-1)',
136
- }, template: "@if (texts$ | async; as texts) {\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_left\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.prev\"\n (click)=\"onArrowClick(-1)\"\n >\n {{ texts[0] }}\n </button>\n {{ index + 1 }}/{{ length }}\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_right\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.next\"\n (click)=\"onArrowClick(1)\"\n >\n {{ texts[1] }}\n </button>\n}\n", styles: [":host{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:6.25rem}.t-arrow{transform:scaleX(var(--tui-inline))}.t-arrow_left{border-top-right-radius:0;border-bottom-right-radius:0}.t-arrow_right{border-top-left-radius:0;border-bottom-left-radius:0}\n"] }]
143
+ }, template: "@let texts = paginationTexts();\n<button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_left\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.prev\"\n (click)=\"onArrowClick(-1)\"\n>\n {{ texts[0] }}\n</button>\n{{ index + 1 }}/{{ length }}\n<button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-arrow t-arrow_right\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.next\"\n (click)=\"onArrowClick(1)\"\n>\n {{ texts[1] }}\n</button>\n", styles: [":host{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:6.25rem}.t-arrow{transform:scaleX(var(--tui-inline))}.t-arrow_left{border-top-right-radius:0;border-bottom-right-radius:0}.t-arrow_right{border-top-left-radius:0;border-bottom-left-radius:0}\n"] }]
137
144
  }], propDecorators: { length: [{
138
145
  type: Input
139
146
  }], index: [{
@@ -146,7 +153,7 @@ const STEP = 0.5;
146
153
  class TuiPreviewZoom {
147
154
  constructor() {
148
155
  this.icons = inject(TUI_PREVIEW_ICONS);
149
- this.zoomTexts$ = inject(TUI_PREVIEW_ZOOM_TEXTS);
156
+ this.zoomTexts = inject(TUI_PREVIEW_ZOOM_TEXTS);
150
157
  this.min = 0.5;
151
158
  this.max = 2;
152
159
  this.value = 1;
@@ -181,7 +188,7 @@ class TuiPreviewZoom {
181
188
  this.onModelChange(this.value < 1 ? 1 : this.value + STEP);
182
189
  }
183
190
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewZoom, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
184
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPreviewZoom, isStandalone: true, selector: "tui-preview-zoom", inputs: { min: "min", max: "max", value: "value" }, outputs: { valueChange: "valueChange", reset: "reset" }, ngImport: i0, template: "@if (zoomTexts$ | async; as texts) {\n <section class=\"t-zoom\">\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_minus\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.zoomOut\"\n (click)=\"onMinus()\"\n >\n {{ texts.zoomOut }}\n </button>\n <label tuiSliderThumbLabel>\n <div\n [tuiHint]=\"hint\"\n [tuiHintManual]=\"!!(hintShow$ | async)\"\n ></div>\n <ng-template #hint>\n {{ (valueChange | async) || value | percent }}\n </ng-template>\n <input\n step=\"any\"\n tuiSlider\n tuiTheme=\"dark\"\n type=\"range\"\n class=\"t-slider\"\n [max]=\"max\"\n [min]=\"min\"\n [ngModel]=\"value\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"onModelChange($event)\"\n />\n </label>\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_plus\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.zoomIn\"\n (click)=\"onPlus()\"\n >\n {{ texts.zoomIn }}\n </button>\n </section>\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-reset-button\"\n [class.t-invisible]=\"!collapseVisible\"\n [iconStart]=\"icons.zoomReset\"\n [tuiHint]=\"texts.reset\"\n (click)=\"onReset()\"\n ></button>\n}\n", styles: [":host{position:relative;display:flex}.t-zoom{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:12rem}.t-slider{inline-size:7.5rem}.t-sign_minus{border-top-right-radius:0;border-bottom-right-radius:0}.t-sign_plus{border-top-left-radius:0;border-bottom-left-radius:0}.t-invisible{visibility:hidden}.t-reset-button{margin-inline-start:.3125rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.RangeValueAccessor, selector: "input[type=range][formControlName],input[type=range][formControl],input[type=range][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: PercentPipe, name: "percent" }, { 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: ["tuiHintContext", "tuiHintAppearance", "tuiHint"], outputs: ["tuiHintVisible"] }, { kind: "directive", type: i2.TuiHintDescribe, selector: "[tuiHintDescribe]", inputs: ["tuiHintDescribe"] }, { kind: "directive", type: i2.TuiHintManual, selector: "[tuiHint][tuiHintManual]", inputs: ["tuiHintManual"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }, { kind: "component", type: i3.TuiSliderComponent, selector: "input[type=range][tuiSlider]", inputs: ["size", "segments"] }, { kind: "component", type: i3.TuiSliderThumbLabel, selector: "[tuiSliderThumbLabel]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
191
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiPreviewZoom, isStandalone: true, selector: "tui-preview-zoom", inputs: { min: "min", max: "max", value: "value" }, outputs: { valueChange: "valueChange", reset: "reset" }, ngImport: i0, template: "@let texts = zoomTexts();\n<section class=\"t-zoom\">\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_minus\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.zoomOut\"\n (click)=\"onMinus()\"\n >\n {{ texts.zoomOut }}\n </button>\n <label tuiSliderThumbLabel>\n <div\n [tuiHint]=\"hint\"\n [tuiHintManual]=\"!!(hintShow$ | async)\"\n ></div>\n <ng-template #hint>\n {{ (valueChange | async) || value | percent }}\n </ng-template>\n <input\n step=\"any\"\n tuiSlider\n tuiTheme=\"dark\"\n type=\"range\"\n class=\"t-slider\"\n [max]=\"max\"\n [min]=\"min\"\n [ngModel]=\"value\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"onModelChange($event)\"\n />\n </label>\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_plus\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.zoomIn\"\n (click)=\"onPlus()\"\n >\n {{ texts.zoomIn }}\n </button>\n</section>\n<button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-reset-button\"\n [class.t-invisible]=\"!collapseVisible\"\n [iconStart]=\"icons.zoomReset\"\n [tuiHint]=\"texts.reset\"\n (click)=\"onReset()\"\n></button>\n", styles: [":host{position:relative;display:flex}.t-zoom{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:12rem}.t-slider{inline-size:7.5rem}.t-sign_minus{border-top-right-radius:0;border-bottom-right-radius:0}.t-sign_plus{border-top-left-radius:0;border-bottom-left-radius:0}.t-invisible{visibility:hidden}.t-reset-button{margin-inline-start:.3125rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.RangeValueAccessor, selector: "input[type=range][formControlName],input[type=range][formControl],input[type=range][ngModel]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: PercentPipe, name: "percent" }, { 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.TuiHintDescribe, selector: "[tuiHintDescribe]", inputs: ["tuiHintDescribe"] }, { kind: "directive", type: i2.TuiHintManual, selector: "[tuiHint][tuiHintManual]", inputs: ["tuiHintManual"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }, { kind: "component", type: i3.TuiSliderComponent, selector: "input[type=range][tuiSlider]", inputs: ["size", "segments"] }, { kind: "component", type: i3.TuiSliderThumbLabel, selector: "[tuiSliderThumbLabel]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
185
192
  }
186
193
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewZoom, decorators: [{
187
194
  type: Component,
@@ -193,7 +200,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
193
200
  TuiHint,
194
201
  TuiPreviewAction,
195
202
  TuiSlider,
196
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (zoomTexts$ | async; as texts) {\n <section class=\"t-zoom\">\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_minus\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.zoomOut\"\n (click)=\"onMinus()\"\n >\n {{ texts.zoomOut }}\n </button>\n <label tuiSliderThumbLabel>\n <div\n [tuiHint]=\"hint\"\n [tuiHintManual]=\"!!(hintShow$ | async)\"\n ></div>\n <ng-template #hint>\n {{ (valueChange | async) || value | percent }}\n </ng-template>\n <input\n step=\"any\"\n tuiSlider\n tuiTheme=\"dark\"\n type=\"range\"\n class=\"t-slider\"\n [max]=\"max\"\n [min]=\"min\"\n [ngModel]=\"value\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"onModelChange($event)\"\n />\n </label>\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_plus\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.zoomIn\"\n (click)=\"onPlus()\"\n >\n {{ texts.zoomIn }}\n </button>\n </section>\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-reset-button\"\n [class.t-invisible]=\"!collapseVisible\"\n [iconStart]=\"icons.zoomReset\"\n [tuiHint]=\"texts.reset\"\n (click)=\"onReset()\"\n ></button>\n}\n", styles: [":host{position:relative;display:flex}.t-zoom{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:12rem}.t-slider{inline-size:7.5rem}.t-sign_minus{border-top-right-radius:0;border-bottom-right-radius:0}.t-sign_plus{border-top-left-radius:0;border-bottom-left-radius:0}.t-invisible{visibility:hidden}.t-reset-button{margin-inline-start:.3125rem}\n"] }]
203
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let texts = zoomTexts();\n<section class=\"t-zoom\">\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_minus\"\n [disabled]=\"leftButtonDisabled\"\n [iconStart]=\"icons.zoomOut\"\n (click)=\"onMinus()\"\n >\n {{ texts.zoomOut }}\n </button>\n <label tuiSliderThumbLabel>\n <div\n [tuiHint]=\"hint\"\n [tuiHintManual]=\"!!(hintShow$ | async)\"\n ></div>\n <ng-template #hint>\n {{ (valueChange | async) || value | percent }}\n </ng-template>\n <input\n step=\"any\"\n tuiSlider\n tuiTheme=\"dark\"\n type=\"range\"\n class=\"t-slider\"\n [max]=\"max\"\n [min]=\"min\"\n [ngModel]=\"value\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"onModelChange($event)\"\n />\n </label>\n <button\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-sign_plus\"\n [disabled]=\"rightButtonDisabled\"\n [iconStart]=\"icons.zoomIn\"\n (click)=\"onPlus()\"\n >\n {{ texts.zoomIn }}\n </button>\n</section>\n<button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-reset-button\"\n [class.t-invisible]=\"!collapseVisible\"\n [iconStart]=\"icons.zoomReset\"\n [tuiHint]=\"texts.reset\"\n (click)=\"onReset()\"\n></button>\n", styles: [":host{position:relative;display:flex}.t-zoom{border-radius:1rem;background:#686868f5;color:#fff;display:flex;font:var(--tui-font-text-s);justify-content:space-between;align-items:center;inline-size:12rem}.t-slider{inline-size:7.5rem}.t-sign_minus{border-top-right-radius:0;border-bottom-right-radius:0}.t-sign_plus{border-top-left-radius:0;border-bottom-left-radius:0}.t-invisible{visibility:hidden}.t-reset-button{margin-inline-start:.3125rem}\n"] }]
197
204
  }], propDecorators: { min: [{
198
205
  type: Input
199
206
  }], max: [{
@@ -214,7 +221,7 @@ class TuiPreviewComponent {
214
221
  this.minZoom = 1;
215
222
  this.width = 0;
216
223
  this.height = 0;
217
- this.texts$ = inject(TUI_PREVIEW_TEXTS);
224
+ this.previewTexts = inject(TUI_PREVIEW_TEXTS);
218
225
  this.icons = inject(TUI_PREVIEW_ICONS);
219
226
  this.cdr = inject(ChangeDetectorRef);
220
227
  this.zoom$ = new BehaviorSubject(this.minZoom);
@@ -304,7 +311,7 @@ class TuiPreviewComponent {
304
311
  ];
305
312
  }
306
313
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
307
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPreviewComponent, isStandalone: true, selector: "tui-preview", inputs: { zoomable: "zoomable", rotatable: "rotatable", initialScale: "initialScale" }, ngImport: i0, template: "@if (texts$ | async; as texts) {\n <section\n #contentWrapper\n attributeFilter=\"src\"\n characterData\n childList\n subtree\n class=\"t-wrapper\"\n [class.t-not-interactive-content]=\"zoomable\"\n [class.t-transitive]=\"transitioned$ | async\"\n [style.cursor]=\"cursor$ | async\"\n [style.transform]=\"wrapperTransform$ | async\"\n (tuiPan)=\"onPan($event)\"\n (tuiZoom)=\"onZoom($event)\"\n (waMutationObserver)=\"onMutation(contentWrapper)\"\n (waResizeObserver)=\"onResize($event)\"\n >\n <ng-content />\n </section>\n <header class=\"t-header\">\n <div class=\"t-title\">\n <ng-content select=\"tui-preview-title\" />\n </div>\n <ng-content select=\"tui-preview-pagination\" />\n <div class=\"t-actions\">\n <ng-content select=\"[tuiPreviewAction]\" />\n </div>\n </header>\n <footer class=\"t-footer\">\n @if (rotatable) {\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-rotate-button\"\n [iconStart]=\"icons.rotate\"\n [tuiHint]=\"texts.rotate\"\n (click)=\"rotate()\"\n ></button>\n }\n @if (zoomable) {\n <tui-preview-zoom\n [min]=\"minZoom\"\n [value]=\"(zoom$ | async) || 1\"\n (reset)=\"reset()\"\n (valueChange)=\"setZoom($event)\"\n />\n }\n </footer>\n}\n", styles: [":host{position:relative;display:flex;justify-content:center;align-items:center;inline-size:100%;block-size:100%;-webkit-user-select:none;user-select:none}.t-header{position:fixed;top:max(1rem,env(safe-area-inset-top));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box}.t-footer{position:absolute;bottom:max(1rem,env(safe-area-inset-bottom));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box;justify-content:center}.t-actions{display:flex;flex:1;justify-content:flex-end}.t-actions ::ng-deep>*{margin-inline-start:.625rem}.t-rotate-button{margin-inline-end:.3125rem}.t-title{flex:1}:host-context(tui-root._mobile) .t-title{display:none}.t-not-interactive-content ::ng-deep>*{pointer-events:none}.t-wrapper{will-change:transform}.t-transitive{transition-duration:.3s}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { 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: ["tuiHintContext", "tuiHintAppearance", "tuiHint"], outputs: ["tuiHintVisible"] }, { kind: "directive", type: i2.TuiHintDescribe, selector: "[tuiHintDescribe]", inputs: ["tuiHintDescribe"] }, { kind: "directive", type: TuiPan, selector: "[tuiPan]", outputs: ["tuiPan"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }, { kind: "component", type: TuiPreviewZoom, selector: "tui-preview-zoom", inputs: ["min", "max", "value"], outputs: ["valueChange", "reset"] }, { kind: "directive", type: TuiZoom, selector: "[tuiZoom]", outputs: ["tuiZoom"] }, { kind: "directive", type: WaMutationObserver, selector: "[waMutationObserver]", inputs: ["attributeFilter", "attributeOldValue", "attributes", "characterData", "characterDataOldValue", "childList", "subtree"], outputs: ["waMutationObserver"], exportAs: ["MutationObserver"] }, { kind: "directive", type: WaResizeObserver, selector: "[waResizeObserver]", inputs: ["box"], outputs: ["waResizeObserver"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
314
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPreviewComponent, isStandalone: true, selector: "tui-preview", inputs: { zoomable: "zoomable", rotatable: "rotatable", initialScale: "initialScale" }, ngImport: i0, template: "@let texts = previewTexts();\n<section\n #contentWrapper\n attributeFilter=\"src\"\n characterData\n childList\n subtree\n class=\"t-wrapper\"\n [class.t-not-interactive-content]=\"zoomable\"\n [class.t-transitive]=\"transitioned$ | async\"\n [style.cursor]=\"cursor$ | async\"\n [style.transform]=\"wrapperTransform$ | async\"\n (tuiPan)=\"onPan($event)\"\n (tuiZoom)=\"onZoom($event)\"\n (waMutationObserver)=\"onMutation(contentWrapper)\"\n (waResizeObserver)=\"onResize($event)\"\n>\n <ng-content />\n</section>\n<header class=\"t-header\">\n <div class=\"t-title\">\n <ng-content select=\"tui-preview-title\" />\n </div>\n <ng-content select=\"tui-preview-pagination\" />\n <div class=\"t-actions\">\n <ng-content select=\"[tuiPreviewAction]\" />\n </div>\n</header>\n<footer class=\"t-footer\">\n @if (rotatable) {\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-rotate-button\"\n [iconStart]=\"icons.rotate\"\n [tuiHint]=\"texts.rotate\"\n (click)=\"rotate()\"\n ></button>\n }\n @if (zoomable) {\n <tui-preview-zoom\n [min]=\"minZoom\"\n [value]=\"(zoom$ | async) || 1\"\n (reset)=\"reset()\"\n (valueChange)=\"setZoom($event)\"\n />\n }\n</footer>\n", styles: [":host{position:relative;display:flex;justify-content:center;align-items:center;inline-size:100%;block-size:100%;-webkit-user-select:none;user-select:none}.t-header{position:fixed;top:max(1rem,env(safe-area-inset-top));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box}.t-footer{position:absolute;bottom:max(1rem,env(safe-area-inset-bottom));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box;justify-content:center}.t-actions{display:flex;flex:1;justify-content:flex-end}.t-actions ::ng-deep>*{margin-inline-start:.625rem}.t-rotate-button{margin-inline-end:.3125rem}.t-title{flex:1}:host-context(tui-root._mobile) .t-title{display:none}.t-not-interactive-content ::ng-deep>*{pointer-events:none}.t-wrapper{will-change:transform}.t-transitive{transition-duration:.3s}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { 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.TuiHintDescribe, selector: "[tuiHintDescribe]", inputs: ["tuiHintDescribe"] }, { kind: "directive", type: TuiPan, selector: "[tuiPan]", outputs: ["tuiPan"] }, { kind: "directive", type: TuiPreviewAction, selector: "[tuiPreviewAction]" }, { kind: "component", type: TuiPreviewZoom, selector: "tui-preview-zoom", inputs: ["min", "max", "value"], outputs: ["valueChange", "reset"] }, { kind: "directive", type: TuiZoom, selector: "[tuiZoom]", outputs: ["tuiZoom"] }, { kind: "directive", type: WaMutationObserver, selector: "[waMutationObserver]", inputs: ["attributeFilter", "attributeOldValue", "attributes", "characterData", "characterDataOldValue", "childList", "subtree"], outputs: ["waMutationObserver"], exportAs: ["MutationObserver"] }, { kind: "directive", type: WaResizeObserver, selector: "[waResizeObserver]", inputs: ["box"], outputs: ["waResizeObserver"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
308
315
  }
309
316
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewComponent, decorators: [{
310
317
  type: Component,
@@ -318,7 +325,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
318
325
  TuiZoom,
319
326
  WaMutationObserver,
320
327
  WaResizeObserver,
321
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (texts$ | async; as texts) {\n <section\n #contentWrapper\n attributeFilter=\"src\"\n characterData\n childList\n subtree\n class=\"t-wrapper\"\n [class.t-not-interactive-content]=\"zoomable\"\n [class.t-transitive]=\"transitioned$ | async\"\n [style.cursor]=\"cursor$ | async\"\n [style.transform]=\"wrapperTransform$ | async\"\n (tuiPan)=\"onPan($event)\"\n (tuiZoom)=\"onZoom($event)\"\n (waMutationObserver)=\"onMutation(contentWrapper)\"\n (waResizeObserver)=\"onResize($event)\"\n >\n <ng-content />\n </section>\n <header class=\"t-header\">\n <div class=\"t-title\">\n <ng-content select=\"tui-preview-title\" />\n </div>\n <ng-content select=\"tui-preview-pagination\" />\n <div class=\"t-actions\">\n <ng-content select=\"[tuiPreviewAction]\" />\n </div>\n </header>\n <footer class=\"t-footer\">\n @if (rotatable) {\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-rotate-button\"\n [iconStart]=\"icons.rotate\"\n [tuiHint]=\"texts.rotate\"\n (click)=\"rotate()\"\n ></button>\n }\n @if (zoomable) {\n <tui-preview-zoom\n [min]=\"minZoom\"\n [value]=\"(zoom$ | async) || 1\"\n (reset)=\"reset()\"\n (valueChange)=\"setZoom($event)\"\n />\n }\n </footer>\n}\n", styles: [":host{position:relative;display:flex;justify-content:center;align-items:center;inline-size:100%;block-size:100%;-webkit-user-select:none;user-select:none}.t-header{position:fixed;top:max(1rem,env(safe-area-inset-top));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box}.t-footer{position:absolute;bottom:max(1rem,env(safe-area-inset-bottom));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box;justify-content:center}.t-actions{display:flex;flex:1;justify-content:flex-end}.t-actions ::ng-deep>*{margin-inline-start:.625rem}.t-rotate-button{margin-inline-end:.3125rem}.t-title{flex:1}:host-context(tui-root._mobile) .t-title{display:none}.t-not-interactive-content ::ng-deep>*{pointer-events:none}.t-wrapper{will-change:transform}.t-transitive{transition-duration:.3s}\n"] }]
328
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let texts = previewTexts();\n<section\n #contentWrapper\n attributeFilter=\"src\"\n characterData\n childList\n subtree\n class=\"t-wrapper\"\n [class.t-not-interactive-content]=\"zoomable\"\n [class.t-transitive]=\"transitioned$ | async\"\n [style.cursor]=\"cursor$ | async\"\n [style.transform]=\"wrapperTransform$ | async\"\n (tuiPan)=\"onPan($event)\"\n (tuiZoom)=\"onZoom($event)\"\n (waMutationObserver)=\"onMutation(contentWrapper)\"\n (waResizeObserver)=\"onResize($event)\"\n>\n <ng-content />\n</section>\n<header class=\"t-header\">\n <div class=\"t-title\">\n <ng-content select=\"tui-preview-title\" />\n </div>\n <ng-content select=\"tui-preview-pagination\" />\n <div class=\"t-actions\">\n <ng-content select=\"[tuiPreviewAction]\" />\n </div>\n</header>\n<footer class=\"t-footer\">\n @if (rotatable) {\n <button\n tuiHintAppearance=\"dark\"\n tuiHintDescribe\n tuiHintDirection=\"top-right\"\n tuiIconButton\n tuiPreviewAction\n type=\"button\"\n class=\"t-rotate-button\"\n [iconStart]=\"icons.rotate\"\n [tuiHint]=\"texts.rotate\"\n (click)=\"rotate()\"\n ></button>\n }\n @if (zoomable) {\n <tui-preview-zoom\n [min]=\"minZoom\"\n [value]=\"(zoom$ | async) || 1\"\n (reset)=\"reset()\"\n (valueChange)=\"setZoom($event)\"\n />\n }\n</footer>\n", styles: [":host{position:relative;display:flex;justify-content:center;align-items:center;inline-size:100%;block-size:100%;-webkit-user-select:none;user-select:none}.t-header{position:fixed;top:max(1rem,env(safe-area-inset-top));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box}.t-footer{position:absolute;bottom:max(1rem,env(safe-area-inset-bottom));display:flex;inline-size:100%;padding:0 1rem;box-sizing:border-box;justify-content:center}.t-actions{display:flex;flex:1;justify-content:flex-end}.t-actions ::ng-deep>*{margin-inline-start:.625rem}.t-rotate-button{margin-inline-end:.3125rem}.t-title{flex:1}:host-context(tui-root._mobile) .t-title{display:none}.t-not-interactive-content ::ng-deep>*{pointer-events:none}.t-wrapper{will-change:transform}.t-transitive{transition-duration:.3s}\n"] }]
322
329
  }], propDecorators: { zoomable: [{
323
330
  type: Input
324
331
  }], rotatable: [{
@@ -335,7 +342,7 @@ class TuiPreviewTitle {
335
342
  }
336
343
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPreviewTitle, decorators: [{
337
344
  type: Component,
338
- args: [{ standalone: true, selector: 'tui-preview-title', template: `
345
+ args: [{ selector: 'tui-preview-title', template: `
339
346
  <ng-content />
340
347
  `, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{border-radius:1rem;background:#686868f5;color:#fff;display:inline-block;font:var(--tui-font-text-s);padding:.375rem .75rem}\n"] }]
341
348
  }] });