diff --git a/src/material/dialog/dialog.ts b/src/material/dialog/dialog.ts index 1c67e983c716..0aad980a8071 100644 --- a/src/material/dialog/dialog.ts +++ b/src/material/dialog/dialog.ts @@ -330,7 +330,12 @@ export abstract class _MatDialogBase implemen } else { const injector = this._createInjector(config, dialogRef, dialogContainer); const contentRef = dialogContainer.attachComponentPortal( - new ComponentPortal(componentOrTemplateRef, config.viewContainerRef, injector), + new ComponentPortal( + componentOrTemplateRef, + config.viewContainerRef, + injector, + config.componentFactoryResolver, + ), ); dialogRef.componentInstance = contentRef.instance; }