MCPcopy Create free account
hub / github.com/angular/components / registerActions

Function registerActions

src/material/datepicker/datepicker-base.ts:624–630  ·  view source on GitHub ↗

* Registers a portal containing action buttons with the datepicker. * @param portal Portal to be registered.

(portal: TemplatePortal)

Source from the content-addressed store, hash-verified

622 * @param portal Portal to be registered.
623 */
624 registerActions(portal: TemplatePortal): void {
625 if (this._actionsPortal && (typeof ngDevMode === 'undefined' || ngDevMode)) {
626 throw Error('A MatDatepicker can only be associated with a single actions row.');
627 }
628 this._actionsPortal = portal;
629 this._componentRef?.instance._assignActions(portal, true);
630 }
631
632 /**
633 * Removes a portal containing action buttons from the datepicker.

Callers

nothing calls this directly

Calls 1

_assignActionsMethod · 0.80

Tested by

no test coverage detected