@taiga-ui/layout 4.52.0-canary.38dfc57 → 4.52.0-canary.3915ce7

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 (54) hide show
  1. package/components/app-bar/app-bar.component.d.ts +2 -2
  2. package/components/app-bar/app-bar.directive.d.ts +2 -2
  3. package/components/block-status/block-status.component.d.ts +3 -3
  4. package/components/block-status/block-status.directive.d.ts +2 -2
  5. package/components/card/collapsed.directive.d.ts +2 -2
  6. package/components/card/large.directive.d.ts +3 -2
  7. package/components/card/medium.directive.d.ts +2 -1
  8. package/components/dynamic-header/dynamic-header-container.directive.d.ts +2 -2
  9. package/components/form/form.directive.d.ts +3 -4
  10. package/components/form/form.options.d.ts +1 -1
  11. package/components/index.d.ts +1 -2
  12. package/components/input-search/input-search.component.d.ts +4 -5
  13. package/components/item-group/item-group.directive.d.ts +3 -3
  14. package/components/navigation/aside-group.component.d.ts +6 -7
  15. package/components/navigation/aside.component.d.ts +2 -3
  16. package/components/navigation/drawer.component.d.ts +3 -3
  17. package/components/search/search-filter.component.d.ts +3 -2
  18. package/components/search/search-filters.component.d.ts +6 -8
  19. package/components/surface/index.d.ts +1 -0
  20. package/components/surface/surface.directive.d.ts +6 -0
  21. package/fesm2022/taiga-ui-layout-components-app-bar.mjs +10 -18
  22. package/fesm2022/taiga-ui-layout-components-app-bar.mjs.map +1 -1
  23. package/fesm2022/taiga-ui-layout-components-block-details.mjs +6 -9
  24. package/fesm2022/taiga-ui-layout-components-block-details.mjs.map +1 -1
  25. package/fesm2022/taiga-ui-layout-components-block-status.mjs +10 -16
  26. package/fesm2022/taiga-ui-layout-components-block-status.mjs.map +1 -1
  27. package/fesm2022/taiga-ui-layout-components-card.mjs +46 -56
  28. package/fesm2022/taiga-ui-layout-components-card.mjs.map +1 -1
  29. package/fesm2022/taiga-ui-layout-components-dynamic-header.mjs +9 -11
  30. package/fesm2022/taiga-ui-layout-components-dynamic-header.mjs.map +1 -1
  31. package/fesm2022/taiga-ui-layout-components-form.mjs +26 -28
  32. package/fesm2022/taiga-ui-layout-components-form.mjs.map +1 -1
  33. package/fesm2022/taiga-ui-layout-components-input-search.mjs +9 -17
  34. package/fesm2022/taiga-ui-layout-components-input-search.mjs.map +1 -1
  35. package/fesm2022/taiga-ui-layout-components-item-group.mjs +16 -30
  36. package/fesm2022/taiga-ui-layout-components-item-group.mjs.map +1 -1
  37. package/fesm2022/taiga-ui-layout-components-navigation.mjs +38 -54
  38. package/fesm2022/taiga-ui-layout-components-navigation.mjs.map +1 -1
  39. package/fesm2022/taiga-ui-layout-components-search.mjs +21 -40
  40. package/fesm2022/taiga-ui-layout-components-search.mjs.map +1 -1
  41. package/fesm2022/taiga-ui-layout-components-surface.mjs +33 -0
  42. package/fesm2022/taiga-ui-layout-components-surface.mjs.map +1 -0
  43. package/fesm2022/taiga-ui-layout-components.mjs +1 -2
  44. package/fesm2022/taiga-ui-layout-components.mjs.map +1 -1
  45. package/package.json +5 -9
  46. package/components/cell/cell.directive.d.ts +0 -10
  47. package/components/cell/cell.options.d.ts +0 -6
  48. package/components/cell/index.d.ts +0 -2
  49. package/components/header/header.directive.d.ts +0 -18
  50. package/components/header/index.d.ts +0 -1
  51. package/fesm2022/taiga-ui-layout-components-cell.mjs +0 -61
  52. package/fesm2022/taiga-ui-layout-components-cell.mjs.map +0 -1
  53. package/fesm2022/taiga-ui-layout-components-header.mjs +0 -60
  54. package/fesm2022/taiga-ui-layout-components-header.mjs.map +0 -1
@@ -1,14 +1,14 @@
1
1
  import * as i0 from '@angular/core';
2
- import { inject, EventEmitter, TemplateRef, Output, Input, ViewChild, ChangeDetectionStrategy, Component } from '@angular/core';
2
+ import { inject, input, model, TemplateRef, ViewChild, ChangeDetectionStrategy, Component } from '@angular/core';
3
3
  import { toSignal } from '@angular/core/rxjs-interop';
4
4
  import { tuiInjectElement, tuiIsElement, tuiContainsOrAfter } from '@taiga-ui/cdk/utils/dom';
5
5
  import { tuiGetClosestFocusable } from '@taiga-ui/cdk/utils/focus';
6
+ import { tuiCellOptionsProvider } from '@taiga-ui/core/components/cell';
6
7
  import * as i1 from '@taiga-ui/core/components/textfield';
7
8
  import { TuiTextfieldComponent, TuiWithTextfield } from '@taiga-ui/core/components/textfield';
8
9
  import { tuiIconStart } from '@taiga-ui/core/directives/icons';
9
10
  import { TuiPopupService } from '@taiga-ui/core/directives/popup';
10
11
  import { TUI_COMMON_ICONS } from '@taiga-ui/core/tokens';
11
- import { tuiCellOptionsProvider } from '@taiga-ui/layout/components/cell';
12
12
  import { TUI_INPUT_SEARCH } from '@taiga-ui/layout/tokens';
