@taiga-ui/core 2.20.0 → 2.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (456) hide show
  1. package/README.md +7 -3
  2. package/abstract/abstract-hint.d.ts +3 -1
  3. package/abstract/taiga-ui-core-abstract.metadata.json +1 -1
  4. package/bundles/taiga-ui-core-abstract.umd.js +4 -2
  5. package/bundles/taiga-ui-core-abstract.umd.js.map +1 -1
  6. package/bundles/taiga-ui-core-abstract.umd.min.js +1 -1
  7. package/bundles/taiga-ui-core-abstract.umd.min.js.map +1 -1
  8. package/bundles/taiga-ui-core-components-button.umd.js +21 -7
  9. package/bundles/taiga-ui-core-components-button.umd.js.map +1 -1
  10. package/bundles/taiga-ui-core-components-button.umd.min.js +1 -1
  11. package/bundles/taiga-ui-core-components-button.umd.min.js.map +1 -1
  12. package/bundles/taiga-ui-core-components-calendar.umd.js +1 -1
  13. package/bundles/taiga-ui-core-components-calendar.umd.js.map +1 -1
  14. package/bundles/taiga-ui-core-components-calendar.umd.min.js +1 -1
  15. package/bundles/taiga-ui-core-components-calendar.umd.min.js.map +1 -1
  16. package/bundles/taiga-ui-core-components-data-list.umd.js +6 -5
  17. package/bundles/taiga-ui-core-components-data-list.umd.js.map +1 -1
  18. package/bundles/taiga-ui-core-components-data-list.umd.min.js +2 -2
  19. package/bundles/taiga-ui-core-components-data-list.umd.min.js.map +1 -1
  20. package/bundles/taiga-ui-core-components-dialog.umd.js +2 -2
  21. package/bundles/taiga-ui-core-components-dialog.umd.js.map +1 -1
  22. package/bundles/taiga-ui-core-components-dialog.umd.min.js +1 -1
  23. package/bundles/taiga-ui-core-components-dialog.umd.min.js.map +1 -1
  24. package/bundles/taiga-ui-core-components-dropdown-box.umd.js +1 -1
  25. package/bundles/taiga-ui-core-components-dropdown-box.umd.min.js +1 -1
  26. package/bundles/taiga-ui-core-components-error.umd.js +1 -1
  27. package/bundles/taiga-ui-core-components-error.umd.min.js +1 -1
  28. package/bundles/taiga-ui-core-components-expand.umd.js +3 -2
  29. package/bundles/taiga-ui-core-components-expand.umd.js.map +1 -1
  30. package/bundles/taiga-ui-core-components-expand.umd.min.js +1 -1
  31. package/bundles/taiga-ui-core-components-expand.umd.min.js.map +1 -1
  32. package/bundles/taiga-ui-core-components-hints-host.umd.js +11 -5
  33. package/bundles/taiga-ui-core-components-hints-host.umd.js.map +1 -1
  34. package/bundles/taiga-ui-core-components-hints-host.umd.min.js +1 -1
  35. package/bundles/taiga-ui-core-components-hints-host.umd.min.js.map +1 -1
  36. package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js +2 -15
  37. package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js.map +1 -1
  38. package/bundles/taiga-ui-core-components-hosted-dropdown.umd.min.js +1 -1
  39. package/bundles/taiga-ui-core-components-hosted-dropdown.umd.min.js.map +1 -1
  40. package/bundles/taiga-ui-core-components-label.umd.js +1 -1
  41. package/bundles/taiga-ui-core-components-label.umd.js.map +1 -1
  42. package/bundles/taiga-ui-core-components-label.umd.min.js +1 -1
  43. package/bundles/taiga-ui-core-components-label.umd.min.js.map +1 -1
  44. package/bundles/taiga-ui-core-components-link.umd.js +1 -1
  45. package/bundles/taiga-ui-core-components-link.umd.min.js +1 -1
  46. package/bundles/taiga-ui-core-components-link.umd.min.js.map +1 -1
  47. package/bundles/taiga-ui-core-components-loader.umd.js +2 -2
  48. package/bundles/taiga-ui-core-components-loader.umd.js.map +1 -1
  49. package/bundles/taiga-ui-core-components-loader.umd.min.js +1 -1
  50. package/bundles/taiga-ui-core-components-loader.umd.min.js.map +1 -1
  51. package/bundles/taiga-ui-core-components-notification.umd.js +1 -1
  52. package/bundles/taiga-ui-core-components-notification.umd.min.js +1 -1
  53. package/bundles/taiga-ui-core-components-primitive-calendar.umd.js +2 -2
  54. package/bundles/taiga-ui-core-components-primitive-calendar.umd.js.map +1 -1
  55. package/bundles/taiga-ui-core-components-primitive-calendar.umd.min.js +1 -1
  56. package/bundles/taiga-ui-core-components-primitive-calendar.umd.min.js.map +1 -1
  57. package/bundles/taiga-ui-core-components-primitive-spin-button.umd.js +2 -2
  58. package/bundles/taiga-ui-core-components-primitive-spin-button.umd.min.js +1 -1
  59. package/bundles/taiga-ui-core-components-primitive-textfield.umd.js +138 -106
  60. package/bundles/taiga-ui-core-components-primitive-textfield.umd.js.map +1 -1
  61. package/bundles/taiga-ui-core-components-primitive-textfield.umd.min.js +2 -2
  62. package/bundles/taiga-ui-core-components-primitive-textfield.umd.min.js.map +1 -1
  63. package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js +2 -2
  64. package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js.map +1 -1
  65. package/bundles/taiga-ui-core-components-primitive-year-picker.umd.min.js +1 -1
  66. package/bundles/taiga-ui-core-components-primitive-year-picker.umd.min.js.map +1 -1
  67. package/bundles/taiga-ui-core-components-scroll-controls.umd.js +2 -2
  68. package/bundles/taiga-ui-core-components-scroll-controls.umd.min.js +1 -1
  69. package/bundles/taiga-ui-core-components-scroll-controls.umd.min.js.map +1 -1
  70. package/bundles/taiga-ui-core-components-scrollbar.umd.js +34 -24
  71. package/bundles/taiga-ui-core-components-scrollbar.umd.js.map +1 -1
  72. package/bundles/taiga-ui-core-components-scrollbar.umd.min.js +2 -2
  73. package/bundles/taiga-ui-core-components-scrollbar.umd.min.js.map +1 -1
  74. package/bundles/taiga-ui-core-components-theme-night.umd.js +7 -11
  75. package/bundles/taiga-ui-core-components-theme-night.umd.js.map +1 -1
  76. package/bundles/taiga-ui-core-components-theme-night.umd.min.js +2 -2
  77. package/bundles/taiga-ui-core-components-theme-night.umd.min.js.map +1 -1
  78. package/bundles/taiga-ui-core-components-tooltip.umd.js +1 -1
  79. package/bundles/taiga-ui-core-components-tooltip.umd.min.js +1 -1
  80. package/bundles/taiga-ui-core-components-wrapper.umd.js +1 -1
  81. package/bundles/taiga-ui-core-components-wrapper.umd.min.js +1 -1
  82. package/bundles/taiga-ui-core-components-wrapper.umd.min.js.map +1 -1
  83. package/bundles/taiga-ui-core-constants.umd.js +10 -1
  84. package/bundles/taiga-ui-core-constants.umd.js.map +1 -1
  85. package/bundles/taiga-ui-core-constants.umd.min.js +1 -1
  86. package/bundles/taiga-ui-core-constants.umd.min.js.map +1 -1
  87. package/bundles/taiga-ui-core-directives-border.umd.js +291 -0
  88. package/bundles/taiga-ui-core-directives-border.umd.js.map +1 -0
  89. package/bundles/taiga-ui-core-directives-border.umd.min.js +16 -0
  90. package/bundles/taiga-ui-core-directives-border.umd.min.js.map +1 -0
  91. package/bundles/taiga-ui-core-directives-hint.umd.js +7 -4
  92. package/bundles/taiga-ui-core-directives-hint.umd.js.map +1 -1
  93. package/bundles/taiga-ui-core-directives-hint.umd.min.js +1 -1
  94. package/bundles/taiga-ui-core-directives-hint.umd.min.js.map +1 -1
  95. package/bundles/taiga-ui-core-directives-manual-hint.umd.js +7 -4
  96. package/bundles/taiga-ui-core-directives-manual-hint.umd.js.map +1 -1
  97. package/bundles/taiga-ui-core-directives-manual-hint.umd.min.js +1 -1
  98. package/bundles/taiga-ui-core-directives-manual-hint.umd.min.js.map +1 -1
  99. package/bundles/taiga-ui-core-directives-pointer-hint.umd.js +1 -1
  100. package/bundles/taiga-ui-core-directives-pointer-hint.umd.js.map +1 -1
  101. package/bundles/taiga-ui-core-directives-pointer-hint.umd.min.js +1 -1
  102. package/bundles/taiga-ui-core-directives-pointer-hint.umd.min.js.map +1 -1
  103. package/bundles/taiga-ui-core-directives-textfield-controller.umd.js +9 -3
  104. package/bundles/taiga-ui-core-directives-textfield-controller.umd.js.map +1 -1
  105. package/bundles/taiga-ui-core-directives-textfield-controller.umd.min.js.map +1 -1
  106. package/bundles/taiga-ui-core-directives.umd.js +12 -4
  107. package/bundles/taiga-ui-core-directives.umd.js.map +1 -1
  108. package/bundles/taiga-ui-core-directives.umd.min.js +1 -1
  109. package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js +1 -1
  110. package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js.map +1 -1
  111. package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.min.js +1 -1
  112. package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.min.js.map +1 -1
  113. package/bundles/taiga-ui-core-modules-notifications.umd.js +2 -2
  114. package/bundles/taiga-ui-core-modules-notifications.umd.js.map +1 -1
  115. package/bundles/taiga-ui-core-modules-notifications.umd.min.js +1 -1
  116. package/bundles/taiga-ui-core-modules-notifications.umd.min.js.map +1 -1
  117. package/bundles/taiga-ui-core-tokens.umd.js +9 -0
  118. package/bundles/taiga-ui-core-tokens.umd.js.map +1 -1
  119. package/bundles/taiga-ui-core-tokens.umd.min.js +1 -1
  120. package/bundles/taiga-ui-core-tokens.umd.min.js.map +1 -1
  121. package/bundles/taiga-ui-core-utils-dom.umd.js +3 -1
  122. package/bundles/taiga-ui-core-utils-dom.umd.js.map +1 -1
  123. package/bundles/taiga-ui-core-utils-dom.umd.min.js +1 -1
  124. package/bundles/taiga-ui-core-utils-dom.umd.min.js.map +1 -1
  125. package/bundles/taiga-ui-core-utils-mask.umd.js +28 -8
  126. package/bundles/taiga-ui-core-utils-mask.umd.js.map +1 -1
  127. package/bundles/taiga-ui-core-utils-mask.umd.min.js +1 -1
  128. package/bundles/taiga-ui-core-utils-mask.umd.min.js.map +1 -1
  129. package/bundles/taiga-ui-core-utils-miscellaneous.umd.js +2 -4
  130. package/bundles/taiga-ui-core-utils-miscellaneous.umd.js.map +1 -1
  131. package/bundles/taiga-ui-core-utils-miscellaneous.umd.min.js +1 -1
  132. package/bundles/taiga-ui-core-utils-miscellaneous.umd.min.js.map +1 -1
  133. package/components/button/button-options.d.ts +10 -0
  134. package/components/button/button.component.d.ts +8 -7
  135. package/components/button/index.d.ts +1 -0
  136. package/components/button/taiga-ui-core-components-button.metadata.json +1 -1
  137. package/components/calendar/taiga-ui-core-components-calendar.metadata.json +1 -1
  138. package/components/data-list/taiga-ui-core-components-data-list.metadata.json +1 -1
  139. package/components/dialog/taiga-ui-core-components-dialog.metadata.json +1 -1
  140. package/components/dropdown-box/taiga-ui-core-components-dropdown-box.metadata.json +1 -1
  141. package/components/error/taiga-ui-core-components-error.metadata.json +1 -1
  142. package/components/expand/taiga-ui-core-components-expand.metadata.json +1 -1
  143. package/components/hints-host/taiga-ui-core-components-hints-host.metadata.json +1 -1
  144. package/components/hosted-dropdown/hosted-dropdown.component.d.ts +1 -3
  145. package/components/hosted-dropdown/taiga-ui-core-components-hosted-dropdown.metadata.json +1 -1
  146. package/components/label/taiga-ui-core-components-label.metadata.json +1 -1
  147. package/components/link/taiga-ui-core-components-link.metadata.json +1 -1
  148. package/components/loader/taiga-ui-core-components-loader.metadata.json +1 -1
  149. package/components/notification/taiga-ui-core-components-notification.metadata.json +1 -1
  150. package/components/primitive-calendar/primitive-calendar.component.d.ts +1 -1
  151. package/components/primitive-calendar/taiga-ui-core-components-primitive-calendar.metadata.json +1 -1
  152. package/components/primitive-spin-button/taiga-ui-core-components-primitive-spin-button.metadata.json +1 -1
  153. package/components/primitive-textfield/index.d.ts +1 -0
  154. package/components/primitive-textfield/primitive-textfield.component.d.ts +9 -16
  155. package/components/primitive-textfield/taiga-ui-core-components-primitive-textfield.metadata.json +1 -1
  156. package/components/primitive-textfield/value-decoration/value-decoration.component.d.ts +18 -0
  157. package/components/primitive-year-picker/taiga-ui-core-components-primitive-year-picker.metadata.json +1 -1
  158. package/components/scroll-controls/scroll-controls.component.d.ts +1 -1
  159. package/components/scroll-controls/taiga-ui-core-components-scroll-controls.metadata.json +1 -1
  160. package/components/scrollbar/scrollable.directive.d.ts +5 -1
  161. package/components/scrollbar/scrollbar.component.d.ts +4 -3
  162. package/components/scrollbar/taiga-ui-core-components-scrollbar.metadata.json +1 -1
  163. package/components/theme-night/taiga-ui-core-components-theme-night.metadata.json +1 -1
  164. package/components/theme-night/theme-night.component.d.ts +0 -1
  165. package/components/tooltip/taiga-ui-core-components-tooltip.metadata.json +1 -1
  166. package/components/wrapper/taiga-ui-core-components-wrapper.metadata.json +1 -1
  167. package/constants/events.d.ts +5 -0
  168. package/constants/media.d.ts +1 -0
  169. package/constants/regexp.d.ts +1 -0
  170. package/constants/taiga-ui-core-constants.metadata.json +1 -1
  171. package/constants/version.d.ts +1 -1
  172. package/directives/border/border.directive.d.ts +9 -0
  173. package/directives/border/border.module.d.ts +2 -0
  174. package/directives/border/index.d.ts +2 -0
  175. package/directives/border/package.json +13 -0
  176. package/directives/border/taiga-ui-core-directives-border.d.ts +4 -0
  177. package/directives/border/taiga-ui-core-directives-border.metadata.json +1 -0
  178. package/directives/hint/hint.directive.d.ts +2 -2
  179. package/directives/hint/taiga-ui-core-directives-hint.metadata.json +1 -1
  180. package/directives/index.d.ts +1 -0
  181. package/directives/manual-hint/manual-hint.directive.d.ts +2 -1
  182. package/directives/manual-hint/taiga-ui-core-directives-manual-hint.metadata.json +1 -1
  183. package/directives/taiga-ui-core-directives.metadata.json +1 -1
  184. package/directives/textfield-controller/taiga-ui-core-directives-textfield-controller.metadata.json +1 -1
  185. package/esm2015/abstract/abstract-hint.js +6 -4
  186. package/esm2015/components/button/button-options.js +10 -0
  187. package/esm2015/components/button/button.component.js +12 -8
  188. package/esm2015/components/button/index.js +2 -1
  189. package/esm2015/components/calendar/calendar.component.js +2 -2
  190. package/esm2015/components/data-list/data-list.component.js +4 -3
  191. package/esm2015/components/data-list/option/option.component.js +4 -4
  192. package/esm2015/components/dialog/dialog.component.js +3 -3
  193. package/esm2015/components/dropdown-box/dropdown-box.component.js +1 -1
  194. package/esm2015/components/error/error.component.js +1 -1
  195. package/esm2015/components/expand/expand.component.js +4 -3
  196. package/esm2015/components/hints-host/hint-box/hint-box.component.js +3 -3
  197. package/esm2015/components/hints-host/hints-host.component.js +3 -3
  198. package/esm2015/components/hints-host/hints-host.module.js +9 -3
  199. package/esm2015/components/hosted-dropdown/hosted-dropdown.component.js +4 -13
  200. package/esm2015/components/label/label.component.js +2 -2
  201. package/esm2015/components/link/link.component.js +1 -1
  202. package/esm2015/components/loader/loader.component.js +3 -3
  203. package/esm2015/components/notification/notification.component.js +1 -1
  204. package/esm2015/components/primitive-calendar/primitive-calendar.component.js +3 -3
  205. package/esm2015/components/primitive-spin-button/primitive-spin-button.component.js +2 -2
  206. package/esm2015/components/primitive-textfield/index.js +2 -1
  207. package/esm2015/components/primitive-textfield/primitive-textfield.component.js +38 -67
  208. package/esm2015/components/primitive-textfield/primitive-textfield.module.js +7 -2
  209. package/esm2015/components/primitive-textfield/value-decoration/value-decoration.component.js +65 -0
  210. package/esm2015/components/primitive-year-picker/primitive-year-picker.component.js +3 -3
  211. package/esm2015/components/scroll-controls/scroll-controls.component.js +2 -2
  212. package/esm2015/components/scrollbar/scrollable.directive.js +18 -4
  213. package/esm2015/components/scrollbar/scrollbar.component.js +20 -18
  214. package/esm2015/components/theme-night/theme-night.component.js +4 -12
  215. package/esm2015/components/tooltip/tooltip.component.js +1 -1
  216. package/esm2015/components/wrapper/wrapper.component.js +1 -1
  217. package/esm2015/constants/events.js +6 -1
  218. package/esm2015/constants/media.js +2 -1
  219. package/esm2015/constants/regexp.js +2 -1
  220. package/esm2015/constants/version.js +2 -2
  221. package/esm2015/directives/border/border.directive.js +42 -0
  222. package/esm2015/directives/border/border.module.js +13 -0
  223. package/esm2015/directives/border/index.js +3 -0
  224. package/esm2015/directives/border/taiga-ui-core-directives-border.js +5 -0
  225. package/esm2015/directives/hint/hint.directive.js +10 -7
  226. package/esm2015/directives/index.js +2 -1
  227. package/esm2015/directives/manual-hint/manual-hint.directive.js +10 -7
  228. package/esm2015/directives/pointer-hint/pointer-hint.directive.js +2 -2
  229. package/esm2015/directives/textfield-controller/textfield-cleaner.directive.js +4 -2
  230. package/esm2015/directives/textfield-controller/textfield-size.directive.js +4 -2
  231. package/esm2015/directives/textfield-controller/textfield-type.directive.js +4 -2
  232. package/esm2015/interfaces/index.js +1 -1
  233. package/esm2015/interfaces/media.js +1 -0
  234. package/esm2015/internal/primitive-year-month-pagination/primitive-year-month-pagination.component.js +2 -2
  235. package/esm2015/modules/notifications/notification-alert/notification-alert.component.js +2 -2
  236. package/esm2015/modules/notifications/notifications-host/notifications-host.component.js +1 -1
  237. package/esm2015/tokens/index.js +2 -1
  238. package/esm2015/tokens/media.js +9 -0
  239. package/esm2015/utils/dom/process-icon.js +4 -2
  240. package/esm2015/utils/mask/create-number-mask.js +28 -10
  241. package/esm2015/utils/miscellaneous/get-border.js +3 -5
  242. package/esm5/abstract/abstract-hint.js +6 -4
  243. package/esm5/components/button/button-options.js +10 -0
  244. package/esm5/components/button/button.component.js +12 -8
  245. package/esm5/components/button/index.js +2 -1
  246. package/esm5/components/calendar/calendar.component.js +2 -2
  247. package/esm5/components/data-list/data-list.component.js +4 -3
  248. package/esm5/components/data-list/option/option.component.js +4 -4
  249. package/esm5/components/dialog/dialog.component.js +3 -3
  250. package/esm5/components/dropdown-box/dropdown-box.component.js +1 -1
  251. package/esm5/components/error/error.component.js +1 -1
  252. package/esm5/components/expand/expand.component.js +4 -3
  253. package/esm5/components/hints-host/hint-box/hint-box.component.js +3 -3
  254. package/esm5/components/hints-host/hints-host.component.js +3 -3
  255. package/esm5/components/hints-host/hints-host.module.js +9 -3
  256. package/esm5/components/hosted-dropdown/hosted-dropdown.component.js +4 -17
  257. package/esm5/components/label/label.component.js +2 -2
  258. package/esm5/components/link/link.component.js +1 -1
  259. package/esm5/components/loader/loader.component.js +3 -3
  260. package/esm5/components/notification/notification.component.js +1 -1
  261. package/esm5/components/primitive-calendar/primitive-calendar.component.js +3 -3
  262. package/esm5/components/primitive-spin-button/primitive-spin-button.component.js +2 -2
  263. package/esm5/components/primitive-textfield/index.js +2 -1
  264. package/esm5/components/primitive-textfield/primitive-textfield.component.js +43 -104
  265. package/esm5/components/primitive-textfield/primitive-textfield.module.js +7 -2
  266. package/esm5/components/primitive-textfield/value-decoration/value-decoration.component.js +99 -0
  267. package/esm5/components/primitive-year-picker/primitive-year-picker.component.js +3 -3
  268. package/esm5/components/scroll-controls/scroll-controls.component.js +2 -2
  269. package/esm5/components/scrollbar/scrollable.directive.js +17 -5
  270. package/esm5/components/scrollbar/scrollbar.component.js +20 -22
  271. package/esm5/components/theme-night/theme-night.component.js +6 -11
  272. package/esm5/components/tooltip/tooltip.component.js +1 -1
  273. package/esm5/components/wrapper/wrapper.component.js +1 -1
  274. package/esm5/constants/events.js +6 -1
  275. package/esm5/constants/media.js +2 -1
  276. package/esm5/constants/regexp.js +2 -1
  277. package/esm5/constants/version.js +2 -2
  278. package/esm5/directives/border/border.directive.js +51 -0
  279. package/esm5/directives/border/border.module.js +16 -0
  280. package/esm5/directives/border/index.js +3 -0
  281. package/esm5/directives/border/taiga-ui-core-directives-border.js +5 -0
  282. package/esm5/directives/hint/hint.directive.js +10 -7
  283. package/esm5/directives/index.js +2 -1
  284. package/esm5/directives/manual-hint/manual-hint.directive.js +10 -7
  285. package/esm5/directives/pointer-hint/pointer-hint.directive.js +2 -2
  286. package/esm5/directives/textfield-controller/textfield-cleaner.directive.js +4 -2
  287. package/esm5/directives/textfield-controller/textfield-size.directive.js +4 -2
  288. package/esm5/directives/textfield-controller/textfield-type.directive.js +4 -2
  289. package/esm5/interfaces/index.js +1 -1
  290. package/esm5/interfaces/media.js +1 -0
  291. package/esm5/internal/primitive-year-month-pagination/primitive-year-month-pagination.component.js +2 -2
  292. package/esm5/modules/notifications/notification-alert/notification-alert.component.js +2 -2
  293. package/esm5/modules/notifications/notifications-host/notifications-host.component.js +1 -1
  294. package/esm5/tokens/index.js +2 -1
  295. package/esm5/tokens/media.js +9 -0
  296. package/esm5/utils/dom/process-icon.js +4 -2
  297. package/esm5/utils/mask/create-number-mask.js +30 -10
  298. package/esm5/utils/miscellaneous/get-border.js +3 -5
  299. package/fesm2015/taiga-ui-core-abstract.js +4 -2
  300. package/fesm2015/taiga-ui-core-abstract.js.map +1 -1
  301. package/fesm2015/taiga-ui-core-components-button.js +21 -9
  302. package/fesm2015/taiga-ui-core-components-button.js.map +1 -1
  303. package/fesm2015/taiga-ui-core-components-calendar.js +1 -1
  304. package/fesm2015/taiga-ui-core-components-calendar.js.map +1 -1
  305. package/fesm2015/taiga-ui-core-components-data-list.js +6 -5
  306. package/fesm2015/taiga-ui-core-components-data-list.js.map +1 -1
  307. package/fesm2015/taiga-ui-core-components-dialog.js +2 -2
  308. package/fesm2015/taiga-ui-core-components-dialog.js.map +1 -1
  309. package/fesm2015/taiga-ui-core-components-dropdown-box.js +1 -1
  310. package/fesm2015/taiga-ui-core-components-error.js +1 -1
  311. package/fesm2015/taiga-ui-core-components-expand.js +3 -2
  312. package/fesm2015/taiga-ui-core-components-expand.js.map +1 -1
  313. package/fesm2015/taiga-ui-core-components-hints-host.js +12 -6
  314. package/fesm2015/taiga-ui-core-components-hints-host.js.map +1 -1
  315. package/fesm2015/taiga-ui-core-components-hosted-dropdown.js +3 -12
  316. package/fesm2015/taiga-ui-core-components-hosted-dropdown.js.map +1 -1
  317. package/fesm2015/taiga-ui-core-components-label.js +1 -1
  318. package/fesm2015/taiga-ui-core-components-label.js.map +1 -1
  319. package/fesm2015/taiga-ui-core-components-link.js +1 -1
  320. package/fesm2015/taiga-ui-core-components-loader.js +2 -2
  321. package/fesm2015/taiga-ui-core-components-loader.js.map +1 -1
  322. package/fesm2015/taiga-ui-core-components-notification.js +1 -1
  323. package/fesm2015/taiga-ui-core-components-primitive-calendar.js +2 -2
  324. package/fesm2015/taiga-ui-core-components-primitive-calendar.js.map +1 -1
  325. package/fesm2015/taiga-ui-core-components-primitive-spin-button.js +2 -2
  326. package/fesm2015/taiga-ui-core-components-primitive-textfield.js +102 -69
  327. package/fesm2015/taiga-ui-core-components-primitive-textfield.js.map +1 -1
  328. package/fesm2015/taiga-ui-core-components-primitive-year-picker.js +2 -2
  329. package/fesm2015/taiga-ui-core-components-primitive-year-picker.js.map +1 -1
  330. package/fesm2015/taiga-ui-core-components-scroll-controls.js +2 -2
  331. package/fesm2015/taiga-ui-core-components-scrollbar.js +33 -17
  332. package/fesm2015/taiga-ui-core-components-scrollbar.js.map +1 -1
  333. package/fesm2015/taiga-ui-core-components-theme-night.js +3 -11
  334. package/fesm2015/taiga-ui-core-components-theme-night.js.map +1 -1
  335. package/fesm2015/taiga-ui-core-components-tooltip.js +1 -1
  336. package/fesm2015/taiga-ui-core-components-wrapper.js +1 -1
  337. package/fesm2015/taiga-ui-core-constants.js +9 -2
  338. package/fesm2015/taiga-ui-core-constants.js.map +1 -1
  339. package/fesm2015/taiga-ui-core-directives-border.js +57 -0
  340. package/fesm2015/taiga-ui-core-directives-border.js.map +1 -0
  341. package/fesm2015/taiga-ui-core-directives-hint.js +9 -6
  342. package/fesm2015/taiga-ui-core-directives-hint.js.map +1 -1
  343. package/fesm2015/taiga-ui-core-directives-manual-hint.js +9 -6
  344. package/fesm2015/taiga-ui-core-directives-manual-hint.js.map +1 -1
  345. package/fesm2015/taiga-ui-core-directives-pointer-hint.js +1 -1
  346. package/fesm2015/taiga-ui-core-directives-pointer-hint.js.map +1 -1
  347. package/fesm2015/taiga-ui-core-directives-textfield-controller.js +9 -3
  348. package/fesm2015/taiga-ui-core-directives-textfield-controller.js.map +1 -1
  349. package/fesm2015/taiga-ui-core-directives.js +1 -0
  350. package/fesm2015/taiga-ui-core-directives.js.map +1 -1
  351. package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js +1 -1
  352. package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js.map +1 -1
  353. package/fesm2015/taiga-ui-core-modules-notifications.js +2 -2
  354. package/fesm2015/taiga-ui-core-modules-notifications.js.map +1 -1
  355. package/fesm2015/taiga-ui-core-tokens.js +9 -1
  356. package/fesm2015/taiga-ui-core-tokens.js.map +1 -1
  357. package/fesm2015/taiga-ui-core-utils-dom.js +3 -1
  358. package/fesm2015/taiga-ui-core-utils-dom.js.map +1 -1
  359. package/fesm2015/taiga-ui-core-utils-mask.js +27 -9
  360. package/fesm2015/taiga-ui-core-utils-mask.js.map +1 -1
  361. package/fesm2015/taiga-ui-core-utils-miscellaneous.js +2 -4
  362. package/fesm2015/taiga-ui-core-utils-miscellaneous.js.map +1 -1
  363. package/fesm5/taiga-ui-core-abstract.js +4 -2
  364. package/fesm5/taiga-ui-core-abstract.js.map +1 -1
  365. package/fesm5/taiga-ui-core-components-button.js +21 -9
  366. package/fesm5/taiga-ui-core-components-button.js.map +1 -1
  367. package/fesm5/taiga-ui-core-components-calendar.js +1 -1
  368. package/fesm5/taiga-ui-core-components-calendar.js.map +1 -1
  369. package/fesm5/taiga-ui-core-components-data-list.js +6 -5
  370. package/fesm5/taiga-ui-core-components-data-list.js.map +1 -1
  371. package/fesm5/taiga-ui-core-components-dialog.js +2 -2
  372. package/fesm5/taiga-ui-core-components-dialog.js.map +1 -1
  373. package/fesm5/taiga-ui-core-components-dropdown-box.js +1 -1
  374. package/fesm5/taiga-ui-core-components-error.js +1 -1
  375. package/fesm5/taiga-ui-core-components-expand.js +3 -2
  376. package/fesm5/taiga-ui-core-components-expand.js.map +1 -1
  377. package/fesm5/taiga-ui-core-components-hints-host.js +12 -6
  378. package/fesm5/taiga-ui-core-components-hints-host.js.map +1 -1
  379. package/fesm5/taiga-ui-core-components-hosted-dropdown.js +3 -16
  380. package/fesm5/taiga-ui-core-components-hosted-dropdown.js.map +1 -1
  381. package/fesm5/taiga-ui-core-components-label.js +1 -1
  382. package/fesm5/taiga-ui-core-components-label.js.map +1 -1
  383. package/fesm5/taiga-ui-core-components-link.js +1 -1
  384. package/fesm5/taiga-ui-core-components-loader.js +2 -2
  385. package/fesm5/taiga-ui-core-components-loader.js.map +1 -1
  386. package/fesm5/taiga-ui-core-components-notification.js +1 -1
  387. package/fesm5/taiga-ui-core-components-primitive-calendar.js +2 -2
  388. package/fesm5/taiga-ui-core-components-primitive-calendar.js.map +1 -1
  389. package/fesm5/taiga-ui-core-components-primitive-spin-button.js +2 -2
  390. package/fesm5/taiga-ui-core-components-primitive-textfield.js +141 -106
  391. package/fesm5/taiga-ui-core-components-primitive-textfield.js.map +1 -1
  392. package/fesm5/taiga-ui-core-components-primitive-year-picker.js +2 -2
  393. package/fesm5/taiga-ui-core-components-primitive-year-picker.js.map +1 -1
  394. package/fesm5/taiga-ui-core-components-scroll-controls.js +2 -2
  395. package/fesm5/taiga-ui-core-components-scrollbar.js +32 -22
  396. package/fesm5/taiga-ui-core-components-scrollbar.js.map +1 -1
  397. package/fesm5/taiga-ui-core-components-theme-night.js +5 -10
  398. package/fesm5/taiga-ui-core-components-theme-night.js.map +1 -1
  399. package/fesm5/taiga-ui-core-components-tooltip.js +1 -1
  400. package/fesm5/taiga-ui-core-components-wrapper.js +1 -1
  401. package/fesm5/taiga-ui-core-constants.js +9 -2
  402. package/fesm5/taiga-ui-core-constants.js.map +1 -1
  403. package/fesm5/taiga-ui-core-directives-border.js +69 -0
  404. package/fesm5/taiga-ui-core-directives-border.js.map +1 -0
  405. package/fesm5/taiga-ui-core-directives-hint.js +9 -6
  406. package/fesm5/taiga-ui-core-directives-hint.js.map +1 -1
  407. package/fesm5/taiga-ui-core-directives-manual-hint.js +9 -6
  408. package/fesm5/taiga-ui-core-directives-manual-hint.js.map +1 -1
  409. package/fesm5/taiga-ui-core-directives-pointer-hint.js +1 -1
  410. package/fesm5/taiga-ui-core-directives-pointer-hint.js.map +1 -1
  411. package/fesm5/taiga-ui-core-directives-textfield-controller.js +9 -3
  412. package/fesm5/taiga-ui-core-directives-textfield-controller.js.map +1 -1
  413. package/fesm5/taiga-ui-core-directives.js +1 -0
  414. package/fesm5/taiga-ui-core-directives.js.map +1 -1
  415. package/fesm5/taiga-ui-core-internal-primitive-year-month-pagination.js +1 -1
  416. package/fesm5/taiga-ui-core-internal-primitive-year-month-pagination.js.map +1 -1
  417. package/fesm5/taiga-ui-core-modules-notifications.js +2 -2
  418. package/fesm5/taiga-ui-core-modules-notifications.js.map +1 -1
  419. package/fesm5/taiga-ui-core-tokens.js +9 -1
  420. package/fesm5/taiga-ui-core-tokens.js.map +1 -1
  421. package/fesm5/taiga-ui-core-utils-dom.js +3 -1
  422. package/fesm5/taiga-ui-core-utils-dom.js.map +1 -1
  423. package/fesm5/taiga-ui-core-utils-mask.js +30 -10
  424. package/fesm5/taiga-ui-core-utils-mask.js.map +1 -1
  425. package/fesm5/taiga-ui-core-utils-miscellaneous.js +2 -4
  426. package/fesm5/taiga-ui-core-utils-miscellaneous.js.map +1 -1
  427. package/interfaces/index.d.ts +1 -0
  428. package/interfaces/media.d.ts +6 -0
  429. package/interfaces/taiga-ui-core-interfaces.metadata.json +1 -1
  430. package/internal/primitive-year-month-pagination/taiga-ui-core-internal-primitive-year-month-pagination.metadata.json +1 -1
  431. package/modules/notifications/taiga-ui-core-modules-notifications.metadata.json +1 -1
  432. package/package.json +5 -5
  433. package/styles/basic/main.less +2 -4
  434. package/styles/markup/tui-autofill.less +2 -0
  435. package/styles/markup/tui-container-old.less +69 -0
  436. package/styles/markup/tui-form-old.less +141 -0
  437. package/styles/markup/tui-form.less +12 -12
  438. package/styles/markup/tui-group-old.less +322 -0
  439. package/styles/markup/tui-group.less +2 -2
  440. package/styles/markup/tui-mobile-only.less +1 -1
  441. package/styles/markup/tui-row-old.less +157 -0
  442. package/styles/markup/tui-table.less +2 -2
  443. package/styles/mixins/mixins.less +8 -3
  444. package/styles/mixins/picker.less +1 -1
  445. package/styles/mixins/textfield.less +37 -78
  446. package/styles/taiga-ui-global-old.less +18 -0
  447. package/styles/taiga-ui-local-old.less +7 -0
  448. package/styles/theme/variables.less +4 -0
  449. package/styles/theme/wrapper/table.less +4 -0
  450. package/styles/variables/media-old.less +48 -0
  451. package/styles/variables/media.less +4 -4
  452. package/tokens/index.d.ts +1 -0
  453. package/tokens/media.d.ts +3 -0
  454. package/tokens/taiga-ui-core-tokens.metadata.json +1 -1
  455. package/utils/mask/create-number-mask.d.ts +1 -0
  456. package/utils/miscellaneous/get-border.d.ts +1 -1
