{"version":3,"sources":["node_modules/ng-dynamic-component/fesm2020/ng-dynamic-component.mjs"],"sourcesContent":["import * as i0 from '@angular/core';\nimport { InjectionToken, Injectable, Injector, Inject, Optional, Directive, Input, Host, NgModule, EventEmitter, Component, Output, ElementRef } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\nimport * as i1 from '@angular/common';\n\n/**\n * @public\n */\nfunction defaultEventArgumentFactory() {\n return '$event';\n}\n/**\n * @public\n */\nconst IoEventArgumentToken = new InjectionToken('EventArgument', {\n providedIn: 'root',\n factory: defaultEventArgumentFactory\n});\n/**\n * @public\n * @deprecated Since v10.4.0 - Use {@link IoEventArgumentToken} instead!\n */\nconst EventArgumentToken = IoEventArgumentToken;\n\n/**\n * A token that holds custom context of the output handlers\n *\n * @public\n */\nconst IoEventContextToken = new InjectionToken('IoEventContext');\n/**\n * A token that holds provider for custom context of the output handlers\n * which should be provided using {@link IoEventContextToken} token\n *\n * @public\n */\nconst IoEventContextProviderToken = new InjectionToken('IoEventContextProvider');\n\n/**\n * @public\n */\nconst DynamicComponentInjectorToken = new InjectionToken('DynamicComponentInjector');\n\n/**\n * @public\n */\nlet IoServiceOptions = /*#__PURE__*/(() => {\n class IoServiceOptions {\n constructor() {\n this.trackOutputChanges = false;\n }\n }\n /** @nocollapse */\n /** @nocollapse */IoServiceOptions.ɵfac = function IoServiceOptions_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || IoServiceOptions)();\n };\n IoServiceOptions.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: IoServiceOptions,\n factory: IoServiceOptions.ɵfac,\n providedIn: 'root'\n });\n return IoServiceOptions;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n/**\n * @public\n */\nlet IoService = /*#__PURE__*/(() => {\n class IoService {\n constructor(injector, differs,\n // TODO: Replace ComponentFactoryResolver once new API is created\n // @see https://github.com/angular/angular/issues/44926\n // eslint-disable-next-line deprecation/deprecation\n cfr, options, compInjector, eventArgument, cdr, eventContextProvider) {\n this.injector = injector;\n this.differs = differs;\n this.cfr = cfr;\n this.options = options;\n this.compInjector = compInjector;\n this.eventArgument = eventArgument;\n this.cdr = cdr;\n this.eventContextProvider = eventContextProvider;\n this.lastComponentInst = null;\n this.lastChangedInputs = new Set();\n this.inputsDiffer = this.differs.find({}).create();\n // TODO: Replace ComponentFactory once new API is created\n // @see https://github.com/angular/angular/issues/44926\n // eslint-disable-next-line deprecation/deprecation\n this.compFactory = null;\n this.outputsShouldDisconnect$ = new Subject();\n this.inputs = {};\n this.outputs = {};\n this.outputsChanged = () => false;\n if (this.options.trackOutputChanges) {\n const outputsDiffer = this.differs.find({}).create();\n this.outputsChanged = outputs => !!outputsDiffer.diff(outputs);\n }\n }\n get compRef() {\n return this.compInjector.componentRef;\n }\n get componentInst() {\n return this.compRef ? this.compRef.instance : null;\n }\n get componentInstChanged() {\n if (this.lastComponentInst !== this.componentInst) {\n this.lastComponentInst = this.componentInst;\n return true;\n } else {\n return false;\n }\n }\n ngOnDestroy() {\n this.disconnectOutputs();\n }\n /**\n * Call update whenever inputs/outputs may or did change.\n *\n * It will detect both new and mutated changes.\n */\n update(inputs, outputs) {\n if (!this.compRef) {\n this.disconnectOutputs();\n return;\n }\n const changes = this.updateIO(inputs, outputs);\n const compChanged = this.componentInstChanged;\n const inputsChanges = this.getInputsChanges(compChanged);\n const outputsChanged = this.outputsChanged(this.outputs);\n if (inputsChanges) {\n this.updateChangedInputs(inputsChanges);\n }\n if (compChanged || inputsChanges) {\n this.updateInputs(compChanged || !this.lastChangedInputs.size);\n }\n if (compChanged || outputsChanged || changes.outputsChanged) {\n this.bindOutputs();\n }\n }\n updateIO(inputs, outputs) {\n if (!inputs) {\n inputs = {};\n }\n if (!outputs) {\n outputs = {};\n }\n const inputsChanged = this.inputs !== inputs;\n const outputsChanged = this.outputs !== outputs;\n this.inputs = inputs;\n this.outputs = outputs;\n return {\n inputsChanged,\n outputsChanged\n };\n }\n updateInputs(isFirstChange = false) {\n if (isFirstChange) {\n this.updateCompFactory();\n }\n const compRef = this.compRef;\n const inputs = this.inputs;\n if (!inputs || !compRef) {\n return;\n }\n const ifInputChanged = this.lastChangedInputs.size ? name => this.lastChangedInputs.has(name) : () => true;\n Object.keys(inputs).filter(ifInputChanged).forEach(name => compRef.setInput(name, inputs[name]));\n }\n bindOutputs() {\n this.disconnectOutputs();\n const compInst = this.componentInst;\n let outputs = this.outputs;\n if (!outputs || !compInst) {\n return;\n }\n outputs = this.resolveOutputs(outputs);\n Object.keys(outputs).filter(p => compInst[p]).forEach(p => compInst[p].pipe(takeUntil(this.outputsShouldDisconnect$)).subscribe(event => {\n this.cdr.markForCheck();\n return outputs[p](event);\n }));\n }\n disconnectOutputs() {\n this.outputsShouldDisconnect$.next();\n }\n getInputsChanges(isCompChanged) {\n if (isCompChanged) {\n this.inputsDiffer.diff({});\n }\n return this.inputsDiffer.diff(this.inputs);\n }\n updateChangedInputs(differ) {\n this.lastChangedInputs.clear();\n const addRecordKeyToSet = record => this.lastChangedInputs.add(record.key);\n differ.forEachAddedItem(addRecordKeyToSet);\n differ.forEachChangedItem(addRecordKeyToSet);\n differ.forEachRemovedItem(addRecordKeyToSet);\n }\n // TODO: Replace ComponentFactory once new API is created\n // @see https://github.com/angular/angular/issues/44926\n // eslint-disable-next-line deprecation/deprecation\n resolveCompFactory() {\n if (!this.compRef) {\n return null;\n }\n try {\n try {\n return this.cfr.resolveComponentFactory(this.compRef.componentType);\n } catch (e) {\n // Fallback if componentType does not exist (happens on NgComponentOutlet)\n return this.cfr.resolveComponentFactory(this.compRef.instance.constructor);\n }\n } catch (e) {\n // Factory not available - bailout\n return null;\n }\n }\n updateCompFactory() {\n this.compFactory = this.resolveCompFactory();\n }\n resolveOutputs(outputs) {\n this.updateOutputsEventContext();\n outputs = this.processOutputs(outputs);\n if (!this.compFactory) {\n return outputs;\n }\n return this.remapIO(outputs, this.compFactory.outputs);\n }\n updateOutputsEventContext() {\n if (this.eventContextProvider) {\n // Resolve custom context from local provider\n const eventContextInjector = Injector.create({\n name: 'EventContext',\n parent: this.injector,\n providers: [this.eventContextProvider]\n });\n this.outputsEventContext = eventContextInjector.get(IoEventContextToken);\n } else {\n // Try to get global context\n this.outputsEventContext = this.injector.get(IoEventContextToken, null);\n }\n }\n processOutputs(outputs) {\n const processedOutputs = {};\n Object.keys(outputs).forEach(key => {\n const outputExpr = outputs[key];\n let outputHandler;\n if (typeof outputExpr === 'function') {\n outputHandler = outputExpr;\n } else {\n outputHandler = outputExpr && this.processOutputArgs(outputExpr);\n }\n if (this.outputsEventContext && outputHandler) {\n outputHandler = outputHandler.bind(this.outputsEventContext);\n }\n processedOutputs[key] = outputHandler;\n });\n return processedOutputs;\n }\n processOutputArgs(output) {\n const eventArgument = this.eventArgument;\n const args = 'args' in output ? output.args || [] : [eventArgument];\n const eventIdx = args.indexOf(eventArgument);\n const handler = output.handler;\n // When there is no event argument - use just arguments\n if (eventIdx === -1) {\n return function () {\n return handler.apply(this, args);\n };\n }\n return function (event) {\n const argsWithEvent = [...args];\n argsWithEvent[eventIdx] = event;\n return handler.apply(this, argsWithEvent);\n };\n }\n remapIO(io, mapping) {\n const newIO = {};\n Object.keys(io).forEach(key => {\n const newKey = this.findPropByTplInMapping(key, mapping) || key;\n newIO[newKey] = io[key];\n });\n return newIO;\n }\n findPropByTplInMapping(tplName, mapping) {\n for (const map of mapping) {\n if (map.templateName === tplName) {\n return map.propName;\n }\n }\n return null;\n }\n }\n /** @nocollapse */\n /** @nocollapse */IoService.ɵfac = function IoService_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || IoService)(i0.ɵɵinject(i0.Injector), i0.ɵɵinject(i0.KeyValueDiffers), i0.ɵɵinject(i0.ComponentFactoryResolver), i0.ɵɵinject(IoServiceOptions), i0.ɵɵinject(DynamicComponentInjectorToken), i0.ɵɵinject(IoEventArgumentToken), i0.ɵɵinject(i0.ChangeDetectorRef), i0.ɵɵinject(IoEventContextProviderToken, 8));\n };\n IoService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: IoService,\n factory: IoService.ɵfac\n });\n return IoService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet IoFactoryService = /*#__PURE__*/(() => {\n class IoFactoryService {\n constructor(injector) {\n this.injector = injector;\n }\n create(componentInjector, ioOptions) {\n const providers = [{\n provide: IoService,\n useClass: IoService\n }, {\n provide: DynamicComponentInjectorToken,\n useValue: componentInjector\n }];\n if (ioOptions) {\n providers.push({\n provide: IoServiceOptions,\n useValue: ioOptions\n });\n }\n const ioInjector = Injector.create({\n name: 'IoInjector',\n parent: ioOptions?.injector ?? this.injector,\n providers\n });\n return ioInjector.get(IoService);\n }\n }\n /** @nocollapse */\n /** @nocollapse */IoFactoryService.ɵfac = function IoFactoryService_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || IoFactoryService)(i0.ɵɵinject(i0.Injector));\n };\n IoFactoryService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: IoFactoryService,\n factory: IoFactoryService.ɵfac,\n providedIn: 'root'\n });\n return IoFactoryService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet ComponentOutletIoDirective = /*#__PURE__*/(() => {\n class ComponentOutletIoDirective {\n constructor(ioService) {\n this.ioService = ioService;\n }\n ngDoCheck() {\n this.ioService.update(this.ngComponentOutletNdcDynamicInputs, this.ngComponentOutletNdcDynamicOutputs);\n }\n }\n /** @nocollapse */\n /** @nocollapse */ComponentOutletIoDirective.ɵfac = function ComponentOutletIoDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ComponentOutletIoDirective)(i0.ɵɵdirectiveInject(IoService));\n };\n ComponentOutletIoDirective.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: ComponentOutletIoDirective,\n selectors: [[\"\", \"ngComponentOutletNdcDynamicInputs\", \"\"], [\"\", \"ngComponentOutletNdcDynamicOutputs\", \"\"]],\n inputs: {\n ngComponentOutletNdcDynamicInputs: \"ngComponentOutletNdcDynamicInputs\",\n ngComponentOutletNdcDynamicOutputs: \"ngComponentOutletNdcDynamicOutputs\"\n },\n exportAs: [\"ndcDynamicIo\"],\n standalone: true,\n features: [i0.ɵɵProvidersFeature([IoService])]\n });\n return ComponentOutletIoDirective;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet ComponentOutletInjectorDirective = /*#__PURE__*/(() => {\n class ComponentOutletInjectorDirective {\n constructor(componentOutlet) {\n this.componentOutlet = componentOutlet;\n }\n get componentRef() {\n // NOTE: Accessing private APIs of Angular\n return this.componentOutlet._componentRef;\n }\n }\n /** @nocollapse */\n /** @nocollapse */ComponentOutletInjectorDirective.ɵfac = function ComponentOutletInjectorDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ComponentOutletInjectorDirective)(i0.ɵɵdirectiveInject(i1.NgComponentOutlet, 1));\n };\n ComponentOutletInjectorDirective.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: ComponentOutletInjectorDirective,\n selectors: [[\"\", \"ngComponentOutlet\", \"\"]],\n exportAs: [\"ndcComponentOutletInjector\"],\n standalone: true,\n features: [i0.ɵɵProvidersFeature([{\n provide: DynamicComponentInjectorToken,\n useExisting: ComponentOutletInjectorDirective\n }])]\n });\n return ComponentOutletInjectorDirective;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet ComponentOutletInjectorModule = /*#__PURE__*/(() => {\n class ComponentOutletInjectorModule {}\n /** @nocollapse */\n /** @nocollapse */\n /** @nocollapse */ComponentOutletInjectorModule.ɵfac = function ComponentOutletInjectorModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ComponentOutletInjectorModule)();\n };\n ComponentOutletInjectorModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: ComponentOutletInjectorModule\n });\n ComponentOutletInjectorModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({});\n return ComponentOutletInjectorModule;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicIoDirective = /*#__PURE__*/(() => {\n class DynamicIoDirective {\n constructor(ioService) {\n this.ioService = ioService;\n }\n ngDoCheck() {\n this.ioService.update(this.ndcDynamicInputs, this.ndcDynamicOutputs);\n }\n }\n /** @nocollapse */\n /** @nocollapse */DynamicIoDirective.ɵfac = function DynamicIoDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicIoDirective)(i0.ɵɵdirectiveInject(IoService));\n };\n DynamicIoDirective.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: DynamicIoDirective,\n selectors: [[\"\", \"ndcDynamicInputs\", \"\"], [\"\", \"ndcDynamicOutputs\", \"\"]],\n inputs: {\n ndcDynamicInputs: \"ndcDynamicInputs\",\n ndcDynamicOutputs: \"ndcDynamicOutputs\"\n },\n exportAs: [\"ndcDynamicIo\"],\n standalone: true,\n features: [i0.ɵɵProvidersFeature([IoService])]\n });\n return DynamicIoDirective;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicIoModule = /*#__PURE__*/(() => {\n class DynamicIoModule {}\n /** @nocollapse */\n /** @nocollapse */\n /** @nocollapse */DynamicIoModule.ɵfac = function DynamicIoModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicIoModule)();\n };\n DynamicIoModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: DynamicIoModule\n });\n DynamicIoModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [ComponentOutletInjectorModule]\n });\n return DynamicIoModule;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicComponent = /*#__PURE__*/(() => {\n class DynamicComponent {\n constructor(vcr) {\n this.vcr = vcr;\n this.ndcDynamicCreated = new EventEmitter();\n this.componentRef = null;\n }\n ngOnChanges(changes) {\n if (DynamicComponent.UpdateOnInputs.some(input => changes.hasOwnProperty(input))) {\n this.createDynamicComponent();\n }\n }\n createDynamicComponent() {\n this.vcr.clear();\n this.componentRef = null;\n if (this.ndcDynamicComponent) {\n this.componentRef = this.vcr.createComponent(this.ndcDynamicComponent, {\n index: 0,\n injector: this._resolveInjector(),\n projectableNodes: this.ndcDynamicContent,\n ngModuleRef: this.ndcDynamicNgModuleRef,\n environmentInjector: this.ndcDynamicEnvironmentInjector\n });\n this.ndcDynamicCreated.emit(this.componentRef);\n }\n }\n _resolveInjector() {\n let injector = this.ndcDynamicInjector || this.vcr.injector;\n if (this.ndcDynamicProviders) {\n injector = Injector.create({\n providers: this.ndcDynamicProviders,\n parent: injector\n });\n }\n return injector;\n }\n }\n DynamicComponent.UpdateOnInputs = ['ndcDynamicComponent', 'ndcDynamicInjector', 'ndcDynamicProviders', 'ndcDynamicContent', 'ndcDynamicNgModuleRef', 'ndcDynamicEnvironmentInjector'];\n /** @nocollapse */\n /** @nocollapse */\n DynamicComponent.ɵfac = function DynamicComponent_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicComponent)(i0.ɵɵdirectiveInject(i0.ViewContainerRef));\n };\n DynamicComponent.ɵcmp = /* @__PURE__ */i0.ɵɵdefineComponent({\n type: DynamicComponent,\n selectors: [[\"ndc-dynamic\"]],\n inputs: {\n ndcDynamicComponent: \"ndcDynamicComponent\",\n ndcDynamicInjector: \"ndcDynamicInjector\",\n ndcDynamicProviders: \"ndcDynamicProviders\",\n ndcDynamicContent: \"ndcDynamicContent\",\n ndcDynamicNgModuleRef: \"ndcDynamicNgModuleRef\",\n ndcDynamicEnvironmentInjector: \"ndcDynamicEnvironmentInjector\"\n },\n outputs: {\n ndcDynamicCreated: \"ndcDynamicCreated\"\n },\n standalone: true,\n features: [i0.ɵɵProvidersFeature([{\n provide: DynamicComponentInjectorToken,\n useExisting: DynamicComponent\n }]), i0.ɵɵNgOnChangesFeature, i0.ɵɵStandaloneFeature],\n decls: 0,\n vars: 0,\n template: function DynamicComponent_Template(rf, ctx) {},\n encapsulation: 2\n });\n return DynamicComponent;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicModule = /*#__PURE__*/(() => {\n class DynamicModule {}\n /** @nocollapse */\n /** @nocollapse */\n /** @nocollapse */DynamicModule.ɵfac = function DynamicModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicModule)();\n };\n DynamicModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: DynamicModule\n });\n DynamicModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [DynamicIoModule, DynamicComponent, DynamicIoModule]\n });\n return DynamicModule;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicAttributesDirective = /*#__PURE__*/(() => {\n class DynamicAttributesDirective {\n constructor(renderer, differs, componentInjector) {\n this.renderer = renderer;\n this.differs = differs;\n this.componentInjector = componentInjector;\n this.attrsDiffer = this.differs.find({}).create();\n }\n get _attributes() {\n return this.ndcDynamicAttributes || this.ngComponentOutletNdcDynamicAttributes || {};\n }\n get nativeElement() {\n return this.componentInjector?.componentRef?.location.nativeElement;\n }\n get compType() {\n return this.componentInjector?.componentRef?.componentType;\n }\n get isCompChanged() {\n if (this.lastCompType !== this.compType) {\n this.lastCompType = this.compType;\n return true;\n }\n return false;\n }\n ngDoCheck() {\n const isCompChanged = this.isCompChanged;\n const changes = this.attrsDiffer.diff(this._attributes);\n if (changes) {\n this.lastAttrActions = this.changesToAttrActions(changes);\n }\n if (changes || isCompChanged && this.lastAttrActions) {\n this.updateAttributes(this.lastAttrActions);\n }\n }\n setAttribute(name, value, namespace) {\n if (this.nativeElement) {\n this.renderer.setAttribute(this.nativeElement, name, value, namespace);\n }\n }\n removeAttribute(name, namespace) {\n if (this.nativeElement) {\n this.renderer.removeAttribute(this.nativeElement, name, namespace);\n }\n }\n updateAttributes(actions) {\n if (!this.compType || !actions) {\n return;\n }\n Object.keys(actions.set).forEach(key => this.setAttribute(key, actions.set[key]));\n actions.remove.forEach(key => this.removeAttribute(key));\n }\n changesToAttrActions(changes) {\n const attrActions = {\n set: {},\n remove: []\n };\n changes.forEachAddedItem(r => attrActions.set[r.key] = r.currentValue);\n changes.forEachChangedItem(r => attrActions.set[r.key] = r.currentValue);\n changes.forEachRemovedItem(r => attrActions.remove.push(r.key));\n return attrActions;\n }\n }\n /** @nocollapse */\n /** @nocollapse */DynamicAttributesDirective.ɵfac = function DynamicAttributesDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicAttributesDirective)(i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.KeyValueDiffers), i0.ɵɵdirectiveInject(DynamicComponentInjectorToken, 8));\n };\n DynamicAttributesDirective.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: DynamicAttributesDirective,\n selectors: [[\"\", \"ndcDynamicAttributes\", \"\"], [\"\", \"ngComponentOutletNdcDynamicAttributes\", \"\"]],\n inputs: {\n ndcDynamicAttributes: \"ndcDynamicAttributes\",\n ngComponentOutletNdcDynamicAttributes: \"ngComponentOutletNdcDynamicAttributes\"\n },\n exportAs: [\"ndcDynamicAttributes\"],\n standalone: true\n });\n return DynamicAttributesDirective;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicAttributesModule = /*#__PURE__*/(() => {\n class DynamicAttributesModule {}\n /** @nocollapse */\n /** @nocollapse */\n /** @nocollapse */DynamicAttributesModule.ɵfac = function DynamicAttributesModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicAttributesModule)();\n };\n DynamicAttributesModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: DynamicAttributesModule\n });\n DynamicAttributesModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [ComponentOutletInjectorModule]\n });\n return DynamicAttributesModule;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * Extract type arguments from Angular Directive/Component\n *\n * @internal\n */\nfunction extractNgParamTypes(type) {\n // NOTE: Accessing private APIs of Angular\n return type?.ctorParameters?.()?.map(param => param.type);\n}\n/**\n * @internal\n */\nfunction isOnDestroy(obj) {\n return !!obj && typeof obj.ngOnDestroy === 'function';\n}\n\n/**\n * @public\n */\nconst ReflectRef = new InjectionToken('ReflectRef', {\n providedIn: 'root',\n factory: () => window.Reflect\n});\n/**\n * @public\n */\nlet ReflectService = /*#__PURE__*/(() => {\n class ReflectService {\n constructor(reflect) {\n this.reflect = reflect;\n }\n getCtorParamTypes(ctor) {\n return this.reflect.getMetadata('design:paramtypes', ctor);\n }\n }\n /** @nocollapse */\n /** @nocollapse */ReflectService.ɵfac = function ReflectService_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ReflectService)(i0.ɵɵinject(ReflectRef));\n };\n ReflectService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ReflectService,\n factory: ReflectService.ɵfac,\n providedIn: 'root'\n });\n return ReflectService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nfunction dynamicDirectiveDef(type, inputs, outputs) {\n return {\n type,\n inputs,\n outputs\n };\n}\n/**\n * @public\n * @experimental Dynamic directives is an experimental API that may not work as expected.\n *\n * NOTE: There is a known issue with OnChanges hook not beign triggered on dynamic directives\n * since this part of functionality has been removed from the core as Angular now\n * supports this out of the box for dynamic components.\n */\nlet DynamicDirectivesDirective = /*#__PURE__*/(() => {\n class DynamicDirectivesDirective {\n constructor(injector, iterableDiffers, ioFactoryService, reflectService, componentInjector) {\n this.injector = injector;\n this.iterableDiffers = iterableDiffers;\n this.ioFactoryService = ioFactoryService;\n this.reflectService = reflectService;\n this.componentInjector = componentInjector;\n this.ndcDynamicDirectivesCreated = new EventEmitter();\n this.dirRef = new Map();\n this.dirIo = new Map();\n this.dirsDiffer = this.iterableDiffers.find([]).create((_, def) => def.type);\n }\n get directives() {\n return this.ndcDynamicDirectives || this.ngComponentOutletNdcDynamicDirectives;\n }\n get componentRef() {\n return this.componentInjector?.componentRef;\n }\n get compInstance() {\n return this.componentRef && this.componentRef.instance;\n }\n get isCompChanged() {\n if (this.lastCompInstance !== this.compInstance) {\n this.lastCompInstance = this.compInstance;\n return true;\n }\n return false;\n }\n get hostInjector() {\n return this.componentRef?.injector;\n }\n ngDoCheck() {\n if (this.maybeDestroyDirectives()) {\n return;\n }\n const dirsChanges = this.dirsDiffer.diff(this.directives);\n if (!dirsChanges) {\n return this.updateDirectives();\n }\n this.processDirChanges(dirsChanges);\n }\n ngOnDestroy() {\n this.destroyAllDirectives();\n }\n maybeDestroyDirectives() {\n if (this.isCompChanged || !this.componentRef) {\n this.dirsDiffer.diff([]);\n this.destroyAllDirectives();\n }\n return !this.componentRef;\n }\n processDirChanges(changes) {\n changes.forEachRemovedItem(({\n item\n }) => this.destroyDirective(item));\n const createdDirs = [];\n changes.forEachAddedItem(({\n item\n }) => {\n const dirRef = this.initDirective(item);\n if (dirRef) {\n createdDirs.push(dirRef);\n }\n });\n if (createdDirs.length) {\n this.ndcDynamicDirectivesCreated.emit(createdDirs);\n }\n }\n updateDirectives() {\n this.directives?.forEach(dir => this.updateDirective(dir));\n }\n updateDirective(dirDef) {\n const io = this.dirIo.get(dirDef.type);\n io?.update(dirDef.inputs, dirDef.outputs);\n }\n initDirective(dirDef) {\n if (this.dirRef.has(dirDef.type)) {\n return;\n }\n const instance = this.createDirective(dirDef.type);\n const directiveRef = {\n instance,\n type: dirDef.type,\n injector: this.hostInjector,\n hostComponent: this.componentRef.instance,\n hostView: this.componentRef.hostView,\n location: this.componentRef.location,\n changeDetectorRef: this.componentRef.changeDetectorRef,\n onDestroy: this.componentRef.onDestroy\n };\n this.initDirIO(directiveRef, dirDef);\n this.callInitHooks(instance);\n this.dirRef.set(directiveRef.type, directiveRef);\n return directiveRef;\n }\n destroyAllDirectives() {\n this.dirRef.forEach(dir => this.destroyDirRef(dir));\n this.dirRef.clear();\n this.dirIo.clear();\n }\n destroyDirective(dirDef) {\n const dirRef = this.dirRef.get(dirDef.type);\n if (dirRef) {\n this.destroyDirRef(dirRef);\n }\n this.dirRef.delete(dirDef.type);\n this.dirIo.delete(dirDef.type);\n }\n initDirIO(dirRef, dirDef) {\n const io = this.ioFactoryService.create({\n componentRef: this.dirToCompDef(dirRef)\n }, {\n trackOutputChanges: true,\n injector: this.injector\n });\n io.update(dirDef.inputs, dirDef.outputs);\n this.dirIo.set(dirRef.type, io);\n }\n dirToCompDef(dirRef) {\n return {\n changeDetectorRef: this.componentRef.changeDetectorRef,\n hostView: this.componentRef.hostView,\n location: this.componentRef.location,\n destroy: this.componentRef.destroy,\n onDestroy: this.componentRef.onDestroy,\n injector: this.componentRef.injector,\n instance: dirRef.instance,\n componentType: dirRef.type,\n setInput: (name, value) => dirRef.instance[name] = value\n };\n }\n destroyDirRef(dirRef) {\n this.dirIo.get(dirRef.type)?.ngOnDestroy();\n if (isOnDestroy(dirRef.instance)) {\n dirRef.instance.ngOnDestroy();\n }\n }\n createDirective(dirType) {\n const directiveInjector = Injector.create({\n providers: [{\n provide: dirType,\n useClass: dirType,\n deps: this.resolveDirParamTypes(dirType)\n }, {\n provide: ElementRef,\n useValue: this.componentRef.location\n }],\n parent: this.hostInjector,\n name: `DynamicDirectiveInjector:${dirType.name}@${this.componentRef.componentType.name}`\n });\n return directiveInjector.get(dirType);\n }\n resolveDirParamTypes(dirType) {\n return (\n // First try Angular Compiler's metadata\n extractNgParamTypes(dirType) ??\n // Then fallback to Reflect API\n this.reflectService.getCtorParamTypes(dirType) ??\n // Bailout\n []\n );\n }\n callInitHooks(obj) {\n this.callHook(obj, 'ngOnInit');\n this.callHook(obj, 'ngDoCheck');\n this.callHook(obj, 'ngAfterContentInit');\n this.callHook(obj, 'ngAfterContentChecked');\n this.callHook(obj, 'ngAfterViewInit');\n this.callHook(obj, 'ngAfterViewChecked');\n }\n callHook(obj, hook, args = []) {\n if (obj[hook]) {\n obj[hook](...args);\n }\n }\n }\n /** @nocollapse */\n /** @nocollapse */DynamicDirectivesDirective.ɵfac = function DynamicDirectivesDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicDirectivesDirective)(i0.ɵɵdirectiveInject(i0.Injector), i0.ɵɵdirectiveInject(i0.IterableDiffers), i0.ɵɵdirectiveInject(IoFactoryService), i0.ɵɵdirectiveInject(ReflectService), i0.ɵɵdirectiveInject(DynamicComponentInjectorToken, 8));\n };\n DynamicDirectivesDirective.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: DynamicDirectivesDirective,\n selectors: [[\"\", \"ndcDynamicDirectives\", \"\"], [\"\", \"ngComponentOutletNdcDynamicDirectives\", \"\"]],\n inputs: {\n ndcDynamicDirectives: \"ndcDynamicDirectives\",\n ngComponentOutletNdcDynamicDirectives: \"ngComponentOutletNdcDynamicDirectives\"\n },\n outputs: {\n ndcDynamicDirectivesCreated: \"ndcDynamicDirectivesCreated\"\n },\n standalone: true,\n features: [i0.ɵɵProvidersFeature([IoFactoryService])]\n });\n return DynamicDirectivesDirective;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * @public\n */\nlet DynamicDirectivesModule = /*#__PURE__*/(() => {\n class DynamicDirectivesModule {}\n /** @nocollapse */\n /** @nocollapse */\n /** @nocollapse */DynamicDirectivesModule.ɵfac = function DynamicDirectivesModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DynamicDirectivesModule)();\n };\n DynamicDirectivesModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: DynamicDirectivesModule\n });\n DynamicDirectivesModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [ComponentOutletInjectorModule]\n });\n return DynamicDirectivesModule;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/*\n * Public API Surface of ng-dynamic-component\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { ComponentOutletInjectorDirective, ComponentOutletInjectorModule, ComponentOutletIoDirective, DynamicAttributesDirective, DynamicAttributesModule, DynamicComponent, DynamicComponentInjectorToken, DynamicDirectivesDirective, DynamicDirectivesModule, DynamicIoDirective, DynamicIoModule, DynamicModule, EventArgumentToken, IoEventArgumentToken, IoEventContextProviderToken, IoEventContextToken, IoFactoryService, IoService, IoServiceOptions, ReflectRef, ReflectService, defaultEventArgumentFactory, dynamicDirectiveDef };\n"],"names":["defaultEventArgumentFactory","IoEventArgumentToken","InjectionToken","IoEventContextToken","InjectionToken","IoEventContextProviderToken","DynamicComponentInjectorToken","IoServiceOptions","__ngFactoryType__","ɵɵdefineInjectable","IoService","injector","differs","cfr","options","compInjector","eventArgument","cdr","eventContextProvider","Subject","outputsDiffer","outputs","inputs","changes","compChanged","inputsChanges","outputsChanged","inputsChanged","isFirstChange","compRef","ifInputChanged","name","compInst","p","takeUntil","event","isCompChanged","differ","addRecordKeyToSet","record","eventContextInjector","Injector","processedOutputs","key","outputExpr","outputHandler","output","args","eventIdx","handler","argsWithEvent","io","mapping","newIO","newKey","tplName","map","ɵɵinject","KeyValueDiffers","ComponentFactoryResolver$1","IoEventArgumentToken","ChangeDetectorRef","ComponentOutletInjectorModule","__ngFactoryType__","ɵɵdefineNgModule","ɵɵdefineInjector","DynamicIoDirective","ioService","ɵɵdirectiveInject","IoService","ɵɵdefineDirective","ɵɵProvidersFeature","DynamicIoModule","DynamicComponent","vcr","EventEmitter","changes","input","injector","Injector","ViewContainerRef","ɵɵdefineComponent","DynamicComponentInjectorToken","ɵɵNgOnChangesFeature","ɵɵStandaloneFeature","rf","ctx","DynamicModule","ReflectRef","InjectionToken"],"mappings":";;wLASA,SAASA,GAA8B,CACrC,MAAO,QACT,CAIA,IAAMC,EAAuB,IAAIC,EAAe,gBAAiB,CAC/D,WAAY,OACZ,QAASF,CACX,CAAC,EAYD,IAAMG,EAAsB,IAAIC,EAAe,gBAAgB,EAOzDC,EAA8B,IAAID,EAAe,wBAAwB,EAKzEE,EAAgC,IAAIF,EAAe,0BAA0B,EAK/EG,GAAiC,IAAM,CACzC,MAAMA,CAAiB,CACrB,aAAc,CACZ,KAAK,mBAAqB,EAC5B,CACF,CAEkB,OAAAA,EAAiB,UAAO,SAAkCC,EAAmB,CAC7F,OAAO,IAAKA,GAAqBD,EACnC,EACAA,EAAiB,WAA0BE,EAAmB,CAC5D,MAAOF,EACP,QAASA,EAAiB,UAC1B,WAAY,MACd,CAAC,EACMA,CACT,GAAG,EAOCG,GAA0B,IAAM,CAClC,MAAMA,CAAU,CACd,YAAYC,EAAUC,EAItBC,EAAKC,EAASC,EAAcC,EAAeC,EAAKC,EAAsB,CAoBpE,GAnBA,KAAK,SAAWP,EAChB,KAAK,QAAUC,EACf,KAAK,IAAMC,EACX,KAAK,QAAUC,EACf,KAAK,aAAeC,EACpB,KAAK,cAAgBC,EACrB,KAAK,IAAMC,EACX,KAAK,qBAAuBC,EAC5B,KAAK,kBAAoB,KACzB,KAAK,kBAAoB,IAAI,IAC7B,KAAK,aAAe,KAAK,QAAQ,KAAK,CAAC,CAAC,EAAE,OAAO,EAIjD,KAAK,YAAc,KACnB,KAAK,yBAA2B,IAAIC,EACpC,KAAK,OAAS,CAAC,EACf,KAAK,QAAU,CAAC,EAChB,KAAK,eAAiB,IAAM,GACxB,KAAK,QAAQ,mBAAoB,CACnC,IAAMC,EAAgB,KAAK,QAAQ,K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