13
13
  import { PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
14
14
 
@@ -22,11 +22,11 @@ class TuiInputSearch {
22
22
  this.neighbor = this.textfield.el.nextSibling;
23
23
  this.placeholder = '';
24
24
  this.icon = tuiIconStart(inject(TUI_COMMON_ICONS).search, {});
25
- this.tuiInputSearchOpen = false;
26
- this.tuiInputSearchOpenChange = new EventEmitter();
25
+ this.tuiInputSearch = input();
26
+ this.searchOpen = model(false, { alias: 'tuiInputSearchOpen' });
27
27
  }
28
28
  ngOnChanges() {
29
- if (this.tuiInputSearchOpen) {
29
+ if (this.searchOpen()) {
30
30
  this.open();
31
31
  }
32
32
  else {
@@ -44,15 +44,13 @@ class TuiInputSearch {
44
44
  this.ref.rootNodes[0]?.insertAdjacentElement('afterbegin', this.textfield.el);
45
45
  this.el.focus({ preventScroll: true });
46
46
  this.el.placeholder = this.i18n()?.placeholder || this.el.placeholder;
47
- this.tuiInputSearchOpen = true;
48
- this.tuiInputSearchOpenChange.emit(true);
47
+ this.searchOpen.set(true);
49
48
  }
50
49
  close() {
51
50
  this.el.placeholder = this.placeholder || this.el.placeholder;
52
51
  this.parent?.insertBefore(this.textfield.el, this.neighbor);
53
52
  this.ref?.destroy();
54
- this.tuiInputSearchOpen = false;
55
- this.tuiInputSearchOpenChange.emit(false);
53
+ this.searchOpen.set(false);
56
54
  }
57
55
  onArrow() {
58
56
  tuiGetClosestFocusable({
@@ -69,7 +67,7 @@ class TuiInputSearch {
69
67
  }
70
68
  }
71
69
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputSearch, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
72
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiInputSearch, isStandalone: true, selector: "input[tuiInputSearch]", inputs: { tuiInputSearch: "tuiInputSearch", tuiInputSearchOpen: "tuiInputSearchOpen" }, outputs: { tuiInputSearchOpenChange: "tuiInputSearchOpenChange" }, host: { attributes: { "ngSkipHydration": "true" }, listeners: { "focus": "open()", "keydown.tab.prevent": "0", "keydown.arrowDown.prevent": "onArrow()" } }, providers: [tuiCellOptionsProvider({ size: 'm' })], viewQueries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }, { propertyName: "container", first: true, predicate: ["container"], descendants: true }], usesOnChanges: true, hostDirectives: [{ directive: i1.TuiWithTextfield }], ngImport: i0, template: "<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorpheusOutlet=\"tuiInputSearch\" />\n </div>\n </div>\n</ng-template>\n", styles: [".t-container{position:fixed;top:0;left:0;bottom:0;right:0;display:grid;gap:.25rem;grid-template:min-content / minmax(auto,50rem);place-content:start center;padding:.5rem;background:var(--tui-service-backdrop);box-shadow:0 0 0 5rem var(--tui-service-backdrop)}.t-container ::ng-deep>tui-textfield{background:var(--tui-background-base-alt)}.t-content{overflow:hidden}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
70
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.15", type: TuiInputSearch, isStandalone: true, selector: "input[tuiInputSearch]", inputs: { tuiInputSearch: { classPropertyName: "tuiInputSearch", publicName: "tuiInputSearch", isSignal: true, isRequired: false, transformFunction: null }, searchOpen: { classPropertyName: "searchOpen", publicName: "tuiInputSearchOpen", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { searchOpen: "tuiInputSearchOpenChange" }, host: { attributes: { "ngSkipHydration": "true" }, listeners: { "focus": "open()", "keydown.tab.prevent": "0", "keydown.arrowDown.prevent": "onArrow()" } }, providers: [tuiCellOptionsProvider({ size: 'm' })], viewQueries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }, { propertyName: "container", first: true, predicate: ["container"], descendants: true }], usesOnChanges: true, hostDirectives: [{ directive: i1.TuiWithTextfield }], ngImport: i0, template: "<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorpheusOutlet=\"tuiInputSearch()\" />\n </div>\n </div>\n</ng-template>\n", styles: [".t-container{position:fixed;top:0;left:0;bottom:0;right:0;display:grid;gap:.25rem;grid-template:min-content / minmax(auto,50rem);place-content:start center;padding:.5rem;background:var(--tui-service-backdrop);box-shadow:0 0 0 5rem var(--tui-service-backdrop)}.t-container ::ng-deep>tui-textfield{background:var(--tui-background-base-alt)}.t-content{overflow:hidden}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
73
71
  }
74
72
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputSearch, decorators: [{
75
73
  type: Component,
@@ -78,19 +76,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
78
76
  '(focus)': 'open()',
79
77
  '(keydown.tab.prevent)': '0',
80
78
  '(keydown.arrowDown.prevent)': 'onArrow()',
81
- }, template: "<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorpheusOutlet=\"tuiInputSearch\" />\n </div>\n </div>\n</ng-template>\n", styles: [".t-container{position:fixed;top:0;left:0;bottom:0;right:0;display:grid;gap:.25rem;grid-template:min-content / minmax(auto,50rem);place-content:start center;padding:.5rem;background:var(--tui-service-backdrop);box-shadow:0 0 0 5rem var(--tui-service-backdrop)}.t-container ::ng-deep>tui-textfield{background:var(--tui-background-base-alt)}.t-content{overflow:hidden}\n"] }]
79
+ }, template: "<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorpheusOutlet=\"tuiInputSearch()\" />\n </div>\n </div>\n</ng-template>\n", styles: [".t-container{position:fixed;top:0;left:0;bottom:0;right:0;display:grid;gap:.25rem;grid-template:min-content / minmax(auto,50rem);place-content:start center;padding:.5rem;background:var(--tui-service-backdrop);box-shadow:0 0 0 5rem var(--tui-service-backdrop)}.t-container ::ng-deep>tui-textfield{background:var(--tui-background-base-alt)}.t-content{overflow:hidden}\n"] }]
82
80
  }], propDecorators: { template: [{
83
81
  type: ViewChild,
84
82
  args: [TemplateRef]
85
83
  }], container: [{
86
84
  type: ViewChild,
87
85
  args: ['container']
88
- }], tuiInputSearch: [{
89
- type: Input
90
- }], tuiInputSearchOpen: [{
91
- type: Input
92
- }], tuiInputSearchOpenChange: [{
93
- type: Output
94
86
  }] } });
95
87
 