@@ -60,7 +60,9 @@ function processIcon(source, name) {
60
60
  if (!heightString ||
61
61
  !widthString ||
62
62
  widthString.includes('%') ||
63
- heightString.includes('%')) {
63
+ heightString.includes('%') ||
64
+ widthString.includes('em') ||
65
+ heightString.includes('em')) {
64
66
  return src.replace(START, "<svg id=\"" + name + "\"");
65
67
  }
66
68
  var width = parseInt(widthString, 10);
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-core-utils-dom.js","sources":["ng://@taiga-ui/core/utils/dom/are-css-vars-supported.ts","ng://@taiga-ui/core/utils/dom/check-fixed-position.ts","ng://@taiga-ui/core/utils/dom/get-safe-area-size.ts","ng://@taiga-ui/core/utils/dom/get-screen-width.ts","ng://@taiga-ui/core/utils/dom/process-icon.ts","ng://@taiga-ui/core/utils/dom/taiga-ui-core-utils-dom.ts"],"sourcesContent":["import {isEdgeOlderThan} from '@taiga-ui/cdk';\n\n/**\n * TODO: remove \"any\" in new TS version; https://github.com/ng-web-apis/common/pull/6\n */\nexport function areCssVarsSupported(cssRef: any, userAgent: string): boolean {\n return cssRef.supports('(--a: 0)') && !isEdgeOlderThan(17, userAgent);\n}\n","export function checkFixedPosition(element: HTMLElement | null): boolean {\n if (!element || typeof getComputedStyle === 'undefined') {\n return false;\n }\n\n const style = getComputedStyle(element);\n\n return (\n style.getPropertyValue('position') === 'fixed' ||\n checkFixedPosition(element.parentElement)\n );\n}\n","/**\n * Calculates size of safe area on mobile devices (status bars)\n *\n * ATTENTION: Only use in browser environment\n */\nexport function getSafeAreaSize(): number {\n if (!CSS.supports('padding-top: env(safe-area-inset-top)')) {\n return 0;\n }\n\n const div = document.createElement('div');\n\n div.style.paddingTop = 'env(safe-area-inset-top)';\n document.body.appendChild(div);\n\n const safeAreaSize = parseInt(window.getComputedStyle(div).paddingTop!, 10) || 0;\n\n document.body.removeChild(div);\n\n return safeAreaSize;\n}\n","export function getScreenWidth(documentRef: Document): number {\n return Math.max(\n documentRef.documentElement.clientWidth,\n documentRef.defaultView ? documentRef.defaultView.innerWidth : 0,\n );\n}\n","const WIDTH_SEARCH = 'width=\"';\nconst HEIGHT_SEARCH = 'height=\"';\nconst START = '<svg';\n\nexport function processIcon(source: string, name: string): string {\n if (source.includes(`id=\"${name}\"`)) {\n return source;\n }\n\n const src = source.substring(source.indexOf(START));\n const attributes = src.substring(0, src.indexOf('>'));\n\n if (\n !attributes ||\n !attributes.includes(WIDTH_SEARCH) ||\n !attributes.includes(HEIGHT_SEARCH)\n ) {\n return (\n src.replace(\n START,\n `<svg xmlns=\"http://www.w3.org/2000/svg\"><g id=\"${name}\" xmlns=\"http://www.w3.org/2000/svg\"><svg`,\n ) + '</g></svg>'\n );\n }\n\n const indexOfWidth = attributes.indexOf(WIDTH_SEARCH);\n const indexOfHeight = attributes.indexOf(HEIGHT_SEARCH);\n const widthOffset = indexOfWidth + WIDTH_SEARCH.length;\n const heightOffset = indexOfHeight + HEIGHT_SEARCH.length;\n const widthString = attributes.substring(\n widthOffset,\n attributes.indexOf('\"', widthOffset),\n );\n const heightString = attributes.substring(\n heightOffset,\n attributes.indexOf('\"', heightOffset),\n );\n\n if (\n !heightString ||\n !widthString ||\n widthString.includes('%') ||\n heightString.includes('%')\n ) {\n return src.replace(START, `<svg id=\"${name}\"`);\n }\n\n const width = parseInt(widthString, 10);\n const height = parseInt(heightString, 10);\n\n return `<g id=\"${name}\" xmlns=\"http://www.w3.org/2000/svg\"><svg x=\"50%\" y=\"50%\" width=\"${\n width / 16\n }em\" height=\"${\n height / 16\n }em\" overflow=\"visible\" viewBox=\"0 0 ${width} ${height}\"><svg x=\"${-width / 2}\" y=\"${\n -width / 2\n }\">${src}</svg></svg></g>`;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAEA;;;SAGgB,mBAAmB,CAAC,MAAW,EAAE,SAAiB;IAC9D,OAAO,MAAM,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,eAAe,CAAC,EAAE,EAAE,SAAS,CAAC,CAAC;AAC1E;;SCPgB,kBAAkB,CAAC,OAA2B;IAC1D,IAAI,CAAC,OAAO,IAAI,OAAO,gBAAgB,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I,kFACjB,KAAK,GAAG,EAAE,sBAEV,MAAM,GAAG,EAAE,gDACwB,KAAK,SAAI,MAAM,oBAAa,CAAC,KAAK,GAAG,CAAC,eACzE,CAAC,KAAK,GAAG,CAAC,WACT,GAAG,qBAAkB,CAAC;AAC/B;;ACzDA;;;;;;"}
1
+ {"version":3,"file":"taiga-ui-core-utils-dom.js","sources":["ng://@taiga-ui/core/utils/dom/are-css-vars-supported.ts","ng://@taiga-ui/core/utils/dom/check-fixed-position.ts","ng://@taiga-ui/core/utils/dom/get-safe-area-size.ts","ng://@taiga-ui/core/utils/dom/get-screen-width.ts","ng://@taiga-ui/core/utils/dom/process-icon.ts","ng://@taiga-ui/core/utils/dom/taiga-ui-core-utils-dom.ts"],"sourcesContent":["import {isEdgeOlderThan} from '@taiga-ui/cdk';\n\n/**\n * TODO: remove \"any\" in new TS version; https://github.com/ng-web-apis/common/pull/6\n */\nexport function areCssVarsSupported(cssRef: any, userAgent: string): boolean {\n return cssRef.supports('(--a: 0)') && !isEdgeOlderThan(17, userAgent);\n}\n","export function checkFixedPosition(element: HTMLElement | null): boolean {\n if (!element || typeof getComputedStyle === 'undefined') {\n return false;\n }\n\n const style = getComputedStyle(element);\n\n return (\n style.getPropertyValue('position') === 'fixed' ||\n checkFixedPosition(element.parentElement)\n );\n}\n","/**\n * Calculates size of safe area on mobile devices (status bars)\n *\n * ATTENTION: Only use in browser environment\n */\nexport function getSafeAreaSize(): number {\n if (!CSS.supports('padding-top: env(safe-area-inset-top)')) {\n return 0;\n }\n\n const div = document.createElement('div');\n\n div.style.paddingTop = 'env(safe-area-inset-top)';\n document.body.appendChild(div);\n\n const safeAreaSize = parseInt(window.getComputedStyle(div).paddingTop!, 10) || 0;\n\n document.body.removeChild(div);\n\n return safeAreaSize;\n}\n","export function getScreenWidth(documentRef: Document): number {\n return Math.max(\n documentRef.documentElement.clientWidth,\n documentRef.defaultView ? documentRef.defaultView.innerWidth : 0,\n );\n}\n","const WIDTH_SEARCH = 'width=\"';\nconst HEIGHT_SEARCH = 'height=\"';\nconst START = '<svg';\n\nexport function processIcon(source: string, name: string): string {\n if (source.includes(`id=\"${name}\"`)) {\n return source;\n }\n\n const src = source.substring(source.indexOf(START));\n const attributes = src.substring(0, src.indexOf('>'));\n\n if (\n !attributes ||\n !attributes.includes(WIDTH_SEARCH) ||\n !attributes.includes(HEIGHT_SEARCH)\n ) {\n return (\n src.replace(\n START,\n `<svg xmlns=\"http://www.w3.org/2000/svg\"><g id=\"${name}\" xmlns=\"http://www.w3.org/2000/svg\"><svg`,\n ) + '</g></svg>'\n );\n }\n\n const indexOfWidth = attributes.indexOf(WIDTH_SEARCH);\n const indexOfHeight = attributes.indexOf(HEIGHT_SEARCH);\n const widthOffset = indexOfWidth + WIDTH_SEARCH.length;\n const heightOffset = indexOfHeight + HEIGHT_SEARCH.length;\n const widthString = attributes.substring(\n widthOffset,\n attributes.indexOf('\"', widthOffset),\n );\n const heightString = attributes.substring(\n heightOffset,\n attributes.indexOf('\"', heightOffset),\n );\n\n if (\n !heightString ||\n !widthString ||\n widthString.includes('%') ||\n heightString.includes('%') ||\n widthString.includes('em') ||\n heightString.includes('em')\n ) {\n return src.replace(START, `<svg id=\"${name}\"`);\n }\n\n const width = parseInt(widthString, 10);\n const height = parseInt(heightString, 10);\n\n return `<g id=\"${name}\" xmlns=\"http://www.w3.org/2000/svg\"><svg x=\"50%\" y=\"50%\" width=\"${\n width / 16\n }em\" height=\"${\n height / 16\n }em\" overflow=\"visible\" viewBox=\"0 0 ${width} ${height}\"><svg x=\"${-width / 2}\" y=\"${\n -width / 2\n }\">${src}</svg></svg></g>`;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAEA;;;SAGgB,mBAAmB,CAAC,MAAW,EAAE,SAAiB;IAC9D,OAAO,MAAM,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,eAAe,CAAC,EAAE,EAAE,SAAS,CAAC,CAAC;AAC1E;;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;KAClD;IAED,IAAM,KAAK,GAAG,QAAQ,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;IACxC,IAAM,MAAM,GAAG,QAAQ,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;IAE1C,OAAO,aAAU,IAAI,kFACjB,KAAK,GAAG,EAAE,sBAEV,MAAM,GAAG,EAAE,gDACwB,KAAK,SAAI,MAAM,oBAAa,CAAC,KAAK,GAAG,CAAC,eACzE,CAAC,KAAK,GAAG,CAAC,WACT,GAAG,qBAAkB,CAAC;AAC/B;;AC3DA;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  import { CHAR_NO_BREAK_SPACE, tuiAssert, isSafari, isNativeFocused, getDocumentOrShadowRoot, CHAR_EN_DASH } from '@taiga-ui/cdk';
2
- import { __spread } from 'tslib';
3
- import { MASK_CARET_TRAP, TUI_DIGIT_REGEXP, TUI_NON_DIGITS_REGEXP } from '@taiga-ui/core/constants';
2
+ import { __spread, __read } from 'tslib';
3
+ import { MASK_CARET_TRAP, TUI_DIGIT_REGEXP, TUI_NON_DIGITS_REGEXP, TUI_LEADING_ZEROES_REGEXP } from '@taiga-ui/core/constants';
4
4
  import { otherDecimalSymbol } from '@taiga-ui/core/utils/format';
5
5
 
6
6
  /**
@@ -123,6 +123,7 @@ function tuiCreateCorrectionMask(allowed, correctionHandler) {
123
123
  var NON_ZERO_DIGIT = /[1-9]/;
124
124
  /**
125
125
  * Adaptation for {@link https://github.com/text-mask/text-mask/tree/master/addons#createnumbermask `createNumberMask`}
126
+ * @todo TODO: autocCorrectDecimalSymbol is no longer needed. Remove it in 3.0
126
127
  */
127
128
  function tuiCreateNumberMask(_a) {
128
129
  var _b = _a === void 0 ? {} : _a, _c = _b.allowDecimal, allowDecimal = _c === void 0 ? false : _c, _d = _b.decimalSymbol, decimalSymbol = _d === void 0 ? ',' : _d, _e = _b.thousandSymbol, thousandSymbol = _e === void 0 ? CHAR_NO_BREAK_SPACE : _e, _f = _b.autoCorrectDecimalSymbol, autoCorrectDecimalSymbol = _f === void 0 ? true : _f, _g = _b.decimalLimit, decimalLimit = _g === void 0 ? 2 : _g, _h = _b.requireDecimal, requireDecimal = _h === void 0 ? false : _h, _j = _b.allowNegative, allowNegative = _j === void 0 ? false : _j, _k = _b.integerLimit, integerLimit = _k === void 0 ? 0 : _k;
@@ -160,10 +161,13 @@ function tuiCreateNumberMask(_a) {
160
161
  var integerCapped = integerLimit
161
162
  ? integer.slice(0, integerLimit + thousandSeparators.length)
162
163
  : integer;
163
- var integerCappedClean = integerCapped
164
- .replace(TUI_NON_DIGITS_REGEXP, '')
165
- .replace(/^0+(?!\.|$)/, '0');
166
- var withSeparator = addThousandsSeparator(integerCappedClean, thousandSymbol);
164
+ var integerCappedClean = integerCapped.replace(TUI_NON_DIGITS_REGEXP, '');
165
+ var _b = __read(integerCappedClean.match(TUI_LEADING_ZEROES_REGEXP) || [''], 1), leadingZerosMatch = _b[0];
166
+ var leadingZerosAmount = leadingZerosMatch.length;
167
+ var integerCappedZerosClean = integerCappedClean
168
+ .replace(/^0+(?!\.|$)/, '')
169
+ .trim();
170
+ var withSeparator = addThousandsSeparator(integerCappedZerosClean, thousandSymbol);
167
171
  var mask = convertToMask(withSeparator);
168
172
  if ((hasDecimal && allowDecimal) || requireDecimal) {
169
173
  var fraction = hasDecimal
@@ -180,20 +184,36 @@ function tuiCreateNumberMask(_a) {
180
184
  mask.push(TUI_DIGIT_REGEXP);
181
185
  }
182
186
  }
187
+ var isOnlyZeroDigit = mask.length === 1 && integerCappedZerosClean === '0';
183
188
  if (isNegative) {
184
189
  if (mask.length === 0) {
185
190
  mask.push(TUI_DIGIT_REGEXP);
186
191
  }
187
192
  mask.unshift('-');
188
193
  }
189
- return preventLeadingZeroes(mask);
194
+ return preventLeadingZeroes(mask, isOnlyZeroDigit, leadingZerosAmount);
190
195
  };
191
196
  }
192
- function preventLeadingZeroes(mask) {
197
+ function preventLeadingZeroes(mask, isOnlyZeroDigit, leadingZerosAmount) {
198
+ if (isOnlyZeroDigit === void 0) { isOnlyZeroDigit = false; }
199
+ if (leadingZerosAmount === void 0) { leadingZerosAmount = 0; }
200
+ if (isOnlyZeroDigit || leadingZerosAmount === 0) {
201
+ return mask;
202
+ }
193
203
  var firstDigitIndex = mask.indexOf(TUI_DIGIT_REGEXP);
194
- if (firstDigitIndex !== -1 && mask[firstDigitIndex + 1] === TUI_DIGIT_REGEXP) {
195
- mask[firstDigitIndex] = NON_ZERO_DIGIT;
204
+ if (firstDigitIndex === -1) {
205
+ return mask;
206
+ }
207
+ var secondMaskDigit = mask[firstDigitIndex + 1];
208
+ var isCaretTrap = secondMaskDigit === MASK_CARET_TRAP;
209
+ if (isCaretTrap && leadingZerosAmount === 1) {
210
+ return mask;
211
+ }
212
+ else if (isCaretTrap) {
213
+ mask.unshift(NON_ZERO_DIGIT);
214
+ return mask;
196
215
  }
216
+ mask[firstDigitIndex] = NON_ZERO_DIGIT;
197
217
  return mask;
198
218
  }
199
219
  function getDecimalSymbolIndex(str, decimalSymbol, autoCorrectDecimalSymbol) {
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-core-utils-mask.js","sources":["ng://@taiga-ui/core/utils/mask/create-auto-corrected-money-pipe.ts","ng://@taiga-ui/core/utils/mask/create-correction-mask.ts","ng://@taiga-ui/core/utils/mask/create-number-mask.ts","ng://@taiga-ui/core/utils/mask/masked-money-value-is-empty.ts","ng://@taiga-ui/core/utils/mask/masked-number-string-to-number.ts","ng://@taiga-ui/core/utils/mask/taiga-ui-core-utils-mask.ts"],"sourcesContent":["import {\n CHAR_NO_BREAK_SPACE,\n getDocumentOrShadowRoot,\n isNativeFocused,\n isSafari,\n tuiAssert,\n} from '@taiga-ui/cdk';\nimport {TuiTextMaskPipeHandler} from '@taiga-ui/core/mask';\nimport {TuiDecimalSymbol} from '@taiga-ui/core/types';\n\n/**\n * Used to finish a number with zeros to a given precision\n */\nexport function tuiCreateAutoCorrectedNumberPipe(\n decimalLimit: number = 0,\n decimalSymbol: TuiDecimalSymbol = ',',\n thousandSymbol: string = CHAR_NO_BREAK_SPACE,\n nativeInput?: HTMLInputElement,\n): TuiTextMaskPipeHandler {\n tuiAssert.assert(Number.isInteger(decimalLimit));\n tuiAssert.assert(decimalLimit >= 0);\n\n // Guess for which browser I need this :)\n let previousCaret = -1;\n\n const unlucky = !!nativeInput && isSafari(nativeInput);\n\n if (nativeInput && unlucky) {\n nativeInput.addEventListener('beforeinput', () => {\n previousCaret = nativeInput.selectionStart || 0;\n });\n }\n\n return (conformedValue, config) => {\n // remove these hacks after text mask library has changed\n if (nativeInput && unlucky && isNativeFocused(nativeInput)) {\n const caret = calculateSafariCaret(\n config.previousConformedValue,\n conformedValue,\n previousCaret,\n );\n\n setTimeout(() => {\n nativeInput.setSelectionRange(caret, caret);\n });\n }\n\n if (\n nativeInput &&\n nativeInput.ownerDocument !== getDocumentOrShadowRoot(nativeInput) &&\n isNativeFocused(nativeInput) &&\n config.currentCaretPosition\n ) {\n const realCaretPosition =\n config.currentCaretPosition +\n calculateCaretGap(\n config.previousConformedValue,\n conformedValue,\n thousandSymbol,\n );\n\n setTimeout(() => {\n nativeInput.setSelectionRange(realCaretPosition, realCaretPosition);\n });\n }\n\n if (conformedValue === '' || !decimalLimit) {\n return {value: conformedValue};\n }\n\n const withDecimalSymbol = addDecimalSymbolIfNeeded(conformedValue, decimalSymbol);\n const decimalPart = withDecimalSymbol.split(decimalSymbol)[1];\n const zeroPaddingSize = decimalLimit - decimalPart.length;\n\n return {\n value: withDecimalSymbol + '0'.repeat(zeroPaddingSize),\n };\n };\n}\n\nfunction addDecimalSymbolIfNeeded(\n value: string,\n decimalSymbol: TuiDecimalSymbol = ',',\n): string {\n return value.indexOf(decimalSymbol) === -1 ? value + decimalSymbol : value;\n}\n\nfunction calculateSafariCaret(\n previousValue: string = '',\n current: string,\n previousCaret: number,\n decimalSymbol: string = ',',\n): number {\n const tailRegex = new RegExp(`${decimalSymbol}.+`);\n const previousWithoutTail = previousValue.replace(tailRegex, '');\n const currentWithoutTail = current.replace(tailRegex, '');\n\n const pasteOrCutOperation =\n Math.abs(previousWithoutTail.length - currentWithoutTail.length) > 2;\n\n if (pasteOrCutOperation) {\n return current.length;\n }\n\n if (previousValue.length === current.length) {\n if (previousValue.indexOf(decimalSymbol) <= previousCaret) {\n return calculateChangedTailIndex(previousValue, current);\n }\n\n return previousWithoutTail === currentWithoutTail\n ? previousCaret - 1\n : previousCaret + 1;\n }\n\n if (previousValue.length === 0) {\n return 1;\n }\n\n const changeLength = current.length - previousValue.length;\n\n return previousCaret + changeLength;\n}\n\nfunction calculateChangedTailIndex(previous: string, current: string): number {\n for (let i = 0; i < current.length; i++) {\n if (previous[i] !== current[i]) {\n return current[i] === '0' ? i : i + 1;\n }\n }\n\n return current.length;\n}\n\nfunction calculateCaretGap(\n previousValue: string = '',\n current: string,\n thousandSymbol: string,\n): number {\n const pasteOrCutOperation = Math.abs(previousValue.length - current.length) > 2;\n\n if (pasteOrCutOperation) {\n return 0;\n }\n\n const wereSpaces = previousValue.split(thousandSymbol).length;\n const nowSpaces = current.split(thousandSymbol).length;\n\n return nowSpaces - wereSpaces;\n}\n","import {tuiAssert} from '@taiga-ui/cdk';\nimport {MASK_CARET_TRAP} from '@taiga-ui/core/constants';\nimport {\n TuiTextMaskCorrectionHandler,\n TuiTextMaskList,\n TuiTextMaskListHandler,\n} from '@taiga-ui/core/mask';\n\nconst ASSERTION = 'Correction function must return single char or null';\n\nexport function tuiCreateCorrectionMask(\n allowed: RegExp,\n correctionHandler: TuiTextMaskCorrectionHandler,\n): TuiTextMaskListHandler {\n return rawValue => {\n const mask = rawValue.split('').reduce<TuiTextMaskList>((result, char, index) => {\n const corrected = correctionHandler(char, index);\n\n tuiAssert.assert(corrected === null || corrected.length === 1, ASSERTION);\n\n if (!allowed.test(char) && !corrected) {\n return result;\n }\n\n if (allowed.test(char)) {\n return [...result, allowed];\n }\n\n if (corrected) {\n return [...result, corrected, MASK_CARET_TRAP];\n }\n\n return result;\n }, []);\n const lastIndex = mask.lastIndexOf(MASK_CARET_TRAP);\n const filtered = mask.filter(\n (item, index) => item !== MASK_CARET_TRAP || index === lastIndex,\n );\n\n return filtered.some(item => item !== allowed)\n ? [...filtered, allowed]\n : filtered;\n };\n}\n","import {CHAR_EN_DASH, CHAR_NO_BREAK_SPACE, tuiAssert} from '@taiga-ui/cdk';\nimport {\n MASK_CARET_TRAP,\n TUI_DIGIT_REGEXP,\n TUI_NON_DIGITS_REGEXP,\n} from '@taiga-ui/core/constants';\nimport {TuiNumberMaskOptions, TuiTextMaskListHandler} from '@taiga-ui/core/mask';\nimport {TuiDecimalSymbol} from '@taiga-ui/core/types';\nimport {otherDecimalSymbol} from '@taiga-ui/core/utils/format';\n\nconst NON_ZERO_DIGIT = /[1-9]/;\n\n/**\n * Adaptation for {@link https://github.com/text-mask/text-mask/tree/master/addons#createnumbermask `createNumberMask`}\n */\nexport function tuiCreateNumberMask({\n allowDecimal = false,\n decimalSymbol = ',',\n thousandSymbol = CHAR_NO_BREAK_SPACE,\n autoCorrectDecimalSymbol = true,\n decimalLimit = 2,\n requireDecimal = false,\n allowNegative = false,\n integerLimit = 0,\n}: TuiNumberMaskOptions = {}): TuiTextMaskListHandler {\n tuiAssert.assert(Number.isInteger(decimalLimit));\n tuiAssert.assert(decimalLimit > 0);\n tuiAssert.assert(Number.isInteger(integerLimit));\n tuiAssert.assert(integerLimit >= 0);\n\n return (rawValue, {previousConformedValue}) => {\n if (previousConformedValue && requireDecimal) {\n const conformedWithoutSeparator = rawValue.split(thousandSymbol).join('');\n const previousConformedValueWithoutDecimalSymbolAndSeparator =\n previousConformedValue\n .split(thousandSymbol)\n .join('')\n .split(decimalSymbol)\n .join('');\n\n // Forbid removal of decimal separator if decimal part is required\n if (\n conformedWithoutSeparator ===\n previousConformedValueWithoutDecimalSymbolAndSeparator\n ) {\n rawValue = previousConformedValue;\n }\n }\n\n const isNegative =\n (rawValue[0] === '-' || rawValue[0] === CHAR_EN_DASH) && allowNegative;\n\n if (\n isDecimalSymbol(rawValue, decimalSymbol, autoCorrectDecimalSymbol) &&\n allowDecimal\n ) {\n return ['0', decimalSymbol, TUI_DIGIT_REGEXP];\n }\n\n if (isNegative) {\n rawValue = rawValue.substr(1);\n }\n\n const decimalIndex = getDecimalSymbolIndex(\n rawValue,\n decimalSymbol,\n autoCorrectDecimalSymbol,\n );\n const hasDecimal = decimalIndex !== -1;\n const integer = hasDecimal ? rawValue.slice(0, decimalIndex) : rawValue;\n const thousandSeparators = integer.match(new RegExp(thousandSymbol, 'g')) || [];\n const integerCapped = integerLimit\n ? integer.slice(0, integerLimit + thousandSeparators.length)\n : integer;\n const integerCappedClean = integerCapped\n .replace(TUI_NON_DIGITS_REGEXP, '')\n .replace(/^0+(?!\\.|$)/, '0');\n const withSeparator = addThousandsSeparator(integerCappedClean, thousandSymbol);\n const mask = convertToMask(withSeparator);\n\n if ((hasDecimal && allowDecimal) || requireDecimal) {\n const fraction = hasDecimal\n ? convertToMask(\n rawValue.slice(decimalIndex + 1).replace(TUI_NON_DIGITS_REGEXP, ''),\n )\n : [];\n const fractionCapped = decimalLimit\n ? fraction.slice(0, decimalLimit)\n : fraction;\n\n if (rawValue[decimalIndex] !== otherDecimalSymbol(decimalSymbol)) {\n mask.push(MASK_CARET_TRAP);\n }\n\n mask.push(decimalSymbol, MASK_CARET_TRAP, ...fractionCapped);\n\n for (let i = 0; i < decimalLimit - fractionCapped.length; i++) {\n mask.push(TUI_DIGIT_REGEXP);\n }\n }\n\n if (isNegative) {\n if (mask.length === 0) {\n mask.push(TUI_DIGIT_REGEXP);\n }\n\n mask.unshift('-');\n }\n\n return preventLeadingZeroes(mask);\n };\n}\n\nfunction preventLeadingZeroes(mask: Array<string | RegExp>): Array<string | RegExp> {\n const firstDigitIndex = mask.indexOf(TUI_DIGIT_REGEXP);\n\n if (firstDigitIndex !== -1 && mask[firstDigitIndex + 1] === TUI_DIGIT_REGEXP) {\n mask[firstDigitIndex] = NON_ZERO_DIGIT;\n }\n\n return mask;\n}\n\nfunction getDecimalSymbolIndex(\n str: string,\n decimalSymbol: TuiDecimalSymbol,\n autoCorrectDecimalSymbol: boolean,\n): number {\n if (!autoCorrectDecimalSymbol) {\n return str.lastIndexOf(decimalSymbol);\n }\n\n return Math.max(\n str.lastIndexOf(decimalSymbol),\n str.lastIndexOf(otherDecimalSymbol(decimalSymbol)),\n );\n}\n\nfunction isDecimalSymbol(\n str: string,\n decimalSymbol: TuiDecimalSymbol,\n autoCorrectDecimalSymbol: boolean,\n): boolean {\n if (autoCorrectDecimalSymbol) {\n return /^[,.]$/.test(str);\n }\n\n return str === decimalSymbol;\n}\n\nfunction convertToMask(strNumber: string): Array<string | RegExp> {\n return strNumber\n .split('')\n .map(char => (TUI_DIGIT_REGEXP.test(char) ? TUI_DIGIT_REGEXP : char));\n}\n\nfunction addThousandsSeparator(strNumber: string, thousandSymbol: string): string {\n return strNumber.length > 3\n ? strNumber.replace(/\\B(?=(\\d{3})+(?!\\d))/g, thousandSymbol)\n : strNumber;\n}\n","export function maskedMoneyValueIsEmpty(value: string): boolean {\n switch (value) {\n case '':\n case '-':\n case ',':\n case '-,':\n return true;\n default:\n return false;\n }\n}\n","import {TuiDecimalSymbol} from '@taiga-ui/core/types';\n\nexport function maskedNumberStringToNumber(\n value: string,\n decimalsSymbol: TuiDecimalSymbol,\n thousandSymbol: string,\n): number {\n return parseFloat(\n value.split(thousandSymbol).join('').split(decimalsSymbol).join('.'),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAUA;;;SAGgB,gCAAgC,CAC5C,YAAwB,EACxB,aAAqC,EACrC,cAA4C,EAC5C,WAA8B;IAH9B,6BAAA,EAAA,gBAAwB;IACxB,8BAAA,EAAA,mBAAqC;IACrC,+BAAA,EAAA,oCAA4C;IAG5C,SAAS,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC;IACjD,SAAS,CAAC,MAAM,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,QAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,IAAC,CAAC,CAAC;AAC9E,CAAC;AAED,SAAS,qBAAqB,CAAC,SAAiB,EAAE,cAAsB;IACpE,OAAO,SAAS,CAAC,MAAM,GAAG,CAAC;UACrB,SAAS,CAAC,OAAO,CAAC,uBAAuB,EAAE,cAAc,CAAC;UAC1D,SAAS,CAAC;AACpB;;SChKgB,uBAAuB,CAAC,KAAa;IACjD,QAAQ,KAAK;QACT,KAAK,EAAE,CAAC;QACR,KAAK,GAAG,CAAC;QACT,KAAK,GAAG,CAAC;QACT,KAAK,IAAI;YACL,OAAO,IAAI,CAAC;QAChB;YACI,OAAO,KAAK,CAAC;KACpB;AACL;;SCRgB,0BAA0B,CACtC,KAAa,EACb,cAAgC,EAChC,cAAsB;IAEtB,OAAO,UAAU,CACb,KAAK,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CACvE,CAAC;AACN;;ACVA;;;;;;"}
1
+ {"version":3,"file":"taiga-ui-core-utils-mask.js","sources":["ng://@taiga-ui/core/utils/mask/create-auto-corrected-money-pipe.ts","ng://@taiga-ui/core/utils/mask/create-correction-mask.ts","ng://@taiga-ui/core/utils/mask/create-number-mask.ts","ng://@taiga-ui/core/utils/mask/masked-money-value-is-empty.ts","ng://@taiga-ui/core/utils/mask/masked-number-string-to-number.ts","ng://@taiga-ui/core/utils/mask/taiga-ui-core-utils-mask.ts"],"sourcesContent":["import {\n CHAR_NO_BREAK_SPACE,\n getDocumentOrShadowRoot,\n isNativeFocused,\n isSafari,\n tuiAssert,\n} from '@taiga-ui/cdk';\nimport {TuiTextMaskPipeHandler} from '@taiga-ui/core/mask';\nimport {TuiDecimalSymbol} from '@taiga-ui/core/types';\n\n/**\n * Used to finish a number with zeros to a given precision\n */\nexport function tuiCreateAutoCorrectedNumberPipe(\n decimalLimit: number = 0,\n decimalSymbol: TuiDecimalSymbol = ',',\n thousandSymbol: string = CHAR_NO_BREAK_SPACE,\n nativeInput?: HTMLInputElement,\n): TuiTextMaskPipeHandler {\n tuiAssert.assert(Number.isInteger(decimalLimit));\n tuiAssert.assert(decimalLimit >= 0);\n\n // Guess for which browser I need this :)\n let previousCaret = -1;\n\n const unlucky = !!nativeInput && isSafari(nativeInput);\n\n if (nativeInput && unlucky) {\n nativeInput.addEventListener('beforeinput', () => {\n previousCaret = nativeInput.selectionStart || 0;\n });\n }\n\n return (conformedValue, config) => {\n // remove these hacks after text mask library has changed\n if (nativeInput && unlucky && isNativeFocused(nativeInput)) {\n const caret = calculateSafariCaret(\n config.previousConformedValue,\n conformedValue,\n previousCaret,\n );\n\n setTimeout(() => {\n nativeInput.setSelectionRange(caret, caret);\n });\n }\n\n if (\n nativeInput &&\n nativeInput.ownerDocument !== getDocumentOrShadowRoot(nativeInput) &&\n isNativeFocused(nativeInput) &&\n config.currentCaretPosition\n ) {\n const realCaretPosition =\n config.currentCaretPosition +\n calculateCaretGap(\n config.previousConformedValue,\n conformedValue,\n thousandSymbol,\n );\n\n setTimeout(() => {\n nativeInput.setSelectionRange(realCaretPosition, realCaretPosition);\n });\n }\n\n if (conformedValue === '' || !decimalLimit) {\n return {value: conformedValue};\n }\n\n const withDecimalSymbol = addDecimalSymbolIfNeeded(conformedValue, decimalSymbol);\n const decimalPart = withDecimalSymbol.split(decimalSymbol)[1];\n const zeroPaddingSize = decimalLimit - decimalPart.length;\n\n return {\n value: withDecimalSymbol + '0'.repeat(zeroPaddingSize),\n };\n };\n}\n\nfunction addDecimalSymbolIfNeeded(\n value: string,\n decimalSymbol: TuiDecimalSymbol = ',',\n): string {\n return value.indexOf(decimalSymbol) === -1 ? value + decimalSymbol : value;\n}\n\nfunction calculateSafariCaret(\n previousValue: string = '',\n current: string,\n previousCaret: number,\n decimalSymbol: string = ',',\n): number {\n const tailRegex = new RegExp(`${decimalSymbol}.+`);\n const previousWithoutTail = previousValue.replace(tailRegex, '');\n const currentWithoutTail = current.replace(tailRegex, '');\n\n const pasteOrCutOperation =\n Math.abs(previousWithoutTail.length - currentWithoutTail.length) > 2;\n\n if (pasteOrCutOperation) {\n return current.length;\n }\n\n if (previousValue.length === current.length) {\n if (previousValue.indexOf(decimalSymbol) <= previousCaret) {\n return calculateChangedTailIndex(previousValue, current);\n }\n\n return previousWithoutTail === currentWithoutTail\n ? previousCaret - 1\n : previousCaret + 1;\n }\n\n if (previousValue.length === 0) {\n return 1;\n }\n\n const changeLength = current.length - previousValue.length;\n\n return previousCaret + changeLength;\n}\n\nfunction calculateChangedTailIndex(previous: string, current: string): number {\n for (let i = 0; i < current.length; i++) {\n if (previous[i] !== current[i]) {\n return current[i] === '0' ? i : i + 1;\n }\n }\n\n return current.length;\n}\n\nfunction calculateCaretGap(\n previousValue: string = '',\n current: string,\n thousandSymbol: string,\n): number {\n const pasteOrCutOperation = Math.abs(previousValue.length - current.length) > 2;\n\n if (pasteOrCutOperation) {\n return 0;\n }\n\n const wereSpaces = previousValue.split(thousandSymbol).length;\n const nowSpaces = current.split(thousandSymbol).length;\n\n return nowSpaces - wereSpaces;\n}\n","import {tuiAssert} from '@taiga-ui/cdk';\nimport {MASK_CARET_TRAP} from '@taiga-ui/core/constants';\nimport {\n TuiTextMaskCorrectionHandler,\n TuiTextMaskList,\n TuiTextMaskListHandler,\n} from '@taiga-ui/core/mask';\n\nconst ASSERTION = 'Correction function must return single char or null';\n\nexport function tuiCreateCorrectionMask(\n allowed: RegExp,\n correctionHandler: TuiTextMaskCorrectionHandler,\n): TuiTextMaskListHandler {\n return rawValue => {\n const mask = rawValue.split('').reduce<TuiTextMaskList>((result, char, index) => {\n const corrected = correctionHandler(char, index);\n\n tuiAssert.assert(corrected === null || corrected.length === 1, ASSERTION);\n\n if (!allowed.test(char) && !corrected) {\n return result;\n }\n\n if (allowed.test(char)) {\n return [...result, allowed];\n }\n\n if (corrected) {\n return [...result, corrected, MASK_CARET_TRAP];\n }\n\n return result;\n }, []);\n const lastIndex = mask.lastIndexOf(MASK_CARET_TRAP);\n const filtered = mask.filter(\n (item, index) => item !== MASK_CARET_TRAP || index === lastIndex,\n );\n\n return filtered.some(item => item !== allowed)\n ? [...filtered, allowed]\n : filtered;\n };\n}\n","import {CHAR_EN_DASH, CHAR_NO_BREAK_SPACE, tuiAssert} from '@taiga-ui/cdk';\nimport {\n MASK_CARET_TRAP,\n TUI_DIGIT_REGEXP,\n TUI_LEADING_ZEROES_REGEXP,\n TUI_NON_DIGITS_REGEXP,\n} from '@taiga-ui/core/constants';\nimport {TuiNumberMaskOptions, TuiTextMaskListHandler} from '@taiga-ui/core/mask';\nimport {TuiDecimalSymbol} from '@taiga-ui/core/types';\nimport {otherDecimalSymbol} from '@taiga-ui/core/utils/format';\n\nconst NON_ZERO_DIGIT = /[1-9]/;\n\n/**\n * Adaptation for {@link https://github.com/text-mask/text-mask/tree/master/addons#createnumbermask `createNumberMask`}\n * @todo TODO: autocCorrectDecimalSymbol is no longer needed. Remove it in 3.0\n */\nexport function tuiCreateNumberMask({\n allowDecimal = false,\n decimalSymbol = ',',\n thousandSymbol = CHAR_NO_BREAK_SPACE,\n autoCorrectDecimalSymbol = true,\n decimalLimit = 2,\n requireDecimal = false,\n allowNegative = false,\n integerLimit = 0,\n}: TuiNumberMaskOptions = {}): TuiTextMaskListHandler {\n tuiAssert.assert(Number.isInteger(decimalLimit));\n tuiAssert.assert(decimalLimit > 0);\n tuiAssert.assert(Number.isInteger(integerLimit));\n tuiAssert.assert(integerLimit >= 0);\n\n return (rawValue, {previousConformedValue}) => {\n if (previousConformedValue && requireDecimal) {\n const conformedWithoutSeparator = rawValue.split(thousandSymbol).join('');\n const previousConformedValueWithoutDecimalSymbolAndSeparator =\n previousConformedValue\n .split(thousandSymbol)\n .join('')\n .split(decimalSymbol)\n .join('');\n\n // Forbid removal of decimal separator if decimal part is required\n if (\n conformedWithoutSeparator ===\n previousConformedValueWithoutDecimalSymbolAndSeparator\n ) {\n rawValue = previousConformedValue;\n }\n }\n\n const isNegative =\n (rawValue[0] === '-' || rawValue[0] === CHAR_EN_DASH) && allowNegative;\n\n if (\n isDecimalSymbol(rawValue, decimalSymbol, autoCorrectDecimalSymbol) &&\n allowDecimal\n ) {\n return ['0', decimalSymbol, TUI_DIGIT_REGEXP];\n }\n\n if (isNegative) {\n rawValue = rawValue.substr(1);\n }\n\n const decimalIndex = getDecimalSymbolIndex(\n rawValue,\n decimalSymbol,\n autoCorrectDecimalSymbol,\n );\n const hasDecimal = decimalIndex !== -1;\n const integer = hasDecimal ? rawValue.slice(0, decimalIndex) : rawValue;\n const thousandSeparators = integer.match(new RegExp(thousandSymbol, 'g')) || [];\n const integerCapped = integerLimit\n ? integer.slice(0, integerLimit + thousandSeparators.length)\n : integer;\n const integerCappedClean = integerCapped.replace(TUI_NON_DIGITS_REGEXP, '');\n const [leadingZerosMatch] = integerCappedClean.match(\n TUI_LEADING_ZEROES_REGEXP,\n ) || [''];\n const leadingZerosAmount = leadingZerosMatch.length;\n const integerCappedZerosClean = integerCappedClean\n .replace(/^0+(?!\\.|$)/, '')\n .trim();\n const withSeparator = addThousandsSeparator(\n integerCappedZerosClean,\n thousandSymbol,\n );\n const mask = convertToMask(withSeparator);\n\n if ((hasDecimal && allowDecimal) || requireDecimal) {\n const fraction = hasDecimal\n ? convertToMask(\n rawValue.slice(decimalIndex + 1).replace(TUI_NON_DIGITS_REGEXP, ''),\n )\n : [];\n const fractionCapped = decimalLimit\n ? fraction.slice(0, decimalLimit)\n : fraction;\n\n if (rawValue[decimalIndex] !== otherDecimalSymbol(decimalSymbol)) {\n mask.push(MASK_CARET_TRAP);\n }\n\n mask.push(decimalSymbol, MASK_CARET_TRAP, ...fractionCapped);\n\n for (let i = 0; i < decimalLimit - fractionCapped.length; i++) {\n mask.push(TUI_DIGIT_REGEXP);\n }\n }\n\n const isOnlyZeroDigit = mask.length === 1 && integerCappedZerosClean === '0';\n\n if (isNegative) {\n if (mask.length === 0) {\n mask.push(TUI_DIGIT_REGEXP);\n }\n\n mask.unshift('-');\n }\n\n return preventLeadingZeroes(mask, isOnlyZeroDigit, leadingZerosAmount);\n };\n}\n\nfunction preventLeadingZeroes(\n mask: Array<string | RegExp>,\n isOnlyZeroDigit: boolean = false,\n leadingZerosAmount: number = 0,\n): Array<string | RegExp> {\n if (isOnlyZeroDigit || leadingZerosAmount === 0) {\n return mask;\n }\n\n const firstDigitIndex = mask.indexOf(TUI_DIGIT_REGEXP);\n\n if (firstDigitIndex === -1) {\n return mask;\n }\n\n const secondMaskDigit = mask[firstDigitIndex + 1];\n const isCaretTrap = secondMaskDigit === MASK_CARET_TRAP;\n\n if (isCaretTrap && leadingZerosAmount === 1) {\n return mask;\n } else if (isCaretTrap) {\n mask.unshift(NON_ZERO_DIGIT);\n\n return mask;\n }\n\n mask[firstDigitIndex] = NON_ZERO_DIGIT;\n\n return mask;\n}\n\nfunction getDecimalSymbolIndex(\n str: string,\n decimalSymbol: TuiDecimalSymbol,\n autoCorrectDecimalSymbol: boolean,\n): number {\n if (!autoCorrectDecimalSymbol) {\n return str.lastIndexOf(decimalSymbol);\n }\n\n return Math.max(\n str.lastIndexOf(decimalSymbol),\n str.lastIndexOf(otherDecimalSymbol(decimalSymbol)),\n );\n}\n\nfunction isDecimalSymbol(\n str: string,\n decimalSymbol: TuiDecimalSymbol,\n autoCorrectDecimalSymbol: boolean,\n): boolean {\n if (autoCorrectDecimalSymbol) {\n return /^[,.]$/.test(str);\n }\n\n return str === decimalSymbol;\n}\n\nfunction convertToMask(strNumber: string): Array<string | RegExp> {\n return strNumber\n .split('')\n .map(char => (TUI_DIGIT_REGEXP.test(char) ? TUI_DIGIT_REGEXP : char));\n}\n\nfunction addThousandsSeparator(strNumber: string, thousandSymbol: string): string {\n return strNumber.length > 3\n ? strNumber.replace(/\\B(?=(\\d{3})+(?!\\d))/g, thousandSymbol)\n : strNumber;\n}\n","export function maskedMoneyValueIsEmpty(value: string): boolean {\n switch (value) {\n case '':\n case '-':\n case ',':\n case '-,':\n return true;\n default:\n return false;\n }\n}\n","import {TuiDecimalSymbol} from '@taiga-ui/core/types';\n\nexport function maskedNumberStringToNumber(\n value: string,\n decimalsSymbol: TuiDecimalSymbol,\n thousandSymbol: string,\n): number {\n return parseFloat(\n value.split(thousandSymbol).join('').split(decimalsSymbol).join('.'),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAUA;;;SAGgB,gCAAgC,CAC5C,YAAwB,EACxB,aAAqC,EACrC,cAA4C,EAC5C,WAA8B;IAH9B,6BAAA,EAAA,gBAAwB;IACxB,8BAAA,EAAA,mBAAqC;IACrC,+BAAA,EAAA,oCAA4C;IAG5C,SAAS,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC;IACjD,SAAS,CAAC,MAAM,CAAC,YAAY,IAAI,CAAC,CAAC,CAAC;;IAGpC,IAAI,aAAa,GAAG,CAAC,CAAC,CAAC;IAEvB,IAAM,OAAO,GAAG,CAAC,CAAC,WAAW,IAAI,QAAQ,CAAC,WAAW,CAAC,CAAC;IAEvD,IAAI,WAAW,IAAI,OAAO,EAAE;QACxB,WAAW,CAAC,gBAAgB,CAAC,aAAa,EAAE;YACxC,aAAa,GAAG,WAAW,CAAC,cAAc,IAAI,CAAC,CAAC;SACnD,CAAC,CAAC;KACN;IAED,OAAO,UAAC,cAAc,EAAE,MAAM;;QAE1B,IAAI,WAAW,IAAI,OAAO,IAAI,eAAe,CAAC,WAAW,CAAC,EAAE;YACxD,IAAM,OAAK,GAAG,oBAAoB,CAC9B,MAAM,CAAC,sBAAsB,EAC7B,cAAc,EACd,aAAa,CAChB,CAAC;YAEF,UAAU,CAAC;gBACP,WAAW,CAAC,iBAAiB,CAAC,OAAK,EAAE,OAAK,CAAC,CAAC;aAC/C,CAAC,CAAC;SACN;QAED,IACI,WAAW;YACX,WAAW,C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CAAC;SACT,GAAG,CAAC,UAAA,IAAI,IAAI,QAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,IAAC,CAAC,CAAC;AAC9E,CAAC;AAED,SAAS,qBAAqB,CAAC,SAAiB,EAAE,cAAsB;IACpE,OAAO,SAAS,CAAC,MAAM,GAAG,CAAC;UACrB,SAAS,CAAC,OAAO,CAAC,uBAAuB,EAAE,cAAc,CAAC;UAC1D,SAAS,CAAC;AACpB;;SCjMgB,uBAAuB,CAAC,KAAa;IACjD,QAAQ,KAAK;QACT,KAAK,EAAE,CAAC;QACR,KAAK,GAAG,CAAC;QACT,KAAK,GAAG,CAAC;QACT,KAAK,IAAI;YACL,OAAO,IAAI,CAAC;QAChB;YACI,OAAO,KAAK,CAAC;KACpB;AACL;;SCRgB,0BAA0B,CACtC,KAAa,EACb,cAAgC,EAChC,cAAsB;IAEtB,OAAO,UAAU,CACb,KAAK,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CACvE,CAAC;AACN;;ACVA;;;;;;"}
@@ -14,15 +14,13 @@ function colorFallback(color) {
14
14
  }
15
15
  }
16
16
 
17
- var BORDER_SMALL = 0.75;
18
- var BORDER_LARGE = 1;
19
17
  var ITEM_SIZE = 1.5;
20
18
  var CONTENT_SIZE = 2.5;
21
- function getBorder(sizeBig, hasIcon, hasCleaner, hasTooltip, hasContent) {
19
+ function getBorder(hasIcon, hasCleaner, hasTooltip, hasContent) {
22
20
  if (hasCleaner === void 0) { hasCleaner = false; }
23
21
  if (hasTooltip === void 0) { hasTooltip = false; }
24
22
  if (hasContent === void 0) { hasContent = false; }
25
- var border = sizeBig ? BORDER_LARGE : BORDER_SMALL;
23
+ var border = 0;
26
24
  if (hasIcon) {
27
25
  border += ITEM_SIZE;
28
26
  }
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-core-utils-miscellaneous.js","sources":["ng://@taiga-ui/core/utils/miscellaneous/color-fallback.ts","ng://@taiga-ui/core/utils/miscellaneous/get-border.ts","ng://@taiga-ui/core/utils/miscellaneous/icons-path-factory.ts","ng://@taiga-ui/core/utils/miscellaneous/is-editing-key.ts","ng://@taiga-ui/core/utils/miscellaneous/is-presumed-hTMLString.ts","ng://@taiga-ui/core/utils/miscellaneous/size-bigger.ts","ng://@taiga-ui/core/utils/miscellaneous/taiga-ui-core-utils-miscellaneous.ts"],"sourcesContent":["/** @deprecated */\nexport function colorFallback(color: string | null): string {\n switch (color) {\n case 'secondary':\n return 'var(--tui-info-fill)';\n case 'error':\n return 'var(--tui-error-fill)';\n case 'success':\n return 'var(--tui-success-fill)';\n default:\n return `var(--tui-${color || 'base-05'})`;\n }\n}\n","const BORDER_SMALL = 0.75;\nconst BORDER_LARGE = 1;\nconst ITEM_SIZE = 1.5;\nconst CONTENT_SIZE = 2.5;\n\nexport function getBorder(\n sizeBig: boolean,\n hasIcon: boolean,\n hasCleaner: boolean = false,\n hasTooltip: boolean = false,\n hasContent: boolean = false,\n): number {\n let border = sizeBig ? BORDER_LARGE : BORDER_SMALL;\n\n if (hasIcon) {\n border += ITEM_SIZE;\n }\n\n if (hasCleaner) {\n border += ITEM_SIZE;\n }\n\n if (hasTooltip) {\n border += ITEM_SIZE;\n }\n\n if (hasContent) {\n border += CONTENT_SIZE;\n }\n\n return border;\n}\n","import {TuiStringHandler} from '@taiga-ui/cdk';\nimport {DEFAULT_ICONS_PATH} from '@taiga-ui/core/constants';\n\nexport function iconsPathFactory(staticPath: string): TuiStringHandler<string> {\n const base =\n staticPath[staticPath.length - 1] === '/' ? staticPath : staticPath + '/';\n\n return name => {\n if (name.startsWith('tuiIcon')) {\n return `${base}${name}.svg#${name}`;\n }\n\n return DEFAULT_ICONS_PATH(name);\n };\n}\n","import {tuiEditingKeys} from '@taiga-ui/core/constants';\n\n/**\n * Check if pressed key is interactive in terms of input field\n */\nexport function isEditingKey(key: string): boolean {\n return key.length === 1 || tuiEditingKeys.indexOf(key) !== -1;\n}\n","export function isPresumedHTMLString(candidate: string): boolean {\n const trimmed = candidate.trim();\n\n return trimmed.startsWith('<') && trimmed.endsWith('>');\n}\n","import {TuiSizeXS, TuiSizeXXL} from '@taiga-ui/core/types';\n\nconst SIZES: ReadonlyArray<TuiSizeXS | TuiSizeXXL> = ['xs', 's', 'm', 'l', 'xl', 'xxl'];\n\n/**\n * Compares size constants to determine if first size is bigger than the second\n *\n * @param size size that we need to compare\n * @param biggerThanSize size to compare with, 's' by default\n */\nexport function sizeBigger(\n size: TuiSizeXS | TuiSizeXXL,\n biggerThanSize: TuiSizeXS | TuiSizeXXL = 's',\n): boolean {\n return SIZES.indexOf(size) > SIZES.indexOf(biggerThanSize);\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAAA;SACgB,aAAa,CAAC,KAAoB;IAC9C,QAAQ,KAAK;QACT,KAAK,WAAW;YACZ,OAAO,sBAAsB,CAAC;QAClC,KAAK,OAAO;YACR,OAAO,uBAAuB,CAAC;QACnC,KAAK,SAAS;YACV,OAAO,yBAAyB,CAAC;QACrC;YACI,OAAO,gBAAa,KAAK,IAAI,SAAS,OAAG,CAAC;KACjD;AACL;;ACZA,IAAM,YAAY,GAAG,IAAI,CAAC;AAC1B,IAAM,YAAY,GAAG,CAAC,CAAC;AACvB,IAAM,SAAS,GAAG,GAAG,CAAC;AACtB,IAAM,YAAY,GAAG,GAAG,CAAC;SAET,SAAS,CACrB,OAAgB,EAChB,OAAgB,EAChB,UAA2B,EAC3B,UAA2B,EAC3B,UAA2B;IAF3B,2BAAA,EAAA,kBAA2B;IAC3B,2BAAA,EAAA,kBAA2B;IAC3B,2BAAA,EAAA,kBAA2B;IAE3B,IAAI,MAAM,GAAG,OAAO,GAAG,YAAY,GAAG,YAAY,CAAC;IAEnD,IAAI,OAAO,EAAE;QACT,MAAM,IAAI,SAAS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1
+ {"version":3,"file":"taiga-ui-core-utils-miscellaneous.js","sources":["ng://@taiga-ui/core/utils/miscellaneous/color-fallback.ts","ng://@taiga-ui/core/utils/miscellaneous/get-border.ts","ng://@taiga-ui/core/utils/miscellaneous/icons-path-factory.ts","ng://@taiga-ui/core/utils/miscellaneous/is-editing-key.ts","ng://@taiga-ui/core/utils/miscellaneous/is-presumed-hTMLString.ts","ng://@taiga-ui/core/utils/miscellaneous/size-bigger.ts","ng://@taiga-ui/core/utils/miscellaneous/taiga-ui-core-utils-miscellaneous.ts"],"sourcesContent":["/** @deprecated */\nexport function colorFallback(color: string | null): string {\n switch (color) {\n case 'secondary':\n return 'var(--tui-info-fill)';\n case 'error':\n return 'var(--tui-error-fill)';\n case 'success':\n return 'var(--tui-success-fill)';\n default:\n return `var(--tui-${color || 'base-05'})`;\n }\n}\n","const ITEM_SIZE = 1.5;\nconst CONTENT_SIZE = 2.5;\n\nexport function getBorder(\n hasIcon: boolean,\n hasCleaner: boolean = false,\n hasTooltip: boolean = false,\n hasContent: boolean = false,\n): number {\n let border = 0;\n\n if (hasIcon) {\n border += ITEM_SIZE;\n }\n\n if (hasCleaner) {\n border += ITEM_SIZE;\n }\n\n if (hasTooltip) {\n border += ITEM_SIZE;\n }\n\n if (hasContent) {\n border += CONTENT_SIZE;\n }\n\n return border;\n}\n","import {TuiStringHandler} from '@taiga-ui/cdk';\nimport {DEFAULT_ICONS_PATH} from '@taiga-ui/core/constants';\n\nexport function iconsPathFactory(staticPath: string): TuiStringHandler<string> {\n const base =\n staticPath[staticPath.length - 1] === '/' ? staticPath : staticPath + '/';\n\n return name => {\n if (name.startsWith('tuiIcon')) {\n return `${base}${name}.svg#${name}`;\n }\n\n return DEFAULT_ICONS_PATH(name);\n };\n}\n","import {tuiEditingKeys} from '@taiga-ui/core/constants';\n\n/**\n * Check if pressed key is interactive in terms of input field\n */\nexport function isEditingKey(key: string): boolean {\n return key.length === 1 || tuiEditingKeys.indexOf(key) !== -1;\n}\n","export function isPresumedHTMLString(candidate: string): boolean {\n const trimmed = candidate.trim();\n\n return trimmed.startsWith('<') && trimmed.endsWith('>');\n}\n","import {TuiSizeXS, TuiSizeXXL} from '@taiga-ui/core/types';\n\nconst SIZES: ReadonlyArray<TuiSizeXS | TuiSizeXXL> = ['xs', 's', 'm', 'l', 'xl', 'xxl'];\n\n/**\n * Compares size constants to determine if first size is bigger than the second\n *\n * @param size size that we need to compare\n * @param biggerThanSize size to compare with, 's' by default\n */\nexport function sizeBigger(\n size: TuiSizeXS | TuiSizeXXL,\n biggerThanSize: TuiSizeXS | TuiSizeXXL = 's',\n): boolean {\n return SIZES.indexOf(size) > SIZES.indexOf(biggerThanSize);\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAAA;SACgB,aAAa,CAAC,KAAoB;IAC9C,QAAQ,KAAK;QACT,KAAK,WAAW;YACZ,OAAO,sBAAsB,CAAC;QAClC,KAAK,OAAO;YACR,OAAO,uBAAuB,CAAC;QACnC,KAAK,SAAS;YACV,OAAO,yBAAyB,CAAC;QACrC;YACI,OAAO,gBAAa,KAAK,IAAI,SAAS,OAAG,CAAC;KACjD;AACL;;ACZA,IAAM,SAAS,GAAG,GAAG,CAAC;AACtB,IAAM,YAAY,GAAG,GAAG,CAAC;SAET,SAAS,CACrB,OAAgB,EAChB,UAA2B,EAC3B,UAA2B,EAC3B,UAA2B;IAF3B,2BAAA,EAAA,kBAA2B;IAC3B,2BAAA,EAAA,kBAA2B;IAC3B,2BAAA,EAAA,kBAA2B;IAE3B,IAAI,MAAM,GAAG,CAAC,CAAC;IAEf,IAAI,OAAO,EAAE;QACT,MAAM,IAAI,SAAS,CAAC;KACvB;IAED,IAAI,UAAU,EAAE;QACZ,MAAM,IAAI,SAAS,CAAC;KACvB;IAED,IAAI,UAAU,EAAE;QACZ,MAAM,IAAI,SAAS,CAAC;KACvB;IAED,IAAI,UAAU,EAAE;QACZ,MAAM,IAAI,YAAY,CAAC;KAC1B;IAED,OAAO,MAAM,CAAC;AAClB;;SCzBgB,gBAAgB,CAAC,UAAkB;IAC/C,IAAM,IAAI,GACN,UAAU,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,GAAG,GAAG,UAAU,GAAG,UAAU,GAAG,GAAG,CAAC;IAE9E,OAAO,UAAA,IAAI;QACP,IAAI,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE;YAC5B,OAAO,KAAG,IAAI,GAAG,IAAI,aAAQ,IAAM,CAAC;SACvC;QAED,OAAO,kBAAkB,CAAC,IAAI,CAAC,CAAC;KACnC,CAAC;AACN;;ACZA;;;SAGgB,YAAY,CAAC,GAAW;IACpC,OAAO,GAAG,CAAC,MAAM,KAAK,CAAC,IAAI,cAAc,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC;AAClE;;SCPgB,oBAAoB,CAAC,SAAiB;IAClD,IAAM,OAAO,GAAG,SAAS,CAAC,IAAI,EAAE,CAAC;IAEjC,OAAO,OAAO,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;AAC5D;;ACFA,IAAM,KAAK,GAA0C,CAAC,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC;AAExF;;;;;;SAMgB,UAAU,CACtB,IAA4B,EAC5B,cAA4C;IAA5C,+BAAA,EAAA,oBAA4C;IAE5C,OAAO,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;AAC/D;;ACfA;;;;;;"}
@@ -9,3 +9,4 @@ export * from './number-format-settings';
9
9
  export * from './value-content-context';
10
10
  export * from './with-optional-min-max';
11
11
  export * from './notification-options';
12
+ export * from './media';
@@ -0,0 +1,6 @@
1
+ export interface TuiMedia {
2
+ readonly mobile: number;
3
+ readonly tablet?: number;
4
+ readonly desktopSmall: number;
5
+ readonly desktopLarge: number;
6
+ }
@@ -1 +1 @@
1
- {"__symbolic":"module","version":4,"metadata":{"TuiAnimationOptions":{"__symbolic":"interface"},"TuiDataListAccessor":{"__symbolic":"interface"},"TuiDataListHost":{"__symbolic":"interface"},"TuiDialogContext":{"__symbolic":"interface"},"TuiDialogOptions":{"__symbolic":"interface"},"TuiDropdown":{"__symbolic":"interface"},"TuiIconError":{"__symbolic":"interface"},"NumberFormatSettings":{"__symbolic":"interface"},"TuiValueContentContext":{"__symbolic":"interface"},"TuiWithOptionalMinMax":{"__symbolic":"interface"},"TuiWithOptionalMinMaxWithValue":{"__symbolic":"interface"},"TuiNotificationAutoClose":{"__symbolic":"interface"},"TuiNotificationOptions":{"__symbolic":"interface"},"TuiNotificationOptionsWithData":{"__symbolic":"interface"}},"origins":{"TuiAnimationOptions":"./animation-options","TuiDataListAccessor":"./data-list-accessor","TuiDataListHost":"./data-list-host","TuiDialogContext":"./dialog-context","TuiDialogOptions":"./dialog-options","TuiDropdown":"./dropdown-directive","TuiIconError":"./icon-error","NumberFormatSettings":"./number-format-settings","TuiValueContentContext":"./value-content-context","TuiWithOptionalMinMax":"./with-optional-min-max","TuiWithOptionalMinMaxWithValue":"./with-optional-min-max","TuiNotificationAutoClose":"./notification-options","TuiNotificationOptions":"./notification-options","TuiNotificationOptionsWithData":"./notification-options"},"importAs":"@taiga-ui/core/interfaces"}
1
+ {"__symbolic":"module","version":4,"metadata":{"TuiAnimationOptions":{"__symbolic":"interface"},"TuiDataListAccessor":{"__symbolic":"interface"},"TuiDataListHost":{"__symbolic":"interface"},"TuiDialogContext":{"__symbolic":"interface"},"TuiDialogOptions":{"__symbolic":"interface"},"TuiDropdown":{"__symbolic":"interface"},"TuiIconError":{"__symbolic":"interface"},"NumberFormatSettings":{"__symbolic":"interface"},"TuiValueContentContext":{"__symbolic":"interface"},"TuiWithOptionalMinMax":{"__symbolic":"interface"},"TuiWithOptionalMinMaxWithValue":{"__symbolic":"interface"},"TuiNotificationAutoClose":{"__symbolic":"interface"},"TuiNotificationOptions":{"__symbolic":"interface"},"TuiNotificationOptionsWithData":{"__symbolic":"interface"},"TuiMedia":{"__symbolic":"interface"}},"origins":{"TuiAnimationOptions":"./animation-options","TuiDataListAccessor":"./data-list-accessor","TuiDataListHost":"./data-list-host","TuiDialogContext":"./dialog-context","TuiDialogOptions":"./dialog-options","TuiDropdown":"./dropdown-directive","TuiIconError":"./icon-error","NumberFormatSettings":"./number-format-settings","TuiValueContentContext":"./value-content-context","TuiWithOptionalMinMax":"./with-optional-min-max","TuiWithOptionalMinMaxWithValue":"./with-optional-min-max","TuiNotificationAutoClose":"./notification-options","TuiNotificationOptions":"./notification-options","TuiNotificationOptionsWithData":"./notification-options","TuiMedia":"./media"},"importAs":"@taiga-ui/core/interfaces"}
@@ -1 +1 @@
1
- {"__symbolic":"module","version":4,"metadata":{"TuiPrimitiveYearMonthPaginationComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":11,"character":1},"arguments":[{"selector":"tui-primitive-year-month-pagination","template":"<tui-primitive-spin-button\n [focusable]=\"false\"\n [leftDisabled]=\"prevMonthDisabled\"\n [rightDisabled]=\"nextMonthDisabled\"\n (leftClick)=\"onPrevMonthClick()\"\n (rightClick)=\"onNextMonthClick()\"\n>\n {{value | tuiMonth | async}}\n <ng-container *ngIf=\"oneYear; else button\">\n {{value.formattedYear}}\n </ng-container>\n <ng-template #button>\n <button\n automation-id=\"tui-primitive-year-month-pagination__year-button\"\n tuiLink\n type=\"button\"\n [tuiFocusable]=\"false\"\n (click)=\"onYearClick()\"\n >\n {{value.formattedYear}}\n </button>\n </ng-template>\n</tui-primitive-spin-button>\n","styles":[":host{display:block}"]}]}],"members":{"value":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":19,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":20,"character":5}}]}],"min":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":23,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":24,"character":5}}]}],"max":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":27,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":28,"character":5}}]}],"valueChange":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":31,"character":5}}]}],"yearClick":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":34,"character":5}}]}],"onYearClick":[{"__symbolic":"method"}],"onPrevMonthClick":[{"__symbolic":"method"}],"onNextMonthClick":[{"__symbolic":"method"}],"appendValueWithLimit":[{"__symbolic":"method"}],"updateValue":[{"__symbolic":"method"}]}},"TuiPrimitiveYearMonthPaginationModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":9,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":11,"character":8},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiFocusableModule","line":12,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/components/primitive-spin-button","name":"TuiPrimitiveSpinButtonModule","line":13,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/components/link","name":"TuiLinkModule","line":14,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/pipes","name":"TuiMonthPipeModule","line":15,"character":8}],"declarations":[{"__symbolic":"reference","name":"TuiPrimitiveYearMonthPaginationComponent"}],"exports":[{"__symbolic":"reference","name":"TuiPrimitiveYearMonthPaginationComponent"}]}]}],"members":{}}},"origins":{"TuiPrimitiveYearMonthPaginationComponent":"./primitive-year-month-pagination.component","TuiPrimitiveYearMonthPaginationModule":"./primitive-year-month-pagination.module"},"importAs":"@taiga-ui/core/internal/primitive-year-month-pagination"}
1
+ {"__symbolic":"module","version":4,"metadata":{"TuiPrimitiveYearMonthPaginationComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":11,"character":1},"arguments":[{"selector":"tui-primitive-year-month-pagination","template":"<tui-primitive-spin-button\n [focusable]=\"false\"\n [leftDisabled]=\"prevMonthDisabled\"\n [rightDisabled]=\"nextMonthDisabled\"\n (leftClick)=\"onPrevMonthClick()\"\n (rightClick)=\"onNextMonthClick()\"\n>\n {{ value | tuiMonth | async }}\n <ng-container *ngIf=\"oneYear; else button\">\n {{ value.formattedYear }}\n </ng-container>\n <ng-template #button>\n <button\n automation-id=\"tui-primitive-year-month-pagination__year-button\"\n tuiLink\n type=\"button\"\n [tuiFocusable]=\"false\"\n (click)=\"onYearClick()\"\n >\n {{ value.formattedYear }}\n </button>\n </ng-template>\n</tui-primitive-spin-button>\n","styles":[":host{display:block}"]}]}],"members":{"value":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":19,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":20,"character":5}}]}],"min":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":23,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":24,"character":5}}]}],"max":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":27,"character":5}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiDefaultProp","line":28,"character":5}}]}],"valueChange":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":31,"character":5}}]}],"yearClick":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":34,"character":5}}]}],"onYearClick":[{"__symbolic":"method"}],"onPrevMonthClick":[{"__symbolic":"method"}],"onNextMonthClick":[{"__symbolic":"method"}],"appendValueWithLimit":[{"__symbolic":"method"}],"updateValue":[{"__symbolic":"method"}]}},"TuiPrimitiveYearMonthPaginationModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":9,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":11,"character":8},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiFocusableModule","line":12,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/components/primitive-spin-button","name":"TuiPrimitiveSpinButtonModule","line":13,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/components/link","name":"TuiLinkModule","line":14,"character":8},{"__symbolic":"reference","module":"@taiga-ui/core/pipes","name":"TuiMonthPipeModule","line":15,"character":8}],"declarations":[{"__symbolic":"reference","name":"TuiPrimitiveYearMonthPaginationComponent"}],"exports":[{"__symbolic":"reference","name":"TuiPrimitiveYearMonthPaginationComponent"}]}]}],"members":{}}},"origins":{"TuiPrimitiveYearMonthPaginationComponent":"./primitive-year-month-pagination.component","TuiPrimitiveYearMonthPaginationModule":"./primitive-year-month-pagination.module"},"importAs":"@taiga-ui/core/internal/primitive-year-month-pagination"}
@@ -1 +1 @@
1
- {"__symbolic":"module","version":4,"metadata":{"DEFAULT_ALERT_AUTOCLOSE_TIMEOUT":3000,"TuiNotificationAlertComponent":{"__symbolic":"class","arity":2,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":17,"character":1},"arguments":[{"selector":"tui-notification-alert","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy","line":19,"character":21},"member":"OnPush"},"providers":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":22,"character":16}],"template":"<tui-notification\n *ngIf=\"item.hasCloseButton else noClose\"\n [status]=\"item.status\"\n [hasIcon]=\"item.hasIcon\"\n (close)=\"closeNotification()\"\n>\n <label\n *ngIf=\"item.label\"\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__heading\"\n class=\"heading\"\n [content]=\"item.label\"\n [context]=\"context\"\n >\n </label>\n <div\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__content\"\n class=\"content\"\n [content]=\"item.content\"\n [context]=\"context\"\n ></div>\n</tui-notification>\n<ng-template #noClose>\n <tui-notification [status]=\"item.status\" [hasIcon]=\"item.hasIcon\">\n <label\n *ngIf=\"item.label\"\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__heading\"\n class=\"heading\"\n [content]=\"item.label\"\n [context]=\"context\"\n >\n </label>\n <div\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__content\"\n class=\"content\"\n [content]=\"item.content\"\n [context]=\"context\"\n ></div>\n </tui-notification>\n</ng-template>\n","styles":[":host{box-shadow:0 .5rem 1rem rgba(0,0,0,.16);display:block;border-radius:var(--tui-radius-m)}.heading{font:var(--tui-font-text-m);line-height:1.25rem;font-weight:700;margin:0}.content{color:var(--tui-text-01);word-wrap:break-word}.content:empty{display:none}"]}]}],"members":{"item":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":25,"character":5}}]}],"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":29,"character":9},"arguments":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef","line":29,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":30,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":30,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":31,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_NOTIFICATION_OPTIONS","line":31,"character":16}]}]],"parameters":[{"__symbolic":"reference","name":"ElementRef","module":"@angular/core","arguments":[{"__symbolic":"error","message":"Could not resolve type","line":29,"character":68,"context":{"typeName":"HTMLElement"},"module":"./notification-alert/notification-alert.component"}]},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":30,"character":62},{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"NotificationTokenOptions","line":32,"character":33}]}],"ngOnInit":[{"__symbolic":"method"}],"closeNotification":[{"__symbolic":"method"}],"calculateContext":[{"__symbolic":"method","decorators":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiPure","line":47,"character":5}]}],"initAutoClose":[{"__symbolic":"method"}]}},"TuiNotificationAlertModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":7,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":8,"character":14},{"__symbolic":"reference","module":"@tinkoff/ng-polymorpheus","name":"PolymorpheusModule","line":8,"character":28},{"__symbolic":"reference","module":"@taiga-ui/core/components/notification","name":"TuiNotificationModule","line":8,"character":48}],"declarations":[{"__symbolic":"reference","name":"TuiNotificationAlertComponent"}],"exports":[{"__symbolic":"reference","name":"TuiNotificationAlertComponent"}]}]}],"members":{}},"NotificationAlert":{"__symbolic":"class","arity":2,"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Observer","module":"rxjs","arguments":[{"__symbolic":"error","message":"Could not resolve type","line":25,"character":36,"context":{"typeName":"O"},"module":"./notification-alert/Notification-alert"}]},{"__symbolic":"reference","name":"PolymorpheusContent","module":"@tinkoff/ng-polymorpheus","arguments":[{"__symbolic":"reference","name":"TuiNotificationContentContext"}]},{"__symbolic":"error","message":"Could not resolve type","line":27,"character":34,"context":{"typeName":"Required"},"module":"./notification-alert/Notification-alert"}]}],"withData":[{"__symbolic":"method"}]}},"TuiNotificationsHostComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":12,"character":1},"arguments":[{"selector":"tui-notifications-host","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy","line":14,"character":21},"member":"OnPush"},"animations":[{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiFadeInList","line":17,"character":17},{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiSlideInRightList","line":17,"character":32},{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiHeightCollapseList","line":17,"character":53}],"template":"<ng-container *tuiLet=\"service.items$ | async as items\">\n <div\n *ngIf=\"items.length\"\n class=\"wrapper\"\n [@tuiFadeInList]=\"getAnimation(items.length)\"\n [@tuiHeightCollapseList]=\"getAnimation(items.length)\"\n [@tuiSlideInRightList]=\"getAnimation(items.length)\"\n >\n <tui-notification-alert\n *ngFor=\"let item of items\"\n class=\"alert\"\n role=\"alert\"\n [item]=\"item\"\n ></tui-notification-alert>\n </div>\n</ng-container>\n","styles":[":host{position:fixed;top:0;left:0;width:100%;height:0}.wrapper{width:18rem;margin-left:auto;padding:2rem 3rem 0 0;pointer-events:none}@media screen and (max-width:47.9375em){.wrapper{padding:1rem 1rem 0 0}}@media screen and (min-width:80em){.wrapper{width:23rem}}.alert{pointer-events:auto}.alert:not(:first-child){margin-top:.75rem}"]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":21,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_ANIMATION_OPTIONS","line":21,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":22,"character":9},"arguments":[{"__symbolic":"reference","name":"TuiNotificationsService"}]}]],"parameters":[{"__symbolic":"reference","module":"@angular/animations","name":"AnimationOptions","line":21,"character":65},{"__symbolic":"reference","name":"TuiNotificationsService"}]}],"getAnimation":[{"__symbolic":"method","decorators":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiPure","line":25,"character":5}]}]}},"TuiNotificationContentContext":{"__symbolic":"interface"},"NOTIFICATIONS_HOST":{"__symbolic":"reference","name":"TuiNotificationsHostComponent"},"TuiNotificationsModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":9,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":10,"character":14},{"__symbolic":"reference","name":"TuiNotificationAlertModule"},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiLetModule","line":10,"character":56}],"declarations":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"exports":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"entryComponents":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"providers":[{"provide":{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"},"useValue":{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}}]}]}],"members":{}},"TuiNotificationsService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":15,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":23,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_NOTIFICATION_OPTIONS","line":23,"character":16}]}]],"parameters":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"NotificationTokenOptions","line":24,"character":33}]}],"show":[{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"}]},"statics":{"ɵprov":{}}}},"origins":{"DEFAULT_ALERT_AUTOCLOSE_TIMEOUT":"./notification-alert/notification-alert.component","TuiNotificationAlertComponent":"./notification-alert/notification-alert.component","TuiNotificationAlertModule":"./notification-alert/notification-alert.module","NotificationAlert":"./notification-alert/Notification-alert","TuiNotificationsHostComponent":"./notifications-host/notifications-host.component","TuiNotificationContentContext":"./notification-content-context","NOTIFICATIONS_HOST":"./notifications-host/notifications-host.component","TuiNotificationsModule":"./notifications.module","TuiNotificationsService":"./notifications.service"},"importAs":"@taiga-ui/core/modules/notifications"}
1
+ {"__symbolic":"module","version":4,"metadata":{"DEFAULT_ALERT_AUTOCLOSE_TIMEOUT":3000,"TuiNotificationAlertComponent":{"__symbolic":"class","arity":2,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":17,"character":1},"arguments":[{"selector":"tui-notification-alert","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy","line":19,"character":21},"member":"OnPush"},"providers":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":22,"character":16}],"template":"<tui-notification\n *ngIf=\"item.hasCloseButton; else noClose\"\n [status]=\"item.status\"\n [hasIcon]=\"item.hasIcon\"\n (close)=\"closeNotification()\"\n>\n <label\n *ngIf=\"item.label\"\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__heading\"\n class=\"heading\"\n [content]=\"item.label\"\n [context]=\"context\"\n ></label>\n <div\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__content\"\n class=\"content\"\n [content]=\"item.content\"\n [context]=\"context\"\n ></div>\n</tui-notification>\n<ng-template #noClose>\n <tui-notification [status]=\"item.status\" [hasIcon]=\"item.hasIcon\">\n <label\n *ngIf=\"item.label\"\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__heading\"\n class=\"heading\"\n [content]=\"item.label\"\n [context]=\"context\"\n ></label>\n <div\n polymorpheus-outlet\n automation-id=\"tui-notification-alert__content\"\n class=\"content\"\n [content]=\"item.content\"\n [context]=\"context\"\n ></div>\n </tui-notification>\n</ng-template>\n","styles":[":host{box-shadow:0 .5rem 1rem rgba(0,0,0,.16);display:block;border-radius:var(--tui-radius-m)}.heading{font:var(--tui-font-text-m);line-height:1.25rem;font-weight:700;margin:0}.content{color:var(--tui-text-01);word-wrap:break-word}.content:empty{display:none}"]}]}],"members":{"item":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":25,"character":5}}]}],"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":29,"character":9},"arguments":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef","line":29,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":30,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":30,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":31,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_NOTIFICATION_OPTIONS","line":31,"character":16}]}]],"parameters":[{"__symbolic":"reference","name":"ElementRef","module":"@angular/core","arguments":[{"__symbolic":"error","message":"Could not resolve type","line":29,"character":68,"context":{"typeName":"HTMLElement"},"module":"./notification-alert/notification-alert.component"}]},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiDestroyService","line":30,"character":62},{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"NotificationTokenOptions","line":32,"character":33}]}],"ngOnInit":[{"__symbolic":"method"}],"closeNotification":[{"__symbolic":"method"}],"calculateContext":[{"__symbolic":"method","decorators":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiPure","line":47,"character":5}]}],"initAutoClose":[{"__symbolic":"method"}]}},"TuiNotificationAlertModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":7,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":8,"character":14},{"__symbolic":"reference","module":"@tinkoff/ng-polymorpheus","name":"PolymorpheusModule","line":8,"character":28},{"__symbolic":"reference","module":"@taiga-ui/core/components/notification","name":"TuiNotificationModule","line":8,"character":48}],"declarations":[{"__symbolic":"reference","name":"TuiNotificationAlertComponent"}],"exports":[{"__symbolic":"reference","name":"TuiNotificationAlertComponent"}]}]}],"members":{}},"NotificationAlert":{"__symbolic":"class","arity":2,"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Observer","module":"rxjs","arguments":[{"__symbolic":"error","message":"Could not resolve type","line":25,"character":36,"context":{"typeName":"O"},"module":"./notification-alert/Notification-alert"}]},{"__symbolic":"reference","name":"PolymorpheusContent","module":"@tinkoff/ng-polymorpheus","arguments":[{"__symbolic":"reference","name":"TuiNotificationContentContext"}]},{"__symbolic":"error","message":"Could not resolve type","line":27,"character":34,"context":{"typeName":"Required"},"module":"./notification-alert/Notification-alert"}]}],"withData":[{"__symbolic":"method"}]}},"TuiNotificationsHostComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":12,"character":1},"arguments":[{"selector":"tui-notifications-host","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy","line":14,"character":21},"member":"OnPush"},"animations":[{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiFadeInList","line":17,"character":17},{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiSlideInRightList","line":17,"character":32},{"__symbolic":"reference","module":"@taiga-ui/core/animations","name":"tuiHeightCollapseList","line":17,"character":53}],"template":"<ng-container *tuiLet=\"service.items$ | async as items\">\n <div\n *ngIf=\"items.length\"\n class=\"wrapper\"\n [@tuiFadeInList]=\"getAnimation(items.length)\"\n [@tuiHeightCollapseList]=\"getAnimation(items.length)\"\n [@tuiSlideInRightList]=\"getAnimation(items.length)\"\n >\n <tui-notification-alert\n *ngFor=\"let item of items\"\n role=\"alert\"\n class=\"alert\"\n [item]=\"item\"\n ></tui-notification-alert>\n </div>\n</ng-container>\n","styles":[":host{position:fixed;top:0;left:0;width:100%;height:0}.wrapper{width:18rem;margin-left:auto;padding:2rem 3rem 0 0;pointer-events:none}@media screen and (max-width:47.9375em){.wrapper{padding:1rem 1rem 0 0}}@media screen and (min-width:80em){.wrapper{width:23rem}}.alert{pointer-events:auto}.alert:not(:first-child){margin-top:.75rem}"]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":21,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_ANIMATION_OPTIONS","line":21,"character":16}]}],[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":22,"character":9},"arguments":[{"__symbolic":"reference","name":"TuiNotificationsService"}]}]],"parameters":[{"__symbolic":"reference","module":"@angular/animations","name":"AnimationOptions","line":21,"character":65},{"__symbolic":"reference","name":"TuiNotificationsService"}]}],"getAnimation":[{"__symbolic":"method","decorators":[{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"tuiPure","line":25,"character":5}]}]}},"TuiNotificationContentContext":{"__symbolic":"interface"},"NOTIFICATIONS_HOST":{"__symbolic":"reference","name":"TuiNotificationsHostComponent"},"TuiNotificationsModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":9,"character":1},"arguments":[{"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":10,"character":14},{"__symbolic":"reference","name":"TuiNotificationAlertModule"},{"__symbolic":"reference","module":"@taiga-ui/cdk","name":"TuiLetModule","line":10,"character":56}],"declarations":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"exports":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"entryComponents":[{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}],"providers":[{"provide":{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"},"useValue":{"__symbolic":"reference","name":"NOTIFICATIONS_HOST"}}]}]}],"members":{}},"TuiNotificationsService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":15,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":23,"character":9},"arguments":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"TUI_NOTIFICATION_OPTIONS","line":23,"character":16}]}]],"parameters":[{"__symbolic":"reference","module":"@taiga-ui/core/tokens","name":"NotificationTokenOptions","line":24,"character":33}]}],"show":[{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"}]},"statics":{"ɵprov":{}}}},"origins":{"DEFAULT_ALERT_AUTOCLOSE_TIMEOUT":"./notification-alert/notification-alert.component","TuiNotificationAlertComponent":"./notification-alert/notification-alert.component","TuiNotificationAlertModule":"./notification-alert/notification-alert.module","NotificationAlert":"./notification-alert/Notification-alert","TuiNotificationsHostComponent":"./notifications-host/notifications-host.component","TuiNotificationContentContext":"./notification-content-context","NOTIFICATIONS_HOST":"./notifications-host/notifications-host.component","TuiNotificationsModule":"./notifications.module","TuiNotificationsService":"./notifications.service"},"importAs":"@taiga-ui/core/modules/notifications"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@taiga-ui/core",
3
- "version": "2.20.0",
3
+ "version": "2.24.0",
4
4
  "description": "Core library for creating Angular components and applications using Taiga UI",
