@ngx-mce/datetime-picker 22.2.14 → 22.3.0-next.1
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.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CdkMonitorFocus, CdkTrapFocus } from "@angular/cdk/a11y";
|
|
2
2
|
import { CdkPortalOutlet, ComponentPortal, TemplatePortal } from "@angular/cdk/portal";
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
|
-
import { Attribute, ChangeDetectionStrategy, ChangeDetectorRef, Component, ContentChild, DOCUMENT, Directive, ElementRef, EventEmitter, HostBinding, Injectable, InjectionToken, Injector, Input, NgZone, Optional, Output, SkipSelf, TemplateRef, ViewChild, ViewContainerRef, ViewEncapsulation, booleanAttribute, computed, effect, forwardRef, inject, input, linkedSignal, model, output, signal, untracked, viewChild } from "@angular/core";
|
|
4
|
+
import { Attribute, ChangeDetectionStrategy, ChangeDetectorRef, Component, ContentChild, DOCUMENT, Directive, ElementRef, EventEmitter, HostBinding, Injectable, InjectionToken, Injector, Input, NgZone, Optional, Output, SkipSelf, TemplateRef, ViewChild, ViewContainerRef, ViewEncapsulation, afterNextRender, booleanAttribute, computed, effect, forwardRef, inject, input, linkedSignal, model, output, signal, untracked, viewChild } from "@angular/core";
|
|
5
5
|
import { outputFromObservable, takeUntilDestroyed, toObservable } from "@angular/core/rxjs-interop";
|
|
6
6
|
import * as i4 from "@angular/material/button";
|
|
7
7
|
import { MatButton, MatButtonModule, MatIconButton } from "@angular/material/button";
|
|
@@ -313,6 +313,7 @@ var NgxMatCalendarBody = class NgxMatCalendarBody {
|
|
|
313
313
|
_didDragSinceMouseDown = false;
|
|
314
314
|
_elementRef = inject(ElementRef);
|
|
315
315
|
_ngZone = inject(NgZone);
|
|
316
|
+
_injector = inject(Injector);
|
|
316
317
|
constructor() {
|
|
317
318
|
this._ngZone.runOutsideAngular(() => {
|
|
318
319
|
const element = this._elementRef.nativeElement;
|
|
@@ -366,7 +367,7 @@ var NgxMatCalendarBody = class NgxMatCalendarBody {
|
|
|
366
367
|
}
|
|
367
368
|
_focusActiveCell(movePreview = true) {
|
|
368
369
|
this._ngZone.runOutsideAngular(() => {
|
|
369
|
-
|
|
370
|
+
afterNextRender(() => {
|
|
370
371
|
setTimeout(() => {
|
|
371
372
|
const activeCell = this._elementRef.nativeElement.querySelector(".mat-calendar-body-active");
|
|
372
373
|
if (activeCell) {
|
|
@@ -374,7 +375,7 @@ var NgxMatCalendarBody = class NgxMatCalendarBody {
|
|
|
374
375
|
activeCell.focus();
|
|
375
376
|
}
|
|
376
377
|
});
|
|
377
|
-
});
|
|
378
|
+
}, { injector: this._injector });
|
|
378
379
|
});
|
|
379
380
|
}
|
|
380
381
|
_scheduleFocusActiveCellAfterViewChecked() {
|
|
@@ -4918,7 +4919,6 @@ var NgxMatDatepickerBase = class NgxMatDatepickerBase {
|
|
|
4918
4919
|
datepickerInput;
|
|
4919
4920
|
stateChanges = new Subject();
|
|
4920
4921
|
_overlay = inject(Overlay);
|
|
4921
|
-
_ngZone = inject(NgZone);
|
|
4922
4922
|
_viewContainerRef = inject(ViewContainerRef);
|
|
4923
4923
|
_scrollStrategy = inject(NGX_MAT_DATEPICKER_SCROLL_STRATEGY);
|
|
4924
4924
|
_dateAdapter = inject(DateAdapter, { optional: true });
|
|
@@ -5038,7 +5038,9 @@ var NgxMatDatepickerBase = class NgxMatDatepickerBase {
|
|
|
5038
5038
|
});
|
|
5039
5039
|
this._componentRef = overlayRef.attach(portal);
|
|
5040
5040
|
this._forwardContentValues(this._componentRef.instance);
|
|
5041
|
-
if (!isDialog)
|
|
5041
|
+
if (!isDialog) afterNextRender(() => {
|
|
5042
|
+
if (overlayRef.hasAttached()) overlayRef.updatePosition();
|
|
5043
|
+
}, { injector: this._viewContainerRef.injector });
|
|
5042
5044
|
}
|
|
5043
5045
|
_destroyOverlay() {
|
|
5044
5046
|
if (this._overlayRef) {
|