96
88
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-layout-components-input-search.mjs","sources":["../../../projects/layout/components/input-search/input-search.component.ts","../../../projects/layout/components/input-search/input-search.component.html","../../../projects/layout/components/input-search/taiga-ui-layout-components-input-search.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n type ElementRef,\n type EmbeddedViewRef,\n EventEmitter,\n inject,\n Input,\n type OnChanges,\n Output,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {\n tuiContainsOrAfter,\n tuiInjectElement,\n tuiIsElement,\n} from '@taiga-ui/cdk/utils/dom';\nimport {tuiGetClosestFocusable} from '@taiga-ui/cdk/utils/focus';\nimport {\n TuiTextfieldComponent,\n TuiWithTextfield,\n} from '@taiga-ui/core/components/textfield';\nimport {tuiIconStart} from '@taiga-ui/core/directives/icons';\nimport {TuiPopupService} from '@taiga-ui/core/directives/popup';\nimport {TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {tuiCellOptionsProvider} from '@taiga-ui/layout/components/cell';\nimport {TUI_INPUT_SEARCH} from '@taiga-ui/layout/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n selector: 'input[tuiInputSearch]',\n imports: [PolymorpheusOutlet],\n templateUrl: './input-search.component.html',\n styleUrls: ['./input-search.component.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiCellOptionsProvider({size: 'm'})],\n hostDirectives: [TuiWithTextfield],\n host: {\n ngSkipHydration: 'true',\n '(focus)': 'open()',\n '(keydown.tab.prevent)': '0',\n '(keydown.arrowDown.prevent)': 'onArrow()',\n },\n})\nexport class TuiInputSearch implements OnChanges {\n @ViewChild(TemplateRef)\n private readonly template?: TemplateRef<any>;\n\n @ViewChild('container')\n private readonly container?: ElementRef<HTMLElement>;\n\n private readonly el = tuiInjectElement<HTMLInputElement>();\n private readonly service = inject(TuiPopupService);\n private readonly textfield = inject(TuiTextfieldComponent);\n private readonly i18n = toSignal(inject(TUI_INPUT_SEARCH));\n private parent = this.textfield.el.parentElement;\n private neighbor = this.textfield.el.nextSibling;\n private placeholder = '';\n private ref?: EmbeddedViewRef<unknown>;\n\n protected readonly icon = tuiIconStart(inject(TUI_COMMON_ICONS).search, {});\n\n @Input()\n public tuiInputSearch: PolymorpheusContent;\n\n @Input()\n public tuiInputSearchOpen = false;\n\n @Output()\n public readonly tuiInputSearchOpenChange = new EventEmitter<boolean>();\n\n public ngOnChanges(): void {\n if (this.tuiInputSearchOpen) {\n this.open();\n } else {\n this.close();\n }\n }\n\n public open(): void {\n if (this.ref?.destroyed === false || !this.template) {\n return;\n }\n\n this.placeholder = this.el.placeholder;\n this.parent = this.textfield.el.parentElement;\n this.neighbor = this.textfield.el.nextSibling;\n this.ref = this.service.addTemplate(this.template);\n this.ref.rootNodes[0]?.insertAdjacentElement('afterbegin', this.textfield.el);\n this.el.focus({preventScroll: true});\n this.el.placeholder = this.i18n()?.placeholder || this.el.placeholder;\n this.tuiInputSearchOpen = true;\n this.tuiInputSearchOpenChange.emit(true);\n }\n\n public close(): void {\n this.el.placeholder = this.placeholder || this.el.placeholder;\n this.parent?.insertBefore(this.textfield.el, this.neighbor);\n this.ref?.destroy();\n this.tuiInputSearchOpen = false;\n this.tuiInputSearchOpenChange.emit(false);\n }\n\n protected onArrow(): void {\n tuiGetClosestFocusable({\n initial: this.container?.nativeElement || this.el,\n root: this.container?.nativeElement || this.el,\n })?.focus();\n }\n\n protected onFocus({target}: Event): void {\n if (\n this.container &&\n target !== this.el &&\n tuiIsElement(target) &&\n !tuiContainsOrAfter(this.container.nativeElement, target)\n ) {\n this.close();\n }\n }\n}\n","<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorphe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SAAA,EACpC,CAAC,sBAAsB,CAAC,EAAC,IAAI,EAAE,GAAG,EAAC,CAAC,CAAC,EAChC,cAAA,EAAA,CAAC,gBAAgB,CAAC,EAC5B,IAAA,EAAA;AACF,wBAAA,eAAe,EAAE,MAAM;AACvB,wBAAA,SAAS,EAAE,QAAQ;AACnB,wBAAA,uBAAuB,EAAE,GAAG;AAC5B,wBAAA,6BAA6B,EAAE,WAAW;AAC7C,qBAAA,EAAA,QAAA,EAAA,0ZAAA,EAAA,MAAA,EAAA,CAAA,iXAAA,CAAA,EAAA;8BAIgB,QAAQ,EAAA,CAAA;sBADxB,SAAS;uBAAC,WAAW;gBAIL,SAAS,EAAA,CAAA;sBADzB,SAAS;uBAAC,WAAW;gBAef,cAAc,EAAA,CAAA;sBADpB;gBAIM,kBAAkB,EAAA,CAAA;sBADxB;gBAIe,wBAAwB,EAAA,CAAA;sBADvC;;;AEtEL;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-layout-components-input-search.mjs","sources":["../../../projects/layout/components/input-search/input-search.component.ts","../../../projects/layout/components/input-search/input-search.component.html","../../../projects/layout/components/input-search/taiga-ui-layout-components-input-search.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n type ElementRef,\n type EmbeddedViewRef,\n inject,\n input,\n model,\n type OnChanges,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {\n tuiContainsOrAfter,\n tuiInjectElement,\n tuiIsElement,\n} from '@taiga-ui/cdk/utils/dom';\nimport {tuiGetClosestFocusable} from '@taiga-ui/cdk/utils/focus';\nimport {tuiCellOptionsProvider} from '@taiga-ui/core/components/cell';\nimport {\n TuiTextfieldComponent,\n TuiWithTextfield,\n} from '@taiga-ui/core/components/textfield';\nimport {tuiIconStart} from '@taiga-ui/core/directives/icons';\nimport {TuiPopupService} from '@taiga-ui/core/directives/popup';\nimport {TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {TUI_INPUT_SEARCH} from '@taiga-ui/layout/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n selector: 'input[tuiInputSearch]',\n imports: [PolymorpheusOutlet],\n templateUrl: './input-search.component.html',\n styleUrls: ['./input-search.component.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiCellOptionsProvider({size: 'm'})],\n hostDirectives: [TuiWithTextfield],\n host: {\n ngSkipHydration: 'true',\n '(focus)': 'open()',\n '(keydown.tab.prevent)': '0',\n '(keydown.arrowDown.prevent)': 'onArrow()',\n },\n})\nexport class TuiInputSearch implements OnChanges {\n @ViewChild(TemplateRef)\n private readonly template?: TemplateRef<any>;\n\n @ViewChild('container')\n private readonly container?: ElementRef<HTMLElement>;\n\n private readonly el = tuiInjectElement<HTMLInputElement>();\n private readonly service = inject(TuiPopupService);\n private readonly textfield = inject(TuiTextfieldComponent);\n private readonly i18n = toSignal(inject(TUI_INPUT_SEARCH));\n private parent = this.textfield.el.parentElement;\n private neighbor = this.textfield.el.nextSibling;\n private placeholder = '';\n private ref?: EmbeddedViewRef<unknown>;\n\n protected readonly icon = tuiIconStart(inject(TUI_COMMON_ICONS).search, {});\n\n public readonly tuiInputSearch = input<PolymorpheusContent>();\n\n public searchOpen = model(false, {alias: 'tuiInputSearchOpen'});\n\n public ngOnChanges(): void {\n if (this.searchOpen()) {\n this.open();\n } else {\n this.close();\n }\n }\n\n public open(): void {\n if (this.ref?.destroyed === false || !this.template) {\n return;\n }\n\n this.placeholder = this.el.placeholder;\n this.parent = this.textfield.el.parentElement;\n this.neighbor = this.textfield.el.nextSibling;\n this.ref = this.service.addTemplate(this.template);\n this.ref.rootNodes[0]?.insertAdjacentElement('afterbegin', this.textfield.el);\n this.el.focus({preventScroll: true});\n this.el.placeholder = this.i18n()?.placeholder || this.el.placeholder;\n this.searchOpen.set(true);\n }\n\n public close(): void {\n this.el.placeholder = this.placeholder || this.el.placeholder;\n this.parent?.insertBefore(this.textfield.el, this.neighbor);\n this.ref?.destroy();\n this.searchOpen.set(false);\n }\n\n protected onArrow(): void {\n tuiGetClosestFocusable({\n initial: this.container?.nativeElement || this.el,\n root: this.container?.nativeElement || this.el,\n })?.focus();\n }\n\n protected onFocus({target}: Event): void {\n if (\n this.container &&\n target !== this.el &&\n tuiIsElement(target) &&\n !tuiContainsOrAfter(this.container.nativeElement, target)\n ) {\n this.close();\n }\n }\n}\n","<ng-template>\n <div\n tuiTheme=\"dark\"\n class=\"t-container\"\n (document:focusin)=\"onFocus($event)\"\n (keydown.esc)=\"close()\"\n (pointerdown.self)=\"close()\"\n >\n <div\n #container\n class=\"t-content\"\n >\n <ng-container *polymorpheusOutlet=\"tuiInputSearch()\" />\n </div>\n </div>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;MA6Ca,cAAc,CAAA;AAf3B,IAAA,WAAA,GAAA;QAsBqB,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAoB;AACzC,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,eAAe,CAAC;AACjC,QAAA,IAAA,CAAA,SAAS,GAAG,MAAM,CAAC,qBAAqB,CAAC;QACzC,IAAI,CAAA,IAAA,GAAG,QAAQ,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC;QAClD,IAAM,CAAA,MAAA,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,aAAa;QACxC,IAAQ,CAAA,QAAA,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,WAAW;QACxC,IAAW,CAAA,WAAA,GAAG,EAAE;AAGL,QAAA,IAAA,CAAA,IAAI,GAAG,YAAY,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC;QAE3D,IAAc,CAAA,cAAA,GAAG,KAAK,EAAuB;QAEtD,IAAU,CAAA,UAAA,GAAG,KAAK,CAAC,KAAK,EAA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BAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,4ZAgBA,yaDgBc,kBAAkB,EAAA,QAAA,EAAA,sBAAA,EAAA,MAAA,EAAA,CAAA,oBAAA,EAAA,2BAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FAanB,cAAc,EAAA,UAAA,EAAA,CAAA;kBAf1B,SAAS;+BACI,uBAAuB,EAAA,OAAA,EACxB,CAAC,kBAAkB,CAAC,mBAGZ,uBAAuB,CAAC,MAAM,EAAA,SAAA,EACpC,CAAC,sBAAsB,CAAC,EAAC,IAAI,EAAE,GAAG,EAAC,CAAC,CAAC,EAChC,cAAA,EAAA,CAAC,gBAAgB,CAAC,EAC5B,IAAA,EAAA;AACF,wBAAA,eAAe,EAAE,MAAM;AACvB,wBAAA,SAAS,EAAE,QAAQ;AACnB,wBAAA,uBAAuB,EAAE,GAAG;AAC5B,wBAAA,6BAA6B,EAAE,WAAW;AAC7C,qBAAA,EAAA,QAAA,EAAA,4ZAAA,EAAA,MAAA,EAAA,CAAA,iXAAA,CAAA,EAAA;8BAIgB,QAAQ,EAAA,CAAA;sBADxB,SAAS;uBAAC,WAAW;gBAIL,SAAS,EAAA,CAAA;sBADzB,SAAS;uBAAC,WAAW;;;AEjD1B;;AAEG;;;;"}
@@ -1,60 +1,46 @@
1
1
  import * as i0 from '@angular/core';
