@taiga-ui/cdk 3.33.1-dev.main-793ee40 → 3.33.1-dev.main-1fa4789
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/taiga-ui-cdk-abstract.umd.js +4 -25
- package/bundles/taiga-ui-cdk-abstract.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-decorators.umd.js +38 -1
- package/bundles/taiga-ui-cdk-decorators.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-active-zone.umd.js +0 -3
- package/bundles/taiga-ui-cdk-directives-active-zone.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-copy-processor.umd.js +4 -325
- package/bundles/taiga-ui-cdk-directives-copy-processor.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-media.umd.js +4 -334
- package/bundles/taiga-ui-cdk-directives-media.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-obscured.umd.js +4 -325
- package/bundles/taiga-ui-cdk-directives-obscured.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-repeat-times.umd.js +4 -325
- package/bundles/taiga-ui-cdk-directives-repeat-times.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-resizer.umd.js +4 -7
- package/bundles/taiga-ui-cdk-directives-resizer.umd.js.map +1 -1
- package/bundles/taiga-ui-cdk-directives-validator.umd.js +4 -325
- package/bundles/taiga-ui-cdk-directives-validator.umd.js.map +1 -1
- package/decorators/debounce.d.ts +4 -0
- package/decorators/default-prop.d.ts +3 -0
- package/decorators/required-setter.d.ts +3 -0
- package/esm2015/abstract/control.js +1 -9
- package/esm2015/abstract/interactive.js +1 -18
- package/esm2015/decorators/debounce.js +5 -1
- package/esm2015/decorators/default-prop.js +4 -1
- package/esm2015/decorators/pure.js +24 -2
- package/esm2015/decorators/required-setter.js +4 -1
- package/esm2015/directives/active-zone/active-zone.directive.js +2 -5
- package/esm2015/directives/copy-processor/copy-processor.directive.js +1 -6
- package/esm2015/directives/media/media.directive.js +1 -15
- package/esm2015/directives/obscured/obscured.directive.js +1 -6
- package/esm2015/directives/repeat-times/repeat-times.directive.js +1 -6
- package/esm2015/directives/resizer/resizer.directive.js +1 -6
- package/esm2015/directives/validator/validator.directive.js +1 -6
- package/fesm2015/taiga-ui-cdk-abstract.js +0 -23
- package/fesm2015/taiga-ui-cdk-abstract.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-decorators.js +33 -1
- package/fesm2015/taiga-ui-cdk-decorators.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-active-zone.js +1 -4
- package/fesm2015/taiga-ui-cdk-directives-active-zone.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-copy-processor.js +0 -5
- package/fesm2015/taiga-ui-cdk-directives-copy-processor.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-media.js +0 -14
- package/fesm2015/taiga-ui-cdk-directives-media.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-obscured.js +0 -5
- package/fesm2015/taiga-ui-cdk-directives-obscured.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-repeat-times.js +0 -5
- package/fesm2015/taiga-ui-cdk-directives-repeat-times.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-resizer.js +0 -5
- package/fesm2015/taiga-ui-cdk-directives-resizer.js.map +1 -1
- package/fesm2015/taiga-ui-cdk-directives-validator.js +0 -5
- package/fesm2015/taiga-ui-cdk-directives-validator.js.map +1 -1
- package/package.json +2 -2
@@ -1,7 +1,5 @@
|
|
1
|
-
import { __decorate } from 'tslib';
|
2
1
|
import * as i0 from '@angular/core';
|
3
2
|
import { EventEmitter, ElementRef, Directive, Inject, Input, HostBinding, Output, HostListener, NgModule } from '@angular/core';
|
4
|
-
import { tuiDefaultProp, tuiRequiredSetter } from '@taiga-ui/cdk/decorators';
|
5
3
|
|
6
4
|
class TuiMediaDirective {
|
7
5
|
constructor(el) {
|
@@ -58,15 +56,6 @@ class TuiMediaDirective {
|
|
58
56
|
}
|
59
57
|
TuiMediaDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiMediaDirective, deps: [{ token: ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
60
58
|
TuiMediaDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.17", type: TuiMediaDirective, selector: "video[tuiMedia], audio[tuiMedia]", inputs: { volume: "volume", playbackRateSetter: ["playbackRate", "playbackRateSetter"], currentTime: "currentTime", paused: "paused" }, outputs: { currentTimeChange: "currentTimeChange", pausedChange: "pausedChange", volumeChange: "volumeChange" }, host: { listeners: { "ended": "onPausedChange(true)", "pause": "onPausedChange(true)", "play": "onPausedChange(false)", "volumechange": "onVolumeChange()", "timeupdate": "onCurrentTimeChange()", "seeking": "onCurrentTimeChange()", "seeked": "onCurrentTimeChange()", "durationchange": "changeDetectionTrigger()" }, properties: { "volume": "this.volume" } }, exportAs: ["tuiMedia"], ngImport: i0 });
|
61
|
-
__decorate([
|
62
|
-
tuiDefaultProp((volume) => Number.isFinite(volume) && volume >= 0 && volume <= 1)
|
63
|
-
], TuiMediaDirective.prototype, "volume", void 0);
|
64
|
-
__decorate([
|
65
|
-
tuiRequiredSetter(nonNegativeFiniteAssertion)
|
66
|
-
], TuiMediaDirective.prototype, "playbackRateSetter", null);
|
67
|
-
__decorate([
|
68
|
-
tuiRequiredSetter(nonNegativeFiniteAssertion)
|
69
|
-
], TuiMediaDirective.prototype, "currentTime", null);
|
70
59
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiMediaDirective, decorators: [{
|
71
60
|
type: Directive,
|
72
61
|
args: [{
|
@@ -119,9 +108,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
119
108
|
type: HostListener,
|
120
109
|
args: ['durationchange']
|
121
110
|
}] } });
|
122
|
-
function nonNegativeFiniteAssertion(value) {
|
123
|
-
return Number.isFinite(value) && value >= 0;
|
124
|
-
}
|
125
111
|
|
126
112
|
class TuiMediaModule {
|
127
113
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"taiga-ui-cdk-directives-media.js","sources":["../../../projects/cdk/directives/media/media.directive.ts","../../../projects/cdk/directives/media/media.module.ts","../../../projects/cdk/directives/media/taiga-ui-cdk-directives-media.ts"],"sourcesContent":["import {\n Directive,\n ElementRef,\n EventEmitter,\n HostBinding,\n HostListener,\n Inject,\n Input,\n Output,\n} from '@angular/core';\
|
1
|
+
{"version":3,"file":"taiga-ui-cdk-directives-media.js","sources":["../../../projects/cdk/directives/media/media.directive.ts","../../../projects/cdk/directives/media/media.module.ts","../../../projects/cdk/directives/media/taiga-ui-cdk-directives-media.ts"],"sourcesContent":["import {\n Directive,\n ElementRef,\n EventEmitter,\n HostBinding,\n HostListener,\n Inject,\n Input,\n Output,\n} from '@angular/core';\n\n@Directive({\n selector: 'video[tuiMedia], audio[tuiMedia]',\n exportAs: 'tuiMedia',\n})\nexport class TuiMediaDirective {\n private playbackRate = 1;\n\n @Input()\n @HostBinding('volume')\n volume = 1;\n\n @Input('playbackRate')\n set playbackRateSetter(playbackRate: number) {\n this.updatePlaybackRate(playbackRate);\n }\n\n @Output()\n readonly currentTimeChange = new EventEmitter<number>();\n\n @Output()\n readonly pausedChange = new EventEmitter<boolean>();\n\n @Output()\n readonly volumeChange = new EventEmitter<number>();\n\n constructor(\n @Inject(ElementRef)\n private readonly el: ElementRef<HTMLMediaElement>,\n ) {}\n\n @Input()\n set currentTime(currentTime: number) {\n if (Math.abs(currentTime - this.currentTime) > 0.05) {\n this.el.nativeElement.currentTime = currentTime;\n }\n }\n\n get currentTime(): number {\n return this.el.nativeElement.currentTime;\n }\n\n @Input()\n set paused(paused: boolean) {\n if (paused) {\n this.el.nativeElement.pause();\n } else {\n // eslint-disable-next-line @typescript-eslint/no-floating-promises\n this.el.nativeElement.play();\n this.updatePlaybackRate(this.playbackRate);\n }\n }\n\n get paused(): boolean {\n return this.el.nativeElement.paused;\n }\n\n // @bad TODO: Make sure no other events can affect this like network issues etc.\n @HostListener('ended', ['true'])\n @HostListener('pause', ['true'])\n @HostListener('play', ['false'])\n onPausedChange(paused: boolean): void {\n this.pausedChange.emit(paused);\n this.updatePlaybackRate(this.playbackRate);\n }\n\n @HostListener('volumechange')\n onVolumeChange(): void {\n this.volume = this.el.nativeElement.volume;\n this.volumeChange.emit(this.volume);\n }\n\n @HostListener('timeupdate')\n @HostListener('seeking')\n @HostListener('seeked')\n onCurrentTimeChange(): void {\n this.currentTimeChange.emit(this.currentTime);\n }\n\n @HostListener('durationchange')\n changeDetectionTrigger(): void {\n // @bad TODO: consider if other events need to trigger CD\n }\n\n private updatePlaybackRate(playbackRate: number): void {\n this.playbackRate = playbackRate;\n this.el.nativeElement.playbackRate = this.playbackRate;\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiMediaDirective} from './media.directive';\n\n@NgModule({\n declarations: [TuiMediaDirective],\n exports: [TuiMediaDirective],\n})\nexport class TuiMediaModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAea,iBAAiB,CAAA;AAqB1B,IAAA,WAAA,CAEqB,EAAgC,EAAA;QAAhC,IAAE,CAAA,EAAA,GAAF,EAAE,CAA8B;QAtB7C,IAAY,CAAA,YAAA,GAAG,CAAC,CAAC;QAIzB,IAAM,CAAA,MAAA,GAAG,CAAC,CAAC;AAQF,QAAA,IAAA,CAAA,iBAAiB,GAAG,IAAI,YAAY,EAAU,CAAC;AAG/C,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAW,CAAC;AAG3C,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAU,CAAC;KAK/C;IAjBJ,IACI,kBAAkB,CAAC,YAAoB,EAAA;AACvC,QAAA,IAAI,CAAC,kBAAkB,CAAC,YAAY,CAAC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C;oBACjC,OAAO,EAAE,CAAC,iBAAiB,CAAC;AAC/B,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
|
@@ -1,7 +1,5 @@
|
|
1
|
-
import { __decorate } from 'tslib';
|
2
1
|
import * as i0 from '@angular/core';
|
3
2
|
import { Directive, Optional, Inject, Self, Input, Output, NgModule } from '@angular/core';
|
4
|
-
import { tuiRequiredSetter } from '@taiga-ui/cdk/decorators';
|
5
3
|
import * as i1 from '@taiga-ui/cdk/directives/active-zone';
|
6
4
|
import { TuiActiveZoneDirective } from '@taiga-ui/cdk/directives/active-zone';
|
7
5
|
import { tuiIfMap } from '@taiga-ui/cdk/observables';
|
@@ -28,9 +26,6 @@ class TuiObscuredDirective {
|
|
28
26
|
}
|
29
27
|
TuiObscuredDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiObscuredDirective, deps: [{ token: TuiActiveZoneDirective, optional: true }, { token: TuiObscuredService, self: true }], target: i0.ɵɵFactoryTarget.Directive });
|
30
28
|
TuiObscuredDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.17", type: TuiObscuredDirective, selector: "[tuiObscured]", inputs: { tuiObscuredEnabled: "tuiObscuredEnabled" }, outputs: { tuiObscured: "tuiObscured" }, providers: [TuiObscuredService, TuiParentsScrollService, TuiDestroyService], ngImport: i0 });
|
31
|
-
__decorate([
|
32
|
-
tuiRequiredSetter()
|
33
|
-
], TuiObscuredDirective.prototype, "tuiObscuredEnabled", null);
|
34
29
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiObscuredDirective, decorators: [{
|
35
30
|
type: Directive,
|
36
31
|
args: [{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"taiga-ui-cdk-directives-obscured.js","sources":["../../../projects/cdk/directives/obscured/obscured.directive.ts","../../../projects/cdk/directives/obscured/obscured.module.ts","../../../projects/cdk/directives/obscured/taiga-ui-cdk-directives-obscured.ts"],"sourcesContent":["import {Directive, Inject, Input, Optional, Output, Self} from '@angular/core';\nimport {
|
1
|
+
{"version":3,"file":"taiga-ui-cdk-directives-obscured.js","sources":["../../../projects/cdk/directives/obscured/obscured.directive.ts","../../../projects/cdk/directives/obscured/obscured.module.ts","../../../projects/cdk/directives/obscured/taiga-ui-cdk-directives-obscured.ts"],"sourcesContent":["import {Directive, Inject, Input, Optional, Output, Self} from '@angular/core';\nimport {TuiActiveZoneDirective} from '@taiga-ui/cdk/directives/active-zone';\nimport {tuiIfMap} from '@taiga-ui/cdk/observables';\nimport {\n TuiDestroyService,\n TuiObscuredService,\n TuiParentsScrollService,\n} from '@taiga-ui/cdk/services';\nimport {Observable, Subject} from 'rxjs';\nimport {map} from 'rxjs/operators';\n\n/**\n * Directive that monitors element visibility\n */\n@Directive({\n selector: '[tuiObscured]',\n providers: [TuiObscuredService, TuiParentsScrollService, TuiDestroyService],\n})\nexport class TuiObscuredDirective {\n private readonly enabled$ = new Subject<boolean>();\n\n @Input()\n set tuiObscuredEnabled(enabled: boolean) {\n this.enabled$.next(enabled);\n }\n\n @Output()\n readonly tuiObscured: Observable<boolean>;\n\n constructor(\n @Optional()\n @Inject(TuiActiveZoneDirective)\n activeZone: TuiActiveZoneDirective | null,\n @Self()\n @Inject(TuiObscuredService)\n obscured$: TuiObscuredService,\n ) {\n const mapped$ = obscured$.pipe(\n map(\n obscuredBy =>\n !!obscuredBy &&\n (!activeZone ||\n !obscuredBy.length ||\n obscuredBy.every(element => !activeZone.contains(element))),\n ),\n );\n\n this.tuiObscured = this.enabled$.pipe(tuiIfMap(() => mapped$));\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiObscuredDirective} from './obscured.directive';\n\n@NgModule({\n declarations: [TuiObscuredDirective],\n exports: [TuiObscuredDirective],\n})\nexport class TuiObscuredModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;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,EAAE,eAAe;AACzB,oBAAA,SAAS,EAAE,CAAC,kBAAkB,EAAE,uBAAuB,EAAE,iBAAiB,CAAC;AAC9E,iBAAA,CAAA;;0BAaQ,QAAQ;;0BACR,MAAM;2BAAC,sBAAsB,CAAA;;0BAE7B,IAAI;;0BACJ,MAAM;2BAAC,kBAAkB,CAAA;4CAZ1B,kBAAkB,EAAA,CAAA;sBADrB,KAAK;gBAMG,WAAW,EAAA,CAAA;sBADnB,MAAM;;;MClBE,iBAAiB,CAAA;;+GAAjB,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;gHAAjB,iBAAiB,EAAA,YAAA,EAAA,CAHX,oBAAoB,CAAA,EAAA,OAAA,EAAA,CACzB,oBAAoB,CAAA,EAAA,CAAA,CAAA;gHAErB,iBAAiB,EAAA,CAAA,CAAA;4FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;AAClC,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
|
@@ -1,7 +1,5 @@
|
|
1
|
-
import { __decorate } from 'tslib';
|
2
1
|
import * as i0 from '@angular/core';
|
3
2
|
import { ViewContainerRef, TemplateRef, Directive, Inject, Input, NgModule } from '@angular/core';
|
4
|
-
import { tuiRequiredSetter } from '@taiga-ui/cdk/decorators';
|
5
3
|
import { tuiClamp } from '@taiga-ui/cdk/utils/math';
|
6
4
|
|
7
5
|
const MAX_VALUE = 0x10000;
|
@@ -45,9 +43,6 @@ class TuiRepeatTimesDirective {
|
|
45
43
|
}
|
46
44
|
TuiRepeatTimesDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiRepeatTimesDirective, deps: [{ token: ViewContainerRef }, { token: TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
|
47
45
|
TuiRepeatTimesDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.17", type: TuiRepeatTimesDirective, selector: "[tuiRepeatTimes][tuiRepeatTimesOf]", inputs: { tuiRepeatTimesOf: "tuiRepeatTimesOf" }, ngImport: i0 });
|
48
|
-
__decorate([
|
49
|
-
tuiRequiredSetter()
|
50
|
-
], TuiRepeatTimesDirective.prototype, "tuiRepeatTimesOf", null);
|
51
46
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiRepeatTimesDirective, decorators: [{
|
52
47
|
type: Directive,
|
53
48
|
args: [{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"taiga-ui-cdk-directives-repeat-times.js","sources":["../../../projects/cdk/directives/repeat-times/repeat-times.directive.ts","../../../projects/cdk/directives/repeat-times/repeat-times.module.ts","../../../projects/cdk/directives/repeat-times/taiga-ui-cdk-directives-repeat-times.ts"],"sourcesContent":["import {Directive, Inject, Input, TemplateRef, ViewContainerRef} from '@angular/core';\nimport {
|
1
|
+
{"version":3,"file":"taiga-ui-cdk-directives-repeat-times.js","sources":["../../../projects/cdk/directives/repeat-times/repeat-times.directive.ts","../../../projects/cdk/directives/repeat-times/repeat-times.module.ts","../../../projects/cdk/directives/repeat-times/taiga-ui-cdk-directives-repeat-times.ts"],"sourcesContent":["import {Directive, Inject, Input, TemplateRef, ViewContainerRef} from '@angular/core';\nimport {TuiContextWithImplicit} from '@taiga-ui/cdk/interfaces';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\n\nconst MAX_VALUE = 0x10000;\n\nexport class TuiRepeatTimesContext implements TuiContextWithImplicit<number> {\n constructor(readonly $implicit: number) {}\n}\n\n/**\n * Directive similar to ngFor but using a number of repetitions rather than an array\n *\n * {@link TuiRepeatTimesDirective.tuiRepeatTimesOf requested number of times}.\n * {@link TuiRepeatTimesContext context} for every instance of the template inherits outer context and stores\n * {@link TuiRepeatTimesContext.$implicit index} of a template instance.\n */\n@Directive({\n selector: '[tuiRepeatTimes][tuiRepeatTimesOf]',\n})\nexport class TuiRepeatTimesDirective {\n @Input()\n set tuiRepeatTimesOf(count: number) {\n const safeCount = Math.floor(tuiClamp(count, 0, MAX_VALUE));\n\n const {length} = this.viewContainer;\n\n if (count < length) {\n this.removeContainers(length - count);\n } else {\n this.addContainers(safeCount);\n }\n }\n\n constructor(\n @Inject(ViewContainerRef)\n private readonly viewContainer: ViewContainerRef,\n @Inject(TemplateRef)\n private readonly templateRef: TemplateRef<TuiRepeatTimesContext>,\n ) {}\n\n private addContainers(count: number): void {\n for (let index = this.viewContainer.length; index < count; index++) {\n this.viewContainer.createEmbeddedView<TuiRepeatTimesContext>(\n this.templateRef,\n new TuiRepeatTimesContext(index),\n );\n }\n }\n\n private removeContainers(amount: number): void {\n for (let index = 0; index < amount; index++) {\n this.viewContainer.remove();\n }\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiRepeatTimesDirective} from './repeat-times.directive';\n\n@NgModule({\n declarations: [TuiRepeatTimesDirective],\n exports: [TuiRepeatTimesDirective],\n})\nexport class TuiRepeatTimesModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAIA,MAAM,SAAS,GAAG,OAAO,CAAC;MAEb,qBAAqB,CAAA;AAC9B,IAAA,WAAA,CAAqB,SAAiB,EAAA;QAAjB,IAAS,CAAA,SAAA,GAAT,SAAS,CAAQ;KAAI;AAC7C,CAAA;AAED;;;;;;AAMG;MAIU,uBAAuB,CAAA;IAchC,WAEqB,CAAA,aAA+B,EAE/B,WAA+C,EAAA;QAF/C,IAAa,CAAA,aAAA,GAAb,aAAa,CAAkB;QAE/B,IAAW,CAAA,WAAA,GAAX,WAAW,CAAoC;KAChE;IAlBJ,IACI,gBAAgB,CAAC,KAAa,EAAA;AAC9B,QAAA,MAAM,S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A,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,oCAAoC;AACjD,iBAAA,CAAA;;0BAgBQ,MAAM;2BAAC,gBAAgB,CAAA;;0BAEvB,MAAM;2BAAC,WAAW,CAAA;4CAfnB,gBAAgB,EAAA,CAAA;sBADnB,KAAK;;;MCbG,oBAAoB,CAAA;;kHAApB,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;mHAApB,oBAAoB,EAAA,YAAA,EAAA,CAHd,uBAAuB,CAAA,EAAA,OAAA,EAAA,CAC5B,uBAAuB,CAAA,EAAA,CAAA,CAAA;mHAExB,oBAAoB,EAAA,CAAA,CAAA;4FAApB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAJhC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,uBAAuB,CAAC;oBACvC,OAAO,EAAE,CAAC,uBAAuB,CAAC;AACrC,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
|
@@ -1,8 +1,6 @@
|
|
1
1
|
import * as i0 from '@angular/core';
|
2
2
|
import { Directive, EventEmitter, Inject, Input, Output, HostBinding, HostListener, NgModule } from '@angular/core';
|
3
3
|
import { TuiElementDirective } from '@taiga-ui/cdk/directives/element';
|
4
|
-
import { __decorate } from 'tslib';
|
5
|
-
import { tuiDefaultProp } from '@taiga-ui/cdk/decorators';
|
6
4
|
import { tuiPx } from '@taiga-ui/cdk/utils/format';
|
7
5
|
|
8
6
|
class TuiResizeableDirective extends TuiElementDirective {
|
@@ -82,9 +80,6 @@ class TuiResizerDirective {
|
|
82
80
|
}
|
83
81
|
TuiResizerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiResizerDirective, deps: [{ token: TuiResizeableDirective }], target: i0.ɵɵFactoryTarget.Directive });
|
84
82
|
TuiResizerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.17", type: TuiResizerDirective, selector: "[tuiResizer]", inputs: { tuiResizer: "tuiResizer" }, outputs: { tuiSizeChange: "tuiSizeChange" }, host: { listeners: { "touchstart.silent.passive": "onTouchStart($event)", "mousedown.silent.prevent": "onMouseDown($event.x,$event.y)", "document:mousemove.silent": "onMouseMove($event)", "document:touchmove.silent": "onTouchMove($event)", "document:mouseup.silent": "onMouseUp()", "document:touchend.silent": "onMouseUp()" }, properties: { "style.touchAction": "\"none\"", "style.cursor": "this.cursor" } }, ngImport: i0 });
|
85
|
-
__decorate([
|
86
|
-
tuiDefaultProp()
|
87
|
-
], TuiResizerDirective.prototype, "tuiResizer", void 0);
|
88
83
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiResizerDirective, decorators: [{
|
89
84
|
type: Directive,
|
90
85
|
args: [{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"taiga-ui-cdk-directives-resizer.js","sources":["../../../projects/cdk/directives/resizer/resizeable.directive.ts","../../../projects/cdk/directives/resizer/resizer.directive.ts","../../../projects/cdk/directives/resizer/resizer.module.ts","../../../projects/cdk/directives/resizer/taiga-ui-cdk-directives-resizer.ts"],"sourcesContent":["import {Directive} from '@angular/core';\nimport {TuiElementDirective} from '@taiga-ui/cdk/directives/element';\n\n@Directive({\n selector: '[tuiResizeable]',\n})\nexport class TuiResizeableDirective extends TuiElementDirective {}\n","import {\n Directive,\n ElementRef,\n EventEmitter,\n HostBinding,\n HostListener,\n Inject,\n Input,\n Output,\n} from '@angular/core';\nimport {
|
1
|
+
{"version":3,"file":"taiga-ui-cdk-directives-resizer.js","sources":["../../../projects/cdk/directives/resizer/resizeable.directive.ts","../../../projects/cdk/directives/resizer/resizer.directive.ts","../../../projects/cdk/directives/resizer/resizer.module.ts","../../../projects/cdk/directives/resizer/taiga-ui-cdk-directives-resizer.ts"],"sourcesContent":["import {Directive} from '@angular/core';\nimport {TuiElementDirective} from '@taiga-ui/cdk/directives/element';\n\n@Directive({\n selector: '[tuiResizeable]',\n})\nexport class TuiResizeableDirective extends TuiElementDirective {}\n","import {\n Directive,\n ElementRef,\n EventEmitter,\n HostBinding,\n HostListener,\n Inject,\n Input,\n Output,\n} from '@angular/core';\nimport {tuiPx} from '@taiga-ui/cdk/utils/format';\n\nimport {TuiResizeableDirective} from './resizeable.directive';\n\n// TODO: Migrate to PointerEvent in 4.0\n@Directive({\n selector: '[tuiResizer]',\n host: {'[style.touchAction]': '\"none\"'},\n})\nexport class TuiResizerDirective {\n @Input()\n tuiResizer: readonly [x: number, y: number] = [0, 0];\n\n @Output()\n readonly tuiSizeChange = new EventEmitter<readonly [x: number, y: number]>();\n\n x = NaN;\n y = NaN;\n width = 0;\n height = 0;\n\n constructor(\n @Inject(TuiResizeableDirective)\n private readonly resizeable: ElementRef<HTMLElement>,\n ) {}\n\n @HostBinding('style.cursor')\n get cursor(): string {\n if (!this.tuiResizer[0]) {\n return 'ns-resize';\n }\n\n if (!this.tuiResizer[1]) {\n return 'ew-resize';\n }\n\n if (this.tuiResizer[0] * this.tuiResizer[1] > 0) {\n return 'nwse-resize';\n }\n\n return 'nesw-resize';\n }\n\n @HostListener('touchstart.silent.passive', ['$event'])\n onTouchStart({touches}: TouchEvent): void {\n this.onMouseDown(touches[0].clientX, touches[0].clientY);\n }\n\n @HostListener('mousedown.silent.prevent', ['$event.x', '$event.y'])\n onMouseDown(x: number, y: number): void {\n this.x = x;\n this.y = y;\n this.width = this.resizeable.nativeElement.clientWidth;\n this.height = this.resizeable.nativeElement.clientHeight;\n }\n\n @HostListener('document:mousemove.silent', ['$event'])\n onMouseMove({x, y, buttons}: MouseEvent): void {\n if (!buttons) {\n this.onMouseUp();\n } else {\n this.onMove(x, y);\n }\n }\n\n @HostListener('document:touchmove.silent', ['$event'])\n onTouchMove({touches}: TouchEvent): void {\n this.onMove(touches[0].clientX, touches[0].clientY);\n }\n\n @HostListener('document:mouseup.silent')\n @HostListener('document:touchend.silent')\n onMouseUp(): void {\n this.x = NaN;\n }\n\n onMove(x: number, y: number): void {\n if (Number.isNaN(this.x)) {\n return;\n }\n\n const {style} = this.resizeable.nativeElement;\n const size = [\n this.width + this.tuiResizer[0] * (x - this.x),\n this.height + this.tuiResizer[1] * (y - this.y),\n ] as const;\n\n if (this.tuiResizer[0]) {\n style.width = tuiPx(size[0]);\n }\n\n if (this.tuiResizer[1]) {\n style.height = tuiPx(size[1]);\n }\n\n this.tuiSizeChange.emit(size);\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiResizeableDirective} from './resizeable.directive';\nimport {TuiResizerDirective} from './resizer.directive';\n\n@NgModule({\n declarations: [TuiResizeableDirective, TuiResizerDirective],\n exports: [TuiResizeableDirective, TuiResizerDirective],\n})\nexport class TuiResizerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAMM,MAAO,sBAAuB,SAAQ,mBAAmB,CAAA;;oHAAlD,sBAAsB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;wGAAtB,sBAAsB,EAAA,QAAA,EAAA,iBAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;4FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAHlC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,iBAAiB;AAC9B,iBAAA,CAAA;;;ACSD;MAKa,mBAAmB,CAAA;AAY5B,IAAA,WAAA,CAEqB,UAAmC,EAAA;QAAnC,IAAU,CAAA,UAAA,GAAV,UAAU,CAAyB;AAZxD,QAAA,IAAA,CAAA,UAAU,GAAoC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAG5C,QAAA,IAAA,CAAA,aAAa,GAAG,IAAI,YAAY,EAAm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AU,CAAC,CAAA;gBASlE,WAAW,EAAA,CAAA;sBADV,YAAY;uBAAC,2BAA2B,EAAE,CAAC,QAAQ,CAAC,CAAA;gBAUrD,WAAW,EAAA,CAAA;sBADV,YAAY;uBAAC,2BAA2B,EAAE,CAAC,QAAQ,CAAC,CAAA;gBAOrD,SAAS,EAAA,CAAA;sBAFR,YAAY;uBAAC,yBAAyB,CAAA;;sBACtC,YAAY;uBAAC,0BAA0B,CAAA;;;MCxE/B,gBAAgB,CAAA;;8GAAhB,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAhB,gBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,gBAAgB,iBAHV,sBAAsB,EAAE,mBAAmB,CAChD,EAAA,OAAA,EAAA,CAAA,sBAAsB,EAAE,mBAAmB,CAAA,EAAA,CAAA,CAAA;+GAE5C,gBAAgB,EAAA,CAAA,CAAA;4FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,YAAY,EAAE,CAAC,sBAAsB,EAAE,mBAAmB,CAAC;AAC3D,oBAAA,OAAO,EAAE,CAAC,sBAAsB,EAAE,mBAAmB,CAAC;AACzD,iBAAA,CAAA;;;ACRD;;AAEG;;;;"}
|
@@ -1,9 +1,7 @@
|
|
1
|
-
import { __decorate } from 'tslib';
|
2
1
|
import * as i0 from '@angular/core';
|
3
2
|
import { forwardRef, Directive, Input, NgModule } from '@angular/core';
|
4
3
|
import { Validators, NG_VALIDATORS } from '@angular/forms';
|
5
4
|
import { EMPTY_FUNCTION } from '@taiga-ui/cdk/constants';
|
6
|
-
import { tuiDefaultProp } from '@taiga-ui/cdk/decorators';
|
7
5
|
|
8
6
|
class TuiValidatorDirective {
|
9
7
|
constructor() {
|
@@ -32,9 +30,6 @@ TuiValidatorDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0",
|
|
32
30
|
multi: true,
|
33
31
|
},
|
34
32
|
], usesOnChanges: true, ngImport: i0 });
|
35
|
-
__decorate([
|
36
|
-
tuiDefaultProp()
|
37
|
-
], TuiValidatorDirective.prototype, "tuiValidator", void 0);
|
38
33
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiValidatorDirective, decorators: [{
|
39
34
|
type: Directive,
|
40
35
|
args: [{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"taiga-ui-cdk-directives-validator.js","sources":["../../../projects/cdk/directives/validator/validator.directive.ts","../../../projects/cdk/directives/validator/validator.module.ts","../../../projects/cdk/directives/validator/taiga-ui-cdk-directives-validator.ts"],"sourcesContent":["import {Directive, forwardRef, Input, OnChanges, OnDestroy} from '@angular/core';\nimport {\n AbstractControl,\n NG_VALIDATORS,\n ValidationErrors,\n Validator,\n ValidatorFn,\n Validators,\n} from '@angular/forms';\nimport {EMPTY_FUNCTION} from '@taiga-ui/cdk/constants';\
|
1
|
+
{"version":3,"file":"taiga-ui-cdk-directives-validator.js","sources":["../../../projects/cdk/directives/validator/validator.directive.ts","../../../projects/cdk/directives/validator/validator.module.ts","../../../projects/cdk/directives/validator/taiga-ui-cdk-directives-validator.ts"],"sourcesContent":["import {Directive, forwardRef, Input, OnChanges, OnDestroy} from '@angular/core';\nimport {\n AbstractControl,\n NG_VALIDATORS,\n ValidationErrors,\n Validator,\n ValidatorFn,\n Validators,\n} from '@angular/forms';\nimport {EMPTY_FUNCTION} from '@taiga-ui/cdk/constants';\n\n@Directive({\n selector: '[tuiValidator]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => TuiValidatorDirective),\n multi: true,\n },\n ],\n})\nexport class TuiValidatorDirective implements Validator, OnChanges, OnDestroy {\n private onChange = EMPTY_FUNCTION;\n\n @Input()\n tuiValidator: ValidatorFn = Validators.nullValidator;\n\n validate(control: AbstractControl): ValidationErrors | null {\n return this.tuiValidator(control);\n }\n\n registerOnValidatorChange(onChange: (...args: any[]) => void): void {\n this.onChange = onChange;\n }\n\n ngOnChanges(): void {\n this.onChange();\n }\n\n ngOnDestroy(): void {\n this.tuiValidator = Validators.nullValidator;\n this.onChange();\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiValidatorDirective} from './validator.directive';\n\n@NgModule({\n declarations: [TuiValidatorDirective],\n exports: [TuiValidatorDirective],\n})\nexport class TuiValidatorModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;MAqBa,qBAAqB,CAAA;AAVlC,IAAA,WAAA,GAAA;QAWY,IAAQ,CAAA,QAAA,GAAG,cAAc,CAAC;AAGlC,QAAA,IAAA,CAAA,YAAY,GAAgB,UAAU,CAAC,aAAa,CAAC;AAkBxD,KAAA;AAhBG,IAAA,QAAQ,CAAC,OAAwB,EAAA;AAC7B,QAAA,OAAO,IAAI,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;KACrC;AAED,IAAA,yBAAyB,CAAC,QAAkC,EAAA;AACxD,QAAA,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;KAC5B;IAED,WAAW,GAAA;QACP,IAAI,CAAC,QAAQ,EAAE,CAAC;KACnB;IAED,WAAW,GAAA;AACP,QAAA,IAAI,CAAC,YAAY,GAAG,UAAU,CAAC,aAAa,CAAC;QAC7C,IAAI,CAAC,QAAQ,EAAE,CAAC;KACnB;;mHArBQ,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAArB,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAA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
|
2
2
|
"name": "@taiga-ui/cdk",
|
3
|
-
"version": "3.33.1-dev.main-
|
3
|
+
"version": "3.33.1-dev.main-1fa4789",
|
4
4
|
"description": "Base library for creating Angular components and applications using Taiga UI principles regarding of actual visual appearance",
|
5
5
|
"keywords": [
|
6
6
|
"angular",
|
@@ -30,7 +30,7 @@
|
|
30
30
|
"rxjs": ">=6.0.0"
|
31
31
|
},
|
32
32
|
"optionalDependencies": {
|
33
|
-
"ng-morph": "2.2.
|
33
|
+
"ng-morph": "2.2.5",
|
34
34
|
"parse5": "6.0.1"
|
35
35
|
},
|
36
36
|
"ng-update": {
|