@taiga-ui/core 3.14.0-dev.main-3f74fe5 → 3.14.0-dev.main-49a682e
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.
- package/bundles/taiga-ui-core-components-alert.umd.js +11 -11
- package/bundles/taiga-ui-core-components-alert.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-button.umd.js +16 -16
- package/bundles/taiga-ui-core-components-button.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-calendar.umd.js +3 -3
- package/bundles/taiga-ui-core-components-calendar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-data-list.umd.js +33 -36
- package/bundles/taiga-ui-core-components-data-list.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-dialog.umd.js +16 -16
- package/bundles/taiga-ui-core-components-dialog.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-error.umd.js +5 -5
- package/bundles/taiga-ui-core-components-error.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-expand.umd.js +14 -14
- package/bundles/taiga-ui-core-components-expand.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-group.umd.js +17 -17
- package/bundles/taiga-ui-core-components-group.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-hints-host.umd.js +4 -4
- package/bundles/taiga-ui-core-components-hints-host.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js +12 -12
- package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-label.umd.js +6 -6
- package/bundles/taiga-ui-core-components-label.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-link.umd.js +14 -14
- package/bundles/taiga-ui-core-components-link.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-loader.umd.js +5 -5
- package/bundles/taiga-ui-core-components-loader.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-notification.umd.js +10 -10
- package/bundles/taiga-ui-core-components-notification.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-calendar.umd.js +5 -5
- package/bundles/taiga-ui-core-components-primitive-calendar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-checkbox.umd.js +5 -5
- package/bundles/taiga-ui-core-components-primitive-checkbox.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-spin-button.umd.js +5 -5
- package/bundles/taiga-ui-core-components-primitive-spin-button.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-textfield.umd.js +57 -57
- package/bundles/taiga-ui-core-components-primitive-textfield.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js +4 -4
- package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-root.umd.js +6 -6
- package/bundles/taiga-ui-core-components-root.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-scroll-controls.umd.js +28 -28
- package/bundles/taiga-ui-core-components-scroll-controls.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-scrollbar.umd.js +10 -10
- package/bundles/taiga-ui-core-components-scrollbar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-svg.umd.js +18 -18
- package/bundles/taiga-ui-core-components-svg.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-theme-night.umd.js +4 -4
- package/bundles/taiga-ui-core-components-theme-night.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-tooltip.umd.js +9 -9
- package/bundles/taiga-ui-core-components-tooltip.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-dropdown.umd.js +87 -83
- package/bundles/taiga-ui-core-directives-dropdown.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-hint.umd.js +61 -61
- package/bundles/taiga-ui-core-directives-hint.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mask-accessor.umd.js +1 -1
- package/bundles/taiga-ui-core-directives-mask-accessor.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mode.umd.js +2 -2
- package/bundles/taiga-ui-core-directives-mode.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-scroll-into-view.umd.js +1 -1
- package/bundles/taiga-ui-core-directives-scroll-into-view.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-textfield-controller.umd.js +34 -34
- package/bundles/taiga-ui-core-directives-textfield-controller.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-wrapper.umd.js +9 -9
- package/bundles/taiga-ui-core-directives-wrapper.umd.js.map +1 -1
- package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js +3 -3
- package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js.map +1 -1
- package/bundles/taiga-ui-core-internal-svg-defs-host.umd.js +3 -3
- package/bundles/taiga-ui-core-internal-svg-defs-host.umd.js.map +1 -1
- package/directives/dropdown/dropdown-context.directive.d.ts +4 -4
- package/directives/dropdown/dropdown-options.directive.d.ts +3 -5
- package/directives/dropdown/dropdown.directive.d.ts +1 -1
- package/esm2015/components/alert/alert.component.js +12 -12
- package/esm2015/components/button/button.component.js +17 -17
- package/esm2015/components/calendar/calendar.component.js +4 -4
- package/esm2015/components/data-list/data-list.component.js +16 -16
- package/esm2015/components/data-list/data-list.directive.js +2 -2
- package/esm2015/components/data-list/opt-group.directive.js +5 -5
- package/esm2015/components/data-list/option/option.component.js +14 -17
- package/esm2015/components/dialog/dialog.component.js +14 -14
- package/esm2015/components/dialog/dialog.directive.js +4 -4
- package/esm2015/components/error/error.component.js +6 -6
- package/esm2015/components/expand/expand-content.directive.js +2 -2
- package/esm2015/components/expand/expand.component.js +14 -14
- package/esm2015/components/group/group-styles.component.js +4 -4
- package/esm2015/components/group/group.directive.js +15 -15
- package/esm2015/components/hints-host/hints-host.component.js +5 -5
- package/esm2015/components/hosted-dropdown/hosted-dropdown-connector.directive.js +2 -2
- package/esm2015/components/hosted-dropdown/hosted-dropdown.component.js +12 -12
- package/esm2015/components/label/label.component.js +7 -7
- package/esm2015/components/link/link.component.js +15 -15
- package/esm2015/components/loader/loader.component.js +6 -6
- package/esm2015/components/notification/notification.component.js +11 -11
- package/esm2015/components/primitive-calendar/primitive-calendar.component.js +6 -6
- package/esm2015/components/primitive-checkbox/primitive-checkbox.component.js +6 -6
- package/esm2015/components/primitive-spin-button/primitive-spin-button.component.js +6 -6
- package/esm2015/components/primitive-textfield/primitive-textfield.component.js +32 -32
- package/esm2015/components/primitive-textfield/primitive-textfield.directive.js +2 -2
- package/esm2015/components/primitive-textfield/textfield/textfield.component.js +13 -13
- package/esm2015/components/primitive-textfield/value-decoration/value-decoration.component.js +14 -14
- package/esm2015/components/primitive-year-picker/primitive-year-picker.component.js +5 -5
- package/esm2015/components/root/root.component.js +7 -7
- package/esm2015/components/scroll-controls/scroll-controls.component.js +6 -6
- package/esm2015/components/scroll-controls/scrollbar-wrapper.directive.js +2 -2
- package/esm2015/components/scroll-controls/scrollbar.directive.js +23 -23
- package/esm2015/components/scrollbar/scroll-ref.directive.js +2 -2
- package/esm2015/components/scrollbar/scrollable.directive.js +2 -2
- package/esm2015/components/scrollbar/scrollbar.component.js +9 -9
- package/esm2015/components/svg/svg.component.js +19 -19
- package/esm2015/components/theme-night/theme-night.component.js +5 -5
- package/esm2015/components/tooltip/tooltip.component.js +10 -10
- package/esm2015/directives/dropdown/dropdown-context.directive.js +16 -16
- package/esm2015/directives/dropdown/dropdown-driver.directive.js +2 -2
- package/esm2015/directives/dropdown/dropdown-host.directive.js +2 -2
- package/esm2015/directives/dropdown/dropdown-hover.directive.js +4 -4
- package/esm2015/directives/dropdown/dropdown-manual.directive.js +2 -2
- package/esm2015/directives/dropdown/dropdown-options.directive.js +19 -15
- package/esm2015/directives/dropdown/dropdown-position-sided.directive.js +12 -12
- package/esm2015/directives/dropdown/dropdown-position.directive.js +11 -11
- package/esm2015/directives/dropdown/dropdown-selection.directive.js +11 -11
- package/esm2015/directives/dropdown/dropdown.component.js +17 -17
- package/esm2015/directives/dropdown/dropdown.directive.js +7 -7
- package/esm2015/directives/hint/hint-describe.directive.js +5 -5
- package/esm2015/directives/hint/hint-driver.directive.js +2 -2
- package/esm2015/directives/hint/hint-host.directive.js +2 -2
- package/esm2015/directives/hint/hint-hover.directive.js +5 -5
- package/esm2015/directives/hint/hint-manual.directive.js +2 -2
- package/esm2015/directives/hint/hint-options.directive.js +12 -12
- package/esm2015/directives/hint/hint-pointer.directive.js +3 -3
- package/esm2015/directives/hint/hint-position.directive.js +25 -25
- package/esm2015/directives/hint/hint.component.js +10 -10
- package/esm2015/directives/hint/hint.directive.js +5 -5
- package/esm2015/directives/mask-accessor/mask-accessor.directive.js +2 -2
- package/esm2015/directives/mode/mode.directive.js +3 -3
- package/esm2015/directives/scroll-into-view/scroll-into-view.directive.js +2 -2
- package/esm2015/directives/textfield-controller/textfield-cleaner.directive.js +4 -4
- package/esm2015/directives/textfield-controller/textfield-custom-content.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-filler.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-icon-left.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-icon.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-label-outside.directive.js +4 -4
- package/esm2015/directives/textfield-controller/textfield-postfix.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-prefix.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-size.directive.js +5 -5
- package/esm2015/directives/wrapper/wrapper.directive.js +10 -10
- package/esm2015/internal/primitive-year-month-pagination/primitive-year-month-pagination.component.js +4 -4
- package/esm2015/internal/svg-defs-host/svg-defs-host.component.js +4 -4
- package/fesm2015/taiga-ui-core-components-alert.js +11 -11
- package/fesm2015/taiga-ui-core-components-alert.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-button.js +16 -16
- package/fesm2015/taiga-ui-core-components-button.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-calendar.js +3 -3
- package/fesm2015/taiga-ui-core-components-calendar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-data-list.js +33 -36
- package/fesm2015/taiga-ui-core-components-data-list.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-dialog.js +16 -16
- package/fesm2015/taiga-ui-core-components-dialog.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-error.js +5 -5
- package/fesm2015/taiga-ui-core-components-error.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-expand.js +14 -14
- package/fesm2015/taiga-ui-core-components-expand.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-group.js +17 -17
- package/fesm2015/taiga-ui-core-components-group.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-hints-host.js +4 -4
- package/fesm2015/taiga-ui-core-components-hints-host.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-hosted-dropdown.js +12 -12
- package/fesm2015/taiga-ui-core-components-hosted-dropdown.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-label.js +6 -6
- package/fesm2015/taiga-ui-core-components-label.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-link.js +14 -14
- package/fesm2015/taiga-ui-core-components-link.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-loader.js +5 -5
- package/fesm2015/taiga-ui-core-components-loader.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-notification.js +10 -10
- package/fesm2015/taiga-ui-core-components-notification.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-calendar.js +5 -5
- package/fesm2015/taiga-ui-core-components-primitive-calendar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-checkbox.js +5 -5
- package/fesm2015/taiga-ui-core-components-primitive-checkbox.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-spin-button.js +5 -5
- package/fesm2015/taiga-ui-core-components-primitive-spin-button.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-textfield.js +57 -57
- package/fesm2015/taiga-ui-core-components-primitive-textfield.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-year-picker.js +4 -4
- package/fesm2015/taiga-ui-core-components-primitive-year-picker.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-root.js +6 -6
- package/fesm2015/taiga-ui-core-components-root.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-scroll-controls.js +28 -28
- package/fesm2015/taiga-ui-core-components-scroll-controls.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-scrollbar.js +10 -10
- package/fesm2015/taiga-ui-core-components-scrollbar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-svg.js +18 -18
- package/fesm2015/taiga-ui-core-components-svg.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-theme-night.js +4 -4
- package/fesm2015/taiga-ui-core-components-theme-night.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-tooltip.js +9 -9
- package/fesm2015/taiga-ui-core-components-tooltip.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-dropdown.js +89 -84
- package/fesm2015/taiga-ui-core-directives-dropdown.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-hint.js +61 -61
- package/fesm2015/taiga-ui-core-directives-hint.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-mask-accessor.js +1 -1
- package/fesm2015/taiga-ui-core-directives-mask-accessor.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-mode.js +2 -2
- package/fesm2015/taiga-ui-core-directives-mode.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-scroll-into-view.js +1 -1
- package/fesm2015/taiga-ui-core-directives-scroll-into-view.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-textfield-controller.js +34 -34
- package/fesm2015/taiga-ui-core-directives-textfield-controller.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-wrapper.js +9 -9
- package/fesm2015/taiga-ui-core-directives-wrapper.js.map +1 -1
- package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js +3 -3
- package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js.map +1 -1
- package/fesm2015/taiga-ui-core-internal-svg-defs-host.js +3 -3
- package/fesm2015/taiga-ui-core-internal-svg-defs-host.js.map +1 -1
- package/package.json +2 -2
|
@@ -48,7 +48,7 @@ const TUI_DIALOG_PROVIDERS = [
|
|
|
48
48
|
},
|
|
49
49
|
];
|
|
50
50
|
|
|
51
|
-
const REQUIRED_ERROR = new Error(
|
|
51
|
+
const REQUIRED_ERROR = new Error('Required dialog was dismissed');
|
|
52
52
|
class TuiDialogComponent {
|
|
53
53
|
constructor(duration, isMobile, context, close$, closeWord$) {
|
|
54
54
|
this.duration = duration;
|
|
@@ -56,16 +56,16 @@ class TuiDialogComponent {
|
|
|
56
56
|
this.context = context;
|
|
57
57
|
this.closeWord$ = closeWord$;
|
|
58
58
|
this.animation = {
|
|
59
|
-
value:
|
|
59
|
+
value: '',
|
|
60
60
|
params: {
|
|
61
|
-
start:
|
|
61
|
+
start: '40px',
|
|
62
62
|
duration: this.duration,
|
|
63
63
|
},
|
|
64
64
|
};
|
|
65
65
|
this.fullscreenAnimation = {
|
|
66
|
-
value:
|
|
66
|
+
value: '',
|
|
67
67
|
params: {
|
|
68
|
-
start:
|
|
68
|
+
start: '100vh',
|
|
69
69
|
duration: this.duration,
|
|
70
70
|
},
|
|
71
71
|
};
|
|
@@ -80,7 +80,7 @@ class TuiDialogComponent {
|
|
|
80
80
|
return this.context.header;
|
|
81
81
|
}
|
|
82
82
|
get slideInTop() {
|
|
83
|
-
return this.size ===
|
|
83
|
+
return this.size === 'fullscreen' || this.size === 'page' || this.isMobile
|
|
84
84
|
? this.fullscreenAnimation
|
|
85
85
|
: this.animation;
|
|
86
86
|
}
|
|
@@ -98,9 +98,9 @@ TuiDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ver
|
|
|
98
98
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDialogComponent, decorators: [{
|
|
99
99
|
type: Component,
|
|
100
100
|
args: [{
|
|
101
|
-
selector:
|
|
102
|
-
templateUrl:
|
|
103
|
-
styleUrls: [
|
|
101
|
+
selector: 'tui-dialog',
|
|
102
|
+
templateUrl: './dialog.template.html',
|
|
103
|
+
styleUrls: ['./dialog.style.less'],
|
|
104
104
|
// So we don't force OnPush on dialog content
|
|
105
105
|
changeDetection: ChangeDetectionStrategy.Default,
|
|
106
106
|
providers: TUI_DIALOG_PROVIDERS,
|
|
@@ -123,16 +123,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
123
123
|
args: [TUI_CLOSE_WORD]
|
|
124
124
|
}] }]; }, propDecorators: { size: [{
|
|
125
125
|
type: HostBinding,
|
|
126
|
-
args: [
|
|
126
|
+
args: ['attr.data-size']
|
|
127
127
|
}], header: [{
|
|
128
128
|
type: HostBinding,
|
|
129
|
-
args: [
|
|
129
|
+
args: ['class._centered']
|
|
130
130
|
}], slideInTop: [{
|
|
131
131
|
type: HostBinding,
|
|
132
|
-
args: [
|
|
132
|
+
args: ['@tuiSlideInTop']
|
|
133
133
|
}, {
|
|
134
134
|
type: HostBinding,
|
|
135
|
-
args: [
|
|
135
|
+
args: ['@tuiFadeIn']
|
|
136
136
|
}] } });
|
|
137
137
|
|
|
138
138
|
const TUI_DIALOG_DEFAULT_OPTIONS = {
|
|
@@ -182,15 +182,15 @@ TuiDialogDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", ver
|
|
|
182
182
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiDialogDirective, decorators: [{
|
|
183
183
|
type: Directive,
|
|
184
184
|
args: [{
|
|
185
|
-
selector:
|
|
185
|
+
selector: 'ng-template[tuiDialog]',
|
|
186
186
|
providers: [
|
|
187
187
|
{
|
|
188
188
|
provide: AbstractTuiDialogService,
|
|
189
189
|
useExisting: TuiDialogService,
|
|
190
190
|
},
|
|
191
191
|
],
|
|
192
|
-
inputs: [
|
|
193
|
-
outputs: [
|
|
192
|
+
inputs: ['options: tuiDialogOptions', 'open: tuiDialog'],
|
|
193
|
+
outputs: ['openChange: tuiDialogChange'],
|
|
194
194
|
}]
|
|
195
195
|
}] });
|
|
196
196
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-dialog.js","sources":["../../../projects/core/components/dialog/dialog.providers.ts","../../../projects/core/components/dialog/dialog.component.ts","../../../projects/core/components/dialog/dialog.template.html","../../../projects/core/components/dialog/dialog.tokens.ts","../../../projects/core/components/dialog/dialog.service.ts","../../../projects/core/components/dialog/dialog.directive.ts","../../../projects/core/components/dialog/dialog.module.ts","../../../projects/core/components/dialog/taiga-ui-core-components-dialog.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {ElementRef, InjectionToken, Provider} from '@angular/core';\nimport {WINDOW} from '@ng-web-apis/common';\nimport {\n tuiContainsOrAfter,\n TuiDestroyService,\n TuiDialog,\n tuiIsCurrentTarget,\n tuiIsElement,\n tuiTypedFromEvent,\n} from '@taiga-ui/cdk';\nimport {TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {tuiGetViewportWidth} from '@taiga-ui/core/utils/dom';\nimport {POLYMORPHEUS_CONTEXT} from '@tinkoff/ng-polymorpheus';\nimport {EMPTY, merge, Observable} from 'rxjs';\nimport {filter, switchMapTo, take, takeUntil} from 'rxjs/operators';\n\nexport const TUI_DIALOGS_CLOSE = new InjectionToken<Observable<unknown>>(\n `[TUI_DIALOGS_CLOSE]: A stream to close dialogs`,\n {\n factory: () => EMPTY,\n },\n);\n\nconst SCROLLBAR_PLACEHOLDER = 17;\n\nexport const TUI_DIALOG_CLOSE_STREAM = new InjectionToken<Observable<unknown>>(\n `[TUI_DIALOG_CLOSE_STREAM]: Dialogs closing stream`,\n);\nexport const TUI_DIALOG_PROVIDERS: Provider[] = [\n TuiDestroyService,\n {\n provide: TUI_DIALOG_CLOSE_STREAM,\n deps: [\n DOCUMENT,\n WINDOW,\n ElementRef,\n TUI_DIALOGS_CLOSE,\n TuiDestroyService,\n POLYMORPHEUS_CONTEXT,\n ],\n useFactory: (\n documentRef: Document,\n windowRef: Window,\n {nativeElement}: ElementRef<HTMLElement>,\n close$: Observable<void>,\n destroy$: Observable<void>,\n {dismissible}: TuiDialog<TuiDialogOptions<unknown>, unknown>,\n ): Observable<unknown> => {\n return dismissible\n ? merge(\n tuiTypedFromEvent(nativeElement, `click`).pipe(\n filter(tuiIsCurrentTarget),\n ),\n tuiTypedFromEvent(documentRef, `keydown`).pipe(\n filter(\n ({key, target}) =>\n key === `Escape` &&\n tuiIsElement(target) &&\n (!tuiContainsOrAfter(nativeElement, target) ||\n nativeElement.contains(target)),\n ),\n ),\n tuiTypedFromEvent(documentRef, `mousedown`).pipe(\n filter(\n ({target, clientX}) =>\n tuiIsElement(target) &&\n tuiGetViewportWidth(windowRef) - clientX >\n SCROLLBAR_PLACEHOLDER &&\n !tuiContainsOrAfter(nativeElement, target),\n ),\n switchMapTo(\n tuiTypedFromEvent(documentRef, `mouseup`).pipe(\n take(1),\n filter(\n ({target}) =>\n tuiIsElement(target) &&\n !tuiContainsOrAfter(nativeElement, target),\n ),\n ),\n ),\n ),\n close$,\n ).pipe(takeUntil(destroy$))\n : close$;\n },\n },\n];\n","import {ChangeDetectionStrategy, Component, HostBinding, Inject} from '@angular/core';\nimport {TUI_IS_MOBILE, TuiDialog} from '@taiga-ui/cdk';\nimport {tuiFadeIn, tuiSlideInTop} from '@taiga-ui/core/animations';\nimport {TuiAnimationOptions, TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {TUI_ANIMATIONS_DURATION, TUI_CLOSE_WORD} from '@taiga-ui/core/tokens';\nimport {TuiDialogSize} from '@taiga-ui/core/types';\nimport {POLYMORPHEUS_CONTEXT, PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\nimport {Observable} from 'rxjs';\n\nimport {TUI_DIALOG_CLOSE_STREAM, TUI_DIALOG_PROVIDERS} from './dialog.providers';\n\nconst REQUIRED_ERROR = new Error(`Required dialog was dismissed`);\n\n@Component({\n selector: `tui-dialog`,\n templateUrl: `./dialog.template.html`,\n styleUrls: [`./dialog.style.less`],\n // So we don't force OnPush on dialog content\n changeDetection: ChangeDetectionStrategy.Default,\n providers: TUI_DIALOG_PROVIDERS,\n animations: [tuiSlideInTop, tuiFadeIn],\n})\nexport class TuiDialogComponent<O, I> {\n private readonly animation = {\n value: ``,\n params: {\n start: `40px`,\n duration: this.duration,\n },\n } as const;\n\n private readonly fullscreenAnimation = {\n value: ``,\n params: {\n start: `100vh`,\n duration: this.duration,\n },\n } as const;\n\n constructor(\n @Inject(TUI_ANIMATIONS_DURATION) private readonly duration: number,\n @Inject(TUI_IS_MOBILE) private readonly isMobile: boolean,\n @Inject(POLYMORPHEUS_CONTEXT)\n readonly context: TuiDialog<TuiDialogOptions<I>, O>,\n @Inject(TUI_DIALOG_CLOSE_STREAM)\n close$: Observable<unknown>,\n @Inject(TUI_CLOSE_WORD) readonly closeWord$: Observable<string>,\n ) {\n close$.subscribe(() => {\n this.close();\n });\n }\n\n @HostBinding(`attr.data-size`)\n get size(): TuiDialogSize {\n return this.context.size;\n }\n\n @HostBinding(`class._centered`)\n get header(): PolymorpheusContent<TuiDialog<TuiDialogOptions<I>, O>> {\n return this.context.header;\n }\n\n @HostBinding(`@tuiSlideInTop`)\n @HostBinding(`@tuiFadeIn`)\n get slideInTop(): TuiAnimationOptions {\n return this.size === `fullscreen` || this.size === `page` || this.isMobile\n ? this.fullscreenAnimation\n : this.animation;\n }\n\n close(): void {\n if (this.context.required) {\n this.context.$implicit.error(REQUIRED_ERROR);\n } else {\n this.context.$implicit.complete();\n }\n }\n}\n","<header\n *ngIf=\"header\"\n class=\"t-header\"\n>\n <ng-container *polymorpheusOutlet=\"header as text; context: context\">\n {{ text }}\n </ng-container>\n</header>\n<div class=\"t-content\">\n <h2\n class=\"t-heading\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <!-- TODO: Polymorpheus fix type -->\n <ng-container *polymorpheusOutlet=\"$any(context.content) as text; context: context\">\n {{ text }}\n <div class=\"t-buttons\">\n <button\n tuiButton\n size=\"m\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ $any(context.data)?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div\n *ngIf=\"context.closeable\"\n class=\"t-wrapper\"\n>\n <button\n tuiIconButton\n tuiPreventDefault=\"mousedown\"\n automation-id=\"tui-dialog__close\"\n size=\"s\"\n appearance=\"\"\n icon=\"tuiIconCloseLarge\"\n shape=\"rounded\"\n class=\"t-close\"\n [title]=\"closeWord$ | async\"\n (click)=\"close()\"\n ></button>\n</div>\n","import {InjectionToken, ValueProvider} from '@angular/core';\nimport type {TuiDialogOptions} from '@taiga-ui/core/interfaces';\n\ntype TuiDialogDefaultOptions = Omit<TuiDialogOptions<unknown>, 'data'>;\n\nexport const TUI_DIALOG_DEFAULT_OPTIONS: TuiDialogDefaultOptions = {\n size: `m`,\n required: false,\n closeable: true,\n dismissible: true,\n label: ``,\n header: ``,\n};\n\nexport const TUI_DIALOG_OPTIONS = new InjectionToken<TuiDialogDefaultOptions>(\n `[TUI_DIALOG_OPTIONS]: Default parameters for dialog component`,\n {\n factory: () => TUI_DIALOG_DEFAULT_OPTIONS,\n },\n);\n\nexport function tuiDialogOptionsProvider(\n options: Partial<TuiDialogDefaultOptions>,\n): ValueProvider {\n return {\n provide: TUI_DIALOG_OPTIONS,\n useValue: {...TUI_DIALOG_DEFAULT_OPTIONS, ...options},\n };\n}\n","import {inject, Injectable} from '@angular/core';\nimport {AbstractTuiDialogService} from '@taiga-ui/cdk';\nimport type {TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {PolymorpheusComponent} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport {TUI_DIALOG_OPTIONS} from './dialog.tokens';\n\nconst DIALOG = new PolymorpheusComponent(TuiDialogComponent);\n\n@Injectable({\n providedIn: `root`,\n})\nexport class TuiDialogService extends AbstractTuiDialogService<TuiDialogOptions<any>> {\n protected readonly component = DIALOG;\n protected readonly defaultOptions: TuiDialogOptions<any> = {\n ...inject(TUI_DIALOG_OPTIONS),\n data: undefined,\n };\n}\n","import {Directive} from '@angular/core';\nimport {AbstractTuiDialogDirective, AbstractTuiDialogService} from '@taiga-ui/cdk';\nimport {TuiDialogOptions} from '@taiga-ui/core/interfaces';\n\nimport {TuiDialogService} from './dialog.service';\n\n@Directive({\n selector: `ng-template[tuiDialog]`,\n providers: [\n {\n provide: AbstractTuiDialogService,\n useExisting: TuiDialogService,\n },\n ],\n inputs: [`options: tuiDialogOptions`, `open: tuiDialog`],\n outputs: [`openChange: tuiDialogChange`],\n})\nexport class TuiDialogDirective<T> extends AbstractTuiDialogDirective<\n TuiDialogOptions<T>\n> {}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {tuiAsDialog, TuiPreventDefaultModule} from '@taiga-ui/cdk';\nimport {TuiButtonModule} from '@taiga-ui/core/components/button';\nimport {PolymorpheusModule} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport {TuiDialogDirective} from './dialog.directive';\nimport {TuiDialogService} from './dialog.service';\n\n@NgModule({\n imports: [PolymorpheusModule, TuiButtonModule, CommonModule, TuiPreventDefaultModule],\n declarations: [TuiDialogComponent, TuiDialogDirective],\n exports: [TuiDialogComponent, TuiDialogDirective],\n providers: [tuiAsDialog(TuiDialogService)],\n})\nexport class TuiDialogModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;MAiBa,iBAAiB,GAAG,IAAI,cAAc,CAC/C,gDAAgD,EAChD;AACI,IAAA,OAAO,EAAE,MAAM,KAAK;AACvB,CAAA,EACH;AAEF,MAAM,qBAAqB,GAAG,EAAE,CAAC;MAEpB,uBAAuB,GAAG,IAAI,cAAc,CACrD,CAAmD,iDAAA,CAAA,EACrD;AACW,MAAA,oBAAoB,GAAe;IAC5C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AA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,aAFb,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC,EAAA,OAAA,EAAA,CAHjC,CAAC,kBAAkB,EAAE,eAAe,EAAE,YAAY,EAAE,uBAAuB,CAAC,CAAA,EAAA,CAAA,CAAA;4FAK5E,eAAe,EAAA,UAAA,EAAA,CAAA;kBAN3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,kBAAkB,EAAE,eAAe,EAAE,YAAY,EAAE,uBAAuB,CAAC;AACrF,oBAAA,YAAY,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;AACtD,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;AACjD,oBAAA,SAAS,EAAE,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC;AAC7C,iBAAA,CAAA;;;ACfD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-dialog.js","sources":["../../../projects/core/components/dialog/dialog.providers.ts","../../../projects/core/components/dialog/dialog.component.ts","../../../projects/core/components/dialog/dialog.template.html","../../../projects/core/components/dialog/dialog.tokens.ts","../../../projects/core/components/dialog/dialog.service.ts","../../../projects/core/components/dialog/dialog.directive.ts","../../../projects/core/components/dialog/dialog.module.ts","../../../projects/core/components/dialog/taiga-ui-core-components-dialog.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {ElementRef, InjectionToken, Provider} from '@angular/core';\nimport {WINDOW} from '@ng-web-apis/common';\nimport {\n tuiContainsOrAfter,\n TuiDestroyService,\n TuiDialog,\n tuiIsCurrentTarget,\n tuiIsElement,\n tuiTypedFromEvent,\n} from '@taiga-ui/cdk';\nimport {TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {tuiGetViewportWidth} from '@taiga-ui/core/utils/dom';\nimport {POLYMORPHEUS_CONTEXT} from '@tinkoff/ng-polymorpheus';\nimport {EMPTY, merge, Observable} from 'rxjs';\nimport {filter, switchMapTo, take, takeUntil} from 'rxjs/operators';\n\nexport const TUI_DIALOGS_CLOSE = new InjectionToken<Observable<unknown>>(\n `[TUI_DIALOGS_CLOSE]: A stream to close dialogs`,\n {\n factory: () => EMPTY,\n },\n);\n\nconst SCROLLBAR_PLACEHOLDER = 17;\n\nexport const TUI_DIALOG_CLOSE_STREAM = new InjectionToken<Observable<unknown>>(\n `[TUI_DIALOG_CLOSE_STREAM]: Dialogs closing stream`,\n);\nexport const TUI_DIALOG_PROVIDERS: Provider[] = [\n TuiDestroyService,\n {\n provide: TUI_DIALOG_CLOSE_STREAM,\n deps: [\n DOCUMENT,\n WINDOW,\n ElementRef,\n TUI_DIALOGS_CLOSE,\n TuiDestroyService,\n POLYMORPHEUS_CONTEXT,\n ],\n useFactory: (\n documentRef: Document,\n windowRef: Window,\n {nativeElement}: ElementRef<HTMLElement>,\n close$: Observable<void>,\n destroy$: Observable<void>,\n {dismissible}: TuiDialog<TuiDialogOptions<unknown>, unknown>,\n ): Observable<unknown> => {\n return dismissible\n ? merge(\n tuiTypedFromEvent(nativeElement, `click`).pipe(\n filter(tuiIsCurrentTarget),\n ),\n tuiTypedFromEvent(documentRef, `keydown`).pipe(\n filter(\n ({key, target}) =>\n key === `Escape` &&\n tuiIsElement(target) &&\n (!tuiContainsOrAfter(nativeElement, target) ||\n nativeElement.contains(target)),\n ),\n ),\n tuiTypedFromEvent(documentRef, `mousedown`).pipe(\n filter(\n ({target, clientX}) =>\n tuiIsElement(target) &&\n tuiGetViewportWidth(windowRef) - clientX >\n SCROLLBAR_PLACEHOLDER &&\n !tuiContainsOrAfter(nativeElement, target),\n ),\n switchMapTo(\n tuiTypedFromEvent(documentRef, `mouseup`).pipe(\n take(1),\n filter(\n ({target}) =>\n tuiIsElement(target) &&\n !tuiContainsOrAfter(nativeElement, target),\n ),\n ),\n ),\n ),\n close$,\n ).pipe(takeUntil(destroy$))\n : close$;\n },\n },\n];\n","import {ChangeDetectionStrategy, Component, HostBinding, Inject} from '@angular/core';\nimport {TUI_IS_MOBILE, TuiDialog} from '@taiga-ui/cdk';\nimport {tuiFadeIn, tuiSlideInTop} from '@taiga-ui/core/animations';\nimport {TuiAnimationOptions, TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {TUI_ANIMATIONS_DURATION, TUI_CLOSE_WORD} from '@taiga-ui/core/tokens';\nimport {TuiDialogSize} from '@taiga-ui/core/types';\nimport {POLYMORPHEUS_CONTEXT, PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\nimport {Observable} from 'rxjs';\n\nimport {TUI_DIALOG_CLOSE_STREAM, TUI_DIALOG_PROVIDERS} from './dialog.providers';\n\nconst REQUIRED_ERROR = new Error('Required dialog was dismissed');\n\n@Component({\n selector: 'tui-dialog',\n templateUrl: './dialog.template.html',\n styleUrls: ['./dialog.style.less'],\n // So we don't force OnPush on dialog content\n changeDetection: ChangeDetectionStrategy.Default,\n providers: TUI_DIALOG_PROVIDERS,\n animations: [tuiSlideInTop, tuiFadeIn],\n})\nexport class TuiDialogComponent<O, I> {\n private readonly animation = {\n value: '',\n params: {\n start: '40px',\n duration: this.duration,\n },\n } as const;\n\n private readonly fullscreenAnimation = {\n value: '',\n params: {\n start: '100vh',\n duration: this.duration,\n },\n } as const;\n\n constructor(\n @Inject(TUI_ANIMATIONS_DURATION) private readonly duration: number,\n @Inject(TUI_IS_MOBILE) private readonly isMobile: boolean,\n @Inject(POLYMORPHEUS_CONTEXT)\n readonly context: TuiDialog<TuiDialogOptions<I>, O>,\n @Inject(TUI_DIALOG_CLOSE_STREAM)\n close$: Observable<unknown>,\n @Inject(TUI_CLOSE_WORD) readonly closeWord$: Observable<string>,\n ) {\n close$.subscribe(() => {\n this.close();\n });\n }\n\n @HostBinding('attr.data-size')\n get size(): TuiDialogSize {\n return this.context.size;\n }\n\n @HostBinding('class._centered')\n get header(): PolymorpheusContent<TuiDialog<TuiDialogOptions<I>, O>> {\n return this.context.header;\n }\n\n @HostBinding('@tuiSlideInTop')\n @HostBinding('@tuiFadeIn')\n get slideInTop(): TuiAnimationOptions {\n return this.size === 'fullscreen' || this.size === 'page' || this.isMobile\n ? this.fullscreenAnimation\n : this.animation;\n }\n\n close(): void {\n if (this.context.required) {\n this.context.$implicit.error(REQUIRED_ERROR);\n } else {\n this.context.$implicit.complete();\n }\n }\n}\n","<header\n *ngIf=\"header\"\n class=\"t-header\"\n>\n <ng-container *polymorpheusOutlet=\"header as text; context: context\">\n {{ text }}\n </ng-container>\n</header>\n<div class=\"t-content\">\n <h2\n class=\"t-heading\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <!-- TODO: Polymorpheus fix type -->\n <ng-container *polymorpheusOutlet=\"$any(context.content) as text; context: context\">\n {{ text }}\n <div class=\"t-buttons\">\n <button\n tuiButton\n size=\"m\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ $any(context.data)?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div\n *ngIf=\"context.closeable\"\n class=\"t-wrapper\"\n>\n <button\n tuiIconButton\n tuiPreventDefault=\"mousedown\"\n automation-id=\"tui-dialog__close\"\n size=\"s\"\n appearance=\"\"\n icon=\"tuiIconCloseLarge\"\n shape=\"rounded\"\n class=\"t-close\"\n [title]=\"closeWord$ | async\"\n (click)=\"close()\"\n ></button>\n</div>\n","import {InjectionToken, ValueProvider} from '@angular/core';\nimport type {TuiDialogOptions} from '@taiga-ui/core/interfaces';\n\ntype TuiDialogDefaultOptions = Omit<TuiDialogOptions<unknown>, 'data'>;\n\nexport const TUI_DIALOG_DEFAULT_OPTIONS: TuiDialogDefaultOptions = {\n size: `m`,\n required: false,\n closeable: true,\n dismissible: true,\n label: ``,\n header: ``,\n};\n\nexport const TUI_DIALOG_OPTIONS = new InjectionToken<TuiDialogDefaultOptions>(\n `[TUI_DIALOG_OPTIONS]: Default parameters for dialog component`,\n {\n factory: () => TUI_DIALOG_DEFAULT_OPTIONS,\n },\n);\n\nexport function tuiDialogOptionsProvider(\n options: Partial<TuiDialogDefaultOptions>,\n): ValueProvider {\n return {\n provide: TUI_DIALOG_OPTIONS,\n useValue: {...TUI_DIALOG_DEFAULT_OPTIONS, ...options},\n };\n}\n","import {inject, Injectable} from '@angular/core';\nimport {AbstractTuiDialogService} from '@taiga-ui/cdk';\nimport type {TuiDialogOptions} from '@taiga-ui/core/interfaces';\nimport {PolymorpheusComponent} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport {TUI_DIALOG_OPTIONS} from './dialog.tokens';\n\nconst DIALOG = new PolymorpheusComponent(TuiDialogComponent);\n\n@Injectable({\n providedIn: `root`,\n})\nexport class TuiDialogService extends AbstractTuiDialogService<TuiDialogOptions<any>> {\n protected readonly component = DIALOG;\n protected readonly defaultOptions: TuiDialogOptions<any> = {\n ...inject(TUI_DIALOG_OPTIONS),\n data: undefined,\n };\n}\n","import {Directive} from '@angular/core';\nimport {AbstractTuiDialogDirective, AbstractTuiDialogService} from '@taiga-ui/cdk';\nimport {TuiDialogOptions} from '@taiga-ui/core/interfaces';\n\nimport {TuiDialogService} from './dialog.service';\n\n@Directive({\n selector: 'ng-template[tuiDialog]',\n providers: [\n {\n provide: AbstractTuiDialogService,\n useExisting: TuiDialogService,\n },\n ],\n inputs: ['options: tuiDialogOptions', 'open: tuiDialog'],\n outputs: ['openChange: tuiDialogChange'],\n})\nexport class TuiDialogDirective<T> extends AbstractTuiDialogDirective<\n TuiDialogOptions<T>\n> {}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {tuiAsDialog, TuiPreventDefaultModule} from '@taiga-ui/cdk';\nimport {TuiButtonModule} from '@taiga-ui/core/components/button';\nimport {PolymorpheusModule} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport {TuiDialogDirective} from './dialog.directive';\nimport {TuiDialogService} from './dialog.service';\n\n@NgModule({\n imports: [PolymorpheusModule, TuiButtonModule, CommonModule, TuiPreventDefaultModule],\n declarations: [TuiDialogComponent, TuiDialogDirective],\n exports: [TuiDialogComponent, TuiDialogDirective],\n providers: [tuiAsDialog(TuiDialogService)],\n})\nexport class TuiDialogModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;MAiBa,iBAAiB,GAAG,IAAI,cAAc,CAC/C,gDAAgD,EAChD;AACI,IAAA,OAAO,EAAE,MAAM,KAAK;AACvB,CAAA,EACH;AAEF,MAAM,qBAAqB,GAAG,EAAE,CAAC;MAEpB,uBAAuB,GAAG,IAAI,cAAc,CACrD,CAAmD,iDAAA,CAAA,EACrD;AACW,MAAA,oBAAoB,GAAe;IAC5C,iBAAiB;AACjB,IAAA;AACI,QAAA,OAAO,EAAE,uBAAuB;AAChC,QAAA,IAAI,EAAE;YACF,QAAQ;YACR,MAAM;YACN,UAAU;YACV,iBAAiB;YACjB,iBAAiB;YACjB,oBAAoB;AACvB,SAAA;AACD,QAAA,UAAU,EAAE,CACR,WAAqB,EACrB,SAAiB,EACjB,EAAC,aAAa,EAA0B,EACxC,MAAwB,EACxB,QAA0B,EAC1B,EAAC,WAAW,EAAgD,KACvC;AACrB,YAAA,OAAO,WAAW;AACd,kBAAE,KAAK,CACD,iBAAiB,CAAC,aAAa,EAAE,CAAO,KAAA,CAAA,CAAC,CAAC,IAAI,CAC1C,MAAM,CAAC,kBAAkB,CAAC,CAC7B,EACD,iBAAiB,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC,IAAI,CAC1C,MAAM,CACF,CAAC,EAAC,GAAG,EAAE,MAAM,EAAC,KACV,GAAG,KAAK,CAAQ,MAAA,CAAA;oBAChB,YAAY,CAAC,MAAM,CAAC;AACpB,qBAAC,CAAC,kBAAkB,CAAC,aAAa,EAAE,MAAM,CAAC;AACvC,wBAAA,aAAa,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC,CAC1C,CACJ,EACD,iBAA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,EAAA,eAAe,EAJT,YAAA,EAAA,CAAA,kBAAkB,EAAE,kBAAkB,aAD3C,kBAAkB,EAAE,eAAe,EAAE,YAAY,EAAE,uBAAuB,CAE1E,EAAA,OAAA,EAAA,CAAA,kBAAkB,EAAE,kBAAkB,CAAA,EAAA,CAAA,CAAA;AAGvC,eAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,aAFb,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC,EAAA,OAAA,EAAA,CAHjC,CAAC,kBAAkB,EAAE,eAAe,EAAE,YAAY,EAAE,uBAAuB,CAAC,CAAA,EAAA,CAAA,CAAA;4FAK5E,eAAe,EAAA,UAAA,EAAA,CAAA;kBAN3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,kBAAkB,EAAE,eAAe,EAAE,YAAY,EAAE,uBAAuB,CAAC;AACrF,oBAAA,YAAY,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;AACtD,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;AACjD,oBAAA,SAAS,EAAE,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC;AAC7C,iBAAA,CAAA;;;ACfD;;AAEG;;;;"}
|
|
@@ -17,7 +17,7 @@ class TuiErrorComponent {
|
|
|
17
17
|
this.mode$ = mode$;
|
|
18
18
|
this.defaultErrorMessage$ = defaultErrorMessage$;
|
|
19
19
|
this.error = null;
|
|
20
|
-
this.animation = Object.assign({ value:
|
|
20
|
+
this.animation = Object.assign({ value: '' }, this.options);
|
|
21
21
|
}
|
|
22
22
|
set errorSetter(error) {
|
|
23
23
|
this.error = tuiIsString(error) ? new TuiValidationError(error) : error;
|
|
@@ -31,9 +31,9 @@ __decorate([
|
|
|
31
31
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiErrorComponent, decorators: [{
|
|
32
32
|
type: Component,
|
|
33
33
|
args: [{
|
|
34
|
-
selector:
|
|
35
|
-
templateUrl:
|
|
36
|
-
styleUrls: [
|
|
34
|
+
selector: 'tui-error',
|
|
35
|
+
templateUrl: './error.template.html',
|
|
36
|
+
styleUrls: ['./error.style.less'],
|
|
37
37
|
providers: [MODE_PROVIDER],
|
|
38
38
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
39
39
|
animations: [tuiHeightCollapse, tuiFadeIn],
|
|
@@ -49,7 +49,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
49
49
|
args: [TUI_DEFAULT_ERROR_MESSAGE]
|
|
50
50
|
}] }]; }, propDecorators: { errorSetter: [{
|
|
51
51
|
type: Input,
|
|
52
|
-
args: [
|
|
52
|
+
args: ['error']
|
|
53
53
|
}] } });
|
|
54
54
|
|
|
55
55
|
class TuiErrorModule {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-error.js","sources":["../../../projects/core/components/error/error.component.ts","../../../projects/core/components/error/error.template.html","../../../projects/core/components/error/error.module.ts","../../../projects/core/components/error/taiga-ui-core-components-error.ts"],"sourcesContent":["import {AnimationOptions} from '@angular/animations';\nimport {ChangeDetectionStrategy, Component, Inject, Input} from '@angular/core';\nimport {tuiDefaultProp, tuiIsString, TuiValidationError} from '@taiga-ui/cdk';\nimport {tuiFadeIn, tuiHeightCollapse} from '@taiga-ui/core/animations';\nimport {MODE_PROVIDER} from '@taiga-ui/core/providers';\nimport {\n TUI_ANIMATION_OPTIONS,\n TUI_DEFAULT_ERROR_MESSAGE,\n TUI_MODE,\n} from '@taiga-ui/core/tokens';\nimport {TuiBrightness} from '@taiga-ui/core/types';\nimport {Observable} from 'rxjs';\n\n@Component({\n selector:
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-error.js","sources":["../../../projects/core/components/error/error.component.ts","../../../projects/core/components/error/error.template.html","../../../projects/core/components/error/error.module.ts","../../../projects/core/components/error/taiga-ui-core-components-error.ts"],"sourcesContent":["import {AnimationOptions} from '@angular/animations';\nimport {ChangeDetectionStrategy, Component, Inject, Input} from '@angular/core';\nimport {tuiDefaultProp, tuiIsString, TuiValidationError} from '@taiga-ui/cdk';\nimport {tuiFadeIn, tuiHeightCollapse} from '@taiga-ui/core/animations';\nimport {MODE_PROVIDER} from '@taiga-ui/core/providers';\nimport {\n TUI_ANIMATION_OPTIONS,\n TUI_DEFAULT_ERROR_MESSAGE,\n TUI_MODE,\n} from '@taiga-ui/core/tokens';\nimport {TuiBrightness} from '@taiga-ui/core/types';\nimport {Observable} from 'rxjs';\n\n@Component({\n selector: 'tui-error',\n templateUrl: './error.template.html',\n styleUrls: ['./error.style.less'],\n providers: [MODE_PROVIDER],\n changeDetection: ChangeDetectionStrategy.OnPush,\n animations: [tuiHeightCollapse, tuiFadeIn],\n})\nexport class TuiErrorComponent {\n @Input('error')\n @tuiDefaultProp()\n set errorSetter(error: TuiValidationError | string | null) {\n this.error = tuiIsString(error) ? new TuiValidationError(error) : error;\n }\n\n error: TuiValidationError | null = null;\n\n readonly animation = {value: '', ...this.options} as const;\n\n constructor(\n @Inject(TUI_ANIMATION_OPTIONS) private readonly options: AnimationOptions,\n @Inject(TUI_MODE) readonly mode$: Observable<TuiBrightness | null>,\n @Inject(TUI_DEFAULT_ERROR_MESSAGE)\n readonly defaultErrorMessage$: Observable<string>,\n ) {}\n}\n","<div\n *ngIf=\"error\"\n automation-id=\"tui-error__text\"\n class=\"t-message-text\"\n [@tuiHeightCollapse]=\"animation\"\n [@tuiFadeIn]=\"animation\"\n [class.t-message-text_light]=\"(mode$ | async) === 'onDark'\"\n>\n <ng-container\n *polymorpheusOutlet=\"error.message || (defaultErrorMessage$ | async) as text; context: error.context || {}\"\n >\n {{ text }}\n </ng-container>\n</div>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {PolymorpheusModule} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiErrorComponent} from './error.component';\n\n@NgModule({\n imports: [CommonModule, PolymorpheusModule],\n declarations: [TuiErrorComponent],\n exports: [TuiErrorComponent],\n})\nexport class TuiErrorModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAqBa,iBAAiB,CAAA;AAW1B,IAAA,WAAA,CACoD,OAAyB,EAC9C,KAAuC,EAEzD,oBAAwC,EAAA;QAHD,IAAO,CAAA,OAAA,GAAP,OAAO,CAAkB;QAC9C,IAAK,CAAA,KAAA,GAAL,KAAK,CAAkC;QAEzD,IAAoB,CAAA,oBAAA,GAApB,oBAAoB,CAAoB;QARrD,IAAK,CAAA,KAAA,GAA8B,IAAI,CAAC;QAE/B,IAAS,CAAA,SAAA,GAAG,MAAC,CAAA,MAAA,CAAA,EAAA,KAAK,EAAE,EAAE,IAAK,IAAI,CAAC,OAAO,CAAU,CAAC;KAOvD;IAbJ,IAAI,WAAW,CAAC,KAAyC,EAAA;AACrD,QAAA,IAAI,CAAC,KAAK,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,IAAI,kBAAkB,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC;KAC3E;;AALQ,iBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,EAYd,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,qBAAqB,EACrB,EAAA,EAAA,KAAA,EAAA,QAAQ,aACR,yBAAyB,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAd5B,iBAAiB,EAAA,QAAA,EAAA,WAAA,EAAA,MAAA,EAAA,EAAA,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sBAFd,KAAK;uBAAC,OAAO,CAAA;;;MEXL,cAAc,CAAA;;4GAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAd,cAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,iBAHR,iBAAiB,CAAA,EAAA,OAAA,EAAA,CADtB,YAAY,EAAE,kBAAkB,aAEhC,iBAAiB,CAAA,EAAA,CAAA,CAAA;AAElB,cAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,EAJd,OAAA,EAAA,CAAA,CAAC,YAAY,EAAE,kBAAkB,CAAC,CAAA,EAAA,CAAA,CAAA;4FAIlC,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,kBAAkB,CAAC;oBAC3C,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,OAAO,EAAE,CAAC,iBAAiB,CAAC;AAC/B,iBAAA,CAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -15,7 +15,7 @@ TuiExpandContentDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.
|
|
|
15
15
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiExpandContentDirective, decorators: [{
|
|
16
16
|
type: Directive,
|
|
17
17
|
args: [{
|
|
18
|
-
selector:
|
|
18
|
+
selector: '[tuiExpandContent]',
|
|
19
19
|
}]
|
|
20
20
|
}] });
|
|
21
21
|
|
|
@@ -75,7 +75,7 @@ class TuiExpandComponent {
|
|
|
75
75
|
}
|
|
76
76
|
onTransitionEnd(event) {
|
|
77
77
|
if (tuiIsCurrentTarget(event) &&
|
|
78
|
-
event.propertyName ===
|
|
78
|
+
event.propertyName === 'opacity' &&
|
|
79
79
|
this.state === 3 /* Animated */) {
|
|
80
80
|
this.state = 0 /* Idle */;
|
|
81
81
|
}
|
|
@@ -109,9 +109,9 @@ __decorate([
|
|
|
109
109
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiExpandComponent, decorators: [{
|
|
110
110
|
type: Component,
|
|
111
111
|
args: [{
|
|
112
|
-
selector:
|
|
113
|
-
templateUrl:
|
|
114
|
-
styleUrls: [
|
|
112
|
+
selector: 'tui-expand',
|
|
113
|
+
templateUrl: './expand.template.html',
|
|
114
|
+
styleUrls: ['./expand.style.less'],
|
|
115
115
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
116
116
|
}]
|
|
117
117
|
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef, decorators: [{
|
|
@@ -119,36 +119,36 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
119
119
|
args: [ChangeDetectorRef]
|
|
120
120
|
}] }]; }, propDecorators: { contentWrapper: [{
|
|
121
121
|
type: ViewChild,
|
|
122
|
-
args: [
|
|
122
|
+
args: ['wrapper']
|
|
123
123
|
}], async: [{
|
|
124
124
|
type: Input
|
|
125
125
|
}], expandedSetter: [{
|
|
126
126
|
type: Input,
|
|
127
|
-
args: [
|
|
127
|
+
args: ['expanded']
|
|
128
128
|
}], content: [{
|
|
129
129
|
type: ContentChild,
|
|
130
130
|
args: [TuiExpandContentDirective, { read: TemplateRef }]
|
|
131
131
|
}], expanded: [{
|
|
132
132
|
type: HostBinding,
|
|
133
|
-
args: [
|
|
133
|
+
args: ['class._expanded']
|
|
134
134
|
}, {
|
|
135
135
|
type: HostBinding,
|
|
136
|
-
args: [
|
|
136
|
+
args: ['attr.aria-expanded']
|
|
137
137
|
}], overflow: [{
|
|
138
138
|
type: HostBinding,
|
|
139
|
-
args: [
|
|
139
|
+
args: ['class._overflow']
|
|
140
140
|
}], loading: [{
|
|
141
141
|
type: HostBinding,
|
|
142
|
-
args: [
|
|
142
|
+
args: ['class._loading']
|
|
143
143
|
}], height: [{
|
|
144
144
|
type: HostBinding,
|
|
145
|
-
args: [
|
|
145
|
+
args: ['style.height.px']
|
|
146
146
|
}], onTransitionEnd: [{
|
|
147
147
|
type: HostListener,
|
|
148
|
-
args: [
|
|
148
|
+
args: ['transitionend', ['$event']]
|
|
149
149
|
}], onExpandLoaded: [{
|
|
150
150
|
type: HostListener,
|
|
151
|
-
args: [TUI_EXPAND_LOADED, [
|
|
151
|
+
args: [TUI_EXPAND_LOADED, ['$event']]
|
|
152
152
|
}] } });
|
|
153
153
|
|
|
154
154
|
class TuiExpandModule {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-expand.js","sources":["../../../projects/core/components/expand/expand-content.directive.ts","../../../projects/core/components/expand/expand.component.ts","../../../projects/core/components/expand/expand.template.html","../../../projects/core/components/expand/expand.module.ts","../../../projects/core/components/expand/taiga-ui-core-components-expand.ts"],"sourcesContent":["import {Directive} from '@angular/core';\n\n@Directive({\n selector: `[tuiExpandContent]`,\n})\nexport class TuiExpandContentDirective {}\n","import {NgIfContext} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ElementRef,\n HostBinding,\n HostListener,\n Inject,\n Input,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport {tuiDefaultProp, tuiIsCurrentTarget, tuiRequiredSetter} from '@taiga-ui/cdk';\nimport {TUI_EXPAND_LOADED} from '@taiga-ui/core/constants';\n\nimport {TuiExpandContentDirective} from './expand-content.directive';\n\nconst enum State {\n Idle,\n Loading,\n Prepared,\n Animated,\n}\n\nconst LOADER_HEIGHT = 48;\n\n@Component({\n selector: `tui-expand`,\n templateUrl: `./expand.template.html`,\n styleUrls: [`./expand.style.less`],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiExpandComponent {\n @ViewChild(`wrapper`)\n private readonly contentWrapper?: ElementRef<HTMLDivElement>;\n\n private state = State.Idle;\n\n @Input()\n @tuiDefaultProp()\n async = false;\n\n @Input(`expanded`)\n @tuiRequiredSetter()\n set expandedSetter(expanded: boolean | null) {\n if (this.expanded === null) {\n this.expanded = expanded;\n\n return;\n }\n\n if (this.state !== State.Idle) {\n this.expanded = expanded;\n this.state = State.Animated;\n\n return;\n }\n\n this.expanded = expanded;\n this.retrigger(this.async && expanded ? State.Loading : State.Animated);\n }\n\n @ContentChild(TuiExpandContentDirective, {read: TemplateRef})\n content: TemplateRef<NgIfContext<boolean>> | null = null;\n\n @HostBinding(`class._expanded`)\n @HostBinding(`attr.aria-expanded`)\n expanded: boolean | null = null;\n\n constructor(\n @Inject(ChangeDetectorRef) private readonly changeDetectorRef: ChangeDetectorRef,\n ) {}\n\n @HostBinding(`class._overflow`)\n get overflow(): boolean {\n return this.state !== State.Idle;\n }\n\n @HostBinding(`class._loading`)\n get loading(): boolean {\n return !!this.expanded && this.async && this.state === State.Loading;\n }\n\n @HostBinding(`style.height.px`)\n get height(): number | null {\n const {expanded, state, contentWrapper} = this;\n\n if (\n (expanded && state === State.Prepared) ||\n (!expanded && state === State.Animated)\n ) {\n return 0;\n }\n\n if (\n contentWrapper &&\n ((!expanded && state === State.Prepared) ||\n (expanded && state === State.Animated))\n ) {\n return contentWrapper.nativeElement.offsetHeight;\n }\n\n if (contentWrapper && expanded && state === State.Loading) {\n return Math.max(contentWrapper.nativeElement.offsetHeight, LOADER_HEIGHT);\n }\n\n return null;\n }\n\n get contentVisible(): boolean {\n return this.expanded || this.state !== State.Idle;\n }\n\n @HostListener(`transitionend`, [`$event`])\n onTransitionEnd(event: TransitionEvent): void {\n if (\n tuiIsCurrentTarget(event) &&\n event.propertyName === `opacity` &&\n this.state === State.Animated\n ) {\n this.state = State.Idle;\n }\n }\n\n @HostListener(TUI_EXPAND_LOADED, [`$event`])\n onExpandLoaded(event: Event): void {\n event.stopPropagation();\n\n if (this.state === State.Loading) {\n this.retrigger(State.Animated);\n }\n }\n\n private retrigger(state: State): void {\n this.state = State.Prepared;\n\n // We need delay to re-trigger CSS height transition from the correct number\n setTimeout(() => {\n if (this.state !== State.Prepared) {\n return;\n }\n\n this.state = state;\n this.changeDetectorRef.markForCheck();\n });\n }\n}\n","<div\n #wrapper\n class=\"t-wrapper\"\n>\n <ng-container *ngIf=\"contentVisible\">\n <ng-content></ng-content>\n <tui-loader\n *ngIf=\"async; else content\"\n size=\"l\"\n [overlay]=\"true\"\n [showLoader]=\"loading\"\n >\n <ng-container [ngTemplateOutlet]=\"content\"></ng-container>\n </tui-loader>\n </ng-container>\n</div>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {TuiLoaderModule} from '@taiga-ui/core/components/loader';\n\nimport {TuiExpandComponent} from './expand.component';\nimport {TuiExpandContentDirective} from './expand-content.directive';\n\n@NgModule({\n imports: [CommonModule, TuiLoaderModule],\n declarations: [TuiExpandComponent, TuiExpandContentDirective],\n exports: [TuiExpandComponent, TuiExpandContentDirective],\n})\nexport class TuiExpandModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;MAKa,yBAAyB,CAAA;;uHAAzB,yBAAyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;2GAAzB,yBAAyB,EAAA,QAAA,EAAA,oBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;4FAAzB,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAHrC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,CAAo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,OAAA,EAAA,CADlD,YAAY,EAAE,eAAe,CAAA,EAAA,OAAA,EAAA,CAE7B,kBAAkB,EAAE,yBAAyB,CAAA,EAAA,CAAA,CAAA;AAE9C,eAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,EAJf,OAAA,EAAA,CAAA,CAAC,YAAY,EAAE,eAAe,CAAC,CAAA,EAAA,CAAA,CAAA;4FAI/B,eAAe,EAAA,UAAA,EAAA,CAAA;kBAL3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;AACxC,oBAAA,YAAY,EAAE,CAAC,kBAAkB,EAAE,yBAAyB,CAAC;AAC7D,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,yBAAyB,CAAC;AAC3D,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-expand.js","sources":["../../../projects/core/components/expand/expand-content.directive.ts","../../../projects/core/components/expand/expand.component.ts","../../../projects/core/components/expand/expand.template.html","../../../projects/core/components/expand/expand.module.ts","../../../projects/core/components/expand/taiga-ui-core-components-expand.ts"],"sourcesContent":["import {Directive} from '@angular/core';\n\n@Directive({\n selector: '[tuiExpandContent]',\n})\nexport class TuiExpandContentDirective {}\n","import {NgIfContext} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ElementRef,\n HostBinding,\n HostListener,\n Inject,\n Input,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport {tuiDefaultProp, tuiIsCurrentTarget, tuiRequiredSetter} from '@taiga-ui/cdk';\nimport {TUI_EXPAND_LOADED} from '@taiga-ui/core/constants';\n\nimport {TuiExpandContentDirective} from './expand-content.directive';\n\nconst enum State {\n Idle,\n Loading,\n Prepared,\n Animated,\n}\n\nconst LOADER_HEIGHT = 48;\n\n@Component({\n selector: 'tui-expand',\n templateUrl: './expand.template.html',\n styleUrls: ['./expand.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiExpandComponent {\n @ViewChild('wrapper')\n private readonly contentWrapper?: ElementRef<HTMLDivElement>;\n\n private state = State.Idle;\n\n @Input()\n @tuiDefaultProp()\n async = false;\n\n @Input('expanded')\n @tuiRequiredSetter()\n set expandedSetter(expanded: boolean | null) {\n if (this.expanded === null) {\n this.expanded = expanded;\n\n return;\n }\n\n if (this.state !== State.Idle) {\n this.expanded = expanded;\n this.state = State.Animated;\n\n return;\n }\n\n this.expanded = expanded;\n this.retrigger(this.async && expanded ? State.Loading : State.Animated);\n }\n\n @ContentChild(TuiExpandContentDirective, {read: TemplateRef})\n content: TemplateRef<NgIfContext<boolean>> | null = null;\n\n @HostBinding('class._expanded')\n @HostBinding('attr.aria-expanded')\n expanded: boolean | null = null;\n\n constructor(\n @Inject(ChangeDetectorRef) private readonly changeDetectorRef: ChangeDetectorRef,\n ) {}\n\n @HostBinding('class._overflow')\n get overflow(): boolean {\n return this.state !== State.Idle;\n }\n\n @HostBinding('class._loading')\n get loading(): boolean {\n return !!this.expanded && this.async && this.state === State.Loading;\n }\n\n @HostBinding('style.height.px')\n get height(): number | null {\n const {expanded, state, contentWrapper} = this;\n\n if (\n (expanded && state === State.Prepared) ||\n (!expanded && state === State.Animated)\n ) {\n return 0;\n }\n\n if (\n contentWrapper &&\n ((!expanded && state === State.Prepared) ||\n (expanded && state === State.Animated))\n ) {\n return contentWrapper.nativeElement.offsetHeight;\n }\n\n if (contentWrapper && expanded && state === State.Loading) {\n return Math.max(contentWrapper.nativeElement.offsetHeight, LOADER_HEIGHT);\n }\n\n return null;\n }\n\n get contentVisible(): boolean {\n return this.expanded || this.state !== State.Idle;\n }\n\n @HostListener('transitionend', ['$event'])\n onTransitionEnd(event: TransitionEvent): void {\n if (\n tuiIsCurrentTarget(event) &&\n event.propertyName === 'opacity' &&\n this.state === State.Animated\n ) {\n this.state = State.Idle;\n }\n }\n\n @HostListener(TUI_EXPAND_LOADED, ['$event'])\n onExpandLoaded(event: Event): void {\n event.stopPropagation();\n\n if (this.state === State.Loading) {\n this.retrigger(State.Animated);\n }\n }\n\n private retrigger(state: State): void {\n this.state = State.Prepared;\n\n // We need delay to re-trigger CSS height transition from the correct number\n setTimeout(() => {\n if (this.state !== State.Prepared) {\n return;\n }\n\n this.state = state;\n this.changeDetectorRef.markForCheck();\n });\n }\n}\n","<div\n #wrapper\n class=\"t-wrapper\"\n>\n <ng-container *ngIf=\"contentVisible\">\n <ng-content></ng-content>\n <tui-loader\n *ngIf=\"async; else content\"\n size=\"l\"\n [overlay]=\"true\"\n [showLoader]=\"loading\"\n >\n <ng-container [ngTemplateOutlet]=\"content\"></ng-container>\n </tui-loader>\n </ng-container>\n</div>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {TuiLoaderModule} from '@taiga-ui/core/components/loader';\n\nimport {TuiExpandComponent} from './expand.component';\nimport {TuiExpandContentDirective} from './expand-content.directive';\n\n@NgModule({\n imports: [CommonModule, TuiLoaderModule],\n declarations: [TuiExpandComponent, TuiExpandContentDirective],\n exports: [TuiExpandComponent, TuiExpandContentDirective],\n})\nexport class TuiExpandModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;MAKa,yBAAyB,CAAA;;uHAAzB,yBAAyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;2GAAzB,yBAAyB,EAAA,QAAA,EAAA,oBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;4FAAzB,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAHrC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA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A,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,EAJf,OAAA,EAAA,CAAA,CAAC,YAAY,EAAE,eAAe,CAAC,CAAA,EAAA,CAAA,CAAA;4FAI/B,eAAe,EAAA,UAAA,EAAA,CAAA;kBAL3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;AACxC,oBAAA,YAAY,EAAE,CAAC,kBAAkB,EAAE,yBAAyB,CAAC;AAC7D,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,yBAAyB,CAAC;AAC3D,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
|
|
@@ -8,33 +8,33 @@ import { CommonModule } from '@angular/common';
|
|
|
8
8
|
class TuiGroupStylesComponent {
|
|
9
9
|
}
|
|
10
10
|
TuiGroupStylesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiGroupStylesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
11
|
-
TuiGroupStylesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: TuiGroupStylesComponent, selector: "ng-component", ngImport: i0, template:
|
|
11
|
+
TuiGroupStylesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: TuiGroupStylesComponent, selector: "ng-component", ngImport: i0, template: '', isInline: true, styles: [".tui-group{position:relative;z-index:0;display:flex}.tui-group>*{flex:1 1 0;min-width:0}.tui-group>*:nth-child(n){border-radius:0}.tui-group>*:not(:last-child){margin-right:.125rem}.tui-group_collapsed>*{z-index:1}.tui-group_collapsed>*:not(:last-child){margin-right:-1px}.tui-group_collapsed>*._readonly,.tui-group_collapsed>*._disabled,.tui-group_collapsed>*._readonly:hover,.tui-group_collapsed>*._disabled:hover{z-index:0}.tui-group_collapsed>*:hover,.tui-group_collapsed>*._hovered,.tui-group_collapsed>*._pressed{z-index:3}.tui-group_collapsed>*._invalid{z-index:2}.tui-group_collapsed>*._invalid:hover,.tui-group_collapsed>*._invalid._hovered,.tui-group_collapsed>*._invalid._pressed{z-index:4}.tui-group_collapsed>*._hosted_dropdown_focused,.tui-group_collapsed>*._focus-visible,.tui-group_collapsed>*._focused.ng-touched,.tui-group_collapsed>*._focused.ng-untouched{z-index:5}.tui-group_collapsed>*._active,.tui-group_collapsed>*[data-appearance=whiteblock-active]{z-index:6}.tui-group_collapsed>*._focus-visible._focused,.tui-group_collapsed>*._focus-visible._active,.tui-group_collapsed>*._focus-visible[data-appearance=whiteblock-active]{z-index:7}.tui-group_orientation_vertical{display:inline-flex;flex-direction:column}.tui-group_orientation_vertical>*{min-height:auto;flex:0 0 auto}.tui-group_orientation_vertical>*:not(:last-child){margin-right:0;margin-bottom:.125rem}.tui-group_orientation_vertical.tui-group_collapsed>*:not(:last-child){margin-right:0;margin-bottom:-1px}.tui-group_rounded.tui-group_orientation_horizontal>*:first-child{border-top-left-radius:var(--tui-radius-m);border-bottom-left-radius:var(--tui-radius-m)}.tui-group_rounded.tui-group_orientation_horizontal>*:last-child{border-top-right-radius:var(--tui-radius-m);border-bottom-right-radius:var(--tui-radius-m)}.tui-group_rounded.tui-group_orientation_horizontal.tui-group_radius_large>*:first-child{border-top-left-radius:var(--tui-radius-l);border-bottom-left-radius:var(--tui-radius-l)}.tui-group_rounded.tui-group_orientation_horizontal.tui-group_radius_large>*:last-child{border-top-right-radius:var(--tui-radius-l);border-bottom-right-radius:var(--tui-radius-l)}.tui-group_rounded.tui-group_orientation_vertical>*:first-child{border-top-left-radius:var(--tui-radius-m);border-top-right-radius:var(--tui-radius-m)}.tui-group_rounded.tui-group_orientation_vertical>*:last-child{border-bottom-left-radius:var(--tui-radius-m);border-bottom-right-radius:var(--tui-radius-m)}.tui-group_rounded.tui-group_orientation_vertical.tui-group_radius_large>*:first-child{border-top-left-radius:var(--tui-radius-l);border-top-right-radius:var(--tui-radius-l)}.tui-group_rounded.tui-group_orientation_vertical.tui-group_radius_large>*:last-child{border-bottom-left-radius:var(--tui-radius-l);border-bottom-right-radius:var(--tui-radius-l)}@media screen and (max-width: 47.9625em){.tui-group_rounded.tui-group_adaptive.tui-group_orientation_vertical:not(.tui-group_collapsed)>*:first-child:not(:last-child),.tui-group_rounded.tui-group_adaptive.tui-group_orientation_horizontal>*:first-child:not(:last-child),.tui-group_rounded.tui-group_adaptive.tui-group_orientation_vertical:not(.tui-group_collapsed)>*:last-child:not(:first-child),.tui-group_rounded.tui-group_adaptive.tui-group_orientation_horizontal>*:last-child:not(:first-child){border-radius:var(--tui-radius-m)}}@media screen and (max-width: 47.9625em){.tui-group_rounded.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical:not(.tui-group_collapsed)>*:first-child:not(:last-child),.tui-group_rounded.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal>*:first-child:not(:last-child),.tui-group_rounded.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical:not(.tui-group_collapsed)>*:last-child:not(:first-child),.tui-group_rounded.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal>*:last-child:not(:first-child){border-radius:var(--tui-radius-l)}}@media screen and (max-width: 47.9625em){.tui-group_adaptive.tui-group_orientation_vertical{width:100%}.tui-group_adaptive.tui-group_orientation_vertical>*:nth-child(n):not(:only-child){border-radius:var(--tui-radius-m)}.tui-group_adaptive.tui-group_orientation_vertical>*:not(:last-child){margin-bottom:1rem}.tui-group_adaptive.tui-group_orientation_vertical.tui-group_collapsed>*:nth-child(n):not(:only-child){border-radius:0}.tui-group_adaptive.tui-group_orientation_vertical.tui-group_collapsed>*:first-child:not(:last-child){border-radius:var(--tui-radius-m) var(--tui-radius-m) 0 0}.tui-group_adaptive.tui-group_orientation_vertical.tui-group_collapsed>*:last-child:not(:first-child){border-radius:0 0 var(--tui-radius-m) var(--tui-radius-m)}.tui-group_adaptive.tui-group_orientation_vertical.tui-group_collapsed>*:not(:last-child){margin-bottom:-1px}}@media screen and (max-width: 47.9625em){.tui-group_adaptive.tui-group_orientation_horizontal{flex-direction:column;width:100%}.tui-group_adaptive.tui-group_orientation_horizontal>*:nth-child(n):not(:only-child){border-radius:var(--tui-radius-m)}.tui-group_adaptive.tui-group_orientation_horizontal>*:not(:last-child){margin-right:0;margin-bottom:1rem}.tui-group_adaptive.tui-group_orientation_horizontal.tui-group_collapsed>*:nth-child(n):not(:only-child){border-radius:0}.tui-group_adaptive.tui-group_orientation_horizontal.tui-group_collapsed>*:first-child:not(:last-child){border-radius:var(--tui-radius-m) var(--tui-radius-m) 0 0}.tui-group_adaptive.tui-group_orientation_horizontal.tui-group_collapsed>*:last-child:not(:first-child){border-radius:0 0 var(--tui-radius-m) var(--tui-radius-m)}.tui-group_adaptive.tui-group_orientation_horizontal.tui-group_collapsed>*:not(:last-child){margin-right:0;margin-bottom:-1px}}@media screen and (max-width: 47.9625em){.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical>*:nth-child(n):not(:only-child){border-radius:var(--tui-radius-l)}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical.tui-group_collapsed>*:nth-child(n):not(:only-child){border-radius:0}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical.tui-group_collapsed>*:first-child:not(:last-child){border-radius:var(--tui-radius-l) var(--tui-radius-l) 0 0}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_vertical.tui-group_collapsed>*:last-child:not(:first-child){border-radius:0 0 var(--tui-radius-l) var(--tui-radius-l)}}@media screen and (max-width: 47.9625em){.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal>*:nth-child(n):not(:only-child){border-radius:var(--tui-radius-l)}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal.tui-group_collapsed>*:nth-child(n):not(:only-child){border-radius:0}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal.tui-group_collapsed>*:first-child:not(:last-child){border-radius:var(--tui-radius-l) var(--tui-radius-l) 0 0}.tui-group_adaptive.tui-group_radius_large.tui-group_orientation_horizontal.tui-group_collapsed>*:last-child:not(:first-child){border-radius:0 0 var(--tui-radius-l) var(--tui-radius-l)}}.tui-group__auto-width-item{min-width:auto;flex:0 0 auto}.tui-group .tui-group__inherit-item{border-radius:inherit}\n"], encapsulation: i0.ViewEncapsulation.None });
|
|
12
12
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiGroupStylesComponent, decorators: [{
|
|
13
13
|
type: Component,
|
|
14
14
|
args: [{
|
|
15
|
-
template:
|
|
16
|
-
styleUrls: [
|
|
15
|
+
template: '',
|
|
16
|
+
styleUrls: ['./group.style.less'],
|
|
17
17
|
encapsulation: ViewEncapsulation.None,
|
|
18
18
|
}]
|
|
19
19
|
}] });
|
|
20
20
|
|
|
21
21
|
class TuiGroupDirective {
|
|
22
22
|
constructor(directiveStyles) {
|
|
23
|
-
this.orientation =
|
|
23
|
+
this.orientation = 'horizontal';
|
|
24
24
|
this.adaptive = false;
|
|
25
25
|
this.collapsed = false;
|
|
26
26
|
this.rounded = true;
|
|
27
|
-
this.size =
|
|
27
|
+
this.size = 'm';
|
|
28
28
|
directiveStyles.addComponent(TuiGroupStylesComponent);
|
|
29
29
|
}
|
|
30
30
|
get orientationHorizontal() {
|
|
31
|
-
return this.orientation ===
|
|
31
|
+
return this.orientation === 'horizontal';
|
|
32
32
|
}
|
|
33
33
|
get orientationVertical() {
|
|
34
|
-
return this.orientation ===
|
|
34
|
+
return this.orientation === 'vertical';
|
|
35
35
|
}
|
|
36
36
|
get sizeLarge() {
|
|
37
|
-
return this.size ===
|
|
37
|
+
return this.size === 'l';
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
40
|
TuiGroupDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiGroupDirective, deps: [{ token: TuiDirectiveStylesService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
@@ -57,10 +57,10 @@ __decorate([
|
|
|
57
57
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiGroupDirective, decorators: [{
|
|
58
58
|
type: Directive,
|
|
59
59
|
args: [{
|
|
60
|
-
selector:
|
|
60
|
+
selector: '[tuiGroup]:not(ng-container)',
|
|
61
61
|
host: {
|
|
62
|
-
class:
|
|
63
|
-
role:
|
|
62
|
+
class: 'tui-group',
|
|
63
|
+
role: 'group',
|
|
64
64
|
},
|
|
65
65
|
}]
|
|
66
66
|
}], ctorParameters: function () { return [{ type: i1.TuiDirectiveStylesService, decorators: [{
|
|
@@ -72,28 +72,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
72
72
|
type: Input
|
|
73
73
|
}, {
|
|
74
74
|
type: HostBinding,
|
|
75
|
-
args: [
|
|
75
|
+
args: ['class.tui-group_adaptive']
|
|
76
76
|
}], collapsed: [{
|
|
77
77
|
type: Input
|
|
78
78
|
}, {
|
|
79
79
|
type: HostBinding,
|
|
80
|
-
args: [
|
|
80
|
+
args: ['class.tui-group_collapsed']
|
|
81
81
|
}], rounded: [{
|
|
82
82
|
type: Input
|
|
83
83
|
}, {
|
|
84
84
|
type: HostBinding,
|
|
85
|
-
args: [
|
|
85
|
+
args: ['class.tui-group_rounded']
|
|
86
86
|
}], size: [{
|
|
87
87
|
type: Input
|
|
88
88
|
}], orientationHorizontal: [{
|
|
89
89
|
type: HostBinding,
|
|
90
|
-
args: [
|
|
90
|
+
args: ['class.tui-group_orientation_horizontal']
|
|
91
91
|
}], orientationVertical: [{
|
|
92
92
|
type: HostBinding,
|
|
93
|
-
args: [
|
|
93
|
+
args: ['class.tui-group_orientation_vertical']
|
|
94
94
|
}], sizeLarge: [{
|
|
95
95
|
type: HostBinding,
|
|
96
|
-
args: [
|
|
96
|
+
args: ['class.tui-group_radius_large']
|
|
97
97
|
}] } });
|
|
98
98
|
|
|
99
99
|
class TuiGroupModule {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-group.js","sources":["../../../projects/core/components/group/group-styles.component.ts","../../../projects/core/components/group/group.directive.ts","../../../projects/core/components/group/group.module.ts","../../../projects/core/components/group/taiga-ui-core-components-group.ts"],"sourcesContent":["import {Component, ViewEncapsulation} from '@angular/core';\n\n@Component({\n template:
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-group.js","sources":["../../../projects/core/components/group/group-styles.component.ts","../../../projects/core/components/group/group.directive.ts","../../../projects/core/components/group/group.module.ts","../../../projects/core/components/group/taiga-ui-core-components-group.ts"],"sourcesContent":["import {Component, ViewEncapsulation} from '@angular/core';\n\n@Component({\n template: '',\n styleUrls: ['./group.style.less'],\n encapsulation: ViewEncapsulation.None,\n})\nexport class TuiGroupStylesComponent {}\n","import {Directive, HostBinding, Inject, Input} from '@angular/core';\nimport {tuiDefaultProp, TuiDirectiveStylesService} from '@taiga-ui/cdk';\nimport {TuiOrientation, TuiSizeL} from '@taiga-ui/core/types';\n\nimport {TuiGroupStylesComponent} from './group-styles.component';\n\n@Directive({\n selector: '[tuiGroup]:not(ng-container)',\n host: {\n class: 'tui-group',\n role: 'group',\n },\n})\nexport class TuiGroupDirective {\n @Input()\n @tuiDefaultProp()\n orientation: TuiOrientation = 'horizontal';\n\n @Input()\n @HostBinding('class.tui-group_adaptive')\n @tuiDefaultProp()\n adaptive = false;\n\n @Input()\n @HostBinding('class.tui-group_collapsed')\n @tuiDefaultProp()\n collapsed = false;\n\n @Input()\n @HostBinding('class.tui-group_rounded')\n @tuiDefaultProp()\n rounded = true;\n\n @Input()\n @tuiDefaultProp()\n size: TuiSizeL = 'm';\n\n constructor(\n @Inject(TuiDirectiveStylesService) directiveStyles: TuiDirectiveStylesService,\n ) {\n directiveStyles.addComponent(TuiGroupStylesComponent);\n }\n\n @HostBinding('class.tui-group_orientation_horizontal')\n get orientationHorizontal(): boolean {\n return this.orientation === 'horizontal';\n }\n\n @HostBinding('class.tui-group_orientation_vertical')\n get orientationVertical(): boolean {\n return this.orientation === 'vertical';\n }\n\n @HostBinding('class.tui-group_radius_large')\n get sizeLarge(): boolean {\n return this.size === 'l';\n }\n}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\n\nimport {TuiGroupDirective} from './group.directive';\nimport {TuiGroupStylesComponent} from './group-styles.component';\n\n@NgModule({\n imports: [CommonModule],\n declarations: [TuiGroupDirective, TuiGroupStylesComponent],\n exports: [TuiGroupDirective, TuiGroupStylesComponent],\n})\nexport class TuiGroupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;MAOa,uBAAuB,CAAA;;qHAAvB,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAvB,uBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,uBAAuB,oDAJtB,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,gmOAAA,CAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;4FAIH,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBALnC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,EAAE;oBACZ,SAAS,EAAE,CAAC,oBAAoB,CAAC;oBACjC,aAAa,EAAE,iBAAiB,CAAC,IAAI;AACxC,iBAAA,CAAA;;;MCOY,iBAAiB,CAAA;AAwB1B,IAAA,WAAA,CACuC,eAA0C,EAAA;QAtBjF,IAAW,CAAA,WAAA,GAA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AK;gBAWF,qBAAqB,EAAA,CAAA;sBADxB,WAAW;uBAAC,wCAAwC,CAAA;gBAMjD,mBAAmB,EAAA,CAAA;sBADtB,WAAW;uBAAC,sCAAsC,CAAA;gBAM/C,SAAS,EAAA,CAAA;sBADZ,WAAW;uBAAC,8BAA8B,CAAA;;;MC1ClC,cAAc,CAAA;;4GAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;6GAAd,cAAc,EAAA,YAAA,EAAA,CAHR,iBAAiB,EAAE,uBAAuB,aAD/C,YAAY,CAAA,EAAA,OAAA,EAAA,CAEZ,iBAAiB,EAAE,uBAAuB,CAAA,EAAA,CAAA,CAAA;6GAE3C,cAAc,EAAA,OAAA,EAAA,CAJd,CAAC,YAAY,CAAC,CAAA,EAAA,CAAA,CAAA;4FAId,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,YAAY,CAAC;AACvB,oBAAA,YAAY,EAAE,CAAC,iBAAiB,EAAE,uBAAuB,CAAC;AAC1D,oBAAA,OAAO,EAAE,CAAC,iBAAiB,EAAE,uBAAuB,CAAC;AACxD,iBAAA,CAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -19,14 +19,14 @@ TuiHintsHostComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
19
19
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TuiHintsHostComponent, decorators: [{
|
|
20
20
|
type: Component,
|
|
21
21
|
args: [{
|
|
22
|
-
selector:
|
|
23
|
-
templateUrl:
|
|
24
|
-
styleUrls: [
|
|
22
|
+
selector: 'tui-hints-host',
|
|
23
|
+
templateUrl: './hints-host.template.html',
|
|
24
|
+
styleUrls: ['./hints-host.style.less'],
|
|
25
25
|
// So that we do not force OnPush on custom hints
|
|
26
26
|
changeDetection: ChangeDetectionStrategy.Default,
|
|
27
27
|
animations: [TUI_PARENT_ANIMATION],
|
|
28
28
|
host: {
|
|
29
|
-
'aria-live':
|
|
29
|
+
'aria-live': 'polite',
|
|
30
30
|
},
|
|
31
31
|
}]
|
|
32
32
|
}], ctorParameters: function () { return [{ type: i4.Observable, decorators: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-hints-host.js","sources":["../../../projects/core/components/hints-host/hints-host.component.ts","../../../projects/core/components/hints-host/hints-host.template.html","../../../projects/core/components/hints-host/hints-host.module.ts","../../../projects/core/components/hints-host/taiga-ui-core-components-hints-host.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, Inject} from '@angular/core';\nimport {TUI_PARENT_ANIMATION} from '@taiga-ui/cdk';\nimport {TuiPortalItem} from '@taiga-ui/core/interfaces';\nimport {TuiHintService} from '@taiga-ui/core/services';\nimport {Observable} from 'rxjs';\n\n@Component({\n selector:
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-hints-host.js","sources":["../../../projects/core/components/hints-host/hints-host.component.ts","../../../projects/core/components/hints-host/hints-host.template.html","../../../projects/core/components/hints-host/hints-host.module.ts","../../../projects/core/components/hints-host/taiga-ui-core-components-hints-host.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, Inject} from '@angular/core';\nimport {TUI_PARENT_ANIMATION} from '@taiga-ui/cdk';\nimport {TuiPortalItem} from '@taiga-ui/core/interfaces';\nimport {TuiHintService} from '@taiga-ui/core/services';\nimport {Observable} from 'rxjs';\n\n@Component({\n selector: 'tui-hints-host',\n templateUrl: './hints-host.template.html',\n styleUrls: ['./hints-host.style.less'],\n // So that we do not force OnPush on custom hints\n changeDetection: ChangeDetectionStrategy.Default,\n animations: [TUI_PARENT_ANIMATION],\n host: {\n 'aria-live': 'polite',\n },\n})\nexport class TuiHintsHostComponent {\n constructor(\n @Inject(TuiHintService) readonly hints$: Observable<readonly TuiPortalItem[]>,\n ) {}\n}\n","<div\n *ngFor=\"let hint of hints$ | async\"\n role=\"tooltip\"\n @tuiParentAnimation\n [tuiActiveZoneParent]=\"hint.activeZone || null\"\n>\n <ng-container *polymorpheusOutlet=\"hint.component; context: {$implicit: hint}\"></ng-container>\n</div>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {TuiActiveZoneModule} from '@taiga-ui/cdk';\nimport {PolymorpheusModule} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiHintsHostComponent} from './hints-host.component';\n\n@NgModule({\n imports: [CommonModule, PolymorpheusModule, TuiActiveZoneModule],\n declarations: [TuiHintsHostComponent],\n exports: [TuiHintsHostComponent],\n})\nexport class TuiHintsHostModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;MAiBa,qBAAqB,CAAA;AAC9B,IAAA,WAAA,CACqC,MAA4C,EAAA;QAA5C,IAAM,CAAA,MAAA,GAAN,MAAM,CAAsC;KAC7E;;AAHK,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qBAAqB,kBAElB,cAAc,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAFjB,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,qBAAqB,ECjBlC,QAAA,EAAA,gBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,WAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,0QAQA,EDIgB,MAAA,EAAA,CAAA,0DAAA,CAAA,EAAA,UAAA,EA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