2
- import { ChangeDetectionStrategy, ViewEncapsulation, Component, Input, Directive } from '@angular/core';
2
+ import { ChangeDetectionStrategy, ViewEncapsulation, Component, input, Directive } from '@angular/core';
3
3
  import { tuiInjectElement } from '@taiga-ui/cdk/utils/dom';
4
4
  import { tuiWithStyles } from '@taiga-ui/cdk/utils/miscellaneous';
5
- import { timer, take } from 'rxjs';
6
5
 
7
- class TuiItemGroupStyles {
8
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiItemGroupStyles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
9
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiItemGroupStyles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-item-group" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiItemGroup]{display:flex;flex-wrap:wrap;--tui-item-margin: .25rem}[tuiItemGroup]>*:not(tui-items-with-more){margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._horizontal{scrollbar-width:none;-ms-overflow-style:none;flex-wrap:nowrap;overflow:scroll}[tuiItemGroup]._horizontal::-webkit-scrollbar,[tuiItemGroup]._horizontal::-webkit-scrollbar-thumb{display:none}[tuiItemGroup]._horizontal>*:not(tui-items-with-more){margin-block-end:0}[tuiItemGroup]._initialized tui-items-with-more .t-item{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:1;transform:scale(1)}[tuiItemGroup]._initialized tui-items-with-more .t-item>*{margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._initialized tui-items-with-more .t-item_hidden{opacity:0;transform:scale(.9)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
6
+ const OPTIONS = { behavior: 'smooth', block: 'nearest', inline: 'center' };
7
+ class Styles {
8
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: Styles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
9
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: Styles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-item-group" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiItemGroup]{display:flex;flex-wrap:wrap;--tui-item-margin: .25rem}[tuiItemGroup]>*:not(tui-items-with-more){margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._horizontal{scrollbar-width:none;-ms-overflow-style:none;flex-wrap:nowrap;overflow:scroll}[tuiItemGroup]._horizontal::-webkit-scrollbar,[tuiItemGroup]._horizontal::-webkit-scrollbar-thumb{display:none}[tuiItemGroup]._horizontal>*:not(tui-items-with-more){margin-block-end:0}[tuiItemGroup]._initialized tui-items-with-more .t-item{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:1;transform:scale(1)}[tuiItemGroup]._initialized tui-items-with-more .t-item>*{margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._initialized tui-items-with-more .t-item_hidden{opacity:0;transform:scale(.9)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
10
10
  }
11
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiItemGroupStyles, decorators: [{
11
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: Styles, decorators: [{
12
12
  type: Component,
13
- args: [{ standalone: true, template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
14
- class: 'tui-item-group',
15
- }, styles: ["[tuiItemGroup]{display:flex;flex-wrap:wrap;--tui-item-margin: .25rem}[tuiItemGroup]>*:not(tui-items-with-more){margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._horizontal{scrollbar-width:none;-ms-overflow-style:none;flex-wrap:nowrap;overflow:scroll}[tuiItemGroup]._horizontal::-webkit-scrollbar,[tuiItemGroup]._horizontal::-webkit-scrollbar-thumb{display:none}[tuiItemGroup]._horizontal>*:not(tui-items-with-more){margin-block-end:0}[tuiItemGroup]._initialized tui-items-with-more .t-item{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:1;transform:scale(1)}[tuiItemGroup]._initialized tui-items-with-more .t-item>*{margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._initialized tui-items-with-more .t-item_hidden{opacity:0;transform:scale(.9)}\n"] }]
13
+ args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'tui-item-group' }, styles: ["[tuiItemGroup]{display:flex;flex-wrap:wrap;--tui-item-margin: .25rem}[tuiItemGroup]>*:not(tui-items-with-more){margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._horizontal{scrollbar-width:none;-ms-overflow-style:none;flex-wrap:nowrap;overflow:scroll}[tuiItemGroup]._horizontal::-webkit-scrollbar,[tuiItemGroup]._horizontal::-webkit-scrollbar-thumb{display:none}[tuiItemGroup]._horizontal>*:not(tui-items-with-more){margin-block-end:0}[tuiItemGroup]._initialized tui-items-with-more .t-item{transition-property:transform,opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:1;transform:scale(1)}[tuiItemGroup]._initialized tui-items-with-more .t-item>*{margin:0 var(--tui-item-margin) var(--tui-item-margin) 0}[tuiItemGroup]._initialized tui-items-with-more .t-item_hidden{opacity:0;transform:scale(.9)}\n"] }]
16
14
  }] });
17
15
  class TuiItemGroup {
18
16
  constructor() {
19
17
  this.el = tuiInjectElement();
20
- this.nothing = tuiWithStyles(TuiItemGroupStyles);
21
- this.horizontal = false;
22
- this.autoscroll = false;
18
+ this.nothing = tuiWithStyles(Styles);
19
+ this.horizontal = input(false);
20
+ this.autoscroll = input(false);
23
21
  }
24
22
  ngAfterViewInit() {
25
23
  this.el.classList.add('_initialized');
26
24
  }
27
25
  onClick(target) {
28
- if (this.autoscroll && this.horizontal) {
29
- timer(0) // Safari bug
30
- .pipe(take(1))
31
- .subscribe(() => {
32
- target.scrollIntoView({
33
- behavior: 'smooth',
34
- block: 'nearest',
35
- inline: 'center',
36
- });
37
- });
26
+ if (this.autoscroll() && this.horizontal()) {
27
+ // Safari bug
28
+ setTimeout(() => target.scrollIntoView(OPTIONS));
38
29
  }
39
30
  }
40
31
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiItemGroup, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
41
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiItemGroup, isStandalone: true, selector: "[tuiItemGroup]", inputs: { horizontal: "horizontal", autoscroll: "autoscroll" }, host: { listeners: { "click": "onClick($event.target)" }, properties: { "class._horizontal": "horizontal" } }, ngImport: i0 }); }
32
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.15", type: TuiItemGroup, isStandalone: true, selector: "[tuiItemGroup]", inputs: { horizontal: { classPropertyName: "horizontal", publicName: "horizontal", isSignal: true, isRequired: false, transformFunction: null }, autoscroll: { classPropertyName: "autoscroll", publicName: "autoscroll", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "onClick($event.target)" }, properties: { "class._horizontal": "horizontal()" } }, ngImport: i0 }); }
42
33
  }
