@taiga-ui/core 4.24.0 → 4.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/directives/dropdown/dropdown-context.directive.d.ts +2 -1
- package/directives/dropdown/dropdown.component.d.ts +4 -1
- package/esm2022/components/button/button.directive.mjs +2 -2
- package/esm2022/components/data-list/data-list.component.mjs +3 -3
- package/esm2022/components/dialog/dialog.component.mjs +3 -3
- package/esm2022/components/root/root.component.mjs +1 -1
- package/esm2022/components/textfield/textfield.component.mjs +3 -3
- package/esm2022/directives/appearance/appearance.bindings.mjs +1 -1
- package/esm2022/directives/appearance/appearance.directive.mjs +3 -4
- package/esm2022/directives/dropdown/dropdown-context.directive.mjs +4 -3
- package/esm2022/directives/dropdown/dropdown.component.mjs +11 -8
- package/esm2022/directives/surface/surface.directive.mjs +2 -2
- package/esm2022/utils/miscellaneous/font-scaling.mjs +11 -0
- package/esm2022/utils/miscellaneous/index.mjs +2 -1
- package/fesm2022/taiga-ui-core-components-button.mjs +2 -2
- package/fesm2022/taiga-ui-core-components-button.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-data-list.mjs +2 -2
- package/fesm2022/taiga-ui-core-components-data-list.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-dialog.mjs +2 -2
- package/fesm2022/taiga-ui-core-components-dialog.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-root.mjs +1 -1
- package/fesm2022/taiga-ui-core-components-textfield.mjs +2 -2
- package/fesm2022/taiga-ui-core-components-textfield.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-appearance.mjs +2 -3
- package/fesm2022/taiga-ui-core-directives-appearance.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-dropdown.mjs +13 -9
- package/fesm2022/taiga-ui-core-directives-dropdown.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-surface.mjs +2 -2
- package/fesm2022/taiga-ui-core-directives-surface.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-utils-miscellaneous.mjs +12 -2
- package/fesm2022/taiga-ui-core-utils-miscellaneous.mjs.map +1 -1
- package/package.json +3 -3
- package/styles/components/appearance.less +2 -2
- package/styles/components/button.less +2 -1
- package/styles/components/textfield.less +2 -1
- package/styles/mixins/mixins.less +4 -3
- package/styles/mixins/mixins.scss +2 -2
- package/styles/theme/appearance/primary.less +0 -2
- package/styles/theme/variables.less +16 -15
- package/utils/miscellaneous/font-scaling.d.ts +2 -0
- package/utils/miscellaneous/index.d.ts +1 -0
|
@@ -120,7 +120,7 @@ class TuiDialogComponent {
|
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
122
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
123
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiDialogComponent, isStandalone: true, selector: "tui-dialog", host: { properties: { "@tuiSlideInTop": "slideInTop()", "@tuiFadeIn": "slideInTop()", "attr.data-appearance": "context.appearance", "attr.data-size": "size", "class._centered": "header" } }, providers: [TuiDialogCloseService], ngImport: i0, template: "<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 [class.t-heading_closable]=\"context.closeable\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n", styles: [":host{position:relative;display:flex;font:var(--tui-font-text-m);flex-direction:column;box-sizing:border-box;margin:auto;border-radius:1.5rem;border:2.5rem solid transparent}:host:after{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;content:\"\";border-radius:inherit;pointer-events:none;box-shadow:var(--tui-shadow-popup)}:host[data-size=auto]{inline-size:auto}:host[data-size=s]{inline-size:30rem}:host[data-size=s] .t-content{padding:1.5rem}:host[data-size=s] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=m]{inline-size:42.5rem}:host[data-size=l]{inline-size:55rem}:host[data-size=fullscreen],:host[data-size=page]{min-inline-size:100vw;min-block-size:100%;border-radius:0;border:none;background:var(--tui-background-elevation-1);box-shadow:0 4rem var(--tui-background-elevation-1)}:host[data-size=fullscreen] .t-content,:host[data-size=page] .t-content{padding:3rem calc(50vw - 22.5rem)}:host[data-size=fullscreen] .t-heading,:host[data-size=page] .t-heading{font:var(--tui-font-heading-3)}:host._centered{text-align:center}:host :host-context(tui-root._mobile)[data-size]{min-inline-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0;border:none;margin:auto 0 0}:host :host-context(tui-root._mobile)[data-size] .t-content{padding:1rem}:host :host-context(tui-root._mobile)[data-size] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=page] .t-content,:host-context(tui-root._mobile) :host[data-size=page] .t-content{padding:0}.t-heading{margin:0 0 .5rem;overflow-wrap:break-word;font:var(--tui-font-heading-4)}.t-heading_closable{padding-inline-end:2rem}.t-heading:empty{display:none}.t-header{display:flex;border-top-left-radius:inherit;border-top-right-radius:inherit;overflow:hidden}:host[data-size=fullscreen] :host-context(tui-root._mobile) .t-header{flex:1}.t-content{border-radius:inherit;padding:1.75rem;background:var(--tui-background-elevation-1)}.t-content:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.t-filler{flex-grow:1}.t-close{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;top:1rem;right:1rem}.t-buttons{margin-top:1.25rem;text-align:end}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAutoFocus, selector: "[tuiAutoFocus]", inputs: ["tuiAutoFocus"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], animations: [tuiSlideInTop, tuiFadeIn], changeDetection: i0.ChangeDetectionStrategy.Default }); }
|
|
123
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiDialogComponent, isStandalone: true, selector: "tui-dialog", host: { properties: { "@tuiSlideInTop": "slideInTop()", "@tuiFadeIn": "slideInTop()", "attr.data-appearance": "context.appearance", "attr.data-size": "size", "class._centered": "header" } }, providers: [TuiDialogCloseService], ngImport: i0, template: "<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 [class.t-heading_closable]=\"context.closeable && !header\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n", styles: [":host{position:relative;display:flex;font:var(--tui-font-text-m);flex-direction:column;box-sizing:border-box;margin:auto;border-radius:1.5rem;border:2.5rem solid transparent}:host:after{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;content:\"\";border-radius:inherit;pointer-events:none;box-shadow:var(--tui-shadow-popup)}:host[data-size=auto]{inline-size:auto}:host[data-size=s]{inline-size:30rem}:host[data-size=s] .t-content{padding:1.5rem}:host[data-size=s] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=m]{inline-size:42.5rem}:host[data-size=l]{inline-size:55rem}:host[data-size=fullscreen],:host[data-size=page]{min-inline-size:100vw;min-block-size:100%;border-radius:0;border:none;background:var(--tui-background-elevation-1);box-shadow:0 4rem var(--tui-background-elevation-1)}:host[data-size=fullscreen] .t-content,:host[data-size=page] .t-content{padding:3rem calc(50vw - 22.5rem)}:host[data-size=fullscreen] .t-heading,:host[data-size=page] .t-heading{font:var(--tui-font-heading-3)}:host._centered{text-align:center}:host :host-context(tui-root._mobile)[data-size]{min-inline-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0;border:none;margin:auto 0 0}:host :host-context(tui-root._mobile)[data-size] .t-content{padding:1rem}:host :host-context(tui-root._mobile)[data-size] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=page] .t-content,:host-context(tui-root._mobile) :host[data-size=page] .t-content{padding:0}.t-heading{margin:0 0 .5rem;overflow-wrap:break-word;font:var(--tui-font-heading-4)}.t-heading_closable{padding-inline-end:2rem}.t-heading:empty{display:none}.t-header{display:flex;border-top-left-radius:inherit;border-top-right-radius:inherit;overflow:hidden}:host[data-size=fullscreen] :host-context(tui-root._mobile) .t-header{flex:1}.t-content{border-radius:inherit;padding:1.75rem;background:var(--tui-background-elevation-1)}.t-content:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.t-filler{flex-grow:1}.t-close{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;top:1rem;right:1rem}.t-buttons{margin-top:1.25rem;text-align:end}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAutoFocus, selector: "[tuiAutoFocus]", inputs: ["tuiAutoFocus"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], animations: [tuiSlideInTop, tuiFadeIn], changeDetection: i0.ChangeDetectionStrategy.Default }); }
|
|
124
124
|
}
|
|
125
125
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiDialogComponent, decorators: [{
|
|
126
126
|
type: Component,
|
|
@@ -130,7 +130,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
130
130
|
'[attr.data-appearance]': 'context.appearance',
|
|
131
131
|
'[attr.data-size]': 'size',
|
|
132
132
|
'[class._centered]': 'header',
|
|
133
|
-
}, template: "<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 [class.t-heading_closable]=\"context.closeable\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n", styles: [":host{position:relative;display:flex;font:var(--tui-font-text-m);flex-direction:column;box-sizing:border-box;margin:auto;border-radius:1.5rem;border:2.5rem solid transparent}:host:after{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;content:\"\";border-radius:inherit;pointer-events:none;box-shadow:var(--tui-shadow-popup)}:host[data-size=auto]{inline-size:auto}:host[data-size=s]{inline-size:30rem}:host[data-size=s] .t-content{padding:1.5rem}:host[data-size=s] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=m]{inline-size:42.5rem}:host[data-size=l]{inline-size:55rem}:host[data-size=fullscreen],:host[data-size=page]{min-inline-size:100vw;min-block-size:100%;border-radius:0;border:none;background:var(--tui-background-elevation-1);box-shadow:0 4rem var(--tui-background-elevation-1)}:host[data-size=fullscreen] .t-content,:host[data-size=page] .t-content{padding:3rem calc(50vw - 22.5rem)}:host[data-size=fullscreen] .t-heading,:host[data-size=page] .t-heading{font:var(--tui-font-heading-3)}:host._centered{text-align:center}:host :host-context(tui-root._mobile)[data-size]{min-inline-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0;border:none;margin:auto 0 0}:host :host-context(tui-root._mobile)[data-size] .t-content{padding:1rem}:host :host-context(tui-root._mobile)[data-size] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=page] .t-content,:host-context(tui-root._mobile) :host[data-size=page] .t-content{padding:0}.t-heading{margin:0 0 .5rem;overflow-wrap:break-word;font:var(--tui-font-heading-4)}.t-heading_closable{padding-inline-end:2rem}.t-heading:empty{display:none}.t-header{display:flex;border-top-left-radius:inherit;border-top-right-radius:inherit;overflow:hidden}:host[data-size=fullscreen] :host-context(tui-root._mobile) .t-header{flex:1}.t-content{border-radius:inherit;padding:1.75rem;background:var(--tui-background-elevation-1)}.t-content:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.t-filler{flex-grow:1}.t-close{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;top:1rem;right:1rem}.t-buttons{margin-top:1.25rem;text-align:end}\n"] }]
|
|
133
|
+
}, template: "<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 [class.t-heading_closable]=\"context.closeable && !header\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n", styles: [":host{position:relative;display:flex;font:var(--tui-font-text-m);flex-direction:column;box-sizing:border-box;margin:auto;border-radius:1.5rem;border:2.5rem solid transparent}:host:after{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;content:\"\";border-radius:inherit;pointer-events:none;box-shadow:var(--tui-shadow-popup)}:host[data-size=auto]{inline-size:auto}:host[data-size=s]{inline-size:30rem}:host[data-size=s] .t-content{padding:1.5rem}:host[data-size=s] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=m]{inline-size:42.5rem}:host[data-size=l]{inline-size:55rem}:host[data-size=fullscreen],:host[data-size=page]{min-inline-size:100vw;min-block-size:100%;border-radius:0;border:none;background:var(--tui-background-elevation-1);box-shadow:0 4rem var(--tui-background-elevation-1)}:host[data-size=fullscreen] .t-content,:host[data-size=page] .t-content{padding:3rem calc(50vw - 22.5rem)}:host[data-size=fullscreen] .t-heading,:host[data-size=page] .t-heading{font:var(--tui-font-heading-3)}:host._centered{text-align:center}:host :host-context(tui-root._mobile)[data-size]{min-inline-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0;border:none;margin:auto 0 0}:host :host-context(tui-root._mobile)[data-size] .t-content{padding:1rem}:host :host-context(tui-root._mobile)[data-size] .t-heading{font:var(--tui-font-heading-5)}:host[data-size=page] .t-content,:host-context(tui-root._mobile) :host[data-size=page] .t-content{padding:0}.t-heading{margin:0 0 .5rem;overflow-wrap:break-word;font:var(--tui-font-heading-4)}.t-heading_closable{padding-inline-end:2rem}.t-heading:empty{display:none}.t-header{display:flex;border-top-left-radius:inherit;border-top-right-radius:inherit;overflow:hidden}:host[data-size=fullscreen] :host-context(tui-root._mobile) .t-header{flex:1}.t-content{border-radius:inherit;padding:1.75rem;background:var(--tui-background-elevation-1)}.t-content:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.t-filler{flex-grow:1}.t-close{transition-property:background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;top:1rem;right:1rem}.t-buttons{margin-top:1.25rem;text-align:end}\n"] }]
|
|
134
134
|
}], ctorParameters: function () { return []; } });
|
|
135
135
|
|
|
136
136
|
class TuiDialogService extends TuiPopoverService {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-dialog.mjs","sources":["../../../projects/core/components/dialog/dialog.tokens.ts","../../../projects/core/components/dialog/dialog-close.service.ts","../../../projects/core/components/dialog/dialog.component.ts","../../../projects/core/components/dialog/dialog.template.html","../../../projects/core/components/dialog/dialog.service.ts","../../../projects/core/components/dialog/dialog.directive.ts","../../../projects/core/components/dialog/dialog.factory.ts","../../../projects/core/components/dialog/dialogs.component.ts","../../../projects/core/components/dialog/dialogs.template.html","../../../projects/core/components/dialog/taiga-ui-core-components-dialog.ts"],"sourcesContent":["import type {Provider} from '@angular/core';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiCreateToken, tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\nimport type {Observable} from 'rxjs';\nimport {BehaviorSubject, EMPTY} from 'rxjs';\n\nimport type {TuiDialogOptions} from './dialog.interfaces';\n\nexport const TUI_DIALOGS = tuiCreateToken(\n new BehaviorSubject<ReadonlyArray<TuiPopover<any, any>>>([]),\n);\n\nexport const TUI_DIALOG_DEFAULT_OPTIONS: TuiDialogOptions<void> = {\n appearance: '',\n size: 'm',\n required: false,\n closeable: true,\n dismissible: true,\n label: '',\n header: '',\n data: undefined,\n};\n\n/**\n * A stream to close dialogs\n */\nexport const TUI_DIALOGS_CLOSE = tuiCreateToken<Observable<unknown>>(EMPTY);\n\n/**\n * Default parameters for dialog component\n */\nexport const TUI_DIALOG_OPTIONS = tuiCreateToken(TUI_DIALOG_DEFAULT_OPTIONS);\n\nexport function tuiDialogOptionsProvider(\n options: Partial<TuiDialogOptions<unknown>>,\n): Provider {\n return tuiProvideOptions(TUI_DIALOG_OPTIONS, options, TUI_DIALOG_DEFAULT_OPTIONS);\n}\n","import {DOCUMENT} from '@angular/common';\nimport {inject, Injectable} from '@angular/core';\nimport {WA_WINDOW} from '@ng-web-apis/common';\nimport {tuiTypedFromEvent} from '@taiga-ui/cdk/observables';\nimport {\n tuiContainsOrAfter,\n tuiGetActualTarget,\n tuiInjectElement,\n tuiIsElement,\n} from '@taiga-ui/cdk/utils/dom';\nimport {tuiGetViewportWidth} from '@taiga-ui/core/utils';\nimport {filter, map, merge, Observable, switchMap, take} from 'rxjs';\n\nconst SCROLLBAR_PLACEHOLDER = 17;\n\n@Injectable()\nexport class TuiDialogCloseService extends Observable<unknown> {\n private readonly win = inject(WA_WINDOW);\n private readonly doc = inject(DOCUMENT);\n private readonly el = tuiInjectElement();\n\n private readonly esc$ = tuiTypedFromEvent(this.doc, 'keydown').pipe(\n filter((event) => {\n const target = tuiGetActualTarget(event);\n\n return (\n event.key === 'Escape' &&\n !event.defaultPrevented &&\n (this.el.contains(target) || this.isOutside(target))\n );\n }),\n );\n\n private readonly mousedown$ = tuiTypedFromEvent(this.doc, 'mousedown').pipe(\n filter(\n (event) =>\n tuiGetViewportWidth(this.win) - event.clientX > SCROLLBAR_PLACEHOLDER &&\n this.isOutside(tuiGetActualTarget(event)),\n ),\n switchMap(() =>\n tuiTypedFromEvent(this.doc, 'mouseup').pipe(\n take(1),\n map(tuiGetActualTarget),\n filter((target) => this.isOutside(target)),\n ),\n ),\n );\n\n constructor() {\n super((subscriber) => merge(this.esc$, this.mousedown$).subscribe(subscriber));\n }\n\n private isOutside(target: EventTarget): boolean {\n return (\n tuiIsElement(target) &&\n (!tuiContainsOrAfter(this.el, target) || target === this.el)\n );\n }\n}\n","import {AsyncPipe, NgIf} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, computed, inject} from '@angular/core';\nimport {takeUntilDestroyed, toSignal} from '@angular/core/rxjs-interop';\nimport {TUI_TRUE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {TuiAutoFocus} from '@taiga-ui/cdk/directives/auto-focus';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiFadeIn, tuiSlideInTop} from '@taiga-ui/core/animations';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiBreakpointService} from '@taiga-ui/core/services';\nimport {\n TUI_ANIMATIONS_SPEED,\n TUI_CLOSE_WORD,\n TUI_COMMON_ICONS,\n} from '@taiga-ui/core/tokens';\nimport {tuiGetDuration} from '@taiga-ui/core/utils';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport type {Observable} from 'rxjs';\nimport {filter, isObservable, map, merge, of, Subject, switchMap} from 'rxjs';\n\nimport type {TuiDialogOptions, TuiDialogSize} from './dialog.interfaces';\nimport {TUI_DIALOGS_CLOSE} from './dialog.tokens';\nimport {TuiDialogCloseService} from './dialog-close.service';\n\nconst REQUIRED_ERROR = new Error('Required dialog was dismissed');\n\nfunction toObservable<T>(valueOrStream: Observable<T> | T): Observable<T> {\n return isObservable(valueOrStream) ? valueOrStream : of(valueOrStream);\n}\n\n@Component({\n standalone: true,\n selector: 'tui-dialog',\n imports: [AsyncPipe, NgIf, PolymorpheusOutlet, TuiAutoFocus, TuiButton],\n templateUrl: './dialog.template.html',\n styleUrls: ['./dialog.style.less'],\n // So we don't force OnPush on dialog content\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n providers: [TuiDialogCloseService],\n animations: [tuiSlideInTop, tuiFadeIn],\n host: {\n '[@tuiSlideInTop]': 'slideInTop()',\n '[@tuiFadeIn]': 'slideInTop()',\n '[attr.data-appearance]': 'context.appearance',\n '[attr.data-size]': 'size',\n '[class._centered]': 'header',\n },\n})\nexport class TuiDialogComponent<O, I> {\n private readonly speed = inject(TUI_ANIMATIONS_SPEED);\n\n private readonly animation = {\n value: '',\n params: {\n start: '40px',\n duration: tuiGetDuration(this.speed),\n },\n } as const;\n\n private readonly fullscreenAnimation = {\n value: '',\n params: {\n start: '100vh',\n duration: tuiGetDuration(this.speed),\n },\n } as const;\n\n protected readonly close$ = new Subject<void>();\n protected readonly context = injectContext<TuiPopover<TuiDialogOptions<I>, O>>();\n protected readonly closeWord$ = inject(TUI_CLOSE_WORD);\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly slideInTop = computed(() =>\n this.size === 'fullscreen' || this.size === 'page' || this.isMobile()\n ? this.fullscreenAnimation\n : this.animation,\n );\n\n protected readonly isMobile = toSignal(\n inject(TuiBreakpointService).pipe(map((breakpoint) => breakpoint === 'mobile')),\n );\n\n constructor() {\n merge(\n this.close$.pipe(switchMap(() => toObservable(this.context.closeable))),\n inject(TuiDialogCloseService).pipe(\n switchMap(() => toObservable(this.context.dismissible)),\n ),\n inject(TUI_DIALOGS_CLOSE).pipe(map(TUI_TRUE_HANDLER)),\n )\n .pipe(filter(Boolean), takeUntilDestroyed())\n .subscribe(() => {\n this.close();\n });\n }\n\n protected get size(): TuiDialogSize {\n return this.context.size;\n }\n\n protected get header(): PolymorpheusContent<TuiPopover<TuiDialogOptions<I>, O>> {\n return this.context.header;\n }\n\n private 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 [class.t-heading_closable]=\"context.closeable\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n","import {inject, Injectable} from '@angular/core';\nimport {TuiPopoverService} from '@taiga-ui/cdk/services';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport type {TuiDialogOptions} from './dialog.interfaces';\nimport {TUI_DIALOG_OPTIONS, TUI_DIALOGS} from './dialog.tokens';\n\n@Injectable({\n providedIn: 'root',\n useFactory: () =>\n new TuiDialogService(TUI_DIALOGS, TuiDialogComponent, inject(TUI_DIALOG_OPTIONS)),\n})\nexport class TuiDialogService extends TuiPopoverService<TuiDialogOptions<any>> {}\n","import {Directive} from '@angular/core';\nimport {TuiPopoverDirective} from '@taiga-ui/cdk/directives/popover';\nimport {tuiAsPopover} from '@taiga-ui/cdk/services';\n\nimport type {TuiDialogOptions} from './dialog.interfaces';\nimport {TuiDialogService} from './dialog.service';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiDialog]',\n inputs: ['options: tuiDialogOptions', 'open: tuiDialog'],\n outputs: ['openChange: tuiDialogChange'],\n providers: [tuiAsPopover(TuiDialogService)],\n})\nexport class TuiDialog<T> extends TuiPopoverDirective<TuiDialogOptions<T>> {}\n","import type {Injector} from '@angular/core';\nimport {assertInInjectionContext, inject, INJECTOR} from '@angular/core';\nimport {PolymorpheusComponent} from '@taiga-ui/polymorpheus';\nimport type {Observable} from 'rxjs';\n\nimport type {TuiDialogContext, TuiDialogOptions} from './dialog.interfaces';\nimport {TuiDialogService} from './dialog.service';\n\ntype SingleUnionOrNever<T, U = T> = [T] extends [never]\n ? never\n : T extends U\n ? [U] extends [T]\n ? T\n : never\n : never;\n\ntype ReplaceAny<T> = 0 extends T & 1 ? void : T;\n\ntype ContextKeys<T> = {\n [K in keyof T]: ReplaceAny<T[K]> extends TuiDialogContext<any, any> ? K : never;\n}[keyof T];\n\ntype AssertNotMultipleContexts<T, K extends keyof T> = [K] extends [never]\n ? new (...args: any[]) => T\n : [SingleUnionOrNever<K>] extends [never]\n ? 'Component has multiple context. Cannot determine the type...'\n : new (...args: any[]) => T;\n\ntype ExtractDialogData<T, K extends keyof T = ContextKeys<T>> = [K] extends [never]\n ? void\n : [SingleUnionOrNever<K>] extends [never]\n ? never\n : T[K] extends TuiDialogContext<any, infer D>\n ? D\n : void;\n\ntype ExtractDialogResult<T, K extends keyof T = ContextKeys<T>> = [K] extends [never]\n ? void\n : [SingleUnionOrNever<K>] extends [never]\n ? never\n : T[K] extends TuiDialogContext<infer R, any>\n ? R\n : void;\n\ntype Options<T> = Omit<TuiDialogOptions<T>, 'data'> & {injector: Injector};\n\nexport function tuiDialog<\n T,\n K extends ContextKeys<T>,\n D extends ExtractDialogData<T, K>,\n R extends ExtractDialogResult<T, K>,\n>(\n component: AssertNotMultipleContexts<T, K>,\n {injector, ...options}: Partial<Options<D>> = {},\n): (data: D) => Observable<R> {\n if (!injector) {\n assertInInjectionContext(tuiDialog);\n injector = inject(INJECTOR);\n }\n\n const dialogService = injector.get(TuiDialogService);\n\n return (data) =>\n dialogService.open(\n new PolymorpheusComponent(component as new () => T, injector),\n {\n ...options,\n data,\n },\n );\n}\n","import {NgForOf} from '@angular/common';\nimport type {Signal} from '@angular/core';\nimport {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {TuiFocusTrap} from '@taiga-ui/cdk/directives/focus-trap';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiHost} from '@taiga-ui/core/animations';\nimport {TuiScrollControls, TuiScrollRef} from '@taiga-ui/core/components/scrollbar';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_DIALOGS} from './dialog.tokens';\n\n@Component({\n standalone: true,\n selector: 'tui-dialogs',\n imports: [NgForOf, PolymorpheusOutlet, TuiFocusTrap, TuiScrollControls, TuiScrollRef],\n templateUrl: './dialogs.template.html',\n styleUrls: ['./dialogs.style.less'],\n // So that we do not force OnPush on custom dialogs\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n animations: [tuiHost],\n host: {\n '(keydown.zoneless)': 'el.scrollTop = el.scrollHeight / 2',\n },\n})\nexport class TuiDialogs {\n protected readonly el = tuiInjectElement();\n protected readonly dialogs: Signal<ReadonlyArray<TuiPopover<any, any>>> = toSignal(\n inject(TUI_DIALOGS),\n {initialValue: []},\n );\n}\n","<div\n class=\"t-overlay\"\n [class.t-overlay_visible]=\"dialogs().length\"\n></div>\n<section\n *ngFor=\"let item of dialogs()\"\n aria-modal=\"true\"\n role=\"dialog\"\n tuiFocusTrap\n tuiScrollRef\n class=\"t-dialog\"\n @tuiHost\n [attr.aria-labelledby]=\"item.id\"\n>\n <ng-container *polymorpheusOutlet=\"item.component; context: item\" />\n <tui-scroll-controls class=\"t-scrollbars\" />\n</section>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAQO,MAAM,WAAW,GAAG,cAAc,CACrC,IAAI,eAAe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file":"taiga-ui-core-components-dialog.mjs","sources":["../../../projects/core/components/dialog/dialog.tokens.ts","../../../projects/core/components/dialog/dialog-close.service.ts","../../../projects/core/components/dialog/dialog.component.ts","../../../projects/core/components/dialog/dialog.template.html","../../../projects/core/components/dialog/dialog.service.ts","../../../projects/core/components/dialog/dialog.directive.ts","../../../projects/core/components/dialog/dialog.factory.ts","../../../projects/core/components/dialog/dialogs.component.ts","../../../projects/core/components/dialog/dialogs.template.html","../../../projects/core/components/dialog/taiga-ui-core-components-dialog.ts"],"sourcesContent":["import type {Provider} from '@angular/core';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiCreateToken, tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\nimport type {Observable} from 'rxjs';\nimport {BehaviorSubject, EMPTY} from 'rxjs';\n\nimport type {TuiDialogOptions} from './dialog.interfaces';\n\nexport const TUI_DIALOGS = tuiCreateToken(\n new BehaviorSubject<ReadonlyArray<TuiPopover<any, any>>>([]),\n);\n\nexport const TUI_DIALOG_DEFAULT_OPTIONS: TuiDialogOptions<void> = {\n appearance: '',\n size: 'm',\n required: false,\n closeable: true,\n dismissible: true,\n label: '',\n header: '',\n data: undefined,\n};\n\n/**\n * A stream to close dialogs\n */\nexport const TUI_DIALOGS_CLOSE = tuiCreateToken<Observable<unknown>>(EMPTY);\n\n/**\n * Default parameters for dialog component\n */\nexport const TUI_DIALOG_OPTIONS = tuiCreateToken(TUI_DIALOG_DEFAULT_OPTIONS);\n\nexport function tuiDialogOptionsProvider(\n options: Partial<TuiDialogOptions<unknown>>,\n): Provider {\n return tuiProvideOptions(TUI_DIALOG_OPTIONS, options, TUI_DIALOG_DEFAULT_OPTIONS);\n}\n","import {DOCUMENT} from '@angular/common';\nimport {inject, Injectable} from '@angular/core';\nimport {WA_WINDOW} from '@ng-web-apis/common';\nimport {tuiTypedFromEvent} from '@taiga-ui/cdk/observables';\nimport {\n tuiContainsOrAfter,\n tuiGetActualTarget,\n tuiInjectElement,\n tuiIsElement,\n} from '@taiga-ui/cdk/utils/dom';\nimport {tuiGetViewportWidth} from '@taiga-ui/core/utils';\nimport {filter, map, merge, Observable, switchMap, take} from 'rxjs';\n\nconst SCROLLBAR_PLACEHOLDER = 17;\n\n@Injectable()\nexport class TuiDialogCloseService extends Observable<unknown> {\n private readonly win = inject(WA_WINDOW);\n private readonly doc = inject(DOCUMENT);\n private readonly el = tuiInjectElement();\n\n private readonly esc$ = tuiTypedFromEvent(this.doc, 'keydown').pipe(\n filter((event) => {\n const target = tuiGetActualTarget(event);\n\n return (\n event.key === 'Escape' &&\n !event.defaultPrevented &&\n (this.el.contains(target) || this.isOutside(target))\n );\n }),\n );\n\n private readonly mousedown$ = tuiTypedFromEvent(this.doc, 'mousedown').pipe(\n filter(\n (event) =>\n tuiGetViewportWidth(this.win) - event.clientX > SCROLLBAR_PLACEHOLDER &&\n this.isOutside(tuiGetActualTarget(event)),\n ),\n switchMap(() =>\n tuiTypedFromEvent(this.doc, 'mouseup').pipe(\n take(1),\n map(tuiGetActualTarget),\n filter((target) => this.isOutside(target)),\n ),\n ),\n );\n\n constructor() {\n super((subscriber) => merge(this.esc$, this.mousedown$).subscribe(subscriber));\n }\n\n private isOutside(target: EventTarget): boolean {\n return (\n tuiIsElement(target) &&\n (!tuiContainsOrAfter(this.el, target) || target === this.el)\n );\n }\n}\n","import {AsyncPipe, NgIf} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, computed, inject} from '@angular/core';\nimport {takeUntilDestroyed, toSignal} from '@angular/core/rxjs-interop';\nimport {TUI_TRUE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {TuiAutoFocus} from '@taiga-ui/cdk/directives/auto-focus';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiFadeIn, tuiSlideInTop} from '@taiga-ui/core/animations';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiBreakpointService} from '@taiga-ui/core/services';\nimport {\n TUI_ANIMATIONS_SPEED,\n TUI_CLOSE_WORD,\n TUI_COMMON_ICONS,\n} from '@taiga-ui/core/tokens';\nimport {tuiGetDuration} from '@taiga-ui/core/utils';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport type {Observable} from 'rxjs';\nimport {filter, isObservable, map, merge, of, Subject, switchMap} from 'rxjs';\n\nimport type {TuiDialogOptions, TuiDialogSize} from './dialog.interfaces';\nimport {TUI_DIALOGS_CLOSE} from './dialog.tokens';\nimport {TuiDialogCloseService} from './dialog-close.service';\n\nconst REQUIRED_ERROR = new Error('Required dialog was dismissed');\n\nfunction toObservable<T>(valueOrStream: Observable<T> | T): Observable<T> {\n return isObservable(valueOrStream) ? valueOrStream : of(valueOrStream);\n}\n\n@Component({\n standalone: true,\n selector: 'tui-dialog',\n imports: [AsyncPipe, NgIf, PolymorpheusOutlet, TuiAutoFocus, TuiButton],\n templateUrl: './dialog.template.html',\n styleUrls: ['./dialog.style.less'],\n // So we don't force OnPush on dialog content\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n providers: [TuiDialogCloseService],\n animations: [tuiSlideInTop, tuiFadeIn],\n host: {\n '[@tuiSlideInTop]': 'slideInTop()',\n '[@tuiFadeIn]': 'slideInTop()',\n '[attr.data-appearance]': 'context.appearance',\n '[attr.data-size]': 'size',\n '[class._centered]': 'header',\n },\n})\nexport class TuiDialogComponent<O, I> {\n private readonly speed = inject(TUI_ANIMATIONS_SPEED);\n\n private readonly animation = {\n value: '',\n params: {\n start: '40px',\n duration: tuiGetDuration(this.speed),\n },\n } as const;\n\n private readonly fullscreenAnimation = {\n value: '',\n params: {\n start: '100vh',\n duration: tuiGetDuration(this.speed),\n },\n } as const;\n\n protected readonly close$ = new Subject<void>();\n protected readonly context = injectContext<TuiPopover<TuiDialogOptions<I>, O>>();\n protected readonly closeWord$ = inject(TUI_CLOSE_WORD);\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly slideInTop = computed(() =>\n this.size === 'fullscreen' || this.size === 'page' || this.isMobile()\n ? this.fullscreenAnimation\n : this.animation,\n );\n\n protected readonly isMobile = toSignal(\n inject(TuiBreakpointService).pipe(map((breakpoint) => breakpoint === 'mobile')),\n );\n\n constructor() {\n merge(\n this.close$.pipe(switchMap(() => toObservable(this.context.closeable))),\n inject(TuiDialogCloseService).pipe(\n switchMap(() => toObservable(this.context.dismissible)),\n ),\n inject(TUI_DIALOGS_CLOSE).pipe(map(TUI_TRUE_HANDLER)),\n )\n .pipe(filter(Boolean), takeUntilDestroyed())\n .subscribe(() => {\n this.close();\n });\n }\n\n protected get size(): TuiDialogSize {\n return this.context.size;\n }\n\n protected get header(): PolymorpheusContent<TuiPopover<TuiDialogOptions<I>, O>> {\n return this.context.header;\n }\n\n private 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 [class.t-heading_closable]=\"context.closeable && !header\"\n [id]=\"context.id\"\n [textContent]=\"context.label\"\n ></h2>\n <section>\n <ng-container *polymorpheusOutlet=\"context.content as text; context: context\">\n <div [innerHTML]=\"text\"></div>\n <div class=\"t-buttons\">\n <button\n size=\"m\"\n tuiAutoFocus\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.complete()\"\n >\n {{ context.data?.button || 'OK' }}\n </button>\n </div>\n </ng-container>\n </section>\n</div>\n<div class=\"t-filler\"></div>\n\n<!-- Close button is insensitive to `context.closeable === Observable<false>` by design -->\n<button\n *ngIf=\"context.closeable\"\n automation-id=\"tui-dialog__close\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [appearance]=\"isMobile() ? 'icon' : 'neutral'\"\n [iconStart]=\"icons.close\"\n [size]=\"isMobile() ? 'xs' : 's'\"\n [style.border-radius.%]=\"100\"\n (click)=\"close$.next()\"\n (mousedown.prevent.zoneless)=\"(0)\"\n>\n {{ closeWord$ | async }}\n</button>\n","import {inject, Injectable} from '@angular/core';\nimport {TuiPopoverService} from '@taiga-ui/cdk/services';\n\nimport {TuiDialogComponent} from './dialog.component';\nimport type {TuiDialogOptions} from './dialog.interfaces';\nimport {TUI_DIALOG_OPTIONS, TUI_DIALOGS} from './dialog.tokens';\n\n@Injectable({\n providedIn: 'root',\n useFactory: () =>\n new TuiDialogService(TUI_DIALOGS, TuiDialogComponent, inject(TUI_DIALOG_OPTIONS)),\n})\nexport class TuiDialogService extends TuiPopoverService<TuiDialogOptions<any>> {}\n","import {Directive} from '@angular/core';\nimport {TuiPopoverDirective} from '@taiga-ui/cdk/directives/popover';\nimport {tuiAsPopover} from '@taiga-ui/cdk/services';\n\nimport type {TuiDialogOptions} from './dialog.interfaces';\nimport {TuiDialogService} from './dialog.service';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiDialog]',\n inputs: ['options: tuiDialogOptions', 'open: tuiDialog'],\n outputs: ['openChange: tuiDialogChange'],\n providers: [tuiAsPopover(TuiDialogService)],\n})\nexport class TuiDialog<T> extends TuiPopoverDirective<TuiDialogOptions<T>> {}\n","import type {Injector} from '@angular/core';\nimport {assertInInjectionContext, inject, INJECTOR} from '@angular/core';\nimport {PolymorpheusComponent} from '@taiga-ui/polymorpheus';\nimport type {Observable} from 'rxjs';\n\nimport type {TuiDialogContext, TuiDialogOptions} from './dialog.interfaces';\nimport {TuiDialogService} from './dialog.service';\n\ntype SingleUnionOrNever<T, U = T> = [T] extends [never]\n ? never\n : T extends U\n ? [U] extends [T]\n ? T\n : never\n : never;\n\ntype ReplaceAny<T> = 0 extends T & 1 ? void : T;\n\ntype ContextKeys<T> = {\n [K in keyof T]: ReplaceAny<T[K]> extends TuiDialogContext<any, any> ? K : never;\n}[keyof T];\n\ntype AssertNotMultipleContexts<T, K extends keyof T> = [K] extends [never]\n ? new (...args: any[]) => T\n : [SingleUnionOrNever<K>] extends [never]\n ? 'Component has multiple context. Cannot determine the type...'\n : new (...args: any[]) => T;\n\ntype ExtractDialogData<T, K extends keyof T = ContextKeys<T>> = [K] extends [never]\n ? void\n : [SingleUnionOrNever<K>] extends [never]\n ? never\n : T[K] extends TuiDialogContext<any, infer D>\n ? D\n : void;\n\ntype ExtractDialogResult<T, K extends keyof T = ContextKeys<T>> = [K] extends [never]\n ? void\n : [SingleUnionOrNever<K>] extends [never]\n ? never\n : T[K] extends TuiDialogContext<infer R, any>\n ? R\n : void;\n\ntype Options<T> = Omit<TuiDialogOptions<T>, 'data'> & {injector: Injector};\n\nexport function tuiDialog<\n T,\n K extends ContextKeys<T>,\n D extends ExtractDialogData<T, K>,\n R extends ExtractDialogResult<T, K>,\n>(\n component: AssertNotMultipleContexts<T, K>,\n {injector, ...options}: Partial<Options<D>> = {},\n): (data: D) => Observable<R> {\n if (!injector) {\n assertInInjectionContext(tuiDialog);\n injector = inject(INJECTOR);\n }\n\n const dialogService = injector.get(TuiDialogService);\n\n return (data) =>\n dialogService.open(\n new PolymorpheusComponent(component as new () => T, injector),\n {\n ...options,\n data,\n },\n );\n}\n","import {NgForOf} from '@angular/common';\nimport type {Signal} from '@angular/core';\nimport {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {TuiFocusTrap} from '@taiga-ui/cdk/directives/focus-trap';\nimport type {TuiPopover} from '@taiga-ui/cdk/services';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiHost} from '@taiga-ui/core/animations';\nimport {TuiScrollControls, TuiScrollRef} from '@taiga-ui/core/components/scrollbar';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_DIALOGS} from './dialog.tokens';\n\n@Component({\n standalone: true,\n selector: 'tui-dialogs',\n imports: [NgForOf, PolymorpheusOutlet, TuiFocusTrap, TuiScrollControls, TuiScrollRef],\n templateUrl: './dialogs.template.html',\n styleUrls: ['./dialogs.style.less'],\n // So that we do not force OnPush on custom dialogs\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n animations: [tuiHost],\n host: {\n '(keydown.zoneless)': 'el.scrollTop = el.scrollHeight / 2',\n },\n})\nexport class TuiDialogs {\n protected readonly el = tuiInjectElement();\n protected readonly dialogs: Signal<ReadonlyArray<TuiPopover<any, any>>> = toSignal(\n inject(TUI_DIALOGS),\n {initialValue: []},\n );\n}\n","<div\n class=\"t-overlay\"\n [class.t-overlay_visible]=\"dialogs().length\"\n></div>\n<section\n *ngFor=\"let item of dialogs()\"\n aria-modal=\"true\"\n role=\"dialog\"\n tuiFocusTrap\n tuiScrollRef\n class=\"t-dialog\"\n @tuiHost\n [attr.aria-labelledby]=\"item.id\"\n>\n <ng-container *polymorpheusOutlet=\"item.component; context: item\" />\n <tui-scroll-controls class=\"t-scrollbars\" />\n</section>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAQO,MAAM,WAAW,GAAG,cAAc,CACrC,IAAI,eAAe,CAAsC,EAAE,CAAC,EAC9D;AAEW,MAAA,0BAA0B,GAA2B;AAC9D,IAAA,UAAU,EAAE,EAAE;AACd,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,QAAQ,EAAE,KAAK;AACf,IAAA,SAAS,EAAE,IAAI;AACf,IAAA,WAAW,EAAE,IAAI;AACjB,IAAA,KAAK,EAAE,EAAE;AACT,IAAA,MAAM,EAAE,EAAE;AACV,IAAA,IAAI,EAAE,SAAS;EACjB;AAEF;;AAEG;MACU,iBAAiB,GAAG,cAAc,CAAsB,KAAK,EAAE;AAE5E;;AAEG;MACU,kBAAkB,GAAG,cAAc,CAAC,0BAA0B,EAAE;AAEvE,SAAU,wBAAwB,CACpC,OAA2C,EA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,WAAA,EAAA,IAAA,EAAE,YAAY,EAAA,QAAA,EAAA,gBAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAE,iBAAiB,EAAE,QAAA,EAAA,qBAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,YAAY,EAMxE,QAAA,EAAA,gBAAA,EAAA,CAAA,EAAA,UAAA,EAAA,CAAC,OAAO,CAAC,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,OAAA,EAAA,CAAA,CAAA,EAAA;;4FAKZ,UAAU,EAAA,UAAA,EAAA,CAAA;kBAdtB,SAAS;iCACM,IAAI,EAAA,QAAA,EACN,aAAa,EACd,OAAA,EAAA,CAAC,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,iBAAiB,EAAE,YAAY,CAAC,mBAKpE,uBAAuB,CAAC,OAAO,EACpC,UAAA,EAAA,CAAC,OAAO,CAAC,EACf,IAAA,EAAA;AACF,wBAAA,oBAAoB,EAAE,oCAAoC;AAC7D,qBAAA,EAAA,QAAA,EAAA,6bAAA,EAAA,MAAA,EAAA,CAAA,05CAAA,CAAA,EAAA,CAAA;;;AEzBL;;AAEG;;;;"}
|
|
@@ -43,7 +43,7 @@ class TuiRoot extends TuiPortals {
|
|
|
43
43
|
console.assert(!!inject(EVENT_MANAGER_PLUGINS).find((plugin) => plugin instanceof PreventEventPlugin), 'NG_EVENT_PLUGINS is missing from global providers');
|
|
44
44
|
}
|
|
45
45
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiRoot, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
46
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiRoot, isStandalone: true, selector: "tui-root", host: { attributes: { "data-tui-version": "4.
|
|
46
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiRoot, isStandalone: true, selector: "tui-root", host: { attributes: { "data-tui-version": "4.25.0" }, listeners: { "touchstart.passive.zoneless": "0" }, properties: { "style.--tui-duration.ms": "duration", "style.--tui-scroll-behavior": "reducedMotion ? \"auto\" : \"smooth\"", "class._mobile": "isMobileRes()" } }, usesInheritance: true, hostDirectives: [{ directive: i1.TuiPlatform }, { directive: i2.TuiVisualViewport }, { directive: i3.TuiFontSize }], ngImport: i0, template: "<div class=\"t-root-content\"><ng-content /></div>\n<tui-scroll-controls\n *ngIf=\"scrollbars\"\n class=\"t-root-scrollbar\"\n/>\n<ng-container #viewContainer />\n<ng-content select=\"tuiOverContent\" />\n<tui-dialogs />\n<ng-content select=\"tuiOverDialogs\" />\n<tui-alerts />\n<ng-content select=\"tuiOverAlerts\" />\n<tui-dropdowns />\n<ng-content select=\"tuiOverDropdowns\" />\n<tui-hints />\n<ng-content select=\"tuiOverHints\" />\n", styles: ["@keyframes tuiPresent{to{content:\"\"}}@keyframes tuiSkeletonVibe{to{opacity:.5}}.tui-zero-scrollbar{scrollbar-width:none;-ms-overflow-style:none}.tui-zero-scrollbar::-webkit-scrollbar,.tui-zero-scrollbar::-webkit-scrollbar-thumb{display:none}body,input{margin:0}tui-root{position:relative;display:block;font:var(--tui-font-text-s);color:var(--tui-text-primary);flex:1;border-image:conic-gradient(var(--tui-background-base) 0 0) fill 0/0/0 0 100vh 0;-webkit-tap-highlight-color:transparent}tui-root>.t-root-scrollbar{position:fixed;top:0;left:0;bottom:0;right:0;z-index:0;display:none;margin:0}[data-tui-theme] tui-root>.t-root-scrollbar{display:block}.t-root-content{position:relative;top:var(--t-root-top);block-size:100%;isolation:isolate}.t-root-content>*{--t-root-top: 0}[tuiDropdownButton][tuiDropdownButton]{display:none}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: TuiAlerts, selector: "tui-alerts" }, { kind: "component", type: TuiDialogs, selector: "tui-dialogs" }, { kind: "component", type: TuiDropdowns, selector: "tui-dropdowns" }, { kind: "component", type: TuiHints, selector: "tui-hints" }, { kind: "component", type: TuiScrollControls, selector: "tui-scroll-controls" }], viewProviders: [tuiAsPortal(TuiPopupService)], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
|
|
47
47
|
}
|
|
48
48
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiRoot, decorators: [{
|
|
49
49
|
type: Component,
|
|
@@ -159,7 +159,7 @@ class TuiTextfieldComponent {
|
|
|
159
159
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiTextfieldComponent, isStandalone: true, selector: "tui-textfield", inputs: { stringify: "stringify", content: "content", fillerSetter: ["filler", "fillerSetter"] }, host: { properties: { "attr.data-size": "options.size()", "class._with-label": "hasLabel", "class._with-template": "content", "class._disabled": "input?.nativeElement.disabled" } }, providers: [
|
|
160
160
|
tuiButtonOptionsProvider({ size: 'xs', appearance: 'icon' }),
|
|
161
161
|
tuiAsDataListHost(TuiTextfieldComponent),
|
|
162
|
-
], queries: [{ propertyName: "label", first: true, predicate: i0.forwardRef(function () { return TuiLabel; }), descendants: true, read: ElementRef }, { propertyName: "control", first: true, predicate: NgControl, descendants: true }, { propertyName: "directive", first: true, predicate: i0.forwardRef(function () { return TuiTextfieldDirective; }), descendants: true, static: true }, { propertyName: "input", first: true, predicate: i0.forwardRef(function () { return TuiTextfieldDirective; }), descendants: true, read: ElementRef, static: true }], viewQueries: [{ propertyName: "vcr", first: true, predicate: ["vcr"], descendants: true, read: ViewContainerRef, static: true }], hostDirectives: [{ directive: i1.TuiDropdownFixed }, { directive: i1.TuiDropdownDirective }, { directive: i1.TuiWithDropdownOpen }, { directive: TuiWithTextfieldDropdown }, { directive: i3.TuiWithIcons }], ngImport: i0, template: "<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n", styles: ["tui-textfield{transition-property:color;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;--t-height: var(--tui-height-l);--t-padding: var(--tui-padding-l);position:relative;display:flex;align-items:center;pointer-events:none;cursor:pointer;block-size:var(--t-height);color:var(--tui-text-tertiary);padding:0 var(--t-padding);border-radius:var(--tui-radius-l);font:var(--tui-font-text-m);box-sizing:border-box;gap:.25rem}tui-textfield[style*=\"--t-icon-start:\"]{--t-left: 2.25rem}tui-textfield[style*=\"--t-icon-end:\"]{--t-right: 2.25rem}tui-textfield input,tui-textfield select{font:var(--tui-font-text-m)}tui-textfield[data-size=s]{--t-height: var(--tui-height-s);--t-padding: var(--tui-padding-s);border-radius:var(--tui-radius-m);gap:0;font:var(--tui-font-text-s)}tui-textfield[data-size=s][style*=\"--t-icon-start:\"]{--t-left: 1.25rem}tui-textfield[data-size=s][style*=\"--t-icon-end:\"]{--t-right: 1.25rem}tui-textfield[data-size=s]:before{margin:0 .5rem 0 -.125rem;font-size:1rem}tui-textfield[data-size=s]:after{margin:0 -.175rem 0 .575rem;font-size:1rem}tui-textfield[data-size=s] input,tui-textfield[data-size=s] select{font:var(--tui-font-text-s)}tui-textfield[data-size=s] .t-content{margin-inline-end:-.325rem}tui-textfield[data-size=m]{--t-height: var(--tui-height-m);--t-padding: var(--tui-padding-m);border-radius:var(--tui-radius-m);font:var(--tui-font-text-s)}tui-textfield[data-size=m][style*=\"--t-icon-start:\"]{--t-left: 1.75rem}tui-textfield[data-size=m][style*=\"--t-icon-end:\"]{--t-right: 1.75rem}tui-textfield[data-size=m]:before{margin:0 .125rem 0 -.125rem}tui-textfield[data-size=m]:after{margin:0 -.125rem 0 .25rem}tui-textfield[data-size=m] input,tui-textfield[data-size=m] select{font:var(--tui-font-text-s)}tui-textfield[data-size=m] .t-content{margin-inline-end:-.125rem}tui-textfield:hover{color:var(--tui-text-secondary)}tui-textfield:hover:has(input:read-only),tui-textfield:hover:has(select[data-mode~=readonly]){color:var(--tui-text-tertiary)}tui-textfield:before{z-index:1;margin-inline-end:.5rem}tui-textfield:has(:disabled:not(.t-filler,button,option)):before,tui-textfield:has(:disabled:not(.t-filler,button,option)):after,tui-textfield:has(:disabled:not(.t-filler,button,option)) .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield._disabled:before,tui-textfield._disabled:after,tui-textfield._disabled .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield:has(label:not(:empty)) .t-template,tui-textfield:has(label:not(:empty)) input:defined,tui-textfield:has(label:not(:empty)) select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield:has(label:not(:empty)) .t-template::placeholder,tui-textfield:has(label:not(:empty)) input:defined::placeholder,tui-textfield:has(label:not(:empty)) select:defined::placeholder,tui-textfield:has(label:not(:empty)) .t-template._empty,tui-textfield:has(label:not(:empty)) input:defined._empty,tui-textfield:has(label:not(:empty)) select:defined._empty{color:transparent}tui-textfield._with-label .t-template,tui-textfield._with-label input:defined,tui-textfield._with-label select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield._with-label .t-template::placeholder,tui-textfield._with-label input:defined::placeholder,tui-textfield._with-label select:defined::placeholder,tui-textfield._with-label .t-template._empty,tui-textfield._with-label input:defined._empty,tui-textfield._with-label select:defined._empty{color:transparent}tui-textfield .t-template,tui-textfield input:defined,tui-textfield select:defined{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;box-sizing:border-box;border-radius:inherit;padding:inherit;border:none;text-indent:var(--t-left, 0);padding-inline-end:calc(var(--t-right, var(--t-0, 0rem)) + var(--t-side) + var(--t-padding))}tui-textfield .t-template{display:flex;align-items:center;color:var(--tui-text-primary)}tui-textfield._with-template input,tui-textfield._with-template select{color:transparent!important}tui-textfield input:defined,tui-textfield select:defined{pointer-events:auto;background:transparent}tui-textfield input:defined:read-only~.t-filler,tui-textfield select:defined:read-only~.t-filler{display:none}tui-textfield input:defined:disabled~label,tui-textfield select:defined:disabled~label,tui-textfield input:defined:disabled~.t-content,tui-textfield select:defined:disabled~.t-content{opacity:var(--tui-disabled-opacity)}tui-textfield input:defined:disabled~label>tui-icon,tui-textfield select:defined:disabled~label>tui-icon,tui-textfield input:defined:disabled~.t-content>tui-icon,tui-textfield select:defined:disabled~.t-content>tui-icon{display:none}tui-textfield input:defined:-webkit-autofill~label,tui-textfield select:defined:-webkit-autofill~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown)~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown)~label{font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label{color:var(--tui-text-negative)}tui-textfield input:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear{display:flex}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]._empty,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]~label,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}@supports (-webkit-touch-callout: none){tui-textfield input:defined._ios-fix,tui-textfield select:defined._ios-fix{position:fixed;left:1000rem}}tui-textfield label:not([data-orientation=vertical]){transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;position:relative;display:block;flex:1;font-size:inherit}tui-textfield label:defined,tui-textfield input:defined::placeholder,tui-textfield select:defined._empty{color:var(--tui-text-secondary)}tui-textfield select:not([data-mode~=readonly]){cursor:pointer}tui-textfield button,tui-textfield a{pointer-events:auto}tui-textfield .t-content{display:flex;align-items:center;gap:inherit;margin-inline-start:auto;isolation:isolate;border-radius:inherit}tui-textfield .t-content>tui-icon{pointer-events:auto}tui-textfield .t-clear{display:none;pointer-events:auto}tui-textfield .t-filler:defined{pointer-events:none;background:none;color:var(--tui-text-tertiary);opacity:1}tui-textfield [tuiFluidTypography]{font-weight:700}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: WaResizeObserver, selector: "[waResizeObserver]", inputs: ["box"], outputs: ["waResizeObserver"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
162
|
+
], queries: [{ propertyName: "label", first: true, predicate: i0.forwardRef(function () { return TuiLabel; }), descendants: true, read: ElementRef }, { propertyName: "control", first: true, predicate: NgControl, descendants: true }, { propertyName: "directive", first: true, predicate: i0.forwardRef(function () { return TuiTextfieldDirective; }), descendants: true, static: true }, { propertyName: "input", first: true, predicate: i0.forwardRef(function () { return TuiTextfieldDirective; }), descendants: true, read: ElementRef, static: true }], viewQueries: [{ propertyName: "vcr", first: true, predicate: ["vcr"], descendants: true, read: ViewContainerRef, static: true }], hostDirectives: [{ directive: i1.TuiDropdownFixed }, { directive: i1.TuiDropdownDirective }, { directive: i1.TuiWithDropdownOpen }, { directive: TuiWithTextfieldDropdown }, { directive: i3.TuiWithIcons }], ngImport: i0, template: "<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n", styles: ["tui-textfield{transition-property:color;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;--t-height: var(--tui-height-l);--t-padding: var(--tui-padding-l);position:relative;display:flex;align-items:center;pointer-events:none;cursor:pointer;block-size:var(--t-height);color:var(--tui-text-tertiary);padding:0 var(--t-padding);border-radius:var(--tui-radius-l);font:var(--tui-font-text-m);box-sizing:border-box;gap:.25rem}tui-textfield[style*=\"--t-icon-start:\"]{--t-left: 2.25rem}tui-textfield[style*=\"--t-icon-end:\"]{--t-right: 2.25rem}tui-textfield input,tui-textfield select{font:var(--tui-font-text-m)}tui-textfield[data-size=s]{--t-height: var(--tui-height-s);--t-padding: var(--tui-padding-s);border-radius:var(--tui-radius-m);gap:0;font:var(--tui-font-text-s)}tui-textfield[data-size=s][style*=\"--t-icon-start:\"]{--t-left: 1.25rem}tui-textfield[data-size=s][style*=\"--t-icon-end:\"]{--t-right: 1.25rem}tui-textfield[data-size=s]:before{margin:0 .5rem 0 -.125rem;font-size:1rem}tui-textfield[data-size=s]:after{margin:0 -.175rem 0 .575rem;font-size:1rem}tui-textfield[data-size=s] input,tui-textfield[data-size=s] select{font:var(--tui-font-text-s)}tui-textfield[data-size=s] .t-content{margin-inline-end:-.325rem}tui-textfield[data-size=m]{--t-height: var(--tui-height-m);--t-padding: var(--tui-padding-m);border-radius:var(--tui-radius-m);font:var(--tui-font-text-s)}tui-textfield[data-size=m][style*=\"--t-icon-start:\"]{--t-left: 1.75rem}tui-textfield[data-size=m][style*=\"--t-icon-end:\"]{--t-right: 1.75rem}tui-textfield[data-size=m]:before{margin:0 .125rem 0 -.125rem}tui-textfield[data-size=m]:after{margin:0 -.125rem 0 .25rem}tui-textfield[data-size=m] input,tui-textfield[data-size=m] select{font:var(--tui-font-text-s)}tui-textfield[data-size=m] .t-content{margin-inline-end:-.125rem}tui-textfield:hover{color:var(--tui-text-secondary)}tui-textfield:hover:has(input:read-only),tui-textfield:hover:has(select[data-mode~=readonly]){color:var(--tui-text-tertiary)}tui-textfield:before{z-index:1;margin-inline-end:.5rem}tui-textfield:has(:disabled:not(.t-filler,button,option)):before,tui-textfield:has(:disabled:not(.t-filler,button,option)):after,tui-textfield:has(:disabled:not(.t-filler,button,option)) .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield._disabled:before,tui-textfield._disabled:after,tui-textfield._disabled .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield:has(label:not(:empty)) .t-template,tui-textfield:has(label:not(:empty)) input:defined,tui-textfield:has(label:not(:empty)) select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield:has(label:not(:empty)) .t-template::placeholder,tui-textfield:has(label:not(:empty)) input:defined::placeholder,tui-textfield:has(label:not(:empty)) select:defined::placeholder,tui-textfield:has(label:not(:empty)) .t-template._empty,tui-textfield:has(label:not(:empty)) input:defined._empty,tui-textfield:has(label:not(:empty)) select:defined._empty{color:transparent}tui-textfield._with-label .t-template,tui-textfield._with-label input:defined,tui-textfield._with-label select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield._with-label .t-template::placeholder,tui-textfield._with-label input:defined::placeholder,tui-textfield._with-label select:defined::placeholder,tui-textfield._with-label .t-template._empty,tui-textfield._with-label input:defined._empty,tui-textfield._with-label select:defined._empty{color:transparent}tui-textfield .t-template,tui-textfield input:defined,tui-textfield select:defined{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;box-sizing:border-box;border-radius:inherit;padding:inherit;border:none;text-indent:var(--t-left, 0);padding-inline-end:calc(var(--t-right, 0rem) + var(--t-side) + var(--t-padding))}tui-textfield .t-template{display:flex;align-items:center;color:var(--tui-text-primary)}tui-textfield._with-template input,tui-textfield._with-template select{color:transparent!important}tui-textfield input:defined,tui-textfield select:defined{pointer-events:auto;background:transparent}tui-textfield input:defined:read-only~.t-filler,tui-textfield select:defined:read-only~.t-filler{display:none}tui-textfield input:defined:disabled~label,tui-textfield select:defined:disabled~label,tui-textfield input:defined:disabled~.t-content,tui-textfield select:defined:disabled~.t-content{opacity:var(--tui-disabled-opacity)}tui-textfield input:defined:disabled~label>tui-icon,tui-textfield select:defined:disabled~label>tui-icon,tui-textfield input:defined:disabled~.t-content>tui-icon,tui-textfield select:defined:disabled~.t-content>tui-icon{display:none}tui-textfield input:defined:-webkit-autofill~label,tui-textfield select:defined:-webkit-autofill~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown)~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown)~label{font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label{color:var(--tui-text-negative)}tui-textfield input:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear{display:flex}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]._empty,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]~label,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}@supports (-webkit-touch-callout: none){tui-textfield input:defined._ios-fix,tui-textfield select:defined._ios-fix{position:fixed;left:1000rem}}tui-textfield label:not([data-orientation=vertical]){transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;position:relative;display:block;flex:1;font-size:inherit}tui-textfield label:defined,tui-textfield input:defined::placeholder,tui-textfield select:defined._empty{color:var(--tui-text-secondary)}tui-textfield select:not([data-mode~=readonly]){cursor:pointer}tui-textfield button,tui-textfield a{pointer-events:auto}tui-textfield .t-content{display:flex;align-items:center;gap:inherit;margin-inline-start:auto;isolation:isolate;border-radius:inherit}tui-textfield .t-content>tui-icon{pointer-events:auto}tui-textfield .t-clear{display:none;pointer-events:auto}tui-textfield .t-filler:defined{pointer-events:none;background:none;color:var(--tui-text-tertiary);opacity:1}tui-textfield [tuiFluidTypography]{font-weight:700}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: WaResizeObserver, selector: "[waResizeObserver]", inputs: ["box"], outputs: ["waResizeObserver"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
163
163
|
}
|
|
164
164
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiTextfieldComponent, decorators: [{
|
|
165
165
|
type: Component,
|
|
@@ -177,7 +177,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
177
177
|
'[class._with-label]': 'hasLabel',
|
|
178
178
|
'[class._with-template]': 'content',
|
|
179
179
|
'[class._disabled]': 'input?.nativeElement.disabled',
|
|
180
|
-
}, template: "<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n", styles: ["tui-textfield{transition-property:color;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;--t-height: var(--tui-height-l);--t-padding: var(--tui-padding-l);position:relative;display:flex;align-items:center;pointer-events:none;cursor:pointer;block-size:var(--t-height);color:var(--tui-text-tertiary);padding:0 var(--t-padding);border-radius:var(--tui-radius-l);font:var(--tui-font-text-m);box-sizing:border-box;gap:.25rem}tui-textfield[style*=\"--t-icon-start:\"]{--t-left: 2.25rem}tui-textfield[style*=\"--t-icon-end:\"]{--t-right: 2.25rem}tui-textfield input,tui-textfield select{font:var(--tui-font-text-m)}tui-textfield[data-size=s]{--t-height: var(--tui-height-s);--t-padding: var(--tui-padding-s);border-radius:var(--tui-radius-m);gap:0;font:var(--tui-font-text-s)}tui-textfield[data-size=s][style*=\"--t-icon-start:\"]{--t-left: 1.25rem}tui-textfield[data-size=s][style*=\"--t-icon-end:\"]{--t-right: 1.25rem}tui-textfield[data-size=s]:before{margin:0 .5rem 0 -.125rem;font-size:1rem}tui-textfield[data-size=s]:after{margin:0 -.175rem 0 .575rem;font-size:1rem}tui-textfield[data-size=s] input,tui-textfield[data-size=s] select{font:var(--tui-font-text-s)}tui-textfield[data-size=s] .t-content{margin-inline-end:-.325rem}tui-textfield[data-size=m]{--t-height: var(--tui-height-m);--t-padding: var(--tui-padding-m);border-radius:var(--tui-radius-m);font:var(--tui-font-text-s)}tui-textfield[data-size=m][style*=\"--t-icon-start:\"]{--t-left: 1.75rem}tui-textfield[data-size=m][style*=\"--t-icon-end:\"]{--t-right: 1.75rem}tui-textfield[data-size=m]:before{margin:0 .125rem 0 -.125rem}tui-textfield[data-size=m]:after{margin:0 -.125rem 0 .25rem}tui-textfield[data-size=m] input,tui-textfield[data-size=m] select{font:var(--tui-font-text-s)}tui-textfield[data-size=m] .t-content{margin-inline-end:-.125rem}tui-textfield:hover{color:var(--tui-text-secondary)}tui-textfield:hover:has(input:read-only),tui-textfield:hover:has(select[data-mode~=readonly]){color:var(--tui-text-tertiary)}tui-textfield:before{z-index:1;margin-inline-end:.5rem}tui-textfield:has(:disabled:not(.t-filler,button,option)):before,tui-textfield:has(:disabled:not(.t-filler,button,option)):after,tui-textfield:has(:disabled:not(.t-filler,button,option)) .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield._disabled:before,tui-textfield._disabled:after,tui-textfield._disabled .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield:has(label:not(:empty)) .t-template,tui-textfield:has(label:not(:empty)) input:defined,tui-textfield:has(label:not(:empty)) select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield:has(label:not(:empty)) .t-template::placeholder,tui-textfield:has(label:not(:empty)) input:defined::placeholder,tui-textfield:has(label:not(:empty)) select:defined::placeholder,tui-textfield:has(label:not(:empty)) .t-template._empty,tui-textfield:has(label:not(:empty)) input:defined._empty,tui-textfield:has(label:not(:empty)) select:defined._empty{color:transparent}tui-textfield._with-label .t-template,tui-textfield._with-label input:defined,tui-textfield._with-label select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield._with-label .t-template::placeholder,tui-textfield._with-label input:defined::placeholder,tui-textfield._with-label select:defined::placeholder,tui-textfield._with-label .t-template._empty,tui-textfield._with-label input:defined._empty,tui-textfield._with-label select:defined._empty{color:transparent}tui-textfield .t-template,tui-textfield input:defined,tui-textfield select:defined{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;box-sizing:border-box;border-radius:inherit;padding:inherit;border:none;text-indent:var(--t-left, 0);padding-inline-end:calc(var(--t-right, var(--t-0, 0rem)) + var(--t-side) + var(--t-padding))}tui-textfield .t-template{display:flex;align-items:center;color:var(--tui-text-primary)}tui-textfield._with-template input,tui-textfield._with-template select{color:transparent!important}tui-textfield input:defined,tui-textfield select:defined{pointer-events:auto;background:transparent}tui-textfield input:defined:read-only~.t-filler,tui-textfield select:defined:read-only~.t-filler{display:none}tui-textfield input:defined:disabled~label,tui-textfield select:defined:disabled~label,tui-textfield input:defined:disabled~.t-content,tui-textfield select:defined:disabled~.t-content{opacity:var(--tui-disabled-opacity)}tui-textfield input:defined:disabled~label>tui-icon,tui-textfield select:defined:disabled~label>tui-icon,tui-textfield input:defined:disabled~.t-content>tui-icon,tui-textfield select:defined:disabled~.t-content>tui-icon{display:none}tui-textfield input:defined:-webkit-autofill~label,tui-textfield select:defined:-webkit-autofill~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown)~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown)~label{font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label{color:var(--tui-text-negative)}tui-textfield input:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear{display:flex}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]._empty,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]~label,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}@supports (-webkit-touch-callout: none){tui-textfield input:defined._ios-fix,tui-textfield select:defined._ios-fix{position:fixed;left:1000rem}}tui-textfield label:not([data-orientation=vertical]){transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;position:relative;display:block;flex:1;font-size:inherit}tui-textfield label:defined,tui-textfield input:defined::placeholder,tui-textfield select:defined._empty{color:var(--tui-text-secondary)}tui-textfield select:not([data-mode~=readonly]){cursor:pointer}tui-textfield button,tui-textfield a{pointer-events:auto}tui-textfield .t-content{display:flex;align-items:center;gap:inherit;margin-inline-start:auto;isolation:isolate;border-radius:inherit}tui-textfield .t-content>tui-icon{pointer-events:auto}tui-textfield .t-clear{display:none;pointer-events:auto}tui-textfield .t-filler:defined{pointer-events:none;background:none;color:var(--tui-text-tertiary);opacity:1}tui-textfield [tuiFluidTypography]{font-weight:700}\n"] }]
|
|
180
|
+
}, template: "<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n", styles: ["tui-textfield{transition-property:color;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;--t-height: var(--tui-height-l);--t-padding: var(--tui-padding-l);position:relative;display:flex;align-items:center;pointer-events:none;cursor:pointer;block-size:var(--t-height);color:var(--tui-text-tertiary);padding:0 var(--t-padding);border-radius:var(--tui-radius-l);font:var(--tui-font-text-m);box-sizing:border-box;gap:.25rem}tui-textfield[style*=\"--t-icon-start:\"]{--t-left: 2.25rem}tui-textfield[style*=\"--t-icon-end:\"]{--t-right: 2.25rem}tui-textfield input,tui-textfield select{font:var(--tui-font-text-m)}tui-textfield[data-size=s]{--t-height: var(--tui-height-s);--t-padding: var(--tui-padding-s);border-radius:var(--tui-radius-m);gap:0;font:var(--tui-font-text-s)}tui-textfield[data-size=s][style*=\"--t-icon-start:\"]{--t-left: 1.25rem}tui-textfield[data-size=s][style*=\"--t-icon-end:\"]{--t-right: 1.25rem}tui-textfield[data-size=s]:before{margin:0 .5rem 0 -.125rem;font-size:1rem}tui-textfield[data-size=s]:after{margin:0 -.175rem 0 .575rem;font-size:1rem}tui-textfield[data-size=s] input,tui-textfield[data-size=s] select{font:var(--tui-font-text-s)}tui-textfield[data-size=s] .t-content{margin-inline-end:-.325rem}tui-textfield[data-size=m]{--t-height: var(--tui-height-m);--t-padding: var(--tui-padding-m);border-radius:var(--tui-radius-m);font:var(--tui-font-text-s)}tui-textfield[data-size=m][style*=\"--t-icon-start:\"]{--t-left: 1.75rem}tui-textfield[data-size=m][style*=\"--t-icon-end:\"]{--t-right: 1.75rem}tui-textfield[data-size=m]:before{margin:0 .125rem 0 -.125rem}tui-textfield[data-size=m]:after{margin:0 -.125rem 0 .25rem}tui-textfield[data-size=m] input,tui-textfield[data-size=m] select{font:var(--tui-font-text-s)}tui-textfield[data-size=m] .t-content{margin-inline-end:-.125rem}tui-textfield:hover{color:var(--tui-text-secondary)}tui-textfield:hover:has(input:read-only),tui-textfield:hover:has(select[data-mode~=readonly]){color:var(--tui-text-tertiary)}tui-textfield:before{z-index:1;margin-inline-end:.5rem}tui-textfield:has(:disabled:not(.t-filler,button,option)):before,tui-textfield:has(:disabled:not(.t-filler,button,option)):after,tui-textfield:has(:disabled:not(.t-filler,button,option)) .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield._disabled:before,tui-textfield._disabled:after,tui-textfield._disabled .t-template{opacity:var(--tui-disabled-opacity)}tui-textfield:has(label:not(:empty)) .t-template,tui-textfield:has(label:not(:empty)) input:defined,tui-textfield:has(label:not(:empty)) select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield:has(label:not(:empty)) .t-template::placeholder,tui-textfield:has(label:not(:empty)) input:defined::placeholder,tui-textfield:has(label:not(:empty)) select:defined::placeholder,tui-textfield:has(label:not(:empty)) .t-template._empty,tui-textfield:has(label:not(:empty)) input:defined._empty,tui-textfield:has(label:not(:empty)) select:defined._empty{color:transparent}tui-textfield._with-label .t-template,tui-textfield._with-label input:defined,tui-textfield._with-label select:defined{padding-top:calc(var(--t-height) / 3)}tui-textfield._with-label .t-template::placeholder,tui-textfield._with-label input:defined::placeholder,tui-textfield._with-label select:defined::placeholder,tui-textfield._with-label .t-template._empty,tui-textfield._with-label input:defined._empty,tui-textfield._with-label select:defined._empty{color:transparent}tui-textfield .t-template,tui-textfield input:defined,tui-textfield select:defined{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;-webkit-appearance:none;appearance:none;box-sizing:border-box;border-radius:inherit;padding:inherit;border:none;text-indent:var(--t-left, 0);padding-inline-end:calc(var(--t-right, 0rem) + var(--t-side) + var(--t-padding))}tui-textfield .t-template{display:flex;align-items:center;color:var(--tui-text-primary)}tui-textfield._with-template input,tui-textfield._with-template select{color:transparent!important}tui-textfield input:defined,tui-textfield select:defined{pointer-events:auto;background:transparent}tui-textfield input:defined:read-only~.t-filler,tui-textfield select:defined:read-only~.t-filler{display:none}tui-textfield input:defined:disabled~label,tui-textfield select:defined:disabled~label,tui-textfield input:defined:disabled~.t-content,tui-textfield select:defined:disabled~.t-content{opacity:var(--tui-disabled-opacity)}tui-textfield input:defined:disabled~label>tui-icon,tui-textfield select:defined:disabled~label>tui-icon,tui-textfield input:defined:disabled~.t-content>tui-icon,tui-textfield select:defined:disabled~.t-content>tui-icon{display:none}tui-textfield input:defined:-webkit-autofill~label,tui-textfield select:defined:-webkit-autofill~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown)~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown)~label{font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:-webkit-autofill:not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled)[data-mode~=invalid]~label,tui-textfield input:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:-webkit-autofill:invalid:not(:disabled):not([data-mode])~label,tui-textfield input:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label,tui-textfield select:defined:not(._empty):not(:placeholder-shown):invalid:not(:disabled):not([data-mode])~label{color:var(--tui-text-negative)}tui-textfield input:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:-webkit-autofill:not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield input:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear,tui-textfield select:defined:not(._empty):not(:placeholder-shown):not(:disabled):not([data-mode~=readonly])~.t-content .t-clear{display:flex}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])::placeholder,tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label,tui-textfield select:defined:not([data-mode~=readonly]):focus-visible:not([data-focus=false])~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]._empty,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[data-focus=true]~label,tui-textfield select:defined:not([data-mode~=readonly])[data-focus=true]~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused::placeholder,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)._empty,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused._empty{color:var(--tui-text-tertiary)}tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]:not(._focused):has(:focus-visible)~label,tui-textfield input:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label,tui-textfield select:defined:not([data-mode~=readonly])[tuiWrapper]._focused~label{color:var(--tui-text-primary)!important;font-size:.83em;transform:translateY(-.7em)}@supports (-webkit-touch-callout: none){tui-textfield input:defined._ios-fix,tui-textfield select:defined._ios-fix{position:fixed;left:1000rem}}tui-textfield label:not([data-orientation=vertical]){transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;position:relative;display:block;flex:1;font-size:inherit}tui-textfield label:defined,tui-textfield input:defined::placeholder,tui-textfield select:defined._empty{color:var(--tui-text-secondary)}tui-textfield select:not([data-mode~=readonly]){cursor:pointer}tui-textfield button,tui-textfield a{pointer-events:auto}tui-textfield .t-content{display:flex;align-items:center;gap:inherit;margin-inline-start:auto;isolation:isolate;border-radius:inherit}tui-textfield .t-content>tui-icon{pointer-events:auto}tui-textfield .t-clear{display:none;pointer-events:auto}tui-textfield .t-filler:defined{pointer-events:none;background:none;color:var(--tui-text-tertiary);opacity:1}tui-textfield [tuiFluidTypography]{font-weight:700}\n"] }]
|
|
181
181
|
}], propDecorators: { label: [{
|
|
182
182
|
type: ContentChild,
|
|
183
183
|
args: [forwardRef(() => TuiLabel), { read: ElementRef }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-textfield.mjs","sources":["../../../projects/core/components/textfield/textfield.options.ts","../../../projects/core/components/textfield/textfield-dropdown.directive.ts","../../../projects/core/components/textfield/textfield.component.ts","../../../projects/core/components/textfield/textfield.template.html","../../../projects/core/components/textfield/textfield.directive.ts","../../../projects/core/components/textfield/select.directive.ts","../../../projects/core/components/textfield/select.template.html","../../../projects/core/components/textfield/textfield.ts","../../../projects/core/components/textfield/textfield-content.directive.ts","../../../projects/core/components/textfield/taiga-ui-core-components-textfield.ts"],"sourcesContent":["import type {Provider, WritableSignal} from '@angular/core';\nimport {Directive, inject, Input, Optional, signal, SkipSelf} from '@angular/core';\nimport {tuiCreateToken, tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\nimport type {TuiSizeL, TuiSizeS} from '@taiga-ui/core/types';\n\nconst DEFAULT = {\n appearance: 'textfield',\n size: 'l',\n cleaner: true,\n} as const;\n\nexport interface TuiTextfieldOptions {\n readonly appearance: WritableSignal<string>;\n readonly size: WritableSignal<TuiSizeL | TuiSizeS>;\n readonly cleaner: WritableSignal<boolean>;\n}\n\nexport const TUI_TEXTFIELD_OPTIONS = tuiCreateToken<TuiTextfieldOptions>({\n appearance: signal(DEFAULT.appearance),\n size: signal(DEFAULT.size),\n cleaner: signal(DEFAULT.cleaner),\n});\n\nexport function tuiTextfieldOptionsProvider(\n options: Partial<TuiTextfieldOptions>,\n): Provider {\n return {\n provide: TUI_TEXTFIELD_OPTIONS,\n deps: [[new Optional(), new SkipSelf(), TUI_TEXTFIELD_OPTIONS]],\n useFactory: (parent: TuiTextfieldOptions | null) => ({\n appearance: signal(parent?.appearance() ?? DEFAULT.appearance),\n size: signal(parent?.size() ?? DEFAULT.size),\n cleaner: signal(parent?.cleaner() ?? DEFAULT.cleaner),\n ...options,\n }),\n };\n}\n\n@Directive({\n standalone: true,\n selector: '[tuiTextfieldAppearance],[tuiTextfieldSize],[tuiTextfieldCleaner]',\n providers: [tuiProvide(TUI_TEXTFIELD_OPTIONS, TuiTextfieldOptionsDirective)],\n})\nexport class TuiTextfieldOptionsDirective implements TuiTextfieldOptions {\n private readonly options = inject(TUI_TEXTFIELD_OPTIONS, {skipSelf: true});\n\n // TODO: refactor to signal inputs after Angular update\n public appearance = signal(this.options.appearance());\n public size = signal(this.options.size());\n public cleaner = signal(this.options.cleaner());\n\n @Input()\n public set tuiTextfieldAppearance(appearance: string) {\n this.appearance.set(appearance);\n }\n\n @Input()\n public set tuiTextfieldSize(size: TuiSizeL | TuiSizeS) {\n this.size.set(size);\n }\n\n @Input()\n public set tuiTextfieldCleaner(enabled: boolean) {\n this.cleaner.set(enabled);\n }\n}\n","import {ContentChild, Directive, TemplateRef} from '@angular/core';\nimport {tuiDropdown} from '@taiga-ui/core/directives/dropdown';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiTextfieldDropdown]',\n})\nexport class TuiTextfieldDropdownDirective {}\n\n@Directive({\n standalone: true,\n})\nexport class TuiWithTextfieldDropdown {\n private readonly dropdown = tuiDropdown(null);\n\n @ContentChild(TuiTextfieldDropdownDirective, {read: TemplateRef, descendants: true})\n protected set template(template: PolymorpheusContent) {\n this.dropdown.set(template);\n }\n}\n","import {NgIf} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n ContentChild,\n ElementRef,\n forwardRef,\n inject,\n Input,\n signal,\n ViewChild,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {NgControl} from '@angular/forms';\nimport {WaResizeObserver} from '@ng-web-apis/resize-observer';\nimport {tuiInjectId} from '@taiga-ui/cdk/services';\nimport type {TuiContext, TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiPx} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton, tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport type {TuiDataListHost} from '@taiga-ui/core/components/data-list';\nimport {tuiAsDataListHost} from '@taiga-ui/core/components/data-list';\nimport {TuiLabel} from '@taiga-ui/core/components/label';\nimport {\n TuiDropdownDirective,\n TuiDropdownFixed,\n tuiDropdownOpen,\n TuiWithDropdownOpen,\n} from '@taiga-ui/core/directives/dropdown';\nimport {TuiWithIcons} from '@taiga-ui/core/directives/icons';\nimport {TUI_CLEAR_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport type {TuiSizeL, TuiSizeS} from '@taiga-ui/core/types';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TuiTextfieldDirective} from './textfield.directive';\nimport {TUI_TEXTFIELD_OPTIONS} from './textfield.options';\nimport {TuiWithTextfieldDropdown} from './textfield-dropdown.directive';\n\n@Component({\n standalone: true,\n selector: 'tui-textfield',\n imports: [NgIf, PolymorpheusOutlet, TuiButton, WaResizeObserver],\n templateUrl: './textfield.template.html',\n styles: ['@import \"@taiga-ui/core/styles/components/textfield.less\";'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiButtonOptionsProvider({size: 'xs', appearance: 'icon'}),\n tuiAsDataListHost(TuiTextfieldComponent),\n ],\n hostDirectives: [\n TuiDropdownFixed,\n TuiDropdownDirective,\n TuiWithDropdownOpen,\n TuiWithTextfieldDropdown,\n TuiWithIcons,\n ],\n host: {\n '[attr.data-size]': 'options.size()',\n '[class._with-label]': 'hasLabel',\n '[class._with-template]': 'content',\n '[class._disabled]': 'input?.nativeElement.disabled',\n },\n})\nexport class TuiTextfieldComponent<T> implements TuiDataListHost<T> {\n // TODO: refactor to signal inputs after Angular update\n private readonly filler = signal('');\n private readonly autoId = tuiInjectId();\n private readonly open = tuiDropdownOpen();\n private readonly focusedIn = tuiFocusedIn(tuiInjectElement());\n\n @ContentChild(forwardRef(() => TuiLabel), {read: ElementRef})\n protected readonly label?: ElementRef<HTMLElement>;\n\n @ContentChild(NgControl)\n protected readonly control?: NgControl;\n\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly clear = toSignal(inject(TUI_CLEAR_WORD));\n\n protected computedFiller = computed(() => {\n const value = this.directive?.value() || '';\n const filledValue = value + this.filler().slice(value.length);\n\n return filledValue.length > value.length ? filledValue : '';\n });\n\n protected showFiller = computed<boolean>(\n () =>\n this.focused() &&\n !!this.computedFiller() &&\n (!!this.directive?.value() || !this.input?.nativeElement.placeholder),\n );\n\n @ViewChild('vcr', {read: ViewContainerRef, static: true})\n public readonly vcr?: ViewContainerRef;\n\n @ContentChild(forwardRef(() => TuiTextfieldDirective), {static: true})\n public readonly directive?: TuiTextfieldDirective<T>;\n\n @ContentChild(forwardRef(() => TuiTextfieldDirective), {\n read: ElementRef,\n static: true,\n })\n public readonly input?: ElementRef<HTMLInputElement>;\n\n @Input()\n public stringify: TuiStringHandler<T> = String;\n\n @Input()\n public content: PolymorpheusContent<TuiContext<T>>;\n\n public readonly focused = computed(() => this.open() || this.focusedIn());\n public readonly options = inject(TUI_TEXTFIELD_OPTIONS);\n public readonly el = tuiInjectElement();\n\n @Input('filler')\n public set fillerSetter(filler: string) {\n this.filler.set(filler);\n }\n\n public get id(): string {\n return this.input?.nativeElement.id || this.autoId;\n }\n\n public get size(): TuiSizeL | TuiSizeS {\n return this.options.size();\n }\n\n public handleOption(option: T): void {\n this.directive?.setValue(option);\n this.open.set(false);\n }\n\n protected get hasLabel(): boolean {\n return Boolean(this.label?.nativeElement?.childNodes.length);\n }\n\n protected onResize({contentRect}: ResizeObserverEntry): void {\n this.el.style.setProperty('--t-side', tuiPx(contentRect.width));\n }\n}\n","<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n","import type {OnChanges} from '@angular/core';\nimport {computed, Directive, inject, Input, signal} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {NgControl} from '@angular/forms';\nimport {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';\nimport {tuiControlValue} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {\n TuiAppearance,\n tuiAppearance,\n tuiAppearanceFocus,\n tuiAppearanceMode,\n tuiAppearanceState,\n} from '@taiga-ui/core/directives/appearance';\nimport type {TuiInteractiveState} from '@taiga-ui/core/types';\nimport {fromEvent, map, merge, switchMap, timer} from 'rxjs';\n\nimport {TuiTextfieldComponent} from './textfield.component';\nimport {TUI_TEXTFIELD_OPTIONS} from './textfield.options';\n\n@Directive()\nexport class TuiTextfieldBase<T> implements OnChanges {\n // TODO: refactor to signal inputs after Angular update\n private readonly focused = signal<boolean | null>(null);\n\n protected readonly control = inject(NgControl, {optional: true});\n protected readonly a = tuiAppearance(inject(TUI_TEXTFIELD_OPTIONS).appearance);\n protected readonly s = tuiAppearanceState(null);\n protected readonly m = tuiAppearanceMode(this.mode);\n protected readonly f = tuiAppearanceFocus(\n computed(() => this.focused() ?? this.textfield.focused()),\n );\n\n protected readonly el = tuiInjectElement<HTMLInputElement>();\n protected readonly textfield: TuiTextfieldComponent<T> =\n inject(TuiTextfieldComponent);\n\n @Input()\n public readOnly = false;\n\n @Input()\n public invalid: boolean | null = null;\n\n public readonly value = toSignal(\n merge(\n fromEvent(this.el, 'input'),\n timer(0) // https://github.com/angular/angular/issues/54418\n .pipe(switchMap(() => tuiControlValue(this.control))),\n ).pipe(map(() => this.el.value)),\n {initialValue: this.el.value},\n );\n\n @Input('focused')\n public set focusedSetter(focused: boolean | null) {\n this.focused.set(focused);\n }\n\n @Input('state')\n public set stateSetter(state: TuiInteractiveState | null) {\n this.s.set(state);\n }\n\n public get mode(): string | null {\n if (this.readOnly) {\n return 'readonly';\n }\n\n if (this.invalid === false) {\n return 'valid';\n }\n\n if (this.invalid) {\n return 'invalid';\n }\n\n return null;\n }\n\n // TODO: refactor to signal inputs after Angular update\n public ngOnChanges(): void {\n this.m.set(this.mode);\n }\n\n public setValue(value: T | null): void {\n this.el.focus();\n this.el.select();\n\n if (value == null) {\n this.el.ownerDocument.execCommand('delete');\n } else {\n this.el.ownerDocument.execCommand(\n 'insertText',\n false,\n this.textfield.stringify(value),\n );\n }\n }\n}\n\n@Directive({\n standalone: true,\n // TODO: Remove :not in v.5\n selector:\n 'input[tuiTextfield]:not([tuiInputCard]):not([tuiInputExpire]):not([tuiInputCVC])',\n hostDirectives: [TuiNativeValidator, TuiAppearance],\n host: {\n '[id]': 'textfield.id',\n '[readOnly]': 'readOnly',\n '[class._empty]': 'el.value === \"\"',\n '(input)': '0',\n '(focusin)': '0',\n '(focusout)': '0',\n },\n})\nexport class TuiTextfieldDirective<T> extends TuiTextfieldBase<T> {}\n\n@Directive({\n standalone: true,\n hostDirectives: [\n {\n directive: TuiTextfieldDirective,\n inputs: ['invalid', 'focused', 'readOnly', 'state'],\n },\n ],\n})\nexport class TuiWithTextfield {}\n","import {CommonModule} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {WA_NAVIGATOR} from '@ng-web-apis/common';\nimport {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiAppearance} from '@taiga-ui/core/directives/appearance';\n\nimport {TuiTextfieldBase, TuiTextfieldDirective} from './textfield.directive';\n\n@Component({\n standalone: true,\n selector: 'select[tuiTextfield]',\n imports: [CommonModule],\n templateUrl: './select.template.html',\n // We want this template to follow change detection to parent textfield.\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n providers: [tuiProvide(TuiTextfieldDirective, TuiSelect)],\n hostDirectives: [TuiNativeValidator, TuiAppearance],\n host: {\n '[id]': 'textfield.id',\n '[class._empty]': 'stringified === \"\"',\n '(input)': '0',\n '(focusin)': '0',\n '(focusout)': '0',\n '(keydown.space.prevent)': '0',\n '(keydown.enter.prevent)': '0',\n '(keydown.backspace)': 'setValue(\"\")',\n '(mousedown.prevent)': 'focus()',\n '(keydown.control.c)': 'onCopy()',\n '(keydown.meta.c)': 'onCopy()',\n },\n})\nexport class TuiSelect<T> extends TuiTextfieldBase<T> {\n private readonly nav = inject(WA_NAVIGATOR);\n\n @Input()\n public placeholder = '';\n\n public override setValue(value: T): void {\n this.control?.control?.setValue(value);\n this.el.dispatchEvent(new Event('input', {bubbles: true}));\n }\n\n public focus(): void {\n this.el.classList.add('_ios-fix');\n this.el.focus();\n this.el.classList.remove('_ios-fix');\n }\n\n protected get stringified(): string {\n return this.textfield.stringify(this.control?.value ?? '');\n }\n\n protected async onCopy(): Promise<void> {\n await this.nav.clipboard.writeText(this.stringified);\n }\n}\n","<option\n *ngIf=\"placeholder && !stringified; else selected\"\n disabled\n selected\n value=\"\"\n>\n {{ placeholder }}\n</option>\n<ng-template #selected>\n <option\n *ngFor=\"let item of [stringified]\"\n selected\n [value]=\"item\"\n >\n {{ item }}\n </option>\n</ng-template>\n","import {TuiLabel} from '@taiga-ui/core/components/label';\n\nimport {TuiSelect} from './select.directive';\nimport {TuiTextfieldComponent} from './textfield.component';\nimport {TuiTextfieldDirective} from './textfield.directive';\nimport {TuiTextfieldOptionsDirective} from './textfield.options';\nimport {TuiTextfieldDropdownDirective} from './textfield-dropdown.directive';\n\nexport const TuiTextfield = [\n TuiLabel,\n TuiSelect,\n TuiTextfieldComponent,\n TuiTextfieldDirective,\n TuiTextfieldOptionsDirective,\n TuiTextfieldDropdownDirective,\n] as const;\n","import type {DoCheck} from '@angular/core';\nimport {Directive, inject, TemplateRef} from '@angular/core';\n\nimport {TuiTextfieldComponent} from './textfield.component';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiTextfieldContent]',\n})\nexport class TuiTextfieldContent implements DoCheck {\n private readonly ref = inject(TuiTextfieldComponent).vcr?.createEmbeddedView(\n inject(TemplateRef),\n );\n\n public ngDoCheck(): void {\n this.ref?.detectChanges();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i2.TuiWithTextfieldDropdown","i1","i3"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAM,OAAO,GAAG;AACZ,IAAA,UAAU,EAAE,WAAW;AACvB,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,OAAO,EAAE,IAAI;CACP,CAAC;AAQJ,MAAM,qBAAqB,GAAG,cAAc,CAAsB;AACrE,IAAA,UAAU,EAAE,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC;AACtC,IAAA,IAAI,EAAE,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC;AAC1B,IAAA,OAAO,EAAE,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC;AACnC,CAAA,EAAE;AAEG,SAAU,2BAA2B,CACvC,OAAqC,EAAA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AMM,WAAW,EAAA,CAAA;sBADjB,KAAK;;;AE5BG,MAAA,YAAY,GAAG;IACxB,QAAQ;IACR,SAAS;IACT,qBAAqB;IACrB,qBAAqB;IACrB,4BAA4B;IAC5B,6BAA6B;;;ACTjC,MAIa,mBAAmB,CAAA;AAJhC,IAAA,WAAA,GAAA;AAKqB,QAAA,IAAA,CAAA,GAAG,GAAG,MAAM,CAAC,qBAAqB,CAAC,CAAC,GAAG,EAAE,kBAAkB,CACxE,MAAM,CAAC,WAAW,CAAC,CACtB,CAAC;AAKL,KAAA;IAHU,SAAS,GAAA;AACZ,QAAA,IAAI,CAAC,GAAG,EAAE,aAAa,EAAE,CAAC;KAC7B;+GAPQ,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;mGAAnB,mBAAmB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,kCAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;4FAAnB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,kCAAkC;AAC/C,iBAAA,CAAA;;;ACRD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-textfield.mjs","sources":["../../../projects/core/components/textfield/textfield.options.ts","../../../projects/core/components/textfield/textfield-dropdown.directive.ts","../../../projects/core/components/textfield/textfield.component.ts","../../../projects/core/components/textfield/textfield.template.html","../../../projects/core/components/textfield/textfield.directive.ts","../../../projects/core/components/textfield/select.directive.ts","../../../projects/core/components/textfield/select.template.html","../../../projects/core/components/textfield/textfield.ts","../../../projects/core/components/textfield/textfield-content.directive.ts","../../../projects/core/components/textfield/taiga-ui-core-components-textfield.ts"],"sourcesContent":["import type {Provider, WritableSignal} from '@angular/core';\nimport {Directive, inject, Input, Optional, signal, SkipSelf} from '@angular/core';\nimport {tuiCreateToken, tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\nimport type {TuiSizeL, TuiSizeS} from '@taiga-ui/core/types';\n\nconst DEFAULT = {\n appearance: 'textfield',\n size: 'l',\n cleaner: true,\n} as const;\n\nexport interface TuiTextfieldOptions {\n readonly appearance: WritableSignal<string>;\n readonly size: WritableSignal<TuiSizeL | TuiSizeS>;\n readonly cleaner: WritableSignal<boolean>;\n}\n\nexport const TUI_TEXTFIELD_OPTIONS = tuiCreateToken<TuiTextfieldOptions>({\n appearance: signal(DEFAULT.appearance),\n size: signal(DEFAULT.size),\n cleaner: signal(DEFAULT.cleaner),\n});\n\nexport function tuiTextfieldOptionsProvider(\n options: Partial<TuiTextfieldOptions>,\n): Provider {\n return {\n provide: TUI_TEXTFIELD_OPTIONS,\n deps: [[new Optional(), new SkipSelf(), TUI_TEXTFIELD_OPTIONS]],\n useFactory: (parent: TuiTextfieldOptions | null) => ({\n appearance: signal(parent?.appearance() ?? DEFAULT.appearance),\n size: signal(parent?.size() ?? DEFAULT.size),\n cleaner: signal(parent?.cleaner() ?? DEFAULT.cleaner),\n ...options,\n }),\n };\n}\n\n@Directive({\n standalone: true,\n selector: '[tuiTextfieldAppearance],[tuiTextfieldSize],[tuiTextfieldCleaner]',\n providers: [tuiProvide(TUI_TEXTFIELD_OPTIONS, TuiTextfieldOptionsDirective)],\n})\nexport class TuiTextfieldOptionsDirective implements TuiTextfieldOptions {\n private readonly options = inject(TUI_TEXTFIELD_OPTIONS, {skipSelf: true});\n\n // TODO: refactor to signal inputs after Angular update\n public appearance = signal(this.options.appearance());\n public size = signal(this.options.size());\n public cleaner = signal(this.options.cleaner());\n\n @Input()\n public set tuiTextfieldAppearance(appearance: string) {\n this.appearance.set(appearance);\n }\n\n @Input()\n public set tuiTextfieldSize(size: TuiSizeL | TuiSizeS) {\n this.size.set(size);\n }\n\n @Input()\n public set tuiTextfieldCleaner(enabled: boolean) {\n this.cleaner.set(enabled);\n }\n}\n","import {ContentChild, Directive, TemplateRef} from '@angular/core';\nimport {tuiDropdown} from '@taiga-ui/core/directives/dropdown';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiTextfieldDropdown]',\n})\nexport class TuiTextfieldDropdownDirective {}\n\n@Directive({\n standalone: true,\n})\nexport class TuiWithTextfieldDropdown {\n private readonly dropdown = tuiDropdown(null);\n\n @ContentChild(TuiTextfieldDropdownDirective, {read: TemplateRef, descendants: true})\n protected set template(template: PolymorpheusContent) {\n this.dropdown.set(template);\n }\n}\n","import {NgIf} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n ContentChild,\n ElementRef,\n forwardRef,\n inject,\n Input,\n signal,\n ViewChild,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {NgControl} from '@angular/forms';\nimport {WaResizeObserver} from '@ng-web-apis/resize-observer';\nimport {tuiInjectId} from '@taiga-ui/cdk/services';\nimport type {TuiContext, TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiPx} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton, tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport type {TuiDataListHost} from '@taiga-ui/core/components/data-list';\nimport {tuiAsDataListHost} from '@taiga-ui/core/components/data-list';\nimport {TuiLabel} from '@taiga-ui/core/components/label';\nimport {\n TuiDropdownDirective,\n TuiDropdownFixed,\n tuiDropdownOpen,\n TuiWithDropdownOpen,\n} from '@taiga-ui/core/directives/dropdown';\nimport {TuiWithIcons} from '@taiga-ui/core/directives/icons';\nimport {TUI_CLEAR_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport type {TuiSizeL, TuiSizeS} from '@taiga-ui/core/types';\nimport type {PolymorpheusContent} from '@taiga-ui/polymorpheus';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TuiTextfieldDirective} from './textfield.directive';\nimport {TUI_TEXTFIELD_OPTIONS} from './textfield.options';\nimport {TuiWithTextfieldDropdown} from './textfield-dropdown.directive';\n\n@Component({\n standalone: true,\n selector: 'tui-textfield',\n imports: [NgIf, PolymorpheusOutlet, TuiButton, WaResizeObserver],\n templateUrl: './textfield.template.html',\n styles: ['@import \"@taiga-ui/core/styles/components/textfield.less\";'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiButtonOptionsProvider({size: 'xs', appearance: 'icon'}),\n tuiAsDataListHost(TuiTextfieldComponent),\n ],\n hostDirectives: [\n TuiDropdownFixed,\n TuiDropdownDirective,\n TuiWithDropdownOpen,\n TuiWithTextfieldDropdown,\n TuiWithIcons,\n ],\n host: {\n '[attr.data-size]': 'options.size()',\n '[class._with-label]': 'hasLabel',\n '[class._with-template]': 'content',\n '[class._disabled]': 'input?.nativeElement.disabled',\n },\n})\nexport class TuiTextfieldComponent<T> implements TuiDataListHost<T> {\n // TODO: refactor to signal inputs after Angular update\n private readonly filler = signal('');\n private readonly autoId = tuiInjectId();\n private readonly open = tuiDropdownOpen();\n private readonly focusedIn = tuiFocusedIn(tuiInjectElement());\n\n @ContentChild(forwardRef(() => TuiLabel), {read: ElementRef})\n protected readonly label?: ElementRef<HTMLElement>;\n\n @ContentChild(NgControl)\n protected readonly control?: NgControl;\n\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly clear = toSignal(inject(TUI_CLEAR_WORD));\n\n protected computedFiller = computed(() => {\n const value = this.directive?.value() || '';\n const filledValue = value + this.filler().slice(value.length);\n\n return filledValue.length > value.length ? filledValue : '';\n });\n\n protected showFiller = computed<boolean>(\n () =>\n this.focused() &&\n !!this.computedFiller() &&\n (!!this.directive?.value() || !this.input?.nativeElement.placeholder),\n );\n\n @ViewChild('vcr', {read: ViewContainerRef, static: true})\n public readonly vcr?: ViewContainerRef;\n\n @ContentChild(forwardRef(() => TuiTextfieldDirective), {static: true})\n public readonly directive?: TuiTextfieldDirective<T>;\n\n @ContentChild(forwardRef(() => TuiTextfieldDirective), {\n read: ElementRef,\n static: true,\n })\n public readonly input?: ElementRef<HTMLInputElement>;\n\n @Input()\n public stringify: TuiStringHandler<T> = String;\n\n @Input()\n public content: PolymorpheusContent<TuiContext<T>>;\n\n public readonly focused = computed(() => this.open() || this.focusedIn());\n public readonly options = inject(TUI_TEXTFIELD_OPTIONS);\n public readonly el = tuiInjectElement();\n\n @Input('filler')\n public set fillerSetter(filler: string) {\n this.filler.set(filler);\n }\n\n public get id(): string {\n return this.input?.nativeElement.id || this.autoId;\n }\n\n public get size(): TuiSizeL | TuiSizeS {\n return this.options.size();\n }\n\n public handleOption(option: T): void {\n this.directive?.setValue(option);\n this.open.set(false);\n }\n\n protected get hasLabel(): boolean {\n return Boolean(this.label?.nativeElement?.childNodes.length);\n }\n\n protected onResize({contentRect}: ResizeObserverEntry): void {\n this.el.style.setProperty('--t-side', tuiPx(contentRect.width));\n }\n}\n","<ng-content select=\"input\" />\n<ng-content select=\"select\" />\n<ng-content select=\"label\" />\n<span\n class=\"t-content\"\n (mousedown.prevent)=\"input?.nativeElement?.focus()\"\n (waResizeObserver)=\"$event[0] && onResize($event[0])\"\n>\n <ng-content />\n <button\n *ngIf=\"options.cleaner()\"\n appearance=\"icon\"\n size=\"xs\"\n tabindex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-clear\"\n [iconStart]=\"icons.close\"\n (click)=\"directive?.setValue(null)\"\n (pointerdown.zoneless.prevent)=\"input?.nativeElement?.focus()\"\n >\n {{ clear() }}\n </button>\n <ng-container #vcr />\n <ng-content select=\"tui-icon\" />\n</span>\n<span class=\"t-template\">\n <ng-container *polymorpheusOutlet=\"content as text; context: {$implicit: control?.value}\">\n {{ text }}\n </ng-container>\n</span>\n<input\n *ngIf=\"showFiller()\"\n aria-hidden=\"true\"\n disabled\n class=\"t-filler\"\n [value]=\"computedFiller()\"\n/>\n","import type {OnChanges} from '@angular/core';\nimport {computed, Directive, inject, Input, signal} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {NgControl} from '@angular/forms';\nimport {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';\nimport {tuiControlValue} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {\n TuiAppearance,\n tuiAppearance,\n tuiAppearanceFocus,\n tuiAppearanceMode,\n tuiAppearanceState,\n} from '@taiga-ui/core/directives/appearance';\nimport type {TuiInteractiveState} from '@taiga-ui/core/types';\nimport {fromEvent, map, merge, switchMap, timer} from 'rxjs';\n\nimport {TuiTextfieldComponent} from './textfield.component';\nimport {TUI_TEXTFIELD_OPTIONS} from './textfield.options';\n\n@Directive()\nexport class TuiTextfieldBase<T> implements OnChanges {\n // TODO: refactor to signal inputs after Angular update\n private readonly focused = signal<boolean | null>(null);\n\n protected readonly control = inject(NgControl, {optional: true});\n protected readonly a = tuiAppearance(inject(TUI_TEXTFIELD_OPTIONS).appearance);\n protected readonly s = tuiAppearanceState(null);\n protected readonly m = tuiAppearanceMode(this.mode);\n protected readonly f = tuiAppearanceFocus(\n computed(() => this.focused() ?? this.textfield.focused()),\n );\n\n protected readonly el = tuiInjectElement<HTMLInputElement>();\n protected readonly textfield: TuiTextfieldComponent<T> =\n inject(TuiTextfieldComponent);\n\n @Input()\n public readOnly = false;\n\n @Input()\n public invalid: boolean | null = null;\n\n public readonly value = toSignal(\n merge(\n fromEvent(this.el, 'input'),\n timer(0) // https://github.com/angular/angular/issues/54418\n .pipe(switchMap(() => tuiControlValue(this.control))),\n ).pipe(map(() => this.el.value)),\n {initialValue: this.el.value},\n );\n\n @Input('focused')\n public set focusedSetter(focused: boolean | null) {\n this.focused.set(focused);\n }\n\n @Input('state')\n public set stateSetter(state: TuiInteractiveState | null) {\n this.s.set(state);\n }\n\n public get mode(): string | null {\n if (this.readOnly) {\n return 'readonly';\n }\n\n if (this.invalid === false) {\n return 'valid';\n }\n\n if (this.invalid) {\n return 'invalid';\n }\n\n return null;\n }\n\n // TODO: refactor to signal inputs after Angular update\n public ngOnChanges(): void {\n this.m.set(this.mode);\n }\n\n public setValue(value: T | null): void {\n this.el.focus();\n this.el.select();\n\n if (value == null) {\n this.el.ownerDocument.execCommand('delete');\n } else {\n this.el.ownerDocument.execCommand(\n 'insertText',\n false,\n this.textfield.stringify(value),\n );\n }\n }\n}\n\n@Directive({\n standalone: true,\n // TODO: Remove :not in v.5\n selector:\n 'input[tuiTextfield]:not([tuiInputCard]):not([tuiInputExpire]):not([tuiInputCVC])',\n hostDirectives: [TuiNativeValidator, TuiAppearance],\n host: {\n '[id]': 'textfield.id',\n '[readOnly]': 'readOnly',\n '[class._empty]': 'el.value === \"\"',\n '(input)': '0',\n '(focusin)': '0',\n '(focusout)': '0',\n },\n})\nexport class TuiTextfieldDirective<T> extends TuiTextfieldBase<T> {}\n\n@Directive({\n standalone: true,\n hostDirectives: [\n {\n directive: TuiTextfieldDirective,\n inputs: ['invalid', 'focused', 'readOnly', 'state'],\n },\n ],\n})\nexport class TuiWithTextfield {}\n","import {CommonModule} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {WA_NAVIGATOR} from '@ng-web-apis/common';\nimport {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiAppearance} from '@taiga-ui/core/directives/appearance';\n\nimport {TuiTextfieldBase, TuiTextfieldDirective} from './textfield.directive';\n\n@Component({\n standalone: true,\n selector: 'select[tuiTextfield]',\n imports: [CommonModule],\n templateUrl: './select.template.html',\n // We want this template to follow change detection to parent textfield.\n // eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection\n changeDetection: ChangeDetectionStrategy.Default,\n providers: [tuiProvide(TuiTextfieldDirective, TuiSelect)],\n hostDirectives: [TuiNativeValidator, TuiAppearance],\n host: {\n '[id]': 'textfield.id',\n '[class._empty]': 'stringified === \"\"',\n '(input)': '0',\n '(focusin)': '0',\n '(focusout)': '0',\n '(keydown.space.prevent)': '0',\n '(keydown.enter.prevent)': '0',\n '(keydown.backspace)': 'setValue(\"\")',\n '(mousedown.prevent)': 'focus()',\n '(keydown.control.c)': 'onCopy()',\n '(keydown.meta.c)': 'onCopy()',\n },\n})\nexport class TuiSelect<T> extends TuiTextfieldBase<T> {\n private readonly nav = inject(WA_NAVIGATOR);\n\n @Input()\n public placeholder = '';\n\n public override setValue(value: T): void {\n this.control?.control?.setValue(value);\n this.el.dispatchEvent(new Event('input', {bubbles: true}));\n }\n\n public focus(): void {\n this.el.classList.add('_ios-fix');\n this.el.focus();\n this.el.classList.remove('_ios-fix');\n }\n\n protected get stringified(): string {\n return this.textfield.stringify(this.control?.value ?? '');\n }\n\n protected async onCopy(): Promise<void> {\n await this.nav.clipboard.writeText(this.stringified);\n }\n}\n","<option\n *ngIf=\"placeholder && !stringified; else selected\"\n disabled\n selected\n value=\"\"\n>\n {{ placeholder }}\n</option>\n<ng-template #selected>\n <option\n *ngFor=\"let item of [stringified]\"\n selected\n [value]=\"item\"\n >\n {{ item }}\n </option>\n</ng-template>\n","import {TuiLabel} from '@taiga-ui/core/components/label';\n\nimport {TuiSelect} from './select.directive';\nimport {TuiTextfieldComponent} from './textfield.component';\nimport {TuiTextfieldDirective} from './textfield.directive';\nimport {TuiTextfieldOptionsDirective} from './textfield.options';\nimport {TuiTextfieldDropdownDirective} from './textfield-dropdown.directive';\n\nexport const TuiTextfield = [\n TuiLabel,\n TuiSelect,\n TuiTextfieldComponent,\n TuiTextfieldDirective,\n TuiTextfieldOptionsDirective,\n TuiTextfieldDropdownDirective,\n] as const;\n","import type {DoCheck} from '@angular/core';\nimport {Directive, inject, TemplateRef} from '@angular/core';\n\nimport {TuiTextfieldComponent} from './textfield.component';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiTextfieldContent]',\n})\nexport class TuiTextfieldContent implements DoCheck {\n private readonly ref = inject(TuiTextfieldComponent).vcr?.createEmbeddedView(\n inject(TemplateRef),\n );\n\n public ngDoCheck(): void {\n this.ref?.detectChanges();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i2.TuiWithTextfieldDropdown","i1","i3"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAM,OAAO,GAAG;AACZ,IAAA,UAAU,EAAE,WAAW;AACvB,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,OAAO,EAAE,IAAI;CACP,CAAC;AAQJ,MAAM,qBAAqB,GAAG,cAAc,CAAsB;AACrE,IAAA,UAAU,EAAE,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC;AACtC,IAAA,IAAI,EAAE,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC;AAC1B,IAAA,OAAO,EAAE,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC;AACnC,CAAA,EAAE;AAEG,SAAU,2BAA2B,CACvC,OAAqC,EAAA;IAErC,OAAO;AACH,QAAA,OAAO,EAAE,qBAAqB;AAC9B,QAAA,IAAI,EAAE,CAAC,CAAC,IAAI,QAAQ,EAAE,EAAE,IAAI,QAAQ,EAAE,EAAE,qBAAqB,CAAC,CAAC;AAC/D,QAAA,UAAU,EAAE,CAAC,MAAkC,MAAM;YACjD,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,OAAO,CAAC,UAAU,CAAC;YAC9D,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,IAAI,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;YAC5C,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,OAAO,CAAC,OAAO,CAAC;AACrD,YAAA,GAAG,OAAO;SACb,CAAC;K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AA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;mGAAnB,mBAAmB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,kCAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;4FAAnB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,kCAAkC;AAC/C,iBAAA,CAAA;;;ACRD;;AAEG;;;;"}
|
|
@@ -13,13 +13,13 @@ function tuiAppearanceOptionsProvider(token) {
|
|
|
13
13
|
|
|
14
14
|
class TuiAppearanceStyles {
|
|
15
15
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiAppearanceStyles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
16
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiAppearanceStyles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-appearance" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiAppearance]{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;-webkit-appearance:none;appearance:none;outline:.125rem solid transparent;outline-offset:-.125rem;transition-property:color,background-color,opacity,box-shadow,border,border-radius}[tuiAppearance].tui-appearance-initializing{transition:none!important}[tuiAppearance]:focus-visible:not([data-focus=false]){outline-color:var(--tui-border-focus)}[tuiAppearance][data-focus=true]{outline-color:var(--tui-border-focus)}[tuiAppearance][tuiWrapper]:not(._focused):has(:focus-visible),[tuiAppearance][tuiWrapper]._focused{outline-color:var(--tui-border-focus)}[tuiAppearance]:disabled:not([data-state]),[tuiAppearance][data-state=disabled]{
|
|
16
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiAppearanceStyles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-appearance" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiAppearance]{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;-webkit-appearance:none;appearance:none;outline:.125rem solid transparent;outline-offset:-.125rem;transition-property:color,background-color,opacity,box-shadow,border,border-radius,filter}[tuiAppearance].tui-appearance-initializing{transition:none!important}[tuiAppearance]:focus-visible:not([data-focus=false]){outline-color:var(--tui-border-focus)}[tuiAppearance][data-focus=true]{outline-color:var(--tui-border-focus)}[tuiAppearance][tuiWrapper]:not(._focused):has(:focus-visible),[tuiAppearance][tuiWrapper]._focused{outline-color:var(--tui-border-focus)}[tuiAppearance]:disabled:not([data-state]),[tuiAppearance][data-state=disabled]{cursor:initial;opacity:var(--tui-disabled-opacity)}[tuiAppearance][tuiWrapper]:disabled:not([data-state]),[tuiAppearance][tuiWrapper][data-state=disabled]{cursor:initial;opacity:var(--tui-disabled-opacity)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
17
17
|
}
|
|
18
18
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiAppearanceStyles, decorators: [{
|
|
19
19
|
type: Component,
|
|
20
20
|
args: [{ standalone: true, template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
21
21
|
class: 'tui-appearance',
|
|
22
|
-
}, styles: ["[tuiAppearance]{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;-webkit-appearance:none;appearance:none;outline:.125rem solid transparent;outline-offset:-.125rem;transition-property:color,background-color,opacity,box-shadow,border,border-radius}[tuiAppearance].tui-appearance-initializing{transition:none!important}[tuiAppearance]:focus-visible:not([data-focus=false]){outline-color:var(--tui-border-focus)}[tuiAppearance][data-focus=true]{outline-color:var(--tui-border-focus)}[tuiAppearance][tuiWrapper]:not(._focused):has(:focus-visible),[tuiAppearance][tuiWrapper]._focused{outline-color:var(--tui-border-focus)}[tuiAppearance]:disabled:not([data-state]),[tuiAppearance][data-state=disabled]{
|
|
22
|
+
}, styles: ["[tuiAppearance]{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;-webkit-appearance:none;appearance:none;outline:.125rem solid transparent;outline-offset:-.125rem;transition-property:color,background-color,opacity,box-shadow,border,border-radius,filter}[tuiAppearance].tui-appearance-initializing{transition:none!important}[tuiAppearance]:focus-visible:not([data-focus=false]){outline-color:var(--tui-border-focus)}[tuiAppearance][data-focus=true]{outline-color:var(--tui-border-focus)}[tuiAppearance][tuiWrapper]:not(._focused):has(:focus-visible),[tuiAppearance][tuiWrapper]._focused{outline-color:var(--tui-border-focus)}[tuiAppearance]:disabled:not([data-state]),[tuiAppearance][data-state=disabled]{cursor:initial;opacity:var(--tui-disabled-opacity)}[tuiAppearance][tuiWrapper]:disabled:not([data-state]),[tuiAppearance][tuiWrapper][data-state=disabled]{cursor:initial;opacity:var(--tui-disabled-opacity)}\n"] }]
|
|
23
23
|
}] });
|
|
24
24
|
class TuiAppearance {
|
|
25
25
|
constructor() {
|
|
@@ -34,7 +34,6 @@ class TuiAppearance {
|
|
|
34
34
|
afterNextRender(() => {
|
|
35
35
|
this.el.classList.toggle('tui-appearance-initializing',
|
|
36
36
|
// Triggering reflow so there's no transition
|
|
37
|
-
// eslint-disable-next-line
|
|
38
37
|
!!this.el.offsetWidth && false);
|
|
39
38
|
});
|
|
40
39
|
}
|