@taiga-ui/addon-doc 3.57.0 → 3.59.0-canary.1c24449

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 (242) hide show
  1. package/components/code/code.component.d.ts +1 -1
  2. package/components/copy/copy.component.d.ts +1 -1
  3. package/components/demo/demo.component.d.ts +3 -3
  4. package/components/doc-tab/doc-tab.component.d.ts +6 -0
  5. package/components/doc-tab/doc-tab.module.d.ts +8 -0
  6. package/components/documentation/documentation-property-connector.directive.d.ts +6 -4
  7. package/components/documentation/documentation.component.d.ts +1 -1
  8. package/components/documentation/documentation.module.d.ts +1 -1
  9. package/components/documentation/pipes/cleaner.pipe.d.ts +1 -1
  10. package/components/documentation/pipes/color.pipe.d.ts +1 -1
  11. package/components/documentation/pipes/inspect.pipe.d.ts +1 -1
  12. package/components/documentation/pipes/opacity.pipe.d.ts +1 -1
  13. package/components/documentation/pipes/optional.pipe.d.ts +1 -1
  14. package/components/documentation/pipes/primitive-polymorpheus-content.pipe.d.ts +1 -1
  15. package/components/documentation/pipes/strip-optional.pipe.d.ts +1 -1
  16. package/components/documentation/pipes/type-reference.pipe.d.ts +1 -1
  17. package/components/example/example-get-tabs.pipe.d.ts +1 -1
  18. package/components/example/example.component.d.ts +1 -1
  19. package/components/index.d.ts +2 -0
  20. package/components/internal/header/header.component.d.ts +1 -1
  21. package/components/internal/input-opacity/input-opacity.directive.d.ts +1 -1
  22. package/components/internal/see-also/see-also.component.d.ts +1 -1
  23. package/components/internal/source-code/source-code.component.d.ts +1 -1
  24. package/components/language-switcher/language-switcher.component.d.ts +3 -3
  25. package/components/main/main.component.d.ts +1 -1
  26. package/components/navigation/navigation.component.d.ts +8 -9
  27. package/components/page/page-tab.directive.d.ts +1 -1
  28. package/components/page/page.component.d.ts +1 -1
  29. package/directives/scroll-into-view/scroll-into-view.directive.d.ts +1 -1
  30. package/directives/text-code/text-code.directive.d.ts +1 -1
  31. package/{esm2015/addon-doc.module.js → esm2020/addon-doc.module.mjs} +4 -4
  32. package/esm2020/components/code/code.component.mjs +43 -0
  33. package/{esm2015/components/code/code.module.js → esm2020/components/code/code.module.mjs} +9 -11
  34. package/esm2020/components/copy/copy.component.mjs +36 -0
  35. package/{esm2015/components/copy/copy.module.js → esm2020/components/copy/copy.module.mjs} +5 -5
  36. package/esm2020/components/demo/demo.component.mjs +179 -0
  37. package/{esm2015/components/demo/demo.module.js → esm2020/components/demo/demo.module.mjs} +23 -25
  38. package/esm2020/components/doc-tab/doc-tab.component.mjs +17 -0
  39. package/esm2020/components/doc-tab/doc-tab.module.mjs +18 -0
  40. package/esm2020/components/documentation/documentation-property-connector.directive.mjs +141 -0
  41. package/esm2020/components/documentation/documentation.component.mjs +110 -0
  42. package/{esm2015/components/documentation/documentation.module.js → esm2020/components/documentation/documentation.module.mjs} +25 -25
  43. package/{esm2015/components/documentation/pipes/cleaner.pipe.js → esm2020/components/documentation/pipes/cleaner.pipe.mjs} +3 -3
  44. package/{esm2015/components/documentation/pipes/color.pipe.js → esm2020/components/documentation/pipes/color.pipe.mjs} +3 -3
  45. package/{esm2015/components/documentation/pipes/inspect.pipe.js → esm2020/components/documentation/pipes/inspect.pipe.mjs} +3 -3
  46. package/{esm2015/components/documentation/pipes/opacity.pipe.js → esm2020/components/documentation/pipes/opacity.pipe.mjs} +3 -3
  47. package/{esm2015/components/documentation/pipes/optional.pipe.js → esm2020/components/documentation/pipes/optional.pipe.mjs} +3 -3
  48. package/{esm2015/components/documentation/pipes/primitive-polymorpheus-content.pipe.js → esm2020/components/documentation/pipes/primitive-polymorpheus-content.pipe.mjs} +3 -3
  49. package/{esm2015/components/documentation/pipes/strip-optional.pipe.js → esm2020/components/documentation/pipes/strip-optional.pipe.mjs} +3 -3
  50. package/esm2020/components/documentation/pipes/type-reference.pipe.mjs +31 -0
  51. package/{esm2015/components/example/example-get-tabs.pipe.js → esm2020/components/example/example-get-tabs.pipe.mjs} +3 -3
  52. package/esm2020/components/example/example.component.mjs +151 -0
  53. package/{esm2015/components/example/example.module.js → esm2020/components/example/example.module.mjs} +13 -15
  54. package/esm2020/components/index.mjs +42 -0
  55. package/esm2020/components/internal/header/header.component.mjs +55 -0
  56. package/{esm2015/components/internal/header/header.module.js → esm2020/components/internal/header/header.module.mjs} +10 -12
  57. package/{esm2015/components/internal/input-opacity/input-opacity.directive.js → esm2020/components/internal/input-opacity/input-opacity.directive.mjs} +8 -8
  58. package/{esm2015/components/internal/input-opacity/input-opacity.module.js → esm2020/components/internal/input-opacity/input-opacity.module.mjs} +4 -4
  59. package/esm2020/components/internal/see-also/see-also.component.mjs +31 -0
  60. package/{esm2015/components/internal/see-also/see-also.module.js → esm2020/components/internal/see-also/see-also.module.mjs} +5 -5
  61. package/{esm2015/components/internal/source-code/source-code.component.js → esm2020/components/internal/source-code/source-code.component.mjs} +7 -11
  62. package/{esm2015/components/internal/source-code/source-code.module.js → esm2020/components/internal/source-code/source-code.module.mjs} +5 -5
  63. package/esm2020/components/language-switcher/language-switcher.component.mjs +61 -0
  64. package/{esm2015/components/language-switcher/language-switcher.module.js → esm2020/components/language-switcher/language-switcher.module.mjs} +9 -11
  65. package/esm2020/components/main/main.component.mjs +59 -0
  66. package/{esm2015/components/main/main.module.js → esm2020/components/main/main.module.mjs} +14 -16
  67. package/esm2020/components/navigation/navigation.component.mjs +214 -0
  68. package/{esm2015/components/navigation/navigation.module.js → esm2020/components/navigation/navigation.module.mjs} +24 -26
  69. package/{esm2015/components/page/page-tab.directive.js → esm2020/components/page/page-tab.directive.mjs} +3 -3
  70. package/esm2020/components/page/page.component.mjs +56 -0
  71. package/{esm2015/components/page/page.module.js → esm2020/components/page/page.module.mjs} +11 -13
  72. package/{esm2015/directives/scroll-into-view/scroll-into-view.directive.js → esm2020/directives/scroll-into-view/scroll-into-view.directive.mjs} +7 -7
  73. package/{esm2015/directives/scroll-into-view/scroll-into-view.module.js → esm2020/directives/scroll-into-view/scroll-into-view.module.mjs} +4 -4
  74. package/{esm2015/directives/text-code/text-code.directive.js → esm2020/directives/text-code/text-code.directive.mjs} +3 -3
  75. package/{esm2015/directives/text-code/text-code.module.js → esm2020/directives/text-code/text-code.module.mjs} +4 -4
  76. package/{esm2015/services/theme-night.service.js → esm2020/services/theme-night.service.mjs} +4 -4
  77. package/{esm2015/services/theme.service.js → esm2020/services/theme.service.mjs} +4 -4
  78. package/esm2020/tokens/pages.mjs +9 -0
  79. package/esm2020/utils/coerce-boolean.mjs +4 -0
  80. package/{esm2015/utils/coerce-value.js → esm2020/utils/coerce-value.mjs} +2 -2
  81. package/esm2020/utils/raw-load-record.mjs +11 -0
  82. package/esm2020/utils/raw-load.mjs +4 -0
  83. package/esm2020/utils/sort-pages.mjs +26 -0
  84. package/esm2020/utils/to-flat-map-pages.mjs +22 -0
  85. package/esm2020/utils/type-reference-parser.mjs +24 -0
  86. package/fesm2015/taiga-ui-addon-doc-components.mjs +1910 -0
  87. package/fesm2015/taiga-ui-addon-doc-components.mjs.map +1 -0
  88. package/fesm2015/taiga-ui-addon-doc-directives.mjs +100 -0
  89. package/fesm2015/taiga-ui-addon-doc-directives.mjs.map +1 -0
  90. package/fesm2015/{taiga-ui-addon-doc-interfaces.js → taiga-ui-addon-doc-interfaces.mjs} +1 -1
  91. package/fesm2015/taiga-ui-addon-doc-interfaces.mjs.map +1 -0
  92. package/fesm2015/{taiga-ui-addon-doc-languages.js → taiga-ui-addon-doc-languages.mjs} +1 -1
  93. package/fesm2015/taiga-ui-addon-doc-languages.mjs.map +1 -0
  94. package/fesm2015/taiga-ui-addon-doc-services.mjs +97 -0
  95. package/fesm2015/taiga-ui-addon-doc-services.mjs.map +1 -0
  96. package/fesm2015/{taiga-ui-addon-doc-tokens.js → taiga-ui-addon-doc-tokens.mjs} +1 -1
  97. package/fesm2015/taiga-ui-addon-doc-tokens.mjs.map +1 -0
  98. package/fesm2015/taiga-ui-addon-doc-types.mjs +4 -0
  99. package/fesm2015/taiga-ui-addon-doc-types.mjs.map +1 -0
  100. package/fesm2015/{taiga-ui-addon-doc-utils.js → taiga-ui-addon-doc-utils.mjs} +7 -6
  101. package/fesm2015/taiga-ui-addon-doc-utils.mjs.map +1 -0
  102. package/fesm2015/{taiga-ui-addon-doc.js → taiga-ui-addon-doc.mjs} +5 -5
  103. package/fesm2015/taiga-ui-addon-doc.mjs.map +1 -0
  104. package/fesm2020/taiga-ui-addon-doc-components.mjs +1880 -0
  105. package/fesm2020/taiga-ui-addon-doc-components.mjs.map +1 -0
  106. package/{fesm2015/taiga-ui-addon-doc-directives.js → fesm2020/taiga-ui-addon-doc-directives.mjs} +18 -18
  107. package/fesm2020/taiga-ui-addon-doc-directives.mjs.map +1 -0
  108. package/fesm2020/taiga-ui-addon-doc-interfaces.mjs +12 -0
  109. package/fesm2020/taiga-ui-addon-doc-interfaces.mjs.map +1 -0
  110. package/fesm2020/taiga-ui-addon-doc-languages.mjs +46 -0
  111. package/fesm2020/taiga-ui-addon-doc-languages.mjs.map +1 -0
  112. package/{fesm2015/taiga-ui-addon-doc-services.js → fesm2020/taiga-ui-addon-doc-services.mjs} +7 -7
  113. package/fesm2020/taiga-ui-addon-doc-services.mjs.map +1 -0
  114. package/fesm2020/taiga-ui-addon-doc-tokens.mjs +149 -0
  115. package/fesm2020/taiga-ui-addon-doc-tokens.mjs.map +1 -0
  116. package/fesm2020/taiga-ui-addon-doc-types.mjs +4 -0
  117. package/fesm2020/taiga-ui-addon-doc-types.mjs.map +1 -0
  118. package/fesm2020/taiga-ui-addon-doc-utils.mjs +275 -0
  119. package/fesm2020/taiga-ui-addon-doc-utils.mjs.map +1 -0
  120. package/fesm2020/taiga-ui-addon-doc.mjs +49 -0
  121. package/fesm2020/taiga-ui-addon-doc.mjs.map +1 -0
  122. package/interfaces/page.d.ts +3 -3
  123. package/package.json +115 -38
  124. package/styles/markdown.less +118 -0
  125. package/tokens/pages.d.ts +4 -2
  126. package/types/pages.d.ts +1 -1
  127. package/utils/type-reference-parser.d.ts +1 -1
  128. package/bundles/taiga-ui-addon-doc-components.umd.js +0 -2500
  129. package/bundles/taiga-ui-addon-doc-components.umd.js.map +0 -1
  130. package/bundles/taiga-ui-addon-doc-directives.umd.js +0 -140
  131. package/bundles/taiga-ui-addon-doc-directives.umd.js.map +0 -1
  132. package/bundles/taiga-ui-addon-doc-interfaces.umd.js +0 -22
  133. package/bundles/taiga-ui-addon-doc-interfaces.umd.js.map +0 -1
  134. package/bundles/taiga-ui-addon-doc-languages.umd.js +0 -54
  135. package/bundles/taiga-ui-addon-doc-languages.umd.js.map +0 -1
  136. package/bundles/taiga-ui-addon-doc-services.umd.js +0 -457
  137. package/bundles/taiga-ui-addon-doc-services.umd.js.map +0 -1
  138. package/bundles/taiga-ui-addon-doc-tokens.umd.js +0 -179
  139. package/bundles/taiga-ui-addon-doc-tokens.umd.js.map +0 -1
  140. package/bundles/taiga-ui-addon-doc-types.umd.js +0 -11
  141. package/bundles/taiga-ui-addon-doc-types.umd.js.map +0 -1
  142. package/bundles/taiga-ui-addon-doc-utils.umd.js +0 -671
  143. package/bundles/taiga-ui-addon-doc-utils.umd.js.map +0 -1
  144. package/bundles/taiga-ui-addon-doc.umd.js +0 -117
  145. package/bundles/taiga-ui-addon-doc.umd.js.map +0 -1
  146. package/components/package.json +0 -10
  147. package/components/taiga-ui-addon-doc-components.d.ts +0 -5
  148. package/directives/package.json +0 -10
  149. package/directives/taiga-ui-addon-doc-directives.d.ts +0 -5
  150. package/esm2015/components/code/code.component.js +0 -48
  151. package/esm2015/components/copy/copy.component.js +0 -42
  152. package/esm2015/components/demo/demo.component.js +0 -183
  153. package/esm2015/components/documentation/documentation-property-connector.directive.js +0 -127
  154. package/esm2015/components/documentation/documentation.component.js +0 -117
  155. package/esm2015/components/documentation/pipes/type-reference.pipe.js +0 -34
  156. package/esm2015/components/example/example.component.js +0 -152
  157. package/esm2015/components/index.js +0 -40
  158. package/esm2015/components/internal/header/header.component.js +0 -60
  159. package/esm2015/components/internal/see-also/see-also.component.js +0 -37
  160. package/esm2015/components/language-switcher/language-switcher.component.js +0 -67
  161. package/esm2015/components/main/main.component.js +0 -68
  162. package/esm2015/components/navigation/navigation.component.js +0 -223
  163. package/esm2015/components/page/page.component.js +0 -62
  164. package/esm2015/tokens/pages.js +0 -9
  165. package/esm2015/utils/coerce-boolean.js +0 -4
  166. package/esm2015/utils/raw-load-record.js +0 -14
  167. package/esm2015/utils/raw-load.js +0 -7
  168. package/esm2015/utils/sort-pages.js +0 -23
  169. package/esm2015/utils/to-flat-map-pages.js +0 -23
  170. package/esm2015/utils/type-reference-parser.js +0 -24
  171. package/fesm2015/taiga-ui-addon-doc-components.js +0 -1928
  172. package/fesm2015/taiga-ui-addon-doc-components.js.map +0 -1
  173. package/fesm2015/taiga-ui-addon-doc-directives.js.map +0 -1
  174. package/fesm2015/taiga-ui-addon-doc-interfaces.js.map +0 -1
  175. package/fesm2015/taiga-ui-addon-doc-languages.js.map +0 -1
  176. package/fesm2015/taiga-ui-addon-doc-services.js.map +0 -1
  177. package/fesm2015/taiga-ui-addon-doc-tokens.js.map +0 -1
  178. package/fesm2015/taiga-ui-addon-doc-types.js +0 -4
  179. package/fesm2015/taiga-ui-addon-doc-types.js.map +0 -1
  180. package/fesm2015/taiga-ui-addon-doc-utils.js.map +0 -1
  181. package/fesm2015/taiga-ui-addon-doc.js.map +0 -1
  182. package/interfaces/package.json +0 -10
  183. package/interfaces/taiga-ui-addon-doc-interfaces.d.ts +0 -5
  184. package/languages/package.json +0 -10
  185. package/languages/taiga-ui-addon-doc-languages.d.ts +0 -5
  186. package/services/package.json +0 -10
  187. package/services/taiga-ui-addon-doc-services.d.ts +0 -5
  188. package/taiga-ui-addon-doc.d.ts +0 -5
  189. package/tokens/package.json +0 -10
  190. package/tokens/taiga-ui-addon-doc-tokens.d.ts +0 -5
  191. package/types/package.json +0 -10
  192. package/types/taiga-ui-addon-doc-types.d.ts +0 -5
  193. package/utils/package.json +0 -10
  194. package/utils/taiga-ui-addon-doc-utils.d.ts +0 -5
  195. /package/{esm2015/components/example/example.options.js → esm2020/components/example/example.options.mjs} +0 -0
  196. /package/{esm2015/components/navigation/navigation.providers.js → esm2020/components/navigation/navigation.providers.mjs} +0 -0
  197. /package/{esm2015/components/page/page.providers.js → esm2020/components/page/page.providers.mjs} +0 -0
  198. /package/{esm2015/components/taiga-ui-addon-doc-components.js → esm2020/components/taiga-ui-addon-doc-components.mjs} +0 -0
  199. /package/{esm2015/directives/index.js → esm2020/directives/index.mjs} +0 -0
  200. /package/{esm2015/directives/taiga-ui-addon-doc-directives.js → esm2020/directives/taiga-ui-addon-doc-directives.mjs} +0 -0
  201. /package/{esm2015/index.js → esm2020/index.mjs} +0 -0
  202. /package/{esm2015/interfaces/code-editor.js → esm2020/interfaces/code-editor.mjs} +0 -0
  203. /package/{esm2015/interfaces/demo-params.js → esm2020/interfaces/demo-params.mjs} +0 -0
  204. /package/{esm2015/interfaces/index.js → esm2020/interfaces/index.mjs} +0 -0
  205. /package/{esm2015/interfaces/page.js → esm2020/interfaces/page.mjs} +0 -0
  206. /package/{esm2015/interfaces/source-code-path-options.js → esm2020/interfaces/source-code-path-options.mjs} +0 -0
  207. /package/{esm2015/interfaces/taiga-ui-addon-doc-interfaces.js → esm2020/interfaces/taiga-ui-addon-doc-interfaces.mjs} +0 -0
  208. /package/{esm2015/languages/index.js → esm2020/languages/index.mjs} +0 -0
  209. /package/{esm2015/languages/russian.js → esm2020/languages/russian.mjs} +0 -0
  210. /package/{esm2015/languages/taiga-ui-addon-doc-languages.js → esm2020/languages/taiga-ui-addon-doc-languages.mjs} +0 -0
  211. /package/{esm2015/services/index.js → esm2020/services/index.mjs} +0 -0
  212. /package/{esm2015/services/taiga-ui-addon-doc-services.js → esm2020/services/taiga-ui-addon-doc-services.mjs} +0 -0
  213. /package/{esm2015/services/theme-night.options.js → esm2020/services/theme-night.options.mjs} +0 -0
  214. /package/{esm2015/services/theme.options.js → esm2020/services/theme.options.mjs} +0 -0
  215. /package/{esm2015/taiga-ui-addon-doc.js → esm2020/taiga-ui-addon-doc.mjs} +0 -0
  216. /package/{esm2015/tokens/code-actions.js → esm2020/tokens/code-actions.mjs} +0 -0
  217. /package/{esm2015/tokens/code-editor.js → esm2020/tokens/code-editor.mjs} +0 -0
  218. /package/{esm2015/tokens/default-tabs.js → esm2020/tokens/default-tabs.mjs} +0 -0
  219. /package/{esm2015/tokens/doc-icons.js → esm2020/tokens/doc-icons.mjs} +0 -0
  220. /package/{esm2015/tokens/example-content-processor.js → esm2020/tokens/example-content-processor.mjs} +0 -0
  221. /package/{esm2015/tokens/excluded-properties.js → esm2020/tokens/excluded-properties.mjs} +0 -0
  222. /package/{esm2015/tokens/i18n.js → esm2020/tokens/i18n.mjs} +0 -0
  223. /package/{esm2015/tokens/index.js → esm2020/tokens/index.mjs} +0 -0
  224. /package/{esm2015/tokens/logo.js → esm2020/tokens/logo.mjs} +0 -0
  225. /package/{esm2015/tokens/page-loaded.js → esm2020/tokens/page-loaded.mjs} +0 -0
  226. /package/{esm2015/tokens/scroll-behavior.js → esm2020/tokens/scroll-behavior.mjs} +0 -0
  227. /package/{esm2015/tokens/see-also.js → esm2020/tokens/see-also.mjs} +0 -0
  228. /package/{esm2015/tokens/source-code.js → esm2020/tokens/source-code.mjs} +0 -0
  229. /package/{esm2015/tokens/taiga-ui-addon-doc-tokens.js → esm2020/tokens/taiga-ui-addon-doc-tokens.mjs} +0 -0
  230. /package/{esm2015/tokens/title.js → esm2020/tokens/title.mjs} +0 -0
  231. /package/{esm2015/tokens/type-reference-handler.js → esm2020/tokens/type-reference-handler.mjs} +0 -0
  232. /package/{esm2015/tokens/url-state-handler.js → esm2020/tokens/url-state-handler.mjs} +0 -0
  233. /package/{esm2015/types/index.js → esm2020/types/index.mjs} +0 -0
  234. /package/{esm2015/types/pages.js → esm2020/types/pages.mjs} +0 -0
  235. /package/{esm2015/types/taiga-ui-addon-doc-types.js → esm2020/types/taiga-ui-addon-doc-types.mjs} +0 -0
  236. /package/{esm2015/utils/generate-routes.js → esm2020/utils/generate-routes.mjs} +0 -0
  237. /package/{esm2015/utils/index.js → esm2020/utils/index.mjs} +0 -0
  238. /package/{esm2015/utils/inspect.js → esm2020/utils/inspect.mjs} +0 -0
  239. /package/{esm2015/utils/is-page-group.js → esm2020/utils/is-page-group.mjs} +0 -0
  240. /package/{esm2015/utils/parse-code-block.js → esm2020/utils/parse-code-block.mjs} +0 -0
  241. /package/{esm2015/utils/taiga-ui-addon-doc-utils.js → esm2020/utils/taiga-ui-addon-doc-utils.mjs} +0 -0
  242. /package/{esm2015/utils/transliterate-keyboard-layout.js → esm2020/utils/transliterate-keyboard-layout.mjs} +0 -0
