@@ -232,10 +232,19 @@ export interface MatDatepickerControl<D> {
232232 stateChanges : Observable < void > ;
233233}
234234
235+ /** A picker panel that can be associated with a {@link MatDatepickerControl}. */
236+ export interface MatDatepickerPanel < C extends MatDatepickerControl < D > , S ,
237+ D = ExtractDateTypeFromSelection < S > > {
238+ id : string ;
239+ opened : boolean ;
240+ open ( ) : void ;
241+ registerInput ( input : C ) : MatDateSelectionModel < S , D > ;
242+ }
243+
235244/** Base class for a datepicker. */
236245@Directive ( )
237246export abstract class MatDatepickerBase < C extends MatDatepickerControl < D > , S ,
238- D = ExtractDateTypeFromSelection < S > > implements OnDestroy , OnChanges {
247+ D = ExtractDateTypeFromSelection < S > > implements MatDatepickerPanel < C , S , D > , OnDestroy , OnChanges {
239248 private _scrollStrategy : ( ) => ScrollStrategy ;
240249 private _inputStateChanges = Subscription . EMPTY ;
241250
@@ -450,7 +459,7 @@ export abstract class MatDatepickerBase<C extends MatDatepickerControl<D>, S,
450459 * @param input The datepicker input to register with this datepicker.
451460 * @returns Selection model that the input should hook itself up to.
452461 */
453- _registerInput ( input : C ) : MatDateSelectionModel < S , D > {
462+ registerInput ( input : C ) : MatDateSelectionModel < S , D > {
454463 if ( this . _datepickerInput && ( typeof ngDevMode === 'undefined' || ngDevMode ) ) {
455464 throw Error ( 'A MatDatepicker can only be associated with a single input.' ) ;
456465 }
0 commit comments