@taiga-ui/kit 5.0.0 → 5.1.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/components/counter/counter.component.d.ts +1 -1
- package/components/files/input-files/input-files.directive.d.ts +1 -0
- package/components/input-number/index.d.ts +1 -0
- package/components/input-number/input-number.d.ts +1 -1
- package/components/input-number/step/input-number-step.component.d.ts +9 -11
- package/components/input-number/step/input-number-step.directive.d.ts +12 -0
- package/components/input-number/step/input-number-step.service.d.ts +0 -1
- package/fesm2022/taiga-ui-kit-components-accordion.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-action-bar.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-avatar.mjs +23 -23
- package/fesm2022/taiga-ui-kit-components-badge-notification.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-badge.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-badged-content.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-block.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-button-loading.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-chip.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-comment.mjs +8 -7
- package/fesm2022/taiga-ui-kit-components-comment.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-compass.mjs +5 -5
- package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-confirm.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-copy.mjs +11 -11
- package/fesm2022/taiga-ui-kit-components-counter.mjs +13 -14
- package/fesm2022/taiga-ui-kit-components-counter.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-drawer.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-files.mjs +31 -26
- package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-filter.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-fullscreen.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-chip.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-input-color.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-date-range.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-input-date.mjs +10 -10
- package/fesm2022/taiga-ui-kit-components-input-inline.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +10 -8
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-month.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-input-number.mjs +80 -55
- package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs +5 -5
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-pin.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-range.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs +11 -11
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-time.mjs +13 -13
- package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-year.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-like.mjs +5 -5
- package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +9 -9
- package/fesm2022/taiga-ui-kit-components-message.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-multi-select.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +9 -9
- package/fesm2022/taiga-ui-kit-components-pager.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-pagination.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-pin.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-preview.mjs +26 -26
- package/fesm2022/taiga-ui-kit-components-progress.mjs +27 -27
- package/fesm2022/taiga-ui-kit-components-pulse.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-push.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-radio-list.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-range.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-rating.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-segmented.mjs +8 -8
- package/fesm2022/taiga-ui-kit-components-select.mjs +9 -9
- package/fesm2022/taiga-ui-kit-components-shrink-wrap.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-status.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-stepper.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-stepper.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-switch.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-tabs.mjs +19 -19
- package/fesm2022/taiga-ui-kit-components-textarea.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-tiles.mjs +24 -21
- package/fesm2022/taiga-ui-kit-components-tiles.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-timeline.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-toast.mjs +16 -16
- package/fesm2022/taiga-ui-kit-components-tree.mjs +24 -24
- package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-button-group.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-button-select.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-chevron.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-connected.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs +4 -4
- package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-fade.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-highlight.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-password.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-present.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-sensitive.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-shimmer.mjs +8 -8
- package/fesm2022/taiga-ui-kit-directives-shimmer.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-skeleton.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-emails.mjs +4 -4
- package/fesm2022/taiga-ui-kit-pipes-emails.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-flag.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-initials.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-stringify.mjs +3 -3
- package/package.json +70 -70
|
@@ -29,7 +29,7 @@ class TuiStepperComponent {
|
|
|
29
29
|
}
|
|
30
30
|
indexOf(step) {
|
|
31
31
|
const index = this.steps().findIndex(({ nativeElement }) => nativeElement === step);
|
|
32
|
-
return index < 0 ? NaN : index;
|
|
32
|
+
return index < 0 ? Number.NaN : index;
|
|
33
33
|
}
|
|
34
34
|
isActive(index) {
|
|
35
35
|
return index === this.activeItemIndex();
|
|
@@ -74,12 +74,12 @@ class TuiStepperComponent {
|
|
|
74
74
|
const left = stepOffsetLeft - offsetLeft - clientWidth / 2 + offsetWidth / 2;
|
|
75
75
|
this.el.scrollTo?.({ left: Math.max(0, left), top: Math.max(0, top) });
|
|
76
76
|
}
|
|
77
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
78
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.
|
|
77
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiStepperComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
78
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.20", type: TuiStepperComponent, isStandalone: true, selector: "tui-stepper", inputs: { orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, activeItemIndex: { classPropertyName: "activeItemIndex", publicName: "activeItemIndex", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activeItemIndex: "activeItemIndexChange" }, host: { listeners: { "keydown.arrowRight": "onHorizontal($event, 1)", "keydown.arrowLeft": "onHorizontal($event, -1)", "keydown.arrowDown": "onVertical($event, 1)", "keydown.arrowUp": "onVertical($event, -1)" }, properties: { "attr.data-orientation": "orientation()" } }, providers: [WaResizeObserverService], queries: [{ propertyName: "steps", predicate: i0.forwardRef(() => TuiStep), read: ElementRef, isSignal: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
79
79
|
<ng-content />
|
|
80
80
|
`, isInline: true, styles: [":host{scrollbar-width:none;-ms-overflow-style:none;display:flex;scroll-behavior:var(--tui-scroll-behavior);overflow:auto;counter-reset:steps;font:var(--tui-typography-body-m)}:host::-webkit-scrollbar,:host::-webkit-scrollbar-thumb{display:none}:host[data-orientation=vertical]{flex-direction:column}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
81
81
|
}
|
|
82
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
82
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiStepperComponent, decorators: [{
|
|
83
83
|
type: Component,
|
|
84
84
|
args: [{ selector: 'tui-stepper', template: `
|
|
85
85
|
<ng-content />
|
|
@@ -123,10 +123,10 @@ class TuiStep {
|
|
|
123
123
|
activate() {
|
|
124
124
|
this.stepper.activate(this.index);
|
|
125
125
|
}
|
|
126
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
127
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.
|
|
126
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiStep, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
127
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.20", type: TuiStep, isStandalone: true, selector: "button[tuiStep], a[tuiStep]:not([routerLink]), a[tuiStep][routerLink][routerLinkActive]", inputs: { stepState: { classPropertyName: "stepState", publicName: "stepState", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "type": "button" }, listeners: { "click": "activate()" }, properties: { "tabIndex": "isActive() ? 0 : -1", "class._active": "isActive()", "class._vertical": "stepper.orientation() === \"vertical\"" } }, hostDirectives: [{ directive: i1.TuiCell }, { directive: i2.TuiWithAppearance }], ngImport: i0, template: "<div\n [appearance]=\"avatarAppearance()\"\n [tuiAvatar]=\"avatarContent()\"\n></div>\n<ng-content />\n", styles: [":host{min-inline-size:fit-content}:host:hover{background:unset!important}:host._active._active:not(:disabled){cursor:unset}:host:not(._vertical):first-of-type{padding-inline-start:0}:host:not(._vertical):last-of-type{padding-inline-end:0}:host._vertical{padding-inline:0;margin-block-end:.5rem}[tuiAvatar][data-size]:before{transition:none}[tuiAvatar][data-size]._initials:before{font-weight:400}\n"], dependencies: [{ kind: "directive", type: TuiAvatar, selector: "[tuiAvatar]", inputs: ["size", "round", "badge"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
128
128
|
}
|
|
129
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
129
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiStep, decorators: [{
|
|
130
130
|
type: Component,
|
|
131
131
|
args: [{ selector: 'button[tuiStep], a[tuiStep]:not([routerLink]), a[tuiStep][routerLink][routerLinkActive]', imports: [TuiAvatar], changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiCell, TuiWithAppearance], host: {
|
|
132
132
|
type: 'button',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-stepper.mjs","sources":["../../../projects/kit/components/stepper/stepper.component.ts","../../../projects/kit/components/stepper/step.component.ts","../../../projects/kit/components/stepper/step.template.html","../../../projects/kit/components/stepper/stepper.ts","../../../projects/kit/components/stepper/taiga-ui-kit-components-stepper.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n contentChildren,\n ElementRef,\n forwardRef,\n inject,\n input,\n model,\n type OnChanges,\n} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {WaResizeObserverService} from '@ng-web-apis/resize-observer';\nimport {tuiInjectElement, tuiIsElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiMoveFocus} from '@taiga-ui/cdk/utils/focus';\nimport {type TuiOrientation} from '@taiga-ui/core/types';\n\nimport {TuiStep} from './step.component';\n\n@Component({\n selector: 'tui-stepper',\n template: `\n <ng-content />\n `,\n styleUrl: './stepper.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [WaResizeObserverService],\n host: {\n '[attr.data-orientation]': 'orientation()',\n '(keydown.arrowRight)': 'onHorizontal($event, 1)',\n '(keydown.arrowLeft)': 'onHorizontal($event, -1)',\n '(keydown.arrowDown)': 'onVertical($event, 1)',\n '(keydown.arrowUp)': 'onVertical($event, -1)',\n },\n})\nexport class TuiStepperComponent implements OnChanges {\n private readonly el = tuiInjectElement();\n private readonly steps = contentChildren(\n forwardRef(() => TuiStep),\n {read: ElementRef},\n );\n\n protected readonly $ = inject(WaResizeObserverService, {self: true})\n .pipe(takeUntilDestroyed())\n .subscribe(() => this.scrollIntoView(this.activeItemIndex()));\n\n public readonly orientation = input<TuiOrientation>('horizontal');\n public readonly activeItemIndex = model(0);\n\n public ngOnChanges(): void {\n this.scrollIntoView(this.activeItemIndex());\n }\n\n public indexOf(step: HTMLElement): number {\n const index = this.steps().findIndex(({nativeElement}) => nativeElement === step);\n\n return index < 0 ? NaN : index;\n }\n\n public isActive(index: number): boolean {\n return index === this.activeItemIndex();\n }\n\n public activate(index: number): void {\n if (this.activeItemIndex() === index) {\n return;\n }\n\n this.activeItemIndex.set(index);\n this.scrollIntoView(index);\n }\n\n protected onHorizontal(event: Event, step: number): void {\n if (this.orientation() !== 'horizontal' || !event.target) {\n return;\n }\n\n event.preventDefault();\n this.moveFocus(event.target, step);\n }\n\n protected onVertical(event: Event, step: number): void {\n if (this.orientation() !== 'vertical' || !event.target) {\n return;\n }\n\n event.preventDefault();\n this.moveFocus(event.target, step);\n }\n\n private moveFocus(current: EventTarget, step: number): void {\n if (!tuiIsElement(current)) {\n return;\n }\n\n const stepElements = this.steps().map(({nativeElement}) => nativeElement);\n const index = stepElements.findIndex((element) => element === current);\n\n tuiMoveFocus(index, stepElements, step);\n }\n\n private scrollIntoView(index: number): void {\n const step = this.steps()[index]?.nativeElement;\n\n if (!step) {\n return;\n }\n\n const {clientHeight, clientWidth, offsetTop, offsetLeft} = this.el;\n const {\n offsetHeight,\n offsetWidth,\n offsetTop: stepOffsetTop,\n offsetLeft: stepOffsetLeft,\n } = step;\n const top = stepOffsetTop - offsetTop - clientHeight / 2 + offsetHeight / 2;\n const left = stepOffsetLeft - offsetLeft - clientWidth / 2 + offsetWidth / 2;\n\n this.el.scrollTo?.({left: Math.max(0, left), top: Math.max(0, top)});\n }\n}\n","import {ChangeDetectionStrategy, Component, computed, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {RouterLinkActive} from '@angular/router';\nimport {tuiDirectiveBinding} from '@taiga-ui/cdk/utils/di';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiCell} from '@taiga-ui/core/components/cell';\nimport {tuiAppearance, TuiWithAppearance} from '@taiga-ui/core/directives/appearance';\nimport {TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {TuiAvatar} from '@taiga-ui/kit/components/avatar';\nimport {EMPTY, filter} from 'rxjs';\n\nimport {TuiStepperComponent} from './stepper.component';\n\n@Component({\n selector:\n 'button[tuiStep], a[tuiStep]:not([routerLink]), a[tuiStep][routerLink][routerLinkActive]',\n imports: [TuiAvatar],\n templateUrl: './step.template.html',\n styleUrl: './step.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiCell, TuiWithAppearance],\n host: {\n type: 'button',\n '[tabIndex]': 'isActive() ? 0 : -1',\n '[class._active]': 'isActive()',\n '[class._vertical]': 'stepper.orientation() === \"vertical\"',\n '(click)': 'activate()',\n },\n})\nexport class TuiStep {\n private readonly el = tuiInjectElement();\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly appearance = tuiAppearance(\n computed(() => (this.isActive() ? 'none' : 'action')),\n );\n\n protected readonly size = tuiDirectiveBinding(TuiCell, 'size', 'm');\n\n protected readonly stepper = inject(TuiStepperComponent);\n protected readonly $ = (\n inject(RouterLinkActive, {optional: true})?.isActiveChange.asObservable() ?? EMPTY\n )\n .pipe(filter(Boolean), takeUntilDestroyed())\n .subscribe(() => this.activate());\n\n public readonly stepState = input<'error' | 'normal' | 'pass'>('normal');\n public readonly icon = input('');\n\n protected readonly isActive = computed(\n () => this.stepper.activeItemIndex() === this.index,\n );\n\n protected readonly avatarAppearance = computed(() => {\n if (this.isActive()) {\n return 'primary';\n }\n\n return this.stepState() === 'error' ? 'negative' : 'secondary';\n });\n\n protected readonly avatarContent = computed(() =>\n this.isActive() || (this.stepState() === 'normal' && !this.icon())\n ? `${this.index + 1}`\n : this.avatarIcon(),\n );\n\n protected readonly avatarIcon = computed(\n () =>\n this.icon() ||\n (this.stepState() === 'error' ? this.icons.error : this.icons.check),\n );\n\n protected get index(): number {\n return this.stepper.indexOf(this.el);\n }\n\n protected activate(): void {\n this.stepper.activate(this.index);\n }\n}\n","<div\n [appearance]=\"avatarAppearance()\"\n [tuiAvatar]=\"avatarContent()\"\n></div>\n<ng-content />\n","import {TuiStep} from './step.component';\nimport {TuiStepperComponent} from './stepper.component';\n\nexport const TuiStepper = [TuiStepperComponent, TuiStep] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;MAmCa,mBAAmB,CAAA;AAhBhC,IAAA,WAAA,GAAA;QAiBqB,IAAA,CAAA,EAAE,GAAG,gBAAgB,EAAE;AACvB,QAAA,IAAA,CAAA,KAAK,GA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C,SAAS,CAAC,mBAGH,uBAAuB,CAAC,MAAM,EAAA,cAAA,EAC/B,CAAC,OAAO,EAAE,iBAAiB,CAAC,EAAA,IAAA,EACtC;AACF,wBAAA,IAAI,EAAE,QAAQ;AACd,wBAAA,YAAY,EAAE,qBAAqB;AACnC,wBAAA,iBAAiB,EAAE,YAAY;AAC/B,wBAAA,mBAAmB,EAAE,sCAAsC;AAC3D,wBAAA,SAAS,EAAE,YAAY;AAC1B,qBAAA,EAAA,QAAA,EAAA,+GAAA,EAAA,MAAA,EAAA,CAAA,gZAAA,CAAA,EAAA;;;MExBQ,UAAU,GAAG,CAAC,mBAAmB,EAAE,OAAO;;ACHvD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-stepper.mjs","sources":["../../../projects/kit/components/stepper/stepper.component.ts","../../../projects/kit/components/stepper/step.component.ts","../../../projects/kit/components/stepper/step.template.html","../../../projects/kit/components/stepper/stepper.ts","../../../projects/kit/components/stepper/taiga-ui-kit-components-stepper.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n contentChildren,\n ElementRef,\n forwardRef,\n inject,\n input,\n model,\n type OnChanges,\n} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {WaResizeObserverService} from '@ng-web-apis/resize-observer';\nimport {tuiInjectElement, tuiIsElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiMoveFocus} from '@taiga-ui/cdk/utils/focus';\nimport {type TuiOrientation} from '@taiga-ui/core/types';\n\nimport {TuiStep} from './step.component';\n\n@Component({\n selector: 'tui-stepper',\n template: `\n <ng-content />\n `,\n styleUrl: './stepper.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [WaResizeObserverService],\n host: {\n '[attr.data-orientation]': 'orientation()',\n '(keydown.arrowRight)': 'onHorizontal($event, 1)',\n '(keydown.arrowLeft)': 'onHorizontal($event, -1)',\n '(keydown.arrowDown)': 'onVertical($event, 1)',\n '(keydown.arrowUp)': 'onVertical($event, -1)',\n },\n})\nexport class TuiStepperComponent implements OnChanges {\n private readonly el = tuiInjectElement();\n private readonly steps = contentChildren(\n forwardRef(() => TuiStep),\n {read: ElementRef},\n );\n\n protected readonly $ = inject(WaResizeObserverService, {self: true})\n .pipe(takeUntilDestroyed())\n .subscribe(() => this.scrollIntoView(this.activeItemIndex()));\n\n public readonly orientation = input<TuiOrientation>('horizontal');\n public readonly activeItemIndex = model(0);\n\n public ngOnChanges(): void {\n this.scrollIntoView(this.activeItemIndex());\n }\n\n public indexOf(step: HTMLElement): number {\n const index = this.steps().findIndex(({nativeElement}) => nativeElement === step);\n\n return index < 0 ? Number.NaN : index;\n }\n\n public isActive(index: number): boolean {\n return index === this.activeItemIndex();\n }\n\n public activate(index: number): void {\n if (this.activeItemIndex() === index) {\n return;\n }\n\n this.activeItemIndex.set(index);\n this.scrollIntoView(index);\n }\n\n protected onHorizontal(event: Event, step: number): void {\n if (this.orientation() !== 'horizontal' || !event.target) {\n return;\n }\n\n event.preventDefault();\n this.moveFocus(event.target, step);\n }\n\n protected onVertical(event: Event, step: number): void {\n if (this.orientation() !== 'vertical' || !event.target) {\n return;\n }\n\n event.preventDefault();\n this.moveFocus(event.target, step);\n }\n\n private moveFocus(current: EventTarget, step: number): void {\n if (!tuiIsElement(current)) {\n return;\n }\n\n const stepElements = this.steps().map(({nativeElement}) => nativeElement);\n const index = stepElements.findIndex((element) => element === current);\n\n tuiMoveFocus(index, stepElements, step);\n }\n\n private scrollIntoView(index: number): void {\n const step = this.steps()[index]?.nativeElement;\n\n if (!step) {\n return;\n }\n\n const {clientHeight, clientWidth, offsetTop, offsetLeft} = this.el;\n const {\n offsetHeight,\n offsetWidth,\n offsetTop: stepOffsetTop,\n offsetLeft: stepOffsetLeft,\n } = step;\n const top = stepOffsetTop - offsetTop - clientHeight / 2 + offsetHeight / 2;\n const left = stepOffsetLeft - offsetLeft - clientWidth / 2 + offsetWidth / 2;\n\n this.el.scrollTo?.({left: Math.max(0, left), top: Math.max(0, top)});\n }\n}\n","import {ChangeDetectionStrategy, Component, computed, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {RouterLinkActive} from '@angular/router';\nimport {tuiDirectiveBinding} from '@taiga-ui/cdk/utils/di';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiCell} from '@taiga-ui/core/components/cell';\nimport {tuiAppearance, TuiWithAppearance} from '@taiga-ui/core/directives/appearance';\nimport {TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {TuiAvatar} from '@taiga-ui/kit/components/avatar';\nimport {EMPTY, filter} from 'rxjs';\n\nimport {TuiStepperComponent} from './stepper.component';\n\n@Component({\n selector:\n 'button[tuiStep], a[tuiStep]:not([routerLink]), a[tuiStep][routerLink][routerLinkActive]',\n imports: [TuiAvatar],\n templateUrl: './step.template.html',\n styleUrl: './step.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiCell, TuiWithAppearance],\n host: {\n type: 'button',\n '[tabIndex]': 'isActive() ? 0 : -1',\n '[class._active]': 'isActive()',\n '[class._vertical]': 'stepper.orientation() === \"vertical\"',\n '(click)': 'activate()',\n },\n})\nexport class TuiStep {\n private readonly el = tuiInjectElement();\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly appearance = tuiAppearance(\n computed(() => (this.isActive() ? 'none' : 'action')),\n );\n\n protected readonly size = tuiDirectiveBinding(TuiCell, 'size', 'm');\n\n protected readonly stepper = inject(TuiStepperComponent);\n protected readonly $ = (\n inject(RouterLinkActive, {optional: true})?.isActiveChange.asObservable() ?? EMPTY\n )\n .pipe(filter(Boolean), takeUntilDestroyed())\n .subscribe(() => this.activate());\n\n public readonly stepState = input<'error' | 'normal' | 'pass'>('normal');\n public readonly icon = input('');\n\n protected readonly isActive = computed(\n () => this.stepper.activeItemIndex() === this.index,\n );\n\n protected readonly avatarAppearance = computed(() => {\n if (this.isActive()) {\n return 'primary';\n }\n\n return this.stepState() === 'error' ? 'negative' : 'secondary';\n });\n\n protected readonly avatarContent = computed(() =>\n this.isActive() || (this.stepState() === 'normal' && !this.icon())\n ? `${this.index + 1}`\n : this.avatarIcon(),\n );\n\n protected readonly avatarIcon = computed(\n () =>\n this.icon() ||\n (this.stepState() === 'error' ? this.icons.error : this.icons.check),\n );\n\n protected get index(): number {\n return this.stepper.indexOf(this.el);\n }\n\n protected activate(): void {\n this.stepper.activate(this.index);\n }\n}\n","<div\n [appearance]=\"avatarAppearance()\"\n [tuiAvatar]=\"avatarContent()\"\n></div>\n<ng-content />\n","import {TuiStep} from './step.component';\nimport {TuiStepperComponent} from './stepper.component';\n\nexport const TuiStepper = [TuiStepperComponent, TuiStep] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;MAmCa,mBAAmB,CAAA;AAhBhC,IAAA,WAAA,GAAA;QAiBqB,IAAA,CAAA,EAAE,GAAG,gBAAgB,EAAE;AACvB,QAAA,IAAA,CAAA,KAAK,GAAG,eAAe,CACpC,UAAU,CAAC,MAAM,OAAO,CAAC,EACzB,EAAC,IAAI,EAAE,UAAU,EAAC,CACrB;QAEkB,IAAA,CAAA,CAAC,GAAG,MAAM,CAAC,uBAAuB,EAAE,EAAC,IAAI,EAAE,IAAI,EAAC;aAC9D,IAAI,CAAC,kBAAkB,EAAE;AACzB,aAAA,SAAS,CAAC,MAAM,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,eAAe,EAAE,CAAC,CAAC;AAEjD,QAAA,IAAA,CAAA,WAAW,GAAG,KAAK,CAAiB,YAAY,CAAC;AACjD,QAAA,IAAA,CAAA,eAAe,GAAG,KAAK,CAAC,CAAC,CAAC;AAyE7C,IAAA;IAvEU,WAAW,GAAA;QACd,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,eAAe,EAAE,CAAC;IAC/C;AAEO,IAAA,OAAO,CAAC,IAAiB,EAAA;Q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()) : '')));
|
|
21
21
|
this.showIcons = input(this.options.showIcons);
|
|
22
22
|
}
|
|
23
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
24
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.
|
|
23
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiSwitch, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
24
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.20", type: TuiSwitch, isStandalone: true, selector: "input[type=\"checkbox\"][tuiSwitch]", inputs: { showIcons: { classPropertyName: "showIcons", publicName: "showIcons", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "switch": "", "role": "switch" }, properties: { "class._native": "native" } }, providers: [tuiProvide(TUI_RADIO_OPTIONS, TUI_SWITCH_OPTIONS)], usesInheritance: true, hostDirectives: [{ directive: i1.TuiIcons }], ngImport: i0, template: '', isInline: true, styles: ["[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]){transition-property:background,box-shadow;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:inline-block;inline-size:3rem;block-size:1.5rem;border-radius:2rem;overflow:hidden;cursor:pointer;margin:0;flex-shrink:0;color:#fff!important}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]{block-size:1rem;inline-size:2rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:before{inline-size:1rem;transform:translate(calc(var(--tui-inline) * -1rem));font-size:.75rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:after{inline-size:1rem;box-shadow:calc(var(--tui-inline) * -2.625rem) 0 0 .5rem var(--tui-background-base);outline-width:.167rem;transform:scale(.375)}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:checked:after{transform:scale(.375) translate(calc(var(--tui-inline) * 2.625rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):checked:before{transform:none}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):checked:after{transform:scale(.33333) translate(calc(var(--tui-inline) * 4.5rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):disabled._readonly._readonly{opacity:1}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):before,[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):after{position:absolute;block-size:100%;inline-size:1.5rem;transition-property:transform;zoom:1}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):before{inset-inline-start:.125rem;font-size:1rem;transform:translate(calc(var(--tui-inline) * -1.5rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):after{display:block;inset-inline-end:0;border-radius:100%;background:none;transform:scale(.33333);box-shadow:calc(var(--tui-inline) * -4.5rem) 0 0 .75rem var(--tui-background-base);outline:.375rem solid var(--tui-background-neutral-2-pressed)}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):not([data-icon-start]):after{outline-offset:20rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):invalid:not([data-mode]),[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-mode~=invalid]{color:#fff}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
25
25
|
}
|
|
26
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
26
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiSwitch, decorators: [{
|
|
27
27
|
type: Component,
|
|
28
28
|
args: [{ selector: 'input[type="checkbox"][tuiSwitch]', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiProvide(TUI_RADIO_OPTIONS, TUI_SWITCH_OPTIONS)], hostDirectives: [TuiIcons], host: {
|
|
29
29
|
switch: '',
|
|
30
30
|
role: 'switch',
|
|
31
31
|
'[class._native]': 'native',
|
|
32
|
-
}, styles: ["[tuiSwitch]:where(*[data-tui-version=\"5.
|
|
32
|
+
}, styles: ["[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]){transition-property:background,box-shadow;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:inline-block;inline-size:3rem;block-size:1.5rem;border-radius:2rem;overflow:hidden;cursor:pointer;margin:0;flex-shrink:0;color:#fff!important}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]{block-size:1rem;inline-size:2rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:before{inline-size:1rem;transform:translate(calc(var(--tui-inline) * -1rem));font-size:.75rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:after{inline-size:1rem;box-shadow:calc(var(--tui-inline) * -2.625rem) 0 0 .5rem var(--tui-background-base);outline-width:.167rem;transform:scale(.375)}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-size=s]:checked:after{transform:scale(.375) translate(calc(var(--tui-inline) * 2.625rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):checked:before{transform:none}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):checked:after{transform:scale(.33333) translate(calc(var(--tui-inline) * 4.5rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):disabled._readonly._readonly{opacity:1}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):before,[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):after{position:absolute;block-size:100%;inline-size:1.5rem;transition-property:transform;zoom:1}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):before{inset-inline-start:.125rem;font-size:1rem;transform:translate(calc(var(--tui-inline) * -1.5rem))}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):after{display:block;inset-inline-end:0;border-radius:100%;background:none;transform:scale(.33333);box-shadow:calc(var(--tui-inline) * -4.5rem) 0 0 .75rem var(--tui-background-base);outline:.375rem solid var(--tui-background-neutral-2-pressed)}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):not([data-icon-start]):after{outline-offset:20rem}[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"]):invalid:not([data-mode]),[tuiSwitch]:where(*[data-tui-version=\"5.1.0\"])[data-mode~=invalid]{color:#fff}\n"] }]
|
|
33
33
|
}] });
|
|
34
34
|
|
|
35
35
|
/**
|
|
@@ -42,10 +42,10 @@ class TuiTab {
|
|
|
42
42
|
this.el.blur();
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
46
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.
|
|
45
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTab, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
46
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.20", type: TuiTab, isStandalone: true, selector: "a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]", host: { attributes: { "type": "button" } }, hostDirectives: [{ directive: i1.TuiWithIcons }], ngImport: i0 }); }
|
|
47
47
|
}
|
|
48
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
48
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTab, decorators: [{
|
|
49
49
|
type: Directive,
|
|
50
50
|
args: [{
|
|
51
51
|
selector: 'a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]',
|
|
@@ -64,12 +64,12 @@ const TUI_TABS_DEFAULT_OPTIONS = {
|
|
|
64
64
|
const [TUI_TABS_OPTIONS, tuiTabsOptionsProvider] = tuiCreateOptions(TUI_TABS_DEFAULT_OPTIONS);
|
|
65
65
|
|
|
66
66
|
class Styles {
|
|
67
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
68
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.
|
|
67
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: Styles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
68
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: Styles, isStandalone: true, selector: "ng-component", exportAs: ["tui-tabs-5.1.0"], ngImport: i0, template: '', isInline: true, styles: ["[tuiTab]:where(*[data-tui-version=\"5.1.0\"]){transition-property:color,box-shadow,opacity,background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;flex-shrink:0;box-sizing:border-box;justify-content:space-between;line-height:1.5rem;align-items:center;white-space:nowrap;cursor:pointer;outline:none;color:inherit;margin-inline-start:var(--tui-tab-margin, 1.5rem)}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):disabled{opacity:var(--tui-disabled-opacity);pointer-events:none}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])._active{color:var(--tui-text-primary);box-shadow:none;anchor-name:--tui-tab-active}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):focus-visible{outline:.125rem solid var(--tui-border-focus);outline-offset:-.125rem}tui-tabs._underline [tuiTab]:where(*[data-tui-version=\"5.1.0\"]):hover:not(._active){box-shadow:inset 0 -.125rem var(--tui-border-normal)}tui-tabs>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child,tui-tabs>:not(.t-overflown)>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child{margin-inline-start:0}tui-tabs>[tuiTab]~:not(.t-overflown)>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child{margin-inline-start:var(--tui-tab-margin, 1.5rem)}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])[tuiIcons]:before{font-size:1rem;margin-inline-end:.5rem}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])[tuiIcons]:after{font-size:1rem;margin-inline-start:.5rem}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):empty:after,[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):empty:before{margin:.5rem}@media (hover: hover) and (pointer: fine){[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):hover{color:var(--tui-text-primary)}}tui-tabs:where(*[data-tui-version=\"5.1.0\"]){scrollbar-width:none;-ms-overflow-style:none;position:relative;display:flex;flex-shrink:0;font:var(--tui-typography-body-m);color:var(--tui-text-secondary);box-shadow:inset 0 -1px var(--tui-border-normal);overflow:auto;isolation:isolate;anchor-scope:--tui-tab-active}tui-tabs:where(*[data-tui-version=\"5.1.0\"])::-webkit-scrollbar,tui-tabs:where(*[data-tui-version=\"5.1.0\"])::-webkit-scrollbar-thumb{display:none}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=m]{font:var(--tui-typography-body-s);--tui-tab-margin: 1rem}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=l]:not([data-vertical]){block-size:var(--tui-height-l)}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=m]:not([data-vertical]){block-size:var(--tui-height-m)}tui-tabs:where(*[data-tui-version=\"5.1.0\"]):before{transition-property:inline-size,inset-inline-start;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;inset-block-end:0;inset-inline-start:var(--t-left);block-size:.125rem;inline-size:var(--t-width);background:var(--t-color);animation:tuiPresent 1ms;contain:strict}@supports (anchor-name: --tui-tab-active){tui-tabs:where(*[data-tui-version=\"5.1.0\"]):before{inset-inline-start:anchor(start);inline-size:anchor-size(inline);position-anchor:--tui-tab-active}}tui-tabs:where(*[data-tui-version=\"5.1.0\"])._underline:before{content:\"\"}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]){flex-direction:column;box-shadow:inset calc(-1px * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]{min-block-size:2.75rem;block-size:auto;white-space:normal;margin:0;text-align:start;padding:.25rem 1.25rem}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]:after{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;display:block;inset-block-start:0;inset-inline-end:0;block-size:100%;inline-size:.125rem;background:var(--tui-background-accent-1);transform:scaleX(0);transform-origin:right;margin:0}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]:hover{box-shadow:inset calc(-.125rem * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]._active:after{transform:none}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-size=m] [tuiTab]{min-block-size:2.25rem;font:var(--tui-typography-body-s)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end]{box-shadow:inset calc(1px * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]{text-align:end}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]:after{inset-inline:0 auto;transform-origin:left}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]:hover{box-shadow:inset calc(.125rem * var(--tui-inline)) 0 var(--tui-border-normal)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
69
69
|
}
|
|
70
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
70
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: Styles, decorators: [{
|
|
71
71
|
type: Component,
|
|
72
|
-
args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, exportAs: `tui-tabs-${TUI_VERSION}`, styles: ["[tuiTab]:where(*[data-tui-version=\"5.
|
|
72
|
+
args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, exportAs: `tui-tabs-${TUI_VERSION}`, styles: ["[tuiTab]:where(*[data-tui-version=\"5.1.0\"]){transition-property:color,box-shadow,opacity,background;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;text-decoration:none;position:relative;display:flex;flex-shrink:0;box-sizing:border-box;justify-content:space-between;line-height:1.5rem;align-items:center;white-space:nowrap;cursor:pointer;outline:none;color:inherit;margin-inline-start:var(--tui-tab-margin, 1.5rem)}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):disabled{opacity:var(--tui-disabled-opacity);pointer-events:none}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])._active{color:var(--tui-text-primary);box-shadow:none;anchor-name:--tui-tab-active}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):focus-visible{outline:.125rem solid var(--tui-border-focus);outline-offset:-.125rem}tui-tabs._underline [tuiTab]:where(*[data-tui-version=\"5.1.0\"]):hover:not(._active){box-shadow:inset 0 -.125rem var(--tui-border-normal)}tui-tabs>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child,tui-tabs>:not(.t-overflown)>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child{margin-inline-start:0}tui-tabs>[tuiTab]~:not(.t-overflown)>[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):first-child{margin-inline-start:var(--tui-tab-margin, 1.5rem)}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])[tuiIcons]:before{font-size:1rem;margin-inline-end:.5rem}[tuiTab]:where(*[data-tui-version=\"5.1.0\"])[tuiIcons]:after{font-size:1rem;margin-inline-start:.5rem}[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):empty:after,[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):empty:before{margin:.5rem}@media (hover: hover) and (pointer: fine){[tuiTab]:where(*[data-tui-version=\"5.1.0\"]):hover{color:var(--tui-text-primary)}}tui-tabs:where(*[data-tui-version=\"5.1.0\"]){scrollbar-width:none;-ms-overflow-style:none;position:relative;display:flex;flex-shrink:0;font:var(--tui-typography-body-m);color:var(--tui-text-secondary);box-shadow:inset 0 -1px var(--tui-border-normal);overflow:auto;isolation:isolate;anchor-scope:--tui-tab-active}tui-tabs:where(*[data-tui-version=\"5.1.0\"])::-webkit-scrollbar,tui-tabs:where(*[data-tui-version=\"5.1.0\"])::-webkit-scrollbar-thumb{display:none}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=m]{font:var(--tui-typography-body-s);--tui-tab-margin: 1rem}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=l]:not([data-vertical]){block-size:var(--tui-height-l)}tui-tabs:where(*[data-tui-version=\"5.1.0\"])[data-size=m]:not([data-vertical]){block-size:var(--tui-height-m)}tui-tabs:where(*[data-tui-version=\"5.1.0\"]):before{transition-property:inline-size,inset-inline-start;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:absolute;inset-block-end:0;inset-inline-start:var(--t-left);block-size:.125rem;inline-size:var(--t-width);background:var(--t-color);animation:tuiPresent 1ms;contain:strict}@supports (anchor-name: --tui-tab-active){tui-tabs:where(*[data-tui-version=\"5.1.0\"]):before{inset-inline-start:anchor(start);inline-size:anchor-size(inline);position-anchor:--tui-tab-active}}tui-tabs:where(*[data-tui-version=\"5.1.0\"])._underline:before{content:\"\"}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]){flex-direction:column;box-shadow:inset calc(-1px * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]{min-block-size:2.75rem;block-size:auto;white-space:normal;margin:0;text-align:start;padding:.25rem 1.25rem}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]:after{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;content:\"\";position:absolute;display:block;inset-block-start:0;inset-inline-end:0;block-size:100%;inline-size:.125rem;background:var(--tui-background-accent-1);transform:scaleX(0);transform-origin:right;margin:0}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]:hover{box-shadow:inset calc(-.125rem * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"]) [tuiTab]._active:after{transform:none}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-size=m] [tuiTab]{min-block-size:2.25rem;font:var(--tui-typography-body-s)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end]{box-shadow:inset calc(1px * var(--tui-inline)) 0 var(--tui-border-normal)}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]{text-align:end}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]:after{inset-inline:0 auto;transform-origin:left}tui-tabs[data-vertical]:where(*[data-tui-version=\"5.1.0\"])[data-vertical=end] [tuiTab]:hover{box-shadow:inset calc(.125rem * var(--tui-inline)) 0 var(--tui-border-normal)}\n"] }]
|
|
73
73
|
}] });
|
|
74
74
|
class TuiTabsDirective {
|
|
75
75
|
constructor() {
|
|
@@ -105,10 +105,10 @@ class TuiTabsDirective {
|
|
|
105
105
|
nativeElement.setAttribute('tabIndex', active ? '0' : '-1');
|
|
106
106
|
});
|
|
107
107
|
}
|
|
108
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
109
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.
|
|
108
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
109
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.20", type: TuiTabsDirective, isStandalone: true, inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, activeItemIndex: { classPropertyName: "activeItemIndex", publicName: "activeItemIndex", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activeItemIndex: "activeItemIndexChange" }, host: { attributes: { "data-tui-version": "5.1.0" }, listeners: { "tui-tab-activate.stop": "onActivate($event.target)" }, properties: { "attr.data-size": "size()" } }, ngImport: i0 }); }
|
|
110
110
|
}
|
|
111
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
111
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsDirective, decorators: [{
|
|
112
112
|
type: Directive,
|
|
113
113
|
args: [{
|
|
114
114
|
host: {
|
|
@@ -162,8 +162,8 @@ class TuiTabsHorizontal {
|
|
|
162
162
|
this.el.style.setProperty('--t-left', tuiPx(offsetLeft));
|
|
163
163
|
this.el.style.setProperty('--t-width', tuiPx(offsetWidth));
|
|
164
164
|
}
|
|
165
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
166
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.
|
|
165
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsHorizontal, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
166
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.20", type: TuiTabsHorizontal, isStandalone: true, selector: "tui-tabs:not([vertical])", inputs: { underline: { classPropertyName: "underline", publicName: "underline", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "animationend": "refresh()", "keydown.arrowRight.prevent": "onKeyDownArrow($event.target, 1)", "keydown.arrowLeft.prevent": "onKeyDownArrow($event.target, -1)" }, properties: { "class._underline": "underline()", "style.--t-color": "underline() === true ? 'var(--tui-background-accent-1)' : underline()" } }, providers: [
|
|
167
167
|
WaMutationObserverService,
|
|
168
168
|
{
|
|
169
169
|
provide: WA_MUTATION_OBSERVER_INIT,
|
|
@@ -175,7 +175,7 @@ class TuiTabsHorizontal {
|
|
|
175
175
|
},
|
|
176
176
|
], hostDirectives: [{ directive: TuiTabsDirective, inputs: ["activeItemIndex", "activeItemIndex", "size", "size"], outputs: ["activeItemIndexChange", "activeItemIndexChange"] }], ngImport: i0 }); }
|
|
177
177
|
}
|
|
178
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
178
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsHorizontal, decorators: [{
|
|
179
179
|
type: Directive,
|
|
180
180
|
args: [{
|
|
181
181
|
selector: 'tui-tabs:not([vertical])',
|
|
@@ -215,10 +215,10 @@ class TuiTabsVertical {
|
|
|
215
215
|
onKeyDownArrow(current, step) {
|
|
216
216
|
this.tabs.moveFocus(current, step);
|
|
217
217
|
}
|
|
218
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
219
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.
|
|
218
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsVertical, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
219
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.20", type: TuiTabsVertical, isStandalone: true, selector: "tui-tabs[vertical]", inputs: { vertical: { classPropertyName: "vertical", publicName: "vertical", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "keydown.arrowDown.prevent": "onKeyDownArrow($event.target, 1)", "keydown.arrowUp.prevent": "onKeyDownArrow($event.target, -1)" }, properties: { "attr.data-vertical": "vertical()" } }, hostDirectives: [{ directive: TuiTabsDirective, inputs: ["activeItemIndex", "activeItemIndex", "size", "size"], outputs: ["activeItemIndexChange", "activeItemIndexChange"] }], ngImport: i0 }); }
|
|
220
220
|
}
|
|
221
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
221
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsVertical, decorators: [{
|
|
222
222
|
type: Directive,
|
|
223
223
|
args: [{
|
|
224
224
|
selector: 'tui-tabs[vertical]',
|
|
@@ -409,10 +409,10 @@ class TuiTabsWithMore {
|
|
|
409
409
|
this.dir()?.nativeElement.style.setProperty('--t-left', tuiPx(offsetLeft));
|
|
410
410
|
this.dir()?.nativeElement.style.setProperty('--t-width', tuiPx(offsetWidth));
|
|
411
411
|
}
|
|
412
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
413
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.
|
|
412
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsWithMore, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
413
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: TuiTabsWithMore, isStandalone: true, selector: "tui-tabs-with-more", inputs: { activeItemIndex: { classPropertyName: "activeItemIndex", publicName: "activeItemIndex", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, underline: { classPropertyName: "underline", publicName: "underline", isSignal: true, isRequired: false, transformFunction: null }, itemsLimit: { classPropertyName: "itemsLimit", publicName: "itemsLimit", isSignal: true, isRequired: false, transformFunction: null }, moreContent: { classPropertyName: "moreContent", publicName: "moreContent", isSignal: true, isRequired: false, transformFunction: null }, dropdownContent: { classPropertyName: "dropdownContent", publicName: "dropdownContent", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activeItemIndex: "activeItemIndexChange" }, host: { properties: { "attr.data-size": "size()" } }, providers: TUI_TABS_PROVIDERS, queries: [{ propertyName: "items", predicate: TuiItem, read: TemplateRef, isSignal: true }], viewQueries: [{ propertyName: "moreButton", first: true, predicate: TuiTab, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "dir", first: true, predicate: TuiTabsHorizontal, descendants: true, read: ElementRef, isSignal: true }], ngImport: i0, template: "<tui-tabs\n class=\"t-tabs\"\n [size]=\"size()\"\n [underline]=\"underline()\"\n [(activeItemIndex)]=\"activeItemIndex\"\n (keydown.arrowRight)=\"onArrowRight($event)\"\n>\n @for (item of items(); track item) {\n @if ($index <= lastVisibleIndex) {\n <ng-container [ngTemplateOutlet]=\"item\" />\n } @else {\n <div\n class=\"t-flex\"\n [class.t-overflown]=\"isOverflown($index)\"\n >\n <ng-container [ngTemplateOutlet]=\"item\" />\n </div>\n }\n }\n</tui-tabs>\n\n@if (moreContent()) {\n <button\n tuiTab\n type=\"button\"\n class=\"t-more\"\n [class._active]=\"isMoreActive\"\n [class.t-no-margin]=\"isMoreAlone\"\n [class.t-overflown]=\"!isMoreVisible\"\n [tabIndex]=\"isMoreFocusable ? 0 : -1\"\n [tuiDropdown]=\"dropdownContent() || dropdown\"\n [(tuiDropdownOpen)]=\"open\"\n (keydown.arrowLeft.prevent)=\"onArrowLeft()\"\n >\n <ng-container *polymorpheusOutlet=\"moreContent() as text\">\n {{ text }}\n </ng-container>\n </button>\n} @else {\n <button\n tuiChevron\n tuiTab\n type=\"button\"\n class=\"t-more\"\n [class._active]=\"isMoreActive\"\n [class.t-no-margin]=\"isMoreAlone\"\n [class.t-overflown]=\"!isMoreVisible\"\n [tabIndex]=\"isMoreFocusable ? 0 : -1\"\n [tuiDropdown]=\"dropdownContent() || dropdown\"\n [(tuiDropdownOpen)]=\"open\"\n (keydown.arrowLeft.prevent)=\"onArrowLeft()\"\n >\n {{ moreWord() }}\n </button>\n}\n<ng-template #dropdown>\n <div\n #element\n class=\"t-dropdown\"\n [attr.data-size]=\"size()\"\n (keydown.arrowDown.prevent)=\"onWrapperArrow($event, element, false)\"\n (keydown.arrowUp.prevent)=\"onWrapperArrow($event, element, true)\"\n >\n @for (item of items(); track item) {\n <div\n class=\"t-dropdown-item\"\n (tui-tab-activate)=\"onClick($index)\"\n >\n @if (shouldShow($index)) {\n <ng-container *polymorpheusOutlet=\"item\" />\n }\n </div>\n }\n </div>\n</ng-template>\n\n<ng-content />\n", styles: [":host{position:relative;display:flex;flex-shrink:0;font:var(--tui-typography-body-m);box-sizing:border-box;color:var(--tui-text-secondary);box-shadow:inset 0 -1px var(--tui-border-normal);overflow:hidden}:host[data-size=m]{font:var(--tui-typography-body-s)}.t-tabs{block-size:inherit;font:inherit;overflow:visible;box-shadow:none;color:inherit}.t-flex{display:flex}.t-overflown{margin:0;inline-size:0;max-inline-size:0;overflow:hidden;visibility:hidden}.t-icon{transition-property:transform;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;margin-inline-end:-.25rem;vertical-align:bottom}.t-icon_rotated{transform:rotate(180deg)}.t-dropdown{padding:.25rem 0}.t-dropdown ::ng-deep *[tuiTab]{inline-size:calc(100% - .75rem);block-size:2.75rem;justify-content:flex-start;margin:.125rem .375rem;padding:0 .625rem;border-radius:var(--tui-radius-s);font:var(--tui-typography-body-m);line-height:1.5rem;color:var(--tui-text-primary)}.t-dropdown ::ng-deep *[tuiTab]:before{display:none}.t-dropdown ::ng-deep *[tuiTab]:hover,.t-dropdown ::ng-deep *[tuiTab]:focus,.t-dropdown ::ng-deep *[tuiTab]._active{box-shadow:none;outline:none;background:var(--tui-background-neutral-1)}.t-dropdown[data-size=m] ::ng-deep *[tuiTab]{block-size:2.25rem;font:var(--tui-typography-body-s)}.t-dropdown-item{display:flex;flex-direction:column}.t-no-margin{margin-inline-start:0}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiChevron, selector: "[tuiChevron]", inputs: ["tuiChevron"] }, { kind: "directive", type: i1$1.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container):not(ng-template)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { kind: "directive", type: i1$1.TuiDropdownOpen, selector: "[tuiDropdown][tuiDropdownAuto],[tuiDropdown][tuiDropdownOpen],[tuiDropdown][tuiDropdownOpenChange]", inputs: ["tuiDropdownEnabled", "tuiDropdownOpen"], outputs: ["tuiDropdownOpenChange"] }, { kind: "directive", type: TuiTab, selector: "a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]" }, { kind: "directive", type: TuiTabsHorizontal, selector: "tui-tabs:not([vertical])", inputs: ["underline"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
414
414
|
}
|
|
415
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
415
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTabsWithMore, decorators: [{
|
|
416
416
|
type: Component,
|
|
417
417
|
args: [{ selector: 'tui-tabs-with-more', imports: [
|
|
418
418
|
NgTemplateOutlet,
|
|
@@ -38,10 +38,10 @@ class TuiTextareaComponent {
|
|
|
38
38
|
onScroll() {
|
|
39
39
|
this.text()?.nativeElement.scrollTo({ top: this.el.scrollTop });
|
|
40
40
|
}
|
|
41
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
42
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.
|
|
41
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
42
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: TuiTextareaComponent, isStandalone: true, selector: "textarea[tuiTextarea]", inputs: { min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "ngSkipHydration": "true" }, listeners: { "scroll.zoneless": "onScroll()", "scroll.once": "onScroll()" }, properties: { "class._mobile": "isMobile" } }, providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)], viewQueries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true, isSignal: true }, { propertyName: "text", first: true, predicate: ["text"], descendants: true, read: ElementRef, isSignal: true }], hostDirectives: [{ directive: i1.TuiWithInput }], ngImport: i0, template: "<ng-template>\n @if (!isMobile) {\n <tui-scroll-controls\n class=\"t-scroll\"\n (click.prevent)=\"(0)\"\n />\n }\n <span\n #text\n aria-hidden=\"true\"\n class=\"t-ghost\"\n [style.max-height.em]=\"1.25 * max()\"\n [style.min-height.em]=\"1.25 * min()\"\n >\n <ng-container *polymorpheusOutlet=\"content() as text; context: {$implicit: el.value}\">{{ text }}</ng-container>\n </span>\n</ng-template>\n", styles: [":host-context(tui-textfield._with-label[data-size=\"m\"]._with-label[data-size=\"m\"]){border-block-start-width:calc(.5rem + var(--t-height) / 3);padding-block:0}:host-context(tui-textfield._with-label[data-size=\"l\"]._with-label[data-size=\"l\"]){border-block-start-width:calc(.625rem + var(--t-height) / 3);padding-block:0}:host-context(tui-textfield[data-size=\"s\"]){padding-block:.5rem .25rem}:host-context(tui-textfield[data-size=\"m\"]){padding-block:.875rem .25rem}:host-context(tui-textfield[data-size=\"l\"]){padding-block:1.125rem .375rem}:host:host{block-size:100%;white-space:pre-wrap;overflow:auto;word-break:break-word;border:0 solid transparent}:host:host:not(._mobile){scrollbar-width:none;-ms-overflow-style:none}:host:host:not(._mobile)::-webkit-scrollbar,:host:host:not(._mobile)::-webkit-scrollbar-thumb{display:none}.t-scroll{position:absolute;inset:.25rem 0;min-block-size:0}::ng-deep tui-textfield._with-label[data-size=m] .t-scroll{inset-block-start:calc(.5rem + var(--t-height) / 3)}::ng-deep tui-textfield._with-label[data-size=l] .t-scroll{inset-block-start:calc(.625rem + var(--t-height) / 3)}.t-ghost{position:relative;z-index:1;order:1;inline-size:calc(100% - var(--t-start) - var(--t-end) - var(--t-side));white-space:pre-wrap;word-break:break-word;overflow-wrap:break-word;padding-inline-start:var(--t-start);padding-inline-end:calc(var(--t-end) + var(--t-side));pointer-events:none;box-sizing:content-box;overflow:hidden;color:transparent}.t-ghost:after{content:\" \"}::ng-deep tui-textfield._with-label[data-size=m] textarea~.t-ghost{margin-block-start:-1.375rem;padding-block-end:.3125rem}::ng-deep tui-textfield._with-label[data-size=l] textarea~.t-ghost{margin-block-start:-1.75rem;padding-block-end:.5rem}::ng-deep tui-textfield[data-size=s] textarea~.t-ghost{margin-block-start:-1.5rem;padding-block-end:.5rem}::ng-deep tui-textfield[data-size=m] textarea~.t-ghost{margin-block-start:-2rem;padding-block-end:.875rem}::ng-deep tui-textfield[data-size=l] textarea~.t-ghost{margin-block-start:-2.5rem;padding-block-end:1rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: TuiScrollControls, selector: "tui-scroll-controls" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
43
43
|
}
|
|
44
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
44
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaComponent, decorators: [{
|
|
45
45
|
type: Component,
|
|
46
46
|
args: [{ selector: 'textarea[tuiTextarea]', imports: [PolymorpheusOutlet, TuiScrollControls], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)], hostDirectives: [TuiWithInput], host: {
|
|
47
47
|
ngSkipHydration: 'true',
|
|
@@ -57,10 +57,10 @@ class TuiTextareaCounter {
|
|
|
57
57
|
this.limit = signal(0);
|
|
58
58
|
this.length = signal(0);
|
|
59
59
|
}
|
|
60
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
61
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.
|
|
60
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaCounter, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
61
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: TuiTextareaCounter, isStandalone: true, selector: "ng-component", ngImport: i0, template: '{{ length() }} / {{ limit() }}', isInline: true, styles: [":host{z-index:1;inline-size:100%;order:2;text-align:end;pointer-events:none;padding-block-end:.75rem;font:var(--tui-typography-ui-2xs);color:var(--tui-text-secondary)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
62
62
|
}
|
|
63
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
63
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaCounter, decorators: [{
|
|
64
64
|
type: Component,
|
|
65
65
|
args: [{ template: '{{ length() }} / {{ limit() }}', changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{z-index:1;inline-size:100%;order:2;text-align:end;pointer-events:none;padding-block-end:.75rem;font:var(--tui-typography-ui-2xs);color:var(--tui-text-secondary)}\n"] }]
|
|
66
66
|
}] });
|
|
@@ -69,13 +69,13 @@ class TuiTextareaLimit {
|
|
|
69
69
|
this.limit = inject(TuiTextareaDirective).limit;
|
|
70
70
|
this.context = injectContext();
|
|
71
71
|
}
|
|
72
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
73
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.
|
|
72
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaLimit, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
73
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: TuiTextareaLimit, isStandalone: true, selector: "ng-component", ngImport: i0, template: `
|
|
74
74
|
<span [textContent]="context.$implicit.slice(0, limit())"></span>
|
|
75
75
|
<span [textContent]="context.$implicit.slice(limit())"></span>
|
|
76
76
|
`, isInline: true, styles: ["span:last-child{background:linear-gradient(transparent .25rem,var(--tui-status-negative-pale) .25rem,var(--tui-status-negative-pale) 100%)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
77
77
|
}
|
|
78
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
78
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaLimit, decorators: [{
|
|
79
79
|
type: Component,
|
|
80
80
|
args: [{ template: `
|
|
81
81
|
<span [textContent]="context.$implicit.slice(0, limit())"></span>
|
|
@@ -97,13 +97,13 @@ class TuiTextareaDirective {
|
|
|
97
97
|
validate(control) {
|
|
98
98
|
return Validators.maxLength(this.limit())(control);
|
|
99
99
|
}
|
|
100
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
101
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.
|
|
100
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
101
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.20", type: TuiTextareaDirective, isStandalone: true, selector: "[tuiTextarea][limit]", inputs: { limit: { classPropertyName: "limit", publicName: "limit", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "style.border-block-end-width.rem": "size() === \"l\" ? 1.875 : 1.75" } }, providers: [
|
|
102
102
|
tuiProvide(NG_VALIDATORS, TuiTextareaDirective, true),
|
|
103
103
|
tuiTextareaOptionsProvider({ content: COMPONENT }),
|
|
104
104
|
], ngImport: i0 }); }
|
|
105
105
|
}
|
|
106
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
106
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTextareaDirective, decorators: [{
|
|
107
107
|
type: Directive,
|
|
108
108
|
args: [{
|
|
109
109
|
selector: '[tuiTextarea][limit]',
|
|
@@ -71,17 +71,17 @@ class TuiTilesComponent {
|
|
|
71
71
|
: new Map(elements.map((_, index) => [index, index]));
|
|
72
72
|
return this.handler(order, currentIndex, newIndex);
|
|
73
73
|
}
|
|
74
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
75
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.
|
|
74
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTilesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
75
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.20", type: TuiTilesComponent, isStandalone: true, selector: "tui-tiles", inputs: { debounce: { classPropertyName: "debounce", publicName: "debounce", isSignal: true, isRequired: false, transformFunction: null }, order: { classPropertyName: "order", publicName: "order", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { order: "orderChange" }, host: { attributes: { "data-tui-version": "5.1.0" }, listeners: { "pointerleave.zoneless": "rearrange()" } }, providers: [
|
|
76
76
|
WaResizeObserverService,
|
|
77
77
|
WaMutationObserverService,
|
|
78
78
|
{
|
|
79
79
|
provide: WA_MUTATION_OBSERVER_INIT,
|
|
80
80
|
useValue: { childList: true },
|
|
81
81
|
},
|
|
82
|
-
], ngImport: i0, template: '<ng-content />', isInline: true, styles: ["tui-tiles:where(*[data-tui-version=\"5.
|
|
82
|
+
], ngImport: i0, template: '<ng-content />', isInline: true, styles: ["tui-tiles:where(*[data-tui-version=\"5.1.0\"]){position:relative;z-index:0;display:grid;grid-auto-flow:dense;justify-items:stretch}tui-tiles:where(*[data-tui-version=\"5.1.0\"])._dragged tui-tile>.t-wrapper{pointer-events:none}tui-tiles:where(*[data-tui-version=\"5.1.0\"])._dragged tui-tile:not(._dragged)>.t-wrapper,tui-tiles:where(*[data-tui-version=\"5.1.0\"]):not(._dragged) tui-tile._dragged>.t-wrapper{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;transition-delay:1ms}tui-tile:where(*[data-tui-version=\"5.1.0\"])>.t-wrapper{position:absolute;z-index:0;border-radius:inherit}tui-tile:where(*[data-tui-version=\"5.1.0\"])._dragged>.t-wrapper,tui-tile:where(*[data-tui-version=\"5.1.0\"]):has(tui-tile:where(*[data-tui-version=\"5.1.0\"])._dragged)>.t-wrapper{z-index:1}tui-tile:where(*[data-tui-version=\"5.1.0\"]) [tuiTileHandle]{touch-action:none;-webkit-user-select:none;user-select:none}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
83
83
|
}
|
|
84
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
84
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTilesComponent, decorators: [{
|
|
85
85
|
type: Component,
|
|
86
86
|
args: [{ selector: 'tui-tiles', template: '<ng-content />', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
87
87
|
WaResizeObserverService,
|
|
@@ -90,7 +90,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.19", ngImpo
|
|
|
90
90
|
provide: WA_MUTATION_OBSERVER_INIT,
|
|
91
91
|
useValue: { childList: true },
|
|
92
92
|
},
|
|
93
|
-
], host: { 'data-tui-version': TUI_VERSION, '(pointerleave.zoneless)': 'rearrange()' }, styles: ["tui-tiles:where(*[data-tui-version=\"5.
|
|
93
|
+
], host: { 'data-tui-version': TUI_VERSION, '(pointerleave.zoneless)': 'rearrange()' }, styles: ["tui-tiles:where(*[data-tui-version=\"5.1.0\"]){position:relative;z-index:0;display:grid;grid-auto-flow:dense;justify-items:stretch}tui-tiles:where(*[data-tui-version=\"5.1.0\"])._dragged tui-tile>.t-wrapper{pointer-events:none}tui-tiles:where(*[data-tui-version=\"5.1.0\"])._dragged tui-tile:not(._dragged)>.t-wrapper,tui-tiles:where(*[data-tui-version=\"5.1.0\"]):not(._dragged) tui-tile._dragged>.t-wrapper{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;transition-delay:1ms}tui-tile:where(*[data-tui-version=\"5.1.0\"])>.t-wrapper{position:absolute;z-index:0;border-radius:inherit}tui-tile:where(*[data-tui-version=\"5.1.0\"])._dragged>.t-wrapper,tui-tile:where(*[data-tui-version=\"5.1.0\"]):has(tui-tile:where(*[data-tui-version=\"5.1.0\"])._dragged)>.t-wrapper{z-index:1}tui-tile:where(*[data-tui-version=\"5.1.0\"]) [tuiTileHandle]{touch-action:none;-webkit-user-select:none;user-select:none}\n"] }]
|
|
94
94
|
}] });
|
|
95
95
|
|
|
96
96
|
class TuiTileService {
|
|
@@ -99,7 +99,10 @@ class TuiTileService {
|
|
|
99
99
|
this.el = tuiInjectElement();
|
|
100
100
|
this.tiles = inject(TuiTilesComponent);
|
|
101
101
|
this.sub = new Subscription();
|
|
102
|
-
this.offset$ = new BehaviorSubject([
|
|
102
|
+
this.offset$ = new BehaviorSubject([
|
|
103
|
+
Number.NaN,
|
|
104
|
+
Number.NaN,
|
|
105
|
+
]);
|
|
103
106
|
this.position$ = combineLatest([
|
|
104
107
|
this.offset$.pipe(distinctUntilChanged(tuiArrayShallowEquals)),
|
|
105
108
|
inject(WaResizeObserverService).pipe(startWith(null)),
|
|
@@ -132,8 +135,8 @@ class TuiTileService {
|
|
|
132
135
|
left: elLeft,
|
|
133
136
|
width: this.el.clientWidth,
|
|
134
137
|
height: this.el.clientHeight,
|
|
135
|
-
right: NaN,
|
|
136
|
-
bottom: NaN,
|
|
138
|
+
right: Number.NaN,
|
|
139
|
+
bottom: Number.NaN,
|
|
137
140
|
y: elTop,
|
|
138
141
|
x: elLeft,
|
|
139
142
|
};
|
|
@@ -165,10 +168,10 @@ class TuiTileService {
|
|
|
165
168
|
style.top = tuiPx(rect.top - host.top + this.el.offsetTop);
|
|
166
169
|
style.left = tuiPx(rect.left - host.left + this.el.offsetLeft);
|
|
167
170
|
}
|
|
168
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
169
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.
|
|
171
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTileService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
172
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTileService }); }
|
|
170
173
|
}
|
|
171
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
174
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTileService, decorators: [{
|
|
172
175
|
type: Injectable
|
|
173
176
|
}] });
|
|
174
177
|
|
|
@@ -202,10 +205,10 @@ class TuiTile {
|
|
|
202
205
|
this.tiles.element.set(null);
|
|
203
206
|
}
|
|
204
207
|
}
|
|
205
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
206
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.
|
|
208
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTile, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
209
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.20", type: TuiTile, isStandalone: true, selector: "tui-tile", inputs: { width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-tui-version": "5.1.0" }, listeners: { "pointerenter": "tiles.rearrange(element)" }, properties: { "class._dragged": "dragged()", "style.grid-column": "`span var(--tui-width, ${width()})`", "style.grid-row": "`span var(--tui-height, ${height()})`" } }, providers: [TuiTileService], viewQueries: [{ propertyName: "wrapper", first: true, predicate: ["wrapper"], descendants: true, read: ElementRef, isSignal: true }], ngImport: i0, template: "<div\n #wrapper\n class=\"t-wrapper\"\n (transitionend.self)=\"dragged.set(false)\"\n>\n <ng-content />\n</div>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
207
210
|
}
|
|
208
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
211
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTile, decorators: [{
|
|
209
212
|
type: Component,
|
|
210
213
|
args: [{ selector: 'tui-tile', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TuiTileService], host: {
|
|
211
214
|
'data-tui-version': TUI_VERSION,
|
|
@@ -220,8 +223,8 @@ class TuiTileHandle {
|
|
|
220
223
|
constructor() {
|
|
221
224
|
this.doc = inject(DOCUMENT);
|
|
222
225
|
this.tile = inject(TuiTile);
|
|
223
|
-
this.x = NaN;
|
|
224
|
-
this.y = NaN;
|
|
226
|
+
this.x = Number.NaN;
|
|
227
|
+
this.y = Number.NaN;
|
|
225
228
|
this.pointerSub = merge(tuiTypedFromEvent(this.doc, 'pointerup'), tuiTypedFromEvent(this.doc, 'pointermove'))
|
|
226
229
|
.pipe(filter(() => !Number.isNaN(this.x)), takeUntilDestroyed())
|
|
227
230
|
.subscribe(({ x, y, type }) => {
|
|
@@ -233,11 +236,11 @@ class TuiTileHandle {
|
|
|
233
236
|
}
|
|
234
237
|
});
|
|
235
238
|
}
|
|
236
|
-
onPointer(x = NaN, y = NaN) {
|
|
239
|
+
onPointer(x = Number.NaN, y = Number.NaN) {
|
|
237
240
|
const { left, top } = this.tile.element.getBoundingClientRect();
|
|
238
241
|
this.x = x - left;
|
|
239
242
|
this.y = y - top;
|
|
240
|
-
this.tile.onDrag([NaN, NaN]);
|
|
243
|
+
this.tile.onDrag([Number.NaN, Number.NaN]);
|
|
241
244
|
}
|
|
242
245
|
onStart(event) {
|
|
243
246
|
const target = tuiGetActualTarget(event);
|
|
@@ -247,10 +250,10 @@ class TuiTileHandle {
|
|
|
247
250
|
}
|
|
248
251
|
this.onPointer(x, y);
|
|
249
252
|
}
|
|
250
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
251
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.
|
|
253
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTileHandle, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
254
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.20", type: TuiTileHandle, isStandalone: true, selector: "[tuiTileHandle]", host: { listeners: { "pointerdown.zoneless.prevent": "onStart($event)" } }, ngImport: i0 }); }
|
|
252
255
|
}
|
|
253
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
256
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: TuiTileHandle, decorators: [{
|
|
254
257
|
type: Directive,
|
|
255
258
|
args: [{
|
|
256
259
|
selector: '[tuiTileHandle]',
|