5
5
  "keywords": [
6
6
  "angular",
@@ -16,19 +16,19 @@
16
16
  "homepage": "https://github.com/TinkoffCreditSystems/taiga-ui",
17
17
  "schematics": "./schematics/collection.json",
18
18
  "dependencies": {
19
- "@taiga-ui/i18n": "2.20.0",
19
+ "@taiga-ui/i18n": "2.24.0",
20
20
  "tslib": "^1.10.0"
21
21
  },
22
22
  "peerDependencies": {
23
- "@taiga-ui/cdk": "2.20.0",
23
+ "@taiga-ui/cdk": "2.24.0",
24
24
  "@angular/animations": ">=9.0.0",
25
25
  "@angular/common": ">=9.0.0",
26
26
  "@angular/core": ">=9.0.0",
27
27
  "@angular/forms": ">=9.0.0",
28
28
  "@angular/platform-browser": ">=9.0.0",
29
29
  "@angular/router": ">=9.0.0",
30
- "@tinkoff/ng-event-plugins": ">=2.3.0",
31
- "@tinkoff/ng-polymorpheus": "3.1.9",
30
+ "@tinkoff/ng-event-plugins": ">=2.3.2",
31
+ "@tinkoff/ng-polymorpheus": "3.1.12",
32
32
  "rxjs": ">=6.0.0"
33
33
  },
34
34
  "main": "bundles/taiga-ui-core.umd.js",
@@ -1,5 +1,7 @@
1
1
  html {
2
2
  height: 100%;
3
+ // TODO: research if it can be used in rem units
4
+ /* stylelint-disable-next-line */
3
5
  font-size: 16px;
4
6
  }
5
7
 
@@ -59,10 +61,6 @@ html,
59
61
  .scrollbar-hidden();
60
62
  }