@@ -0,0 +1,1910 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Component, ChangeDetectionStrategy, Inject, Input, HostBinding, NgModule, ElementRef, forwardRef, TemplateRef, ViewChild, ContentChild, HostListener, EventEmitter, Directive, Output, Pipe, Renderer2, ChangeDetectorRef, Self, ContentChildren, Optional, InjectionToken, ViewEncapsulation } from '@angular/core';
3
+ import { TUI_DOC_EXAMPLE_MARKDOWN_CODE_PROCESSOR, TUI_DOC_DEMO_TEXTS, TUI_DOC_URL_STATE_HANDLER, TUI_DOC_TYPE_REFERENCE_PARSER, TUI_DOC_TYPE_REFERENCE_HANDLER, TUI_DOC_DOCUMENTATION_TEXTS, TUI_DOC_EXCLUDED_PROPERTIES, TUI_DOC_EXAMPLE_TEXTS, TUI_DOC_CODE_EDITOR, TUI_DOC_EXAMPLE_CONTENT_PROCESSOR, TUI_DOC_CODE_ACTIONS, TUI_DOC_TITLE, TUI_DOC_PAGES, TUI_DOC_SEARCH_TEXT, TUI_DOC_PAGE_LOADED, TUI_DOC_ICONS, TUI_DOC_LOGO, TUI_DOC_MENU_TEXT, TUI_DOC_SEE_ALSO_TEXT, TUI_DOC_MAP_PAGES, TUI_DOC_SOURCE_CODE, TUI_DOC_SOURCE_CODE_TEXT, TUI_DOC_SEE_ALSO, TUI_DOC_DEFAULT_TABS } from '@taiga-ui/addon-doc/tokens';
4
+ import { tuiRawLoad, tuiCoerceValueIsTrue, tuiInspectAny, tuiCoerceValue, tuiRawLoadRecord, tuiTransliterateKeyboardLayout } from '@taiga-ui/addon-doc/utils';
5
+ import * as i10 from 'rxjs';
6
+ import { BehaviorSubject, Subject, timer, merge, combineLatest } from 'rxjs';
7
+ import { switchMap, map, startWith, takeUntil, filter, mergeMap, take, distinctUntilChanged, share } from 'rxjs/operators';
8
+ import * as i1 from '@angular/common';
9
+ import { CommonModule, Location as Location$1, DOCUMENT } from '@angular/common';
10
+ import * as i2 from 'ngx-highlightjs';
11
+ import { HighlightModule } from 'ngx-highlightjs';
12
+ import * as i4 from '@taiga-ui/core';
13
+ import { TuiSvgModule, TuiButtonModule, TuiModeDirective, TuiLinkModule, TuiExpandModule, TuiGroupModule, TuiTooltipModule, TuiModeModule, TuiDataListModule, TuiTextfieldControllerModule, TuiHintModule, TuiAlertService, TuiPrimitiveTextfieldModule, TuiDropdownModule, TuiNotificationModule, TuiLoaderModule, TUI_COMMON_ICONS, TuiHostedDropdownModule, TuiScrollbarModule, tuiCapitalizeFirstLetter, TuiFlagPipe, TuiFlagPipeModule, TuiThemeNightModule, TuiRootModule, TuiDialogModule, TuiAlertModule } from '@taiga-ui/core';
14
+ import * as i4$1 from '@angular/cdk/clipboard';
15
+ import { ClipboardModule, Clipboard } from '@angular/cdk/clipboard';
16
+ import { __decorate } from 'tslib';
17
+ import * as i6 from '@taiga-ui/cdk';
18
+ import { ALWAYS_FALSE_HANDLER, TuiDestroyService, tuiPure, tuiToInteger, tuiClamp, tuiPx, tuiCleanObject, TUI_IS_MOBILE, TuiResizeableDirective, TuiResizerModule, tuiIsNumber, tuiRgbToHex, TUI_FOCUSABLE_ITEM_ACCESSOR, TUI_IS_E2E, tuiIsString, EMPTY_QUERY, tuiQueryListChanges, tuiWatch, tuiHexToRgb, TuiFilterPipeModule, tuiCreateToken, tuiProvideOptions, TuiMapperPipeModule, tuiIsPresent, tuiControlValue, tuiUniqBy, TuiSwipeService, TuiActiveZoneModule, TuiLetModule, TuiAutoFocusModule, TuiReplacePipeModule } from '@taiga-ui/cdk';
19
+ import * as i3$1 from '@taiga-ui/kit';
20
+ import { TUI_COPY_TEXTS, TUI_ARROW_OPTIONS, TuiSelectModule, TuiRadioBlockModule, TuiCheckboxLabeledModule, TuiDataListWrapperModule, TuiBadgeModule, TuiToggleModule, TuiInputNumberModule, TuiTabsModule, TuiInputModule, TuiAccordionModule, TuiTagModule } from '@taiga-ui/kit';
21
+ import * as i2$1 from '@angular/forms';
22
+ import { UntypedFormGroup, ReactiveFormsModule, FormsModule, UntypedFormControl } from '@angular/forms';
23
+ import * as i3 from '@angular/router';
24
+ import { UrlSerializer, RouterModule, ActivatedRoute, Router, NavigationEnd, Scroll } from '@angular/router';
25
+ import { trigger, transition, style, animate } from '@angular/animations';
26
+ import { LOCATION } from '@ng-web-apis/common';
27
+ import { TUI_EXAMPLE_PRIMARY_FILE_NAME } from '@taiga-ui/addon-doc/interfaces';
28
+ import * as i1$1 from '@tinkoff/ng-polymorpheus';
29
+ import { PolymorpheusModule } from '@tinkoff/ng-polymorpheus';
30
+ import * as i3$2 from '@taiga-ui/addon-mobile';
31
+ import { TuiSidebarDirective, TuiSidebarModule } from '@taiga-ui/addon-mobile';
32
+ import * as i9 from '@angular/platform-browser';
33
+ import { Title } from '@angular/platform-browser';
34
+ import * as i5 from '@taiga-ui/addon-doc/directives';
35
+ import { TuiScrollIntoViewLinkModule } from '@taiga-ui/addon-doc/directives';
36
+ import * as i5$1 from '@taiga-ui/i18n';
37
+ import { TuiCountryIsoCode, TuiLanguageSwitcher } from '@taiga-ui/i18n';
38
+ import * as i6$1 from '@taiga-ui/addon-doc/services';
39
+ import { TuiThemeService, TuiThemeNightService } from '@taiga-ui/addon-doc/services';
40
+
41
+ class TuiDocCodeComponent {
42
+ constructor(markdownCodeProcessor) {
43
+ this.markdownCodeProcessor = markdownCodeProcessor;
44
+ this.rawLoader$$ = new BehaviorSubject('');
45
+ this.filename = '';
46
+ this.copy$ = new Subject();
47
+ this.icon$ = this.copy$.pipe(switchMap(() => timer(2000).pipe(map(() => 'tuiIconCopyLarge'), startWith('tuiIconCheckLarge'))));
48
+ this.processor$ = this.rawLoader$$.pipe(switchMap(tuiRawLoad), map((value) => this.markdownCodeProcessor(value)));
49
+ }
50
+ set code(code) {
51
+ this.rawLoader$$.next(code);
52
+ }
53
+ get hasFilename() {
54
+ return !!this.filename;
55
+ }
56
+ }
57
+ TuiDocCodeComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeComponent, deps: [{ token: TUI_DOC_EXAMPLE_MARKDOWN_CODE_PROCESSOR }], target: i0.ɵɵFactoryTarget.Component });
58
+ TuiDocCodeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocCodeComponent, selector: "tui-doc-code", inputs: { filename: "filename", code: "code" }, host: { properties: { "class._has-filename": "this.hasFilename" } }, ngImport: i0, template: "<p\n *ngIf=\"filename\"\n class=\"t-header\"\n>\n {{ filename }}\n</p>\n<pre\n *ngFor=\"let content of processor$ | async\"\n class=\"t-code\"\n>\n <code [lineNumbers]=\"true\" [highlight]=\"content\"></code>\n <div class=\"t-code-actions\">\n <button\n tuiIconButton\n appearance=\"icon\"\n size=\"xs\"\n class=\"t-copy-button\"\n [icon]=\"(icon$ | async) || 'tuiIconCopyLarge'\"\n [cdkCopyToClipboard]=\"content\"\n (click)=\"copy$.next()\"\n >\n </button>\n <ng-content></ng-content>\n </div>\n</pre>\n", styles: [":host{display:block}.t-header{font:var(--tui-font-text-s);font-weight:700}.t-header+.t-code{border-radius:.25rem}.t-code{position:relative;margin:0;white-space:normal;outline:1px solid var(--tui-base-03)}.t-code ::ng-deep .hljs-ln{width:-webkit-max-content;width:max-content}.t-code+.t-code{margin-top:1rem}.t-code-actions{position:absolute;top:.75rem;right:.75rem;display:flex;justify-content:center;align-items:center;flex-direction:row-reverse}:host-context(tui-root._mobile) .t-code-actions{padding:.3125rem;border-radius:.25rem;border:1px solid var(--tui-base-04)}.t-copy-button::ng-deep+*:not(:empty){margin-right:.375rem}.hljs:not(:empty){font:var(--tui-font-text-m);font-size:.875rem;padding:1.5rem 2rem;font-family:monospace;word-wrap:break-word;white-space:pre-wrap}@media all and (-webkit-min-device-pixel-ratio: 0) and (-webkit-min-device-pixel-ratio: 0),all and (-webkit-min-device-pixel-ratio: 0) and (min-resolution: .001dpcm){.hljs:not(:empty)::-webkit-scrollbar,.hljs:not(:empty)::-webkit-scrollbar-thumb{width:1rem;height:1rem;border-radius:6.25rem;background-clip:padding-box;border:.375rem solid transparent}.hljs:not(:empty)::-webkit-scrollbar{background-color:transparent}.hljs:not(:empty)::-webkit-scrollbar-thumb{background-color:var(--tui-clear-hover)}.hljs:not(:empty)::-webkit-scrollbar-thumb:hover{background-color:var(--tui-clear-active)}.hljs:not(:empty)::-webkit-scrollbar-thumb:active{background-color:var(--tui-text-03)}}:host-context(tui-root._mobile) .hljs:not(:empty){padding:1rem}.t-code-actions,.hljs:not(:empty){background:var(--tui-base-01)}@supports (background: color-mix(in srgb,var(--tui-base-01),#222 2%)){.t-code-actions,.hljs:not(:empty){background:color-mix(in srgb,var(--tui-base-01),#222 2%)}}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.Highlight, selector: "[highlight]", inputs: ["highlight", "languages", "lineNumbers"], outputs: ["highlighted"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i4$1.CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
59
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeComponent, decorators: [{
60
+ type: Component,
61
+ args: [{ selector: 'tui-doc-code', changeDetection: ChangeDetectionStrategy.OnPush, template: "<p\n *ngIf=\"filename\"\n class=\"t-header\"\n>\n {{ filename }}\n</p>\n<pre\n *ngFor=\"let content of processor$ | async\"\n class=\"t-code\"\n>\n <code [lineNumbers]=\"true\" [highlight]=\"content\"></code>\n <div class=\"t-code-actions\">\n <button\n tuiIconButton\n appearance=\"icon\"\n size=\"xs\"\n class=\"t-copy-button\"\n [icon]=\"(icon$ | async) || 'tuiIconCopyLarge'\"\n [cdkCopyToClipboard]=\"content\"\n (click)=\"copy$.next()\"\n >\n </button>\n <ng-content></ng-content>\n </div>\n</pre>\n", styles: [":host{display:block}.t-header{font:var(--tui-font-text-s);font-weight:700}.t-header+.t-code{border-radius:.25rem}.t-code{position:relative;margin:0;white-space:normal;outline:1px solid var(--tui-base-03)}.t-code ::ng-deep .hljs-ln{width:-webkit-max-content;width:max-content}.t-code+.t-code{margin-top:1rem}.t-code-actions{position:absolute;top:.75rem;right:.75rem;display:flex;justify-content:center;align-items:center;flex-direction:row-reverse}:host-context(tui-root._mobile) .t-code-actions{padding:.3125rem;border-radius:.25rem;border:1px solid var(--tui-base-04)}.t-copy-button::ng-deep+*:not(:empty){margin-right:.375rem}.hljs:not(:empty){font:var(--tui-font-text-m);font-size:.875rem;padding:1.5rem 2rem;font-family:monospace;word-wrap:break-word;white-space:pre-wrap}@media all and (-webkit-min-device-pixel-ratio: 0) and (-webkit-min-device-pixel-ratio: 0),all and (-webkit-min-device-pixel-ratio: 0) and (min-resolution: .001dpcm){.hljs:not(:empty)::-webkit-scrollbar,.hljs:not(:empty)::-webkit-scrollbar-thumb{width:1rem;height:1rem;border-radius:6.25rem;background-clip:padding-box;border:.375rem solid transparent}.hljs:not(:empty)::-webkit-scrollbar{background-color:transparent}.hljs:not(:empty)::-webkit-scrollbar-thumb{background-color:var(--tui-clear-hover)}.hljs:not(:empty)::-webkit-scrollbar-thumb:hover{background-color:var(--tui-clear-active)}.hljs:not(:empty)::-webkit-scrollbar-thumb:active{background-color:var(--tui-text-03)}}:host-context(tui-root._mobile) .hljs:not(:empty){padding:1rem}.t-code-actions,.hljs:not(:empty){background:var(--tui-base-01)}@supports (background: color-mix(in srgb,var(--tui-base-01),#222 2%)){.t-code-actions,.hljs:not(:empty){background:color-mix(in srgb,var(--tui-base-01),#222 2%)}}\n"] }]
62
+ }], ctorParameters: function () {
63
+ return [{ type: undefined, decorators: [{
64
+ type: Inject,
65
+ args: [TUI_DOC_EXAMPLE_MARKDOWN_CODE_PROCESSOR]
66
+ }] }];
67
+ }, propDecorators: { filename: [{
68
+ type: Input
69
+ }], code: [{
70
+ type: Input
71
+ }], hasFilename: [{
72
+ type: HostBinding,
73
+ args: ['class._has-filename']
74
+ }] } });
75
+
76
+ class TuiDocCodeModule {
77
+ }
78
+ TuiDocCodeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
79
+ TuiDocCodeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeModule, declarations: [TuiDocCodeComponent], imports: [CommonModule,
80
+ TuiSvgModule,
81
+ HighlightModule,
82
+ TuiButtonModule,
83
+ ClipboardModule], exports: [TuiDocCodeComponent] });
84
+ TuiDocCodeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeModule, imports: [CommonModule,
85
+ TuiSvgModule,
86
+ HighlightModule,
87
+ TuiButtonModule,
88
+ ClipboardModule] });
89
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCodeModule, decorators: [{
90
+ type: NgModule,
91
+ args: [{
92
+ imports: [
93
+ CommonModule,
94
+ TuiSvgModule,
95
+ HighlightModule,
96
+ TuiButtonModule,
97
+ ClipboardModule,
98
+ ],
99
+ declarations: [TuiDocCodeComponent],
100
+ exports: [TuiDocCodeComponent],
101
+ }]
102
+ }] });
103
+
104
+ const COPIED_TIMEOUT = 1500;
105
+ class TuiDocCopyComponent {
106
+ constructor(texts$) {
107
+ this.texts$ = texts$;
108
+ this.copy$ = new Subject();
109
+ }
110
+ get copied$() {
111
+ return this.copy$.pipe(switchMap(() => timer(COPIED_TIMEOUT).pipe(map(ALWAYS_FALSE_HANDLER), startWith(true))));
112
+ }
113
+ onClick() {
114
+ this.copy$.next();
115
+ }
116
+ }
117
+ TuiDocCopyComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyComponent, deps: [{ token: TUI_COPY_TEXTS }], target: i0.ɵɵFactoryTarget.Component });
118
+ TuiDocCopyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocCopyComponent, selector: "tui-doc-copy", providers: [TuiDestroyService], ngImport: i0, template: "<button\n *ngIf=\"texts$ | async as texts\"\n appearance=\"\"\n size=\"s\"\n tuiButton\n type=\"button\"\n class=\"t-copy\"\n [title]=\"texts[0]\"\n (click)=\"onClick()\"\n>\n <span\n class=\"t-content\"\n [class.t-content_moved]=\"copied$ | async\"\n >\n <span\n class=\"t-initial\"\n [attr.data-text]=\"texts[0]\"\n >\n <ng-content></ng-content>\n </span>\n {{ texts[1] }}\n </span>\n</button>\n", styles: [":host{position:relative;display:inline-block;vertical-align:middle;border-radius:var(--tui-radius-m)}.t-copy{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;width:100%;color:var(--tui-text-01);background:var(--tui-base-01);overflow:hidden}.t-copy:hover{background:var(--tui-base-02)}.t-initial{white-space:nowrap}.t-initial:empty:before{content:attr(data-text)}.t-content{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:flex;flex-direction:column;transform:translateY(1rem);text-align:center;line-height:2rem}.t-content_moved{transform:translateY(-1rem)}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
119
+ __decorate([
120
+ tuiPure
121
+ ], TuiDocCopyComponent.prototype, "copied$", null);
122
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyComponent, decorators: [{
123
+ type: Component,
124
+ args: [{ selector: 'tui-doc-copy', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TuiDestroyService], template: "<button\n *ngIf=\"texts$ | async as texts\"\n appearance=\"\"\n size=\"s\"\n tuiButton\n type=\"button\"\n class=\"t-copy\"\n [title]=\"texts[0]\"\n (click)=\"onClick()\"\n>\n <span\n class=\"t-content\"\n [class.t-content_moved]=\"copied$ | async\"\n >\n <span\n class=\"t-initial\"\n [attr.data-text]=\"texts[0]\"\n >\n <ng-content></ng-content>\n </span>\n {{ texts[1] }}\n </span>\n</button>\n", styles: [":host{position:relative;display:inline-block;vertical-align:middle;border-radius:var(--tui-radius-m)}.t-copy{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;width:100%;color:var(--tui-text-01);background:var(--tui-base-01);overflow:hidden}.t-copy:hover{background:var(--tui-base-02)}.t-initial{white-space:nowrap}.t-initial:empty:before{content:attr(data-text)}.t-content{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:flex;flex-direction:column;transform:translateY(1rem);text-align:center;line-height:2rem}.t-content_moved{transform:translateY(-1rem)}\n"] }]
125
+ }], ctorParameters: function () {
126
+ return [{ type: i10.Observable, decorators: [{
127
+ type: Inject,
128
+ args: [TUI_COPY_TEXTS]
129
+ }] }];
130
+ }, propDecorators: { copied$: [] } });
131
+
132
+ class TuiDocCopyModule {
133
+ }
134
+ TuiDocCopyModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
135
+ TuiDocCopyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyModule, declarations: [TuiDocCopyComponent], imports: [CommonModule, TuiButtonModule], exports: [TuiDocCopyComponent] });
136
+ TuiDocCopyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyModule, imports: [CommonModule, TuiButtonModule] });
137
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocCopyModule, decorators: [{
138
+ type: NgModule,
139
+ args: [{
140
+ imports: [CommonModule, TuiButtonModule],
141
+ declarations: [TuiDocCopyComponent],
142
+ exports: [TuiDocCopyComponent],
143
+ }]
144
+ }] });
145
+
146
+ const MIN_WIDTH = 160;
147
+ class TuiDocDemoComponent {
148
+ constructor(options, isMobile, el, locationRef, urlSerializer, texts, urlStateHandler) {
149
+ var _a, _b;
150
+ this.options = options;
151
+ this.isMobile = isMobile;
152
+ this.el = el;
153
+ this.locationRef = locationRef;
154
+ this.urlSerializer = urlSerializer;
155
+ this.texts = texts;
156
+ this.urlStateHandler = urlStateHandler;
157
+ this.control = null;
158
+ this.sticky = true;
159
+ this.template = null;
160
+ this.updateOnVariants = ['change', 'blur', 'submit'];
161
+ this.updateOn = this.params.updateOn || this.updateOnVariants[0];
162
+ this.opaque = tuiCoerceValueIsTrue((_a = this.params.sandboxOpaque) !== null && _a !== void 0 ? _a : true);
163
+ this.expanded = tuiCoerceValueIsTrue((_b = this.params.sandboxExpanded) !== null && _b !== void 0 ? _b : false);
164
+ this.mode = this.params.tuiMode || null;
165
+ this.sandboxWidth = tuiToInteger(this.params.sandboxWidth);
166
+ this.change$ = new Subject();
167
+ this.items = ['onLight', 'onDark'];
168
+ }
169
+ onResize() {
170
+ this.updateWidth();
171
+ this.onMouseUp();
172
+ }
173
+ onMouseUp() {
174
+ this.updateUrl({ sandboxWidth: this.sandboxWidth });
175
+ }
176
+ ngOnInit() {
177
+ this.createForm();
178
+ this.updateWidth(this.sandboxWidth + this.delta);
179
+ }
180
+ onModeChange(mode) {
181
+ this.mode = mode;
182
+ this.updateUrl({ sandboxWidth: this.sandboxWidth });
183
+ this.change$.next();
184
+ }
185
+ toggleDetails() {
186
+ this.expanded = !this.expanded;
187
+ this.updateUrl({ sandboxExpanded: this.expanded });
188
+ }
189
+ changeOpaque(opaque) {
190
+ this.opaque = opaque;
191
+ this.updateUrl({ sandboxOpaque: this.opaque });
192
+ }
193
+ updateOnChange(updateOn) {
194
+ this.updateOn = updateOn;
195
+ this.updateUrl({ updateOn });
196
+ this.createForm();
197
+ }
198
+ updateWidth(width = NaN) {
199
+ if (!this.resizer || !this.resizeable || !this.content) {
200
+ return;
201
+ }
202
+ const safe = width || this.resizeable.nativeElement.clientWidth;
203
+ const total = this.el.nativeElement.clientWidth;
204
+ const clamped = Math.round(tuiClamp(safe, MIN_WIDTH, total)) - this.delta;
205
+ const validated = safe < total ? clamped : NaN;
206
+ this.resizer.nativeElement.textContent = String(clamped || '-');
207
+ this.resizeable.nativeElement.style.width = validated ? tuiPx(safe) : '';
208
+ this.sandboxWidth = validated;
209
+ }
210
+ get delta() {
211
+ return this.resizeable && this.content
212
+ ? this.resizeable.nativeElement.clientWidth -
213
+ this.content.nativeElement.clientWidth
214
+ : 0;
215
+ }
216
+ updateUrl(params) {
217
+ const tree = this.getUrlTree();
218
+ const { queryParams } = tree;
219
+ delete queryParams.sandboxWidth;
220
+ delete queryParams.tuiMode;
221
+ tree.queryParams = Object.assign(Object.assign({}, queryParams), tuiCleanObject(Object.assign({ tuiMode: this.mode }, params)));
222
+ this.locationRef.go(this.urlStateHandler(tree));
223
+ }
224
+ createForm() {
225
+ const { control, updateOn } = this;
226
+ if (control) {
227
+ this.testForm = new UntypedFormGroup({ testValue: control }, { updateOn });
228
+ }
229
+ }
230
+ getUrlTree() {
231
+ return this.urlSerializer.parse(this.locationRef.path());
232
+ }
233
+ get params() {
234
+ return this.getUrlTree().queryParams;
235
+ }
236
+ }
237
+ TuiDocDemoComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoComponent, deps: [{ token: TUI_ARROW_OPTIONS }, { token: TUI_IS_MOBILE }, { token: ElementRef }, { token: Location$1 }, { token: UrlSerializer }, { token: TUI_DOC_DEMO_TEXTS }, { token: TUI_DOC_URL_STATE_HANDLER }], target: i0.ɵɵFactoryTarget.Component });
238
+ TuiDocDemoComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocDemoComponent, selector: "tui-doc-demo", inputs: { control: "control", sticky: "sticky" }, host: { listeners: { "window:resize": "onResize()", "document:mouseup.silent": "onMouseUp()" }, properties: { "class._sticky": "this.sticky" } }, providers: [
239
+ TuiDestroyService,
240
+ {
241
+ provide: TuiModeDirective,
242
+ useExisting: forwardRef(() => TuiDocDemoComponent),
243
+ },
244
+ ], queries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }], viewQueries: [{ propertyName: "resizeable", first: true, predicate: TuiResizeableDirective, descendants: true, static: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, static: true }, { propertyName: "resizer", first: true, predicate: ["resizer"], descendants: true, static: true }], ngImport: i0, template: "<div\n class=\"t-bg-toggle\"\n [tuiMode]=\"null\"\n>\n <ng-template #tooltip>\n {{ texts[0] }}\n <a\n routerLink=\"/directives/mode\"\n tuiLink\n tuiMode=\"onDark\"\n >\n <code>tuiMode</code>\n </a>\n </ng-template>\n <ng-container *ngIf=\"isMobile; else desktop\">\n <tui-select\n tuiTextfieldSize=\"s\"\n class=\"t-mode\"\n [ngModel]=\"mode\"\n [tuiHintContent]=\"tooltip\"\n [tuiTextfieldCleaner]=\"true\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n tuiMode\n <tui-data-list-wrapper\n *tuiDataList\n [items]=\"items\"\n ></tui-data-list-wrapper>\n </tui-select>\n </ng-container>\n <ng-template #desktop>\n tuiMode:\n <tui-tooltip\n describeId=\"form\"\n [content]=\"tooltip\"\n ></tui-tooltip>\n <div\n tuiGroup\n class=\"t-group\"\n [collapsed]=\"true\"\n >\n <tui-radio-block\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [item]=\"null\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n null\n </tui-radio-block>\n <tui-radio-block\n item=\"onDark\"\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n onDark\n </tui-radio-block>\n <tui-radio-block\n item=\"onLight\"\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n onLight\n </tui-radio-block>\n </div>\n </ng-template>\n <tui-checkbox-labeled\n size=\"m\"\n class=\"t-checkbox\"\n [ngModel]=\"opaque\"\n (ngModelChange)=\"changeOpaque($event)\"\n >\n {{ texts[1] }}\n </tui-checkbox-labeled>\n</div>\n<div\n tuiResizeable\n class=\"t-wrapper\"\n [class.t-wrapper_dark]=\"mode === 'onDark'\"\n [class.t-wrapper_gray]=\"mode === 'onLight'\"\n [class.t-wrapper_transparent]=\"!opaque\"\n>\n <div\n id=\"demo-content\"\n class=\"t-content\"\n >\n <div #content>\n <form\n *ngIf=\"testForm\"\n class=\"t-form\"\n [formGroup]=\"testForm\"\n >\n <div class=\"t-input-wrapper\">\n <ng-container [ngTemplateOutlet]=\"template\"></ng-container>\n </div>\n <button\n automation-id=\"tui-demo-button__toggle-details\"\n size=\"s\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [iconRight]=\"icon\"\n (click)=\"toggleDetails()\"\n >\n {{ texts[2] }}\n </button>\n <ng-template #icon>\n <tui-svg\n class=\"t-icon\"\n [class.t-icon_rotated]=\"expanded\"\n [src]=\"options.iconSmall\"\n ></tui-svg>\n </ng-template>\n <tui-expand\n class=\"t-expand\"\n [expanded]=\"expanded\"\n >\n <ng-template tuiExpandContent>\n <pre class=\"t-value\">Form data: {{ testForm.value | json }}</pre>\n <div\n tuiGroup\n class=\"t-form-controls\"\n >\n <tui-select\n automation-id=\"tui-demo-select__expand-update-on\"\n tuiTextfieldSize=\"s\"\n class=\"t-select\"\n [ngModel]=\"updateOn\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"updateOnChange($event)\"\n >\n updateOn\n <tui-data-list-wrapper\n *tuiDataList\n [items]=\"updateOnVariants\"\n ></tui-data-list-wrapper>\n </tui-select>\n <button\n automation-id=\"tui-demo-button__reset-state\"\n size=\"s\"\n tuiButton\n type=\"reset\"\n class=\"tui-group__auto-width-item\"\n >\n Reset\n </button>\n <button\n automation-id=\"tui-demo-button__submit-state\"\n size=\"s\"\n tuiButton\n type=\"submit\"\n class=\"tui-group__auto-width-item\"\n >\n Submit\n </button>\n </div>\n </ng-template>\n </tui-expand>\n </form>\n <ng-content></ng-content>\n </div>\n </div>\n <div\n #resizer\n class=\"t-resizer\"\n [tuiResizer]=\"[1, 0]\"\n (tuiSizeChange)=\"updateWidth($event[0])\"\n ></div>\n</div>\n", styles: [":host{position:relative;display:block;min-width:100%;margin:1.5rem 0}.t-bg-toggle{position:absolute;bottom:calc(100% + .75rem);display:flex;align-items:center;justify-content:flex-end;pointer-events:none;width:100%}.t-bg-toggle>*{pointer-events:auto}.t-wrapper{box-shadow:var(--tui-shadow-dropdown);display:flex;border:1px solid var(--tui-base-03);border-radius:var(--tui-radius-m);max-width:100%;min-height:6rem;width:100%;min-width:10rem;background-color:var(--tui-base-01);overflow:hidden}.t-wrapper.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-base-02) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-base-02) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-base-02) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-base-02) 75%);background-size:1.25rem 1.25rem;background-position:0 0,0 .625rem,.625rem -.625rem,-.625rem 0}.t-wrapper.t-wrapper_dark{background-color:#454e58;color:var(--tui-base-01)}.t-wrapper.t-wrapper_gray{background-color:#e5e7ea}.t-wrapper.t-wrapper_dark.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-focus) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-focus) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-focus) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-focus) 75%)}.t-wrapper.t-wrapper_gray.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-base-05) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-base-05) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-base-05) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-base-05) 75%)}:host-context(tui-root._mobile) .t-wrapper{min-height:auto}.t-content{flex:1 1 0;min-width:0;padding:1.5rem;box-sizing:border-box;overflow:hidden}:host-context(tui-root._mobile) .t-content{padding:1rem}.t-form{display:flex;flex-wrap:wrap;align-items:flex-start}.t-input-wrapper{width:100%;margin-bottom:.5rem}.t-expand{width:100%}.t-icon{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out}.t-icon_rotated{transform:rotate(180deg)}.t-value{flex:1;background:var(--tui-clear-inverse);padding:.75rem;border-radius:.25rem}.t-mode{width:12.5rem}.t-select{max-width:15rem}.t-resizer{box-shadow:var(--tui-shadow-dropdown);position:relative;width:3.5rem;min-height:inherit;display:flex;align-items:center;justify-content:center;flex-shrink:0;border-left:1px solid var(--tui-base-03);outline:none;background:var(--tui-base-01);color:var(--tui-text-01)}.t-resizer:before,.t-resizer:after{content:\"\";position:absolute;top:.75rem;left:50%;bottom:calc(50% + 1rem);width:1px;background:var(--tui-base-04);box-shadow:-.25rem 0 var(--tui-base-04);transform:translateZ(0)}.t-resizer:after{bottom:.75rem;top:calc(50% + 1rem)}:host-context(tui-root._mobile) .t-resizer{display:none}.t-resizer-text{font:var(--tui-font-text-s);position:relative;z-index:1;padding:.75rem;background:var(--tui-base-01)}.wrapper_light .t-resizer-text{background:#3e464e}.t-group,.t-checkbox{margin-left:.75rem}.t-button,.t-form-controls{margin-top:.75rem}@supports ((position: -webkit-sticky) or (position: sticky)){@media screen and (min-height: 37.5rem){:host._sticky{position:-webkit-sticky;position:sticky;top:4.625rem;z-index:2}}}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i4.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "component", type: i3$1.TuiSelectComponent, selector: "tui-select", inputs: ["stringify", "identityMatcher", "valueContent"] }, { kind: "directive", type: i3$1.TuiSelectDirective, selector: "tui-select" }, { kind: "component", type: i4.TuiExpandComponent, selector: "tui-expand", inputs: ["async", "expanded"] }, { kind: "directive", type: i4.TuiExpandContentDirective, selector: "[tuiExpandContent]" }, { kind: "directive", type: i4.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { kind: "component", type: i4.TuiTooltipComponent, selector: "tui-tooltip", inputs: ["content", "direction", "appearance", "showDelay", "hideDelay", "describeId", "context"] }, { kind: "directive", type: i4.TuiModeDirective, selector: "[tuiMode]", inputs: ["tuiMode"] }, { kind: "component", type: i3$1.TuiRadioBlockComponent, selector: "tui-radio-block", inputs: ["item", "identityMatcher", "contentAlign", "size", "hideRadio", "pseudoDisabled"] }, { kind: "component", type: i3$1.TuiCheckboxLabeledComponent, selector: "tui-checkbox-labeled", inputs: ["size"] }, { kind: "component", type: i4.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { kind: "component", type: i3$1.TuiDataListWrapperComponent, selector: "tui-data-list-wrapper:not([labels])", inputs: ["items"] }, { kind: "directive", type: i4.TuiDataListDirective, selector: "ng-template[tuiDataList]" }, { kind: "directive", type: i4.TuiTextfieldCleanerDirective, selector: "[tuiTextfieldCleaner]", inputs: ["tuiTextfieldCleaner"] }, { kind: "directive", type: i4.TuiTextfieldSizeDirective, selector: "[tuiTextfieldSize]", inputs: ["tuiTextfieldSize"] }, { kind: "directive", type: i4.TuiHintOptionsDirective, selector: "[tuiHintContent]", inputs: ["tuiHintContent", "tuiHintDirection", "tuiHintAppearance", "tuiHintShowDelay", "tuiHintHideDelay"] }, { kind: "directive", type: i6.TuiResizeableDirective, selector: "[tuiResizeable]" }, { kind: "directive", type: i6.TuiResizerDirective, selector: "[tuiResizer]", inputs: ["tuiResizer"], outputs: ["tuiSizeChange"] }, { kind: "pipe", type: i1.JsonPipe, name: "json" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
245
+ __decorate([
246
+ tuiPure
247
+ ], TuiDocDemoComponent.prototype, "updateUrl", null);
248
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoComponent, decorators: [{
249
+ type: Component,
250
+ args: [{ selector: 'tui-doc-demo', changeDetection: ChangeDetectionStrategy.OnPush, providers: [
251
+ TuiDestroyService,
252
+ {
253
+ provide: TuiModeDirective,
254
+ useExisting: forwardRef(() => TuiDocDemoComponent),
255
+ },
256
+ ], template: "<div\n class=\"t-bg-toggle\"\n [tuiMode]=\"null\"\n>\n <ng-template #tooltip>\n {{ texts[0] }}\n <a\n routerLink=\"/directives/mode\"\n tuiLink\n tuiMode=\"onDark\"\n >\n <code>tuiMode</code>\n </a>\n </ng-template>\n <ng-container *ngIf=\"isMobile; else desktop\">\n <tui-select\n tuiTextfieldSize=\"s\"\n class=\"t-mode\"\n [ngModel]=\"mode\"\n [tuiHintContent]=\"tooltip\"\n [tuiTextfieldCleaner]=\"true\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n tuiMode\n <tui-data-list-wrapper\n *tuiDataList\n [items]=\"items\"\n ></tui-data-list-wrapper>\n </tui-select>\n </ng-container>\n <ng-template #desktop>\n tuiMode:\n <tui-tooltip\n describeId=\"form\"\n [content]=\"tooltip\"\n ></tui-tooltip>\n <div\n tuiGroup\n class=\"t-group\"\n [collapsed]=\"true\"\n >\n <tui-radio-block\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [item]=\"null\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n null\n </tui-radio-block>\n <tui-radio-block\n item=\"onDark\"\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n onDark\n </tui-radio-block>\n <tui-radio-block\n item=\"onLight\"\n nativeId=\"form\"\n size=\"s\"\n class=\"tui-group__auto-width-item\"\n [hideRadio]=\"true\"\n [ngModel]=\"mode\"\n (ngModelChange)=\"onModeChange($event)\"\n >\n onLight\n </tui-radio-block>\n </div>\n </ng-template>\n <tui-checkbox-labeled\n size=\"m\"\n class=\"t-checkbox\"\n [ngModel]=\"opaque\"\n (ngModelChange)=\"changeOpaque($event)\"\n >\n {{ texts[1] }}\n </tui-checkbox-labeled>\n</div>\n<div\n tuiResizeable\n class=\"t-wrapper\"\n [class.t-wrapper_dark]=\"mode === 'onDark'\"\n [class.t-wrapper_gray]=\"mode === 'onLight'\"\n [class.t-wrapper_transparent]=\"!opaque\"\n>\n <div\n id=\"demo-content\"\n class=\"t-content\"\n >\n <div #content>\n <form\n *ngIf=\"testForm\"\n class=\"t-form\"\n [formGroup]=\"testForm\"\n >\n <div class=\"t-input-wrapper\">\n <ng-container [ngTemplateOutlet]=\"template\"></ng-container>\n </div>\n <button\n automation-id=\"tui-demo-button__toggle-details\"\n size=\"s\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [iconRight]=\"icon\"\n (click)=\"toggleDetails()\"\n >\n {{ texts[2] }}\n </button>\n <ng-template #icon>\n <tui-svg\n class=\"t-icon\"\n [class.t-icon_rotated]=\"expanded\"\n [src]=\"options.iconSmall\"\n ></tui-svg>\n </ng-template>\n <tui-expand\n class=\"t-expand\"\n [expanded]=\"expanded\"\n >\n <ng-template tuiExpandContent>\n <pre class=\"t-value\">Form data: {{ testForm.value | json }}</pre>\n <div\n tuiGroup\n class=\"t-form-controls\"\n >\n <tui-select\n automation-id=\"tui-demo-select__expand-update-on\"\n tuiTextfieldSize=\"s\"\n class=\"t-select\"\n [ngModel]=\"updateOn\"\n [ngModelOptions]=\"{standalone: true}\"\n (ngModelChange)=\"updateOnChange($event)\"\n >\n updateOn\n <tui-data-list-wrapper\n *tuiDataList\n [items]=\"updateOnVariants\"\n ></tui-data-list-wrapper>\n </tui-select>\n <button\n automation-id=\"tui-demo-button__reset-state\"\n size=\"s\"\n tuiButton\n type=\"reset\"\n class=\"tui-group__auto-width-item\"\n >\n Reset\n </button>\n <button\n automation-id=\"tui-demo-button__submit-state\"\n size=\"s\"\n tuiButton\n type=\"submit\"\n class=\"tui-group__auto-width-item\"\n >\n Submit\n </button>\n </div>\n </ng-template>\n </tui-expand>\n </form>\n <ng-content></ng-content>\n </div>\n </div>\n <div\n #resizer\n class=\"t-resizer\"\n [tuiResizer]=\"[1, 0]\"\n (tuiSizeChange)=\"updateWidth($event[0])\"\n ></div>\n</div>\n", styles: [":host{position:relative;display:block;min-width:100%;margin:1.5rem 0}.t-bg-toggle{position:absolute;bottom:calc(100% + .75rem);display:flex;align-items:center;justify-content:flex-end;pointer-events:none;width:100%}.t-bg-toggle>*{pointer-events:auto}.t-wrapper{box-shadow:var(--tui-shadow-dropdown);display:flex;border:1px solid var(--tui-base-03);border-radius:var(--tui-radius-m);max-width:100%;min-height:6rem;width:100%;min-width:10rem;background-color:var(--tui-base-01);overflow:hidden}.t-wrapper.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-base-02) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-base-02) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-base-02) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-base-02) 75%);background-size:1.25rem 1.25rem;background-position:0 0,0 .625rem,.625rem -.625rem,-.625rem 0}.t-wrapper.t-wrapper_dark{background-color:#454e58;color:var(--tui-base-01)}.t-wrapper.t-wrapper_gray{background-color:#e5e7ea}.t-wrapper.t-wrapper_dark.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-focus) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-focus) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-focus) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-focus) 75%)}.t-wrapper.t-wrapper_gray.t-wrapper_transparent{background-image:linear-gradient(45deg,var(--tui-base-05) 25%,transparent 25%),linear-gradient(-45deg,var(--tui-base-05) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--tui-base-05) 75%),linear-gradient(-45deg,transparent 75%,var(--tui-base-05) 75%)}:host-context(tui-root._mobile) .t-wrapper{min-height:auto}.t-content{flex:1 1 0;min-width:0;padding:1.5rem;box-sizing:border-box;overflow:hidden}:host-context(tui-root._mobile) .t-content{padding:1rem}.t-form{display:flex;flex-wrap:wrap;align-items:flex-start}.t-input-wrapper{width:100%;margin-bottom:.5rem}.t-expand{width:100%}.t-icon{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out}.t-icon_rotated{transform:rotate(180deg)}.t-value{flex:1;background:var(--tui-clear-inverse);padding:.75rem;border-radius:.25rem}.t-mode{width:12.5rem}.t-select{max-width:15rem}.t-resizer{box-shadow:var(--tui-shadow-dropdown);position:relative;width:3.5rem;min-height:inherit;display:flex;align-items:center;justify-content:center;flex-shrink:0;border-left:1px solid var(--tui-base-03);outline:none;background:var(--tui-base-01);color:var(--tui-text-01)}.t-resizer:before,.t-resizer:after{content:\"\";position:absolute;top:.75rem;left:50%;bottom:calc(50% + 1rem);width:1px;background:var(--tui-base-04);box-shadow:-.25rem 0 var(--tui-base-04);transform:translateZ(0)}.t-resizer:after{bottom:.75rem;top:calc(50% + 1rem)}:host-context(tui-root._mobile) .t-resizer{display:none}.t-resizer-text{font:var(--tui-font-text-s);position:relative;z-index:1;padding:.75rem;background:var(--tui-base-01)}.wrapper_light .t-resizer-text{background:#3e464e}.t-group,.t-checkbox{margin-left:.75rem}.t-button,.t-form-controls{margin-top:.75rem}@supports ((position: -webkit-sticky) or (position: sticky)){@media screen and (min-height: 37.5rem){:host._sticky{position:-webkit-sticky;position:sticky;top:4.625rem;z-index:2}}}\n"] }]
257
+ }], ctorParameters: function () {
258
+ return [{ type: undefined, decorators: [{
259
+ type: Inject,
260
+ args: [TUI_ARROW_OPTIONS]
261
+ }] }, { type: undefined, decorators: [{
262
+ type: Inject,
263
+ args: [TUI_IS_MOBILE]
264
+ }] }, { type: i0.ElementRef, decorators: [{
265
+ type: Inject,
266
+ args: [ElementRef]
267
+ }] }, { type: i1.Location, decorators: [{
268
+ type: Inject,
269
+ args: [Location$1]
270
+ }] }, { type: i3.UrlSerializer, decorators: [{
271
+ type: Inject,
272
+ args: [UrlSerializer]
273
+ }] }, { type: undefined, decorators: [{
274
+ type: Inject,
275
+ args: [TUI_DOC_DEMO_TEXTS]
276
+ }] }, { type: undefined, decorators: [{
277
+ type: Inject,
278
+ args: [TUI_DOC_URL_STATE_HANDLER]
279
+ }] }];
280
+ }, propDecorators: { resizeable: [{
281
+ type: ViewChild,
282
+ args: [TuiResizeableDirective, { static: true }]
283
+ }], content: [{
284
+ type: ViewChild,
285
+ args: ['content', { static: true }]
286
+ }], resizer: [{
287
+ type: ViewChild,
288
+ args: ['resizer', { static: true }]
289
+ }], control: [{
290
+ type: Input
291
+ }], sticky: [{
292
+ type: Input
293
+ }, {
294
+ type: HostBinding,
295
+ args: ['class._sticky']
296
+ }], template: [{
297
+ type: ContentChild,
298
+ args: [TemplateRef]
299
+ }], onResize: [{
300
+ type: HostListener,
301
+ args: ['window:resize']
302
+ }], onMouseUp: [{
303
+ type: HostListener,
304
+ args: ['document:mouseup.silent']
305
+ }], updateUrl: [] } });
306
+
307
+ class TuiDocDemoModule {
308
+ }
309
+ TuiDocDemoModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
310
+ TuiDocDemoModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoModule, declarations: [TuiDocDemoComponent], imports: [CommonModule,
311
+ ReactiveFormsModule,
312
+ FormsModule,
313
+ RouterModule,
314
+ TuiLinkModule,
315
+ TuiButtonModule,
316
+ TuiSelectModule,
317
+ TuiExpandModule,
318
+ TuiGroupModule,
319
+ TuiTooltipModule,
320
+ TuiModeModule,
321
+ TuiRadioBlockModule,
322
+ TuiCheckboxLabeledModule,
323
+ TuiSvgModule,
324
+ TuiDataListWrapperModule,
325
+ TuiDataListModule,
326
+ TuiTextfieldControllerModule,
327
+ TuiHintModule,
328
+ TuiResizerModule], exports: [TuiDocDemoComponent] });
329
+ TuiDocDemoModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoModule, imports: [CommonModule,
330
+ ReactiveFormsModule,
331
+ FormsModule,
332
+ RouterModule,
333
+ TuiLinkModule,
334
+ TuiButtonModule,
335
+ TuiSelectModule,
336
+ TuiExpandModule,
337
+ TuiGroupModule,
338
+ TuiTooltipModule,
339
+ TuiModeModule,
340
+ TuiRadioBlockModule,
341
+ TuiCheckboxLabeledModule,
342
+ TuiSvgModule,
343
+ TuiDataListWrapperModule,
344
+ TuiDataListModule,
345
+ TuiTextfieldControllerModule,
346
+ TuiHintModule,
347
+ TuiResizerModule] });
348
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDemoModule, decorators: [{
349
+ type: NgModule,
350
+ args: [{
351
+ imports: [
352
+ CommonModule,
353
+ ReactiveFormsModule,
354
+ FormsModule,
355
+ RouterModule,
356
+ TuiLinkModule,
357
+ TuiButtonModule,
358
+ TuiSelectModule,
359
+ TuiExpandModule,
360
+ TuiGroupModule,
361
+ TuiTooltipModule,
362
+ TuiModeModule,
363
+ TuiRadioBlockModule,
364
+ TuiCheckboxLabeledModule,
365
+ TuiSvgModule,
366
+ TuiDataListWrapperModule,
367
+ TuiDataListModule,
368
+ TuiTextfieldControllerModule,
369
+ TuiHintModule,
370
+ TuiResizerModule,
371
+ ],
372
+ declarations: [TuiDocDemoComponent],
373
+ exports: [TuiDocDemoComponent],
374
+ }]
375
+ }] });
376
+
377
+ class TuiDocTabComponent {
378
+ constructor() {
379
+ this.src = '';
380
+ }
381
+ }
382
+ TuiDocTabComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
383
+ TuiDocTabComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocTabComponent, selector: "tui-doc-tab", inputs: { src: "src" }, ngImport: i0, template: "<div class=\"t-tab\">\n <tui-svg\n class=\"t-icon\"\n [src]=\"src\"\n ></tui-svg>\n <ng-content></ng-content>\n</div>\n", styles: [".t-tab{display:flex;align-items:center;justify-content:center;padding:0 .5rem;gap:.5rem;color:var(--tui-text-01)}.t-tab .t-icon{width:1rem;height:1rem;color:var(--tui-text-01)}\n"], dependencies: [{ kind: "component", type: i4.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
384
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabComponent, decorators: [{
385
+ type: Component,
386
+ args: [{ selector: 'tui-doc-tab', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"t-tab\">\n <tui-svg\n class=\"t-icon\"\n [src]=\"src\"\n ></tui-svg>\n <ng-content></ng-content>\n</div>\n", styles: [".t-tab{display:flex;align-items:center;justify-content:center;padding:0 .5rem;gap:.5rem;color:var(--tui-text-01)}.t-tab .t-icon{width:1rem;height:1rem;color:var(--tui-text-01)}\n"] }]
387
+ }], propDecorators: { src: [{
388
+ type: Input
389
+ }] } });
390
+
391
+ class TuiDocTabModule {
392
+ }
393
+ TuiDocTabModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
394
+ TuiDocTabModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabModule, declarations: [TuiDocTabComponent], imports: [TuiSvgModule], exports: [TuiDocTabComponent] });
395
+ TuiDocTabModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabModule, imports: [TuiSvgModule] });
396
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTabModule, decorators: [{
397
+ type: NgModule,
398
+ args: [{
399
+ imports: [TuiSvgModule],
400
+ declarations: [TuiDocTabComponent],
401
+ exports: [TuiDocTabComponent],
402
+ }]
403
+ }] });
404
+
405
+ const SERIALIZED_SUFFIX = '$';
406
+ // @bad TODO: refactor output and value sync
407
+ class TuiDocDocumentationPropertyConnectorDirective {
408
+ constructor(template, locationRef, activatedRoute, urlSerializer, urlStateHandler, alerts) {
409
+ this.template = template;
410
+ this.locationRef = locationRef;
411
+ this.activatedRoute = activatedRoute;
412
+ this.urlSerializer = urlSerializer;
413
+ this.urlStateHandler = urlStateHandler;
414
+ this.alerts = alerts;
415
+ this.documentationPropertyName = '';
416
+ this.documentationPropertyMode = null;
417
+ this.documentationPropertyType = '';
418
+ this.documentationPropertyDeprecated = false;
419
+ this.documentationPropertyValues = null;
420
+ this.documentationPropertyValueChange = new EventEmitter();
421
+ this.changed$ = new Subject();
422
+ this.emits$ = new BehaviorSubject(1);
423
+ }
424
+ ngOnInit() {
425
+ this.parseParams(this.activatedRoute.snapshot.queryParams);
426
+ }
427
+ get attrName() {
428
+ switch (this.documentationPropertyMode) {
429
+ case 'input':
430
+ return `[${this.documentationPropertyName}]`;
431
+ case 'output':
432
+ return `(${this.documentationPropertyName})`;
433
+ case 'input-output':
434
+ return `[(${this.documentationPropertyName})]`;
435
+ default:
436
+ return this.documentationPropertyName;
437
+ }
438
+ }
439
+ get hasItems() {
440
+ return !!this.documentationPropertyValues;
441
+ }
442
+ get shouldShowValues() {
443
+ return this.documentationPropertyMode !== 'output';
444
+ }
445
+ ngOnChanges() {
446
+ this.changed$.next();
447
+ }
448
+ onValueChange(value) {
449
+ this.documentationPropertyValue = value;
450
+ this.documentationPropertyValueChange.emit(value);
451
+ this.setQueryParam(value);
452
+ }
453
+ emitEvent(event) {
454
+ // For more convenient debugging
455
+ console.info(this.attrName, event);
456
+ this.emits$.next(this.emits$.value + 1);
457
+ let content;
458
+ if (event !== undefined) {
459
+ content = tuiInspectAny(event, 2);
460
+ }
461
+ this.alerts.open(content, { label: this.attrName }).subscribe();
462
+ }
463
+ parseParams(params) {
464
+ const propertyValue = params[this.documentationPropertyName];
465
+ const propertyValueWithSuffix = params[`${this.documentationPropertyName}${SERIALIZED_SUFFIX}`];
466
+ if (!propertyValue && !propertyValueWithSuffix) {
467
+ return;
468
+ }
469
+ let value = !!propertyValueWithSuffix && this.documentationPropertyValues
470
+ ? this.documentationPropertyValues[propertyValueWithSuffix]
471
+ : tuiCoerceValue(propertyValue);
472
+ if (this.documentationPropertyType === 'string' && tuiIsNumber(value)) {
473
+ value = value.toString();
474
+ }
475
+ this.onValueChange(value);
476
+ }
477
+ setQueryParam(value) {
478
+ const tree = this.urlSerializer.parse(this.locationRef.path());
479
+ const isValueAvailableByKey = value instanceof Object;
480
+ const computedValue = isValueAvailableByKey && this.documentationPropertyValues
481
+ ? this.documentationPropertyValues.indexOf(value)
482
+ : value;
483
+ const suffix = isValueAvailableByKey ? SERIALIZED_SUFFIX : '';
484
+ const propName = this.documentationPropertyName + suffix;
485
+ tree.queryParams = Object.assign(Object.assign({}, tree.queryParams), { [propName]: computedValue });
486
+ this.locationRef.go(this.urlStateHandler(tree));
487
+ }
488
+ }
489
+ TuiDocDocumentationPropertyConnectorDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationPropertyConnectorDirective, deps: [{ token: TemplateRef }, { token: Location$1 }, { token: ActivatedRoute }, { token: UrlSerializer }, { token: TUI_DOC_URL_STATE_HANDLER }, { token: TuiAlertService }], target: i0.ɵɵFactoryTarget.Directive });
490
+ TuiDocDocumentationPropertyConnectorDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocDocumentationPropertyConnectorDirective, selector: "ng-template[documentationPropertyName]", inputs: { documentationPropertyName: "documentationPropertyName", documentationPropertyMode: "documentationPropertyMode", documentationPropertyType: "documentationPropertyType", documentationPropertyValue: "documentationPropertyValue", documentationPropertyDeprecated: "documentationPropertyDeprecated", documentationPropertyValues: "documentationPropertyValues" }, outputs: { documentationPropertyValueChange: "documentationPropertyValueChange" }, exportAs: ["documentationProperty"], usesOnChanges: true, ngImport: i0 });
491
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationPropertyConnectorDirective, decorators: [{
492
+ type: Directive,
493
+ args: [{
494
+ selector: 'ng-template[documentationPropertyName]',
495
+ exportAs: 'documentationProperty',
496
+ }]
497
+ }], ctorParameters: function () {
498
+ return [{ type: i0.TemplateRef, decorators: [{
499
+ type: Inject,
500
+ args: [TemplateRef]
501
+ }] }, { type: i1.Location, decorators: [{
502
+ type: Inject,
503
+ args: [Location$1]
504
+ }] }, { type: i3.ActivatedRoute, decorators: [{
505
+ type: Inject,
506
+ args: [ActivatedRoute]
507
+ }] }, { type: i3.UrlSerializer, decorators: [{
508
+ type: Inject,
509
+ args: [UrlSerializer]
510
+ }] }, { type: undefined, decorators: [{
511
+ type: Inject,
512
+ args: [TUI_DOC_URL_STATE_HANDLER]
513
+ }] }, { type: i4.TuiAlertService, decorators: [{
514
+ type: Inject,
515
+ args: [TuiAlertService]
516
+ }] }];
517
+ }, propDecorators: { documentationPropertyName: [{
518
+ type: Input
519
+ }], documentationPropertyMode: [{
520
+ type: Input
521
+ }], documentationPropertyType: [{
522
+ type: Input
523
+ }], documentationPropertyValue: [{
524
+ type: Input
525
+ }], documentationPropertyDeprecated: [{
526
+ type: Input
527
+ }], documentationPropertyValues: [{
528
+ type: Input
529
+ }], documentationPropertyValueChange: [{
530
+ type: Output
531
+ }] } });
532
+
533
+ class TuiGetColorPipe {
534
+ transform(color) {
535
+ if (color.length === 4) {
536
+ return color
537
+ .split(``)
538
+ .reduce((result, current) => [...result, current, current], [])
539
+ .join(``)
540
+ .replace(`#`, ``);
541
+ }
542
+ if (color.startsWith(`#`)) {
543
+ return color;
544
+ }
545
+ if (color === `transparent`) {
546
+ return `#000000`;
547
+ }
548
+ const parsed = color
549
+ .replace(`rgb(`, ``)
550
+ .replace(`rgba(`, ``)
551
+ .replace(`)`, ``)
552
+ .replace(` `, ``)
553
+ .split(`,`)
554
+ .map(v => Number.parseInt(v, 10));
555
+ return tuiRgbToHex(...parsed);
556
+ }
557
+ }
558
+ TuiGetColorPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiGetColorPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
559
+ TuiGetColorPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiGetColorPipe, name: "tuiGetColorPipe" });
560
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiGetColorPipe, decorators: [{
561
+ type: Pipe,
562
+ args: [{ name: `tuiGetColorPipe` }]
563
+ }] });
564
+
565
+ class TuiGetOpacityPipe {
566
+ transform(color) {
567
+ if (color.startsWith(`#`) || color.startsWith(`rgb(`)) {
568
+ return 100;
569
+ }
570
+ if (color === `transparent`) {
571
+ return 0;
572
+ }
573
+ const lastComma = color.lastIndexOf(`,`);
574
+ const parsed = color
575
+ .slice(lastComma)
576
+ .replace(`)`, ``)
577
+ .replace(` `, ``)
578
+ .replace(`,`, ``);
579
+ return Math.round(Number.parseFloat(parsed) * 100);
580
+ }
581
+ }
582
+ TuiGetOpacityPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiGetOpacityPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
583
+ TuiGetOpacityPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiGetOpacityPipe, name: "tuiGetOpacity" });
584
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiGetOpacityPipe, decorators: [{
585
+ type: Pipe,
586
+ args: [{ name: `tuiGetOpacity` }]
587
+ }] });
588
+
589
+ class TuiInputOpacityDirective {
590
+ set tuiInputOpacity(opacity) {
591
+ const { nativeFocusableElement } = this.focusable;
592
+ if (nativeFocusableElement) {
593
+ this.renderer.setStyle(nativeFocusableElement, 'opacity', opacity / 100);
594
+ }
595
+ }
596
+ constructor(renderer, focusable) {
597
+ this.renderer = renderer;
598
+ this.focusable = focusable;
599
+ }
600
+ }
601
+ TuiInputOpacityDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityDirective, deps: [{ token: Renderer2 }, { token: TUI_FOCUSABLE_ITEM_ACCESSOR }], target: i0.ɵɵFactoryTarget.Directive });
602
+ TuiInputOpacityDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: TuiInputOpacityDirective, selector: "[tuiInputOpacity]", inputs: { tuiInputOpacity: "tuiInputOpacity" }, ngImport: i0 });
603
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityDirective, decorators: [{
604
+ type: Directive,
605
+ args: [{
606
+ selector: '[tuiInputOpacity]',
607
+ }]
608
+ }], ctorParameters: function () {
609
+ return [{ type: i0.Renderer2, decorators: [{
610
+ type: Inject,
611
+ args: [Renderer2]
612
+ }] }, { type: undefined, decorators: [{
613
+ type: Inject,
614
+ args: [TUI_FOCUSABLE_ITEM_ACCESSOR]
615
+ }] }];
616
+ }, propDecorators: { tuiInputOpacity: [{
617
+ type: Input
618
+ }] } });
619
+
620
+ class TuiInspectPipe {
621
+ constructor(isE2E) {
622
+ this.isE2E = isE2E;
623
+ }
624
+ transform(value, depth = 2) {
625
+ if (this.isE2E && typeof value === `function`) {
626
+ /**
627
+ * @description:
628
+ * When developing in production mode the webpack bundler minify
629
+ * functions in different ways, then due to which the string content
630
+ * of the function may differ from build to build, which can be to
631
+ * various problems when screenshot testing on e2e.
632
+ */
633
+ return `λ(x) => y`;
634
+ }
635
+ return tuiInspectAny(value, depth);
636
+ }
637
+ }
638
+ TuiInspectPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInspectPipe, deps: [{ token: TUI_IS_E2E }], target: i0.ɵɵFactoryTarget.Pipe });
639
+ TuiInspectPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiInspectPipe, name: "tuiInspectAny" });
640
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInspectPipe, decorators: [{
641
+ type: Pipe,
642
+ args: [{ name: `tuiInspectAny` }]
643
+ }], ctorParameters: function () {
644
+ return [{ type: undefined, decorators: [{
645
+ type: Inject,
646
+ args: [TUI_IS_E2E]
647
+ }] }];
648
+ } });
649
+
650
+ class TuiIsOptionalPipe {
651
+ transform(name) {
652
+ return name.includes(`?`);
653
+ }
654
+ }
655
+ TuiIsOptionalPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiIsOptionalPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
656
+ TuiIsOptionalPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiIsOptionalPipe, name: "tuiIsOptionalPipe" });
657
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiIsOptionalPipe, decorators: [{
658
+ type: Pipe,
659
+ args: [{ name: `tuiIsOptionalPipe` }]
660
+ }] });
661
+
662
+ class TuiShowCleanerPipe {
663
+ transform(type) {
664
+ return type.includes(`null`);
665
+ }
666
+ }
667
+ TuiShowCleanerPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiShowCleanerPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
668
+ TuiShowCleanerPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiShowCleanerPipe, name: "tuiShowCleanerPipe" });
669
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiShowCleanerPipe, decorators: [{
670
+ type: Pipe,
671
+ args: [{ name: `tuiShowCleanerPipe` }]
672
+ }] });
673
+
674
+ class TuiStripOptionalPipe {
675
+ transform(name) {
676
+ return name.replace(`?`, ``);
677
+ }
678
+ }
679
+ TuiStripOptionalPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiStripOptionalPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
680
+ TuiStripOptionalPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiStripOptionalPipe, name: "tuiStripOptionalPipe" });
681
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiStripOptionalPipe, decorators: [{
682
+ type: Pipe,
683
+ args: [{ name: `tuiStripOptionalPipe` }]
684
+ }] });
685
+
686
+ class TuiDocTypeReferencePipe {
687
+ constructor(parser, linkHandler) {
688
+ this.parser = parser;
689
+ this.linkHandler = linkHandler;
690
+ }
691
+ transform(original) {
692
+ return this.parser(original)
693
+ .map(({ type, extracted }) => {
694
+ var _a, _b;
695
+ return ({
696
+ type,
697
+ extracted,
698
+ reference: (_b = (_a = this.linkHandler) === null || _a === void 0 ? void 0 : _a.call(this, extracted)) !== null && _b !== void 0 ? _b : null,
699
+ });
700
+ })
701
+ .sort((a, b) => { var _a, _b, _c; return (_c = (_a = b.reference) === null || _a === void 0 ? void 0 : _a.localeCompare((_b = a.reference) !== null && _b !== void 0 ? _b : ``)) !== null && _c !== void 0 ? _c : -1; });
702
+ }
703
+ }
704
+ TuiDocTypeReferencePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTypeReferencePipe, deps: [{ token: TUI_DOC_TYPE_REFERENCE_PARSER }, { token: TUI_DOC_TYPE_REFERENCE_HANDLER }], target: i0.ɵɵFactoryTarget.Pipe });
705
+ TuiDocTypeReferencePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTypeReferencePipe, name: "tuiDocTypeReference" });
706
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocTypeReferencePipe, decorators: [{
707
+ type: Pipe,
708
+ args: [{ name: `tuiDocTypeReference` }]
709
+ }], ctorParameters: function () {
710
+ return [{ type: undefined, decorators: [{
711
+ type: Inject,
712
+ args: [TUI_DOC_TYPE_REFERENCE_PARSER]
713
+ }] }, { type: undefined, decorators: [{
714
+ type: Inject,
715
+ args: [TUI_DOC_TYPE_REFERENCE_HANDLER]
716
+ }] }];
717
+ } });
718
+
719
+ class TuiIsPrimitivePolymorpheusContentPipe {
720
+ transform(value) {
721
+ return tuiIsString(value) || tuiIsNumber(value);
722
+ }
723
+ }
724
+ TuiIsPrimitivePolymorpheusContentPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiIsPrimitivePolymorpheusContentPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
725
+ TuiIsPrimitivePolymorpheusContentPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiIsPrimitivePolymorpheusContentPipe, name: "tuiIsPrimitivePolymorpheusContentPipe" });
726
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiIsPrimitivePolymorpheusContentPipe, decorators: [{
727
+ type: Pipe,
728
+ args: [{ name: `tuiIsPrimitivePolymorpheusContentPipe` }]
729
+ }] });
730
+
731
+ // @bad TODO subscribe propertiesConnectors changes
732
+ // @bad TODO refactor to make more flexible
733
+ class TuiDocDocumentationComponent {
734
+ constructor(cdr, texts, excludedProperties, destroy$, getColor, getOpacity) {
735
+ this.cdr = cdr;
736
+ this.texts = texts;
737
+ this.excludedProperties = excludedProperties;
738
+ this.destroy$ = destroy$;
739
+ this.getColor = getColor;
740
+ this.getOpacity = getOpacity;
741
+ this.heading = '';
742
+ this.showValues = true;
743
+ this.isAPI = false;
744
+ this.propertiesConnectors = EMPTY_QUERY;
745
+ this.activeItemIndex = 0;
746
+ this.matcher = (item, exclusions) => !exclusions.has(item.documentationPropertyName);
747
+ }
748
+ ngAfterContentInit() {
749
+ tuiQueryListChanges(this.propertiesConnectors)
750
+ .pipe(switchMap(items => merge(...items.map(({ changed$ }) => changed$))), tuiWatch(this.cdr), takeUntil(this.destroy$))
751
+ .subscribe();
752
+ }
753
+ get type() {
754
+ return this.isAPI ? this.texts[0] : this.texts[1];
755
+ }
756
+ onColorChange(connector, color) {
757
+ const opacity = this.getOpacity.transform(connector.documentationPropertyValue || '');
758
+ if (opacity === 100) {
759
+ connector.onValueChange(color);
760
+ return;
761
+ }
762
+ const rgb = tuiHexToRgb(color).join(', ');
763
+ const result = `rgba(${rgb}, ${opacity / 100})`;
764
+ connector.onValueChange(result);
765
+ }
766
+ onOpacityChange(connector, opacity) {
767
+ const hex = this.getColor.transform(connector.documentationPropertyValue || '');
768
+ const rgb = tuiHexToRgb(hex);
769
+ const result = `rgba(${rgb}, ${(opacity || 0) / 100})`;
770
+ connector.onValueChange(result);
771
+ }
772
+ }
773
+ TuiDocDocumentationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationComponent, deps: [{ token: ChangeDetectorRef }, { token: TUI_DOC_DOCUMENTATION_TEXTS }, { token: TUI_DOC_EXCLUDED_PROPERTIES }, { token: TuiDestroyService, self: true }, { token: TuiGetColorPipe }, { token: TuiGetOpacityPipe }], target: i0.ɵɵFactoryTarget.Component });
774
+ TuiDocDocumentationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocDocumentationComponent, selector: "tui-doc-documentation", inputs: { heading: "heading", showValues: "showValues", isAPI: "isAPI" }, providers: [TuiGetColorPipe, TuiGetOpacityPipe, TuiDestroyService], queries: [{ propertyName: "propertiesConnectors", predicate: TuiDocDocumentationPropertyConnectorDirective }], ngImport: i0, template: "<h1\n *ngIf=\"heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h1>\n<ng-content></ng-content>\n<ng-container *ngIf=\"$any(propertiesConnectors) | tuiFilter: matcher : excludedProperties as properties\">\n <table\n *ngIf=\"properties.length\"\n class=\"t-table\"\n >\n <tr class=\"t-row t-row_header\">\n <th class=\"t-th t-cell t-cell_prop\">{{ texts[2] }}</th>\n <th class=\"t-th\">{{ type }}</th>\n <th\n *ngIf=\"showValues && !isAPI\"\n class=\"t-th t-cell t-th_value\"\n >\n {{ texts[3] }}\n </th>\n </tr>\n <tr\n *ngFor=\"let propertyConnector of properties\"\n class=\"t-row\"\n [class.t-deprecated]=\"propertyConnector.documentationPropertyDeprecated\"\n >\n <td class=\"t-cell\">\n <div\n automation-id=\"tui-documentation__property-name\"\n class=\"t-property t-additional-info\"\n >\n <code\n class=\"t-property-code\"\n [style.color]=\"'var(--tui-accent-active)'\"\n >\n {{ propertyConnector.attrName | tuiStripOptionalPipe }}\n </code>\n <tui-badge\n *ngIf=\"propertyConnector.attrName | tuiIsOptionalPipe\"\n size=\"s\"\n status=\"neutral\"\n value=\"Optional\"\n ></tui-badge>\n <tui-badge\n *ngIf=\"propertyConnector.documentationPropertyDeprecated\"\n size=\"s\"\n status=\"error\"\n value=\"Deprecated\"\n ></tui-badge>\n </div>\n <ng-container [ngTemplateOutlet]=\"propertyConnector.template\"></ng-container>\n </td>\n <td class=\"t-cell\">\n <span class=\"type\">\n <code class=\"t-code-type\">\n <ng-container\n *ngFor=\"\n let item of propertyConnector.documentationPropertyType | tuiDocTypeReference;\n let last = last\n \"\n >\n <a\n *ngIf=\"item.reference; else default\"\n target=\"_blank\"\n class=\"t-code-reference\"\n [attr.href]=\"item.reference\"\n >\n {{ item.type }}\n </a>\n <ng-template #default>\n {{ item.type }}\n </ng-template>\n <span *ngIf=\"!last\">&nbsp;|&nbsp;</span>\n </ng-container>\n </code>\n </span>\n </td>\n <td\n *ngIf=\"showValues\"\n class=\"t-cell t-cell_value\"\n >\n <ng-container *ngIf=\"propertyConnector.shouldShowValues; else elseEmitter\">\n <tui-select\n *ngIf=\"propertyConnector.hasItems; else noItems\"\n tuiDropdownLimitWidth=\"min\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [tuiTextfieldCleaner]=\"propertyConnector.documentationPropertyType | tuiShowCleanerPipe\"\n [tuiTextfieldLabelOutside]=\"true\"\n [valueContent]=\"selectContent\"\n (ngModelChange)=\"propertyConnector.onValueChange($event)\"\n >\n <code class=\"t-exception\">null</code>\n <tui-data-list-wrapper\n *tuiDataList\n [itemContent]=\"selectContent\"\n [items]=\"propertyConnector.documentationPropertyValues\"\n ></tui-data-list-wrapper>\n </tui-select>\n <ng-template\n #selectContent\n let-data\n >\n <code>{{ data | tuiInspectAny }}</code>\n </ng-template>\n\n <ng-template #noItems>\n <ng-container [ngSwitch]=\"propertyConnector.documentationPropertyType\">\n <tui-toggle\n *ngSwitchCase=\"'boolean'\"\n size=\"l\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [showIcons]=\"true\"\n (ngModelChange)=\"propertyConnector.onValueChange($event)\"\n ></tui-toggle>\n\n <tui-primitive-textfield\n *ngSwitchCase=\"'string'\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue || ''\"\n (valueChange)=\"propertyConnector.onValueChange($event)\"\n ></tui-primitive-textfield>\n\n <div\n *ngSwitchCase=\"'color'\"\n tuiGroup\n >\n <tui-primitive-textfield\n tuiTextfieldSize=\"m\"\n [attr.id]=\"propertyConnector.attrName\"\n [tuiInputOpacity]=\"propertyConnector.documentationPropertyValue | tuiGetOpacity\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue | tuiGetColorPipe\"\n (valueChange)=\"onColorChange(propertyConnector, $event)\"\n >\n <input\n tuiTextfield\n type=\"text\"\n />\n </tui-primitive-textfield>\n <tui-input-number\n tuiTextfieldSize=\"m\"\n [max]=\"100\"\n [min]=\"0\"\n [ngModel]=\"propertyConnector.documentationPropertyValue | tuiGetOpacity\"\n [step]=\"1\"\n (ngModelChange)=\"onOpacityChange(propertyConnector, $event)\"\n >\n Opacity\n </tui-input-number>\n </div>\n\n <tui-input-number\n *ngSwitchCase=\"'number'\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [step]=\"1\"\n [tuiTextfieldLabelOutside]=\"true\"\n (ngModelChange)=\"propertyConnector.onValueChange($event || 0)\"\n ></tui-input-number>\n\n <ng-container *ngSwitchCase=\"'PolymorpheusContent'\">\n <tui-primitive-textfield\n *ngIf=\"\n propertyConnector.documentationPropertyValue\n | tuiIsPrimitivePolymorpheusContentPipe\n \"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue.toString()\"\n (valueChange)=\"propertyConnector.onValueChange($event)\"\n >\n Default content\n </tui-primitive-textfield>\n </ng-container>\n </ng-container>\n </ng-template>\n </ng-container>\n\n <ng-template #elseEmitter>\n <tui-notification\n class=\"t-output\"\n [@emitEvent]=\"propertyConnector.emits$ | async\"\n >\n Emit!\n </tui-notification>\n </ng-template>\n </td>\n </tr>\n </table>\n</ng-container>\n", styles: [":host{display:block;min-width:100%}.t-table{width:100%;table-layout:fixed}.t-row:not(:last-child){border-bottom:1px solid var(--tui-base-03)}:host-context(tui-root._mobile) .t-row{display:flex;flex-wrap:wrap}:host-context(tui-root._mobile) .t-row_header{display:none}.t-cell{padding:1rem 1rem .875rem}.t-cell:first-child{padding-left:0}.t-cell:last-child{padding-right:0}.t-cell_prop{width:40%}.t-cell_value{text-align:right}:host-context(tui-root._mobile) .t-cell{width:100%;height:auto;padding:.5rem 0;text-align:left}.t-th{padding:.5rem 1rem;color:var(--tui-text-02);font-weight:400;text-align:left}.t-th_value{max-width:20rem;text-align:right}:host-context(tui-root._mobile) .t-th_value{width:9.375rem}.t-property{font:var(--tui-font-text-m);margin-bottom:.25rem;font-family:monospace;color:#8f75d1}:host-context(tui-root._mobile) .t-property{padding:.5rem 0}.t-type{font-family:monospace}.t-deprecated .t-property-code{text-decoration:line-through}.t-deprecated-label{margin-right:.125rem;color:var(--tui-error-fill);font-size:.75rem}.t-additional-info{display:flex;gap:.3125rem;align-items:center}.t-exception{display:block;width:-webkit-max-content;width:max-content}.t-output{text-align:left;opacity:0}.t-heading{font:var(--tui-font-heading-4)}.t-code-type{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-start}.t-code-reference{display:inline-flex;color:var(--tui-link);text-decoration:none;align-items:center;justify-content:center;gap:3px}.t-code-reference:after{content:\"\";font-size:1rem;width:1rem;height:1rem;background:currentColor;-webkit-mask:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1rem\" height=\"1rem\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"></path><polyline points=\"15 3 21 3 21 9\"></polyline><line x1=\"10\" y1=\"14\" x2=\"21\" y2=\"3\"></line></svg>') center / 100%;mask:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1rem\" height=\"1rem\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"></path><polyline points=\"15 3 21 3 21 9\"></polyline><line x1=\"10\" y1=\"14\" x2=\"21\" y2=\"3\"></line></svg>') center / 100%}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3$1.TuiBadgeComponent, selector: "tui-badge", inputs: ["value", "size", "status", "hoverable"] }, { kind: "component", type: i3$1.TuiSelectComponent, selector: "tui-select", inputs: ["stringify", "identityMatcher", "valueContent"] }, { kind: "directive", type: i3$1.TuiSelectDirective, selector: "tui-select" }, { kind: "component", type: i4.TuiTextfieldComponent, selector: "input[tuiTextfield], textarea[tuiTextfield]" }, { kind: "component", type: i3$1.TuiToggleComponent, selector: "tui-toggle", inputs: ["singleColor", "showIcons", "showLoader", "size"] }, { kind: "component", type: i3$1.TuiInputNumberComponent, selector: "tui-input-number", inputs: ["min", "max", "decimal", "precision", "step", "prefix", "postfix"] }, { kind: "directive", type: i3$1.TuiInputNumberDirective, selector: "tui-input-number" }, { kind: "directive", type: i4.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { kind: "directive", type: TuiInputOpacityDirective, selector: "[tuiInputOpacity]", inputs: ["tuiInputOpacity"] }, { kind: "component", type: i4.TuiPrimitiveTextfieldComponent, selector: "tui-primitive-textfield", inputs: ["editable", "filler", "iconCleaner", "readOnly", "invalid", "disabled", "prefix", "postfix", "value"], outputs: ["valueChange"] }, { kind: "directive", type: i4.TuiPrimitiveTextfieldDirective, selector: "tui-primitive-textfield" }, { kind: "directive", type: i4.TuiTextfieldCleanerDirective, selector: "[tuiTextfieldCleaner]", inputs: ["tuiTextfieldCleaner"] }, { kind: "directive", type: i4.TuiTextfieldLabelOutsideDirective, selector: "[tuiTextfieldLabelOutside]", inputs: ["tuiTextfieldLabelOutside"] }, { kind: "directive", type: i4.TuiTextfieldSizeDirective, selector: "[tuiTextfieldSize]", inputs: ["tuiTextfieldSize"] }, { kind: "directive", type: i4.TuiDropdownOptionsDirective, selector: "[tuiDropdownAlign], [tuiDropdownAppearance], [tuiDropdownDirection], [tuiDropdownLimitWidth], [tuiDropdownMinHeight], [tuiDropdownMaxHeight], [tuiDropdownOffset]", inputs: ["tuiDropdownAlign", "tuiDropdownAppearance", "tuiDropdownDirection", "tuiDropdownLimitWidth", "tuiDropdownMinHeight", "tuiDropdownMaxHeight", "tuiDropdownOffset"] }, { kind: "directive", type: i4.TuiDataListDirective, selector: "ng-template[tuiDataList]" }, { kind: "component", type: i3$1.TuiDataListWrapperComponent, selector: "tui-data-list-wrapper:not([labels])", inputs: ["items"] }, { kind: "component", type: i4.TuiNotificationComponent, selector: "tui-notification", inputs: ["hasIcon", "icon", "status", "size", "hideClose"], outputs: ["close"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.TuiFilterPipe, name: "tuiFilter" }, { kind: "pipe", type: TuiInspectPipe, name: "tuiInspectAny" }, { kind: "pipe", type: TuiGetColorPipe, name: "tuiGetColorPipe" }, { kind: "pipe", type: TuiGetOpacityPipe, name: "tuiGetOpacity" }, { kind: "pipe", type: TuiIsOptionalPipe, name: "tuiIsOptionalPipe" }, { kind: "pipe", type: TuiShowCleanerPipe, name: "tuiShowCleanerPipe" }, { kind: "pipe", type: TuiStripOptionalPipe, name: "tuiStripOptionalPipe" }, { kind: "pipe", type: TuiDocTypeReferencePipe, name: "tuiDocTypeReference" }, { kind: "pipe", type: TuiIsPrimitivePolymorpheusContentPipe, name: "tuiIsPrimitivePolymorpheusContentPipe" }], animations: [
775
+ trigger('emitEvent', [
776
+ transition(':increment', [style({ opacity: 1 }), animate('500ms ease-in')]),
777
+ ]),
778
+ ], changeDetection: i0.ChangeDetectionStrategy.OnPush });
779
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationComponent, decorators: [{
780
+ type: Component,
781
+ args: [{ selector: 'tui-doc-documentation', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TuiGetColorPipe, TuiGetOpacityPipe, TuiDestroyService], animations: [
782
+ trigger('emitEvent', [
783
+ transition(':increment', [style({ opacity: 1 }), animate('500ms ease-in')]),
784
+ ]),
785
+ ], template: "<h1\n *ngIf=\"heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h1>\n<ng-content></ng-content>\n<ng-container *ngIf=\"$any(propertiesConnectors) | tuiFilter: matcher : excludedProperties as properties\">\n <table\n *ngIf=\"properties.length\"\n class=\"t-table\"\n >\n <tr class=\"t-row t-row_header\">\n <th class=\"t-th t-cell t-cell_prop\">{{ texts[2] }}</th>\n <th class=\"t-th\">{{ type }}</th>\n <th\n *ngIf=\"showValues && !isAPI\"\n class=\"t-th t-cell t-th_value\"\n >\n {{ texts[3] }}\n </th>\n </tr>\n <tr\n *ngFor=\"let propertyConnector of properties\"\n class=\"t-row\"\n [class.t-deprecated]=\"propertyConnector.documentationPropertyDeprecated\"\n >\n <td class=\"t-cell\">\n <div\n automation-id=\"tui-documentation__property-name\"\n class=\"t-property t-additional-info\"\n >\n <code\n class=\"t-property-code\"\n [style.color]=\"'var(--tui-accent-active)'\"\n >\n {{ propertyConnector.attrName | tuiStripOptionalPipe }}\n </code>\n <tui-badge\n *ngIf=\"propertyConnector.attrName | tuiIsOptionalPipe\"\n size=\"s\"\n status=\"neutral\"\n value=\"Optional\"\n ></tui-badge>\n <tui-badge\n *ngIf=\"propertyConnector.documentationPropertyDeprecated\"\n size=\"s\"\n status=\"error\"\n value=\"Deprecated\"\n ></tui-badge>\n </div>\n <ng-container [ngTemplateOutlet]=\"propertyConnector.template\"></ng-container>\n </td>\n <td class=\"t-cell\">\n <span class=\"type\">\n <code class=\"t-code-type\">\n <ng-container\n *ngFor=\"\n let item of propertyConnector.documentationPropertyType | tuiDocTypeReference;\n let last = last\n \"\n >\n <a\n *ngIf=\"item.reference; else default\"\n target=\"_blank\"\n class=\"t-code-reference\"\n [attr.href]=\"item.reference\"\n >\n {{ item.type }}\n </a>\n <ng-template #default>\n {{ item.type }}\n </ng-template>\n <span *ngIf=\"!last\">&nbsp;|&nbsp;</span>\n </ng-container>\n </code>\n </span>\n </td>\n <td\n *ngIf=\"showValues\"\n class=\"t-cell t-cell_value\"\n >\n <ng-container *ngIf=\"propertyConnector.shouldShowValues; else elseEmitter\">\n <tui-select\n *ngIf=\"propertyConnector.hasItems; else noItems\"\n tuiDropdownLimitWidth=\"min\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [tuiTextfieldCleaner]=\"propertyConnector.documentationPropertyType | tuiShowCleanerPipe\"\n [tuiTextfieldLabelOutside]=\"true\"\n [valueContent]=\"selectContent\"\n (ngModelChange)=\"propertyConnector.onValueChange($event)\"\n >\n <code class=\"t-exception\">null</code>\n <tui-data-list-wrapper\n *tuiDataList\n [itemContent]=\"selectContent\"\n [items]=\"propertyConnector.documentationPropertyValues\"\n ></tui-data-list-wrapper>\n </tui-select>\n <ng-template\n #selectContent\n let-data\n >\n <code>{{ data | tuiInspectAny }}</code>\n </ng-template>\n\n <ng-template #noItems>\n <ng-container [ngSwitch]=\"propertyConnector.documentationPropertyType\">\n <tui-toggle\n *ngSwitchCase=\"'boolean'\"\n size=\"l\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [showIcons]=\"true\"\n (ngModelChange)=\"propertyConnector.onValueChange($event)\"\n ></tui-toggle>\n\n <tui-primitive-textfield\n *ngSwitchCase=\"'string'\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue || ''\"\n (valueChange)=\"propertyConnector.onValueChange($event)\"\n ></tui-primitive-textfield>\n\n <div\n *ngSwitchCase=\"'color'\"\n tuiGroup\n >\n <tui-primitive-textfield\n tuiTextfieldSize=\"m\"\n [attr.id]=\"propertyConnector.attrName\"\n [tuiInputOpacity]=\"propertyConnector.documentationPropertyValue | tuiGetOpacity\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue | tuiGetColorPipe\"\n (valueChange)=\"onColorChange(propertyConnector, $event)\"\n >\n <input\n tuiTextfield\n type=\"text\"\n />\n </tui-primitive-textfield>\n <tui-input-number\n tuiTextfieldSize=\"m\"\n [max]=\"100\"\n [min]=\"0\"\n [ngModel]=\"propertyConnector.documentationPropertyValue | tuiGetOpacity\"\n [step]=\"1\"\n (ngModelChange)=\"onOpacityChange(propertyConnector, $event)\"\n >\n Opacity\n </tui-input-number>\n </div>\n\n <tui-input-number\n *ngSwitchCase=\"'number'\"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [ngModel]=\"propertyConnector.documentationPropertyValue\"\n [step]=\"1\"\n [tuiTextfieldLabelOutside]=\"true\"\n (ngModelChange)=\"propertyConnector.onValueChange($event || 0)\"\n ></tui-input-number>\n\n <ng-container *ngSwitchCase=\"'PolymorpheusContent'\">\n <tui-primitive-textfield\n *ngIf=\"\n propertyConnector.documentationPropertyValue\n | tuiIsPrimitivePolymorpheusContentPipe\n \"\n tuiTextfieldSize=\"m\"\n [nativeId]=\"propertyConnector.attrName\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldLabelOutside]=\"true\"\n [value]=\"propertyConnector.documentationPropertyValue.toString()\"\n (valueChange)=\"propertyConnector.onValueChange($event)\"\n >\n Default content\n </tui-primitive-textfield>\n </ng-container>\n </ng-container>\n </ng-template>\n </ng-container>\n\n <ng-template #elseEmitter>\n <tui-notification\n class=\"t-output\"\n [@emitEvent]=\"propertyConnector.emits$ | async\"\n >\n Emit!\n </tui-notification>\n </ng-template>\n </td>\n </tr>\n </table>\n</ng-container>\n", styles: [":host{display:block;min-width:100%}.t-table{width:100%;table-layout:fixed}.t-row:not(:last-child){border-bottom:1px solid var(--tui-base-03)}:host-context(tui-root._mobile) .t-row{display:flex;flex-wrap:wrap}:host-context(tui-root._mobile) .t-row_header{display:none}.t-cell{padding:1rem 1rem .875rem}.t-cell:first-child{padding-left:0}.t-cell:last-child{padding-right:0}.t-cell_prop{width:40%}.t-cell_value{text-align:right}:host-context(tui-root._mobile) .t-cell{width:100%;height:auto;padding:.5rem 0;text-align:left}.t-th{padding:.5rem 1rem;color:var(--tui-text-02);font-weight:400;text-align:left}.t-th_value{max-width:20rem;text-align:right}:host-context(tui-root._mobile) .t-th_value{width:9.375rem}.t-property{font:var(--tui-font-text-m);margin-bottom:.25rem;font-family:monospace;color:#8f75d1}:host-context(tui-root._mobile) .t-property{padding:.5rem 0}.t-type{font-family:monospace}.t-deprecated .t-property-code{text-decoration:line-through}.t-deprecated-label{margin-right:.125rem;color:var(--tui-error-fill);font-size:.75rem}.t-additional-info{display:flex;gap:.3125rem;align-items:center}.t-exception{display:block;width:-webkit-max-content;width:max-content}.t-output{text-align:left;opacity:0}.t-heading{font:var(--tui-font-heading-4)}.t-code-type{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-start}.t-code-reference{display:inline-flex;color:var(--tui-link);text-decoration:none;align-items:center;justify-content:center;gap:3px}.t-code-reference:after{content:\"\";font-size:1rem;width:1rem;height:1rem;background:currentColor;-webkit-mask:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1rem\" height=\"1rem\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"></path><polyline points=\"15 3 21 3 21 9\"></polyline><line x1=\"10\" y1=\"14\" x2=\"21\" y2=\"3\"></line></svg>') center / 100%;mask:url('data:image/svg+xml,<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1rem\" height=\"1rem\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"></path><polyline points=\"15 3 21 3 21 9\"></polyline><line x1=\"10\" y1=\"14\" x2=\"21\" y2=\"3\"></line></svg>') center / 100%}\n"] }]
786
+ }], ctorParameters: function () {
787
+ return [{ type: i0.ChangeDetectorRef, decorators: [{
788
+ type: Inject,
789
+ args: [ChangeDetectorRef]
790
+ }] }, { type: undefined, decorators: [{
791
+ type: Inject,
792
+ args: [TUI_DOC_DOCUMENTATION_TEXTS]
793
+ }] }, { type: Set, decorators: [{
794
+ type: Inject,
795
+ args: [TUI_DOC_EXCLUDED_PROPERTIES]
796
+ }] }, { type: i6.TuiDestroyService, decorators: [{
797
+ type: Self
798
+ }, {
799
+ type: Inject,
800
+ args: [TuiDestroyService]
801
+ }] }, { type: TuiGetColorPipe, decorators: [{
802
+ type: Inject,
803
+ args: [TuiGetColorPipe]
804
+ }] }, { type: TuiGetOpacityPipe, decorators: [{
805
+ type: Inject,
806
+ args: [TuiGetOpacityPipe]
807
+ }] }];
808
+ }, propDecorators: { heading: [{
809
+ type: Input
810
+ }], showValues: [{
811
+ type: Input
812
+ }], isAPI: [{
813
+ type: Input
814
+ }], propertiesConnectors: [{
815
+ type: ContentChildren,
816
+ args: [TuiDocDocumentationPropertyConnectorDirective]
817
+ }] } });
818
+
819
+ class TuiInputOpacityModule {
820
+ }
821
+ TuiInputOpacityModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
822
+ TuiInputOpacityModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityModule, declarations: [TuiInputOpacityDirective], exports: [TuiInputOpacityDirective] });
823
+ TuiInputOpacityModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityModule });
824
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiInputOpacityModule, decorators: [{
825
+ type: NgModule,
826
+ args: [{
827
+ declarations: [TuiInputOpacityDirective],
828
+ exports: [TuiInputOpacityDirective],
829
+ }]
830
+ }] });
831
+
832
+ class TuiDocDocumentationModule {
833
+ }
834
+ TuiDocDocumentationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
835
+ TuiDocDocumentationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationModule, declarations: [TuiInspectPipe,
836
+ TuiGetColorPipe,
837
+ TuiGetOpacityPipe,
838
+ TuiIsOptionalPipe,
839
+ TuiShowCleanerPipe,
840
+ TuiStripOptionalPipe,
841
+ TuiDocTypeReferencePipe,
842
+ TuiDocDocumentationComponent,
843
+ TuiIsPrimitivePolymorpheusContentPipe,
844
+ TuiDocDocumentationPropertyConnectorDirective], imports: [CommonModule,
845
+ FormsModule,
846
+ RouterModule,
847
+ TuiBadgeModule,
848
+ TuiSelectModule,
849
+ TuiToggleModule,
850
+ TuiLinkModule,
851
+ TuiInputNumberModule,
852
+ TuiModeModule,
853
+ TuiGroupModule,
854
+ TuiInputOpacityModule,
855
+ TuiPrimitiveTextfieldModule,
856
+ TuiTextfieldControllerModule,
857
+ TuiDropdownModule,
858
+ TuiDataListModule,
859
+ TuiDataListWrapperModule,
860
+ TuiNotificationModule,
861
+ TuiFilterPipeModule], exports: [TuiDocTypeReferencePipe,
862
+ TuiDocDocumentationComponent,
863
+ TuiDocDocumentationPropertyConnectorDirective] });
864
+ TuiDocDocumentationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationModule, imports: [CommonModule,
865
+ FormsModule,
866
+ RouterModule,
867
+ TuiBadgeModule,
868
+ TuiSelectModule,
869
+ TuiToggleModule,
870
+ TuiLinkModule,
871
+ TuiInputNumberModule,
872
+ TuiModeModule,
873
+ TuiGroupModule,
874
+ TuiInputOpacityModule,
875
+ TuiPrimitiveTextfieldModule,
876
+ TuiTextfieldControllerModule,
877
+ TuiDropdownModule,
878
+ TuiDataListModule,
879
+ TuiDataListWrapperModule,
880
+ TuiNotificationModule,
881
+ TuiFilterPipeModule] });
882
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocDocumentationModule, decorators: [{
883
+ type: NgModule,
884
+ args: [{
885
+ imports: [
886
+ CommonModule,
887
+ FormsModule,
888
+ RouterModule,
889
+ TuiBadgeModule,
890
+ TuiSelectModule,
891
+ TuiToggleModule,
892
+ TuiLinkModule,
893
+ TuiInputNumberModule,
894
+ TuiModeModule,
895
+ TuiGroupModule,
896
+ TuiInputOpacityModule,
897
+ TuiPrimitiveTextfieldModule,
898
+ TuiTextfieldControllerModule,
899
+ TuiDropdownModule,
900
+ TuiDataListModule,
901
+ TuiDataListWrapperModule,
902
+ TuiNotificationModule,
903
+ TuiFilterPipeModule,
904
+ ],
905
+ declarations: [
906
+ TuiInspectPipe,
907
+ TuiGetColorPipe,
908
+ TuiGetOpacityPipe,
909
+ TuiIsOptionalPipe,
910
+ TuiShowCleanerPipe,
911
+ TuiStripOptionalPipe,
912
+ TuiDocTypeReferencePipe,
913
+ TuiDocDocumentationComponent,
914
+ TuiIsPrimitivePolymorpheusContentPipe,
915
+ TuiDocDocumentationPropertyConnectorDirective,
916
+ ],
917
+ exports: [
918
+ TuiDocTypeReferencePipe,
919
+ TuiDocDocumentationComponent,
920
+ TuiDocDocumentationPropertyConnectorDirective,
921
+ ],
922
+ }]
923
+ }] });
924
+
925
+ const TUI_DOC_EXAMPLE_DEFAULT_OPTIONS = {
926
+ codeEditorVisibilityHandler: files => Boolean(files[TUI_EXAMPLE_PRIMARY_FILE_NAME.TS] &&
927
+ files[TUI_EXAMPLE_PRIMARY_FILE_NAME.HTML]),
928
+ tabTitles: new Map(),
929
+ fullsize: true,
930
+ linkIcon: `tuiIconLink`,
931
+ };
932
+ /**
933
+ * Default parameters for DocExample component
934
+ */
935
+ const TUI_DOC_EXAMPLE_OPTIONS = tuiCreateToken(TUI_DOC_EXAMPLE_DEFAULT_OPTIONS);
936
+ function tuiDocExampleOptionsProvider(options) {
937
+ return tuiProvideOptions(TUI_DOC_EXAMPLE_OPTIONS, options, TUI_DOC_EXAMPLE_DEFAULT_OPTIONS);
938
+ }
939
+
940
+ class TuiDocExampleGetTabsPipe {
941
+ transform(content, defaultTab) {
942
+ return [defaultTab, ...Object.keys(content)];
943
+ }
944
+ }
945
+ TuiDocExampleGetTabsPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleGetTabsPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
946
+ TuiDocExampleGetTabsPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleGetTabsPipe, name: "tuiDocExampleGetTabs" });
947
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleGetTabsPipe, decorators: [{
948
+ type: Pipe,
949
+ args: [{ name: `tuiDocExampleGetTabs` }]
950
+ }] });
951
+
952
+ class TuiDocExampleComponent {
953
+ set content(content) {
954
+ this.rawLoader$$.next(content);
955
+ }
956
+ constructor(clipboard, alerts, location, copyTexts$, texts, codeEditor, processContent, isE2E, codeActions, router, route, ngLocation, options) {
957
+ this.clipboard = clipboard;
958
+ this.alerts = alerts;
959
+ this.location = location;
960
+ this.copyTexts$ = copyTexts$;
961
+ this.texts = texts;
962
+ this.codeEditor = codeEditor;
963
+ this.processContent = processContent;
964
+ this.isE2E = isE2E;
965
+ this.codeActions = codeActions;
966
+ this.router = router;
967
+ this.route = route;
968
+ this.ngLocation = ngLocation;
969
+ this.options = options;
970
+ this.rawLoader$$ = new BehaviorSubject({});
971
+ this.id = null;
972
+ this.fullsize = this.options.fullsize;
973
+ this.componentName = this.location.pathname.slice(1);
974
+ this.defaultTabIndex = 0;
975
+ this.defaultTab = this.texts[this.defaultTabIndex];
976
+ this.activeItemIndex = this.defaultTabIndex;
977
+ this.copy$ = this.copyTexts$.pipe(map(([copy]) => copy));
978
+ this.processor$ = this.rawLoader$$.pipe(switchMap(tuiRawLoadRecord), map(value => this.processContent(value)));
979
+ this.loading$ = new Subject();
980
+ this.visible = (files) => Boolean(this.codeEditor && this.options.codeEditorVisibilityHandler(files));
981
+ }
982
+ getTabTitle(fileName) {
983
+ return this.options.tabTitles.get(fileName) || fileName;
984
+ }
985
+ copyExampleLink() {
986
+ const hashPosition = this.location.href.indexOf('#');
987
+ const currentUrl = hashPosition > -1
988
+ ? this.location.href.slice(0, Math.max(0, hashPosition))
989
+ : this.location.href;
990
+ const url = `${currentUrl}#${this.id}`;
991
+ this.setFragmentWithoutRedirect(this.id);
992
+ this.clipboard.copy(url);
993
+ this.alerts
994
+ .open(this.texts[1], {
995
+ label: this.texts[2],
996
+ status: 'success',
997
+ })
998
+ .subscribe();
999
+ }
1000
+ edit(files) {
1001
+ var _a;
1002
+ this.loading$.next(true);
1003
+ (_a = this.codeEditor) === null || _a === void 0 ? void 0 : _a.edit(this.componentName, this.id || '', files).then(() => this.loading$.next(false)).catch(() => this.loading$.next(false));
1004
+ }
1005
+ setFragmentWithoutRedirect(id) {
1006
+ const url = this.router
1007
+ .createUrlTree([], { relativeTo: this.route, fragment: id || '' })
1008
+ .toString();
1009
+ this.ngLocation.go(url);
1010
+ }
1011
+ }
1012
+ TuiDocExampleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleComponent, deps: [{ token: Clipboard }, { token: TuiAlertService }, { token: LOCATION }, { token: TUI_COPY_TEXTS }, { token: TUI_DOC_EXAMPLE_TEXTS }, { token: TUI_DOC_CODE_EDITOR, optional: true }, { token: TUI_DOC_EXAMPLE_CONTENT_PROCESSOR }, { token: TUI_IS_E2E }, { token: TUI_DOC_CODE_ACTIONS }, { token: Router }, { token: ActivatedRoute }, { token: Location$1 }, { token: TUI_DOC_EXAMPLE_OPTIONS }], target: i0.ɵɵFactoryTarget.Component });
1013
+ TuiDocExampleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocExampleComponent, selector: "tui-doc-example", inputs: { id: "id", heading: "heading", description: "description", content: "content", fullsize: "fullsize", componentName: "componentName" }, host: { properties: { "class._fullsize": "this.fullsize" } }, ngImport: i0, template: "<h3\n *ngIf=\"heading\"\n class=\"t-title\"\n>\n <span\n *polymorpheusOutlet=\"heading as text\"\n [textContent]=\"text\"\n ></span>\n <button\n *ngIf=\"id\"\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-link-icon\"\n [icon]=\"options.linkIcon\"\n [title]=\"copy$ | async\"\n (click)=\"copyExampleLink()\"\n ></button>\n</h3>\n<h4\n *ngIf=\"description\"\n class=\"t-description\"\n>\n <ng-container *polymorpheusOutlet=\"description as text\">\n {{ text }}\n </ng-container>\n</h4>\n\n<div\n *ngIf=\"processor$ | async as files\"\n class=\"t-example\"\n>\n <ng-container *ngIf=\"files | tuiDocExampleGetTabs: defaultTab as tabs\">\n <div\n *ngIf=\"tabs.length > 1\"\n class=\"t-tabs-wrapper\"\n >\n <tui-tabs-with-more\n class=\"t-tabs\"\n [(activeItemIndex)]=\"activeItemIndex\"\n >\n <ng-container *ngFor=\"let tab of tabs\">\n <button\n *tuiItem\n tuiTab\n >\n <ng-container *polymorpheusOutlet=\"getTabTitle(tab) as text\">\n {{ text }}\n </ng-container>\n </button>\n </ng-container>\n </tui-tabs-with-more>\n\n <tui-loader\n *ngIf=\"files | tuiMapper: visible\"\n size=\"xs\"\n [overlay]=\"true\"\n [showLoader]=\"!!(loading$ | async)\"\n (click)=\"edit(files)\"\n >\n <ng-container *ngIf=\"codeEditor?.content as content; else defaultEditContent\">\n <ng-container *polymorpheusOutlet=\"content as editContent\">\n {{ editContent }}\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEditContent>\n <button\n appearance=\"flat\"\n size=\"s\"\n tuiButton\n type=\"button\"\n >\n Edit on {{ codeEditor!.name }}\n </button>\n </ng-template>\n </tui-loader>\n </div>\n\n <div\n *ngFor=\"let tab of tabs; let index = index\"\n class=\"t-content\"\n [class.t-content_animated]=\"!isE2E\"\n [class.t-content_visible]=\"activeItemIndex === index\"\n >\n <ng-container\n *ngIf=\"index === defaultTabIndex; else anotherTab\"\n [ngTemplateOutlet]=\"preview\"\n ></ng-container>\n <ng-template #anotherTab>\n <ng-container\n [ngTemplateOutlet]=\"codeSection\"\n [ngTemplateOutletContext]=\"{$implicit: files?.[tabs[activeItemIndex]] || ''}\"\n ></ng-container>\n </ng-template>\n </div>\n </ng-container>\n</div>\n\n<ng-template #preview>\n <div\n automation-id=\"tui-doc-example\"\n class=\"t-demo\"\n >\n <ng-content></ng-content>\n </div>\n</ng-template>\n\n<ng-template\n #codeSection\n let-code\n>\n <tui-doc-code [code]=\"code\">\n <ng-container *ngFor=\"let action of codeActions\">\n <ng-container *polymorpheusOutlet=\"action as text; context: {$implicit: code}\">\n {{ text }}\n </ng-container>\n </ng-container>\n </tui-doc-code>\n</ng-template>\n", styles: [":host{position:relative;display:block;padding-top:3.5rem;clear:right}:host:target{animation:1s .3s tuiShaking}:host :host-context(tui-root._mobile){padding-top:2rem}.t-title{font:var(--tui-font-heading-5);margin:0 0 .5rem}:host-context(tui-root._mobile) .t-title{font:var(--tui-font-heading-6)}.t-description{font:var(--tui-font-text-m);font-weight:400;margin:0}.t-title:first-letter,.t-description:first-letter{text-transform:capitalize}.t-example{position:relative;margin-top:1.5rem;border:1px solid var(--tui-base-03);border-radius:var(--tui-radius-m);box-shadow:0 .125rem .1875rem #0000001a;overflow:hidden}:host-context(tui-root._mobile) .t-example{margin-top:.75rem}.t-tabs-wrapper{display:flex;padding:0 .875rem 0 2rem;box-shadow:inset 0 -1px var(--tui-base-03);justify-content:space-between;align-items:center}:host-context(tui-root._mobile) .t-tabs-wrapper{padding:0 .875rem 0 1rem}.t-tabs{flex-grow:1}.t-demo{padding:2rem;max-width:100%;box-sizing:border-box;overflow-x:auto}@media all and (-webkit-min-device-pixel-ratio: 0) and (-webkit-min-device-pixel-ratio: 0),all and (-webkit-min-device-pixel-ratio: 0) and (min-resolution: .001dpcm){.t-demo::-webkit-scrollbar,.t-demo::-webkit-scrollbar-thumb{width:1rem;height:1rem;border-radius:6.25rem;background-clip:padding-box;border:.375rem solid transparent}.t-demo::-webkit-scrollbar{background-color:transparent}.t-demo::-webkit-scrollbar-thumb{background-color:var(--tui-clear-hover)}.t-demo::-webkit-scrollbar-thumb:hover{background-color:var(--tui-clear-active)}.t-demo::-webkit-scrollbar-thumb:active{background-color:var(--tui-text-03)}}:host-context(tui-root._mobile) .t-demo{padding:1rem}:host:not(._fullsize) .t-demo{width:-webkit-min-content;width:min-content;min-width:20rem}.t-link-icon{margin-left:.3rem;vertical-align:baseline}.t-content{will-change:opacity;height:0;visibility:hidden;opacity:0}.t-content_animated{transition:opacity .3s ease-in-out}.t-content_visible{height:auto;visibility:visible;opacity:1}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i3$1.TuiTabsWithMoreComponent, selector: "tui-tabs-with-more, nav[tuiTabsWithMore]", inputs: ["moreContent", "dropdownContent", "underline", "activeItemIndex", "itemsLimit"], outputs: ["activeItemIndexChange"] }, { kind: "component", type: i3$1.TuiTabComponent, selector: "a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]" }, { kind: "directive", type: i6.TuiItemDirective, selector: "[tuiItem]" }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "component", type: TuiDocCodeComponent, selector: "tui-doc-code", inputs: ["filename", "code"] }, { kind: "directive", type: i1$1.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i4.TuiLoaderComponent, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "showLoader"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.TuiMapperPipe, name: "tuiMapper" }, { kind: "pipe", type: TuiDocExampleGetTabsPipe, name: "tuiDocExampleGetTabs" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1014
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleComponent, decorators: [{
1015
+ type: Component,
1016
+ args: [{ selector: 'tui-doc-example', changeDetection: ChangeDetectionStrategy.OnPush, template: "<h3\n *ngIf=\"heading\"\n class=\"t-title\"\n>\n <span\n *polymorpheusOutlet=\"heading as text\"\n [textContent]=\"text\"\n ></span>\n <button\n *ngIf=\"id\"\n appearance=\"icon\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-link-icon\"\n [icon]=\"options.linkIcon\"\n [title]=\"copy$ | async\"\n (click)=\"copyExampleLink()\"\n ></button>\n</h3>\n<h4\n *ngIf=\"description\"\n class=\"t-description\"\n>\n <ng-container *polymorpheusOutlet=\"description as text\">\n {{ text }}\n </ng-container>\n</h4>\n\n<div\n *ngIf=\"processor$ | async as files\"\n class=\"t-example\"\n>\n <ng-container *ngIf=\"files | tuiDocExampleGetTabs: defaultTab as tabs\">\n <div\n *ngIf=\"tabs.length > 1\"\n class=\"t-tabs-wrapper\"\n >\n <tui-tabs-with-more\n class=\"t-tabs\"\n [(activeItemIndex)]=\"activeItemIndex\"\n >\n <ng-container *ngFor=\"let tab of tabs\">\n <button\n *tuiItem\n tuiTab\n >\n <ng-container *polymorpheusOutlet=\"getTabTitle(tab) as text\">\n {{ text }}\n </ng-container>\n </button>\n </ng-container>\n </tui-tabs-with-more>\n\n <tui-loader\n *ngIf=\"files | tuiMapper: visible\"\n size=\"xs\"\n [overlay]=\"true\"\n [showLoader]=\"!!(loading$ | async)\"\n (click)=\"edit(files)\"\n >\n <ng-container *ngIf=\"codeEditor?.content as content; else defaultEditContent\">\n <ng-container *polymorpheusOutlet=\"content as editContent\">\n {{ editContent }}\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEditContent>\n <button\n appearance=\"flat\"\n size=\"s\"\n tuiButton\n type=\"button\"\n >\n Edit on {{ codeEditor!.name }}\n </button>\n </ng-template>\n </tui-loader>\n </div>\n\n <div\n *ngFor=\"let tab of tabs; let index = index\"\n class=\"t-content\"\n [class.t-content_animated]=\"!isE2E\"\n [class.t-content_visible]=\"activeItemIndex === index\"\n >\n <ng-container\n *ngIf=\"index === defaultTabIndex; else anotherTab\"\n [ngTemplateOutlet]=\"preview\"\n ></ng-container>\n <ng-template #anotherTab>\n <ng-container\n [ngTemplateOutlet]=\"codeSection\"\n [ngTemplateOutletContext]=\"{$implicit: files?.[tabs[activeItemIndex]] || ''}\"\n ></ng-container>\n </ng-template>\n </div>\n </ng-container>\n</div>\n\n<ng-template #preview>\n <div\n automation-id=\"tui-doc-example\"\n class=\"t-demo\"\n >\n <ng-content></ng-content>\n </div>\n</ng-template>\n\n<ng-template\n #codeSection\n let-code\n>\n <tui-doc-code [code]=\"code\">\n <ng-container *ngFor=\"let action of codeActions\">\n <ng-container *polymorpheusOutlet=\"action as text; context: {$implicit: code}\">\n {{ text }}\n </ng-container>\n </ng-container>\n </tui-doc-code>\n</ng-template>\n", styles: [":host{position:relative;display:block;padding-top:3.5rem;clear:right}:host:target{animation:1s .3s tuiShaking}:host :host-context(tui-root._mobile){padding-top:2rem}.t-title{font:var(--tui-font-heading-5);margin:0 0 .5rem}:host-context(tui-root._mobile) .t-title{font:var(--tui-font-heading-6)}.t-description{font:var(--tui-font-text-m);font-weight:400;margin:0}.t-title:first-letter,.t-description:first-letter{text-transform:capitalize}.t-example{position:relative;margin-top:1.5rem;border:1px solid var(--tui-base-03);border-radius:var(--tui-radius-m);box-shadow:0 .125rem .1875rem #0000001a;overflow:hidden}:host-context(tui-root._mobile) .t-example{margin-top:.75rem}.t-tabs-wrapper{display:flex;padding:0 .875rem 0 2rem;box-shadow:inset 0 -1px var(--tui-base-03);justify-content:space-between;align-items:center}:host-context(tui-root._mobile) .t-tabs-wrapper{padding:0 .875rem 0 1rem}.t-tabs{flex-grow:1}.t-demo{padding:2rem;max-width:100%;box-sizing:border-box;overflow-x:auto}@media all and (-webkit-min-device-pixel-ratio: 0) and (-webkit-min-device-pixel-ratio: 0),all and (-webkit-min-device-pixel-ratio: 0) and (min-resolution: .001dpcm){.t-demo::-webkit-scrollbar,.t-demo::-webkit-scrollbar-thumb{width:1rem;height:1rem;border-radius:6.25rem;background-clip:padding-box;border:.375rem solid transparent}.t-demo::-webkit-scrollbar{background-color:transparent}.t-demo::-webkit-scrollbar-thumb{background-color:var(--tui-clear-hover)}.t-demo::-webkit-scrollbar-thumb:hover{background-color:var(--tui-clear-active)}.t-demo::-webkit-scrollbar-thumb:active{background-color:var(--tui-text-03)}}:host-context(tui-root._mobile) .t-demo{padding:1rem}:host:not(._fullsize) .t-demo{width:-webkit-min-content;width:min-content;min-width:20rem}.t-link-icon{margin-left:.3rem;vertical-align:baseline}.t-content{will-change:opacity;height:0;visibility:hidden;opacity:0}.t-content_animated{transition:opacity .3s ease-in-out}.t-content_visible{height:auto;visibility:visible;opacity:1}\n"] }]
1017
+ }], ctorParameters: function () {
1018
+ return [{ type: i4$1.Clipboard, decorators: [{
1019
+ type: Inject,
1020
+ args: [Clipboard]
1021
+ }] }, { type: i4.TuiAlertService, decorators: [{
1022
+ type: Inject,
1023
+ args: [TuiAlertService]
1024
+ }] }, { type: Location, decorators: [{
1025
+ type: Inject,
1026
+ args: [LOCATION]
1027
+ }] }, { type: i10.Observable, decorators: [{
1028
+ type: Inject,
1029
+ args: [TUI_COPY_TEXTS]
1030
+ }] }, { type: undefined, decorators: [{
1031
+ type: Inject,
1032
+ args: [TUI_DOC_EXAMPLE_TEXTS]
1033
+ }] }, { type: undefined, decorators: [{
1034
+ type: Optional
1035
+ }, {
1036
+ type: Inject,
1037
+ args: [TUI_DOC_CODE_EDITOR]
1038
+ }] }, { type: undefined, decorators: [{
1039
+ type: Inject,
1040
+ args: [TUI_DOC_EXAMPLE_CONTENT_PROCESSOR]
1041
+ }] }, { type: undefined, decorators: [{
1042
+ type: Inject,
1043
+ args: [TUI_IS_E2E]
1044
+ }] }, { type: Array, decorators: [{
1045
+ type: Inject,
1046
+ args: [TUI_DOC_CODE_ACTIONS]
1047
+ }] }, { type: i3.Router, decorators: [{
1048
+ type: Inject,
1049
+ args: [Router]
1050
+ }] }, { type: i3.ActivatedRoute, decorators: [{
1051
+ type: Inject,
1052
+ args: [ActivatedRoute]
1053
+ }] }, { type: i1.Location, decorators: [{
1054
+ type: Inject,
1055
+ args: [Location$1]
1056
+ }] }, { type: undefined, decorators: [{
1057
+ type: Inject,
1058
+ args: [TUI_DOC_EXAMPLE_OPTIONS]
1059
+ }] }];
1060
+ }, propDecorators: { id: [{
1061
+ type: Input
1062
+ }], heading: [{
1063
+ type: Input
1064
+ }], description: [{
1065
+ type: Input
1066
+ }], content: [{
1067
+ type: Input
1068
+ }], fullsize: [{
1069
+ type: Input
1070
+ }, {
1071
+ type: HostBinding,
1072
+ args: ['class._fullsize']
1073
+ }], componentName: [{
1074
+ type: Input
1075
+ }] } });
1076
+
1077
+ class TuiDocExampleModule {
1078
+ }
1079
+ TuiDocExampleModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1080
+ TuiDocExampleModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleModule, declarations: [TuiDocExampleComponent, TuiDocExampleGetTabsPipe], imports: [CommonModule,
1081
+ ClipboardModule,
1082
+ TuiTabsModule,
1083
+ TuiButtonModule,
1084
+ TuiDocCopyModule,
1085
+ TuiDocCodeModule,
1086
+ PolymorpheusModule,
1087
+ TuiMapperPipeModule,
1088
+ TuiLoaderModule], exports: [TuiDocExampleComponent, TuiDocExampleGetTabsPipe] });
1089
+ TuiDocExampleModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleModule, imports: [CommonModule,
1090
+ ClipboardModule,
1091
+ TuiTabsModule,
1092
+ TuiButtonModule,
1093
+ TuiDocCopyModule,
1094
+ TuiDocCodeModule,
1095
+ PolymorpheusModule,
1096
+ TuiMapperPipeModule,
1097
+ TuiLoaderModule] });
1098
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocExampleModule, decorators: [{
1099
+ type: NgModule,
1100
+ args: [{
1101
+ imports: [
1102
+ CommonModule,
1103
+ ClipboardModule,
1104
+ TuiTabsModule,
1105
+ TuiButtonModule,
1106
+ TuiDocCopyModule,
1107
+ TuiDocCodeModule,
1108
+ PolymorpheusModule,
1109
+ TuiMapperPipeModule,
1110
+ TuiLoaderModule,
1111
+ ],
1112
+ declarations: [TuiDocExampleComponent, TuiDocExampleGetTabsPipe],
1113
+ exports: [TuiDocExampleComponent, TuiDocExampleGetTabsPipe],
1114
+ }]
1115
+ }] });
1116
+
1117
+ function labelsProviderFactory(pages) {
1118
+ return pages
1119
+ .map(({ section }) => section)
1120
+ .filter(tuiIsPresent)
1121
+ .filter((item, index, array) => array.indexOf(item) === index);
1122
+ }
1123
+ /**
1124
+ * Page title
1125
+ */
1126
+ const NAVIGATION_TITLE = new InjectionToken(`[NAVIGATION_TITLE]`);
1127
+ /**
1128
+ * Navigation sections labels for search
1129
+ */
1130
+ const NAVIGATION_LABELS = new InjectionToken(`[NAVIGATION_LABELS]`);
1131
+ /**
1132
+ * Navigation pages
1133
+ */
1134
+ const NAVIGATION_ITEMS = new InjectionToken(`[NAVIGATION_ITEMS]`);
1135
+ const NAVIGATION_PROVIDERS = [
1136
+ TuiDestroyService,
1137
+ {
1138
+ provide: NAVIGATION_TITLE,
1139
+ deps: [Router, ActivatedRoute, TUI_DOC_TITLE, TuiDestroyService],
1140
+ useFactory: (router, activatedRoute, titlePrefix, destroy$) => router.events.pipe(filter(event => event instanceof NavigationEnd), map(() => activatedRoute.firstChild), filter(tuiIsPresent), mergeMap(({ data }) => data), map(({ title }) => `${titlePrefix}${title}`), takeUntil(destroy$)),
1141
+ },
1142
+ {
1143
+ provide: NAVIGATION_LABELS,
1144
+ deps: [TUI_DOC_PAGES],
1145
+ useFactory: labelsProviderFactory,
1146
+ },
1147
+ {
1148
+ provide: NAVIGATION_ITEMS,
1149
+ deps: [TUI_DOC_PAGES],
1150
+ useFactory: (pages) => {
1151
+ const labels = labelsProviderFactory(pages);
1152
+ return [
1153
+ ...labels.map(label => pages.filter(({ section }) => section === label)),
1154
+ pages.filter(page => !page.section),
1155
+ ];
1156
+ },
1157
+ },
1158
+ ];
1159
+
1160
+ class TuiDocNavigationComponent {
1161
+ constructor(cdr, titleService, title$, mode, sidebar, labels, items, searchText, router, activatedRoute, destroy$, readyToScroll$, docIcons, icons, doc) {
1162
+ this.title$ = title$;
1163
+ this.mode = mode;
1164
+ this.sidebar = sidebar;
1165
+ this.labels = labels;
1166
+ this.items = items;
1167
+ this.searchText = searchText;
1168
+ this.router = router;
1169
+ this.activatedRoute = activatedRoute;
1170
+ this.destroy$ = destroy$;
1171
+ this.readyToScroll$ = readyToScroll$;
1172
+ this.docIcons = docIcons;
1173
+ this.icons = icons;
1174
+ this.doc = doc;
1175
+ this.menuOpen = false;
1176
+ this.openPagesArr = [];
1177
+ this.openPagesGroupsArr = [];
1178
+ this.active = '';
1179
+ this.search = new UntypedFormControl('');
1180
+ this.filtered$ = tuiControlValue(this.search).pipe(filter(search => search.trim().length > 2), map(search => this.filterItems(this.flattenSubPages(this.items), search)));
1181
+ this.mode$ = this.mode.change$.pipe(startWith(null), map(() => this.mode.mode || 'onLight'));
1182
+ title$.subscribe(title => {
1183
+ cdr.markForCheck();
1184
+ titleService.setTitle(title);
1185
+ this.openActivePageGroup();
1186
+ });
1187
+ combineLatest([
1188
+ this.router.events.pipe(filter((event) => event instanceof Scroll)),
1189
+ this.title$.pipe(switchMap(() => this.readyToScroll$.pipe(filter(Boolean)))),
1190
+ ])
1191
+ .pipe(take(1), map(([event]) => event.anchor || ''), filter(Boolean), takeUntil(this.destroy$))
1192
+ .subscribe(anchor => this.navigateToAnchorLink(anchor));
1193
+ }
1194
+ get canOpen() {
1195
+ var _a, _b;
1196
+ return ((_b = (_a = this.search.value) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0) > 2;
1197
+ }
1198
+ get itemsWithoutSections() {
1199
+ return this.items[this.items.length - 1];
1200
+ }
1201
+ $pages(pages) {
1202
+ return pages;
1203
+ }
1204
+ isActive(route) {
1205
+ return route === this.active;
1206
+ }
1207
+ onGroupClick(index) {
1208
+ this.openPagesGroupsArr[index] = !this.openPagesGroupsArr[index];
1209
+ }
1210
+ closeMenu() {
1211
+ this.menuOpen = false;
1212
+ }
1213
+ onClick(input) {
1214
+ input.open = false;
1215
+ this.menuOpen = false;
1216
+ this.search.setValue('');
1217
+ this.openActivePageGroup();
1218
+ }
1219
+ filterItems(items, search) {
1220
+ return items.map(section => tuiUniqBy(section.filter(({ title, keywords = '' }) => {
1221
+ search = search.toLowerCase().trim();
1222
+ keywords = keywords.toLowerCase();
1223
+ title = title.toLowerCase();
1224
+ return (title.includes(search) ||
1225
+ keywords.includes(search) ||
1226
+ title.includes(tuiTransliterateKeyboardLayout(search)) ||
1227
+ keywords.includes(tuiTransliterateKeyboardLayout(search)) ||
1228
+ search.replace(/-/gi, '').includes(title) ||
1229
+ title.includes(search.replace(/\s|tui/g, '')) ||
1230
+ keywords.includes(search.replace(/\s|tui/g, '')) ||
1231
+ search.split(/\s/).find(word => title.includes(word)));
1232
+ }), 'title'));
1233
+ }
1234
+ flattenSubPages(items) {
1235
+ return items.reduce((array, item) => [
1236
+ ...array,
1237
+ item.reduce((pages, page) => 'subPages' in page
1238
+ ? [...pages, ...page.subPages]
1239
+ : [...pages, page], []),
1240
+ ], []);
1241
+ }
1242
+ isActiveRoute(route) {
1243
+ return this.router.isActive(route, {
1244
+ paths: 'subset',
1245
+ queryParams: 'subset',
1246
+ fragment: 'ignored',
1247
+ matrixParams: 'ignored',
1248
+ });
1249
+ }
1250
+ openActivePageGroup() {
1251
+ this.items.forEach((pages, pagesIndex) => {
1252
+ pages.forEach((page, pageIndex) => {
1253
+ if ('route' in page && this.isActiveRoute(page.route)) {
1254
+ this.openPagesArr[pagesIndex] = true;
1255
+ this.active = page.route;
1256
+ }
1257
+ if ('subPages' in page) {
1258
+ page.subPages.forEach(subPage => {
1259
+ if (this.isActiveRoute(subPage.route)) {
1260
+ this.openPagesArr[pagesIndex] = true;
1261
+ this.openPagesGroupsArr[pagesIndex * 100 + pageIndex] = true;
1262
+ this.active = subPage.route;
1263
+ }
1264
+ });
1265
+ }
1266
+ });
1267
+ });
1268
+ }
1269
+ navigateToAnchorLink(fragment) {
1270
+ const nodes = fragment ? this.doc.querySelectorAll(`#${fragment}`) : [];
1271
+ const element = nodes.length && nodes[nodes.length - 1];
1272
+ if (!element) {
1273
+ return;
1274
+ }
1275
+ // emulate :target event
1276
+ const target = this.doc.createElement('a');
1277
+ target.href = `${this.doc.location.pathname}#${fragment}`;
1278
+ target.style.display = 'none';
1279
+ target.style.position = 'absolute';
1280
+ this.doc.body.appendChild(target);
1281
+ target.click();
1282
+ target.remove();
1283
+ }
1284
+ }
1285
+ TuiDocNavigationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationComponent, deps: [{ token: ChangeDetectorRef }, { token: Title }, { token: NAVIGATION_TITLE }, { token: TuiModeDirective }, { token: TuiSidebarDirective, optional: true }, { token: NAVIGATION_LABELS }, { token: NAVIGATION_ITEMS }, { token: TUI_DOC_SEARCH_TEXT }, { token: Router }, { token: ActivatedRoute }, { token: TuiDestroyService, self: true }, { token: TUI_DOC_PAGE_LOADED }, { token: TUI_DOC_ICONS }, { token: TUI_COMMON_ICONS }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Component });
1286
+ TuiDocNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocNavigationComponent, selector: "tui-doc-navigation", host: { properties: { "class._open": "this.menuOpen" } }, providers: NAVIGATION_PROVIDERS, ngImport: i0, template: "<tui-input\n #input\n tuiTextfieldSize=\"m\"\n class=\"t-input\"\n [formControl]=\"search\"\n [tuiAutoFocus]=\"!!sidebar\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldIconLeft]=\"docIcons.search\"\n [tuiTextfieldLabelOutside]=\"true\"\n>\n {{ searchText }}\n <ng-container *ngIf=\"canOpen\">\n <tui-data-list *tuiDataList>\n <tui-opt-group\n *ngFor=\"let group of filtered$ | async; let index = index\"\n [label]=\"labels[index] || ''\"\n >\n <a\n *ngFor=\"let item of group\"\n tuiOption\n [fragment]=\"item.fragment\"\n [routerLink]=\"item.route\"\n (click)=\"onClick(input)\"\n >\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n </tui-opt-group>\n </tui-data-list>\n </ng-container>\n</tui-input>\n\n<nav class=\"t-navigation\">\n <tui-scrollbar\n class=\"t-scrollbar\"\n [tuiMode]=\"mode$ | async\"\n >\n <tui-accordion\n [closeOthers]=\"false\"\n [rounded]=\"false\"\n >\n <tui-accordion-item\n *ngFor=\"let label of labels; index as index\"\n size=\"s\"\n [borders]=\"null\"\n [(open)]=\"!!openPagesArr[index]\"\n >\n <span class=\"t-label\">\n <strong>{{ label }}</strong>\n </span>\n <ng-template tuiAccordionItemContent>\n <div class=\"t-section\">\n <ng-container\n *ngFor=\"let item of items[index]; index as subIndex\"\n [ngTemplateOutlet]=\"pages\"\n [ngTemplateOutletContext]=\"{item: item, index: index * 100 + subIndex}\"\n ></ng-container>\n </div>\n </ng-template>\n </tui-accordion-item>\n </tui-accordion>\n <div class=\"t-items-container\">\n <ng-container\n *ngFor=\"let item of itemsWithoutSections; let index = index\"\n [ngTemplateOutlet]=\"pages\"\n [ngTemplateOutletContext]=\"{item: item, index: items.length - 1 + index}\"\n ></ng-container>\n </div>\n\n <ng-template\n #pages\n let-index=\"index\"\n let-item=\"item\"\n >\n <a\n *ngIf=\"!item.subPages; else subPagesTemplate\"\n routerLinkActive=\"t-sublink_active\"\n tuiLink\n class=\"t-sublink\"\n [routerLink]=\"item.route\"\n [tuiScrollIntoViewLink]=\"isActive(item.route)\"\n (click)=\"closeMenu()\"\n >\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n\n <ng-template #subPagesTemplate>\n <div\n routerLinkActive\n class=\"t-subsection\"\n [routerLinkActiveOptions]=\"{exact: false}\"\n >\n <button\n *ngIf=\"item.subPages\"\n tuiLink\n type=\"button\"\n class=\"t-sublink t-sublink_subsection\"\n (click)=\"onGroupClick(index)\"\n >\n <tui-svg\n class=\"t-chevron\"\n [class.t-chevron_active]=\"!!openPagesGroupsArr[index]\"\n [src]=\"icons.more\"\n ></tui-svg>\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </button>\n <tui-expand\n class=\"t-expand\"\n [expanded]=\"!!openPagesGroupsArr[index]\"\n >\n <div class=\"t-section t-section_bordered\">\n <a\n *ngFor=\"let subPage of $pages(item.subPages)\"\n routerLinkActive=\"t-sublink_active\"\n tuiLink\n class=\"t-sublink t-sublink_small\"\n [fragment]=\"subPage.fragment\"\n [routerLink]=\"subPage.route\"\n [tuiScrollIntoViewLink]=\"isActive(subPage.route)\"\n (click)=\"closeMenu()\"\n >\n {{ subPage.title }}\n <tui-svg\n *polymorpheusOutlet=\"subPage.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n </div>\n </tui-expand>\n </div>\n </ng-template>\n </ng-template>\n </tui-scrollbar>\n</nav>\n\n<ng-content></ng-content>\n", styles: [":host{z-index:1;display:flex;flex-direction:column;text-align:center;background:var(--tui-base-01)}.t-input{margin:1.25rem}.t-navigation{display:flex;max-height:100%;min-height:0;flex:1 1 0;text-align:left}.t-scrollbar{scroll-behavior:smooth;width:100%}:host-context(tui-root._reduced-motion) .t-scrollbar{scroll-behavior:auto}.t-items-container{display:flex;flex-direction:column;padding:0 1rem}.t-label{margin-left:.5rem}.t-expand{margin-left:.25rem}.t-section{display:flex;flex-direction:column;align-items:flex-start;margin:-1rem 0 -.5rem}.t-section_bordered{margin:.5rem 0;border-left:1px solid var(--tui-base-03)}.t-subsection{margin-left:.5rem}.t-sublink{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;border:0;background:none;font-size:inherit;line-height:inherit;text-decoration:none;font:var(--tui-font-text-m);margin-left:.5rem;padding-top:1rem}.t-sublink_small{margin-left:1rem;line-height:1.5rem;padding-top:.5rem}.t-sublink_subsection{margin-left:0;line-height:1.6rem}.t-sublink.t-sublink.t-sublink_active{color:var(--tui-text-01)}.t-icon{margin-left:.5rem}.t-chevron{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;width:1rem;height:1rem;margin:-.25rem .25rem 0 -.1875rem}.t-chevron_active{transform:rotate(90deg)}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i3.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "directive", type: i1$1.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: i5.TuiScrollIntoViewLinkDirective, selector: "[tuiScrollIntoViewLink]", inputs: ["tuiScrollIntoViewLink"] }, { kind: "component", type: i3$1.TuiInputComponent, selector: "tui-input" }, { kind: "directive", type: i3$1.TuiInputDirective, selector: "tui-input" }, { kind: "directive", type: i4.TuiTextfieldCleanerDirective, selector: "[tuiTextfieldCleaner]", inputs: ["tuiTextfieldCleaner"] }, { kind: "directive", type: i4.TuiTextfieldLabelOutsideDirective, selector: "[tuiTextfieldLabelOutside]", inputs: ["tuiTextfieldLabelOutside"] }, { kind: "directive", type: i4.TuiTextfieldSizeDirective, selector: "[tuiTextfieldSize]", inputs: ["tuiTextfieldSize"] }, { kind: "directive", type: i4.TuiTextfieldIconLeftDirective, selector: "[tuiTextfieldIconLeft]", inputs: ["tuiTextfieldIconLeft"] }, { kind: "directive", type: i4.TuiModeDirective, selector: "[tuiMode]", inputs: ["tuiMode"] }, { kind: "component", type: i4.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }, { kind: "component", type: i4.TuiExpandComponent, selector: "tui-expand", inputs: ["async", "expanded"] }, { kind: "component", type: i3$1.TuiAccordionComponent, selector: "tui-accordion", inputs: ["closeOthers", "rounded"] }, { kind: "component", type: i3$1.TuiAccordionItemComponent, selector: "tui-accordion-item", inputs: ["noPadding", "showArrow", "borders", "size", "disabled", "disableHover", "open", "async"], outputs: ["openChange"] }, { kind: "directive", type: i3$1.TuiAccordionItemContentDirective, selector: "ng-template[tuiAccordionItemContent]" }, { kind: "component", type: i4.TuiScrollbarComponent, selector: "tui-scrollbar", inputs: ["hidden"] }, { kind: "component", type: i4.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { kind: "component", type: i4.TuiDataListComponent, selector: "tui-data-list", inputs: ["role", "emptyContent", "size"] }, { kind: "component", type: i4.TuiOptionComponent, selector: "button[tuiOption], a[tuiOption]", inputs: ["size", "role", "disabled", "value"] }, { kind: "directive", type: i4.TuiOptGroupDirective, selector: "tui-opt-group", inputs: ["label"] }, { kind: "directive", type: i4.TuiDataListDirective, selector: "ng-template[tuiDataList]" }, { kind: "directive", type: i6.TuiAutoFocusDirective, selector: "[tuiAutoFocus]", inputs: ["tuiAutoFocus"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1287
+ __decorate([
1288
+ tuiPure
1289
+ ], TuiDocNavigationComponent.prototype, "filterItems", null);
1290
+ __decorate([
1291
+ tuiPure
1292
+ ], TuiDocNavigationComponent.prototype, "flattenSubPages", null);
1293
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationComponent, decorators: [{
1294
+ type: Component,
1295
+ args: [{ selector: 'tui-doc-navigation', changeDetection: ChangeDetectionStrategy.OnPush, providers: NAVIGATION_PROVIDERS, template: "<tui-input\n #input\n tuiTextfieldSize=\"m\"\n class=\"t-input\"\n [formControl]=\"search\"\n [tuiAutoFocus]=\"!!sidebar\"\n [tuiTextfieldCleaner]=\"true\"\n [tuiTextfieldIconLeft]=\"docIcons.search\"\n [tuiTextfieldLabelOutside]=\"true\"\n>\n {{ searchText }}\n <ng-container *ngIf=\"canOpen\">\n <tui-data-list *tuiDataList>\n <tui-opt-group\n *ngFor=\"let group of filtered$ | async; let index = index\"\n [label]=\"labels[index] || ''\"\n >\n <a\n *ngFor=\"let item of group\"\n tuiOption\n [fragment]=\"item.fragment\"\n [routerLink]=\"item.route\"\n (click)=\"onClick(input)\"\n >\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n </tui-opt-group>\n </tui-data-list>\n </ng-container>\n</tui-input>\n\n<nav class=\"t-navigation\">\n <tui-scrollbar\n class=\"t-scrollbar\"\n [tuiMode]=\"mode$ | async\"\n >\n <tui-accordion\n [closeOthers]=\"false\"\n [rounded]=\"false\"\n >\n <tui-accordion-item\n *ngFor=\"let label of labels; index as index\"\n size=\"s\"\n [borders]=\"null\"\n [(open)]=\"!!openPagesArr[index]\"\n >\n <span class=\"t-label\">\n <strong>{{ label }}</strong>\n </span>\n <ng-template tuiAccordionItemContent>\n <div class=\"t-section\">\n <ng-container\n *ngFor=\"let item of items[index]; index as subIndex\"\n [ngTemplateOutlet]=\"pages\"\n [ngTemplateOutletContext]=\"{item: item, index: index * 100 + subIndex}\"\n ></ng-container>\n </div>\n </ng-template>\n </tui-accordion-item>\n </tui-accordion>\n <div class=\"t-items-container\">\n <ng-container\n *ngFor=\"let item of itemsWithoutSections; let index = index\"\n [ngTemplateOutlet]=\"pages\"\n [ngTemplateOutletContext]=\"{item: item, index: items.length - 1 + index}\"\n ></ng-container>\n </div>\n\n <ng-template\n #pages\n let-index=\"index\"\n let-item=\"item\"\n >\n <a\n *ngIf=\"!item.subPages; else subPagesTemplate\"\n routerLinkActive=\"t-sublink_active\"\n tuiLink\n class=\"t-sublink\"\n [routerLink]=\"item.route\"\n [tuiScrollIntoViewLink]=\"isActive(item.route)\"\n (click)=\"closeMenu()\"\n >\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n\n <ng-template #subPagesTemplate>\n <div\n routerLinkActive\n class=\"t-subsection\"\n [routerLinkActiveOptions]=\"{exact: false}\"\n >\n <button\n *ngIf=\"item.subPages\"\n tuiLink\n type=\"button\"\n class=\"t-sublink t-sublink_subsection\"\n (click)=\"onGroupClick(index)\"\n >\n <tui-svg\n class=\"t-chevron\"\n [class.t-chevron_active]=\"!!openPagesGroupsArr[index]\"\n [src]=\"icons.more\"\n ></tui-svg>\n {{ item.title }}\n <tui-svg\n *polymorpheusOutlet=\"item.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </button>\n <tui-expand\n class=\"t-expand\"\n [expanded]=\"!!openPagesGroupsArr[index]\"\n >\n <div class=\"t-section t-section_bordered\">\n <a\n *ngFor=\"let subPage of $pages(item.subPages)\"\n routerLinkActive=\"t-sublink_active\"\n tuiLink\n class=\"t-sublink t-sublink_small\"\n [fragment]=\"subPage.fragment\"\n [routerLink]=\"subPage.route\"\n [tuiScrollIntoViewLink]=\"isActive(subPage.route)\"\n (click)=\"closeMenu()\"\n >\n {{ subPage.title }}\n <tui-svg\n *polymorpheusOutlet=\"subPage.icon as icon\"\n class=\"t-icon\"\n [src]=\"icon\"\n ></tui-svg>\n </a>\n </div>\n </tui-expand>\n </div>\n </ng-template>\n </ng-template>\n </tui-scrollbar>\n</nav>\n\n<ng-content></ng-content>\n", styles: [":host{z-index:1;display:flex;flex-direction:column;text-align:center;background:var(--tui-base-01)}.t-input{margin:1.25rem}.t-navigation{display:flex;max-height:100%;min-height:0;flex:1 1 0;text-align:left}.t-scrollbar{scroll-behavior:smooth;width:100%}:host-context(tui-root._reduced-motion) .t-scrollbar{scroll-behavior:auto}.t-items-container{display:flex;flex-direction:column;padding:0 1rem}.t-label{margin-left:.5rem}.t-expand{margin-left:.25rem}.t-section{display:flex;flex-direction:column;align-items:flex-start;margin:-1rem 0 -.5rem}.t-section_bordered{margin:.5rem 0;border-left:1px solid var(--tui-base-03)}.t-subsection{margin-left:.5rem}.t-sublink{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;border:0;background:none;font-size:inherit;line-height:inherit;text-decoration:none;font:var(--tui-font-text-m);margin-left:.5rem;padding-top:1rem}.t-sublink_small{margin-left:1rem;line-height:1.5rem;padding-top:.5rem}.t-sublink_subsection{margin-left:0;line-height:1.6rem}.t-sublink.t-sublink.t-sublink_active{color:var(--tui-text-01)}.t-icon{margin-left:.5rem}.t-chevron{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;width:1rem;height:1rem;margin:-.25rem .25rem 0 -.1875rem}.t-chevron_active{transform:rotate(90deg)}\n"] }]
1296
+ }], ctorParameters: function () {
1297
+ return [{ type: i0.ChangeDetectorRef, decorators: [{
1298
+ type: Inject,
1299
+ args: [ChangeDetectorRef]
1300
+ }] }, { type: i9.Title, decorators: [{
1301
+ type: Inject,
1302
+ args: [Title]
1303
+ }] }, { type: i10.Observable, decorators: [{
1304
+ type: Inject,
1305
+ args: [NAVIGATION_TITLE]
1306
+ }] }, { type: i4.TuiModeDirective, decorators: [{
1307
+ type: Inject,
1308
+ args: [TuiModeDirective]
1309
+ }] }, { type: undefined, decorators: [{
1310
+ type: Optional
1311
+ }, {
1312
+ type: Inject,
1313
+ args: [TuiSidebarDirective]
1314
+ }] }, { type: undefined, decorators: [{
1315
+ type: Inject,
1316
+ args: [NAVIGATION_LABELS]
1317
+ }] }, { type: undefined, decorators: [{
1318
+ type: Inject,
1319
+ args: [NAVIGATION_ITEMS]
1320
+ }] }, { type: undefined, decorators: [{
1321
+ type: Inject,
1322
+ args: [TUI_DOC_SEARCH_TEXT]
1323
+ }] }, { type: i3.Router, decorators: [{
1324
+ type: Inject,
1325
+ args: [Router]
1326
+ }] }, { type: i3.ActivatedRoute, decorators: [{
1327
+ type: Inject,
1328
+ args: [ActivatedRoute]
1329
+ }] }, { type: i10.Observable, decorators: [{
1330
+ type: Self
1331
+ }, {
1332
+ type: Inject,
1333
+ args: [TuiDestroyService]
1334
+ }] }, { type: i10.Observable, decorators: [{
1335
+ type: Inject,
1336
+ args: [TUI_DOC_PAGE_LOADED]
1337
+ }] }, { type: undefined, decorators: [{
1338
+ type: Inject,
1339
+ args: [TUI_DOC_ICONS]
1340
+ }] }, { type: undefined, decorators: [{
1341
+ type: Inject,
1342
+ args: [TUI_COMMON_ICONS]
1343
+ }] }, { type: Document, decorators: [{
1344
+ type: Inject,
1345
+ args: [DOCUMENT]
1346
+ }] }];
1347
+ }, propDecorators: { menuOpen: [{
1348
+ type: HostBinding,
1349
+ args: ['class._open']
1350
+ }], filterItems: [], flattenSubPages: [] } });
1351
+
1352
+ class TuiDocHeaderComponent {
1353
+ constructor(icons, logo, menu, router, swipes$) {
1354
+ this.icons = icons;
1355
+ this.logo = logo;
1356
+ this.menu = menu;
1357
+ this.router = router;
1358
+ this.swipes$ = swipes$;
1359
+ this.stream$ = new Subject();
1360
+ this.open$ = merge(this.router.events.pipe(map(ALWAYS_FALSE_HANDLER)), this.stream$, this.swipes$.pipe(filter(swipe => swipe.direction === 'left' || swipe.direction === 'right'), map(swipe => swipe.direction === 'right'))).pipe(startWith(false), distinctUntilChanged());
1361
+ }
1362
+ onClick() {
1363
+ this.stream$.next(true);
1364
+ }
1365
+ onActiveZone(active) {
1366
+ if (!active) {
1367
+ this.stream$.next(false);
1368
+ }
1369
+ }
1370
+ }
1371
+ TuiDocHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderComponent, deps: [{ token: TUI_DOC_ICONS }, { token: TUI_DOC_LOGO }, { token: TUI_DOC_MENU_TEXT }, { token: Router }, { token: TuiSwipeService }], target: i0.ɵɵFactoryTarget.Component });
1372
+ TuiDocHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocHeaderComponent, selector: "header[tuiDocHeader]", ngImport: i0, template: "<button\n appearance=\"icon\"\n tuiIconButton\n type=\"button\"\n class=\"t-menu\"\n [icon]=\"icons.menu\"\n [title]=\"menu\"\n (click)=\"onClick()\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n>\n <tui-doc-navigation\n *tuiSidebar=\"!!(open$ | async)\"\n class=\"t-navigation\"\n ></tui-doc-navigation>\n</button>\n<div class=\"t-logo\">\n <img\n *polymorpheusOutlet=\"logo as src\"\n alt=\"Logo\"\n class=\"t-img\"\n [src]=\"src\"\n />\n</div>\n<ng-content></ng-content>\n", styles: [":host{position:fixed;top:0;left:0;right:0;z-index:1;display:flex;box-shadow:var(--tui-shadow-navigation);height:3.9375rem;align-items:center;padding:0 1.25rem;background:var(--tui-base-01);border-bottom:1px solid var(--tui-base-03)}@supports (background: color-mix(in srgb,var(--tui-base-01),transparent 50%)){:host{background:color-mix(in srgb,var(--tui-base-01),transparent 50%);-webkit-backdrop-filter:blur(1.25rem);backdrop-filter:blur(1.25rem)}}.t-logo{margin-right:auto;font:var(--tui-font-heading-5)}.t-img{display:block}.t-menu{margin-left:-1.25rem}@media screen and (min-width: 48em){.t-menu{display:none}}.t-navigation{min-height:100%}\n"], dependencies: [{ kind: "directive", type: i1$1.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i3$2.TuiSidebarDirective, selector: "[tuiSidebar]", inputs: ["tuiSidebarDirection", "tuiSidebarAutoWidth", "tuiSidebar"] }, { kind: "directive", type: i6.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { kind: "component", type: TuiDocNavigationComponent, selector: "tui-doc-navigation" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1373
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderComponent, decorators: [{
1374
+ type: Component,
1375
+ args: [{ selector: 'header[tuiDocHeader]', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\n appearance=\"icon\"\n tuiIconButton\n type=\"button\"\n class=\"t-menu\"\n [icon]=\"icons.menu\"\n [title]=\"menu\"\n (click)=\"onClick()\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n>\n <tui-doc-navigation\n *tuiSidebar=\"!!(open$ | async)\"\n class=\"t-navigation\"\n ></tui-doc-navigation>\n</button>\n<div class=\"t-logo\">\n <img\n *polymorpheusOutlet=\"logo as src\"\n alt=\"Logo\"\n class=\"t-img\"\n [src]=\"src\"\n />\n</div>\n<ng-content></ng-content>\n", styles: [":host{position:fixed;top:0;left:0;right:0;z-index:1;display:flex;box-shadow:var(--tui-shadow-navigation);height:3.9375rem;align-items:center;padding:0 1.25rem;background:var(--tui-base-01);border-bottom:1px solid var(--tui-base-03)}@supports (background: color-mix(in srgb,var(--tui-base-01),transparent 50%)){:host{background:color-mix(in srgb,var(--tui-base-01),transparent 50%);-webkit-backdrop-filter:blur(1.25rem);backdrop-filter:blur(1.25rem)}}.t-logo{margin-right:auto;font:var(--tui-font-heading-5)}.t-img{display:block}.t-menu{margin-left:-1.25rem}@media screen and (min-width: 48em){.t-menu{display:none}}.t-navigation{min-height:100%}\n"] }]
1376
+ }], ctorParameters: function () {
1377
+ return [{ type: undefined, decorators: [{
1378
+ type: Inject,
1379
+ args: [TUI_DOC_ICONS]
1380
+ }] }, { type: undefined, decorators: [{
1381
+ type: Inject,
1382
+ args: [TUI_DOC_LOGO]
1383
+ }] }, { type: undefined, decorators: [{
1384
+ type: Inject,
1385
+ args: [TUI_DOC_MENU_TEXT]
1386
+ }] }, { type: i3.Router, decorators: [{
1387
+ type: Inject,
1388
+ args: [Router]
1389
+ }] }, { type: i6.TuiSwipeService, decorators: [{
1390
+ type: Inject,
1391
+ args: [TuiSwipeService]
1392
+ }] }];
1393
+ } });
1394
+
1395
+ class TuiDocNavigationModule {
1396
+ }
1397
+ TuiDocNavigationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1398
+ TuiDocNavigationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationModule, declarations: [TuiDocNavigationComponent], imports: [CommonModule,
1399
+ ReactiveFormsModule,
1400
+ RouterModule,
1401
+ PolymorpheusModule,
1402
+ TuiScrollIntoViewLinkModule,
1403
+ TuiButtonModule,
1404
+ TuiInputModule,
1405
+ TuiTextfieldControllerModule,
1406
+ TuiActiveZoneModule,
1407
+ TuiLetModule,
1408
+ TuiModeModule,
1409
+ TuiLinkModule,
1410
+ TuiExpandModule,
1411
+ TuiHostedDropdownModule,
1412
+ TuiDropdownModule,
1413
+ TuiAccordionModule,
1414
+ TuiScrollbarModule,
1415
+ TuiSvgModule,
1416
+ TuiDataListModule,
1417
+ TuiAutoFocusModule], exports: [TuiDocNavigationComponent] });
1418
+ TuiDocNavigationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationModule, imports: [CommonModule,
1419
+ ReactiveFormsModule,
1420
+ RouterModule,
1421
+ PolymorpheusModule,
1422
+ TuiScrollIntoViewLinkModule,
1423
+ TuiButtonModule,
1424
+ TuiInputModule,
1425
+ TuiTextfieldControllerModule,
1426
+ TuiActiveZoneModule,
1427
+ TuiLetModule,
1428
+ TuiModeModule,
1429
+ TuiLinkModule,
1430
+ TuiExpandModule,
1431
+ TuiHostedDropdownModule,
1432
+ TuiDropdownModule,
1433
+ TuiAccordionModule,
1434
+ TuiScrollbarModule,
1435
+ TuiSvgModule,
1436
+ TuiDataListModule,
1437
+ TuiAutoFocusModule] });
1438
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocNavigationModule, decorators: [{
1439
+ type: NgModule,
1440
+ args: [{
1441
+ imports: [
1442
+ CommonModule,
1443
+ ReactiveFormsModule,
1444
+ RouterModule,
1445
+ PolymorpheusModule,
1446
+ TuiScrollIntoViewLinkModule,
1447
+ TuiButtonModule,
1448
+ TuiInputModule,
1449
+ TuiTextfieldControllerModule,
1450
+ TuiActiveZoneModule,
1451
+ TuiLetModule,
1452
+ TuiModeModule,
1453
+ TuiLinkModule,
1454
+ TuiExpandModule,
1455
+ TuiHostedDropdownModule,
1456
+ TuiDropdownModule,
1457
+ TuiAccordionModule,
1458
+ TuiScrollbarModule,
1459
+ TuiSvgModule,
1460
+ TuiDataListModule,
1461
+ TuiAutoFocusModule,
1462
+ ],
1463
+ declarations: [TuiDocNavigationComponent],
1464
+ exports: [TuiDocNavigationComponent],
1465
+ }]
1466
+ }] });
1467
+
1468
+ class TuiDocHeaderModule {
1469
+ }
1470
+ TuiDocHeaderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1471
+ TuiDocHeaderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderModule, declarations: [TuiDocHeaderComponent], imports: [CommonModule,
1472
+ PolymorpheusModule,
1473
+ TuiButtonModule,
1474
+ TuiSidebarModule,
1475
+ TuiActiveZoneModule,
1476
+ TuiDocNavigationModule], exports: [TuiDocHeaderComponent] });
1477
+ TuiDocHeaderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderModule, imports: [CommonModule,
1478
+ PolymorpheusModule,
1479
+ TuiButtonModule,
1480
+ TuiSidebarModule,
1481
+ TuiActiveZoneModule,
1482
+ TuiDocNavigationModule] });
1483
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocHeaderModule, decorators: [{
1484
+ type: NgModule,
1485
+ args: [{
1486
+ imports: [
1487
+ CommonModule,
1488
+ PolymorpheusModule,
1489
+ TuiButtonModule,
1490
+ TuiSidebarModule,
1491
+ TuiActiveZoneModule,
1492
+ TuiDocNavigationModule,
1493
+ ],
1494
+ declarations: [TuiDocHeaderComponent],
1495
+ exports: [TuiDocHeaderComponent],
1496
+ }]
1497
+ }] });
1498
+
1499
+ class TuiDocSeeAlsoComponent {
1500
+ constructor(text, pages) {
1501
+ this.text = text;
1502
+ this.pages = pages;
1503
+ this.seeAlso = [];
1504
+ }
1505
+ getRouterLink(pageTitle) {
1506
+ var _a, _b;
1507
+ return (_b = (_a = this.pages.get(pageTitle)) === null || _a === void 0 ? void 0 : _a.route) !== null && _b !== void 0 ? _b : '';
1508
+ }
1509
+ }
1510
+ TuiDocSeeAlsoComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoComponent, deps: [{ token: TUI_DOC_SEE_ALSO_TEXT }, { token: TUI_DOC_MAP_PAGES }], target: i0.ɵɵFactoryTarget.Component });
1511
+ TuiDocSeeAlsoComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocSeeAlsoComponent, selector: "tui-doc-see-also", inputs: { seeAlso: "seeAlso" }, ngImport: i0, template: "<h5 class=\"t-header\">{{ text }}</h5>\n<ng-container *ngFor=\"let item of seeAlso; last as last\">\n <a\n tuiLink\n [innerText]=\"item\"\n [routerLink]=\"getRouterLink(item)\"\n ></a>\n <ng-container *ngIf=\"!last\">{{ ', ' }}</ng-container>\n</ng-container>\n", styles: [":host{display:block}.t-header{font-size:.6875rem;line-height:1rem;text-transform:uppercase;letter-spacing:.075em;color:var(--tui-text-02);margin:0 0 .5rem;white-space:nowrap}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i4.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1512
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoComponent, decorators: [{
1513
+ type: Component,
1514
+ args: [{ selector: 'tui-doc-see-also', changeDetection: ChangeDetectionStrategy.OnPush, template: "<h5 class=\"t-header\">{{ text }}</h5>\n<ng-container *ngFor=\"let item of seeAlso; last as last\">\n <a\n tuiLink\n [innerText]=\"item\"\n [routerLink]=\"getRouterLink(item)\"\n ></a>\n <ng-container *ngIf=\"!last\">{{ ', ' }}</ng-container>\n</ng-container>\n", styles: [":host{display:block}.t-header{font-size:.6875rem;line-height:1rem;text-transform:uppercase;letter-spacing:.075em;color:var(--tui-text-02);margin:0 0 .5rem;white-space:nowrap}\n"] }]
1515
+ }], ctorParameters: function () {
1516
+ return [{ type: undefined, decorators: [{
1517
+ type: Inject,
1518
+ args: [TUI_DOC_SEE_ALSO_TEXT]
1519
+ }] }, { type: Map, decorators: [{
1520
+ type: Inject,
1521
+ args: [TUI_DOC_MAP_PAGES]
1522
+ }] }];
1523
+ }, propDecorators: { seeAlso: [{
1524
+ type: Input
1525
+ }] } });
1526
+
1527
+ class TuiDocSeeAlsoModule {
1528
+ }
1529
+ TuiDocSeeAlsoModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1530
+ TuiDocSeeAlsoModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoModule, declarations: [TuiDocSeeAlsoComponent], imports: [CommonModule, RouterModule, TuiLinkModule], exports: [TuiDocSeeAlsoComponent] });
1531
+ TuiDocSeeAlsoModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoModule, imports: [CommonModule, RouterModule, TuiLinkModule] });
1532
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSeeAlsoModule, decorators: [{
1533
+ type: NgModule,
1534
+ args: [{
1535
+ imports: [CommonModule, RouterModule, TuiLinkModule],
1536
+ declarations: [TuiDocSeeAlsoComponent],
1537
+ exports: [TuiDocSeeAlsoComponent],
1538
+ }]
1539
+ }] });
1540
+
1541
+ class TuiDocSourceCodeComponent {
1542
+ constructor(icons, sourceCode, text) {
1543
+ this.icons = icons;
1544
+ this.sourceCode = sourceCode;
1545
+ this.text = text;
1546
+ this.header = '';
1547
+ this.package = '';
1548
+ this.type = '';
1549
+ this.path = '';
1550
+ }
1551
+ get pathOptions() {
1552
+ return this.getPathOptions(this.header, this.package, this.type, this.path);
1553
+ }
1554
+ pathIsUrl(path) {
1555
+ return path.startsWith('http');
1556
+ }
1557
+ getPathOptions(header, packageName, type, path) {
1558
+ return {
1559
+ header,
1560
+ package: packageName,
1561
+ type,
1562
+ path,
1563
+ };
1564
+ }
1565
+ }
1566
+ TuiDocSourceCodeComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeComponent, deps: [{ token: TUI_DOC_ICONS }, { token: TUI_DOC_SOURCE_CODE }, { token: TUI_DOC_SOURCE_CODE_TEXT }], target: i0.ɵɵFactoryTarget.Component });
1567
+ TuiDocSourceCodeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocSourceCodeComponent, selector: "tui-doc-source-code", inputs: { header: "header", package: "package", type: "type", path: "path" }, ngImport: i0, template: "<a\n *polymorpheusOutlet=\"pathIsUrl(path) ? path : sourceCode as link; context: pathOptions\"\n appearance=\"icon\"\n size=\"s\"\n target=\"_blank\"\n tuiIconButton\n type=\"button\"\n [href]=\"link\"\n [icon]=\"icons.code\"\n [title]=\"text\"\n></a>\n", dependencies: [{ kind: "directive", type: i1$1.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1568
+ __decorate([
1569
+ tuiPure
1570
+ ], TuiDocSourceCodeComponent.prototype, "pathIsUrl", null);
1571
+ __decorate([
1572
+ tuiPure
1573
+ ], TuiDocSourceCodeComponent.prototype, "getPathOptions", null);
1574
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeComponent, decorators: [{
1575
+ type: Component,
1576
+ args: [{ selector: 'tui-doc-source-code', changeDetection: ChangeDetectionStrategy.OnPush, template: "<a\n *polymorpheusOutlet=\"pathIsUrl(path) ? path : sourceCode as link; context: pathOptions\"\n appearance=\"icon\"\n size=\"s\"\n target=\"_blank\"\n tuiIconButton\n type=\"button\"\n [href]=\"link\"\n [icon]=\"icons.code\"\n [title]=\"text\"\n></a>\n" }]
1577
+ }], ctorParameters: function () {
1578
+ return [{ type: undefined, decorators: [{
1579
+ type: Inject,
1580
+ args: [TUI_DOC_ICONS]
1581
+ }] }, { type: undefined, decorators: [{
1582
+ type: Inject,
1583
+ args: [TUI_DOC_SOURCE_CODE]
1584
+ }] }, { type: undefined, decorators: [{
1585
+ type: Inject,
1586
+ args: [TUI_DOC_SOURCE_CODE_TEXT]
1587
+ }] }];
1588
+ }, propDecorators: { header: [{
1589
+ type: Input
1590
+ }], package: [{
1591
+ type: Input
1592
+ }], type: [{
1593
+ type: Input
1594
+ }], path: [{
1595
+ type: Input
1596
+ }], pathIsUrl: [], getPathOptions: [] } });
1597
+
1598
+ class TuiDocSourceCodeModule {
1599
+ }
1600
+ TuiDocSourceCodeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1601
+ TuiDocSourceCodeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeModule, declarations: [TuiDocSourceCodeComponent], imports: [CommonModule, PolymorpheusModule, TuiButtonModule], exports: [TuiDocSourceCodeComponent] });
1602
+ TuiDocSourceCodeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeModule, imports: [CommonModule, PolymorpheusModule, TuiButtonModule] });
1603
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocSourceCodeModule, decorators: [{
1604
+ type: NgModule,
1605
+ args: [{
1606
+ imports: [CommonModule, PolymorpheusModule, TuiButtonModule],
1607
+ declarations: [TuiDocSourceCodeComponent],
1608
+ exports: [TuiDocSourceCodeComponent],
1609
+ }]
1610
+ }] });
1611
+
1612
+ class TuiLanguageSwitcherComponent {
1613
+ constructor(switcher, flagPipe) {
1614
+ this.switcher = switcher;
1615
+ this.flagPipe = flagPipe;
1616
+ this.language = new UntypedFormControl(tuiCapitalizeFirstLetter(this.switcher.language));
1617
+ this.flags = new Map([
1618
+ ['chinese', TuiCountryIsoCode.CN],
1619
+ ['dutch', TuiCountryIsoCode.NL],
1620
+ ['english', TuiCountryIsoCode.GB],
1621
+ ['french', TuiCountryIsoCode.FR],
1622
+ ['german', TuiCountryIsoCode.DE],
1623
+ ['italian', TuiCountryIsoCode.IT],
1624
+ ['polish', TuiCountryIsoCode.PL],
1625
+ ['portuguese', TuiCountryIsoCode.PT],
1626
+ ['russian', TuiCountryIsoCode.RU],
1627
+ ['spanish', TuiCountryIsoCode.ES],
1628
+ ['turkish', TuiCountryIsoCode.TR],
1629
+ ['ukrainian', TuiCountryIsoCode.UA],
1630
+ ['kazakh', TuiCountryIsoCode.KZ],
1631
+ ['malay', TuiCountryIsoCode.MY],
1632
+ ['vietnamese', TuiCountryIsoCode.VN],
1633
+ ]);
1634
+ this.names = Array.from(this.flags.keys());
1635
+ }
1636
+ /**
1637
+ * @deprecated use `<img [src]="countryIsoCode | tuiFlagPipe" />`
1638
+ * TODO drop in v4.0
1639
+ */
1640
+ getFlagPath(code) {
1641
+ return this.flagPipe.transform(code);
1642
+ }
1643
+ }
1644
+ TuiLanguageSwitcherComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherComponent, deps: [{ token: TuiLanguageSwitcher }, { token: TuiFlagPipe }], target: i0.ɵɵFactoryTarget.Component });
1645
+ TuiLanguageSwitcherComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiLanguageSwitcherComponent, selector: "tui-language-switcher", providers: [
1646
+ // TODO: for backward compatibility only. Drop in v4.0
1647
+ TuiFlagPipe,
1648
+ ], ngImport: i0, template: "<tui-select [formControl]=\"language\">\n <ng-content></ng-content>\n <tui-data-list *tuiDataList>\n <button\n *ngFor=\"let name of names\"\n tuiOption\n [value]=\"name | titlecase\"\n (click)=\"switcher.setLanguage(name)\"\n >\n <img\n alt=\"\"\n class=\"t-flag\"\n [src]=\"flags.get(name) | tuiFlag\"\n />\n {{ name | titlecase }}\n </button>\n </tui-data-list>\n</tui-select>\n", styles: [".t-flag{width:1.75rem;height:1.25rem;margin-right:.5rem}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: i3$1.TuiSelectComponent, selector: "tui-select", inputs: ["stringify", "identityMatcher", "valueContent"] }, { kind: "directive", type: i3$1.TuiSelectDirective, selector: "tui-select" }, { kind: "component", type: i4.TuiDataListComponent, selector: "tui-data-list", inputs: ["role", "emptyContent", "size"] }, { kind: "component", type: i4.TuiOptionComponent, selector: "button[tuiOption], a[tuiOption]", inputs: ["size", "role", "disabled", "value"] }, { kind: "directive", type: i4.TuiDataListDirective, selector: "ng-template[tuiDataList]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "pipe", type: i1.TitleCasePipe, name: "titlecase" }, { kind: "pipe", type: i4.TuiFlagPipe, name: "tuiFlag" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1649
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherComponent, decorators: [{
1650
+ type: Component,
1651
+ args: [{ selector: 'tui-language-switcher', changeDetection: ChangeDetectionStrategy.OnPush, providers: [
1652
+ // TODO: for backward compatibility only. Drop in v4.0
1653
+ TuiFlagPipe,
1654
+ ], template: "<tui-select [formControl]=\"language\">\n <ng-content></ng-content>\n <tui-data-list *tuiDataList>\n <button\n *ngFor=\"let name of names\"\n tuiOption\n [value]=\"name | titlecase\"\n (click)=\"switcher.setLanguage(name)\"\n >\n <img\n alt=\"\"\n class=\"t-flag\"\n [src]=\"flags.get(name) | tuiFlag\"\n />\n {{ name | titlecase }}\n </button>\n </tui-data-list>\n</tui-select>\n", styles: [".t-flag{width:1.75rem;height:1.25rem;margin-right:.5rem}\n"] }]
1655
+ }], ctorParameters: function () {
1656
+ return [{ type: i5$1.TuiLanguageSwitcher, decorators: [{
1657
+ type: Inject,
1658
+ args: [TuiLanguageSwitcher]
1659
+ }] }, { type: i4.TuiFlagPipe, decorators: [{
1660
+ type: Inject,
1661
+ args: [TuiFlagPipe]
1662
+ }] }];
1663
+ } });
1664
+
1665
+ class TuiLanguageSwitcherModule {
1666
+ }
1667
+ TuiLanguageSwitcherModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1668
+ TuiLanguageSwitcherModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherModule, declarations: [TuiLanguageSwitcherComponent], imports: [CommonModule,
1669
+ TuiFlagPipeModule,
1670
+ TuiSelectModule,
1671
+ TuiDataListModule,
1672
+ ReactiveFormsModule], exports: [TuiLanguageSwitcherComponent] });
1673
+ TuiLanguageSwitcherModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherModule, imports: [CommonModule,
1674
+ TuiFlagPipeModule,
1675
+ TuiSelectModule,
1676
+ TuiDataListModule,
1677
+ ReactiveFormsModule] });
1678
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiLanguageSwitcherModule, decorators: [{
1679
+ type: NgModule,
1680
+ args: [{
1681
+ imports: [
1682
+ CommonModule,
1683
+ TuiFlagPipeModule,
1684
+ TuiSelectModule,
1685
+ TuiDataListModule,
1686
+ ReactiveFormsModule,
1687
+ ],
1688
+ declarations: [TuiLanguageSwitcherComponent],
1689
+ exports: [TuiLanguageSwitcherComponent],
1690
+ }]
1691
+ }] });
1692
+
1693
+ class TuiDocMainComponent {
1694
+ constructor(icons, theme, night) {
1695
+ this.icons = icons;
1696
+ this.theme = theme;
1697
+ this.night = night;
1698
+ this.change$ = this.night;
1699
+ this.night$ = this.change$.pipe(startWith(null), map(() => this.night.value), distinctUntilChanged(), share());
1700
+ }
1701
+ get mode() {
1702
+ return this.night.value ? 'onDark' : null;
1703
+ }
1704
+ get icon() {
1705
+ return this.night.value ? this.icons.day : this.icons.night;
1706
+ }
1707
+ }
1708
+ TuiDocMainComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainComponent, deps: [{ token: TUI_DOC_ICONS }, { token: TuiThemeService }, { token: TuiThemeNightService }], target: i0.ɵɵFactoryTarget.Component });
1709
+ TuiDocMainComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocMainComponent, selector: "tui-doc-main", host: { properties: { "attr.data-mode": "this.mode" } }, providers: [
1710
+ {
1711
+ provide: TuiModeDirective,
1712
+ useExisting: forwardRef(() => TuiDocMainComponent),
1713
+ },
1714
+ TuiSwipeService,
1715
+ ], ngImport: i0, template: "<tui-theme-night *ngIf=\"theme.isDefaultTheme && night.useDefaultNightTheme && (night$ | async)\"></tui-theme-night>\n<tui-root>\n <div class=\"tui-doc-page\">\n <tui-doc-navigation class=\"tui-doc-navigation\">\n <ng-content select=\"tuiDocNavigation\"></ng-content>\n </tui-doc-navigation>\n <div class=\"tui-doc-content\">\n <router-outlet class=\"tui-doc-outlet\"></router-outlet>\n </div>\n </div>\n <header tuiDocHeader>\n <ng-content select=\"tuiDocHeader\"></ng-content>\n <button\n appearance=\"secondary\"\n shape=\"rounded\"\n size=\"s\"\n tuiIconButton\n tuiMode=\"onLight\"\n type=\"button\"\n class=\"tui-doc-night-mode-switch\"\n [icon]=\"icon\"\n (click)=\"night.toggle()\"\n ></button>\n </header>\n <ng-container ngProjectAs=\"tuiOverContent\">\n <ng-content select=\"tuiOverContent\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverDialogs\">\n <ng-content select=\"tuiOverDialogs\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverAlerts\">\n <ng-content select=\"tuiOverAlerts\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverPortals\">\n <ng-content select=\"tuiOverPortals\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverHints\">\n <ng-content select=\"tuiOverHints\"></ng-content>\n </ng-container>\n</tui-root>\n", styles: ["@keyframes tuiShaking{0%,to{transform:translateZ(0)}10%,30%,50%,70%,90%{transform:translate3d(-.3125rem,0,0)}20%,40%,60%,80%{transform:translate3d(.3125rem,0,0)}}html,body{scroll-padding-top:4rem;background:var(--tui-base-01);height:auto}tui-root>tui-scroll-controls>.t-bar_vertical{top:4rem!important}tui-doc-main{display:block}code:not(pre code):not(.hljs):not([class*=\"language-\"]){transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:inline-flex;background:var(--tui-base-02);color:var(--tui-text-02);vertical-align:middle;align-items:center;border-radius:.25rem;font-weight:500;outline:1px solid var(--tui-base-04);font-size:.75rem;padding:0 .3125rem;margin:.125rem .1875rem;text-wrap:wrap}tui-notification code:not(pre code):not(.hljs):not([class*=\"language-\"]){mix-blend-mode:luminosity}a code:not(pre code):not(.hljs):not([class*=\"language-\"]){color:var(--tui-link)}button:focus code,a:focus code{background:var(--tui-base-01)}.tui-doc-page{isolation:isolate;padding-top:4rem}tui-doc-navigation.tui-doc-navigation{position:fixed;top:4rem;bottom:0;width:16.25rem;border-right:1px solid var(--tui-base-03)}@media screen and (max-width: 47.9625em){tui-doc-navigation.tui-doc-navigation{display:none}}.tui-doc-content{margin-left:16.25rem}@media screen and (max-width: 47.9625em){.tui-doc-content{margin-left:0}}.tui-doc-outlet+*{display:block}.tui-doc-night-mode-switch{margin-left:1rem}.tui-doc-night-mode-switch tui-svg{color:var(--tui-text-02)}tui-doc-code .hljs-tag{background:none}tui-doc-code .hljs{display:block;overflow-x:auto;padding:.5em;color:var(--tui-text-01);background-color:var(--tui-clear)}tui-doc-code .hljs.hljs-line-numbers{background:transparent}tui-doc-code .hljs-subst,tui-doc-code .hljs-title{font-weight:400;color:var(--tui-text-01)}tui-doc-code .hljs-property{color:var(--tui-support-14)}tui-doc-code .hljs-comment,tui-doc-code .hljs-quote{color:var(--tui-text-02);font-style:italic}tui-doc-code .hljs-meta{color:#e38162}tui-doc-code .hljs-section,tui-doc-code .hljs-name,tui-doc-code .hljs-literal,tui-doc-code .hljs-keyword,tui-doc-code .hljs-selector-tag,tui-doc-code .hljs-type,tui-doc-code .hljs-selector-id,tui-doc-code .hljs-selector-class{font-weight:700;color:var(--tui-link)}tui-doc-code .hljs-attr{color:var(--tui-link)}tui-doc-code .hljs-attribute,tui-doc-code .hljs-number,tui-doc-code .hljs-regexp,tui-doc-code .hljs-link,tui-doc-code .hljs-built_in{font-weight:700;color:var(--tui-support-06)}tui-doc-code .hljs-number,tui-doc-code .hljs-regexp,tui-doc-code .hljs-link{font-weight:400}tui-doc-code .hljs-string{color:var(--tui-positive);font-weight:700}tui-doc-code .hljs-symbol,tui-doc-code .hljs-bullet,tui-doc-code .hljs-formula{color:var(--tui-text-01);background:var(--tui-base-02);font-style:italic}tui-doc-code .hljs-doctag{text-decoration:underline}tui-doc-code .hljs-variable,tui-doc-code .hljs-template-variable{color:var(--tui-link-hover)}tui-doc-code [data-mode=onDark] .hljs-variable,tui-doc-code [data-mode=onDark] .hljs-template-variable{color:var(--tui-warning-fill)}tui-doc-code .hljs-addition{background:var(--tui-success-bg)}tui-doc-code .hljs-deletion{background:var(--tui-error-bg)}tui-doc-code .hljs-emphasis{font-style:italic}tui-doc-code .hljs-strong{font-weight:700}tui-doc-code .hljs .hljs-line-numbers{padding:0}tui-doc-code .hljs-ln-numbers{vertical-align:top;opacity:.3;text-align:right;padding-right:1em!important}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.RouterOutlet, selector: "router-outlet", inputs: ["name"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }, { kind: "component", type: i4.TuiThemeNightComponent, selector: "tui-theme-night" }, { kind: "component", type: TuiDocHeaderComponent, selector: "header[tuiDocHeader]" }, { kind: "component", type: i4.TuiRootComponent, selector: "tui-root" }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i4.TuiModeDirective, selector: "[tuiMode]", inputs: ["tuiMode"] }, { kind: "component", type: TuiDocNavigationComponent, selector: "tui-doc-navigation" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None });
1716
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainComponent, decorators: [{
1717
+ type: Component,
1718
+ args: [{ selector: 'tui-doc-main', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.Default, providers: [
1719
+ {
1720
+ provide: TuiModeDirective,
1721
+ useExisting: forwardRef(() => TuiDocMainComponent),
1722
+ },
1723
+ TuiSwipeService,
1724
+ ], template: "<tui-theme-night *ngIf=\"theme.isDefaultTheme && night.useDefaultNightTheme && (night$ | async)\"></tui-theme-night>\n<tui-root>\n <div class=\"tui-doc-page\">\n <tui-doc-navigation class=\"tui-doc-navigation\">\n <ng-content select=\"tuiDocNavigation\"></ng-content>\n </tui-doc-navigation>\n <div class=\"tui-doc-content\">\n <router-outlet class=\"tui-doc-outlet\"></router-outlet>\n </div>\n </div>\n <header tuiDocHeader>\n <ng-content select=\"tuiDocHeader\"></ng-content>\n <button\n appearance=\"secondary\"\n shape=\"rounded\"\n size=\"s\"\n tuiIconButton\n tuiMode=\"onLight\"\n type=\"button\"\n class=\"tui-doc-night-mode-switch\"\n [icon]=\"icon\"\n (click)=\"night.toggle()\"\n ></button>\n </header>\n <ng-container ngProjectAs=\"tuiOverContent\">\n <ng-content select=\"tuiOverContent\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverDialogs\">\n <ng-content select=\"tuiOverDialogs\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverAlerts\">\n <ng-content select=\"tuiOverAlerts\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverPortals\">\n <ng-content select=\"tuiOverPortals\"></ng-content>\n </ng-container>\n <ng-container ngProjectAs=\"tuiOverHints\">\n <ng-content select=\"tuiOverHints\"></ng-content>\n </ng-container>\n</tui-root>\n", styles: ["@keyframes tuiShaking{0%,to{transform:translateZ(0)}10%,30%,50%,70%,90%{transform:translate3d(-.3125rem,0,0)}20%,40%,60%,80%{transform:translate3d(.3125rem,0,0)}}html,body{scroll-padding-top:4rem;background:var(--tui-base-01);height:auto}tui-root>tui-scroll-controls>.t-bar_vertical{top:4rem!important}tui-doc-main{display:block}code:not(pre code):not(.hljs):not([class*=\"language-\"]){transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:inline-flex;background:var(--tui-base-02);color:var(--tui-text-02);vertical-align:middle;align-items:center;border-radius:.25rem;font-weight:500;outline:1px solid var(--tui-base-04);font-size:.75rem;padding:0 .3125rem;margin:.125rem .1875rem;text-wrap:wrap}tui-notification code:not(pre code):not(.hljs):not([class*=\"language-\"]){mix-blend-mode:luminosity}a code:not(pre code):not(.hljs):not([class*=\"language-\"]){color:var(--tui-link)}button:focus code,a:focus code{background:var(--tui-base-01)}.tui-doc-page{isolation:isolate;padding-top:4rem}tui-doc-navigation.tui-doc-navigation{position:fixed;top:4rem;bottom:0;width:16.25rem;border-right:1px solid var(--tui-base-03)}@media screen and (max-width: 47.9625em){tui-doc-navigation.tui-doc-navigation{display:none}}.tui-doc-content{margin-left:16.25rem}@media screen and (max-width: 47.9625em){.tui-doc-content{margin-left:0}}.tui-doc-outlet+*{display:block}.tui-doc-night-mode-switch{margin-left:1rem}.tui-doc-night-mode-switch tui-svg{color:var(--tui-text-02)}tui-doc-code .hljs-tag{background:none}tui-doc-code .hljs{display:block;overflow-x:auto;padding:.5em;color:var(--tui-text-01);background-color:var(--tui-clear)}tui-doc-code .hljs.hljs-line-numbers{background:transparent}tui-doc-code .hljs-subst,tui-doc-code .hljs-title{font-weight:400;color:var(--tui-text-01)}tui-doc-code .hljs-property{color:var(--tui-support-14)}tui-doc-code .hljs-comment,tui-doc-code .hljs-quote{color:var(--tui-text-02);font-style:italic}tui-doc-code .hljs-meta{color:#e38162}tui-doc-code .hljs-section,tui-doc-code .hljs-name,tui-doc-code .hljs-literal,tui-doc-code .hljs-keyword,tui-doc-code .hljs-selector-tag,tui-doc-code .hljs-type,tui-doc-code .hljs-selector-id,tui-doc-code .hljs-selector-class{font-weight:700;color:var(--tui-link)}tui-doc-code .hljs-attr{color:var(--tui-link)}tui-doc-code .hljs-attribute,tui-doc-code .hljs-number,tui-doc-code .hljs-regexp,tui-doc-code .hljs-link,tui-doc-code .hljs-built_in{font-weight:700;color:var(--tui-support-06)}tui-doc-code .hljs-number,tui-doc-code .hljs-regexp,tui-doc-code .hljs-link{font-weight:400}tui-doc-code .hljs-string{color:var(--tui-positive);font-weight:700}tui-doc-code .hljs-symbol,tui-doc-code .hljs-bullet,tui-doc-code .hljs-formula{color:var(--tui-text-01);background:var(--tui-base-02);font-style:italic}tui-doc-code .hljs-doctag{text-decoration:underline}tui-doc-code .hljs-variable,tui-doc-code .hljs-template-variable{color:var(--tui-link-hover)}tui-doc-code [data-mode=onDark] .hljs-variable,tui-doc-code [data-mode=onDark] .hljs-template-variable{color:var(--tui-warning-fill)}tui-doc-code .hljs-addition{background:var(--tui-success-bg)}tui-doc-code .hljs-deletion{background:var(--tui-error-bg)}tui-doc-code .hljs-emphasis{font-style:italic}tui-doc-code .hljs-strong{font-weight:700}tui-doc-code .hljs .hljs-line-numbers{padding:0}tui-doc-code .hljs-ln-numbers{vertical-align:top;opacity:.3;text-align:right;padding-right:1em!important}\n"] }]
1725
+ }], ctorParameters: function () {
1726
+ return [{ type: undefined, decorators: [{
1727
+ type: Inject,
1728
+ args: [TUI_DOC_ICONS]
1729
+ }] }, { type: i6$1.TuiThemeService, decorators: [{
1730
+ type: Inject,
1731
+ args: [TuiThemeService]
1732
+ }] }, { type: i6$1.TuiThemeNightService, decorators: [{
1733
+ type: Inject,
1734
+ args: [TuiThemeNightService]
1735
+ }] }];
1736
+ }, propDecorators: { mode: [{
1737
+ type: HostBinding,
1738
+ args: ['attr.data-mode']
1739
+ }] } });
1740
+
1741
+ class TuiDocMainModule {
1742
+ }
1743
+ TuiDocMainModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1744
+ TuiDocMainModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainModule, declarations: [TuiDocMainComponent], imports: [CommonModule,
1745
+ RouterModule,
1746
+ TuiThemeNightModule,
1747
+ TuiDocHeaderModule,
1748
+ TuiRootModule,
1749
+ TuiDialogModule,
1750
+ TuiAlertModule,
1751
+ TuiButtonModule,
1752
+ TuiModeModule,
1753
+ TuiDocNavigationModule], exports: [TuiDocMainComponent] });
1754
+ TuiDocMainModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainModule, imports: [CommonModule,
1755
+ RouterModule,
1756
+ TuiThemeNightModule,
1757
+ TuiDocHeaderModule,
1758
+ TuiRootModule,
1759
+ TuiDialogModule,
1760
+ TuiAlertModule,
1761
+ TuiButtonModule,
1762
+ TuiModeModule,
1763
+ TuiDocNavigationModule] });
1764
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocMainModule, decorators: [{
1765
+ type: NgModule,
1766
+ args: [{
1767
+ imports: [
1768
+ CommonModule,
1769
+ RouterModule,
1770
+ TuiThemeNightModule,
1771
+ TuiDocHeaderModule,
1772
+ TuiRootModule,
1773
+ TuiDialogModule,
1774
+ TuiAlertModule,
1775
+ TuiButtonModule,
1776
+ TuiModeModule,
1777
+ TuiDocNavigationModule,
1778
+ ],
1779
+ declarations: [TuiDocMainComponent],
1780
+ exports: [TuiDocMainComponent],
1781
+ }]
1782
+ }] });
1783
+
1784
+ /**
1785
+ * Array if related page titles
1786
+ */
1787
+ const PAGE_SEE_ALSO = new InjectionToken(`[PAGE_SEE_ALSO]`);
1788
+ const PAGE_PROVIDERS = [
1789
+ {
1790
+ provide: PAGE_SEE_ALSO,
1791
+ deps: [ElementRef, TUI_DOC_SEE_ALSO],
1792
+ useFactory: ({ nativeElement }, seeAlsoGroups) => {
1793
+ const currentHeader = nativeElement.getAttribute(`header`);
1794
+ const groups = seeAlsoGroups.filter(group => group.includes(currentHeader)) || [];
1795
+ const seeAlsoSet = new Set(groups
1796
+ .join()
1797
+ .split(`,`)
1798
+ .filter(component => component && component !== currentHeader));
1799
+ return Array.from(seeAlsoSet);
1800
+ },
1801
+ },
1802
+ ];
1803
+
1804
+ class TuiDocPageTabConnectorDirective {
1805
+ constructor(template) {
1806
+ this.template = template;
1807
+ }
1808
+ }
1809
+ TuiDocPageTabConnectorDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageTabConnectorDirective, deps: [{ token: TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
1810
+ TuiDocPageTabConnectorDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocPageTabConnectorDirective, selector: "[pageTab]", inputs: { pageTab: "pageTab" }, ngImport: i0 });
1811
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageTabConnectorDirective, decorators: [{
1812
+ type: Directive,
1813
+ args: [{
1814
+ selector: '[pageTab]',
1815
+ }]
1816
+ }], ctorParameters: function () {
1817
+ return [{ type: i0.TemplateRef, decorators: [{
1818
+ type: Inject,
1819
+ args: [TemplateRef]
1820
+ }] }];
1821
+ }, propDecorators: { pageTab: [{
1822
+ type: Input
1823
+ }] } });
1824
+
1825
+ class TuiDocPageComponent {
1826
+ constructor(defaultTabs, seeAlso) {
1827
+ this.defaultTabs = defaultTabs;
1828
+ this.seeAlso = seeAlso;
1829
+ this.header = '';
1830
+ this.package = '';
1831
+ this.type = '';
1832
+ this.path = '';
1833
+ this.deprecated = false;
1834
+ this.tabConnectors = EMPTY_QUERY;
1835
+ this.activeItemIndex = 0;
1836
+ this.from = / /g;
1837
+ this.to = '_';
1838
+ }
1839
+ get showSeeAlso() {
1840
+ return !!this.seeAlso.length && this.activeItemIndex === 0;
1841
+ }
1842
+ }
1843
+ TuiDocPageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageComponent, deps: [{ token: TUI_DOC_DEFAULT_TABS }, { token: PAGE_SEE_ALSO }], target: i0.ɵɵFactoryTarget.Component });
1844
+ TuiDocPageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TuiDocPageComponent, selector: "tui-doc-page", inputs: { header: "header", package: "package", type: "type", path: "path", deprecated: "deprecated" }, providers: PAGE_PROVIDERS, queries: [{ propertyName: "tabConnectors", predicate: TuiDocPageTabConnectorDirective }], ngImport: i0, template: "<header class=\"t-header\">\n <h1 class=\"t-title\">\n {{ header }}\n <tui-tag\n *ngIf=\"!!deprecated || deprecated === ''\"\n status=\"custom\"\n value=\"deprecated\"\n class=\"t-tag t-tag_deprecated\"\n ></tui-tag>\n <tui-tag\n *ngIf=\"package\"\n status=\"custom\"\n class=\"t-tag t-tag_package\"\n [autoColor]=\"true\"\n [value]=\"package\"\n ></tui-tag>\n </h1>\n <tui-tabs-with-more\n *ngIf=\"tabConnectors.length\"\n class=\"t-tabs\"\n [(activeItemIndex)]=\"activeItemIndex\"\n >\n <ng-container *ngFor=\"let tab of tabConnectors; first as first; index as index\">\n <ng-container *ngIf=\"tab.pageTab || defaultTabs[index] as tabName\">\n <a\n *tuiItem\n routerLinkActive\n tuiTab\n [routerLink]=\"first ? './' : (tabName | tuiReplace: from : to)\"\n [routerLinkActiveOptions]=\"{exact: first}\"\n >\n {{ tabName }}\n </a>\n </ng-container>\n </ng-container>\n </tui-tabs-with-more>\n <tui-doc-source-code\n class=\"t-source-code\"\n [header]=\"header\"\n [package]=\"package\"\n [path]=\"path\"\n [type]=\"type\"\n ></tui-doc-source-code>\n</header>\n<div class=\"t-content\">\n <ng-content></ng-content>\n <tui-doc-see-also\n *ngIf=\"showSeeAlso\"\n class=\"t-see-also\"\n [seeAlso]=\"seeAlso\"\n ></tui-doc-see-also>\n <ng-container *ngFor=\"let tab of tabConnectors; index as index\">\n <ng-container\n *ngIf=\"index === activeItemIndex\"\n [ngTemplateOutlet]=\"tab.template\"\n ></ng-container>\n </ng-container>\n</div>\n", styles: [":host{display:flex;flex-direction:column;min-height:0;flex-basis:0;flex-grow:1}.t-header{display:flex;font:var(--tui-font-heading-3);flex-wrap:wrap;min-height:7.25rem;color:var(--tui-text-01);box-shadow:inset 0 -1px 0 0 var(--tui-base-03);padding:3.75rem 0 0;box-sizing:border-box;flex-shrink:0;margin:0 min(10vw,8.75rem)}:host-context(tui-root._mobile) .t-header{font:var(--tui-font-heading-4);min-height:4.5rem;padding:1.25rem 1.25rem 0;margin:0}.t-title{min-width:100%;font-size:inherit;margin:0}.t-tag{vertical-align:middle;text-transform:uppercase;margin-right:.5rem}.t-tag_deprecated{background-color:var(--tui-error-fill);color:#fff}.t-tag.t-tag_package{color:#000}.t-tabs{flex:1;margin:1.125rem .3125rem 0 0}:host-context(tui-root._mobile) .t-tabs{margin-top:.25rem}.t-content{padding:2rem 0;margin:0 min(10vw,8.75rem)}:host-context(tui-root._mobile) .t-content{padding:2rem 1.25rem;margin:0}.t-see-also{min-width:18.75rem;width:30%;float:right;margin-left:1.5rem}:host-context(tui-root._mobile) .t-see-also{float:none;width:100%;margin:0 0 1.5rem}.t-source-code{align-self:flex-end;line-height:2.75rem;margin-left:auto}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i3.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i3.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "component", type: TuiDocSeeAlsoComponent, selector: "tui-doc-see-also", inputs: ["seeAlso"] }, { kind: "component", type: i3$1.TuiTabsWithMoreComponent, selector: "tui-tabs-with-more, nav[tuiTabsWithMore]", inputs: ["moreContent", "dropdownContent", "underline", "activeItemIndex", "itemsLimit"], outputs: ["activeItemIndexChange"] }, { kind: "component", type: i3$1.TuiTabComponent, selector: "a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]" }, { kind: "directive", type: i6.TuiItemDirective, selector: "[tuiItem]" }, { kind: "component", type: i3$1.TuiTagComponent, selector: "tui-tag, a[tuiTag], button[tuiTag]", inputs: ["value", "editable", "separator", "maxLength", "size", "showLoader", "status", "hoverable", "removable", "disabled", "autoColor", "leftContent"], outputs: ["edited"] }, { kind: "component", type: TuiDocSourceCodeComponent, selector: "tui-doc-source-code", inputs: ["header", "package", "type", "path"] }, { kind: "pipe", type: i6.TuiReplacePipe, name: "tuiReplace" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1845
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageComponent, decorators: [{
1846
+ type: Component,
1847
+ args: [{ selector: 'tui-doc-page', changeDetection: ChangeDetectionStrategy.OnPush, providers: PAGE_PROVIDERS, template: "<header class=\"t-header\">\n <h1 class=\"t-title\">\n {{ header }}\n <tui-tag\n *ngIf=\"!!deprecated || deprecated === ''\"\n status=\"custom\"\n value=\"deprecated\"\n class=\"t-tag t-tag_deprecated\"\n ></tui-tag>\n <tui-tag\n *ngIf=\"package\"\n status=\"custom\"\n class=\"t-tag t-tag_package\"\n [autoColor]=\"true\"\n [value]=\"package\"\n ></tui-tag>\n </h1>\n <tui-tabs-with-more\n *ngIf=\"tabConnectors.length\"\n class=\"t-tabs\"\n [(activeItemIndex)]=\"activeItemIndex\"\n >\n <ng-container *ngFor=\"let tab of tabConnectors; first as first; index as index\">\n <ng-container *ngIf=\"tab.pageTab || defaultTabs[index] as tabName\">\n <a\n *tuiItem\n routerLinkActive\n tuiTab\n [routerLink]=\"first ? './' : (tabName | tuiReplace: from : to)\"\n [routerLinkActiveOptions]=\"{exact: first}\"\n >\n {{ tabName }}\n </a>\n </ng-container>\n </ng-container>\n </tui-tabs-with-more>\n <tui-doc-source-code\n class=\"t-source-code\"\n [header]=\"header\"\n [package]=\"package\"\n [path]=\"path\"\n [type]=\"type\"\n ></tui-doc-source-code>\n</header>\n<div class=\"t-content\">\n <ng-content></ng-content>\n <tui-doc-see-also\n *ngIf=\"showSeeAlso\"\n class=\"t-see-also\"\n [seeAlso]=\"seeAlso\"\n ></tui-doc-see-also>\n <ng-container *ngFor=\"let tab of tabConnectors; index as index\">\n <ng-container\n *ngIf=\"index === activeItemIndex\"\n [ngTemplateOutlet]=\"tab.template\"\n ></ng-container>\n </ng-container>\n</div>\n", styles: [":host{display:flex;flex-direction:column;min-height:0;flex-basis:0;flex-grow:1}.t-header{display:flex;font:var(--tui-font-heading-3);flex-wrap:wrap;min-height:7.25rem;color:var(--tui-text-01);box-shadow:inset 0 -1px 0 0 var(--tui-base-03);padding:3.75rem 0 0;box-sizing:border-box;flex-shrink:0;margin:0 min(10vw,8.75rem)}:host-context(tui-root._mobile) .t-header{font:var(--tui-font-heading-4);min-height:4.5rem;padding:1.25rem 1.25rem 0;margin:0}.t-title{min-width:100%;font-size:inherit;margin:0}.t-tag{vertical-align:middle;text-transform:uppercase;margin-right:.5rem}.t-tag_deprecated{background-color:var(--tui-error-fill);color:#fff}.t-tag.t-tag_package{color:#000}.t-tabs{flex:1;margin:1.125rem .3125rem 0 0}:host-context(tui-root._mobile) .t-tabs{margin-top:.25rem}.t-content{padding:2rem 0;margin:0 min(10vw,8.75rem)}:host-context(tui-root._mobile) .t-content{padding:2rem 1.25rem;margin:0}.t-see-also{min-width:18.75rem;width:30%;float:right;margin-left:1.5rem}:host-context(tui-root._mobile) .t-see-also{float:none;width:100%;margin:0 0 1.5rem}.t-source-code{align-self:flex-end;line-height:2.75rem;margin-left:auto}\n"] }]
1848
+ }], ctorParameters: function () {
1849
+ return [{ type: undefined, decorators: [{
1850
+ type: Inject,
1851
+ args: [TUI_DOC_DEFAULT_TABS]
1852
+ }] }, { type: undefined, decorators: [{
1853
+ type: Inject,
1854
+ args: [PAGE_SEE_ALSO]
1855
+ }] }];
1856
+ }, propDecorators: { header: [{
1857
+ type: Input
1858
+ }], package: [{
1859
+ type: Input
1860
+ }], type: [{
1861
+ type: Input
1862
+ }], path: [{
1863
+ type: Input
1864
+ }], deprecated: [{
1865
+ type: Input
1866
+ }], tabConnectors: [{
1867
+ type: ContentChildren,
1868
+ args: [TuiDocPageTabConnectorDirective]
1869
+ }] } });
1870
+
1871
+ class TuiDocPageModule {
1872
+ }
1873
+ TuiDocPageModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1874
+ TuiDocPageModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageModule, declarations: [TuiDocPageComponent, TuiDocPageTabConnectorDirective], imports: [CommonModule,
1875
+ RouterModule,
1876
+ TuiDocSeeAlsoModule,
1877
+ TuiTabsModule,
1878
+ TuiTagModule,
1879
+ TuiDocSourceCodeModule,
1880
+ TuiReplacePipeModule], exports: [TuiDocPageComponent, TuiDocPageTabConnectorDirective] });
1881
+ TuiDocPageModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageModule, imports: [CommonModule,
1882
+ RouterModule,
1883
+ TuiDocSeeAlsoModule,
1884
+ TuiTabsModule,
1885
+ TuiTagModule,
1886
+ TuiDocSourceCodeModule,
1887
+ TuiReplacePipeModule] });
1888
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TuiDocPageModule, decorators: [{
1889
+ type: NgModule,
1890
+ args: [{
1891
+ imports: [
1892
+ CommonModule,
1893
+ RouterModule,
1894
+ TuiDocSeeAlsoModule,
1895
+ TuiTabsModule,
1896
+ TuiTagModule,
1897
+ TuiDocSourceCodeModule,
1898
+ TuiReplacePipeModule,
1899
+ ],
1900
+ declarations: [TuiDocPageComponent, TuiDocPageTabConnectorDirective],
1901
+ exports: [TuiDocPageComponent, TuiDocPageTabConnectorDirective],
1902
+ }]
1903
+ }] });
1904
+
1905
+ /**
1906
+ * Generated bundle index. Do not edit.
1907
+ */
1908
+
1909
+ export { PAGE_PROVIDERS, PAGE_SEE_ALSO, TUI_DOC_EXAMPLE_DEFAULT_OPTIONS, TUI_DOC_EXAMPLE_OPTIONS, TuiDocCodeComponent, TuiDocCodeModule, TuiDocCopyComponent, TuiDocCopyModule, TuiDocDemoComponent, TuiDocDemoModule, TuiDocDocumentationComponent, TuiDocDocumentationModule, TuiDocDocumentationPropertyConnectorDirective, TuiDocExampleComponent, TuiDocExampleGetTabsPipe, TuiDocExampleModule, TuiDocHeaderComponent, TuiDocHeaderModule, TuiDocMainComponent, TuiDocMainModule, TuiDocNavigationComponent, TuiDocNavigationModule, TuiDocPageComponent, TuiDocPageModule, TuiDocPageTabConnectorDirective, TuiDocSeeAlsoComponent, TuiDocSeeAlsoModule, TuiDocSourceCodeComponent, TuiDocSourceCodeModule, TuiDocTabComponent, TuiDocTabModule, TuiDocTypeReferencePipe, TuiGetColorPipe, TuiGetOpacityPipe, TuiInputOpacityDirective, TuiInputOpacityModule, TuiInspectPipe, TuiIsOptionalPipe, TuiIsPrimitivePolymorpheusContentPipe, TuiLanguageSwitcherComponent, TuiLanguageSwitcherModule, TuiShowCleanerPipe, TuiStripOptionalPipe, tuiDocExampleOptionsProvider };
1910
+ //# sourceMappingURL=taiga-ui-addon-doc-components.mjs.map