@taiga-ui/kit 3.0.0-rc.0 → 3.0.0-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (585) hide show
  1. package/bundles/taiga-ui-kit-components-accordion.umd.js +5 -17
  2. package/bundles/taiga-ui-kit-components-accordion.umd.js.map +1 -1
  3. package/bundles/taiga-ui-kit-components-action.umd.js +3 -9
  4. package/bundles/taiga-ui-kit-components-action.umd.js.map +1 -1
  5. package/bundles/taiga-ui-kit-components-arrow.umd.js +1 -1
  6. package/bundles/taiga-ui-kit-components-arrow.umd.js.map +1 -1
  7. package/bundles/taiga-ui-kit-components-avatar.umd.js +3 -3
  8. package/bundles/taiga-ui-kit-components-avatar.umd.js.map +1 -1
  9. package/bundles/taiga-ui-kit-components-badge.umd.js +3 -3
  10. package/bundles/taiga-ui-kit-components-badge.umd.js.map +1 -1
  11. package/bundles/taiga-ui-kit-components-badged-content.umd.js +3 -6
  12. package/bundles/taiga-ui-kit-components-badged-content.umd.js.map +1 -1
  13. package/bundles/taiga-ui-kit-components-breadcrumbs.umd.js +1 -1
  14. package/bundles/taiga-ui-kit-components-breadcrumbs.umd.js.map +1 -1
  15. package/bundles/taiga-ui-kit-components-calendar-month.umd.js +0 -1
  16. package/bundles/taiga-ui-kit-components-calendar-month.umd.js.map +1 -1
  17. package/bundles/taiga-ui-kit-components-calendar-range.umd.js +12 -8
  18. package/bundles/taiga-ui-kit-components-calendar-range.umd.js.map +1 -1
  19. package/bundles/taiga-ui-kit-components-carousel.umd.js +4 -5
  20. package/bundles/taiga-ui-kit-components-carousel.umd.js.map +1 -1
  21. package/bundles/taiga-ui-kit-components-checkbox-block.umd.js +7 -10
  22. package/bundles/taiga-ui-kit-components-checkbox-block.umd.js.map +1 -1
  23. package/bundles/taiga-ui-kit-components-checkbox-labeled.umd.js +5 -9
  24. package/bundles/taiga-ui-kit-components-checkbox-labeled.umd.js.map +1 -1
  25. package/bundles/taiga-ui-kit-components-checkbox.umd.js +5 -9
  26. package/bundles/taiga-ui-kit-components-checkbox.umd.js.map +1 -1
  27. package/bundles/taiga-ui-kit-components-combo-box.umd.js +21 -41
  28. package/bundles/taiga-ui-kit-components-combo-box.umd.js.map +1 -1
  29. package/bundles/taiga-ui-kit-components-data-list-wrapper.umd.js +5 -26
  30. package/bundles/taiga-ui-kit-components-data-list-wrapper.umd.js.map +1 -1
  31. package/bundles/taiga-ui-kit-components-files.umd.js +1 -2
  32. package/bundles/taiga-ui-kit-components-files.umd.js.map +1 -1
  33. package/bundles/taiga-ui-kit-components-filter.umd.js +1 -1
  34. package/bundles/taiga-ui-kit-components-filter.umd.js.map +1 -1
  35. package/bundles/taiga-ui-kit-components-input-copy.umd.js +21 -36
  36. package/bundles/taiga-ui-kit-components-input-copy.umd.js.map +1 -1
  37. package/bundles/taiga-ui-kit-components-input-count.umd.js +12 -35
  38. package/bundles/taiga-ui-kit-components-input-count.umd.js.map +1 -1
  39. package/bundles/taiga-ui-kit-components-input-date-range.umd.js +19 -42
  40. package/bundles/taiga-ui-kit-components-input-date-range.umd.js.map +1 -1
  41. package/bundles/taiga-ui-kit-components-input-date-time.umd.js +18 -42
  42. package/bundles/taiga-ui-kit-components-input-date-time.umd.js.map +1 -1
  43. package/bundles/taiga-ui-kit-components-input-date.umd.js +17 -41
  44. package/bundles/taiga-ui-kit-components-input-date.umd.js.map +1 -1
  45. package/bundles/taiga-ui-kit-components-input-files.umd.js +4 -17
  46. package/bundles/taiga-ui-kit-components-input-files.umd.js.map +1 -1
  47. package/bundles/taiga-ui-kit-components-input-inline.umd.js +2 -8
  48. package/bundles/taiga-ui-kit-components-input-inline.umd.js.map +1 -1
  49. package/bundles/taiga-ui-kit-components-input-month-range.umd.js +19 -37
  50. package/bundles/taiga-ui-kit-components-input-month-range.umd.js.map +1 -1
  51. package/bundles/taiga-ui-kit-components-input-month.umd.js +19 -37
  52. package/bundles/taiga-ui-kit-components-input-month.umd.js.map +1 -1
  53. package/bundles/taiga-ui-kit-components-input-number.umd.js +14 -37
  54. package/bundles/taiga-ui-kit-components-input-number.umd.js.map +1 -1
  55. package/bundles/taiga-ui-kit-components-input-password.umd.js +29 -56
  56. package/bundles/taiga-ui-kit-components-input-password.umd.js.map +1 -1
  57. package/bundles/taiga-ui-kit-components-input-phone-international.umd.js +38 -51
  58. package/bundles/taiga-ui-kit-components-input-phone-international.umd.js.map +1 -1
  59. package/bundles/taiga-ui-kit-components-input-phone.umd.js +30 -57
  60. package/bundles/taiga-ui-kit-components-input-phone.umd.js.map +1 -1
  61. package/bundles/taiga-ui-kit-components-input-range.umd.js +17 -13
  62. package/bundles/taiga-ui-kit-components-input-range.umd.js.map +1 -1
  63. package/bundles/taiga-ui-kit-components-input-slider.umd.js +14 -12
  64. package/bundles/taiga-ui-kit-components-input-slider.umd.js.map +1 -1
  65. package/bundles/taiga-ui-kit-components-input-tag.umd.js +33 -50
  66. package/bundles/taiga-ui-kit-components-input-tag.umd.js.map +1 -1
  67. package/bundles/taiga-ui-kit-components-input-time.umd.js +8 -15
  68. package/bundles/taiga-ui-kit-components-input-time.umd.js.map +1 -1
  69. package/bundles/taiga-ui-kit-components-input.umd.js +16 -33
  70. package/bundles/taiga-ui-kit-components-input.umd.js.map +1 -1
  71. package/bundles/taiga-ui-kit-components-line-clamp.umd.js +108 -18
  72. package/bundles/taiga-ui-kit-components-line-clamp.umd.js.map +1 -1
  73. package/bundles/taiga-ui-kit-components-marker-icon.umd.js +1 -1
  74. package/bundles/taiga-ui-kit-components-marker-icon.umd.js.map +1 -1
  75. package/bundles/taiga-ui-kit-components-multi-select-option.umd.js +3 -3
  76. package/bundles/taiga-ui-kit-components-multi-select-option.umd.js.map +1 -1
  77. package/bundles/taiga-ui-kit-components-multi-select.umd.js +34 -69
  78. package/bundles/taiga-ui-kit-components-multi-select.umd.js.map +1 -1
  79. package/bundles/taiga-ui-kit-components-pagination.umd.js +10 -23
  80. package/bundles/taiga-ui-kit-components-pagination.umd.js.map +1 -1
  81. package/bundles/taiga-ui-kit-components-pdf-viewer.umd.js +2 -15
  82. package/bundles/taiga-ui-kit-components-pdf-viewer.umd.js.map +1 -1
  83. package/bundles/taiga-ui-kit-components-progress.umd.js +5 -15
  84. package/bundles/taiga-ui-kit-components-progress.umd.js.map +1 -1
  85. package/bundles/taiga-ui-kit-components-radio-block.umd.js +7 -10
  86. package/bundles/taiga-ui-kit-components-radio-block.umd.js.map +1 -1
  87. package/bundles/taiga-ui-kit-components-radio-labeled.umd.js +5 -9
  88. package/bundles/taiga-ui-kit-components-radio-labeled.umd.js.map +1 -1
  89. package/bundles/taiga-ui-kit-components-radio-list.umd.js +5 -9
  90. package/bundles/taiga-ui-kit-components-radio-list.umd.js.map +1 -1
  91. package/bundles/taiga-ui-kit-components-radio.umd.js +5 -10
  92. package/bundles/taiga-ui-kit-components-radio.umd.js.map +1 -1
  93. package/bundles/taiga-ui-kit-components-range.umd.js +40 -86
  94. package/bundles/taiga-ui-kit-components-range.umd.js.map +1 -1
  95. package/bundles/taiga-ui-kit-components-rating.umd.js +4 -8
  96. package/bundles/taiga-ui-kit-components-rating.umd.js.map +1 -1
  97. package/bundles/taiga-ui-kit-components-select-option.umd.js +5 -5
  98. package/bundles/taiga-ui-kit-components-select-option.umd.js.map +1 -1
  99. package/bundles/taiga-ui-kit-components-select.umd.js +20 -40
  100. package/bundles/taiga-ui-kit-components-select.umd.js.map +1 -1
  101. package/bundles/taiga-ui-kit-components-slider.umd.js +40 -38
  102. package/bundles/taiga-ui-kit-components-slider.umd.js.map +1 -1
  103. package/bundles/taiga-ui-kit-components-stepper.umd.js +9 -7
  104. package/bundles/taiga-ui-kit-components-stepper.umd.js.map +1 -1
  105. package/bundles/taiga-ui-kit-components-tabs.umd.js +40 -40
  106. package/bundles/taiga-ui-kit-components-tabs.umd.js.map +1 -1
  107. package/bundles/taiga-ui-kit-components-tag.umd.js +6 -17
  108. package/bundles/taiga-ui-kit-components-tag.umd.js.map +1 -1
  109. package/bundles/taiga-ui-kit-components-text-area.umd.js +18 -31
  110. package/bundles/taiga-ui-kit-components-text-area.umd.js.map +1 -1
  111. package/bundles/taiga-ui-kit-components-toggle.umd.js +5 -9
  112. package/bundles/taiga-ui-kit-components-toggle.umd.js.map +1 -1
  113. package/bundles/taiga-ui-kit-components-tree.umd.js +2 -8
  114. package/bundles/taiga-ui-kit-components-tree.umd.js.map +1 -1
  115. package/bundles/taiga-ui-kit-constants.umd.js +334 -3
  116. package/bundles/taiga-ui-kit-constants.umd.js.map +1 -1
  117. package/bundles/{taiga-ui-kit-directives-dropdown-context.umd.js → taiga-ui-kit-directives-data-list-dropdown-manager.umd.js} +117 -141
  118. package/bundles/taiga-ui-kit-directives-data-list-dropdown-manager.umd.js.map +1 -0
  119. package/bundles/taiga-ui-kit-directives-highlight.umd.js +0 -1
  120. package/bundles/taiga-ui-kit-directives-highlight.umd.js.map +1 -1
  121. package/bundles/taiga-ui-kit-directives-lazy-loading.umd.js +2 -2
  122. package/bundles/taiga-ui-kit-directives-lazy-loading.umd.js.map +1 -1
  123. package/bundles/taiga-ui-kit-directives-present.umd.js +2 -2
  124. package/bundles/taiga-ui-kit-directives-present.umd.js.map +1 -1
  125. package/bundles/taiga-ui-kit-directives-project-class.umd.js +0 -3
  126. package/bundles/taiga-ui-kit-directives-project-class.umd.js.map +1 -1
  127. package/bundles/taiga-ui-kit-directives.umd.js +6 -18
  128. package/bundles/taiga-ui-kit-directives.umd.js.map +1 -1
  129. package/bundles/taiga-ui-kit-internal-primitive-calendar-range.umd.js +4 -4
  130. package/bundles/taiga-ui-kit-internal-primitive-calendar-range.umd.js.map +1 -1
  131. package/bundles/taiga-ui-kit-pipes-field-error.umd.js +0 -2
  132. package/bundles/taiga-ui-kit-pipes-field-error.umd.js.map +1 -1
  133. package/bundles/taiga-ui-kit-pipes-filter-by-input.umd.js +3 -3
  134. package/bundles/taiga-ui-kit-pipes-filter-by-input.umd.js.map +1 -1
  135. package/bundles/taiga-ui-kit-providers.umd.js +11 -42
  136. package/bundles/taiga-ui-kit-providers.umd.js.map +1 -1
  137. package/bundles/taiga-ui-kit-tokens.umd.js +17 -12
  138. package/bundles/taiga-ui-kit-tokens.umd.js.map +1 -1
  139. package/bundles/taiga-ui-kit-utils-files.umd.js +3 -15
  140. package/bundles/taiga-ui-kit-utils-files.umd.js.map +1 -1
  141. package/bundles/taiga-ui-kit-utils-format.umd.js +1 -5
  142. package/bundles/taiga-ui-kit-utils-format.umd.js.map +1 -1
  143. package/bundles/taiga-ui-kit-utils-mask.umd.js +3 -9
  144. package/bundles/taiga-ui-kit-utils-mask.umd.js.map +1 -1
  145. package/bundles/taiga-ui-kit-utils-math.umd.js +1 -1
  146. package/bundles/taiga-ui-kit-utils-math.umd.js.map +1 -1
  147. package/bundles/taiga-ui-kit-utils-miscellaneous.umd.js +1 -5
  148. package/bundles/taiga-ui-kit-utils-miscellaneous.umd.js.map +1 -1
  149. package/bundles/taiga-ui-kit-utils.umd.js +4 -10
  150. package/bundles/taiga-ui-kit-utils.umd.js.map +1 -1
  151. package/components/badge/badge.component.d.ts +2 -2
  152. package/components/badged-content/badged-content.component.d.ts +2 -2
  153. package/components/combo-box/index.d.ts +0 -1
  154. package/components/filter/filter.component.d.ts +1 -1
  155. package/components/input/index.d.ts +0 -1
  156. package/components/input-copy/index.d.ts +0 -1
  157. package/components/input-copy/input-copy.component.d.ts +4 -4
  158. package/components/input-date/index.d.ts +0 -1
  159. package/components/input-date-range/index.d.ts +0 -1
  160. package/components/input-date-time/index.d.ts +0 -1
  161. package/components/input-month/index.d.ts +0 -1
  162. package/components/input-month-range/index.d.ts +0 -1
  163. package/components/input-password/input-password.component.d.ts +2 -2
  164. package/components/input-password/input-password.module.d.ts +2 -3
  165. package/components/input-phone/index.d.ts +0 -1
  166. package/components/input-phone/input-phone.component.d.ts +2 -2
  167. package/components/input-phone-international/utils/extract-value-from-event.d.ts +1 -5
  168. package/components/input-range/input-range.component.d.ts +1 -0
  169. package/components/input-slider/input-slider.component.d.ts +1 -0
  170. package/components/input-tag/input-tag-options.d.ts +4 -1
  171. package/components/input-tag/input-tag.component.d.ts +3 -5
  172. package/components/line-clamp/index.d.ts +1 -0
  173. package/components/line-clamp/line-clamp-box.component.d.ts +7 -0
  174. package/components/line-clamp/line-clamp-position.directive.d.ts +9 -0
  175. package/components/line-clamp/line-clamp.module.d.ts +7 -5
  176. package/components/multi-select/multi-select-group/multi-select-group.directive.d.ts +0 -3
  177. package/components/pagination/pagination.component.d.ts +0 -1
  178. package/components/progress/progress-segmented/progress-segmented.component.d.ts +0 -2
  179. package/components/range/range.component.d.ts +7 -23
  180. package/components/select/index.d.ts +0 -1
  181. package/components/slider/helpers/slider-key-steps.directive.d.ts +1 -3
  182. package/components/slider/slider.component.d.ts +5 -3
  183. package/components/stepper/step/step.component.d.ts +2 -2
  184. package/components/tabs/tab/tab.providers.d.ts +1 -4
  185. package/components/tabs/tabs-with-more/tabs-with-more.component.d.ts +2 -1
  186. package/components/tabs/tabs-with-more/tabs-with-more.providers.d.ts +3 -4
  187. package/components/tag/tag.component.d.ts +1 -3
  188. package/components/text-area/index.d.ts +0 -1
  189. package/components/tree/components/tree-item/tree-item.providers.d.ts +0 -1
  190. package/directives/data-list-dropdown-manager/data-list-dropdown-manager.directive.d.ts +15 -0
  191. package/directives/data-list-dropdown-manager/data-list-dropdown-manager.module.d.ts +7 -0
  192. package/directives/data-list-dropdown-manager/index.d.ts +2 -0
  193. package/directives/data-list-dropdown-manager/package.json +10 -0
  194. package/directives/data-list-dropdown-manager/taiga-ui-kit-directives-data-list-dropdown-manager.d.ts +5 -0
  195. package/directives/index.d.ts +1 -3
  196. package/esm2015/components/accordion/accordion-item/accordion-item.component.js +5 -17
  197. package/esm2015/components/accordion/accordion.component.js +5 -5
  198. package/esm2015/components/action/action.component.js +6 -12
  199. package/esm2015/components/arrow/arrow.component.js +3 -3
  200. package/esm2015/components/avatar/avatar.component.js +6 -6
  201. package/esm2015/components/badge/badge.component.js +6 -6
  202. package/esm2015/components/badged-content/badged-content.component.js +4 -7
  203. package/esm2015/components/breadcrumbs/breadcrumbs.component.js +2 -2
  204. package/esm2015/components/calendar-month/calendar-month.component.js +1 -2
  205. package/esm2015/components/calendar-range/calendar-range.component.js +12 -11
  206. package/esm2015/components/carousel/carousel-scroll.directive.js +3 -3
  207. package/esm2015/components/carousel/carousel.component.js +4 -5
  208. package/esm2015/components/carousel/carousel.directive.js +3 -3
  209. package/esm2015/components/checkbox/checkbox.component.js +8 -12
  210. package/esm2015/components/checkbox-block/checkbox-block.component.js +10 -13
  211. package/esm2015/components/checkbox-labeled/checkbox-labeled.component.js +8 -12
  212. package/esm2015/components/combo-box/combo-box.component.js +20 -8
  213. package/esm2015/components/combo-box/combo-box.directive.js +5 -15
  214. package/esm2015/components/combo-box/index.js +1 -2
  215. package/esm2015/components/data-list-wrapper/data-list-group-wrapper.component.js +5 -15
  216. package/esm2015/components/data-list-wrapper/data-list-wrapper.component.js +5 -15
  217. package/esm2015/components/data-list-wrapper/data-list-wrapper.js +3 -4
  218. package/esm2015/components/files/file/file.component.js +3 -4
  219. package/esm2015/components/filter/filter.component.js +2 -2
  220. package/esm2015/components/input/index.js +1 -2
  221. package/esm2015/components/input/input.component.js +18 -7
  222. package/esm2015/components/input/input.directive.js +5 -15
  223. package/esm2015/components/input-copy/index.js +1 -2
  224. package/esm2015/components/input-copy/input-copy.component.js +18 -10
  225. package/esm2015/components/input-copy/input-copy.directive.js +5 -15
  226. package/esm2015/components/input-count/input-count.component.js +14 -27
  227. package/esm2015/components/input-count/input-count.directive.js +5 -15
  228. package/esm2015/components/input-date/index.js +1 -2
  229. package/esm2015/components/input-date/input-date.component.js +15 -9
  230. package/esm2015/components/input-date/input-date.directive.js +5 -15
  231. package/esm2015/components/input-date-range/index.js +1 -2
  232. package/esm2015/components/input-date-range/input-date-range.component.js +18 -11
  233. package/esm2015/components/input-date-range/input-date-range.directive.js +5 -15
  234. package/esm2015/components/input-date-time/index.js +1 -2
  235. package/esm2015/components/input-date-time/input-date-time.component.js +16 -10
  236. package/esm2015/components/input-date-time/input-date-time.directive.js +5 -15
  237. package/esm2015/components/input-files/input-files.component.js +8 -21
  238. package/esm2015/components/input-inline/input-inline.component.js +5 -11
  239. package/esm2015/components/input-month/index.js +1 -2
  240. package/esm2015/components/input-month/input-month.component.js +17 -8
  241. package/esm2015/components/input-month/input-month.directive.js +5 -17
  242. package/esm2015/components/input-month-range/index.js +1 -2
  243. package/esm2015/components/input-month-range/input-month-range.component.js +17 -8
  244. package/esm2015/components/input-month-range/input-month-range.directive.js +5 -17
  245. package/esm2015/components/input-number/input-number.component.js +16 -29
  246. package/esm2015/components/input-number/input-number.directive.js +5 -15
  247. package/esm2015/components/input-password/input-password.component.js +18 -32
  248. package/esm2015/components/input-password/input-password.directive.js +5 -15
  249. package/esm2015/components/input-password/input-password.module.js +1 -5
  250. package/esm2015/components/input-phone/index.js +1 -2
  251. package/esm2015/components/input-phone/input-phone.component.js +28 -14
  252. package/esm2015/components/input-phone/input-phone.directive.js +5 -15
  253. package/esm2015/components/input-phone-international/input-phone-international.component.js +16 -22
  254. package/esm2015/components/input-phone-international/utils/extract-value-from-event.js +5 -11
  255. package/esm2015/components/input-range/input-range.component.js +20 -16
  256. package/esm2015/components/input-slider/input-slider.component.js +13 -15
  257. package/esm2015/components/input-tag/input-tag-options.js +8 -1
  258. package/esm2015/components/input-tag/input-tag.component.js +24 -54
  259. package/esm2015/components/input-time/input-time.component.js +11 -18
  260. package/esm2015/components/line-clamp/index.js +2 -1
  261. package/esm2015/components/line-clamp/line-clamp-box.component.js +32 -0
  262. package/esm2015/components/line-clamp/line-clamp-position.directive.js +26 -0
  263. package/esm2015/components/line-clamp/line-clamp.component.js +22 -9
  264. package/esm2015/components/line-clamp/line-clamp.module.js +30 -6
  265. package/esm2015/components/marker-icon/marker-icon.component.js +2 -2
  266. package/esm2015/components/multi-select/multi-select-group/multi-select-group.component.js +11 -21
  267. package/esm2015/components/multi-select/multi-select-group/multi-select-group.directive.js +17 -28
  268. package/esm2015/components/multi-select/multi-select.component.js +15 -30
  269. package/esm2015/components/multi-select-option/multi-select-option.component.js +6 -6
  270. package/esm2015/components/pagination/pagination.component.js +13 -25
  271. package/esm2015/components/pdf-viewer/pdf-viewer.module.js +4 -17
  272. package/esm2015/components/progress/progress-bar/progress-color-segments.directive.js +4 -4
  273. package/esm2015/components/progress/progress-circle/progress-circle.component.js +2 -2
  274. package/esm2015/components/progress/progress-segmented/progress-segmented.component.js +3 -11
  275. package/esm2015/components/radio/radio.component.js +8 -13
  276. package/esm2015/components/radio-block/radio-block.component.js +10 -13
  277. package/esm2015/components/radio-labeled/radio-labeled.component.js +8 -12
  278. package/esm2015/components/radio-list/radio-list.component.js +8 -12
  279. package/esm2015/components/range/range-change.directive.js +10 -9
  280. package/esm2015/components/range/range.component.js +27 -79
  281. package/esm2015/components/rating/rating.component.js +7 -11
  282. package/esm2015/components/select/index.js +1 -2
  283. package/esm2015/components/select/select.component.js +19 -7
  284. package/esm2015/components/select/select.directive.js +5 -15
  285. package/esm2015/components/select-option/select-option.component.js +7 -7
  286. package/esm2015/components/slider/helpers/slider-key-steps.directive.js +14 -22
  287. package/esm2015/components/slider/helpers/slider-readonly.directive.js +5 -6
  288. package/esm2015/components/slider/slider.component.js +21 -10
  289. package/esm2015/components/stepper/step/step.component.js +5 -5
  290. package/esm2015/components/stepper/stepper.component.js +7 -5
  291. package/esm2015/components/tabs/tab/tab.providers.js +10 -10
  292. package/esm2015/components/tabs/tabs/tabs.component.js +1 -2
  293. package/esm2015/components/tabs/tabs-with-more/tabs-with-more.component.js +18 -17
  294. package/esm2015/components/tabs/tabs-with-more/tabs-with-more.providers.js +9 -11
  295. package/esm2015/components/tag/tag.component.js +10 -20
  296. package/esm2015/components/text-area/index.js +1 -2
  297. package/esm2015/components/text-area/text-area.component.js +19 -8
  298. package/esm2015/components/text-area/text-area.directive.js +5 -15
  299. package/esm2015/components/toggle/toggle.component.js +8 -12
  300. package/esm2015/components/tree/components/tree-item/tree-item.providers.js +2 -6
  301. package/esm2015/components/tree/directives/tree-controller.directive.js +3 -3
  302. package/esm2015/components/tree/misc/tree.service.js +1 -2
  303. package/esm2015/constants/max-day-range-length-mapper.js +5 -4
  304. package/esm2015/directives/data-list-dropdown-manager/data-list-dropdown-manager.directive.js +100 -0
  305. package/esm2015/directives/data-list-dropdown-manager/data-list-dropdown-manager.module.js +16 -0
  306. package/esm2015/directives/data-list-dropdown-manager/index.js +3 -0
  307. package/esm2015/directives/data-list-dropdown-manager/taiga-ui-kit-directives-data-list-dropdown-manager.js +5 -0
  308. package/esm2015/directives/highlight/highlight.directive.js +1 -2
  309. package/esm2015/directives/index.js +2 -4
  310. package/esm2015/directives/lazy-loading/lazy-loading.directive.js +2 -2
  311. package/esm2015/directives/lazy-loading/lazy-loading.service.js +3 -3
  312. package/esm2015/directives/present/present.directive.js +4 -4
  313. package/esm2015/directives/project-class/project-class.directive.js +1 -4
  314. package/esm2015/interfaces/index.js +1 -2
  315. package/esm2015/internal/primitive-calendar-range/primitive-calendar-range.component.js +7 -7
  316. package/esm2015/pipes/field-error/field-error-content-pipe.js +1 -2
  317. package/esm2015/pipes/field-error/field-error-pipe.js +1 -2
  318. package/esm2015/pipes/filter-by-input/filter-by-input.base.js +5 -5
  319. package/esm2015/providers/month-formatter.provider.js +8 -13
  320. package/esm2015/providers/specific-dropdown-controllers.js +6 -29
  321. package/esm2015/tokens/calendar-date-stream.js +15 -0
  322. package/esm2015/tokens/index.js +2 -3
  323. package/esm2015/utils/files/format-size.js +4 -9
  324. package/esm2015/utils/files/get-accept-array.js +2 -7
  325. package/esm2015/utils/format/string-hash-to-hsl.js +2 -5
  326. package/esm2015/utils/index.js +1 -2
  327. package/esm2015/utils/mask/create-auto-corrected-date-pipe.js +3 -8
  328. package/esm2015/utils/mask/create-auto-corrected-date-time-pipe.js +3 -3
  329. package/esm2015/utils/math/key-steps.js +3 -3
  330. package/esm2015/utils/miscellaneous/get-precision.js +2 -5
  331. package/fesm2015/taiga-ui-kit-components-accordion.js +7 -19
  332. package/fesm2015/taiga-ui-kit-components-accordion.js.map +1 -1
  333. package/fesm2015/taiga-ui-kit-components-action.js +5 -11
  334. package/fesm2015/taiga-ui-kit-components-action.js.map +1 -1
  335. package/fesm2015/taiga-ui-kit-components-arrow.js +2 -2
  336. package/fesm2015/taiga-ui-kit-components-arrow.js.map +1 -1
  337. package/fesm2015/taiga-ui-kit-components-avatar.js +5 -5
  338. package/fesm2015/taiga-ui-kit-components-avatar.js.map +1 -1
  339. package/fesm2015/taiga-ui-kit-components-badge.js +4 -4
  340. package/fesm2015/taiga-ui-kit-components-badge.js.map +1 -1
  341. package/fesm2015/taiga-ui-kit-components-badged-content.js +3 -6
  342. package/fesm2015/taiga-ui-kit-components-badged-content.js.map +1 -1
  343. package/fesm2015/taiga-ui-kit-components-breadcrumbs.js +1 -1
  344. package/fesm2015/taiga-ui-kit-components-breadcrumbs.js.map +1 -1
  345. package/fesm2015/taiga-ui-kit-components-calendar-month.js +0 -1
  346. package/fesm2015/taiga-ui-kit-components-calendar-month.js.map +1 -1
  347. package/fesm2015/taiga-ui-kit-components-calendar-range.js +12 -11
  348. package/fesm2015/taiga-ui-kit-components-calendar-range.js.map +1 -1
  349. package/fesm2015/taiga-ui-kit-components-carousel.js +5 -6
  350. package/fesm2015/taiga-ui-kit-components-carousel.js.map +1 -1
  351. package/fesm2015/taiga-ui-kit-components-checkbox-block.js +9 -12
  352. package/fesm2015/taiga-ui-kit-components-checkbox-block.js.map +1 -1
  353. package/fesm2015/taiga-ui-kit-components-checkbox-labeled.js +7 -11
  354. package/fesm2015/taiga-ui-kit-components-checkbox-labeled.js.map +1 -1
  355. package/fesm2015/taiga-ui-kit-components-checkbox.js +7 -11
  356. package/fesm2015/taiga-ui-kit-components-checkbox.js.map +1 -1
  357. package/fesm2015/taiga-ui-kit-components-combo-box.js +22 -41
  358. package/fesm2015/taiga-ui-kit-components-combo-box.js.map +1 -1
  359. package/fesm2015/taiga-ui-kit-components-data-list-wrapper.js +7 -28
  360. package/fesm2015/taiga-ui-kit-components-data-list-wrapper.js.map +1 -1
  361. package/fesm2015/taiga-ui-kit-components-files.js +2 -3
  362. package/fesm2015/taiga-ui-kit-components-files.js.map +1 -1
  363. package/fesm2015/taiga-ui-kit-components-filter.js +1 -1
  364. package/fesm2015/taiga-ui-kit-components-filter.js.map +1 -1
  365. package/fesm2015/taiga-ui-kit-components-input-copy.js +22 -36
  366. package/fesm2015/taiga-ui-kit-components-input-copy.js.map +1 -1
  367. package/fesm2015/taiga-ui-kit-components-input-count.js +15 -38
  368. package/fesm2015/taiga-ui-kit-components-input-count.js.map +1 -1
  369. package/fesm2015/taiga-ui-kit-components-input-date-range.js +20 -44
  370. package/fesm2015/taiga-ui-kit-components-input-date-range.js.map +1 -1
  371. package/fesm2015/taiga-ui-kit-components-input-date-time.js +19 -44
  372. package/fesm2015/taiga-ui-kit-components-input-date-time.js.map +1 -1
  373. package/fesm2015/taiga-ui-kit-components-input-date.js +18 -43
  374. package/fesm2015/taiga-ui-kit-components-input-date.js.map +1 -1
  375. package/fesm2015/taiga-ui-kit-components-input-files.js +7 -20
  376. package/fesm2015/taiga-ui-kit-components-input-files.js.map +1 -1
  377. package/fesm2015/taiga-ui-kit-components-input-inline.js +4 -10
  378. package/fesm2015/taiga-ui-kit-components-input-inline.js.map +1 -1
  379. package/fesm2015/taiga-ui-kit-components-input-month-range.js +20 -37
  380. package/fesm2015/taiga-ui-kit-components-input-month-range.js.map +1 -1
  381. package/fesm2015/taiga-ui-kit-components-input-month.js +20 -37
  382. package/fesm2015/taiga-ui-kit-components-input-month.js.map +1 -1
  383. package/fesm2015/taiga-ui-kit-components-input-number.js +17 -40
  384. package/fesm2015/taiga-ui-kit-components-input-number.js.map +1 -1
  385. package/fesm2015/taiga-ui-kit-components-input-password.js +20 -47
  386. package/fesm2015/taiga-ui-kit-components-input-password.js.map +1 -1
  387. package/fesm2015/taiga-ui-kit-components-input-phone-international.js +18 -30
  388. package/fesm2015/taiga-ui-kit-components-input-phone-international.js.map +1 -1
  389. package/fesm2015/taiga-ui-kit-components-input-phone.js +31 -57
  390. package/fesm2015/taiga-ui-kit-components-input-phone.js.map +1 -1
  391. package/fesm2015/taiga-ui-kit-components-input-range.js +19 -15
  392. package/fesm2015/taiga-ui-kit-components-input-range.js.map +1 -1
  393. package/fesm2015/taiga-ui-kit-components-input-slider.js +12 -14
  394. package/fesm2015/taiga-ui-kit-components-input-slider.js.map +1 -1
  395. package/fesm2015/taiga-ui-kit-components-input-tag.js +33 -55
  396. package/fesm2015/taiga-ui-kit-components-input-tag.js.map +1 -1
  397. package/fesm2015/taiga-ui-kit-components-input-time.js +10 -17
  398. package/fesm2015/taiga-ui-kit-components-input-time.js.map +1 -1
  399. package/fesm2015/taiga-ui-kit-components-input.js +20 -36
  400. package/fesm2015/taiga-ui-kit-components-input.js.map +1 -1
  401. package/fesm2015/taiga-ui-kit-components-line-clamp.js +96 -14
  402. package/fesm2015/taiga-ui-kit-components-line-clamp.js.map +1 -1
  403. package/fesm2015/taiga-ui-kit-components-marker-icon.js +1 -1
  404. package/fesm2015/taiga-ui-kit-components-marker-icon.js.map +1 -1
  405. package/fesm2015/taiga-ui-kit-components-multi-select-option.js +5 -5
  406. package/fesm2015/taiga-ui-kit-components-multi-select-option.js.map +1 -1
  407. package/fesm2015/taiga-ui-kit-components-multi-select.js +37 -73
  408. package/fesm2015/taiga-ui-kit-components-multi-select.js.map +1 -1
  409. package/fesm2015/taiga-ui-kit-components-pagination.js +13 -25
  410. package/fesm2015/taiga-ui-kit-components-pagination.js.map +1 -1
  411. package/fesm2015/taiga-ui-kit-components-pdf-viewer.js +3 -16
  412. package/fesm2015/taiga-ui-kit-components-pdf-viewer.js.map +1 -1
  413. package/fesm2015/taiga-ui-kit-components-progress.js +7 -15
  414. package/fesm2015/taiga-ui-kit-components-progress.js.map +1 -1
  415. package/fesm2015/taiga-ui-kit-components-radio-block.js +9 -12
  416. package/fesm2015/taiga-ui-kit-components-radio-block.js.map +1 -1
  417. package/fesm2015/taiga-ui-kit-components-radio-labeled.js +7 -11
  418. package/fesm2015/taiga-ui-kit-components-radio-labeled.js.map +1 -1
  419. package/fesm2015/taiga-ui-kit-components-radio-list.js +7 -11
  420. package/fesm2015/taiga-ui-kit-components-radio-list.js.map +1 -1
  421. package/fesm2015/taiga-ui-kit-components-radio.js +7 -12
  422. package/fesm2015/taiga-ui-kit-components-radio.js.map +1 -1
  423. package/fesm2015/taiga-ui-kit-components-range.js +38 -86
  424. package/fesm2015/taiga-ui-kit-components-range.js.map +1 -1
  425. package/fesm2015/taiga-ui-kit-components-rating.js +6 -10
  426. package/fesm2015/taiga-ui-kit-components-rating.js.map +1 -1
  427. package/fesm2015/taiga-ui-kit-components-select-option.js +6 -6
  428. package/fesm2015/taiga-ui-kit-components-select-option.js.map +1 -1
  429. package/fesm2015/taiga-ui-kit-components-select.js +21 -40
  430. package/fesm2015/taiga-ui-kit-components-select.js.map +1 -1
  431. package/fesm2015/taiga-ui-kit-components-slider.js +34 -32
  432. package/fesm2015/taiga-ui-kit-components-slider.js.map +1 -1
  433. package/fesm2015/taiga-ui-kit-components-stepper.js +10 -8
  434. package/fesm2015/taiga-ui-kit-components-stepper.js.map +1 -1
  435. package/fesm2015/taiga-ui-kit-components-tabs.js +33 -35
  436. package/fesm2015/taiga-ui-kit-components-tabs.js.map +1 -1
  437. package/fesm2015/taiga-ui-kit-components-tag.js +10 -20
  438. package/fesm2015/taiga-ui-kit-components-tag.js.map +1 -1
  439. package/fesm2015/taiga-ui-kit-components-text-area.js +22 -34
  440. package/fesm2015/taiga-ui-kit-components-text-area.js.map +1 -1
  441. package/fesm2015/taiga-ui-kit-components-toggle.js +7 -11
  442. package/fesm2015/taiga-ui-kit-components-toggle.js.map +1 -1
  443. package/fesm2015/taiga-ui-kit-components-tree.js +4 -9
  444. package/fesm2015/taiga-ui-kit-components-tree.js.map +1 -1
  445. package/fesm2015/taiga-ui-kit-constants.js +4 -3
  446. package/fesm2015/taiga-ui-kit-constants.js.map +1 -1
  447. package/fesm2015/taiga-ui-kit-directives-data-list-dropdown-manager.js +120 -0
  448. package/fesm2015/taiga-ui-kit-directives-data-list-dropdown-manager.js.map +1 -0
  449. package/fesm2015/taiga-ui-kit-directives-highlight.js +0 -1
  450. package/fesm2015/taiga-ui-kit-directives-highlight.js.map +1 -1
  451. package/fesm2015/taiga-ui-kit-directives-lazy-loading.js +3 -3
  452. package/fesm2015/taiga-ui-kit-directives-lazy-loading.js.map +1 -1
  453. package/fesm2015/taiga-ui-kit-directives-present.js +3 -3
  454. package/fesm2015/taiga-ui-kit-directives-present.js.map +1 -1
  455. package/fesm2015/taiga-ui-kit-directives-project-class.js +0 -3
  456. package/fesm2015/taiga-ui-kit-directives-project-class.js.map +1 -1
  457. package/fesm2015/taiga-ui-kit-directives.js +1 -3
  458. package/fesm2015/taiga-ui-kit-directives.js.map +1 -1
  459. package/fesm2015/taiga-ui-kit-internal-primitive-calendar-range.js +6 -6
  460. package/fesm2015/taiga-ui-kit-internal-primitive-calendar-range.js.map +1 -1
  461. package/fesm2015/taiga-ui-kit-pipes-field-error.js +0 -2
  462. package/fesm2015/taiga-ui-kit-pipes-field-error.js.map +1 -1
  463. package/fesm2015/taiga-ui-kit-pipes-filter-by-input.js +4 -4
  464. package/fesm2015/taiga-ui-kit-pipes-filter-by-input.js.map +1 -1
  465. package/fesm2015/taiga-ui-kit-providers.js +13 -40
  466. package/fesm2015/taiga-ui-kit-providers.js.map +1 -1
  467. package/fesm2015/taiga-ui-kit-tokens.js +15 -8
  468. package/fesm2015/taiga-ui-kit-tokens.js.map +1 -1
  469. package/fesm2015/taiga-ui-kit-utils-files.js +5 -15
  470. package/fesm2015/taiga-ui-kit-utils-files.js.map +1 -1
  471. package/fesm2015/taiga-ui-kit-utils-format.js +2 -5
  472. package/fesm2015/taiga-ui-kit-utils-format.js.map +1 -1
  473. package/fesm2015/taiga-ui-kit-utils-mask.js +4 -9
  474. package/fesm2015/taiga-ui-kit-utils-mask.js.map +1 -1
  475. package/fesm2015/taiga-ui-kit-utils-math.js +2 -2
  476. package/fesm2015/taiga-ui-kit-utils-math.js.map +1 -1
  477. package/fesm2015/taiga-ui-kit-utils-miscellaneous.js +2 -5
  478. package/fesm2015/taiga-ui-kit-utils-miscellaneous.js.map +1 -1
  479. package/fesm2015/taiga-ui-kit-utils.js +0 -1
  480. package/fesm2015/taiga-ui-kit-utils.js.map +1 -1
  481. package/interfaces/index.d.ts +0 -1
  482. package/package.json +5 -5
  483. package/providers/month-formatter.provider.d.ts +0 -7
  484. package/providers/specific-dropdown-controllers.d.ts +1 -6
  485. package/tokens/calendar-date-stream.d.ts +5 -0
  486. package/tokens/index.d.ts +1 -2
  487. package/tokens/validation-errors.d.ts +1 -1
  488. package/utils/files/format-size.d.ts +1 -5
  489. package/utils/files/get-accept-array.d.ts +1 -5
  490. package/utils/format/string-hash-to-hsl.d.ts +1 -3
  491. package/utils/index.d.ts +0 -1
  492. package/utils/mask/create-auto-corrected-date-pipe.d.ts +1 -5
  493. package/utils/miscellaneous/get-precision.d.ts +1 -3
  494. package/abstract/index.d.ts +0 -1
  495. package/abstract/package.json +0 -10
  496. package/abstract/slider/slider.d.ts +0 -69
  497. package/abstract/taiga-ui-kit-abstract.d.ts +0 -5
  498. package/bundles/taiga-ui-kit-abstract.umd.js +0 -651
  499. package/bundles/taiga-ui-kit-abstract.umd.js.map +0 -1
  500. package/bundles/taiga-ui-kit-directives-dropdown-context.umd.js.map +0 -1
  501. package/bundles/taiga-ui-kit-directives-dropdown-hover.umd.js +0 -107
  502. package/bundles/taiga-ui-kit-directives-dropdown-hover.umd.js.map +0 -1
  503. package/bundles/taiga-ui-kit-directives-dropdown-selection.umd.js +0 -643
  504. package/bundles/taiga-ui-kit-directives-dropdown-selection.umd.js.map +0 -1
  505. package/bundles/taiga-ui-kit-utils-dom.umd.js +0 -124
  506. package/bundles/taiga-ui-kit-utils-dom.umd.js.map +0 -1
  507. package/components/combo-box/combo-box.providers.d.ts +0 -1
  508. package/components/input/input.providers.d.ts +0 -1
  509. package/components/input-copy/input-copy.providers.d.ts +0 -2
  510. package/components/input-date/input-date.providers.d.ts +0 -1
  511. package/components/input-date-range/input-date-range.providers.d.ts +0 -1
  512. package/components/input-date-time/input-date-time.providers.d.ts +0 -1
  513. package/components/input-month/input-month.providers.d.ts +0 -2
  514. package/components/input-month-range/input-month-range.providers.d.ts +0 -2
  515. package/components/input-phone/input-phone.providers.d.ts +0 -5
  516. package/components/select/select.providers.d.ts +0 -1
  517. package/components/text-area/text-area.providers.d.ts +0 -2
  518. package/directives/dropdown-context/dropdown-context.directive.d.ts +0 -30
  519. package/directives/dropdown-context/dropdown-context.module.d.ts +0 -8
  520. package/directives/dropdown-context/index.d.ts +0 -2
  521. package/directives/dropdown-context/package.json +0 -10
  522. package/directives/dropdown-context/taiga-ui-kit-directives-dropdown-context.d.ts +0 -5
  523. package/directives/dropdown-hover/dropdown-hover.directive.d.ts +0 -11
  524. package/directives/dropdown-hover/dropdown-hover.module.d.ts +0 -7
  525. package/directives/dropdown-hover/index.d.ts +0 -2
  526. package/directives/dropdown-hover/package.json +0 -10
  527. package/directives/dropdown-hover/taiga-ui-kit-directives-dropdown-hover.d.ts +0 -5
  528. package/directives/dropdown-selection/dropdown-selection.directive.d.ts +0 -46
  529. package/directives/dropdown-selection/dropdown-selection.module.d.ts +0 -8
  530. package/directives/dropdown-selection/index.d.ts +0 -2
  531. package/directives/dropdown-selection/package.json +0 -10
  532. package/directives/dropdown-selection/taiga-ui-kit-directives-dropdown-selection.d.ts +0 -5
  533. package/esm2015/abstract/index.js +0 -2
  534. package/esm2015/abstract/slider/slider.js +0 -264
  535. package/esm2015/abstract/taiga-ui-kit-abstract.js +0 -5
  536. package/esm2015/components/combo-box/combo-box.providers.js +0 -26
  537. package/esm2015/components/input/input.providers.js +0 -22
  538. package/esm2015/components/input-copy/input-copy.providers.js +0 -16
  539. package/esm2015/components/input-date/input-date.providers.js +0 -27
  540. package/esm2015/components/input-date-range/input-date-range.providers.js +0 -27
  541. package/esm2015/components/input-date-time/input-date-time.providers.js +0 -27
  542. package/esm2015/components/input-month/input-month.providers.js +0 -19
  543. package/esm2015/components/input-month-range/input-month-range.providers.js +0 -19
  544. package/esm2015/components/input-phone/input-phone.providers.js +0 -35
  545. package/esm2015/components/select/select.providers.js +0 -26
  546. package/esm2015/components/text-area/text-area.providers.js +0 -18
  547. package/esm2015/directives/dropdown-context/dropdown-context.directive.js +0 -141
  548. package/esm2015/directives/dropdown-context/dropdown-context.module.js +0 -18
  549. package/esm2015/directives/dropdown-context/index.js +0 -3
  550. package/esm2015/directives/dropdown-context/taiga-ui-kit-directives-dropdown-context.js +0 -5
  551. package/esm2015/directives/dropdown-hover/dropdown-hover.directive.js +0 -56
  552. package/esm2015/directives/dropdown-hover/dropdown-hover.module.js +0 -16
  553. package/esm2015/directives/dropdown-hover/index.js +0 -3
  554. package/esm2015/directives/dropdown-hover/taiga-ui-kit-directives-dropdown-hover.js +0 -5
  555. package/esm2015/directives/dropdown-selection/dropdown-selection.directive.js +0 -252
  556. package/esm2015/directives/dropdown-selection/dropdown-selection.module.js +0 -18
  557. package/esm2015/directives/dropdown-selection/index.js +0 -3
  558. package/esm2015/directives/dropdown-selection/taiga-ui-kit-directives-dropdown-selection.js +0 -5
  559. package/esm2015/interfaces/bread-crumbs-item.js +0 -2
  560. package/esm2015/tokens/calendar-data-stream.js +0 -3
  561. package/esm2015/tokens/tag-status.js +0 -6
  562. package/esm2015/utils/dom/get-word-range.js +0 -53
  563. package/esm2015/utils/dom/index.js +0 -4
  564. package/esm2015/utils/dom/scroll-to-element.js +0 -23
  565. package/esm2015/utils/dom/set-range-offset.js +0 -29
  566. package/esm2015/utils/dom/taiga-ui-kit-utils-dom.js +0 -5
  567. package/fesm2015/taiga-ui-kit-abstract.js +0 -271
  568. package/fesm2015/taiga-ui-kit-abstract.js.map +0 -1
  569. package/fesm2015/taiga-ui-kit-directives-dropdown-context.js +0 -162
  570. package/fesm2015/taiga-ui-kit-directives-dropdown-context.js.map +0 -1
  571. package/fesm2015/taiga-ui-kit-directives-dropdown-hover.js +0 -76
  572. package/fesm2015/taiga-ui-kit-directives-dropdown-hover.js.map +0 -1
  573. package/fesm2015/taiga-ui-kit-directives-dropdown-selection.js +0 -273
  574. package/fesm2015/taiga-ui-kit-directives-dropdown-selection.js.map +0 -1
  575. package/fesm2015/taiga-ui-kit-utils-dom.js +0 -111
  576. package/fesm2015/taiga-ui-kit-utils-dom.js.map +0 -1
  577. package/interfaces/bread-crumbs-item.d.ts +0 -6
  578. package/tokens/calendar-data-stream.d.ts +0 -4
  579. package/tokens/tag-status.d.ts +0 -3
  580. package/utils/dom/get-word-range.d.ts +0 -9
  581. package/utils/dom/index.d.ts +0 -3
  582. package/utils/dom/package.json +0 -10
  583. package/utils/dom/scroll-to-element.d.ts +0 -5
  584. package/utils/dom/set-range-offset.d.ts +0 -6
  585. package/utils/dom/taiga-ui-kit-utils-dom.d.ts +0 -5
