@taiga-ui/addon-mobile 3.54.0 → 3.55.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/bundles/taiga-ui-addon-mobile-components-app-bar.umd.js +1 -1
- package/bundles/taiga-ui-addon-mobile-components-app-bar.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-mobile-components-mobile-calendar.umd.js +36 -20
- package/bundles/taiga-ui-addon-mobile-components-mobile-calendar.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-mobile-components-sheet-dialog.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-mobile-components-sheet.umd.js +7 -7
- package/bundles/taiga-ui-addon-mobile-components-sheet.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-mobile-components-tab-bar.umd.js +1 -1
- package/bundles/taiga-ui-addon-mobile-const.umd.js.map +1 -1
- package/components/mobile-calendar/mobile-calendar.component.d.ts +4 -3
- package/components/sheet-dialog/sheet-dialog.options.d.ts +1 -1
- package/esm2015/components/app-bar/app-bar-back.component.js +1 -1
- package/esm2015/components/mobile-calendar/mobile-calendar.component.js +15 -11
- package/esm2015/components/mobile-calendar/mobile-calendar.const.js +24 -12
- package/esm2015/components/sheet/components/sheet-bar/sheet-bar.component.js +2 -2
- package/esm2015/components/sheet/directives/sheet-wrapper/sheet-wrapper.directive.js +7 -7
- package/esm2015/components/sheet-dialog/sheet-dialog.options.js +1 -1
- package/esm2015/components/tab-bar/tab-bar-item.component.js +1 -1
- package/esm2015/const/mobile-alert-options.js +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-app-bar.js +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-app-bar.js.map +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-mobile-calendar.js +37 -21
- package/fesm2015/taiga-ui-addon-mobile-components-mobile-calendar.js.map +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-sheet-dialog.js.map +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-sheet.js +7 -7
- package/fesm2015/taiga-ui-addon-mobile-components-sheet.js.map +1 -1
- package/fesm2015/taiga-ui-addon-mobile-components-tab-bar.js +1 -1
- package/fesm2015/taiga-ui-addon-mobile-const.js.map +1 -1
- package/package.json +4 -4
- package/styles/android/toggle.less +64 -0
- package/styles/ios/toggle.less +50 -0
- package/styles/taiga-ui-mobile.less +9 -0
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
return TuiAppBarBackComponent;
|
|
106
106
|
}());
|
|
107
107
|
TuiAppBarBackComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiAppBarBackComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
108
|
-
TuiAppBarBackComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TuiAppBarBackComponent, selector: "button[tuiAppBarBack], a[tuiAppBarBack]", ngImport: i0__namespace, template: "<svg\n height=\"24\"\n viewBox=\"0 0 24 24\"\n width=\"24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n>\n <path\n d=\"M7.44025 12L14.9826 4.43872C15.5391 3.88083 15.5391 2.97631 14.9826 2.41842C14.4261 1.86053 13.5239 1.86053 12.9674 2.41842L4.41737 10.9898C3.86088 11.5477 3.86088 12.4523 4.41737 13.0102L12.9674 21.5816C13.5239 22.1395 14.4261 22.1395 14.9826 21.5816C15.5391 21.0237 15.5391 20.1192 14.9826 19.5613L7.44025 12Z\"\n fill=\"currentColor\"\n />\n</svg>\n<ng-content></ng-content>\n", styles: [":host{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:0;background:none;font-size:inherit;line-height:inherit;display:flex;align-items:center;padding:0 .625rem 0 .125rem}\n"], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
108
|
+
TuiAppBarBackComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TuiAppBarBackComponent, selector: "button[tuiAppBarBack], a[tuiAppBarBack]", ngImport: i0__namespace, template: "<svg\n height=\"24\"\n viewBox=\"0 0 24 24\"\n width=\"24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n>\n <path\n d=\"M7.44025 12L14.9826 4.43872C15.5391 3.88083 15.5391 2.97631 14.9826 2.41842C14.4261 1.86053 13.5239 1.86053 12.9674 2.41842L4.41737 10.9898C3.86088 11.5477 3.86088 12.4523 4.41737 13.0102L12.9674 21.5816C13.5239 22.1395 14.4261 22.1395 14.9826 21.5816C15.5391 21.0237 15.5391 20.1192 14.9826 19.5613L7.44025 12Z\"\n fill=\"currentColor\"\n />\n</svg>\n<ng-content></ng-content>\n", styles: [":host{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:0;background:none;font-size:inherit;line-height:inherit;text-decoration:none;display:flex;align-items:center;padding:0 .625rem 0 .125rem}\n"], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
109
109
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiAppBarBackComponent, decorators: [{
|
|
110
110
|
type: i0.Component,
|
|
111
111
|
args: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-addon-mobile-components-app-bar.umd.js","sources":["../../../projects/addon-mobile/components/app-bar/app-bar.providers.ts","../../../projects/addon-mobile/components/app-bar/app-bar.component.ts","../../../projects/addon-mobile/components/app-bar/app-bar.template.html","../../../projects/addon-mobile/components/app-bar/app-bar.directive.ts","../../../projects/addon-mobile/components/app-bar/app-bar-back.component.ts","../../../projects/addon-mobile/components/app-bar/app-bar-back.template.html","../../../projects/addon-mobile/components/app-bar/app-bar.module.ts","../../../projects/addon-mobile/components/app-bar/taiga-ui-addon-mobile-components-app-bar.ts"],"sourcesContent":["import {Provider} from '@angular/core';\nimport {\n MUTATION_OBSERVER_INIT,\n MutationObserverService,\n} from '@ng-web-apis/mutation-observer';\nimport {TuiDestroyService, TuiResizeService} from '@taiga-ui/cdk';\nimport {tuiButtonOptionsProvider} from '@taiga-ui/core';\n\nexport const TUI_APP_BAR_PROVIDERS: Provider[] = [\n TuiDestroyService,\n TuiResizeService,\n MutationObserverService,\n {\n provide: MUTATION_OBSERVER_INIT,\n useValue: {\n characterData: true,\n childList: true,\n subtree: true,\n },\n },\n tuiButtonOptionsProvider({\n size: `m`,\n appearance: ``,\n }),\n];\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Inject,\n QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {MutationObserverService} from '@ng-web-apis/mutation-observer';\nimport {EMPTY_QUERY, TuiResizeService} from '@taiga-ui/cdk';\nimport {merge, Observable} from 'rxjs';\nimport {map} from 'rxjs/operators';\n\nimport {TUI_APP_BAR_PROVIDERS} from './app-bar.providers';\n\n@Component({\n selector: 'tui-app-bar',\n templateUrl: './app-bar.template.html',\n styleUrls: ['./app-bar.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: TUI_APP_BAR_PROVIDERS,\n})\nexport class TuiAppBarComponent {\n @ViewChildren('side')\n private readonly side: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n readonly width$ = merge(this.resize$, this.mutation$).pipe(\n map(\n () =>\n 2 *\n Math.max(\n this.side.first?.nativeElement.clientWidth,\n this.side.last?.nativeElement.clientWidth,\n ),\n ),\n );\n\n constructor(\n @Inject(TuiResizeService) private readonly resize$: Observable<unknown>,\n @Inject(MutationObserverService) private readonly mutation$: Observable<unknown>,\n ) {}\n}\n","<div\n #side\n class=\"t-left\"\n>\n <ng-content select=\"[tuiSlot='left']\"></ng-content>\n</div>\n<div\n class=\"t-content\"\n [style.--sides.px]=\"width$ | async\"\n>\n <ng-content></ng-content>\n</div>\n<div\n #side\n class=\"t-right\"\n>\n <ng-content select=\"[tuiSlot='right']\"></ng-content>\n</div>\n","import {Directive, Input} from '@angular/core';\n\n@Directive({\n selector: '[tuiSlot]',\n})\nexport class TuiAppBarDirective {\n @Input()\n tuiSlot: string | 'left' | 'right' = 'left';\n}\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\n\n@Component({\n selector: 'button[tuiAppBarBack], a[tuiAppBarBack]',\n templateUrl: './app-bar-back.template.html',\n styleUrls: ['./app-bar-back.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiAppBarBackComponent {}\n","<svg\n height=\"24\"\n viewBox=\"0 0 24 24\"\n width=\"24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n>\n <path\n d=\"M7.44025 12L14.9826 4.43872C15.5391 3.88083 15.5391 2.97631 14.9826 2.41842C14.4261 1.86053 13.5239 1.86053 12.9674 2.41842L4.41737 10.9898C3.86088 11.5477 3.86088 12.4523 4.41737 13.0102L12.9674 21.5816C13.5239 22.1395 14.4261 22.1395 14.9826 21.5816C15.5391 21.0237 15.5391 20.1192 14.9826 19.5613L7.44025 12Z\"\n fill=\"currentColor\"\n />\n</svg>\n<ng-content></ng-content>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {TuiSvgModule} from '@taiga-ui/core';\n\nimport {TuiAppBarComponent} from './app-bar.component';\nimport {TuiAppBarDirective} from './app-bar.directive';\nimport {TuiAppBarBackComponent} from './app-bar-back.component';\n\n@NgModule({\n imports: [CommonModule, TuiSvgModule],\n declarations: [TuiAppBarComponent, TuiAppBarDirective, TuiAppBarBackComponent],\n exports: [TuiAppBarComponent, TuiAppBarDirective, TuiAppBarBackComponent],\n})\nexport class TuiAppBarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["TuiDestroyService","TuiResizeService","MutationObserverService","MUTATION_OBSERVER_INIT","tuiButtonOptionsProvider","EMPTY_QUERY","merge","map","i0","i1","Component","ChangeDetectionStrategy","Inject","ViewChildren","Directive","Input","CommonModule","TuiSvgModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAQ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AA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,QAAA,EAAAA,aAAA,EAAA,CAAA,CAAA;sHAAlB,kBAAkB,EAAA,UAAA,EAAA,CAAA;sBAH9BM,YAAS;IAAC,YAAA,IAAA,EAAA,CAAA;IACP,oBAAA,QAAQ,EAAE,WAAW;qBACxB,CAAA;kCAGG,OAAO,EAAA,CAAA;0BADNC,QAAK;;;ACEV,QAAA,sBAAA,kBAAA,YAAA;IAAA,IAAA,SAAA,sBAAA,GAAA;;;;8IAAa,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAAP,aAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;IAAtB,sBAAA,CAAA,IAAA,GAAAA,aAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,sBAAsB,0FCRnC,ihBAYA,EAAA,MAAA,EAAA,CAAA,
|
|
1
|
+
{"version":3,"file":"taiga-ui-addon-mobile-components-app-bar.umd.js","sources":["../../../projects/addon-mobile/components/app-bar/app-bar.providers.ts","../../../projects/addon-mobile/components/app-bar/app-bar.component.ts","../../../projects/addon-mobile/components/app-bar/app-bar.template.html","../../../projects/addon-mobile/components/app-bar/app-bar.directive.ts","../../../projects/addon-mobile/components/app-bar/app-bar-back.component.ts","../../../projects/addon-mobile/components/app-bar/app-bar-back.template.html","../../../projects/addon-mobile/components/app-bar/app-bar.module.ts","../../../projects/addon-mobile/components/app-bar/taiga-ui-addon-mobile-components-app-bar.ts"],"sourcesContent":["import {Provider} from '@angular/core';\nimport {\n MUTATION_OBSERVER_INIT,\n MutationObserverService,\n} from '@ng-web-apis/mutation-observer';\nimport {TuiDestroyService, TuiResizeService} from '@taiga-ui/cdk';\nimport {tuiButtonOptionsProvider} from '@taiga-ui/core';\n\nexport const TUI_APP_BAR_PROVIDERS: Provider[] = [\n TuiDestroyService,\n TuiResizeService,\n MutationObserverService,\n {\n provide: MUTATION_OBSERVER_INIT,\n useValue: {\n characterData: true,\n childList: true,\n subtree: true,\n },\n },\n tuiButtonOptionsProvider({\n size: `m`,\n appearance: ``,\n }),\n];\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Inject,\n QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {MutationObserverService} from '@ng-web-apis/mutation-observer';\nimport {EMPTY_QUERY, TuiResizeService} from '@taiga-ui/cdk';\nimport {merge, Observable} from 'rxjs';\nimport {map} from 'rxjs/operators';\n\nimport {TUI_APP_BAR_PROVIDERS} from './app-bar.providers';\n\n@Component({\n selector: 'tui-app-bar',\n templateUrl: './app-bar.template.html',\n styleUrls: ['./app-bar.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: TUI_APP_BAR_PROVIDERS,\n})\nexport class TuiAppBarComponent {\n @ViewChildren('side')\n private readonly side: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n readonly width$ = merge(this.resize$, this.mutation$).pipe(\n map(\n () =>\n 2 *\n Math.max(\n this.side.first?.nativeElement.clientWidth,\n this.side.last?.nativeElement.clientWidth,\n ),\n ),\n );\n\n constructor(\n @Inject(TuiResizeService) private readonly resize$: Observable<unknown>,\n @Inject(MutationObserverService) private readonly mutation$: Observable<unknown>,\n ) {}\n}\n","<div\n #side\n class=\"t-left\"\n>\n <ng-content select=\"[tuiSlot='left']\"></ng-content>\n</div>\n<div\n class=\"t-content\"\n [style.--sides.px]=\"width$ | async\"\n>\n <ng-content></ng-content>\n</div>\n<div\n #side\n class=\"t-right\"\n>\n <ng-content select=\"[tuiSlot='right']\"></ng-content>\n</div>\n","import {Directive, Input} from '@angular/core';\n\n@Directive({\n selector: '[tuiSlot]',\n})\nexport class TuiAppBarDirective {\n @Input()\n tuiSlot: string | 'left' | 'right' = 'left';\n}\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\n\n@Component({\n selector: 'button[tuiAppBarBack], a[tuiAppBarBack]',\n templateUrl: './app-bar-back.template.html',\n styleUrls: ['./app-bar-back.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiAppBarBackComponent {}\n","<svg\n height=\"24\"\n viewBox=\"0 0 24 24\"\n width=\"24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n>\n <path\n d=\"M7.44025 12L14.9826 4.43872C15.5391 3.88083 15.5391 2.97631 14.9826 2.41842C14.4261 1.86053 13.5239 1.86053 12.9674 2.41842L4.41737 10.9898C3.86088 11.5477 3.86088 12.4523 4.41737 13.0102L12.9674 21.5816C13.5239 22.1395 14.4261 22.1395 14.9826 21.5816C15.5391 21.0237 15.5391 20.1192 14.9826 19.5613L7.44025 12Z\"\n fill=\"currentColor\"\n />\n</svg>\n<ng-content></ng-content>\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {TuiSvgModule} from '@taiga-ui/core';\n\nimport {TuiAppBarComponent} from './app-bar.component';\nimport {TuiAppBarDirective} from './app-bar.directive';\nimport {TuiAppBarBackComponent} from './app-bar-back.component';\n\n@NgModule({\n imports: [CommonModule, TuiSvgModule],\n declarations: [TuiAppBarComponent, TuiAppBarDirective, TuiAppBarBackComponent],\n exports: [TuiAppBarComponent, TuiAppBarDirective, TuiAppBarBackComponent],\n})\nexport class TuiAppBarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["TuiDestroyService","TuiResizeService","MutationObserverService","MUTATION_OBSERVER_INIT","tuiButtonOptionsProvider","EMPTY_QUERY","merge","map","i0","i1","Component","ChangeDetectionStrategy","Inject","ViewChildren","Directive","Input","CommonModule","TuiSvgModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAQa,QAAA,qBAAqB,GAAe;QAC7CA,qBAAiB;QACjBC,oBAAgB;QAChBC,wCAAuB;IACvB,IAAA;IACI,QAAA,OAAO,EAAEC,uCAAsB;IAC/B,QAAA,QAAQ,EAAE;IACN,YAAA,aAAa,EAAE,IAA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AA,kBAAkB,EAAE,kBAAkB,EAAE,sBAAsB,CAAA,EAAA,CAAA,CAAA;IAE/D,eAAA,CAAA,IAAA,GAAAT,aAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAAA,aAAA,EAAA,IAAA,EAAA,eAAe,EAJf,OAAA,EAAA,CAAA,CAACQ,eAAY,EAAEC,iBAAY,CAAC,CAAA,EAAA,CAAA,CAAA;sHAI5B,eAAe,EAAA,UAAA,EAAA,CAAA;sBAL3BC,WAAQ;IAAC,YAAA,IAAA,EAAA,CAAA;IACN,oBAAA,OAAO,EAAE,CAACF,eAAY,EAAEC,iBAAY,CAAC;IACrC,oBAAA,YAAY,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,EAAE,sBAAsB,CAAC;IAC9E,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,kBAAkB,EAAE,sBAAsB,CAAC;qBAC5E,CAAA;;;ICZD;;IAEG;;;;;;;;;;;;;;"}
|
|
@@ -32,6 +32,17 @@
|
|
|
32
32
|
var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
|
|
33
33
|
var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
|
|
34
34
|
|
|
35
|
+
function getCycle(options) {
|
|
36
|
+
return Array.from({ length: options.yearCycle }, function (_, i) { return Array.from({ length: i7.MONTHS_IN_YEAR }, function (_, month) { return options.label +
|
|
37
|
+
weekCount({ year: i, month: month, startingYear: options.startingYear }) *
|
|
38
|
+
options.week; }); });
|
|
39
|
+
}
|
|
40
|
+
function weekCount(options) {
|
|
41
|
+
var firstOfMonth = new Date(options.year + options.startingYear, options.month, 1);
|
|
42
|
+
var lastOfMonth = new Date(options.year + options.startingYear, options.month + 1, 0);
|
|
43
|
+
var days = lastOfMonth.getDate() + (firstOfMonth.getDay() || 7) - 1;
|
|
44
|
+
return Math.ceil(days / 7);
|
|
45
|
+
}
|
|
35
46
|
var SCROLL_DEBOUNCE_TIME = 80;
|
|
36
47
|
var YEARS_IN_ROW = 5;
|
|
37
48
|
var STARTING_YEAR = 1900;
|
|
@@ -42,17 +53,18 @@
|
|
|
42
53
|
var IOS_LABEL = 50;
|
|
43
54
|
var IOS_WEEK = 50;
|
|
44
55
|
var YEARLY_CYCLE = 28;
|
|
45
|
-
var ANDROID_CYCLE = getCycle(
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
+
var ANDROID_CYCLE = getCycle({
|
|
57
|
+
label: ANDROID_LABEL,
|
|
58
|
+
week: ANDROID_WEEK,
|
|
59
|
+
yearCycle: YEARLY_CYCLE,
|
|
60
|
+
startingYear: STARTING_YEAR,
|
|
61
|
+
});
|
|
62
|
+
var IOS_CYCLE = getCycle({
|
|
63
|
+
label: IOS_LABEL,
|
|
64
|
+
week: IOS_WEEK,
|
|
65
|
+
yearCycle: YEARLY_CYCLE,
|
|
66
|
+
startingYear: STARTING_YEAR,
|
|
67
|
+
});
|
|
56
68
|
|
|
57
69
|
/*! *****************************************************************************
|
|
58
70
|
Copyright (c) Microsoft Corporation.
|
|
@@ -524,7 +536,7 @@
|
|
|
524
536
|
];
|
|
525
537
|
|
|
526
538
|
var TuiMobileCalendarComponent = /** @class */ (function () {
|
|
527
|
-
function TuiMobileCalendarComponent(isIOS, isE2E, doc, destroy$, valueChanges, icons, closeWord$, cancelWord$, doneWord$, unorderedWeekDays$, chooseDayOrRangeTexts$, duration) {
|
|
539
|
+
function TuiMobileCalendarComponent(isIOS, isE2E, doc, destroy$, valueChanges, icons, closeWord$, cancelWord$, doneWord$, unorderedWeekDays$, chooseDayOrRangeTexts$, duration, ngZone) {
|
|
528
540
|
var _this = this;
|
|
529
541
|
this.isIOS = isIOS;
|
|
530
542
|
this.isE2E = isE2E;
|
|
@@ -537,6 +549,7 @@
|
|
|
537
549
|
this.unorderedWeekDays$ = unorderedWeekDays$;
|
|
538
550
|
this.chooseDayOrRangeTexts$ = chooseDayOrRangeTexts$;
|
|
539
551
|
this.duration = duration;
|
|
552
|
+
this.ngZone = ngZone;
|
|
540
553
|
this.today = i7.TuiDay.currentLocal();
|
|
541
554
|
this.activeYear = 0;
|
|
542
555
|
this.activeMonth = 0;
|
|
@@ -626,9 +639,9 @@
|
|
|
626
639
|
this.activeMonth += this.getMonthOffset(year);
|
|
627
640
|
this.activeYear = year;
|
|
628
641
|
this.scrollToActiveYear('smooth');
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
_this.scrollToActiveMonth();
|
|
642
|
+
this.ngZone.runOutsideAngular(function () {
|
|
643
|
+
// Delay is required to run months scroll in the next frame to prevent flicker
|
|
644
|
+
setTimeout(function () { return _this.scrollToActiveMonth(); });
|
|
632
645
|
});
|
|
633
646
|
};
|
|
634
647
|
Object.defineProperty(TuiMobileCalendarComponent.prototype, "initialYear", {
|
|
@@ -698,8 +711,8 @@
|
|
|
698
711
|
if (!yearsScrollRef) {
|
|
699
712
|
return;
|
|
700
713
|
}
|
|
701
|
-
var touchstart$ = i7.tuiTypedFromEvent(yearsScrollRef.elementRef.nativeElement, 'touchstart');
|
|
702
|
-
var touchend$ = i7.tuiTypedFromEvent(yearsScrollRef.elementRef.nativeElement, 'touchend');
|
|
714
|
+
var touchstart$ = i7.tuiTypedFromEvent(yearsScrollRef.elementRef.nativeElement, 'touchstart', { passive: true });
|
|
715
|
+
var touchend$ = i7.tuiTypedFromEvent(yearsScrollRef.elementRef.nativeElement, 'touchend', { passive: true });
|
|
703
716
|
var click$ = i7.tuiTypedFromEvent(yearsScrollRef.elementRef.nativeElement, 'click');
|
|
704
717
|
// Refresh activeYear
|
|
705
718
|
yearsScrollRef
|
|
@@ -728,7 +741,7 @@
|
|
|
728
741
|
return;
|
|
729
742
|
}
|
|
730
743
|
var touchstart$ = i7.tuiTypedFromEvent(monthsScrollRef.elementRef.nativeElement, 'touchstart', { passive: true });
|
|
731
|
-
var touchend$ = i7.tuiTypedFromEvent(monthsScrollRef.elementRef.nativeElement, 'touchend');
|
|
744
|
+
var touchend$ = i7.tuiTypedFromEvent(monthsScrollRef.elementRef.nativeElement, 'touchend', { passive: true });
|
|
732
745
|
// Smooth scroll to the closest month after scrolling is done
|
|
733
746
|
touchstart$
|
|
734
747
|
.pipe(operators.switchMap(function () { return touchend$; }), operators.switchMap(function () { return i8.race(monthsScrollRef.elementScrolled(), i8.timer(SCROLL_DEBOUNCE_TIME)).pipe(operators.debounceTime(SCROLL_DEBOUNCE_TIME * 2), operators.take(1), operators.takeUntil(touchstart$)); }), operators.takeUntil(this.destroy$))
|
|
@@ -755,8 +768,8 @@
|
|
|
755
768
|
};
|
|
756
769
|
return TuiMobileCalendarComponent;
|
|
757
770
|
}());
|
|
758
|
-
TuiMobileCalendarComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiMobileCalendarComponent, deps: [{ token: i7.TUI_IS_IOS }, { token: i7.TUI_IS_E2E }, { token: i6.DOCUMENT }, { token: i7.TuiDestroyService, self: true }, { token: TUI_VALUE_STREAM }, { token: i1.TUI_COMMON_ICONS }, { token: i1.TUI_CLOSE_WORD }, { token: kit.TUI_CANCEL_WORD }, { token: kit.TUI_DONE_WORD }, { token: i1.TUI_SHORT_WEEK_DAYS }, { token: kit.TUI_CHOOSE_DAY_OR_RANGE_TEXTS }, { token: i1.TUI_ANIMATIONS_DURATION }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
759
|
-
TuiMobileCalendarComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TuiMobileCalendarComponent, selector: "tui-mobile-calendar", inputs: { single: "single", min: "min", max: "max", disabledItemHandler: "disabledItemHandler" }, outputs: { cancel: "cancel", confirm: "confirm" }, host: { properties: { "class._ios": "isIOS" } }, providers: TUI_MOBILE_CALENDAR_PROVIDERS, viewQueries: [{ propertyName: "yearsScrollRef", first: true, predicate: ["yearsScrollRef"], descendants: true }, { propertyName: "monthsScrollRef", first: true, predicate: ["monthsScrollRef"], descendants: true }], ngImport: i0__namespace, template: "<header class=\"t-header\">\n <button\n appearance=\"\"\n automation-id=\"tui-mobile-calendar__cancel\"\n shape=\"rounded\"\n tuiIconButton\n tuiRipple\n type=\"button\"\n class=\"t-close\"\n [icon]=\"icons.close\"\n [title]=\"closeWord$ | async\"\n (click)=\"onClose()\"\n ></button>\n <button\n tuiLink\n tuiTouchable=\"opacity\"\n type=\"button\"\n class=\"t-link t-link_close\"\n (click)=\"onClose()\"\n >\n {{ cancelWord$ | async }}\n </button>\n <h2\n *ngIf=\"chooseDayOrRangeTexts$ | async as texts\"\n automation-id=\"tui-mobile-calendar__label\"\n class=\"t-label\"\n >\n {{ single ? texts[0] : texts[1] }}\n </h2>\n <button\n automation-id=\"tui-mobile-calendar__confirm\"\n tuiLink\n tuiTouchable=\"opacity\"\n type=\"button\"\n class=\"t-link\"\n (click)=\"onConfirm()\"\n >\n {{ doneWord$ | async }}\n </button>\n</header>\n<cdk-virtual-scroll-viewport\n #yearsScrollRef\n orientation=\"horizontal\"\n class=\"t-years\"\n [itemSize]=\"yearWidth\"\n>\n <div class=\"t-years-wrapper\">\n <button\n *cdkVirtualFor=\"let index of years\"\n type=\"button\"\n class=\"t-year\"\n [attr.data-state]=\"getState(index)\"\n (click)=\"setYear(index)\"\n >\n {{ index }}\n </button>\n </div>\n</cdk-virtual-scroll-viewport>\n<div class=\"t-week\">\n <div\n *ngFor=\"let day of unorderedWeekDays$ | tuiOrderWeekDays | async\"\n class=\"t-day\"\n >\n {{ day }}\n </div>\n</div>\n<cdk-virtual-scroll-viewport\n #monthsScrollRef\n class=\"t-months\"\n (scrolledIndexChange)=\"onMonthChange($event)\"\n>\n <section\n *cdkVirtualFor=\"let month of months; templateCacheSize: 10\"\n class=\"t-month-wrapper\"\n >\n <h2 class=\"t-month\">{{ month | tuiMonth | async }}</h2>\n <tui-primitive-calendar-mobile\n class=\"t-calendar\"\n [disabledItemHandler]=\"disabledItemHandler | tuiMapper: disabledItemHandlerMapper : min : max\"\n [month]=\"month\"\n [value]=\"value\"\n (dayClick)=\"onDayClick($event)\"\n ></tui-primitive-calendar-mobile>\n </section>\n</cdk-virtual-scroll-viewport>\n", styles: [":host{display:block;height:100%;font-family:-apple-system,BlinkMacSystemFont,Roboto,sans-serif;color:var(--tui-text-01);-webkit-tap-highlight-color:transparent}.t-header{position:relative;display:flex;align-items:center;height:3.5rem;padding:0 1rem;border-bottom:.5px solid var(--tui-base-03)}:host._ios .t-header{height:2.75rem;border-bottom:none}.t-close{width:1.5rem;height:1.5rem;margin-right:2rem}:host._ios .t-close{display:none}.t-link{margin-left:auto;flex-shrink:0;font-size:.875rem;line-height:1rem;font-weight:500;text-transform:uppercase;color:var(--tui-link)}.t-link_close{display:none}:host._ios .t-link{min-width:3.75rem;text-align:right;font-size:.9375rem;line-height:1.125rem;font-weight:400;letter-spacing:.018125rem;text-transform:none}:host._ios .t-link_close{display:block;margin:0 auto 0 0;text-align:left}.t-label{flex-grow:1;margin:0;font-size:1.25rem;line-height:3.5rem;font-weight:500;letter-spacing:-.0125rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.t-label+.t-link{padding-left:1rem}:host._ios .t-label{font-size:1.0625rem;font-weight:600;letter-spacing:-.025625rem;text-align:center}.t-years{scrollbar-width:none;-ms-overflow-style:none;height:4.0625rem;background-color:var(--tui-base-01);box-shadow:0 .5px var(--tui-base-03)}.t-years::-webkit-scrollbar,.t-years::-webkit-scrollbar-thumb{background:transparent;width:0;height:0}:host._ios .t-years{background-color:transparent}.t-years-wrapper{display:flex;height:4.0625rem}.t-year{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;border:0;background:none;font-size:inherit;line-height:inherit;outline:none;width:20vw;flex-shrink:0;font-size:.9375rem;font-weight:700;letter-spacing:.015625rem;cursor:pointer;opacity:.1;transform:scale(.73);transition:color,opacity,transform .2s}.t-year[data-state=adjacent]{transform:scale(.86);opacity:.3}.t-year[data-state=active]{color:var(--tui-link);opacity:1;transform:scale(1)}.t-week{display:flex;align-items:center;height:1.875rem;width:20.75rem;max-width:100%;margin:0 auto;font-size:.75rem}:host._ios .t-week{width:22.625rem;font-size:.6875rem;font-weight:500;color:var(--tui-text-02)}.t-day{flex:1;text-align:center}.t-months{scrollbar-width:none;-ms-overflow-style:none;height:calc(100% - 9.5rem);box-shadow:0 -1px var(--tui-base-03);overflow-x:hidden}.t-months::-webkit-scrollbar,.t-months::-webkit-scrollbar-thumb{background:transparent;width:0;height:0}:host._ios .t-months{height:calc(100% - 8.75rem)}.t-month-wrapper{margin:.625rem 0 -.625rem}.t-month{height:2.75rem;line-height:2.75rem;padding-left:1rem;font-size:.875rem;font-weight:500;text-transform:uppercase;margin:0 0 1.25rem;box-sizing:border-box;border-bottom:.5px solid var(--tui-base-03)}:host._ios .t-month{height:3.125rem;margin:0;border-bottom:none;text-transform:none;font-size:1.375rem;line-height:3.125rem;letter-spacing:.02rem;font-weight:700}.t-calendar{margin:0 auto;font-family:inherit;font-size:1.125rem;transition:opacity .2s}:host._ios .t-calendar{font-size:1.0625rem}\n"], components: [{ type: i1__namespace.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { type: i1__namespace.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }, { type: i2__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: i3__namespace.TuiPrimitiveCalendarMobileComponent, selector: "tui-primitive-calendar-mobile" }], directives: [{ type: i4__namespace.TuiRippleDirective, selector: "[tuiRipple]", inputs: ["tuiRipple"] }, { type: i5__namespace.TuiTouchableDirective, selector: "[tuiTouchable]", inputs: ["tuiTouchable"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i2__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i6__namespace.AsyncPipe, "tuiOrderWeekDays": i1__namespace.TuiOrderWeekDaysPipe, "tuiMonth": i1__namespace.TuiMonthPipe, "tuiMapper": i7__namespace.TuiMapperPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
771
|
+
TuiMobileCalendarComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiMobileCalendarComponent, deps: [{ token: i7.TUI_IS_IOS }, { token: i7.TUI_IS_E2E }, { token: i6.DOCUMENT }, { token: i7.TuiDestroyService, self: true }, { token: TUI_VALUE_STREAM }, { token: i1.TUI_COMMON_ICONS }, { token: i1.TUI_CLOSE_WORD }, { token: kit.TUI_CANCEL_WORD }, { token: kit.TUI_DONE_WORD }, { token: i1.TUI_SHORT_WEEK_DAYS }, { token: kit.TUI_CHOOSE_DAY_OR_RANGE_TEXTS }, { token: i1.TUI_ANIMATIONS_DURATION }, { token: i0.NgZone }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
772
|
+
TuiMobileCalendarComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TuiMobileCalendarComponent, selector: "tui-mobile-calendar", inputs: { single: "single", min: "min", max: "max", disabledItemHandler: "disabledItemHandler" }, outputs: { cancel: "cancel", confirm: "confirm" }, host: { properties: { "class._ios": "isIOS" } }, providers: TUI_MOBILE_CALENDAR_PROVIDERS, viewQueries: [{ propertyName: "yearsScrollRef", first: true, predicate: ["yearsScrollRef"], descendants: true }, { propertyName: "monthsScrollRef", first: true, predicate: ["monthsScrollRef"], descendants: true }], ngImport: i0__namespace, template: "<header class=\"t-header\">\n <button\n appearance=\"\"\n automation-id=\"tui-mobile-calendar__cancel\"\n shape=\"rounded\"\n tuiIconButton\n tuiRipple\n type=\"button\"\n class=\"t-close\"\n [icon]=\"icons.close\"\n [title]=\"closeWord$ | async\"\n (click)=\"onClose()\"\n ></button>\n <button\n tuiLink\n tuiTouchable=\"opacity\"\n type=\"button\"\n class=\"t-link t-link_close\"\n (click)=\"onClose()\"\n >\n {{ cancelWord$ | async }}\n </button>\n <h2\n *ngIf=\"chooseDayOrRangeTexts$ | async as texts\"\n automation-id=\"tui-mobile-calendar__label\"\n class=\"t-label\"\n >\n {{ single ? texts[0] : texts[1] }}\n </h2>\n <button\n automation-id=\"tui-mobile-calendar__confirm\"\n tuiLink\n tuiTouchable=\"opacity\"\n type=\"button\"\n class=\"t-link\"\n (click)=\"onConfirm()\"\n >\n {{ doneWord$ | async }}\n </button>\n</header>\n<cdk-virtual-scroll-viewport\n #yearsScrollRef\n orientation=\"horizontal\"\n class=\"t-years\"\n [itemSize]=\"yearWidth\"\n>\n <div class=\"t-years-wrapper\">\n <button\n *cdkVirtualFor=\"let index of years\"\n type=\"button\"\n class=\"t-year\"\n [attr.data-state]=\"getState(index)\"\n (click)=\"setYear(index)\"\n >\n {{ index }}\n </button>\n </div>\n</cdk-virtual-scroll-viewport>\n<div class=\"t-week\">\n <div\n *ngFor=\"let day of unorderedWeekDays$ | tuiOrderWeekDays | async\"\n class=\"t-day\"\n >\n {{ day }}\n </div>\n</div>\n<cdk-virtual-scroll-viewport\n #monthsScrollRef\n class=\"t-months\"\n (scrolledIndexChange)=\"onMonthChange($event)\"\n>\n <section\n *cdkVirtualFor=\"let month of months; templateCacheSize: 10\"\n class=\"t-month-wrapper\"\n >\n <h2 class=\"t-month\">{{ month | tuiMonth | async }}</h2>\n <tui-primitive-calendar-mobile\n class=\"t-calendar\"\n [disabledItemHandler]=\"disabledItemHandler | tuiMapper: disabledItemHandlerMapper : min : max\"\n [month]=\"month\"\n [value]=\"value\"\n (dayClick)=\"onDayClick($event)\"\n ></tui-primitive-calendar-mobile>\n </section>\n</cdk-virtual-scroll-viewport>\n", styles: [":host{display:block;height:100%;font-family:-apple-system,BlinkMacSystemFont,Roboto,sans-serif;color:var(--tui-text-01);-webkit-tap-highlight-color:transparent}.t-header{position:relative;display:flex;align-items:center;height:3.5rem;padding:0 1rem;border-bottom:.5px solid var(--tui-base-03)}:host._ios .t-header{height:2.75rem;border-bottom:none}.t-close{width:1.5rem;height:1.5rem;margin-right:2rem}:host._ios .t-close{display:none}.t-link{margin-left:auto;flex-shrink:0;font-size:.875rem;line-height:1rem;font-weight:500;text-transform:uppercase;color:var(--tui-link)}.t-link_close{display:none}:host._ios .t-link{min-width:3.75rem;text-align:right;font-size:.9375rem;line-height:1.125rem;font-weight:400;letter-spacing:.018125rem;text-transform:none}:host._ios .t-link_close{display:block;margin:0 auto 0 0;text-align:left}.t-label{flex-grow:1;margin:0;font-size:1.25rem;line-height:3.5rem;font-weight:500;letter-spacing:-.0125rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.t-label+.t-link{padding-left:1rem}:host._ios .t-label{font-size:1.0625rem;font-weight:600;letter-spacing:-.025625rem;text-align:center}.t-years{scrollbar-width:none;-ms-overflow-style:none;height:4.0625rem;background-color:var(--tui-base-01);box-shadow:0 .5px var(--tui-base-03)}.t-years::-webkit-scrollbar,.t-years::-webkit-scrollbar-thumb{background:transparent;width:0;height:0}:host._ios .t-years{background-color:transparent}.t-years-wrapper{display:flex;height:4.0625rem}.t-year{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;border:0;background:none;font-size:inherit;line-height:inherit;text-decoration:none;outline:none;width:20vw;flex-shrink:0;font-size:.9375rem;font-weight:700;letter-spacing:.015625rem;cursor:pointer;opacity:.1;transform:scale(.73);transition:color,opacity,transform .2s}.t-year[data-state=adjacent]{transform:scale(.86);opacity:.3}.t-year[data-state=active]{color:var(--tui-link);opacity:1;transform:scale(1)}.t-week{display:flex;align-items:center;height:1.875rem;width:20.75rem;max-width:100%;margin:0 auto;font-size:.75rem}:host._ios .t-week{width:22.625rem;font-size:.6875rem;font-weight:500;color:var(--tui-text-02)}.t-day{flex:1;text-align:center}.t-months{scrollbar-width:none;-ms-overflow-style:none;height:calc(100% - 9.5rem);box-shadow:0 -1px var(--tui-base-03);overflow-x:hidden}.t-months::-webkit-scrollbar,.t-months::-webkit-scrollbar-thumb{background:transparent;width:0;height:0}:host._ios .t-months{height:calc(100% - 8.75rem)}.t-month-wrapper{margin:.625rem 0 -.625rem}.t-month{height:2.75rem;line-height:2.75rem;padding-left:1rem;font-size:.875rem;font-weight:500;text-transform:uppercase;margin:0 0 1.25rem;box-sizing:border-box;border-bottom:.5px solid var(--tui-base-03)}:host._ios .t-month{height:3.125rem;margin:0;border-bottom:none;text-transform:none;font-size:1.375rem;line-height:3.125rem;letter-spacing:.02rem;font-weight:700}.t-calendar{margin:0 auto;font-family:inherit;font-size:1.125rem;transition:opacity .2s}:host._ios .t-calendar{font-size:1.0625rem}\n"], components: [{ type: i1__namespace.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { type: i1__namespace.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }, { type: i2__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: i3__namespace.TuiPrimitiveCalendarMobileComponent, selector: "tui-primitive-calendar-mobile" }], directives: [{ type: i4__namespace.TuiRippleDirective, selector: "[tuiRipple]", inputs: ["tuiRipple"] }, { type: i5__namespace.TuiTouchableDirective, selector: "[tuiTouchable]", inputs: ["tuiTouchable"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i2__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i6__namespace.AsyncPipe, "tuiOrderWeekDays": i1__namespace.TuiOrderWeekDaysPipe, "tuiMonth": i1__namespace.TuiMonthPipe, "tuiMapper": i7__namespace.TuiMapperPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
760
773
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiMobileCalendarComponent, decorators: [{
|
|
761
774
|
type: i0.Component,
|
|
762
775
|
args: [{
|
|
@@ -806,6 +819,9 @@
|
|
|
806
819
|
}] }, { type: undefined, decorators: [{
|
|
807
820
|
type: i0.Inject,
|
|
808
821
|
args: [i1.TUI_ANIMATIONS_DURATION]
|
|
822
|
+
}] }, { type: i0__namespace.NgZone, decorators: [{
|
|
823
|
+
type: i0.Inject,
|
|
824
|
+
args: [i0.NgZone]
|
|
809
825
|
}] }];
|
|
810
826
|
}, propDecorators: { yearsScrollRef: [{
|
|
811
827
|
type: i0.ViewChild,
|