diff --git a/src/material/datepicker/datepicker-base.ts b/src/material/datepicker/datepicker-base.ts index 08d969bd027d..89c4244f7f01 100644 --- a/src/material/datepicker/datepicker-base.ts +++ b/src/material/datepicker/datepicker-base.ts @@ -17,7 +17,6 @@ import { FlexibleConnectedPositionStrategy, } from '@angular/cdk/overlay'; import {ComponentPortal, ComponentType, TemplatePortal} from '@angular/cdk/portal'; -import {DOCUMENT} from '@angular/common'; import { AfterViewInit, ChangeDetectionStrategy, @@ -439,22 +438,12 @@ export abstract class MatDatepickerBase, S, readonly stateChanges = new Subject(); constructor( - /** - * @deprecated `_dialog` parameter is no longer being used and it will be removed. - * @breaking-change 13.0.0 - */ - @Inject(ElementRef) _dialog: any, private _overlay: Overlay, private _ngZone: NgZone, private _viewContainerRef: ViewContainerRef, @Inject(MAT_DATEPICKER_SCROLL_STRATEGY) scrollStrategy: any, @Optional() private _dateAdapter: DateAdapter, @Optional() private _dir: Directionality, - /** - * @deprecated No longer being used. To be removed. - * @breaking-change 13.0.0 - */ - @Optional() @Inject(DOCUMENT) _document: any, private _model: MatDateSelectionModel) { if (!this._dateAdapter && (typeof ngDevMode === 'undefined' || ngDevMode)) { throw createMissingDateImplError('DateAdapter'); diff --git a/src/material/schematics/ng-update/data/constructor-checks.ts b/src/material/schematics/ng-update/data/constructor-checks.ts index 5fbba0838c71..be7bce16cf74 100644 --- a/src/material/schematics/ng-update/data/constructor-checks.ts +++ b/src/material/schematics/ng-update/data/constructor-checks.ts @@ -18,6 +18,10 @@ export const constructorChecks: VersionChanges = { { pr: 'https://github.com/angular/components/pull/23389', changes: ['MatFormField'] + }, + { + pr: 'https://github.com/angular/components/pull/23573', + changes: ['MatDatepicker', 'MatDateRangePicker'] } ], [TargetVersion.V12]: [ diff --git a/tools/public_api_guard/material/datepicker.md b/tools/public_api_guard/material/datepicker.md index 474fe9e9698f..da6a7b6ef509 100644 --- a/tools/public_api_guard/material/datepicker.md +++ b/tools/public_api_guard/material/datepicker.md @@ -347,9 +347,7 @@ export class MatDatepickerApply { // @public abstract class MatDatepickerBase, S, D = ExtractDateTypeFromSelection> implements MatDatepickerPanel, OnDestroy, OnChanges { - constructor( - _dialog: any, _overlay: Overlay, _ngZone: NgZone, _viewContainerRef: ViewContainerRef, scrollStrategy: any, _dateAdapter: DateAdapter, _dir: Directionality, - _document: any, _model: MatDateSelectionModel); + constructor(_overlay: Overlay, _ngZone: NgZone, _viewContainerRef: ViewContainerRef, scrollStrategy: any, _dateAdapter: DateAdapter, _dir: Directionality, _model: MatDateSelectionModel); _applyPendingSelection(): void; calendarHeaderComponent: ComponentType; close(): void; @@ -409,7 +407,7 @@ abstract class MatDatepickerBase, S, D = Extra // (undocumented) static ɵdir: i0.ɵɵDirectiveDeclaration, never, never, { "calendarHeaderComponent": "calendarHeaderComponent"; "startAt": "startAt"; "startView": "startView"; "color": "color"; "touchUi": "touchUi"; "disabled": "disabled"; "xPosition": "xPosition"; "yPosition": "yPosition"; "restoreFocus": "restoreFocus"; "dateClass": "dateClass"; "panelClass": "panelClass"; "opened": "opened"; }, { "yearSelected": "yearSelected"; "monthSelected": "monthSelected"; "viewChanged": "viewChanged"; "openedStream": "opened"; "closedStream": "closed"; }, never>; // (undocumented) - static ɵfac: i0.ɵɵFactoryDeclaration, [null, null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }, null]>; + static ɵfac: i0.ɵɵFactoryDeclaration, [null, null, null, null, { optional: true; }, { optional: true; }, null]>; } // @public