61
63
 
62
- ::-moz-selection {
63
- background-color: var(--tui-selection);
64
- }
65
-
66
64
  ::selection {
67
65
  background-color: var(--tui-selection);
68
66
  }
@@ -11,6 +11,8 @@
11
11
  -webkit-text-fill-color: inherit !important;
12
12
  color: inherit !important;
13
13
  background-color: transparent !important;
14
+ // TODO: research if it can be used in rem units
15
+ /* stylelint-disable-next-line */
14
16
  -webkit-box-shadow: 0 0 0 1000px var(--tui-autofill) inset !important; // to overlay native background
15
17
  animation-name: tuiAutofillOn;
16
18
  }
@@ -0,0 +1,69 @@
1
+ // width - conscious choice
2
+ /* stylelint-disable order/order */
3
+ .tui-container {
4
+ margin-right: auto;
5
+ margin-left: auto;
6
+ box-sizing: border-box;
7
+
8
+ &.tui-container_adaptive {
9
+ @media @desktop-lg-min {
10
+ width: 69rem;
11
+ }
12
+
13
+ @media @desktop {
14
+ width: 51.5rem;
15
+ }
16
+
17
+ @media @tablet-lg {
18
+ width: 38rem;
19
+ }
20
+
21
+ @media @tablet-s {
22
+ width: 32rem;
23
+ }
24
+
25
+ @media @mobile {
26
+ width: 100%;
27
+ padding: 0 1rem;
28
+ }
29
+ }
30
+
31
+ @media @desktop-lg-min {
32
+ width: 69rem;
33
+ }
34
+
35
+ @media @desktop {
36
+ width: 51.5rem;
37
+ }
38
+
39
+ &_menu {
40
+ @media @desktop-lg-min {
41
+ width: 69rem;
42
+ }
43
+
44
+ @media @desktop-interval {
45
+ width: 51.5rem;
46
+ }
47
+
48
+ @media @tablet {
49
+ width: auto;
50
+ padding: 0 1rem;
51
+ }
52
+ }
53
+
54
+ &_fullwidth {
55
+ width: auto;
56
+ padding: 0 1.5rem;
57
+
58
+ @media @tablet {
59
+ padding: 0 1rem;
60
+ }
61
+ }
62
+
63
+ &_fixed {
64
+ @media @desktop {
65
+ width: 69rem;
66
+ }
67
+ }
68
+ }
69
+ /* stylelint-enable order/order */