43
34
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiItemGroup, decorators: [{
44
35
  type: Directive,
45
36
  args: [{
46
- standalone: true,
47
37
  selector: '[tuiItemGroup]',
48
38
  host: {
49
39
  '(click)': 'onClick($event.target)',
50
- '[class._horizontal]': 'horizontal',
40
+ '[class._horizontal]': 'horizontal()',
51
41
  },
52
42
  }]
53
- }], propDecorators: { horizontal: [{
54
- type: Input
55
- }], autoscroll: [{
56
- type: Input
57
- }] } });
43
+ }] });
58
44
 
59
45
  /**
60
46
  * Generated bundle index. Do not edit.
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-layout-components-item-group.mjs","sources":["../../../projects/layout/components/item-group/item-group.directive.ts","../../../projects/layout/components/item-group/taiga-ui-layout-components-item-group.ts"],"sourcesContent":["import {\n type AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n Directive,\n Input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {take, timer} from 'rxjs';\n\n@Component({\n standalone: true,\n template: '',\n styleUrls: ['./item-group.styles.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tui-item-group',\n },\n})\nclass TuiItemGroupStyles {}\n\n@Directive({\n standalone: true,\n selector: '[tuiItemGroup]',\n host: {\n '(click)': 'onClick($event.target)',\n '[class._horizontal]': 'horizontal',\n },\n})\nexport class TuiItemGroup implements AfterViewInit {\n private readonly el = tuiInjectElement();\n protected readonly nothing = tuiWithStyles(TuiItemGroupStyles);\n\n @Input()\n public horizontal = false;\n\n @Input()\n public autoscroll = false;\n\n public ngAfterViewInit(): void {\n this.el.classList.add('_initialized');\n }\n\n protected onClick(target: HTMLElement): void {\n if (this.autoscroll && this.horizontal) {\n timer(0) // Safari bug\n .pipe(take(1))\n .subscribe(() => {\n target.scrollIntoView({\n behavior: 'smooth',\n block: 'nearest',\n inline: 'center',\n });\n });\n }\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAYA,MAUM,kBAAkB,CAAA;+GAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,kBAAkB,oHARV,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,42BAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAA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A,UAAA,EAAA,YAAA,EAAA,UAAA,EAAA,YAAA,EAAA,EAAA,IAAA,EAAA,EAAA,SAAA,EAAA,EAAA,OAAA,EAAA,wBAAA,EAAA,EAAA,UAAA,EAAA,EAAA,mBAAA,EAAA,YAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAZ,YAAY,EAAA,UAAA,EAAA,CAAA;kBARxB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,gBAAgB;AAC1B,oBAAA,IAAI,EAAE;AACF,wBAAA,SAAS,EAAE,wBAAwB;AACnC,wBAAA,qBAAqB,EAAE,YAAY;AACtC,qBAAA;AACJ,iBAAA;8BAMU,UAAU,EAAA,CAAA;sBADhB;gBAIM,UAAU,EAAA,CAAA;sBADhB;;;ACvCL;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-layout-components-item-group.mjs","sources":["../../../projects/layout/components/item-group/item-group.directive.ts","../../../projects/layout/components/item-group/taiga-ui-layout-components-item-group.ts"],"sourcesContent":["import {\n type AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n Directive,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\nconst OPTIONS = {behavior: 'smooth', block: 'nearest', inline: 'center'} as const;\n\n@Component({\n template: '',\n styleUrls: ['./item-group.styles.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-item-group'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiItemGroup]',\n host: {\n '(click)': 'onClick($event.target)',\n '[class._horizontal]': 'horizontal()',\n },\n})\nexport class TuiItemGroup implements AfterViewInit {\n private readonly el = tuiInjectElement();\n\n protected readonly nothing = tuiWithStyles(Styles);\n\n public readonly horizontal = input(false);\n public readonly autoscroll = input(false);\n\n public ngAfterViewInit(): void {\n this.el.classList.add('_initialized');\n }\n\n protected onClick(target: HTMLElement): void {\n if (this.autoscroll() && this.horizontal()) {\n // Safari bug\n setTimeout(() => target.scrollIntoView(OPTIONS));\n }\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAWA,MAAM,OAAO,GAAG,EAAC,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAU;AAEjF,MAOM,MAAM,CAAA;+GAAN,MAAM,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAN,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,MAAM,oHANE,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,42BAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAMV,MAAM,EAAA,UAAA,EAAA,CAAA;kBAPX,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAE,EAEG,aAAA,EAAA,iBAAiB,CAAC,IAAI,EACpB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACzC,IAAA,EAAA,EAAC,KAAK,EAAE,gBAAgB,EAAC,EAAA,MAAA,EAAA,CAAA,42BAAA,CAAA,EAAA;;MAWtB,YAAY,CAAA;AAPzB,IAAA,WAAA,GAAA;QAQqB,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAErB,QAAA,IAAA,CAAA,OAAO,GAAG,aAAa,CAAC,MAAM,CAA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AAA,qBAAqB,EAAE,cAAc;AACxC,qBAAA;AACJ,iBAAA;;;AC5BD;;AAEG;;;;"}
@@ -1,27 +1,25 @@
1
1
  import * as i0 from '@angular/core';
2
- import { signal, Input, ChangeDetectionStrategy, ViewEncapsulation, Component, inject, computed, TemplateRef, Output, ContentChild, ViewChild, Directive } from '@angular/core';
3
- import * as i3$1 from '@taiga-ui/core/components/button';
2
+ import { input, ChangeDetectionStrategy, ViewEncapsulation, Component, viewChild, contentChild, inject, TemplateRef, computed, effect, model, Directive, signal } from '@angular/core';
3
+ import * as i3 from '@taiga-ui/core/components/button';
4
4
  import { tuiButtonOptionsProvider, TuiButton } from '@taiga-ui/core/components/button';
5
5
  import { TuiScrollable, TuiScrollbar } from '@taiga-ui/core/components/scrollbar';
6
6
  import * as i1 from '@taiga-ui/core/directives/dropdown';
7
7
  import { tuiDropdownOptionsProvider, TuiDropdownDirective, TuiDropdownHover, TuiDropdownPositionSided, TuiDropdownOpen, TuiDropdownManual, TUI_DROPDOWN_OPTIONS, tuiDropdown, TUI_DROPDOWN_COMPONENT, TuiWithDropdownOpen } from '@taiga-ui/core/directives/dropdown';
8
+ import * as i1$1 from '@taiga-ui/core/directives/hint';
9
+ import { tuiHintOptionsProvider, TuiHintDirective } from '@taiga-ui/core/directives/hint';
8
10
  import { TuiFade } from '@taiga-ui/kit/directives/fade';
9
- import { toObservable, toSignal } from '@angular/core/rxjs-interop';
10
- import { tuiDirectiveBinding, tuiSetSignal } from '@taiga-ui/cdk/utils/miscellaneous';
11
+ import { tuiSetSignal, tuiDirectiveBinding } from '@taiga-ui/cdk/utils/miscellaneous';
11
12
  import * as i2 from '@taiga-ui/core/components/data-list';
12
13
  import { tuiAsDataListHost, TuiDataList, TuiDataListComponent } from '@taiga-ui/core/components/data-list';
13
- import * as i3 from '@taiga-ui/core/components/expand';
14
14
  import { TuiExpand } from '@taiga-ui/core/components/expand';
15
15
  import { TuiChevron, TUI_CHEVRON } from '@taiga-ui/kit/directives/chevron';
16
16
  import { PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
17
- import { skip } from 'rxjs';
17
+ import { toSignal } from '@angular/core/rxjs-interop';
18
18
  import * as i4 from '@angular/router';
19
19
  import { RouterLink, RouterLinkActive } from '@angular/router';
20
20
  import { TuiIcons } from '@taiga-ui/core/directives/icons';
21
21
  import { TUI_COMMON_ICONS, TUI_ICON_END, TUI_ANIMATIONS_SPEED } from '@taiga-ui/core/tokens';
22
22
  import { tuiInjectElement, tuiIsHTMLElement } from '@taiga-ui/cdk/utils/dom';
23
- import * as i1$1 from '@taiga-ui/core/directives/hint';
24
- import { TuiHintDirective, tuiHintOptionsProvider } from '@taiga-ui/core/directives/hint';
25
23
  import * as i1$2 from '@taiga-ui/cdk/directives/active-zone';
26
24
  import { TuiActiveZone } from '@taiga-ui/cdk/directives/active-zone';
27
25
  import * as i2$1 from '@taiga-ui/cdk/directives/animated';
@@ -38,14 +36,11 @@ import { tuiBreadcrumbsOptionsProvider } from '@taiga-ui/kit/components/breadcru
38
36
 
39
37
  class TuiAsideComponent {
40
38
  constructor() {
41
- // TODO: refactor to signal inputs after Angular update
42
- this.expanded = signal(false);
43
- }
44
- set tuiNavigationAside(expanded) {
45
- this.expanded.set(expanded);
39
+ this.expanded = input(false, { alias: 'tuiNavigationAside' });
46
40
  }
47
41
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiAsideComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
48
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiAsideComponent, isStandalone: true, selector: "aside[tuiNavigationAside]", inputs: { tuiNavigationAside: "tuiNavigationAside" }, host: { attributes: { "tuiNavigationAside": "", "tuiTheme": "dark" }, properties: { "class._expanded": "expanded()" } }, providers: [
42
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.15", type: TuiAsideComponent, isStandalone: true, selector: "aside[tuiNavigationAside]", inputs: { expanded: { classPropertyName: "expanded", publicName: "tuiNavigationAside", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "tuiNavigationAside": "", "tuiTheme": "dark" }, properties: { "class._expanded": "expanded()" } }, providers: [
43
+ tuiHintOptionsProvider({ appearance: 'floating' }),
49
44
  tuiButtonOptionsProvider({ size: 's', appearance: 'flat-grayscale' }),
50
45
  tuiDropdownOptionsProvider({
51
46
  appearance: 'dropdown-navigation',
@@ -81,6 +76,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
81
76
  </tui-scrollbar>
82
77
  <ng-content select="footer" />
83
78
  `, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
79
+ tuiHintOptionsProvider({ appearance: 'floating' }),
84
80
  tuiButtonOptionsProvider({ size: 's', appearance: 'flat-grayscale' }),
85
81
  tuiDropdownOptionsProvider({
86
82
  appearance: 'dropdown-navigation',
@@ -92,29 +88,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
92
88
  tuiTheme: 'dark',
93
89
  '[class._expanded]': 'expanded()',
94
90
  }, styles: ["aside[tuiNavigationAside]{transition-property:width;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:sticky;top:3rem;left:0;z-index:1;display:flex;inset-inline-start:0;inline-size:3rem;flex-direction:column;padding:.5rem .5rem .25rem;box-sizing:border-box;background:var(--tui-theme-color, #000);color:var(--tui-text-primary)}aside[tuiNavigationAside]:before{content:\"\";position:absolute;top:0;left:100%;z-index:-1;inset-inline-start:100%;block-size:3rem;inline-size:3rem;pointer-events:none;border-top-left-radius:1.25rem;box-shadow:-1.5rem 0 var(--tui-theme-color, #000);transform:scaleX(var(--tui-inline))}aside[tuiNavigationAside]:after{content:\"\";position:fixed;top:inherit;left:0;bottom:-3rem;z-index:-1;inset-inline-start:0;inline-size:3rem;background:inherit}aside[tuiNavigationAside]._expanded{inline-size:14.375rem}aside[tuiNavigationAside]._expanded+main[tuiNavigationMain]{max-inline-size:calc(100% - 14.375rem)}aside[tuiNavigationAside] .t-nav-scrollbar{margin:0 -.25rem}aside[tuiNavigationAside] .t-nav-content{scrollbar-width:none;-ms-overflow-style:none;block-size:100%;padding:0 .25rem;overflow:auto}aside[tuiNavigationAside] .t-nav-content::-webkit-scrollbar,aside[tuiNavigationAside] .t-nav-content::-webkit-scrollbar-thumb{display:none}aside[tuiNavigationAside] tui-expand [tuiAsideItem]{padding-inline-start:2rem}aside[tuiNavigationAside] hr{background:var(--tui-border-normal);block-size:1px;margin:0 0 .25rem;border:none}aside[tuiNavigationAside] header{padding-block-end:.25rem;box-shadow:inset 0 -1px var(--tui-border-normal);margin-block-end:1rem}aside[tuiNavigationAside] footer{display:flex;flex-direction:column;flex:1}aside[tuiNavigationAside] footer:before{content:\"\";min-block-size:1.75rem;margin:0 -.5rem;flex:1;mask:linear-gradient(transparent 0,black 3rem,black calc(100% - 3rem),transparent 100%)}aside[tuiNavigationAside]+main[tuiNavigationMain]{max-inline-size:calc(100% - 3rem)}[tuiAsideItem][tuiAsideItem]{inline-size:100%;justify-content:flex-start;gap:.625rem;margin-block-end:.25rem}[tuiAsideItem][tuiAsideItem]:after{border:none!important;margin-inline-start:auto!important;color:var(--tui-text-tertiary)}[tuiAsideItem][tuiAsideItem].tui-dropdown-open,[tuiAsideItem][tuiAsideItem]._active:not(._chevron-rotated),aside[tuiNavigationAside]:not(._expanded) [tuiAsideItem][tuiAsideItem]._active{background:var(--tui-background-neutral-1-hover)}tui-dropdown[data-appearance=dropdown-navigation]{border:none;background:var(--tui-background-elevation-3);background:color-mix(in srgb,var(--tui-theme-color, #000) 80%,#fff)}tui-dropdown[data-appearance=dropdown-navigation] [tuiAsideItem]{justify-content:flex-start;margin:0;padding:0 .5rem}tui-dropdown[data-appearance=dropdown-navigation] [tuiAsideItem]._active{background:transparent}tui-dropdown[data-appearance=dropdown-navigation] [tuiAsideItem]._link:not(._custom):after{opacity:0}tui-dropdown[data-appearance=dropdown-navigation] [tuiAsideItem]._link._active:after{opacity:1}\n"] }]
95
- }], propDecorators: { tuiNavigationAside: [{
96
- type: Input
97
- }] } });
91
+ }] });
98
92
 
99
93
  class TuiAsideGroupComponent {
100
94
  constructor() {
95
+ this.datalist = viewChild('datalist');
96
+ this.chevron = contentChild(TuiChevron);
101
97
  this.aside = inject(TuiAsideComponent);
102
- this.open = signal(false);
103
- this.template = null;
98
+ this.template = contentChild(TemplateRef);
104
99
  this.expanded = computed(() => this.aside.expanded() && this.open());
105
- this.binding = tuiDirectiveBinding(TuiDropdownDirective, 'tuiDropdown', computed(() => (this.aside.expanded() ? null : this.datalist)));
106
- this.openChange = toObservable(this.open).pipe(skip(1));
100
+ this.chevronEffect = effect(() => {
101
+ const chevron = this.chevron();
102
+ if (chevron) {
103
+ tuiSetSignal(chevron.rotated, this.expanded());
104
+ }
105
+ });
106
+ this.binding = tuiDirectiveBinding(TuiDropdownDirective, 'tuiDropdown', computed(() => (this.aside.expanded() ? null : this.datalist())));
107
107
  this.size = 's';
108
+ this.open = model(false);
108
109
  }
109
- set openSetter(open) {
110
- this.toggle(open);
111
- }
112
- toggle(open = !this.open()) {
113
- this.open.set(open && this.aside.expanded());
114
- this.chevron?.chevron.set(this.open());
110
+ toggle() {
111
+ if (this.aside.expanded()) {
112
+ this.open.set(!this.open());
113
+ }
115
114
  }
116
115
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiAsideGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
117
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiAsideGroupComponent, isStandalone: true, selector: "tui-aside-group", inputs: { openSetter: ["open", "openSetter"] }, outputs: { openChange: "openChange" }, providers: [tuiAsDataListHost(TuiAsideGroupComponent)], queries: [{ propertyName: "chevron", first: true, predicate: TuiChevron, descendants: true, static: true }, { propertyName: "template", first: true, predicate: TemplateRef, descendants: true }], viewQueries: [{ propertyName: "datalist", first: true, predicate: ["datalist"], descendants: true, static: true }], hostDirectives: [{ directive: i1.TuiDropdownDirective }, { directive: i1.TuiDropdownHover }, { directive: i1.TuiDropdownPositionSided }, { directive: i1.TuiDropdownOpen }], ngImport: i0, template: "<div\n #host\n (click)=\"toggle()\"\n>\n <ng-content />\n</div>\n<tui-expand [expanded]=\"expanded()\">\n <ng-container *polymorpheusOutlet=\"template\" />\n</tui-expand>\n<ng-template #datalist>\n <tui-data-list>\n <tui-opt-group [label]=\"host.textContent\">\n <ng-container *polymorpheusOutlet=\"template\" />\n </tui-opt-group>\n </tui-data-list>\n</ng-template>\n", dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i2.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "directive", type: i2.TuiOptGroup, selector: "tui-opt-group", inputs: ["label"] }, { kind: "component", type: i3.TuiExpandComponent, selector: "tui-expand", inputs: ["async", "expanded"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
116
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.15", type: TuiAsideGroupComponent, isStandalone: true, selector: "tui-aside-group", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange" }, providers: [tuiAsDataListHost(TuiAsideGroupComponent)], queries: [{ propertyName: "chevron", first: true, predicate: TuiChevron, descendants: true, isSignal: true }, { propertyName: "template", first: true, predicate: TemplateRef, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "datalist", first: true, predicate: ["datalist"], descendants: true, isSignal: true }], hostDirectives: [{ directive: i1.TuiDropdownDirective }, { directive: i1.TuiDropdownHover }, { directive: i1.TuiDropdownPositionSided }, { directive: i1.TuiDropdownOpen }], ngImport: i0, template: "<div\n #host\n (click)=\"toggle()\"\n>\n <ng-content />\n</div>\n<tui-expand [expanded]=\"expanded()\">\n <ng-container *polymorpheusOutlet=\"template()\" />\n</tui-expand>\n<ng-template #datalist>\n <tui-data-list>\n <tui-opt-group [label]=\"host.textContent\">\n <ng-container *polymorpheusOutlet=\"template()\" />\n </tui-opt-group>\n </tui-data-list>\n</ng-template>\n", dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i2.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "directive", type: i2.TuiOptGroup, selector: "tui-opt-group", inputs: ["label"] }, { kind: "component", type: TuiExpand, selector: "tui-expand", inputs: ["expanded"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
118
117
  }
119
118
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiAsideGroupComponent, decorators: [{
120
119
  type: Component,
@@ -123,22 +122,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
123
122
  TuiDropdownHover,
124
123
  TuiDropdownPositionSided,
125
124
  TuiDropdownOpen,
126
- ], template: "<div\n #host\n (click)=\"toggle()\"\n>\n <ng-content />\n</div>\n<tui-expand [expanded]=\"expanded()\">\n <ng-container *polymorpheusOutlet=\"template\" />\n</tui-expand>\n<ng-template #datalist>\n <tui-data-list>\n <tui-opt-group [label]=\"host.textContent\">\n <ng-container *polymorpheusOutlet=\"template\" />\n </tui-opt-group>\n </tui-data-list>\n</ng-template>\n" }]
127
- }], propDecorators: { datalist: [{
128
- type: ViewChild,
129
- args: ['datalist', { static: true }]
130
- }], chevron: [{
131
- type: ContentChild,
132
- args: [TuiChevron, { static: true }]
133
- }], template: [{
134
- type: ContentChild,
135
- args: [TemplateRef]
136
- }], openChange: [{
137
- type: Output
138
- }], openSetter: [{
139
- type: Input,
140
- args: ['open']
141
- }] } });
125
+ ], template: "<div\n #host\n (click)=\"toggle()\"\n>\n <ng-content />\n</div>\n<tui-expand [expanded]=\"expanded()\">\n <ng-container *polymorpheusOutlet=\"template()\" />\n</tui-expand>\n<ng-template #datalist>\n <tui-data-list>\n <tui-opt-group [label]=\"host.textContent\">\n <ng-container *polymorpheusOutlet=\"template()\" />\n </tui-opt-group>\n </tui-data-list>\n</ng-template>\n" }]
126
+ }] });
142
127
 
143
128
  class TuiHintAsideDirective {
144
129
  constructor() {
@@ -175,7 +160,7 @@ class TuiAsideItemDirective {
175
160
  tuiAsDataListHost(TuiAsideItemDirective),
176
161
  provideIcon(),
177
162
  provideDropdown(),
178
- ], hostDirectives: [{ directive: TuiHintAsideDirective }, { directive: i1.TuiDropdownManual }, { directive: i1.TuiDropdownPositionSided }, { directive: i3$1.TuiButton }, { directive: i4.RouterLinkActive, inputs: ["routerLinkActiveOptions", "routerLinkActiveOptions"] }], ngImport: i0 }); }
163
+ ], hostDirectives: [{ directive: TuiHintAsideDirective }, { directive: i1.TuiDropdownManual }, { directive: i1.TuiDropdownPositionSided }, { directive: i3.TuiButton }, { directive: i4.RouterLinkActive, inputs: ["routerLinkActiveOptions", "routerLinkActiveOptions"] }], ngImport: i0 }); }
179
164
  }
180
165
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiAsideItemDirective, decorators: [{
181
166
  type: Directive,
@@ -268,16 +253,15 @@ class TuiDrawerDirective {
268
253
  this.icons = inject(TuiIcons);
269
254
  this.dropdown = tuiDropdown(null);
270
255
  this.open = inject(TuiDropdownOpen);
256
+ this.template = viewChild(TemplateRef);
257
+ this.ef = effect(() => this.dropdown.set(this.template()));
271
258
  }
272
259
  ngDoCheck() {
273
260
  // TODO: Refactor to tuiDirectiveBinding
274
261
  tuiSetSignal(this.icons.iconStart, this.open.tuiDropdownOpen ? this.x : '');
275
262
  }
276
- set template(template) {
277
- this.dropdown.set(template);
278
- }
279
263
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDrawerDirective, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
280
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: TuiDrawerDirective, isStandalone: true, selector: "[tuiIconButton][tuiNavigationDrawer]", providers: [
264
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.15", type: TuiDrawerDirective, isStandalone: true, selector: "[tuiIconButton][tuiNavigationDrawer]", providers: [
281
265
  tuiButtonOptionsProvider({ appearance: 'secondary-grayscale' }),
282
266
  {
283
267
  provide: TUI_ICON_END,
@@ -287,7 +271,7 @@ class TuiDrawerDirective {
287
271
  provide: TUI_DROPDOWN_COMPONENT,
288
272
  useValue: TuiDrawerComponent,
289
273
  },
290
- ], viewQueries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }], hostDirectives: [{ directive: i1.TuiDropdownDirective }, { directive: i1.TuiWithDropdownOpen }], ngImport: i0, template: '<ng-template><ng-content /></ng-template>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
274
+ ], viewQueries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true, isSignal: true }], hostDirectives: [{ directive: i1.TuiDropdownDirective }, { directive: i1.TuiWithDropdownOpen }], ngImport: i0, template: '<ng-template><ng-content /></ng-template>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
291
275
  }
292
276
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiDrawerDirective, decorators: [{
293
277
  type: Component,
@@ -310,10 +294,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
310
294
  ],
311
295
  hostDirectives: [TuiDropdownDirective, TuiWithDropdownOpen],
312
296
  }]
313
- }], propDecorators: { template: [{
314
- type: ViewChild,
315
- args: [TemplateRef]
316
- }] } });
297
+ }] });
317
298
 
318
299
  class TuiHeaderComponent {
319
300
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
@@ -324,6 +305,7 @@ class TuiHeaderComponent {
324
305
  tuiButtonOptionsProvider({ size: 's', appearance: 'flat-grayscale' }),
325
306
  tuiDropdownOptionsProvider({ appearance: 'dropdown-navigation' }),
326
307
  tuiTextfieldOptionsProvider({ size: signal('s') }),
308
+ tuiHintOptionsProvider({ appearance: 'floating' }),
327
309
  ], ngImport: i0, template: '<ng-content />', isInline: true, styles: ["header[tuiNavigationHeader][tuiNavigationHeader]{position:sticky;top:0;left:0;z-index:2;display:flex;inset-inline-start:0;block-size:3rem;inline-size:100vw;align-items:center;gap:.25rem;padding:.5rem;box-sizing:border-box;font:var(--tui-font-text-s);line-height:1rem;background:var(--tui-theme-color, #000);color:var(--tui-text-primary);box-shadow:0 -100rem 0 100rem var(--tui-theme-color, #000)}header[tuiNavigationHeader][tuiNavigationHeader]:before{content:\"\";position:absolute;top:100%;left:0;right:0;z-index:-1;block-size:3rem;pointer-events:none;box-shadow:0 -1.5rem var(--tui-theme-color, #000);border-radius:1.25rem 1.25rem 0 0}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationLogo]{padding:0 .5rem;margin:0 1rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationLogo] tui-icon{font-size:1rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]{display:flex;gap:.5rem;min-inline-size:12rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]>*:not(:last-child){flex:1 0 auto}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]>*:last-child{min-inline-size:3rem;flex:1 1 auto}header[tuiNavigationHeader][tuiNavigationHeader] [tuiButton],header[tuiNavigationHeader][tuiNavigationHeader] [tuiBadge],header[tuiNavigationHeader][tuiNavigationHeader] [tuiChip],header[tuiNavigationHeader][tuiNavigationHeader] tui-badge,header[tuiNavigationHeader][tuiNavigationHeader] tui-chip{max-inline-size:12.5rem}header[tuiNavigationHeader][tuiNavigationHeader] hr{flex:1;block-size:calc(100% + 1rem);min-inline-size:4rem;margin:-.5rem 0;border:none;flex-shrink:0;background:transparent;mask:linear-gradient(to right,transparent 0,black 3rem,black calc(100% - 3rem),transparent 100%)}header[tuiNavigationHeader][tuiNavigationHeader] hr~[tuiButton]{margin-inline-end:.5rem}header[tuiNavigationHeader][tuiNavigationHeader] tui-textfield{inline-size:12rem;margin-inline-end:1.75rem}tui-dropdown[data-appearance=dropdown-navigation]{border:none;color:var(--tui-text-primary);background:var(--tui-background-elevation-3);background:color-mix(in srgb,var(--tui-theme-color, #000) 80%,#fff)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
328
310
  }
329
311
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiHeaderComponent, decorators: [{
@@ -335,6 +317,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
335
317
  tuiButtonOptionsProvider({ size: 's', appearance: 'flat-grayscale' }),
336
318
  tuiDropdownOptionsProvider({ appearance: 'dropdown-navigation' }),
337
319
  tuiTextfieldOptionsProvider({ size: signal('s') }),
320
+ tuiHintOptionsProvider({ appearance: 'floating' }),
338
321
  ], host: {
339
322
  tuiTheme: 'dark',
340
323
  }, styles: ["header[tuiNavigationHeader][tuiNavigationHeader]{position:sticky;top:0;left:0;z-index:2;display:flex;inset-inline-start:0;block-size:3rem;inline-size:100vw;align-items:center;gap:.25rem;padding:.5rem;box-sizing:border-box;font:var(--tui-font-text-s);line-height:1rem;background:var(--tui-theme-color, #000);color:var(--tui-text-primary);box-shadow:0 -100rem 0 100rem var(--tui-theme-color, #000)}header[tuiNavigationHeader][tuiNavigationHeader]:before{content:\"\";position:absolute;top:100%;left:0;right:0;z-index:-1;block-size:3rem;pointer-events:none;box-shadow:0 -1.5rem var(--tui-theme-color, #000);border-radius:1.25rem 1.25rem 0 0}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationLogo]{padding:0 .5rem;margin:0 1rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationLogo] tui-icon{font-size:1rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]{display:flex;gap:.5rem;min-inline-size:12rem}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]>*:not(:last-child){flex:1 0 auto}header[tuiNavigationHeader][tuiNavigationHeader] [tuiNavigationSegments]>*:last-child{min-inline-size:3rem;flex:1 1 auto}header[tuiNavigationHeader][tuiNavigationHeader] [tuiButton],header[tuiNavigationHeader][tuiNavigationHeader] [tuiBadge],header[tuiNavigationHeader][tuiNavigationHeader] [tuiChip],header[tuiNavigationHeader][tuiNavigationHeader] tui-badge,header[tuiNavigationHeader][tuiNavigationHeader] tui-chip{max-inline-size:12.5rem}header[tuiNavigationHeader][tuiNavigationHeader] hr{flex:1;block-size:calc(100% + 1rem);min-inline-size:4rem;margin:-.5rem 0;border:none;flex-shrink:0;background:transparent;mask:linear-gradient(to right,transparent 0,black 3rem,black calc(100% - 3rem),transparent 100%)}header[tuiNavigationHeader][tuiNavigationHeader] hr~[tuiButton]{margin-inline-end:.5rem}header[tuiNavigationHeader][tuiNavigationHeader] tui-textfield{inline-size:12rem;margin-inline-end:1.75rem}tui-dropdown[data-appearance=dropdown-navigation]{border:none;color:var(--tui-text-primary);background:var(--tui-background-elevation-3);background:color-mix(in srgb,var(--tui-theme-color, #000) 80%,#fff)}\n"] }]
@@ -383,6 +366,7 @@ const PROVIDERS = [
383
366
  tuiLinkOptionsProvider({ appearance: 'action-grayscale' }),
384
367
  tuiTabsOptionsProvider({ size: 'm' }),
385
368
  tuiDropdownOptionsProvider({ align: 'right' }),
369
+ tuiBadgeOptionsProvider({ size: 'm' }),
386
370
  ];
387
371
  class TuiSubheaderComponent {
388
372
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiSubheaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }