@angular/cdk 19.1.0-next.2 → 19.1.0-next.3
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/a11y/index.d.ts +4 -3
- package/dialog/index.d.ts +1 -0
- package/drag-drop/index.d.ts +34 -3
- package/fesm2022/a11y.mjs +82 -81
- package/fesm2022/a11y.mjs.map +1 -1
- package/fesm2022/accordion.mjs +10 -10
- package/fesm2022/bidi.mjs +10 -10
- package/fesm2022/cdk.mjs +1 -1
- package/fesm2022/cdk.mjs.map +1 -1
- package/fesm2022/clipboard.mjs +10 -10
- package/fesm2022/collections.mjs +3 -3
- package/fesm2022/dialog.mjs +16 -15
- package/fesm2022/dialog.mjs.map +1 -1
- package/fesm2022/drag-drop.mjs +153 -114
- package/fesm2022/drag-drop.mjs.map +1 -1
- package/fesm2022/layout.mjs +10 -10
- package/fesm2022/listbox.mjs +23 -29
- package/fesm2022/listbox.mjs.map +1 -1
- package/fesm2022/menu.mjs +131 -114
- package/fesm2022/menu.mjs.map +1 -1
- package/fesm2022/observers/private.mjs +8 -8
- package/fesm2022/observers/private.mjs.map +1 -1
- package/fesm2022/observers.mjs +13 -13
- package/fesm2022/overlay.mjs +89 -106
- package/fesm2022/overlay.mjs.map +1 -1
- package/fesm2022/platform.mjs +30 -9
- package/fesm2022/platform.mjs.map +1 -1
- package/fesm2022/portal.mjs +16 -16
- package/fesm2022/private.mjs +6 -6
- package/fesm2022/scrolling.mjs +64 -86
- package/fesm2022/scrolling.mjs.map +1 -1
- package/fesm2022/stepper.mjs +22 -22
- package/fesm2022/table.mjs +76 -76
- package/fesm2022/testing/testbed.mjs +83 -40
- package/fesm2022/testing/testbed.mjs.map +1 -1
- package/fesm2022/text-field.mjs +42 -52
- package/fesm2022/text-field.mjs.map +1 -1
- package/fesm2022/tree.mjs +25 -25
- package/listbox/index.d.ts +1 -5
- package/menu/index.d.ts +18 -19
- package/observers/private/index.d.ts +1 -0
- package/overlay/index.d.ts +12 -6
- package/package.json +1 -1
- package/platform/index.d.ts +10 -0
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-add/index.mjs +1 -1
- package/scrolling/index.d.ts +7 -14
- package/text-field/index.d.ts +4 -4
package/fesm2022/scrolling.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { coerceNumberProperty, coerceElement } from '@angular/cdk/coercion';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { InjectionToken, forwardRef, Directive, Input, inject, NgZone, Injectable, ElementRef, ChangeDetectorRef, Injector, afterNextRender, booleanAttribute, Optional, Inject, Component, ViewEncapsulation, ChangeDetectionStrategy, Output, ViewChild, ViewContainerRef, TemplateRef, IterableDiffers, NgModule } from '@angular/core';
|
|
4
|
-
import { Subject, of, Observable,
|
|
5
|
-
import { distinctUntilChanged, auditTime, filter,
|
|
3
|
+
import { InjectionToken, forwardRef, Directive, Input, inject, NgZone, RendererFactory2, Injectable, ElementRef, Renderer2, ChangeDetectorRef, Injector, afterNextRender, booleanAttribute, Optional, Inject, Component, ViewEncapsulation, ChangeDetectionStrategy, Output, ViewChild, ViewContainerRef, TemplateRef, IterableDiffers, NgModule } from '@angular/core';
|
|
4
|
+
import { Subject, of, Observable, animationFrameScheduler, asapScheduler, Subscription, isObservable } from 'rxjs';
|
|
5
|
+
import { distinctUntilChanged, auditTime, filter, startWith, takeUntil, pairwise, switchMap, shareReplay } from 'rxjs/operators';
|
|
6
6
|
import { Platform, getRtlScrollAxisType, RtlScrollAxisType, supportsScrollBehavior } from '@angular/cdk/platform';
|
|
7
|
-
import { DOCUMENT } from '@angular/common';
|
|
8
7
|
import { Directionality, BidiModule } from '@angular/cdk/bidi';
|
|
9
8
|
import { _VIEW_REPEATER_STRATEGY, isDataSource, ArrayDataSource, _RecycleViewRepeaterStrategy } from '@angular/cdk/collections';
|
|
9
|
+
import { DOCUMENT } from '@angular/common';
|
|
10
10
|
|
|
11
11
|
/** The injection token used to specify the virtual scrolling strategy. */
|
|
12
12
|
const VIRTUAL_SCROLL_STRATEGY = new InjectionToken('VIRTUAL_SCROLL_STRATEGY');
|
|
@@ -190,8 +190,8 @@ class CdkFixedSizeVirtualScroll {
|
|
|
190
190
|
ngOnChanges() {
|
|
191
191
|
this._scrollStrategy.updateItemAndBufferSize(this.itemSize, this.minBufferPx, this.maxBufferPx);
|
|
192
192
|
}
|
|
193
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
194
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
193
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkFixedSizeVirtualScroll, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
194
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkFixedSizeVirtualScroll, isStandalone: true, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: { itemSize: "itemSize", minBufferPx: "minBufferPx", maxBufferPx: "maxBufferPx" }, providers: [
|
|
195
195
|
{
|
|
196
196
|
provide: VIRTUAL_SCROLL_STRATEGY,
|
|
197
197
|
useFactory: _fixedSizeVirtualScrollStrategyFactory,
|
|
@@ -199,7 +199,7 @@ class CdkFixedSizeVirtualScroll {
|
|
|
199
199
|
},
|
|
200
200
|
], usesOnChanges: true, ngImport: i0 });
|
|
201
201
|
}
|
|
202
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
202
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkFixedSizeVirtualScroll, decorators: [{
|
|
203
203
|
type: Directive,
|
|
204
204
|
args: [{
|
|
205
205
|
selector: 'cdk-virtual-scroll-viewport[itemSize]',
|
|
@@ -228,13 +228,11 @@ const DEFAULT_SCROLL_TIME = 20;
|
|
|
228
228
|
class ScrollDispatcher {
|
|
229
229
|
_ngZone = inject(NgZone);
|
|
230
230
|
_platform = inject(Platform);
|
|
231
|
-
|
|
232
|
-
|
|
231
|
+
_renderer = inject(RendererFactory2).createRenderer(null, null);
|
|
232
|
+
_cleanupGlobalListener;
|
|
233
233
|
constructor() { }
|
|
234
234
|
/** Subject for notifying that a registered scrollable reference element has been scrolled. */
|
|
235
235
|
_scrolled = new Subject();
|
|
236
|
-
/** Keeps track of the global `scroll` and `resize` subscriptions. */
|
|
237
|
-
_globalSubscription = null;
|
|
238
236
|
/** Keeps track of the amount of subscriptions to `scrolled`. Used for cleaning up afterwards. */
|
|
239
237
|
_scrolledCount = 0;
|
|
240
238
|
/**
|
|
@@ -278,8 +276,8 @@ class ScrollDispatcher {
|
|
|
278
276
|
return of();
|
|
279
277
|
}
|
|
280
278
|
return new Observable((observer) => {
|
|
281
|
-
if (!this.
|
|
282
|
-
this.
|
|
279
|
+
if (!this._cleanupGlobalListener) {
|
|
280
|
+
this._cleanupGlobalListener = this._ngZone.runOutsideAngular(() => this._renderer.listen('document', 'scroll', () => this._scrolled.next()));
|
|
283
281
|
}
|
|
284
282
|
// In the case of a 0ms delay, use an observable without auditTime
|
|
285
283
|
// since it does add a perceptible delay in processing overhead.
|
|
@@ -291,13 +289,15 @@ class ScrollDispatcher {
|
|
|
291
289
|
subscription.unsubscribe();
|
|
292
290
|
this._scrolledCount--;
|
|
293
291
|
if (!this._scrolledCount) {
|
|
294
|
-
this.
|
|
292
|
+
this._cleanupGlobalListener?.();
|
|
293
|
+
this._cleanupGlobalListener = undefined;
|
|
295
294
|
}
|
|
296
295
|
};
|
|
297
296
|
});
|
|
298
297
|
}
|
|
299
298
|
ngOnDestroy() {
|
|
300
|
-
this.
|
|
299
|
+
this._cleanupGlobalListener?.();
|
|
300
|
+
this._cleanupGlobalListener = undefined;
|
|
301
301
|
this.scrollContainers.forEach((_, container) => this.deregister(container));
|
|
302
302
|
this._scrolled.complete();
|
|
303
303
|
}
|
|
@@ -309,9 +309,7 @@ class ScrollDispatcher {
|
|
|
309
309
|
*/
|
|
310
310
|
ancestorScrolled(elementOrElementRef, auditTimeInMs) {
|
|
311
311
|
const ancestors = this.getAncestorScrollContainers(elementOrElementRef);
|
|
312
|
-
return this.scrolled(auditTimeInMs).pipe(filter(target =>
|
|
313
|
-
return !target || ancestors.indexOf(target) > -1;
|
|
314
|
-
}));
|
|
312
|
+
return this.scrolled(auditTimeInMs).pipe(filter(target => !target || ancestors.indexOf(target) > -1));
|
|
315
313
|
}
|
|
316
314
|
/** Returns all registered Scrollables that contain the provided element. */
|
|
317
315
|
getAncestorScrollContainers(elementOrElementRef) {
|
|
@@ -323,10 +321,6 @@ class ScrollDispatcher {
|
|
|
323
321
|
});
|
|
324
322
|
return scrollingContainers;
|
|
325
323
|
}
|
|
326
|
-
/** Use defaultView of injected document if available or fallback to global window reference */
|
|
327
|
-
_getWindow() {
|
|
328
|
-
return this._document.defaultView || window;
|
|
329
|
-
}
|
|
330
324
|
/** Returns true if the element is contained within the provided Scrollable. */
|
|
331
325
|
_scrollableContainsElement(scrollable, elementOrElementRef) {
|
|
332
326
|
let element = coerceElement(elementOrElementRef);
|
|
@@ -340,24 +334,10 @@ class ScrollDispatcher {
|
|
|
340
334
|
} while ((element = element.parentElement));
|
|
341
335
|
return false;
|
|
342
336
|
}
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
this._globalSubscription = this._ngZone.runOutsideAngular(() => {
|
|
346
|
-
const window = this._getWindow();
|
|
347
|
-
return fromEvent(window.document, 'scroll').subscribe(() => this._scrolled.next());
|
|
348
|
-
});
|
|
349
|
-
}
|
|
350
|
-
/** Cleans up the global scroll listener. */
|
|
351
|
-
_removeGlobalListener() {
|
|
352
|
-
if (this._globalSubscription) {
|
|
353
|
-
this._globalSubscription.unsubscribe();
|
|
354
|
-
this._globalSubscription = null;
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.2", ngImport: i0, type: ScrollDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
358
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-next.2", ngImport: i0, type: ScrollDispatcher, providedIn: 'root' });
|
|
337
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
338
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollDispatcher, providedIn: 'root' });
|
|
359
339
|
}
|
|
360
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
340
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollDispatcher, decorators: [{
|
|
361
341
|
type: Injectable,
|
|
362
342
|
args: [{ providedIn: 'root' }]
|
|
363
343
|
}], ctorParameters: () => [] });
|
|
@@ -372,15 +352,19 @@ class CdkScrollable {
|
|
|
372
352
|
scrollDispatcher = inject(ScrollDispatcher);
|
|
373
353
|
ngZone = inject(NgZone);
|
|
374
354
|
dir = inject(Directionality, { optional: true });
|
|
355
|
+
_scrollElement = this.elementRef.nativeElement;
|
|
375
356
|
_destroyed = new Subject();
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
357
|
+
_renderer = inject(Renderer2);
|
|
358
|
+
_cleanupScroll;
|
|
359
|
+
_elementScrolled = new Subject();
|
|
379
360
|
constructor() { }
|
|
380
361
|
ngOnInit() {
|
|
362
|
+
this._cleanupScroll = this.ngZone.runOutsideAngular(() => this._renderer.listen(this._scrollElement, 'scroll', event => this._elementScrolled.next(event)));
|
|
381
363
|
this.scrollDispatcher.register(this);
|
|
382
364
|
}
|
|
383
365
|
ngOnDestroy() {
|
|
366
|
+
this._cleanupScroll?.();
|
|
367
|
+
this._elementScrolled.complete();
|
|
384
368
|
this.scrollDispatcher.deregister(this);
|
|
385
369
|
this._destroyed.next();
|
|
386
370
|
this._destroyed.complete();
|
|
@@ -509,10 +493,10 @@ class CdkScrollable {
|
|
|
509
493
|
}
|
|
510
494
|
}
|
|
511
495
|
}
|
|
512
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
513
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
496
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollable, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
497
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkScrollable, isStandalone: true, selector: "[cdk-scrollable], [cdkScrollable]", ngImport: i0 });
|
|
514
498
|
}
|
|
515
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
499
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollable, decorators: [{
|
|
516
500
|
type: Directive,
|
|
517
501
|
args: [{
|
|
518
502
|
selector: '[cdk-scrollable], [cdkScrollable]',
|
|
@@ -527,25 +511,23 @@ const DEFAULT_RESIZE_TIME = 20;
|
|
|
527
511
|
*/
|
|
528
512
|
class ViewportRuler {
|
|
529
513
|
_platform = inject(Platform);
|
|
514
|
+
_listeners;
|
|
530
515
|
/** Cached viewport dimensions. */
|
|
531
516
|
_viewportSize;
|
|
532
517
|
/** Stream of viewport change events. */
|
|
533
518
|
_change = new Subject();
|
|
534
|
-
/** Event listener that will be used to handle the viewport change events. */
|
|
535
|
-
_changeListener = (event) => {
|
|
536
|
-
this._change.next(event);
|
|
537
|
-
};
|
|
538
519
|
/** Used to reference correct document/window */
|
|
539
520
|
_document = inject(DOCUMENT, { optional: true });
|
|
540
521
|
constructor() {
|
|
541
522
|
const ngZone = inject(NgZone);
|
|
523
|
+
const renderer = inject(RendererFactory2).createRenderer(null, null);
|
|
542
524
|
ngZone.runOutsideAngular(() => {
|
|
543
525
|
if (this._platform.isBrowser) {
|
|
544
|
-
const
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
526
|
+
const changeListener = (event) => this._change.next(event);
|
|
527
|
+
this._listeners = [
|
|
528
|
+
renderer.listen('window', 'resize', changeListener),
|
|
529
|
+
renderer.listen('window', 'orientationchange', changeListener),
|
|
530
|
+
];
|
|
549
531
|
}
|
|
550
532
|
// Clear the cached position so that the viewport is re-measured next time it is required.
|
|
551
533
|
// We don't need to keep track of the subscription, because it is completed on destroy.
|
|
@@ -553,11 +535,7 @@ class ViewportRuler {
|
|
|
553
535
|
});
|
|
554
536
|
}
|
|
555
537
|
ngOnDestroy() {
|
|
556
|
-
|
|
557
|
-
const window = this._getWindow();
|
|
558
|
-
window.removeEventListener('resize', this._changeListener);
|
|
559
|
-
window.removeEventListener('orientationchange', this._changeListener);
|
|
560
|
-
}
|
|
538
|
+
this._listeners?.forEach(cleanup => cleanup());
|
|
561
539
|
this._change.complete();
|
|
562
540
|
}
|
|
563
541
|
/** Returns the viewport's width and height. */
|
|
@@ -642,10 +620,10 @@ class ViewportRuler {
|
|
|
642
620
|
? { width: window.innerWidth, height: window.innerHeight }
|
|
643
621
|
: { width: 0, height: 0 };
|
|
644
622
|
}
|
|
645
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
646
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
623
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ViewportRuler, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
624
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ViewportRuler, providedIn: 'root' });
|
|
647
625
|
}
|
|
648
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
626
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ViewportRuler, decorators: [{
|
|
649
627
|
type: Injectable,
|
|
650
628
|
args: [{ providedIn: 'root' }]
|
|
651
629
|
}], ctorParameters: () => [] });
|
|
@@ -667,10 +645,10 @@ class CdkVirtualScrollable extends CdkScrollable {
|
|
|
667
645
|
const viewportEl = this.elementRef.nativeElement;
|
|
668
646
|
return orientation === 'horizontal' ? viewportEl.clientWidth : viewportEl.clientHeight;
|
|
669
647
|
}
|
|
670
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
671
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
648
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollable, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
649
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkVirtualScrollable, isStandalone: true, usesInheritance: true, ngImport: i0 });
|
|
672
650
|
}
|
|
673
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
651
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollable, decorators: [{
|
|
674
652
|
type: Directive
|
|
675
653
|
}], ctorParameters: () => [] });
|
|
676
654
|
|
|
@@ -1063,8 +1041,8 @@ class CdkVirtualScrollViewport extends CdkVirtualScrollable {
|
|
|
1063
1041
|
this._totalContentWidth =
|
|
1064
1042
|
this.orientation === 'horizontal' ? `${this._totalContentSize}px` : '';
|
|
1065
1043
|
}
|
|
1066
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1067
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "19.1.0-next.
|
|
1044
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollViewport, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1045
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "19.1.0-next.3", type: CdkVirtualScrollViewport, isStandalone: true, selector: "cdk-virtual-scroll-viewport", inputs: { orientation: "orientation", appendOnly: ["appendOnly", "appendOnly", booleanAttribute] }, outputs: { scrolledIndexChange: "scrolledIndexChange" }, host: { properties: { "class.cdk-virtual-scroll-orientation-horizontal": "orientation === \"horizontal\"", "class.cdk-virtual-scroll-orientation-vertical": "orientation !== \"horizontal\"" }, classAttribute: "cdk-virtual-scroll-viewport" }, providers: [
|
|
1068
1046
|
{
|
|
1069
1047
|
provide: CdkScrollable,
|
|
1070
1048
|
useFactory: (virtualScrollable, viewport) => virtualScrollable || viewport,
|
|
@@ -1072,7 +1050,7 @@ class CdkVirtualScrollViewport extends CdkVirtualScrollable {
|
|
|
1072
1050
|
},
|
|
1073
1051
|
], viewQueries: [{ propertyName: "_contentWrapper", first: true, predicate: ["contentWrapper"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<!--\n Wrap the rendered content in an element that will be used to offset it based on the scroll\n position.\n-->\n<div #contentWrapper class=\"cdk-virtual-scroll-content-wrapper\">\n <ng-content></ng-content>\n</div>\n<!--\n Spacer used to force the scrolling container to the correct size for the *total* number of items\n so that the scrollbar captures the size of the entire data set.\n-->\n<div class=\"cdk-virtual-scroll-spacer\"\n [style.width]=\"_totalContentWidth\" [style.height]=\"_totalContentHeight\"></div>\n", styles: ["cdk-virtual-scroll-viewport{display:block;position:relative;transform:translateZ(0)}.cdk-virtual-scrollable{overflow:auto;will-change:scroll-position;contain:strict}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{height:1px;transform-origin:0 0;flex:0 0 auto}[dir=rtl] .cdk-virtual-scroll-spacer{transform-origin:100% 0}"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1074
1052
|
}
|
|
1075
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1053
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollViewport, decorators: [{
|
|
1076
1054
|
type: Component,
|
|
1077
1055
|
args: [{ selector: 'cdk-virtual-scroll-viewport', host: {
|
|
1078
1056
|
'class': 'cdk-virtual-scroll-viewport',
|
|
@@ -1357,10 +1335,10 @@ class CdkVirtualForOf {
|
|
|
1357
1335
|
static ngTemplateContextGuard(directive, context) {
|
|
1358
1336
|
return true;
|
|
1359
1337
|
}
|
|
1360
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1361
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
1338
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualForOf, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1339
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkVirtualForOf, isStandalone: true, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: { cdkVirtualForOf: "cdkVirtualForOf", cdkVirtualForTrackBy: "cdkVirtualForTrackBy", cdkVirtualForTemplate: "cdkVirtualForTemplate", cdkVirtualForTemplateCacheSize: "cdkVirtualForTemplateCacheSize" }, providers: [{ provide: _VIEW_REPEATER_STRATEGY, useClass: _RecycleViewRepeaterStrategy }], ngImport: i0 });
|
|
1362
1340
|
}
|
|
1363
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1341
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualForOf, decorators: [{
|
|
1364
1342
|
type: Directive,
|
|
1365
1343
|
args: [{
|
|
1366
1344
|
selector: '[cdkVirtualFor][cdkVirtualForOf]',
|
|
@@ -1387,10 +1365,10 @@ class CdkVirtualScrollableElement extends CdkVirtualScrollable {
|
|
|
1387
1365
|
return (this.getElementRef().nativeElement.getBoundingClientRect()[from] -
|
|
1388
1366
|
this.measureScrollOffset(from));
|
|
1389
1367
|
}
|
|
1390
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1391
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
1368
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollableElement, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1369
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkVirtualScrollableElement, isStandalone: true, selector: "[cdkVirtualScrollingElement]", host: { classAttribute: "cdk-virtual-scrollable" }, providers: [{ provide: VIRTUAL_SCROLLABLE, useExisting: CdkVirtualScrollableElement }], usesInheritance: true, ngImport: i0 });
|
|
1392
1370
|
}
|
|
1393
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1371
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollableElement, decorators: [{
|
|
1394
1372
|
type: Directive,
|
|
1395
1373
|
args: [{
|
|
1396
1374
|
selector: '[cdkVirtualScrollingElement]',
|
|
@@ -1405,18 +1383,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.2",
|
|
|
1405
1383
|
* Provides as virtual scrollable for the global / window scrollbar.
|
|
1406
1384
|
*/
|
|
1407
1385
|
class CdkVirtualScrollableWindow extends CdkVirtualScrollable {
|
|
1408
|
-
_elementScrolled = new Observable((observer) => this.ngZone.runOutsideAngular(() => fromEvent(document, 'scroll').pipe(takeUntil(this._destroyed)).subscribe(observer)));
|
|
1409
1386
|
constructor() {
|
|
1410
1387
|
super();
|
|
1411
1388
|
this.elementRef = new ElementRef(document.documentElement);
|
|
1389
|
+
this._scrollElement = document;
|
|
1412
1390
|
}
|
|
1413
1391
|
measureBoundingClientRectWithScrollOffset(from) {
|
|
1414
1392
|
return this.getElementRef().nativeElement.getBoundingClientRect()[from];
|
|
1415
1393
|
}
|
|
1416
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1417
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
1394
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollableWindow, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1395
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-next.3", type: CdkVirtualScrollableWindow, isStandalone: true, selector: "cdk-virtual-scroll-viewport[scrollWindow]", providers: [{ provide: VIRTUAL_SCROLLABLE, useExisting: CdkVirtualScrollableWindow }], usesInheritance: true, ngImport: i0 });
|
|
1418
1396
|
}
|
|
1419
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1397
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkVirtualScrollableWindow, decorators: [{
|
|
1420
1398
|
type: Directive,
|
|
1421
1399
|
args: [{
|
|
1422
1400
|
selector: 'cdk-virtual-scroll-viewport[scrollWindow]',
|
|
@@ -1425,11 +1403,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.2",
|
|
|
1425
1403
|
}], ctorParameters: () => [] });
|
|
1426
1404
|
|
|
1427
1405
|
class CdkScrollableModule {
|
|
1428
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1429
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
1430
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1406
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollableModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1407
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollableModule, imports: [CdkScrollable], exports: [CdkScrollable] });
|
|
1408
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollableModule });
|
|
1431
1409
|
}
|
|
1432
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1410
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: CdkScrollableModule, decorators: [{
|
|
1433
1411
|
type: NgModule,
|
|
1434
1412
|
args: [{
|
|
1435
1413
|
exports: [CdkScrollable],
|
|
@@ -1440,8 +1418,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.2",
|
|
|
1440
1418
|
* @docs-primary-export
|
|
1441
1419
|
*/
|
|
1442
1420
|
class ScrollingModule {
|
|
1443
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1444
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-next.
|
|
1421
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1422
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollingModule, imports: [BidiModule, CdkScrollableModule, CdkVirtualScrollViewport,
|
|
1445
1423
|
CdkFixedSizeVirtualScroll,
|
|
1446
1424
|
CdkVirtualForOf,
|
|
1447
1425
|
CdkVirtualScrollableWindow,
|
|
@@ -1450,10 +1428,10 @@ class ScrollingModule {
|
|
|
1450
1428
|
CdkVirtualScrollViewport,
|
|
1451
1429
|
CdkVirtualScrollableWindow,
|
|
1452
1430
|
CdkVirtualScrollableElement] });
|
|
1453
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1431
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollingModule, imports: [BidiModule,
|
|
1454
1432
|
CdkScrollableModule, BidiModule, CdkScrollableModule] });
|
|
1455
1433
|
}
|
|
1456
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.
|
|
1434
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3", ngImport: i0, type: ScrollingModule, decorators: [{
|
|
1457
1435
|
type: NgModule,
|
|
1458
1436
|
args: [{
|
|
1459
1437
|
imports: [
|