@@ -1,162 +0,0 @@
1
- import { __decorate } from 'tslib';
2
- import { DOCUMENT } from '@angular/common';
3
- import * as i0 from '@angular/core';
4
- import { ComponentFactoryResolver, Injector, forwardRef, Directive, Inject, Input, HostListener, NgModule } from '@angular/core';
5
- import * as i1 from '@taiga-ui/cdk';
6
- import { EMPTY_CLIENT_RECT, tuiGetNativeFocused, tuiGetClosestFocusable, setNativeFocused, tuiPointToClientRect, TuiDestroyService, TuiDropdownPortalService, TuiActiveZoneDirective, tuiDefaultProp } from '@taiga-ui/cdk';
7
- import { AbstractTuiDropdown, TUI_DROPDOWN_DIRECTIVE, TuiDropdownBoxModule } from '@taiga-ui/core';
8
- import * as i2 from 'rxjs';
9
- import { EMPTY } from 'rxjs';
10
- import { filter, takeUntil } from 'rxjs/operators';
11
-
12
- // @dynamic
13
- class TuiDropdownContextDirective extends AbstractTuiDropdown {
14
- constructor(elementRef, documentRef, destroy$, componentFactoryResolver, injector, portalService, activeZone) {
15
- super(componentFactoryResolver, injector, portalService, elementRef, activeZone);
16
- this.elementRef = elementRef;
17
- this.documentRef = documentRef;
18
- this.activeZone = activeZone;
19
- this.lastClickedClientRect = EMPTY_CLIENT_RECT;
20
- this.content = ``;
21
- this.refresh$ = EMPTY;
22
- this.context = { close: () => this.closeDropdownBox() };
23
- activeZone.tuiActiveZoneChange
24
- .pipe(filter(isActive => !isActive), takeUntil(destroy$))
25
- .subscribe(() => this.closeDropdownBox());
26
- }
27
- get clientRect() {
28
- return this.lastClickedClientRect;
29
- }
30
- get fixed() {
31
- return true;
32
- }
33
- get dropdownContent() {
34
- var _a, _b;
35
- return ((_b = (_a = this.dropdownBoxRef) === null || _a === void 0 ? void 0 : _a.instance.contentElementRef) === null || _b === void 0 ? void 0 : _b.nativeElement) || null;
36
- }
37
- onHostClick() {
38
- this.closeDropdownBox();
39
- }
40
- onContextMenu(x, y) {
41
- this.closeDropdownBox();
42
- this.openDropdown(x, y);
43
- }
44
- onAnotherContextOpen(target) {
45
- const isAnotherContextOpened = !this.elementRef.nativeElement.contains(target);
46
- if (isAnotherContextOpened) {
47
- this.closeDropdownBox();
48
- }
49
- }
50
- onArrow(event, down) {
51
- const activeElement = tuiGetNativeFocused(this.documentRef);
52
- const focusInside = activeElement && this.activeZone.contains(activeElement);
53
- if (!this.dropdownContent || focusInside) {
54
- return;
55
- }
56
- event.preventDefault();
57
- const nextEl = this.dropdownContent.nextElementSibling;
58
- const initial = down || !this.checkIsFocusableElement(nextEl) ? this.dropdownContent : nextEl;
59
- const focusable = tuiGetClosestFocusable(initial, !down, this.dropdownContent);
60
- if (focusable === null) {
61
- return;
62
- }
63
- setNativeFocused(focusable);
64
- }
65
- onKeyDownEsc(event) {
66
- if (!this.dropdownContent) {
67
- return;
68
- }
69
- event.stopPropagation();
70
- this.closeDropdownBox();
71
- }
72
- openDropdown(x, y) {
73
- this.lastClickedClientRect = tuiPointToClientRect(x, y);
74
- this.openDropdownBox();
75
- }
76
- checkIsFocusableElement(element) {
77
- return !!element && `focus` in element && `blur` in element;
78
- }
79
- }
80
- TuiDropdownContextDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextDirective, deps: [{ token: i0.ElementRef }, { token: DOCUMENT }, { token: TuiDestroyService }, { token: ComponentFactoryResolver }, { token: Injector }, { token: TuiDropdownPortalService }, { token: i1.TuiActiveZoneDirective }], target: i0.ɵɵFactoryTarget.Directive });
81
- TuiDropdownContextDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiDropdownContextDirective, selector: "[tuiDropdownContext]", inputs: { content: ["tuiDropdownContext", "content"] }, host: { listeners: { "click": "onHostClick()", "contextmenu.prevent": "onContextMenu($event.clientX,$event.clientY)", "document:contextmenu": "onAnotherContextOpen($event.target)", "document:keydown.arrowDown": "onArrow($event,true)", "document:keydown.arrowUp": "onArrow($event,false)", "document:keydown.esc": "onKeyDownEsc($event)" } }, providers: [
82
- TuiDestroyService,
83
- TuiActiveZoneDirective,
84
- {
85
- provide: TUI_DROPDOWN_DIRECTIVE,
86
- useExisting: forwardRef(() => TuiDropdownContextDirective),
87
- },
88
- ], usesInheritance: true, ngImport: i0 });
89
- __decorate([
90
- tuiDefaultProp()
91
- ], TuiDropdownContextDirective.prototype, "content", void 0);
92
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextDirective, decorators: [{
93
- type: Directive,
94
- args: [{
95
- selector: `[tuiDropdownContext]`,
96
- providers: [
97
- TuiDestroyService,
98
- TuiActiveZoneDirective,
99
- {
100
- provide: TUI_DROPDOWN_DIRECTIVE,
101
- useExisting: forwardRef(() => TuiDropdownContextDirective),
102
- },
103
- ],
104
- }]
105
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: Document, decorators: [{
106
- type: Inject,
107
- args: [DOCUMENT]
108
- }] }, { type: i2.Observable, decorators: [{
109
- type: Inject,
110
- args: [TuiDestroyService]
111
- }] }, { type: i0.ComponentFactoryResolver, decorators: [{
112
- type: Inject,
113
- args: [ComponentFactoryResolver]
114
- }] }, { type: i0.Injector, decorators: [{
115
- type: Inject,
116
- args: [Injector]
117
- }] }, { type: i1.TuiDropdownPortalService, decorators: [{
118
- type: Inject,
119
- args: [TuiDropdownPortalService]
120
- }] }, { type: i1.TuiActiveZoneDirective }]; }, propDecorators: { content: [{
121
- type: Input,
122
- args: [`tuiDropdownContext`]
123
- }], onHostClick: [{
124
- type: HostListener,
125
- args: [`click`]
126
- }], onContextMenu: [{
127
- type: HostListener,
128
- args: [`contextmenu.prevent`, [`$event.clientX`, `$event.clientY`]]
129
- }], onAnotherContextOpen: [{
130
- type: HostListener,
131
- args: [`document:contextmenu`, [`$event.target`]]
132
- }], onArrow: [{
133
- type: HostListener,
134
- args: [`document:keydown.arrowDown`, [`$event`, `true`]]
135
- }, {
136
- type: HostListener,
137
- args: [`document:keydown.arrowUp`, [`$event`, `false`]]
138
- }], onKeyDownEsc: [{
139
- type: HostListener,
140
- args: [`document:keydown.esc`, [`$event`]]
141
- }] } });
142
-
143
- class TuiDropdownContextModule {
144
- }
145
- TuiDropdownContextModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
146
- TuiDropdownContextModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextModule, declarations: [TuiDropdownContextDirective], imports: [TuiDropdownBoxModule], exports: [TuiDropdownContextDirective] });
147
- TuiDropdownContextModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextModule, imports: [[TuiDropdownBoxModule]] });
148
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownContextModule, decorators: [{
149
- type: NgModule,
150
- args: [{
151
- imports: [TuiDropdownBoxModule],
152
- declarations: [TuiDropdownContextDirective],
153
- exports: [TuiDropdownContextDirective],
154
- }]
155
- }] });
156
-
157
- /**
158
- * Generated bundle index. Do not edit.
159
- */
160
-
161
- export { TuiDropdownContextDirective, TuiDropdownContextModule };
162
- //# sourceMappingURL=taiga-ui-kit-directives-dropdown-context.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-directives-dropdown-context.js","sources":["../../../projects/kit/directives/dropdown-context/dropdown-context.directive.ts","../../../projects/kit/directives/dropdown-context/dropdown-context.module.ts","../../../projects/kit/directives/dropdown-context/taiga-ui-kit-directives-dropdown-context.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {\n ComponentFactoryResolver,\n Directive,\n ElementRef,\n forwardRef,\n HostListener,\n Inject,\n Injector,\n Input,\n} from '@angular/core';\nimport {\n EMPTY_CLIENT_RECT,\n setNativeFocused,\n TuiActiveZoneDirective,\n tuiDefaultProp,\n TuiDestroyService,\n TuiDropdownPortalService,\n tuiGetClosestFocusable,\n tuiGetNativeFocused,\n tuiPointToClientRect,\n} from '@taiga-ui/cdk';\nimport {AbstractTuiDropdown, TUI_DROPDOWN_DIRECTIVE, TuiDropdown} from '@taiga-ui/core';\nimport {PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\nimport {EMPTY, Observable} from 'rxjs';\nimport {filter, takeUntil} from 'rxjs/operators';\n\n// @dynamic\n@Directive({\n selector: `[tuiDropdownContext]`,\n providers: [\n TuiDestroyService,\n TuiActiveZoneDirective,\n {\n provide: TUI_DROPDOWN_DIRECTIVE,\n useExisting: forwardRef(() => TuiDropdownContextDirective),\n },\n ],\n})\nexport class TuiDropdownContextDirective\n extends AbstractTuiDropdown\n implements TuiDropdown\n{\n private lastClickedClientRect = EMPTY_CLIENT_RECT;\n\n @Input(`tuiDropdownContext`)\n @tuiDefaultProp()\n content: PolymorpheusContent = ``;\n\n readonly refresh$ = EMPTY;\n\n readonly context = {close: () => this.closeDropdownBox()};\n\n constructor(\n protected readonly elementRef: ElementRef,\n @Inject(DOCUMENT) private readonly documentRef: Document,\n @Inject(TuiDestroyService) destroy$: Observable<unknown>,\n @Inject(ComponentFactoryResolver)\n componentFactoryResolver: ComponentFactoryResolver,\n @Inject(Injector) injector: Injector,\n @Inject(TuiDropdownPortalService) portalService: TuiDropdownPortalService,\n readonly activeZone: TuiActiveZoneDirective,\n ) {\n super(componentFactoryResolver, injector, portalService, elementRef, activeZone);\n\n activeZone.tuiActiveZoneChange\n .pipe(\n filter(isActive => !isActive),\n takeUntil(destroy$),\n )\n .subscribe(() => this.closeDropdownBox());\n }\n\n get clientRect(): ClientRect {\n return this.lastClickedClientRect;\n }\n\n get fixed(): boolean {\n return true;\n }\n\n private get dropdownContent(): HTMLElement | null {\n return this.dropdownBoxRef?.instance.contentElementRef?.nativeElement || null;\n }\n\n @HostListener(`click`)\n onHostClick(): void {\n this.closeDropdownBox();\n }\n\n @HostListener(`contextmenu.prevent`, [`$event.clientX`, `$event.clientY`])\n onContextMenu(x: number, y: number): void {\n this.closeDropdownBox();\n this.openDropdown(x, y);\n }\n\n @HostListener(`document:contextmenu`, [`$event.target`])\n onAnotherContextOpen(target: HTMLElement): void {\n const isAnotherContextOpened = !this.elementRef.nativeElement.contains(target);\n\n if (isAnotherContextOpened) {\n this.closeDropdownBox();\n }\n }\n\n @HostListener(`document:keydown.arrowDown`, [`$event`, `true`])\n @HostListener(`document:keydown.arrowUp`, [`$event`, `false`])\n onArrow(event: KeyboardEvent, down: boolean): void {\n const activeElement = tuiGetNativeFocused(this.documentRef);\n const focusInside = activeElement && this.activeZone.contains(activeElement);\n\n if (!this.dropdownContent || focusInside) {\n return;\n }\n\n event.preventDefault();\n\n const nextEl = this.dropdownContent.nextElementSibling;\n const initial =\n down || !this.checkIsFocusableElement(nextEl) ? this.dropdownContent : nextEl;\n const focusable = tuiGetClosestFocusable(initial, !down, this.dropdownContent);\n\n if (focusable === null) {\n return;\n }\n\n setNativeFocused(focusable);\n }\n\n @HostListener(`document:keydown.esc`, [`$event`])\n onKeyDownEsc(event: KeyboardEvent): void {\n if (!this.dropdownContent) {\n return;\n }\n\n event.stopPropagation();\n this.closeDropdownBox();\n }\n\n private openDropdown(x: number, y: number): void {\n this.lastClickedClientRect = tuiPointToClientRect(x, y);\n this.openDropdownBox();\n }\n\n private checkIsFocusableElement(element: Element | null): element is HTMLElement {\n return !!element && `focus` in element && `blur` in element;\n }\n}\n","import {NgModule} from '@angular/core';\nimport {TuiDropdownBoxModule} from '@taiga-ui/core';\n\nimport {TuiDropdownContextDirective} from './dropdown-context.directive';\n\n@NgModule({\n imports: [TuiDropdownBoxModule],\n declarations: [TuiDropdownContextDirective],\n exports: [TuiDropdownContextDirective],\n})\nexport class TuiDropdownContextModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AA2BA;AAYM,MAAO,2BACT,SAAQ,mBAAmB,CAAA;AAa3B,IAAA,WAAA,CACuB,UAAsB,EACN,WAAqB,EAC7B,QAA6B,EAExD,wBAAkD,EAChC,QAAkB,EACF,aAAuC,EAChE,UAAkC,EAAA;QAE3C,KAAK,CAAC,wBAAwB,EAAE,QAAQ,EAAE,aAAa,EAAE,UAAU,EAAE,UAAU,CAAC,CAAC;QAT9D,IAAU,CAAA,UAAA,GAAV,UAAU,CAAY;QACN,IAAW,CAAA,WAAA,GAAX,WAAW,CAAU;QAM/C,IAAU,CAAA,UAAA,GAAV,UAAU,CAAwB;QAlBvC,IAAqB,CAAA,qBAAA,GAAG,iBAAiB,CAAC;QAIlD,IAAO,CAAA,OAAA,GAAwB,EAAE,CAAC;QAEzB,IAAQ,CAAA,QAAA,GAAG,KAAK,CAAC;AAEjB,QAAA,IAAA,CAAA,OAAO,GAAG,EAAC,KAAK,EAAE,MAAM,IAAI,CAAC,gBAAgB,EAAE,EAAC,CAAC;AActD,QAAA,UAAU,CAAC,mBAAmB;AACzB,aAAA,IAA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,CAAA;AAAxB,wBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,wBAAwB,EAHlB,YAAA,EAAA,CAAA,2BAA2B,CADhC,EAAA,OAAA,EAAA,CAAA,oBAAoB,aAEpB,2BAA2B,CAAA,EAAA,CAAA,CAAA;uHAE5B,wBAAwB,EAAA,OAAA,EAAA,CAJxB,CAAC,oBAAoB,CAAC,CAAA,EAAA,CAAA,CAAA;4FAItB,wBAAwB,EAAA,UAAA,EAAA,CAAA;kBALpC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,oBAAoB,CAAC;oBAC/B,YAAY,EAAE,CAAC,2BAA2B,CAAC;oBAC3C,OAAO,EAAE,CAAC,2BAA2B,CAAC;AACzC,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
@@ -1,76 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { ElementRef, Directive, Inject, HostListener, NgModule } from '@angular/core';
3
- import { isPresent, typedFromEvent, tuiIsNativeFocusedIn, tuiGetClosestFocusable, setNativeMouseFocused, TuiDestroyService } from '@taiga-ui/cdk';
4
- import * as i2 from '@taiga-ui/core';
5
- import { TuiHostedDropdownComponent } from '@taiga-ui/core';
6
- import * as i1 from 'rxjs';
7
- import { merge, of, timer } from 'rxjs';
8
- import { debounceTime, map, filter, share, tap, switchMap, mapTo, debounce, distinctUntilChanged, takeUntil } from 'rxjs/operators';
9
-
10
- // TODO: Refactor
11
- class TuiDropdownHoverDirective {
12
- constructor(destroy$, { nativeElement }, dropdown) {
13
- this.dropdown = dropdown;
14
- const dropdown$ = dropdown.openChange.pipe(
15
- // Give change detection time to open dropdown
16
- debounceTime(0), map(() => dropdown.dropdown), filter(isPresent), share());
17
- const open$ = merge(typedFromEvent(nativeElement, `mouseenter`), typedFromEvent(nativeElement, `click`).pipe(tap(e => e.stopImmediatePropagation())), dropdown$.pipe(switchMap(element => merge(typedFromEvent(element, `focusin`), typedFromEvent(element, `mouseenter`))))).pipe(mapTo(true));
18
- const close$ = merge(typedFromEvent(nativeElement, `mouseleave`), dropdown$.pipe(switchMap(element => typedFromEvent(element, `mouseleave`).pipe(filter(() => !tuiIsNativeFocusedIn(element)))))).pipe(mapTo(false));
19
- merge(open$, close$)
20
- .pipe(debounce(value => (value ? of(value) : timer(300))), distinctUntilChanged(), takeUntil(destroy$))
21
- .subscribe(open => {
22
- dropdown.updateOpen(open);
23
- });
24
- }
25
- onMouseEnter() {
26
- const { host } = this.dropdown;
27
- if (tuiIsNativeFocusedIn(host)) {
28
- return;
29
- }
30
- const focusable = tuiGetClosestFocusable(host, false, host, false);
31
- if (focusable) {
32
- setNativeMouseFocused(focusable);
33
- }
34
- }
35
- }
36
- TuiDropdownHoverDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverDirective, deps: [{ token: TuiDestroyService }, { token: ElementRef }, { token: TuiHostedDropdownComponent }], target: i0.ɵɵFactoryTarget.Directive });
37
- TuiDropdownHoverDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiDropdownHoverDirective, selector: "tui-hosted-dropdown[tuiDropdownHover]", host: { listeners: { "mouseenter": "onMouseEnter()" } }, providers: [TuiDestroyService], ngImport: i0 });
38
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverDirective, decorators: [{
39
- type: Directive,
40
- args: [{
41
- selector: `tui-hosted-dropdown[tuiDropdownHover]`,
42
- providers: [TuiDestroyService],
43
- }]
44
- }], ctorParameters: function () { return [{ type: i1.Observable, decorators: [{
45
- type: Inject,
46
- args: [TuiDestroyService]
47
- }] }, { type: i0.ElementRef, decorators: [{
48
- type: Inject,
49
- args: [ElementRef]
50
- }] }, { type: i2.TuiHostedDropdownComponent, decorators: [{
51
- type: Inject,
52
- args: [TuiHostedDropdownComponent]
53
- }] }]; }, propDecorators: { onMouseEnter: [{
54
- type: HostListener,
55
- args: [`mouseenter`]
56
- }] } });
57
-
58
- class TuiDropdownHoverModule {
59
- }
60
- TuiDropdownHoverModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
61
- TuiDropdownHoverModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverModule, declarations: [TuiDropdownHoverDirective], exports: [TuiDropdownHoverDirective] });
62
- TuiDropdownHoverModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverModule });
63
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownHoverModule, decorators: [{
64
- type: NgModule,
65
- args: [{
66
- declarations: [TuiDropdownHoverDirective],
67
- exports: [TuiDropdownHoverDirective],
68
- }]
69
- }] });
70
-
71
- /**
72
- * Generated bundle index. Do not edit.
73
- */
74
-
75
- export { TuiDropdownHoverDirective, TuiDropdownHoverModule };
76
- //# sourceMappingURL=taiga-ui-kit-directives-dropdown-hover.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-directives-dropdown-hover.js","sources":["../../../projects/kit/directives/dropdown-hover/dropdown-hover.directive.ts","../../../projects/kit/directives/dropdown-hover/dropdown-hover.module.ts","../../../projects/kit/directives/dropdown-hover/taiga-ui-kit-directives-dropdown-hover.ts"],"sourcesContent":["import {Directive, ElementRef, HostListener, Inject} from '@angular/core';\nimport {\n isPresent,\n setNativeMouseFocused,\n TuiDestroyService,\n tuiGetClosestFocusable,\n tuiIsNativeFocusedIn,\n typedFromEvent,\n} from '@taiga-ui/cdk';\nimport {TuiHostedDropdownComponent} from '@taiga-ui/core';\nimport {merge, Observable, of, timer} from 'rxjs';\nimport {\n debounce,\n debounceTime,\n distinctUntilChanged,\n filter,\n map,\n mapTo,\n share,\n switchMap,\n takeUntil,\n tap,\n} from 'rxjs/operators';\n\n// TODO: Refactor\n@Directive({\n selector: `tui-hosted-dropdown[tuiDropdownHover]`,\n providers: [TuiDestroyService],\n})\nexport class TuiDropdownHoverDirective {\n constructor(\n @Inject(TuiDestroyService) destroy$: Observable<void>,\n @Inject(ElementRef) {nativeElement}: ElementRef<HTMLElement>,\n @Inject(TuiHostedDropdownComponent)\n private readonly dropdown: TuiHostedDropdownComponent,\n ) {\n const dropdown$ = dropdown.openChange.pipe(\n // Give change detection time to open dropdown\n debounceTime(0),\n map(() => dropdown.dropdown),\n filter(isPresent),\n share(),\n );\n\n const open$ = merge(\n typedFromEvent(nativeElement, `mouseenter`),\n typedFromEvent(nativeElement, `click`).pipe(\n tap(e => e.stopImmediatePropagation()),\n ),\n dropdown$.pipe(\n switchMap(element =>\n merge(\n typedFromEvent(element, `focusin`),\n typedFromEvent(element, `mouseenter`),\n ),\n ),\n ),\n ).pipe(mapTo(true));\n\n const close$ = merge(\n typedFromEvent(nativeElement, `mouseleave`),\n dropdown$.pipe(\n switchMap(element =>\n typedFromEvent(element, `mouseleave`).pipe(\n filter(() => !tuiIsNativeFocusedIn(element)),\n ),\n ),\n ),\n ).pipe(mapTo(false));\n\n merge(open$, close$)\n .pipe(\n debounce(value => (value ? of(value) : timer(300))),\n distinctUntilChanged(),\n takeUntil(destroy$),\n )\n .subscribe(open => {\n dropdown.updateOpen(open);\n });\n }\n\n @HostListener(`mouseenter`)\n onMouseEnter(): void {\n const {host} = this.dropdown;\n\n if (tuiIsNativeFocusedIn(host)) {\n return;\n }\n\n const focusable = tuiGetClosestFocusable(host, false, host, false);\n\n if (focusable) {\n setNativeMouseFocused(focusable);\n }\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiDropdownHoverDirective} from './dropdown-hover.directive';\n\n@NgModule({\n declarations: [TuiDropdownHoverDirective],\n exports: [TuiDropdownHoverDirective],\n})\nexport class TuiDropdownHoverModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAwBA;MAKa,yBAAyB,CAAA;AAClC,IAAA,WAAA,CAC+B,QAA0B,EACjC,EAAC,aAAa,EAA0B,EAE3C,QAAoC,EAAA;QAApC,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAA4B;AAErD,QAAA,MAAM,SAAS,GAAG,QAAQ,CAAC,UAAU,CAAC,IAAI;;QAEtC,YAAY,CAAC,CAAC,CAAC,EACf,GAAG,CAAC,MAAM,QAAQ,CAAC,QAAQ,CAAC,EAC5B,MAAM,CAAC,SAAS,CAAC,EACjB,KAAK,EAAE,CACV,CAAC;AAEF,QAAA,MAAM,KAAK,GAAG,KAAK,CACf,cAAc,CAAC,aAAa,EAAE,CAAA,UAAA,CAAY,CAAC,EAC3C,cAAc,CAAC,aAAa,EAAE,CAAA,KAAA,CAAO,CAAC,CAAC,IAAI,CACvC,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,wBAAwB,EAAE,CAAC,CACzC,EACD,SAAS,CAAC,IAAI,CACV,SAAS,CAAC,OAAO,IACb,KAAK,CACD,cAAc,CAAC,OAAO,EAAE,CAAA,OAAA,CAAS,CAAC,EAClC,cAAc,CAAC,OAAO,EAAE,CAAA,UAAA,CAAY,CAAC,CACxC,CACJ,CACJ,CACJ,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC;QAEpB,MAAM,MAAM,GAAG,KAAK,CAChB,cAAc,CAAC,aAAa,EAAE,CAAY,UAAA,CAAA,CAAC,EAC3C,SAAS,CAAC,IAAI,CACV,SAAS,CAAC,OAAO,IACb,cAAc,CAAC,OAAO,EAAE,CAAA,UAAA,CAAY,CAAC,CAAC,IAAI,CACtC,MAAM,CAAC,MAAM,C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A,EAAA,gBAAA,EAAA,EAAA,EAAA,SAAA,EAFvB,CAAC,iBAAiB,CAAC,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;4FAErB,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAJrC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,CAAuC,qCAAA,CAAA;oBACjD,SAAS,EAAE,CAAC,iBAAiB,CAAC;AACjC,iBAAA,CAAA;;0BAGQ,MAAM;2BAAC,iBAAiB,CAAA;;0BACxB,MAAM;2BAAC,UAAU,CAAA;;0BACjB,MAAM;2BAAC,0BAA0B,CAAA;4CAiDtC,YAAY,EAAA,CAAA;sBADX,YAAY;uBAAC,CAAY,UAAA,CAAA,CAAA;;;MCzEjB,sBAAsB,CAAA;;oHAAtB,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;qHAAtB,sBAAsB,EAAA,YAAA,EAAA,CAHhB,yBAAyB,CAAA,EAAA,OAAA,EAAA,CAC9B,yBAAyB,CAAA,EAAA,CAAA,CAAA;qHAE1B,sBAAsB,EAAA,CAAA,CAAA;4FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAJlC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,yBAAyB,CAAC;oBACzC,OAAO,EAAE,CAAC,yBAAyB,CAAC;AACvC,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
@@ -1,273 +0,0 @@
1
- import { DOCUMENT } from '@angular/common';
2
- import * as i0 from '@angular/core';
3
- import { ComponentFactoryResolver, Injector, ElementRef, ChangeDetectorRef, NgZone, Renderer2, ViewContainerRef, forwardRef, Directive, Inject, Host, Optional, Input, NgModule } from '@angular/core';
4
- import * as i1 from '@taiga-ui/cdk';
5
- import { ALWAYS_TRUE_HANDLER, typedFromEvent, tuiGetNativeFocused, EMPTY_CLIENT_RECT, tuiPx, CHAR_ZERO_WIDTH_SPACE, CHAR_NO_BREAK_SPACE, TuiDropdownPortalService, TuiActiveZoneDirective, TuiDestroyService, TuiParentsScrollService } from '@taiga-ui/cdk';
6
- import { AbstractTuiDropdown, TUI_DOCUMENT_OR_SHADOW_ROOT, TUI_ELEMENT_REF, TUI_DROPDOWN_DIRECTIVE, TuiDropdownBoxModule } from '@taiga-ui/core';
7
- import { getWordRange } from '@taiga-ui/kit/utils/dom';
8
- import { merge } from 'rxjs';
9
- import { switchMapTo, takeUntil, map } from 'rxjs/operators';
10
-
11
- // @dynamic
12
- class TuiDropdownSelectionDirective extends AbstractTuiDropdown {
13
- constructor(documentRef, componentFactoryResolver, injector, portalService, elementRef, activeZone, shadowRootRef, customElementRef, destroy$, refresh$, changeDetectorRef, ngZone, renderer, viewContainerRef) {
14
- super(componentFactoryResolver, injector, portalService, customElementRef || elementRef, activeZone);
15
- this.refresh$ = refresh$;
16
- this.changeDetectorRef = changeDetectorRef;
17
- this.ngZone = ngZone;
18
- this.renderer = renderer;
19
- this.viewContainerRef = viewContainerRef;
20
- this.visibilityHandler = ALWAYS_TRUE_HANDLER;
21
- this.position = `selection`;
22
- this.documentRef = shadowRootRef || documentRef;
23
- // SSR protection
24
- if (!this.documentRef.createRange) {
25
- return;
26
- }
27
- this.range = this.documentRef.createRange();
28
- const { nativeElement } = this.elementRef;
29
- merge(typedFromEvent(this.documentRef, `mouseup`), typedFromEvent(nativeElement, `mousedown`).pipe(switchMapTo(typedFromEvent(nativeElement, `mousemove`).pipe(takeUntil(typedFromEvent(this.documentRef, `mouseup`))))), typedFromEvent(nativeElement, `keyup`))
30
- .pipe(map(() => {
31
- const active = tuiGetNativeFocused(this.documentRef);
32
- const selection = this.documentRef.getSelection();
33
- // TODO: iframe warning
34
- if ((active instanceof HTMLInputElement ||
35
- active instanceof HTMLTextAreaElement) &&
36
- nativeElement.contains(active)) {
37
- return this.veryVerySadInputFix(active);
38
- }
39
- return (selection === null || selection === void 0 ? void 0 : selection.rangeCount) ? selection.getRangeAt(0) : this.range;
40
- }), takeUntil(destroy$))
41
- .subscribe(range => {
42
- const contained = !!range && nativeElement.contains(range.commonAncestorContainer);
43
- this.range = contained ? range : this.range;
44
- const valid = contained &&
45
- (!this.visibilityHandler ||
46
- !this.range ||
47
- this.visibilityHandler(this.range));
48
- this.toggleDropdownBox(!!range && (valid || this.inDropdown(range)));
49
- });
50
- }
51
- set tuiDropdownSelection(handler) {
52
- if (!handler || !this.range) {
53
- return;
54
- }
55
- const inHostAndValid = this.elementRef.nativeElement.contains(this.range.commonAncestorContainer) &&
56
- handler(this.range);
57
- this.visibilityHandler = handler;
58
- this.toggleDropdownBox(inHostAndValid);
59
- }
60
- get clientRect() {
61
- const { defaultView } = this.documentRef;
62
- const { rangeRect } = this;
63
- const frameElement = defaultView ? defaultView.frameElement : null;
64
- if (!frameElement) {
65
- return rangeRect;
66
- }
67
- const documentRect = frameElement.getBoundingClientRect();
68
- return {
69
- top: rangeRect.top + documentRect.top,
70
- left: rangeRect.left + documentRect.left,
71
- right: rangeRect.left + documentRect.left + rangeRect.width,
72
- bottom: rangeRect.top + documentRect.top + rangeRect.height,
73
- width: rangeRect.width,
74
- height: rangeRect.height,
75
- };
76
- }
77
- ngOnDestroy() {
78
- this.closeDropdownBox();
79
- if (this.ghost) {
80
- this.renderer.removeChild(this.viewContainerRef.element.nativeElement, this.ghost);
81
- }
82
- }
83
- /**
84
- * get ClientRect of current Range according to provided position
85
- */
86
- get rangeRect() {
87
- if (!this.range) {
88
- return EMPTY_CLIENT_RECT;
89
- }
90
- switch (this.position) {
91
- case `tag`: {
92
- const { commonAncestorContainer } = this.range;
93
- const element = commonAncestorContainer.nodeType === Node.ELEMENT_NODE
94
- ? commonAncestorContainer
95
- : commonAncestorContainer.parentNode;
96
- return element.getBoundingClientRect();
97
- }
98
- case `word`:
99
- return getWordRange(this.range).getBoundingClientRect();
100
- default:
101
- return this.range.getBoundingClientRect();
102
- }
103
- }
104
- /**
105
- * Toggle dropdown visibility (has to be in ngZone.run because it could be initiated inside iframe in Editor)
106
- */
107
- toggleDropdownBox(visible) {
108
- this.ngZone.run(() => {
109
- if (visible) {
110
- this.openDropdownBox();
111
- }
112
- else {
113
- this.closeDropdownBox();
114
- }
115
- this.changeDetectorRef.markForCheck();
116
- });
117
- }
118
- /**
119
- * Check if Node is inside dropdown
120
- */
121
- boxContains(node) {
122
- return (!!this.dropdownBoxRef &&
123
- this.dropdownBoxRef.location.nativeElement.contains(node));
124
- }
125
- /**
126
- * Check if given range is at least partially inside dropdown
127
- */
128
- inDropdown(range) {
129
- const { startContainer, endContainer } = range;
130
- const inDropdown = this.boxContains(range.commonAncestorContainer);
131
- const hostToDropdown = this.boxContains(endContainer) &&
132
- this.elementRef.nativeElement.contains(startContainer);
133
- const dropdownToHost = this.boxContains(startContainer) &&
134
- this.elementRef.nativeElement.contains(endContainer);
135
- return inDropdown || hostToDropdown || dropdownToHost;
136
- }
137
- /**
138
- * Position invisible DIV and create Range similar to selected range inside input/textarea
139
- */
140
- veryVerySadInputFix(element) {
141
- const { ghost = this.initGhost(element) } = this;
142
- const { top, left, width, height } = element.getBoundingClientRect();
143
- const { selectionStart, selectionEnd } = element;
144
- const range = this.documentRef.createRange();
145
- const hostRect = this.elementRef.nativeElement.getBoundingClientRect();
146
- ghost.style.top = tuiPx(top - hostRect.top);
147
- ghost.style.left = tuiPx(left - hostRect.left);
148
- ghost.style.width = tuiPx(width);
149
- ghost.style.height = tuiPx(height);
150
- ghost.textContent = CHAR_ZERO_WIDTH_SPACE + element.value + CHAR_NO_BREAK_SPACE;
151
- range.setStart(ghost.firstChild, selectionStart || 0);
152
- range.setEnd(ghost.firstChild, selectionEnd || 0);
153
- return range;
154
- }
155
- /**
156
- * Create an invisible DIV styled exactly like input/textarea element inside directive
157
- */
158
- initGhost(element) {
159
- const ghost = this.renderer.createElement(`div`);
160
- const { nativeElement } = this.viewContainerRef.element;
161
- const { font, letterSpacing, textTransform, padding } = getComputedStyle(element);
162
- ghost.style.position = `absolute`;
163
- ghost.style.pointerEvents = `none`;
164
- ghost.style.opacity = `0`;
165
- ghost.style.whiteSpace = `pre-wrap`;
166
- ghost.style.font = font;
167
- ghost.style.letterSpacing = letterSpacing;
168
- ghost.style.textTransform = textTransform;
169
- ghost.style.padding = padding;
170
- this.renderer.appendChild(nativeElement, ghost);
171
- this.ghost = ghost;
172
- return ghost;
173
- }
174
- }
175
- TuiDropdownSelectionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionDirective, deps: [{ token: DOCUMENT }, { token: ComponentFactoryResolver }, { token: Injector }, { token: TuiDropdownPortalService }, { token: ElementRef, host: true }, { token: TuiActiveZoneDirective, optional: true }, { token: TUI_DOCUMENT_OR_SHADOW_ROOT, optional: true }, { token: TUI_ELEMENT_REF, optional: true }, { token: TuiDestroyService }, { token: TuiParentsScrollService }, { token: ChangeDetectorRef }, { token: NgZone }, { token: Renderer2 }, { token: ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
176
- TuiDropdownSelectionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiDropdownSelectionDirective, selector: "[tuiDropdownSelection]:not(ng-container)", inputs: { tuiDropdownSelection: "tuiDropdownSelection", position: ["tuiDropdownSelectionPosition", "position"] }, providers: [
177
- {
178
- provide: TUI_DROPDOWN_DIRECTIVE,
179
- useExisting: forwardRef(() => TuiDropdownSelectionDirective),
180
- },
181
- TuiParentsScrollService,
182
- TuiDestroyService,
183
- ], usesInheritance: true, ngImport: i0 });
184
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionDirective, decorators: [{
185
- type: Directive,
186
- args: [{
187
- selector: `[tuiDropdownSelection]:not(ng-container)`,
188
- providers: [
189
- {
190
- provide: TUI_DROPDOWN_DIRECTIVE,
191
- useExisting: forwardRef(() => TuiDropdownSelectionDirective),
192
- },
193
- TuiParentsScrollService,
194
- TuiDestroyService,
195
- ],
196
- }]
197
- }], ctorParameters: function () { return [{ type: Document, decorators: [{
198
- type: Inject,
199
- args: [DOCUMENT]
200
- }] }, { type: i0.ComponentFactoryResolver, decorators: [{
201
- type: Inject,
202
- args: [ComponentFactoryResolver]
203
- }] }, { type: i0.Injector, decorators: [{
204
- type: Inject,
205
- args: [Injector]
206
- }] }, { type: i1.TuiDropdownPortalService, decorators: [{
207
- type: Inject,
208
- args: [TuiDropdownPortalService]
209
- }] }, { type: i0.ElementRef, decorators: [{
210
- type: Host
211
- }, {
212
- type: Inject,
213
- args: [ElementRef]
214
- }] }, { type: i1.TuiActiveZoneDirective, decorators: [{
215
- type: Inject,
216
- args: [TuiActiveZoneDirective]
217
- }, {
218
- type: Optional
219
- }] }, { type: Document, decorators: [{
220
- type: Inject,
221
- args: [TUI_DOCUMENT_OR_SHADOW_ROOT]
222
- }, {
223
- type: Optional
224
- }] }, { type: i0.ElementRef, decorators: [{
225
- type: Inject,
226
- args: [TUI_ELEMENT_REF]
227
- }, {
228
- type: Optional
229
- }] }, { type: i1.TuiDestroyService, decorators: [{
230
- type: Inject,
231
- args: [TuiDestroyService]
232
- }] }, { type: i1.TuiParentsScrollService, decorators: [{
233
- type: Inject,
234
- args: [TuiParentsScrollService]
235
- }] }, { type: i0.ChangeDetectorRef, decorators: [{
236
- type: Inject,
237
- args: [ChangeDetectorRef]
238
- }] }, { type: i0.NgZone, decorators: [{
239
- type: Inject,
240
- args: [NgZone]
241
- }] }, { type: i0.Renderer2, decorators: [{
242
- type: Inject,
243
- args: [Renderer2]
244
- }] }, { type: i0.ViewContainerRef, decorators: [{
245
- type: Inject,
246
- args: [ViewContainerRef]
247
- }] }]; }, propDecorators: { tuiDropdownSelection: [{
248
- type: Input
249
- }], position: [{
250
- type: Input,
251
- args: [`tuiDropdownSelectionPosition`]
252
- }] } });
253
-
254
- class TuiDropdownSelectionModule {
255
- }
256
- TuiDropdownSelectionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
257
- TuiDropdownSelectionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionModule, declarations: [TuiDropdownSelectionDirective], imports: [TuiDropdownBoxModule], exports: [TuiDropdownSelectionDirective] });
258
- TuiDropdownSelectionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionModule, imports: [[TuiDropdownBoxModule]] });
259
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDropdownSelectionModule, decorators: [{
260
- type: NgModule,
261
- args: [{
262
- imports: [TuiDropdownBoxModule],
263
- declarations: [TuiDropdownSelectionDirective],
264
- exports: [TuiDropdownSelectionDirective],
265
- }]
266
- }] });
267
-
268
- /**
269
- * Generated bundle index. Do not edit.
270
- */
271
-
272
- export { TuiDropdownSelectionDirective, TuiDropdownSelectionModule };
273
- //# sourceMappingURL=taiga-ui-kit-directives-dropdown-selection.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-kit-directives-dropdown-selection.js","sources":["../../../projects/kit/directives/dropdown-selection/dropdown-selection.directive.ts","../../../projects/kit/directives/dropdown-selection/dropdown-selection.module.ts","../../../projects/kit/directives/dropdown-selection/taiga-ui-kit-directives-dropdown-selection.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {\n ChangeDetectorRef,\n ComponentFactoryResolver,\n Directive,\n ElementRef,\n forwardRef,\n Host,\n Inject,\n Injector,\n Input,\n NgZone,\n OnDestroy,\n Optional,\n Renderer2,\n ViewContainerRef,\n} from '@angular/core';\nimport {\n ALWAYS_TRUE_HANDLER,\n CHAR_NO_BREAK_SPACE,\n CHAR_ZERO_WIDTH_SPACE,\n EMPTY_CLIENT_RECT,\n TuiActiveZoneDirective,\n TuiBooleanHandler,\n TuiDestroyService,\n TuiDropdownPortalService,\n tuiGetNativeFocused,\n TuiParentsScrollService,\n tuiPx,\n typedFromEvent,\n} from '@taiga-ui/cdk';\nimport {\n AbstractTuiDropdown,\n TUI_DOCUMENT_OR_SHADOW_ROOT,\n TUI_DROPDOWN_DIRECTIVE,\n TUI_ELEMENT_REF,\n TuiDropdown,\n} from '@taiga-ui/core';\nimport {getWordRange} from '@taiga-ui/kit/utils/dom';\nimport {merge} from 'rxjs';\nimport {map, switchMapTo, takeUntil} from 'rxjs/operators';\n\n// @dynamic\n@Directive({\n selector: `[tuiDropdownSelection]:not(ng-container)`,\n providers: [\n {\n provide: TUI_DROPDOWN_DIRECTIVE,\n useExisting: forwardRef(() => TuiDropdownSelectionDirective),\n },\n TuiParentsScrollService,\n TuiDestroyService,\n ],\n})\nexport class TuiDropdownSelectionDirective\n extends AbstractTuiDropdown\n implements TuiDropdown, OnDestroy\n{\n private visibilityHandler: TuiBooleanHandler<Range> = ALWAYS_TRUE_HANDLER;\n private readonly documentRef: Document;\n private ghost?: HTMLElement;\n private range?: Range;\n\n @Input()\n set tuiDropdownSelection(handler: TuiBooleanHandler<Range> | '') {\n if (!handler || !this.range) {\n return;\n }\n\n const inHostAndValid =\n this.elementRef.nativeElement.contains(this.range.commonAncestorContainer) &&\n handler(this.range);\n\n this.visibilityHandler = handler;\n this.toggleDropdownBox(inHostAndValid);\n }\n\n @Input(`tuiDropdownSelectionPosition`)\n position: 'selection' | 'word' | 'tag' = `selection`;\n\n constructor(\n @Inject(DOCUMENT) documentRef: Document,\n @Inject(ComponentFactoryResolver)\n componentFactoryResolver: ComponentFactoryResolver,\n @Inject(Injector) injector: Injector,\n @Inject(TuiDropdownPortalService) portalService: TuiDropdownPortalService,\n @Host() @Inject(ElementRef) elementRef: ElementRef<HTMLElement>,\n @Inject(TuiActiveZoneDirective)\n @Optional()\n activeZone: TuiActiveZoneDirective | null,\n @Inject(TUI_DOCUMENT_OR_SHADOW_ROOT)\n @Optional()\n shadowRootRef: Document | null,\n @Inject(TUI_ELEMENT_REF)\n @Optional()\n customElementRef: ElementRef<HTMLElement> | null,\n @Inject(TuiDestroyService)\n destroy$: TuiDestroyService,\n @Inject(TuiParentsScrollService) readonly refresh$: TuiParentsScrollService,\n @Inject(ChangeDetectorRef) private readonly changeDetectorRef: ChangeDetectorRef,\n @Inject(NgZone) private readonly ngZone: NgZone,\n @Inject(Renderer2) private readonly renderer: Renderer2,\n @Inject(ViewContainerRef) private readonly viewContainerRef: ViewContainerRef,\n ) {\n super(\n componentFactoryResolver,\n injector,\n portalService,\n customElementRef || elementRef,\n activeZone,\n );\n this.documentRef = shadowRootRef || documentRef;\n\n // SSR protection\n if (!this.documentRef.createRange) {\n return;\n }\n\n this.range = this.documentRef.createRange();\n\n const {nativeElement} = this.elementRef;\n\n merge(\n typedFromEvent(this.documentRef, `mouseup`),\n typedFromEvent(nativeElement, `mousedown`).pipe(\n switchMapTo(\n typedFromEvent(nativeElement, `mousemove`).pipe(\n takeUntil(typedFromEvent(this.documentRef, `mouseup`)),\n ),\n ),\n ),\n typedFromEvent(nativeElement, `keyup`),\n )\n .pipe(\n map(() => {\n const active = tuiGetNativeFocused(this.documentRef);\n const selection = this.documentRef.getSelection();\n\n // TODO: iframe warning\n if (\n (active instanceof HTMLInputElement ||\n active instanceof HTMLTextAreaElement) &&\n nativeElement.contains(active)\n ) {\n return this.veryVerySadInputFix(active);\n }\n\n return selection?.rangeCount ? selection.getRangeAt(0) : this.range;\n }),\n takeUntil(destroy$),\n )\n .subscribe(range => {\n const contained =\n !!range && nativeElement.contains(range.commonAncestorContainer);\n\n this.range = contained ? range : this.range;\n\n const valid =\n contained &&\n (!this.visibilityHandler ||\n !this.range ||\n this.visibilityHandler(this.range));\n\n this.toggleDropdownBox(!!range && (valid || this.inDropdown(range)));\n });\n }\n\n get clientRect(): ClientRect {\n const {defaultView} = this.documentRef;\n const {rangeRect} = this;\n const frameElement = defaultView ? defaultView.frameElement : null;\n\n if (!frameElement) {\n return rangeRect;\n }\n\n const documentRect = frameElement.getBoundingClientRect();\n\n return {\n top: rangeRect.top + documentRect.top,\n left: rangeRect.left + documentRect.left,\n right: rangeRect.left + documentRect.left + rangeRect.width,\n bottom: rangeRect.top + documentRect.top + rangeRect.height,\n width: rangeRect.width,\n height: rangeRect.height,\n };\n }\n\n ngOnDestroy(): void {\n this.closeDropdownBox();\n\n if (this.ghost) {\n this.renderer.removeChild(\n this.viewContainerRef.element.nativeElement,\n this.ghost,\n );\n }\n }\n\n /**\n * get ClientRect of current Range according to provided position\n */\n private get rangeRect(): ClientRect {\n if (!this.range) {\n return EMPTY_CLIENT_RECT;\n }\n\n switch (this.position) {\n case `tag`: {\n const {commonAncestorContainer} = this.range;\n const element =\n commonAncestorContainer.nodeType === Node.ELEMENT_NODE\n ? commonAncestorContainer\n : commonAncestorContainer.parentNode;\n\n return (element as Element).getBoundingClientRect();\n }\n case `word`:\n return getWordRange(this.range).getBoundingClientRect();\n default:\n return this.range.getBoundingClientRect();\n }\n }\n\n /**\n * Toggle dropdown visibility (has to be in ngZone.run because it could be initiated inside iframe in Editor)\n */\n private toggleDropdownBox(visible: boolean): void {\n this.ngZone.run(() => {\n if (visible) {\n this.openDropdownBox();\n } else {\n this.closeDropdownBox();\n }\n\n this.changeDetectorRef.markForCheck();\n });\n }\n\n /**\n * Check if Node is inside dropdown\n */\n private boxContains(node: Node): boolean {\n return (\n !!this.dropdownBoxRef &&\n this.dropdownBoxRef.location.nativeElement.contains(node)\n );\n }\n\n /**\n * Check if given range is at least partially inside dropdown\n */\n private inDropdown(range: Range): boolean {\n const {startContainer, endContainer} = range;\n const inDropdown = this.boxContains(range.commonAncestorContainer);\n const hostToDropdown =\n this.boxContains(endContainer) &&\n this.elementRef.nativeElement.contains(startContainer);\n const dropdownToHost =\n this.boxContains(startContainer) &&\n this.elementRef.nativeElement.contains(endContainer);\n\n return inDropdown || hostToDropdown || dropdownToHost;\n }\n\n /**\n * Position invisible DIV and create Range similar to selected range inside input/textarea\n */\n private veryVerySadInputFix(element: HTMLInputElement | HTMLTextAreaElement): Range {\n const {ghost = this.initGhost(element)} = this;\n const {top, left, width, height} = element.getBoundingClientRect();\n const {selectionStart, selectionEnd} = element;\n const range = this.documentRef.createRange();\n const hostRect = this.elementRef.nativeElement.getBoundingClientRect();\n\n ghost.style.top = tuiPx(top - hostRect.top);\n ghost.style.left = tuiPx(left - hostRect.left);\n ghost.style.width = tuiPx(width);\n ghost.style.height = tuiPx(height);\n ghost.textContent = CHAR_ZERO_WIDTH_SPACE + element.value + CHAR_NO_BREAK_SPACE;\n\n range.setStart(ghost.firstChild!, selectionStart || 0);\n range.setEnd(ghost.firstChild!, selectionEnd || 0);\n\n return range;\n }\n\n /**\n * Create an invisible DIV styled exactly like input/textarea element inside directive\n */\n private initGhost(element: HTMLInputElement | HTMLTextAreaElement): HTMLElement {\n const ghost = this.renderer.createElement(`div`);\n const {nativeElement} = this.viewContainerRef.element;\n const {font, letterSpacing, textTransform, padding} = getComputedStyle(element);\n\n ghost.style.position = `absolute`;\n ghost.style.pointerEvents = `none`;\n ghost.style.opacity = `0`;\n ghost.style.whiteSpace = `pre-wrap`;\n ghost.style.font = font;\n ghost.style.letterSpacing = letterSpacing;\n ghost.style.textTransform = textTransform;\n ghost.style.padding = padding;\n\n this.renderer.appendChild(nativeElement, ghost);\n this.ghost = ghost;\n\n return ghost;\n }\n}\n","import {NgModule} from '@angular/core';\nimport {TuiDropdownBoxModule} from '@taiga-ui/core';\n\nimport {TuiDropdownSelectionDirective} from './dropdown-selection.directive';\n\n@NgModule({\n imports: [TuiDropdownBoxModule],\n declarations: [TuiDropdownSelectionDirective],\n exports: [TuiDropdownSelectionDirective],\n})\nexport class TuiDropdownSelectionModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;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