fg-dynamic-component 1.1.1 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +107 -11
- package/fesm2022/fg-dynamic-component.mjs +1671 -408
- package/fesm2022/fg-dynamic-component.mjs.map +1 -1
- package/package.json +10 -11
- package/types/fg-dynamic-component.d.ts +216 -0
- package/esm2022/fg-dynamic-component.mjs +0 -5
- package/esm2022/lib/fg-dynamic.component.mjs +0 -404
- package/esm2022/public-api.mjs +0 -5
- package/index.d.ts +0 -5
- package/lib/fg-dynamic.component.d.ts +0 -114
- package/public-api.d.ts +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fg-dynamic-component.mjs","sources":["../../../projects/fg-dynamic-component/src/lib/fg-dynamic.component.ts","../../../projects/fg-dynamic-component/src/public-api.ts","../../../projects/fg-dynamic-component/src/fg-dynamic-component.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, ComponentRef, ElementRef, EventEmitter, Injector, InputSignal, ModelSignal, OnChanges, OnDestroy, Renderer2, Signal, Type, ViewContainerRef, inject, input, model, viewChild, viewChildren } from '@angular/core';\nimport { ControlValueAccessor, FormControl, FormControlDirective, FormGroup, NG_VALUE_ACCESSOR, NgControl, ValidatorFn, Validators } from '@angular/forms';\nimport { Subscription } from 'rxjs';\n\nexport interface FGDynamicItem {\n type?: string | Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>);\n inputs?: Record<string, string | unknown>;\n outputs?: Record<string, string | Function>;\n attributes?: Record<string, string | unknown>;\n items?: FGDynamicItem[];\n}\n\n/**\n * Declare components to dynamically load in static and/or dynamic way using the FGDynamicService.\n */\nexport class FGDynamicService {\n private static _components: Record<string, Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>)> = {};\n\n static registerComponent(name: string, type: Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>)): void {\n if (name && type) {\n FGDynamicService._components[name] = type;\n }\n }\n\n static getComponent(name: string): Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>) {\n return FGDynamicService._components[name];\n }\n}\n\n/**\n * Create a standalone signals based dynamic components tree through a JSON configuration with full\n * life-cycle support for inputs, outputs, attributes, reactive forms and expressions binding evaluation.\n */\n@Component({\n\tselector: 'fg-dynamic',\n\ttemplate: `\n <ng-container #viewContainer></ng-container>\n @for (item of configuration()?.items; track $index) {\n <fg-dynamic #dynamicItem [configuration]=\"item\" [(viewModel)]=\"viewModel\" [formGroup]=\"formGroup()\" />\n }\n `,\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\tstandalone: true\n})\nexport class FGDynamicComponent implements OnChanges, OnDestroy {\n\tconfiguration: InputSignal<FGDynamicItem> = input.required<FGDynamicItem>();\n\tviewModel: ModelSignal<unknown> = model<unknown>();\n\tformGroup: InputSignal<FormGroup> = input<FormGroup>();\n\n\tprivate _viewContainerRef: Signal<ViewContainerRef> = viewChild.required('viewContainer', {\n read: ViewContainerRef\n });\n private _dynamicItems: Signal<readonly ElementRef<unknown>[]> = viewChildren('dynamicItem', {\n read: ElementRef\n });\n\tprivate _componentRef: ComponentRef<unknown>;\n private _elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n private _renderer: Renderer2 = inject(Renderer2);\n private _outputsSubscriptions: Subscription[] = [];\n private _formControl: FormControl;\n private _formControlDirective: FormControlDirective;\n private _formControlSubscription: Subscription;\n private _component: Type<unknown>;\n private _injector: Injector = inject(Injector);\n\n /**\n * A callback method that is invoked immediately after the default change\n * detector has checked data-bound properties if at least one has changed,\n * and before the view and content children are checked.\n */\n async ngOnChanges(): Promise<void> {\n // Lazy-load a component.\n await this.loadComponentAsync();\n // Instantiates a single component and inserts its host view into this container.\n this.createComponent();\n // Remove the fg-dynamic tag.\n this.removeHostElement();\n // Updates specified input names to new values.\n this.setInputs();\n // Disables/enables the control.\n this.setFormControlStatus();\n // Add synchronous validators to this control.\n this.setFormControlValidators();\n // Set attribute values for an element in the DOM.\n this.setAttributes();\n }\n\n /**\n * A method to lazy-load a component.\n */\n private async loadComponentAsync(): Promise<void> {\n if (this.configuration().type != null && !this._component) {\n let type: Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>);\n\n if (typeof(this.configuration().type) === 'string') {\n type = FGDynamicService.getComponent(this.configuration().type as string);\n } else {\n type = this.configuration().type as Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>);\n }\n\n try {\n type = (type as () => Promise<Type<unknown>>)();\n } catch {\n type = type;\n } finally {\n if (type instanceof Promise) {\n this._component = await type;\n } else {\n this._component = type as Type<unknown>;\n }\n }\n }\n }\n\n /**\n * Instantiates a single component and inserts its host view into this container.\n */\n private createComponent(): void {\n if (this._component && !this._componentRef && this._viewContainerRef() && !this._formControlDirective) {\n let injector: Injector;\n\n if (this.formGroup() && this.configuration()?.attributes && this.configuration().attributes['name'] && typeof(this.evaluateExpression(this.configuration().attributes['name'], this.viewModel)) === 'string' && this.viewModel()) {\n // Synchronizes a standalone FormControl instance to a form control element.\n this._formControlDirective = new FormControlDirective(null, null, null, null);\n\n // Creates a new injector instance that provides one or more dependencies, according to a given type or types of StaticProvider.\n injector = Injector.create({\n providers: [{\n provide: NgControl,\n useValue: this._formControlDirective\n }],\n parent: this._injector\n });\n }\n\n // Instantiates a single component and inserts its host view into this container.\n this._componentRef = this._viewContainerRef().createComponent(this._component, {\n projectableNodes: this._dynamicItems()?.length > 0 ? [this._dynamicItems().map((e: ElementRef<unknown>): Node => e.nativeElement as Node)] : undefined,\n injector: injector\n });\n\n // When a view uses the ChangeDetectionStrategy#OnPush (checkOnce) change detection strategy, explicitly marks the view as changed so that it can be checked again.\n // Components are normally marked as dirty (in need of rerendering) when inputs have changed or events have fired in the view.\n // Call this method to ensure that a component is checked even if these triggers have not occurred.\n if (this._componentRef?.changeDetectorRef) {\n this._componentRef.changeDetectorRef.markForCheck();\n }\n\n // Register handlers for those events by subscribing to an instance.\n this.handleOutputs();\n // Construct a FormControl with an initial value.\n this.createFormControl();\n }\n }\n\n /**\n * A method to remove the fg-dynamic tag.\n */\n private removeHostElement(): void {\n if (this._elementRef?.nativeElement?.parentElement) {\n const nativeElement: HTMLElement = this._elementRef.nativeElement;\n const parentElement: HTMLElement = nativeElement.parentElement;\n\n // Move all children out of the element\n while (nativeElement.firstChild) {\n parentElement.insertBefore(nativeElement.firstChild, nativeElement);\n }\n\n // Remove the empty element (the host)\n parentElement.removeChild(nativeElement);\n }\n }\n\n /**\n * Register handlers for those events by subscribing to an instance.\n */\n private handleOutputs(): void {\n if (this.configuration()?.outputs && Object.keys(this.configuration().outputs).length > 0 && this._componentRef?.instance) {\n for (const outputName in this.configuration().outputs) {\n if (this._componentRef.instance[outputName] instanceof EventEmitter) {\n this._outputsSubscriptions.push(this._componentRef.instance[outputName].subscribe(($event: unknown): void => {\n // Evaluates JavaScript code and executes it.\n const result: unknown = this.evaluateExpression(this.configuration().outputs[outputName], this.viewModel, $event);\n\n if (result instanceof Function) {\n // Executes a function.\n result($event);\n }\n }));\n }\n }\n }\n }\n\n /**\n * Construct a FormControl with an initial value.\n */\n private createFormControl(): void {\n if (this.formGroup() && this.configuration()?.attributes && this.configuration().attributes['name'] && this.viewModel()) {\n // Evaluates JavaScript code and executes it.\n const name = this.evaluateExpression(this.configuration().attributes['name'], this.viewModel) as string;\n\n if (typeof(name) === 'string') {\n // Construct a FormControl with an initial value.\n this._formControl = new FormControl(this.getModelPropertyValue(this.viewModel(), name, null));\n\n // Add a control to this group. In a strongly-typed group, the control must be in the group's type (possibly as an optional key).\n // If a control with a given name already exists, it would not be replaced with a new one.\n // If you want to replace an existing control, use the FormGroup#setControl setControl method instead.\n // This method also updates the value and validity of the control.\n this.formGroup().addControl(name, this._formControl);\n\n // A multicasting observable that emits an event every time the value of the control changes, in the UI or programmatically.\n this._formControlSubscription = this._formControl.valueChanges.subscribe((value: unknown): void => {\n // Creates a deep clone of an object.\n const viewModel: unknown = structuredClone(this.viewModel());\n\n // Sets the value at path of object.\n // If a portion of path doesn't exist, it's created.\n // Arrays are created for missing index properties while objects are created for all other missing properties.\n // This method mutates object.\n this.setModelPropertyValue(viewModel, name, value);\n // Directly set the signal to a new value, and notify any dependents.\n this.viewModel.set(viewModel);\n });\n\n // Synchronizes a standalone FormControl instance to a form control element.\n this.attachFormControlDirective();\n }\n }\n }\n\n /**\n * Disables/enables the control.\n */\n private setFormControlStatus(): void {\n if (this._formControl && this.configuration().attributes && this.configuration().attributes['disabled'] != null) {\n // Evaluates JavaScript code and executes it.\n const isDisabled: boolean = this.evaluateExpression(this.configuration().attributes['disabled'], this.viewModel) as boolean;\n\n if (typeof(isDisabled) === 'boolean' && ((isDisabled && this._formControl.enabled) || (!isDisabled && this._formControl.disabled))) {\n if (isDisabled) {\n // Disables the control.\n this._formControl.disable({\n onlySelf: true,\n emitEvent: false\n });\n } else {\n // Enables the control.\n this._formControl.enable({\n onlySelf: true,\n emitEvent: false\n });\n }\n }\n }\n }\n\n /**\n * Add synchronous validators to this control.\n */\n private setFormControlValidators(): void {\n if (this._formControl && this.configuration()?.attributes && Object.keys(this.configuration().attributes).length > 0 && this._componentRef?.location?.nativeElement) {\n const validators: ValidatorFn[] = [];\n // Validator that requires the control's value to be greater than or equal to the provided number.\n const min = this.evaluateExpression(this.configuration().attributes['min'], this.viewModel) as number;\n\n if (typeof(min) === 'number' && min.toString() !== this._componentRef.location.nativeElement.getAttribute('min')) {\n validators.push(Validators.min(min));\n }\n\n // Validator that requires the control's value to be less than or equal to the provided number.\n const max = this.evaluateExpression(this.configuration().attributes['max'], this.viewModel) as number;\n\n if (typeof(max) === 'number' && max.toString() !== this._componentRef.location.nativeElement.getAttribute('max')) {\n validators.push(Validators.max(max));\n }\n\n // Validator that requires the control have a non-empty value.\n const required = this.evaluateExpression(this.configuration().attributes['required'], this.viewModel) as boolean;\n\n if (required === true && required.toString() !== this._componentRef.location.nativeElement.getAttribute('required')) {\n validators.push(Validators.required);\n }\n\n // Validator that requires the control's value pass an email validation test.\n const email = this.evaluateExpression(this.configuration().attributes['email'], this.viewModel) as boolean;\n\n if (email === true && email.toString() !== this._componentRef.location.nativeElement.getAttribute('email')) {\n validators.push(Validators.email);\n }\n\n // Validator that requires the length of the control's value to be less than or equal to the provided maximum length.\n const maxLength = this.evaluateExpression(this.configuration().attributes['maxlength'], this.viewModel) as number;\n\n if (maxLength > 0 && maxLength.toString() !== this._componentRef.location.nativeElement.getAttribute('maxlength')) {\n validators.push(Validators.maxLength(maxLength));\n }\n\n // Validator that requires the length of the control's value to be greater than or equal to the provided minimum length.\n const minLength = this.evaluateExpression(this.configuration().attributes['minlength'], this.viewModel) as number;\n\n if (minLength > 0 && minLength.toString() !== this._componentRef.location.nativeElement.getAttribute('minlength')) {\n validators.push(Validators.minLength(minLength));\n }\n\n // Validator that requires the control's value to match a regex pattern.\n const pattern = this.evaluateExpression(this.configuration().attributes['pattern'], this.viewModel) as string;\n\n if (typeof(pattern) === 'string' && pattern !== this._componentRef.location.nativeElement.getAttribute('pattern')) {\n validators.push(Validators.pattern(pattern));\n }\n\n if (validators.length > 0) {\n // Empties out the synchronous validator list.\n this._formControl.clearValidators();\n // Add a synchronous validator or validators to this control, without affecting other validators.\n this._formControl.addValidators(validators);\n // Recalculates the value and validation status of the control.\n this._formControl.updateValueAndValidity({\n onlySelf: true,\n emitEvent: false\n });\n }\n }\n }\n\n /**\n * Synchronizes a standalone FormControl instance to a form control element.\n */\n private attachFormControlDirective(): void {\n if (this._formControlDirective && this._componentRef?.injector && this._formControl) {\n this._formControlDirective.valueAccessor = this._componentRef.injector.get<ControlValueAccessor[]>(NG_VALUE_ACCESSOR, null)?.find((_: ControlValueAccessor): true => true);\n this._formControlDirective.form = this._formControl;\n\n // A callback method that is invoked immediately after the default change detector has checked data-bound properties if at least one has changed, and before the view and content children are checked.\n this._formControlDirective.ngOnChanges({\n form: {\n firstChange: true,\n currentValue: this._formControl,\n previousValue: undefined,\n isFirstChange: (): true => true\n }\n });\n }\n }\n\n /**\n * Gets the value at path of object. If the resolved value is undefined, the defaultValue is returned in its place.\n * @param model The object.\n * @param property The path.\n * @param defaultValue The resolved value.\n */\n private getModelPropertyValue(model: unknown, property: Array<string> | string, defaultValue: unknown): unknown {\n // If path is not defined or it has false value\n if (!property) {\n return undefined\n }\n\n // Check if path is string or array. Regex : ensure that we do not have '.' and brackets.\n const pathArray: string[] = Array.isArray(property) ? property : property.match(/([^[.\\]])+/g);\n // Find value\n const result: unknown = pathArray.reduce((prevObj: unknown, key: string): unknown => prevObj && prevObj[key], model);\n\n // If found value is undefined return default value; otherwise return the value\n return result != null ? result : defaultValue\n }\n\n /**\n * Sets the value at path of object. If a portion of path doesn't exist, it's created.\n * Arrays are created for missing index properties while objects are created for all other missing properties.\n * This method mutates object.\n * @param model The object.\n * @param property The path.\n * @param value The value.\n */\n private setModelPropertyValue(model: unknown, property: Array<string> | string, value: unknown): void {\n const pathArray: string[] = Array.isArray(property) ? property : property.match(/([^[.\\]])+/g);\n\n pathArray.reduce((acc: unknown, key: string, i: number): unknown => {\n if (acc[key] === undefined) {\n acc[key] = {};\n }\n\n if (i === pathArray.length - 1) {\n acc[key] = value;\n }\n\n return acc[key]\n }, model);\n }\n\n /**\n * Updates specified input names to new values.\n */\n private setInputs(): void {\n if (this.configuration()?.inputs && Object.keys(this.configuration().inputs).length > 0 && this._componentRef) {\n for (const inputName in this.configuration().inputs) {\n // Updates a specified input name to a new value.\n // Using this method will properly mark for check component using the OnPush change detection strategy.\n // It will also assure that the OnChanges lifecycle hook runs when a dynamically created component is change-detected.\n this._componentRef.setInput(inputName, this.evaluateExpression(this.configuration().inputs[inputName], this.viewModel));\n }\n }\n }\n\n /**\n * Set attribute values for an element in the DOM.\n */\n private setAttributes(): void {\n if (this.configuration()?.attributes && Object.keys(this.configuration().attributes).length > 0 && this._componentRef?.location?.nativeElement) {\n for (const attributeName in this.configuration().attributes) {\n // Evaluates JavaScript code and executes it.\n const value = this.evaluateExpression(this.configuration().attributes[attributeName], this.viewModel) as string;\n\n // Returns element's first attribute whose qualified name is qualifiedName, and null if there is no such attribute otherwise.\n if (value !== this._componentRef.location.nativeElement.getAttribute(attributeName)) {\n // Implement this callback to set an attribute value for an element in the DOM.\n this._renderer.setAttribute(this._componentRef.location.nativeElement, attributeName, value);\n }\n }\n }\n }\n\n /**\n * Evaluates JavaScript code and executes it.\n * @param value The JavaScript code.\n * @param $vm The view model.\n * @param $event The event.\n * @returns Evaluated expression.\n */\n private evaluateExpression(value: unknown, $vm?: ModelSignal<unknown>, $event?: unknown): unknown {\n if (typeof(value) === 'string' && ((value.includes('$vm') && $vm != null && $vm() != null) || (value.includes('$event') && $event != null))) {\n // Evaluates JavaScript code and executes it.\n return eval(value);\n } else {\n return value;\n }\n }\n\n /**\n * A callback method that performs custom clean-up, invoked immediately before a directive, pipe, or service instance is destroyed.\n */\n\tngOnDestroy(): void {\n // Performs the specified action for each element in an array (Disposes the resources held by the subscription).\n this._outputsSubscriptions?.forEach((s: Subscription): void => s.unsubscribe());\n // Disposes the resources held by the subscription.\n // May, for instance, cancel an ongoing Observable execution or cancel any other type of work that started when the Subscription was created.\n this._formControlSubscription?.unsubscribe();\n // A callback method that performs custom clean-up, invoked immediately before a directive, pipe, or service instance is destroyed.\n this._formControlDirective?.ngOnDestroy();\n // Destroys the component instance and all of the data structures associated with it.\n this._componentRef?.destroy();\n\t}\n}\n","/*\n * Public API Surface of fg-dynamic-component\n */\n\nexport * from './lib/fg-dynamic.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;AAYA;;AAEG;MACU,gBAAgB,CAAA;aACV,IAAW,CAAA,WAAA,GAA4F,EAAE,CAAC,EAAA;AAEzH,IAAA,OAAO,iBAAiB,CAAC,IAAY,EAAE,IAA6E,EAAA;AAChH,QAAA,IAAI,IAAI,IAAI,IAAI,EAAE;AACd,YAAA,gBAAgB,CAAC,WAAW,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;SAC7C;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AAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAIQ,kBAAkB,EAAA,QAAA,EAAA,YAAA,EAAA,MAAA,EAAA,CAAA,eAAA,EAAA,WAAA,EAAA,WAAA,CAAA,EAAA,OAAA,EAAA,CAAA,iBAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA,EAAA;;2FAAlB,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAX9B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,YAAY;AACtB,oBAAA,QAAQ,EAAE,CAAA;;;;;AAKN,IAAA,CAAA;oBACJ,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAC/C,oBAAA,UAAU,EAAE,IAAI;AAChB,iBAAA,CAAA;;;AC3CD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"fg-dynamic-component.mjs","names":[],"sources":["../../../projects/fg-dynamic-component/src/lib/safe-expression.ts","../../../projects/fg-dynamic-component/src/lib/fg-dynamic.component.ts"],"sourcesContent":["/**\n * Small, allowlisted expression interpreter used for the `$vm` / `$event` binding\n * feature of `FGDynamicComponent`.\n *\n * This intentionally does NOT use `eval`, `new Function`, or any other\n * string-to-code primitive. Only the following constructs are supported:\n *\n * - literals (string, number, boolean, null, undefined, NaN, Infinity)\n * - identifiers from the provided variables (`$vm`, `$event`, arrow parameters)\n * - member access: `a.b`, `a['b']`, optional chaining `a?.b`\n * - calls: `$vm()`, `$vm.update(fn)`, `$event.value`\n * - unary: `!`, `-`, `+`, `typeof`\n * - binary/logical/ternary operators\n * - array and object literals, including spread\n * - expression-bodied arrow functions (and arrow blocks containing `return`)\n *\n * Assignments, `new`, `this`, globals (e.g. `window`, `fetch`), template\n * literals and regular-expression literals are rejected. Prototype-related\n * property names are blocked at every access.\n */\n\nconst MAX_SOURCE_LENGTH = 2000;\nconst MAX_TOKENS = 4000;\nconst MAX_PARSE_DEPTH = 80;\nconst MAX_EVALUATION_STEPS = 20000;\nconst MAX_EVALUATION_DEPTH = 80;\n\nconst FORBIDDEN_PROPERTIES: ReadonlySet<string> = new Set([\n '__proto__',\n 'prototype',\n 'constructor',\n 'caller',\n 'callee',\n 'arguments',\n '__defineGetter__',\n '__defineSetter__',\n '__lookupGetter__',\n '__lookupSetter__'\n]);\n\nconst PUNCTUATORS: readonly string[] = [\n '===', '!==', '**', '==', '!=', '<=', '>=', '&&', '||', '??', '?.', '...', '=>',\n '+', '-', '*', '/', '%', '<', '>', '!', '?', ':', '.', ',', '(', ')', '[', ']', '{', '}', ';'\n];\n\ntype TokenType = 'number' | 'string' | 'identifier' | 'punctuator' | 'eof';\n\ninterface Token {\n type: TokenType;\n value: string;\n position: number;\n}\n\ninterface ArgumentNode {\n spread: boolean;\n value: Node;\n}\n\ninterface ObjectProperty {\n spread: boolean;\n key?: Node;\n value: Node;\n computed: boolean;\n}\n\ntype Node =\n | { type: 'Literal'; value: unknown }\n | { type: 'Identifier'; name: string }\n | { type: 'Member'; object: Node; property: Node; computed: boolean; optional: boolean }\n | { type: 'Call'; callee: Node; args: ArgumentNode[]; optional: boolean }\n | { type: 'Unary'; operator: string; argument: Node }\n | { type: 'Binary'; operator: string; left: Node; right: Node }\n | { type: 'Logical'; operator: string; left: Node; right: Node }\n | { type: 'Conditional'; test: Node; consequent: Node; alternate: Node }\n | { type: 'Array'; elements: ArgumentNode[] }\n | { type: 'Object'; properties: ObjectProperty[] }\n | { type: 'Arrow'; params: string[]; body: Node; block: boolean };\n\ninterface EvaluationState {\n steps: number;\n depth: number;\n}\n\nexport class FGDynamicExpressionError extends Error {\n constructor(message: string) {\n super(message);\n this.name = 'FGDynamicExpressionError';\n }\n}\n\nfunction fail(message: string): never {\n throw new FGDynamicExpressionError(message);\n}\n\nfunction isPunctuator(token: Token, value: string): boolean {\n return token.type === 'punctuator' && token.value === value;\n}\n\nfunction isIdentifier(token: Token, value: string): boolean {\n return token.type === 'identifier' && token.value === value;\n}\n\nfunction tokenize(source: string): Token[] {\n const tokens: Token[] = [];\n let index = 0;\n\n while (index < source.length) {\n const character = source[index];\n\n if (/\\s/.test(character)) {\n index++;\n continue;\n }\n\n if (character === '\"' || character === \"'\") {\n const quote = character;\n let value = '';\n let cursor = index + 1;\n let closed = false;\n\n while (cursor < source.length) {\n const current = source[cursor];\n\n if (current === quote) {\n cursor++;\n closed = true;\n break;\n }\n\n if (current === '\\\\') {\n const escaped = source[cursor + 1];\n if (escaped === undefined) {\n fail('Unterminated string literal.');\n }\n\n switch (escaped) {\n case 'n': value += '\\n'; break;\n case 'r': value += '\\r'; break;\n case 't': value += '\\t'; break;\n case 'b': value += '\\b'; break;\n case 'f': value += '\\f'; break;\n case 'v': value += '\\v'; break;\n case '0': value += '\\0'; break;\n case 'u': {\n const hex = source.slice(cursor + 2, cursor + 6);\n if (!/^[0-9a-fA-F]{4}$/.test(hex)) {\n fail('Invalid unicode escape sequence.');\n }\n value += String.fromCharCode(parseInt(hex, 16));\n cursor += 4;\n break;\n }\n default: value += escaped; break;\n }\n\n cursor += 2;\n continue;\n }\n\n value += current;\n cursor++;\n }\n\n if (!closed) {\n fail('Unterminated string literal.');\n }\n\n tokens.push({ type: 'string', value, position: index });\n index = cursor;\n continue;\n }\n\n if (/[0-9]/.test(character) || (character === '.' && /[0-9]/.test(source[index + 1] ?? ''))) {\n const match = /^(?:0[xX][0-9a-fA-F]+|(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+-]?\\d+)?)/.exec(source.slice(index));\n if (!match) {\n fail('Invalid number literal.');\n }\n const raw = match[0];\n const numeric = Number(raw);\n if (!Number.isFinite(numeric)) {\n fail('Number literal is not finite.');\n }\n tokens.push({ type: 'number', value: raw, position: index });\n index += raw.length;\n continue;\n }\n\n if (/[A-Za-z_$]/.test(character)) {\n const match = /^[A-Za-z_$][A-Za-z0-9_$]*/.exec(source.slice(index));\n if (!match) {\n fail('Invalid identifier.');\n }\n tokens.push({ type: 'identifier', value: match[0], position: index });\n index += match[0].length;\n continue;\n }\n\n const punctuator = PUNCTUATORS.find((candidate: string): boolean => source.startsWith(candidate, index));\n if (!punctuator) {\n fail('Unexpected character in expression.');\n }\n\n tokens.push({ type: 'punctuator', value: punctuator, position: index });\n index += punctuator.length;\n }\n\n tokens.push({ type: 'eof', value: '', position: source.length });\n\n if (tokens.length > MAX_TOKENS) {\n fail('Expression is too complex.');\n }\n\n return tokens;\n}\n\nclass ExpressionParser {\n private index = 0;\n private depth = 0;\n private readonly tokens: Token[];\n\n constructor(tokens: Token[]) {\n this.tokens = tokens;\n }\n\n parse(): Node {\n const expression = this.parseExpression();\n if (this.current().type !== 'eof') {\n fail('Unexpected token after expression.');\n }\n return expression;\n }\n\n private current(): Token {\n return this.tokens[this.index];\n }\n\n private peek(offset = 1): Token | undefined {\n return this.tokens[this.index + offset];\n }\n\n private advance(): Token {\n const token = this.tokens[this.index];\n if (token.type !== 'eof') {\n this.index++;\n }\n return token;\n }\n\n private matchPunctuator(value: string): boolean {\n if (isPunctuator(this.current(), value)) {\n this.advance();\n return true;\n }\n return false;\n }\n\n private expectPunctuator(value: string): void {\n if (!this.matchPunctuator(value)) {\n fail(`Expected \"${value}\".`);\n }\n }\n\n private enter(): void {\n this.depth++;\n if (this.depth > MAX_PARSE_DEPTH) {\n fail('Expression is nested too deeply.');\n }\n }\n\n private leave(): void {\n this.depth--;\n }\n\n private parseExpression(): Node {\n this.enter();\n try {\n return this.parseAssignment();\n } finally {\n this.leave();\n }\n }\n\n private parseAssignment(): Node {\n if (this.isArrowStart()) {\n return this.parseArrow();\n }\n return this.parseConditional();\n }\n\n private isArrowStart(): boolean {\n const token = this.current();\n\n if (token.type === 'identifier' && this.peek()?.value === '=>') {\n return true;\n }\n\n if (!isPunctuator(token, '(')) {\n return false;\n }\n\n let nesting = 0;\n for (let cursor = this.index; cursor < this.tokens.length; cursor++) {\n const candidate = this.tokens[cursor];\n if (candidate.type !== 'punctuator') {\n continue;\n }\n if (candidate.value === '(') {\n nesting++;\n } else if (candidate.value === ')') {\n nesting--;\n if (nesting === 0) {\n return this.tokens[cursor + 1]?.value === '=>';\n }\n }\n }\n\n return false;\n }\n\n private parseArrow(): Node {\n const params: string[] = [];\n\n if (this.current().type === 'identifier') {\n params.push(this.advance().value);\n } else {\n this.expectPunctuator('(');\n if (!isPunctuator(this.current(), ')')) {\n do {\n if (isPunctuator(this.current(), ')')) {\n break;\n }\n const parameter = this.advance();\n if (parameter.type !== 'identifier') {\n fail('Arrow function parameters must be identifiers.');\n }\n if (FORBIDDEN_PROPERTIES.has(parameter.value)) {\n fail('Forbidden arrow function parameter name.');\n }\n params.push(parameter.value);\n } while (this.matchPunctuator(','));\n }\n this.expectPunctuator(')');\n }\n\n this.expectPunctuator('=>');\n\n if (this.matchPunctuator('{')) {\n while (this.matchPunctuator(';')) {\n // Skip empty statements.\n }\n\n if (!isIdentifier(this.current(), 'return')) {\n fail('Arrow function blocks must contain a return statement.');\n }\n\n this.advance();\n const value = this.parseExpression();\n this.matchPunctuator(';');\n this.expectPunctuator('}');\n return { type: 'Arrow', params, body: value, block: true };\n }\n\n return { type: 'Arrow', params, body: this.parseExpression(), block: false };\n }\n\n private parseConditional(): Node {\n const test = this.parseNullish();\n\n if (this.matchPunctuator('?')) {\n const consequent = this.parseAssignment();\n this.expectPunctuator(':');\n const alternate = this.parseAssignment();\n return { type: 'Conditional', test, consequent, alternate };\n }\n\n return test;\n }\n\n private parseNullish(): Node {\n let left = this.parseLogicalOr();\n while (this.matchPunctuator('??')) {\n const right = this.parseLogicalOr();\n left = { type: 'Logical', operator: '??', left, right };\n }\n return left;\n }\n\n private parseLogicalOr(): Node {\n let left = this.parseLogicalAnd();\n while (this.matchPunctuator('||')) {\n const right = this.parseLogicalAnd();\n left = { type: 'Logical', operator: '||', left, right };\n }\n return left;\n }\n\n private parseLogicalAnd(): Node {\n let left = this.parseEquality();\n while (this.matchPunctuator('&&')) {\n const right = this.parseEquality();\n left = { type: 'Logical', operator: '&&', left, right };\n }\n return left;\n }\n\n private parseEquality(): Node {\n let left = this.parseRelational();\n while (\n isPunctuator(this.current(), '===') ||\n isPunctuator(this.current(), '!==') ||\n isPunctuator(this.current(), '==') ||\n isPunctuator(this.current(), '!=')\n ) {\n const operator = this.advance().value;\n const right = this.parseRelational();\n left = { type: 'Binary', operator, left, right };\n }\n return left;\n }\n\n private parseRelational(): Node {\n let left = this.parseAdditive();\n while (\n isPunctuator(this.current(), '<') ||\n isPunctuator(this.current(), '>') ||\n isPunctuator(this.current(), '<=') ||\n isPunctuator(this.current(), '>=')\n ) {\n const operator = this.advance().value;\n const right = this.parseAdditive();\n left = { type: 'Binary', operator, left, right };\n }\n return left;\n }\n\n private parseAdditive(): Node {\n let left = this.parseMultiplicative();\n while (isPunctuator(this.current(), '+') || isPunctuator(this.current(), '-')) {\n const operator = this.advance().value;\n const right = this.parseMultiplicative();\n left = { type: 'Binary', operator, left, right };\n }\n return left;\n }\n\n private parseMultiplicative(): Node {\n let left = this.parseExponent();\n while (\n isPunctuator(this.current(), '*') ||\n isPunctuator(this.current(), '/') ||\n isPunctuator(this.current(), '%')\n ) {\n const operator = this.advance().value;\n const right = this.parseExponent();\n left = { type: 'Binary', operator, left, right };\n }\n return left;\n }\n\n private parseExponent(): Node {\n const left = this.parseUnary();\n if (this.matchPunctuator('**')) {\n const right = this.parseExponent();\n return { type: 'Binary', operator: '**', left, right };\n }\n return left;\n }\n\n private parseUnary(): Node {\n if (\n isPunctuator(this.current(), '!') ||\n isPunctuator(this.current(), '-') ||\n isPunctuator(this.current(), '+')\n ) {\n const operator = this.advance().value;\n return { type: 'Unary', operator, argument: this.parseUnary() };\n }\n\n if (isIdentifier(this.current(), 'typeof')) {\n this.advance();\n return { type: 'Unary', operator: 'typeof', argument: this.parseUnary() };\n }\n\n return this.parsePostfix();\n }\n\n private parsePostfix(): Node {\n let node = this.parsePrimary();\n\n for (;;) {\n if (this.matchPunctuator('.')) {\n const property = this.advance();\n if (property.type !== 'identifier') {\n fail('Expected a property name.');\n }\n node = {\n type: 'Member',\n object: node,\n property: { type: 'Literal', value: property.value },\n computed: false,\n optional: false\n };\n continue;\n }\n\n if (this.matchPunctuator('?.')) {\n if (this.matchPunctuator('(')) {\n node = { type: 'Call', callee: node, args: this.parseArguments(), optional: true };\n } else if (this.matchPunctuator('[')) {\n const property = this.parseExpression();\n this.expectPunctuator(']');\n node = { type: 'Member', object: node, property, computed: true, optional: true };\n } else {\n const property = this.advance();\n if (property.type !== 'identifier') {\n fail('Expected a property name.');\n }\n node = {\n type: 'Member',\n object: node,\n property: { type: 'Literal', value: property.value },\n computed: false,\n optional: true\n };\n }\n continue;\n }\n\n if (this.matchPunctuator('[')) {\n const property = this.parseExpression();\n this.expectPunctuator(']');\n node = { type: 'Member', object: node, property, computed: true, optional: false };\n continue;\n }\n\n if (this.matchPunctuator('(')) {\n node = { type: 'Call', callee: node, args: this.parseArguments(), optional: false };\n continue;\n }\n\n break;\n }\n\n return node;\n }\n\n private parseArguments(): ArgumentNode[] {\n const args: ArgumentNode[] = [];\n\n if (!isPunctuator(this.current(), ')')) {\n do {\n if (isPunctuator(this.current(), ')')) {\n break;\n }\n const spread = this.matchPunctuator('...');\n args.push({ spread, value: this.parseAssignment() });\n } while (this.matchPunctuator(','));\n }\n\n this.expectPunctuator(')');\n return args;\n }\n\n private parsePrimary(): Node {\n const token = this.current();\n\n if (token.type === 'number') {\n this.advance();\n return { type: 'Literal', value: Number(token.value) };\n }\n\n if (token.type === 'string') {\n this.advance();\n return { type: 'Literal', value: token.value };\n }\n\n if (token.type === 'identifier') {\n this.advance();\n switch (token.value) {\n case 'true': return { type: 'Literal', value: true };\n case 'false': return { type: 'Literal', value: false };\n case 'null': return { type: 'Literal', value: null };\n case 'undefined': return { type: 'Literal', value: undefined };\n case 'NaN': return { type: 'Literal', value: NaN };\n case 'Infinity': return { type: 'Literal', value: Infinity };\n default: return { type: 'Identifier', name: token.value };\n }\n }\n\n if (this.matchPunctuator('(')) {\n const expression = this.parseExpression();\n this.expectPunctuator(')');\n return expression;\n }\n\n if (this.matchPunctuator('[')) {\n return this.parseArray();\n }\n\n if (this.matchPunctuator('{')) {\n return this.parseObject();\n }\n\n return fail('Unexpected token in expression.');\n }\n\n private parseArray(): Node {\n const elements: ArgumentNode[] = [];\n\n if (!isPunctuator(this.current(), ']')) {\n do {\n if (isPunctuator(this.current(), ']')) {\n break;\n }\n const spread = this.matchPunctuator('...');\n elements.push({ spread, value: this.parseAssignment() });\n } while (this.matchPunctuator(','));\n }\n\n this.expectPunctuator(']');\n return { type: 'Array', elements };\n }\n\n private parseObject(): Node {\n const properties: ObjectProperty[] = [];\n\n if (!isPunctuator(this.current(), '}')) {\n do {\n if (isPunctuator(this.current(), '}')) {\n break;\n }\n\n if (this.matchPunctuator('...')) {\n properties.push({ spread: true, value: this.parseAssignment(), computed: false });\n continue;\n }\n\n let key: Node;\n let computed = false;\n\n if (this.matchPunctuator('[')) {\n key = this.parseExpression();\n this.expectPunctuator(']');\n computed = true;\n } else {\n const keyToken = this.advance();\n if (keyToken.type === 'identifier' || keyToken.type === 'string') {\n key = { type: 'Literal', value: keyToken.value };\n } else if (keyToken.type === 'number') {\n key = { type: 'Literal', value: String(Number(keyToken.value)) };\n } else {\n return fail('Invalid object key.');\n }\n }\n\n this.expectPunctuator(':');\n const value = this.parseAssignment();\n properties.push({ spread: false, key, value, computed });\n } while (this.matchPunctuator(','));\n }\n\n this.expectPunctuator('}');\n return { type: 'Object', properties };\n }\n}\n\nfunction assertSafeProperty(property: string): void {\n if (FORBIDDEN_PROPERTIES.has(property)) {\n fail('Access to a forbidden property was blocked.');\n }\n}\n\nfunction defineSafeProperty(target: Record<string, unknown>, key: string, value: unknown): void {\n assertSafeProperty(key);\n Object.defineProperty(target, key, {\n value,\n writable: true,\n enumerable: true,\n configurable: true\n });\n}\n\nfunction readMember(target: unknown, key: unknown, optional: boolean): unknown {\n if (typeof key !== 'string' && typeof key !== 'number') {\n fail('Property keys must be strings or numbers.');\n }\n\n const property = String(key);\n assertSafeProperty(property);\n\n if (target == null) {\n if (optional) {\n return undefined;\n }\n fail('Cannot read properties of null or undefined.');\n }\n\n return (Object(target) as Record<string, unknown>)[property];\n}\n\nfunction spreadValues(value: unknown): unknown[] {\n if (Array.isArray(value)) {\n return value.slice();\n }\n if (typeof value === 'string') {\n return value.split('');\n }\n return fail('Spread is only supported for arrays and strings.');\n}\n\nfunction isPrimitive(value: unknown): boolean {\n return value == null || typeof value === 'string' || typeof value === 'number' ||\n typeof value === 'boolean' || typeof value === 'bigint';\n}\n\nfunction primitiveAdd(left: unknown, right: unknown): unknown {\n if (!isPrimitive(left) || !isPrimitive(right)) {\n fail('Arithmetic on objects is not allowed.');\n }\n return (left as number) + (right as number);\n}\n\nfunction numericOperation(operator: string, left: unknown, right: unknown): number {\n if (typeof left !== 'number' || typeof right !== 'number') {\n fail(`Operator \"${operator}\" only supports numbers.`);\n }\n\n switch (operator) {\n case '-': return left - right;\n case '*': return left * right;\n case '/': return left / right;\n case '%': return left % right;\n case '**': return left ** right;\n default: return fail(`Unsupported arithmetic operator \"${operator}\".`);\n }\n}\n\nfunction looseEquals(left: unknown, right: unknown): boolean {\n if (!isPrimitive(left) || !isPrimitive(right)) {\n fail('Loose equality is only supported for primitive values.');\n }\n return left == right;\n}\n\nfunction compareValues(operator: string, left: unknown, right: unknown): boolean {\n if (!isPrimitive(left) || !isPrimitive(right)) {\n fail('Comparison is only supported for primitive values.');\n }\n\n switch (operator) {\n case '<': return (left as number) < (right as number);\n case '>': return (left as number) > (right as number);\n case '<=': return (left as number) <= (right as number);\n case '>=': return (left as number) >= (right as number);\n default: return fail(`Unsupported comparison operator \"${operator}\".`);\n }\n}\n\nfunction evaluateNode(node: Node, environment: Map<string, unknown>, state: EvaluationState): unknown {\n state.steps++;\n state.depth++;\n\n if (state.steps > MAX_EVALUATION_STEPS) {\n state.depth--;\n return fail('Expression is too complex.');\n }\n if (state.depth > MAX_EVALUATION_DEPTH) {\n state.depth--;\n return fail('Expression is nested too deeply.');\n }\n\n try {\n switch (node.type) {\n case 'Literal':\n return node.value;\n\n case 'Identifier': {\n if (!environment.has(node.name)) {\n return fail(`Unknown identifier \"${node.name}\".`);\n }\n return environment.get(node.name);\n }\n\n case 'Member': {\n const object = evaluateNode(node.object, environment, state);\n const key = evaluateNode(node.property, environment, state);\n return readMember(object, key, node.optional);\n }\n\n case 'Call': {\n let fn: unknown;\n let thisArg: unknown;\n\n if (node.callee.type === 'Member') {\n const object = evaluateNode(node.callee.object, environment, state);\n const key = evaluateNode(node.callee.property, environment, state);\n fn = readMember(object, key, node.callee.optional);\n thisArg = object;\n } else {\n fn = evaluateNode(node.callee, environment, state);\n }\n\n if (fn == null && node.optional) {\n return undefined;\n }\n if (typeof fn !== 'function') {\n if (node.optional) {\n return undefined;\n }\n return fail('Attempted to call a non-function value.');\n }\n if (fn === Function || fn === eval) {\n return fail('Calling global constructors is not allowed.');\n }\n\n const args: unknown[] = [];\n for (const argument of node.args) {\n const value = evaluateNode(argument.value, environment, state);\n if (argument.spread) {\n args.push(...spreadValues(value));\n } else {\n args.push(value);\n }\n }\n\n return (fn as (...args: unknown[]) => unknown).apply(thisArg, args);\n }\n\n case 'Unary': {\n const argument = evaluateNode(node.argument, environment, state);\n switch (node.operator) {\n case '!': return !argument;\n case 'typeof': return typeof argument;\n case '-':\n if (typeof argument !== 'number' && typeof argument !== 'bigint') {\n return fail('Unary \"-\" only supports numbers.');\n }\n return typeof argument === 'bigint' ? -argument : -argument;\n case '+':\n if (typeof argument !== 'number') {\n return fail('Unary \"+\" only supports numbers.');\n }\n return +argument;\n default:\n return fail(`Unsupported unary operator \"${node.operator}\".`);\n }\n }\n\n case 'Binary': {\n const left = evaluateNode(node.left, environment, state);\n const right = evaluateNode(node.right, environment, state);\n\n switch (node.operator) {\n case '===': return left === right;\n case '!==': return left !== right;\n case '==': return looseEquals(left, right);\n case '!=': return !looseEquals(left, right);\n case '+': return primitiveAdd(left, right);\n case '-':\n case '*':\n case '/':\n case '%':\n case '**':\n return numericOperation(node.operator, left, right);\n case '<':\n case '>':\n case '<=':\n case '>=':\n return compareValues(node.operator, left, right);\n default:\n return fail(`Unsupported binary operator \"${node.operator}\".`);\n }\n }\n\n case 'Logical': {\n const left = evaluateNode(node.left, environment, state);\n switch (node.operator) {\n case '&&': return left ? evaluateNode(node.right, environment, state) : left;\n case '||': return left ? left : evaluateNode(node.right, environment, state);\n case '??': return left == null ? evaluateNode(node.right, environment, state) : left;\n default: return fail(`Unsupported logical operator \"${node.operator}\".`);\n }\n }\n\n case 'Conditional':\n return evaluateNode(node.test, environment, state)\n ? evaluateNode(node.consequent, environment, state)\n : evaluateNode(node.alternate, environment, state);\n\n case 'Array': {\n const values: unknown[] = [];\n for (const element of node.elements) {\n const value = evaluateNode(element.value, environment, state);\n if (element.spread) {\n values.push(...spreadValues(value));\n } else {\n values.push(value);\n }\n }\n return values;\n }\n\n case 'Object': {\n const result: Record<string, unknown> = {};\n for (const property of node.properties) {\n if (property.spread) {\n const source = evaluateNode(property.value, environment, state);\n if (source == null || typeof source !== 'object') {\n return fail('Object spread is only supported for objects.');\n }\n for (const key of Object.keys(source)) {\n const descriptor = Object.getOwnPropertyDescriptor(source, key);\n if (descriptor && 'value' in descriptor) {\n defineSafeProperty(result, key, descriptor.value);\n }\n }\n continue;\n }\n\n if (!property.key) {\n return fail('Invalid object property.');\n }\n\n const key = property.computed\n ? evaluateNode(property.key, environment, state)\n : (property.key as { type: 'Literal'; value: unknown }).value;\n\n if (typeof key !== 'string' && typeof key !== 'number') {\n return fail('Object keys must be strings or numbers.');\n }\n\n defineSafeProperty(result, String(key), evaluateNode(property.value, environment, state));\n }\n return result;\n }\n\n case 'Arrow': {\n const params = node.params;\n const body = node.body;\n const closure = new Map(environment);\n\n return function evaluateArrowFunction(...args: unknown[]): unknown {\n const local = new Map(closure);\n params.forEach((parameter: string, index: number): void => {\n local.set(parameter, args[index]);\n });\n return evaluateNode(body, local, state);\n };\n }\n\n default:\n return fail('Unsupported expression node.');\n }\n } finally {\n state.depth--;\n }\n}\n\n/**\n * Evaluates a configuration expression without ever compiling it as JavaScript.\n *\n * Only the identifiers provided in `variables` are visible. Any unsupported\n * construct throws an `FGDynamicExpressionError`; callers should treat that as\n * an invalid expression and fall back to the literal value.\n */\nexport function evaluateSafeExpression(source: string, variables: Record<string, unknown> = {}): unknown {\n if (typeof source !== 'string') {\n fail('Expression must be a string.');\n }\n if (source.length === 0) {\n fail('Expression is empty.');\n }\n if (source.length > MAX_SOURCE_LENGTH) {\n fail('Expression is too long.');\n }\n\n const parser = new ExpressionParser(tokenize(source));\n const ast = parser.parse();\n const environment = new Map<string, unknown>();\n\n for (const [key, value] of Object.entries(variables)) {\n environment.set(key, value);\n }\n\n return evaluateNode(ast, environment, { steps: 0, depth: 0 });\n}\n","import { ChangeDetectionStrategy, Component, ComponentRef, ElementRef, EventEmitter, Injector, InputSignal, ModelSignal, OnChanges, OnDestroy, Renderer2, Signal, SimpleChanges, Type, ViewContainerRef, computed, inject, input, isDevMode, model, viewChild, viewChildren } from '@angular/core';\nimport { AbstractControl, ControlValueAccessor, FormControl, FormControlDirective, FormGroup, NG_VALUE_ACCESSOR, NgControl, ValidationErrors, ValidatorFn, Validators } from '@angular/forms';\nimport { Subscription } from 'rxjs';\nimport { evaluateSafeExpression } from './safe-expression';\n\nexport type FGDynamicType = Type<unknown> | Promise<Type<unknown>> | (() => Promise<Type<unknown>>);\n\nexport interface IFGDynamicItem {\n type?: string | FGDynamicType;\n inputs?: Record<string, string | unknown>;\n outputs?: Record<string, string | Function>;\n attributes?: Record<string, string | unknown>;\n items?: IFGDynamicItem[];\n}\n\nconst FORBIDDEN_PATH_SEGMENTS: ReadonlySet<string> = new Set(['__proto__', 'prototype', 'constructor']);\nconst MAX_PATH_DEPTH = 32;\nconst MAX_PATH_SEGMENT_LENGTH = 128;\nconst MAX_CONFIGURATION_ITEMS = 1000;\nconst MAX_ATTRIBUTE_NAME_LENGTH = 128;\nconst MAX_ATTRIBUTE_VALUE_LENGTH = 8192;\nconst MAX_PATTERN_LENGTH = 512;\nconst MAX_PATTERN_INPUT_LENGTH = 1024;\n\nconst ALLOWED_ATTRIBUTES: ReadonlySet<string> = new Set([\n 'class', 'id', 'name', 'role', 'title', 'tabindex', 'hidden', 'dir', 'lang',\n 'disabled', 'readonly', 'required', 'placeholder', 'autocomplete', 'spellcheck',\n 'min', 'max', 'minlength', 'maxlength', 'pattern', 'email', 'step',\n 'multiple', 'checked', 'selected', 'for', 'href', 'src'\n]);\n\nconst URL_ATTRIBUTES: ReadonlySet<string> = new Set(['href', 'src']);\n\n/**\n * A scoped component registry. Backed by a `Map`, so lookups never walk the\n * prototype chain and names such as `__proto__` or `constructor` are ordinary keys.\n *\n * Use one registry per rendering context (e.g. per plugin or tenant) so a\n * configuration can only select components that were explicitly registered for\n * that context.\n */\nexport class FGDynamicRegistry {\n private readonly _components = new Map<string, FGDynamicType>();\n\n register(name: string, type: FGDynamicType): void {\n if (typeof name === 'string' && name.length > 0 && type) {\n this._components.set(name, type);\n }\n }\n\n get(name: string): FGDynamicType | undefined {\n return typeof name === 'string' ? this._components.get(name) : undefined;\n }\n\n has(name: string): boolean {\n return typeof name === 'string' && this._components.has(name);\n }\n\n unregister(name: string): boolean {\n return this._components.delete(name);\n }\n\n clear(): void {\n this._components.clear();\n }\n\n get names(): string[] {\n return Array.from(this._components.keys());\n }\n}\n\n/**\n * Declare components to dynamically load in static and/or dynamic way using the FGDynamicService.\n *\n * The static registry is global. For untrusted or multi-tenant configurations,\n * create a scoped registry with `FGDynamicService.createRegistry()` and pass it\n * to `<fg-dynamic [registry]=\"registry\">`.\n */\nexport class FGDynamicService {\n private static readonly _defaultRegistry = new FGDynamicRegistry();\n\n static get registry(): FGDynamicRegistry {\n return FGDynamicService._defaultRegistry;\n }\n\n static createRegistry(): FGDynamicRegistry {\n return new FGDynamicRegistry();\n }\n\n static registerComponent(name: string, type: FGDynamicType): void {\n FGDynamicService._defaultRegistry.register(name, type);\n }\n\n static getComponent(name: string): FGDynamicType | undefined {\n return FGDynamicService._defaultRegistry.get(name);\n }\n\n static hasComponent(name: string): boolean {\n return FGDynamicService._defaultRegistry.has(name);\n }\n\n static unregisterComponent(name: string): boolean {\n return FGDynamicService._defaultRegistry.unregister(name);\n }\n\n static clearRegistry(): void {\n FGDynamicService._defaultRegistry.clear();\n }\n}\n\n/**\n * Create a standalone signals based dynamic components tree through a JSON configuration with full\n * life-cycle support for inputs, outputs, attributes, reactive forms and expressions binding evaluation.\n */\n@Component({\n\tselector: 'fg-dynamic',\n\ttemplate: `\n <ng-container #viewContainer></ng-container>\n @for (item of items(); track $index) {\n <fg-dynamic #dynamicItem [configuration]=\"item\" [(viewModel)]=\"viewModel\" [formGroup]=\"formGroup()\" [registry]=\"registry()\" />\n }\n `,\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\tstandalone: true,\n\tstyles: [`:host { display: contents; }`]\n})\nexport class FGDynamicComponent implements OnChanges, OnDestroy {\n\tconfiguration: InputSignal<IFGDynamicItem> = input.required<IFGDynamicItem>();\n\tviewModel: ModelSignal<unknown> = model<unknown>();\n\tformGroup: InputSignal<FormGroup> = input<FormGroup>();\n\tregistry: InputSignal<FGDynamicRegistry> = input<FGDynamicRegistry>(FGDynamicService.registry);\n\n /**\n * Validated child items. Invalid entries are ignored and the list is capped\n * to avoid pathological configurations blocking the renderer.\n */\n protected readonly items: Signal<readonly IFGDynamicItem[]> = computed((): readonly IFGDynamicItem[] => {\n const configuration = this.configuration();\n const items = configuration && typeof configuration === 'object' && !Array.isArray(configuration) ? (configuration as IFGDynamicItem).items : undefined;\n if (!Array.isArray(items)) {\n return [];\n }\n return items\n .filter((item: unknown): item is IFGDynamicItem => item != null && typeof item === 'object' && !Array.isArray(item))\n .slice(0, MAX_CONFIGURATION_ITEMS);\n });\n\n\tprivate _viewContainerRef: Signal<ViewContainerRef> = viewChild.required('viewContainer', {\n read: ViewContainerRef\n });\n private _dynamicItems: Signal<readonly ElementRef<unknown>[]> = viewChildren('dynamicItem', {\n read: ElementRef\n });\n\tprivate _componentRef: ComponentRef<unknown>;\n private _renderer: Renderer2 = inject(Renderer2);\n private _outputsSubscriptions: Subscription[] = [];\n private _currentOutputsConfig?: Record<string, string | Function>;\n private _formControl: FormControl;\n private _formControlDirective: FormControlDirective;\n private _formControlSubscription: Subscription;\n private _managedValidatorFns: ValidatorFn[] = [];\n private _component: Type<unknown>;\n private _injector: Injector = inject(Injector);\n private _ngOnChangesCounter = 0;\n private _lastProjectedItemsSignature: string;\n\n /**\n * A callback method that is invoked immediately after the default change\n * detector has checked data-bound properties if at least one has changed,\n * and before the view and content children are checked.\n */\n async ngOnChanges(changes?: SimpleChanges): Promise<void> {\n const counter = ++this._ngOnChangesCounter;\n try {\n const configuration = this.configuration();\n if (configuration != null && (typeof configuration !== 'object' || Array.isArray(configuration))) {\n this.logError('Invalid configuration: expected an object.');\n return;\n }\n\n // Lazy-load a component.\n await this.loadComponentAsync();\n\n if (counter !== this._ngOnChangesCounter) {\n return;\n }\n\n // If projected items changed, we need to recreate the component to update projectableNodes\n const items = this.items();\n const itemsSignature = items.length > 0\n ? `${items.length}:${items.map((item: IFGDynamicItem, index: number): string => `${index}:${item?.type}`).join('|')}`\n : '';\n if (this._componentRef && this._lastProjectedItemsSignature !== itemsSignature) {\n this.cleanup();\n this._lastProjectedItemsSignature = itemsSignature;\n } else if (!this._componentRef) {\n this._lastProjectedItemsSignature = itemsSignature;\n }\n\n // Instantiates a single component and inserts its host view into this container.\n this.createComponent();\n\n if (counter !== this._ngOnChangesCounter) {\n return;\n }\n\n // Updates specified input names to new values.\n this.setInputs();\n // Disables/enables the control.\n this.setFormControlStatus();\n // Add synchronous validators to this control.\n this.setFormControlValidators();\n // Set attribute values for an element in the DOM.\n this.setAttributes();\n // Re-wire outputs if they changed\n this.handleOutputsIfChanged();\n // Ensure change detection\n if (this._componentRef?.changeDetectorRef) {\n this._componentRef.changeDetectorRef.markForCheck();\n }\n } catch (error) {\n this.logError('Error during component initialization.', error);\n }\n }\n\n /**\n * A method to lazy-load a component.\n */\n private async loadComponentAsync(): Promise<void> {\n const configurationType = this.configuration()?.type;\n\n if (configurationType == null) {\n return;\n }\n\n let candidate: FGDynamicType | undefined;\n\n if (typeof configurationType === 'string') {\n candidate = this.getRegistry().get(configurationType);\n if (candidate == null) {\n this.logWarning(`Component type \"${configurationType}\" not found in the registry.`);\n return;\n }\n } else {\n candidate = configurationType;\n }\n\n try {\n const resolved = this.resolveCandidate(candidate);\n\n // Resolve synchronous types without an extra microtask hop so that\n // attribute/form updates happen within the same change-detection pass.\n const resolvedType = resolved instanceof Promise ? await resolved : resolved;\n\n // Only re-assign when the resolved type actually changed, so that subsequent\n // input/attribute updates don't tear down the already-instantiated component.\n if (resolvedType && this._component !== resolvedType) {\n this._component = resolvedType;\n }\n } catch (error) {\n this.logError('Unable to resolve the dynamic component type.', error);\n }\n }\n\n private resolveCandidate(candidate: unknown): Type<unknown> | Promise<Type<unknown> | undefined> | undefined {\n if (candidate == null) {\n return undefined;\n }\n\n if (candidate instanceof Promise) {\n return candidate.then((resolved: unknown): Type<unknown> | undefined => this.toComponentType(resolved));\n }\n\n if (typeof candidate === 'function') {\n // Never invoke an Angular component/directive/pipe class: it is a type, not a loader.\n if (this.isAngularComponentType(candidate)) {\n return candidate as Type<unknown>;\n }\n\n // A function with declared parameters cannot be a lazy loader (loaders are zero-arity).\n if (candidate.length > 0) {\n return candidate as Type<unknown>;\n }\n\n const result: unknown = (candidate as () => unknown)();\n\n if (result instanceof Promise) {\n return result.then((resolved: unknown): Type<unknown> | undefined => this.toComponentType(resolved));\n }\n\n return this.toComponentType(result);\n }\n\n this.logWarning('Invalid component type in configuration.');\n return undefined;\n }\n\n private toComponentType(resolved: unknown): Type<unknown> | undefined {\n if (typeof resolved === 'function') {\n return resolved as Type<unknown>;\n }\n\n this.logWarning('Component loader did not resolve to a component type.');\n return undefined;\n }\n\n private isAngularComponentType(candidate: Function): boolean {\n const metadata = candidate as unknown as Record<string, unknown>;\n return Boolean(\n metadata['ɵcmp'] ||\n metadata['ɵdir'] ||\n metadata['ɵpipe'] ||\n metadata['ɵfac'] ||\n metadata['ngComponentDef'] ||\n metadata['ngDirectiveDef']\n );\n }\n\n private getRegistry(): FGDynamicRegistry {\n return this.registry() ?? FGDynamicService.registry;\n }\n\n /**\n * Instantiates a single component and inserts its host view into this container.\n */\n private createComponent(): void {\n // If the component type changed, clean up and recreate it.\n if (this._componentRef && this._component !== this._componentRef.componentType) {\n this.cleanup();\n }\n\n if (this._component && !this._componentRef && this._viewContainerRef()) {\n let injector: Injector | undefined = undefined;\n const attributes = this.configuration()?.attributes;\n const nameAttr = attributes && Object.hasOwn(attributes, 'name') ? attributes['name'] : undefined;\n\n if (this.formGroup() && nameAttr != null && this.viewModel() != null) {\n const evaluatedName = this.evaluateExpression(nameAttr, this.viewModel);\n if (typeof evaluatedName === 'string' && this.isSafePath(evaluatedName)) {\n // Synchronizes a standalone FormControl instance to a form control element.\n this._formControlDirective = new FormControlDirective(null, null, null, null);\n\n // Creates a new injector instance that provides one or more dependencies, according to a given type or types of StaticProvider.\n injector = Injector.create({\n providers: [{\n provide: NgControl,\n useValue: this._formControlDirective\n }],\n parent: this._injector\n });\n } else if (typeof evaluatedName === 'string') {\n this.logWarning('Unsafe form control name was ignored.');\n }\n }\n\n // Instantiates a single component and inserts its host view into this container.\n const dynamicItems = this._dynamicItems();\n this._componentRef = this._viewContainerRef().createComponent(this._component, {\n projectableNodes: dynamicItems && dynamicItems.length > 0 ? [dynamicItems.map((e: ElementRef<unknown>): Node => e.nativeElement as Node)] : undefined,\n injector: injector\n });\n\n // When a view uses the ChangeDetectionStrategy#OnPush (checkOnce) change detection strategy, explicitly marks the view as changed so that it can be checked again.\n // Components are normally marked as dirty (in need of rerendering) when inputs have changed or events have fired in the view.\n // Call this method to ensure that a component is checked even if these triggers have not occurred.\n if (this._componentRef?.changeDetectorRef) {\n this._componentRef.changeDetectorRef.markForCheck();\n }\n\n // Register handlers for those events by subscribing to an instance.\n this.handleOutputs();\n // Construct a FormControl with an initial value.\n this.createFormControl();\n }\n }\n\n /**\n * Register handlers for those events by subscribing to an instance.\n */\n private handleOutputs(): void {\n // Clean up existing subscriptions\n if (this._outputsSubscriptions && this._outputsSubscriptions.length > 0) {\n this._outputsSubscriptions.forEach((s: Subscription): void => {\n try {\n s.unsubscribe();\n } catch (e) {\n // Ignore\n }\n });\n this._outputsSubscriptions = [];\n }\n\n const outputs = this.configuration()?.outputs;\n this._currentOutputsConfig = outputs ? { ...outputs } : undefined;\n\n if (outputs && typeof outputs === 'object' && this._componentRef?.instance) {\n const instance = this._componentRef.instance as Record<string, unknown>;\n\n for (const outputName of Object.keys(outputs)) {\n const emitter = instance[outputName];\n\n if (!(emitter instanceof EventEmitter)) {\n continue;\n }\n\n this._outputsSubscriptions.push(emitter.subscribe(($event: unknown): void => {\n try {\n const expr = outputs[outputName];\n const viewModelValue = this.getViewModelValue();\n const result: unknown = typeof expr === 'string'\n ? this.evaluateExpression(expr, this.viewModel, $event)\n : expr;\n\n if (typeof result === 'function') {\n (result as Function).call(viewModelValue, $event);\n } else if (typeof expr === 'function') {\n (expr as Function).call(viewModelValue, $event);\n }\n } catch (error) {\n this.logError('Error handling output.', error);\n }\n }));\n }\n }\n }\n\n private handleOutputsIfChanged(): void {\n const outputs = this.configuration()?.outputs;\n const current = this._currentOutputsConfig;\n \n // Check if outputs changed\n if (!outputs && !current) {\n return;\n }\n if (!outputs || !current) {\n this.handleOutputs();\n return;\n }\n \n const currentKeys = Object.keys(current).sort();\n const newKeys = Object.keys(outputs).sort();\n if (currentKeys.length !== newKeys.length) {\n this.handleOutputs();\n return;\n }\n for (let i = 0; i < currentKeys.length; i++) {\n if (currentKeys[i] !== newKeys[i] || current[currentKeys[i]] !== outputs[newKeys[i]]) {\n this.handleOutputs();\n return;\n }\n }\n }\n\n /**\n * Construct a FormControl with an initial value.\n */\n private createFormControl(): void {\n const attributes = this.configuration()?.attributes;\n const nameAttr = attributes && Object.hasOwn(attributes, 'name') ? attributes['name'] : undefined;\n\n if (this.formGroup() && nameAttr != null && this.viewModel() != null) {\n const name = this.evaluateExpression(nameAttr, this.viewModel);\n\n if (typeof name === 'string' && name.length > 0 && this.isSafePath(name)) {\n const formGroup = this.formGroup();\n\n // Check if control with same name already exists\n const existingControl = formGroup.get(name);\n if (existingControl && existingControl !== this._formControl) {\n this.logWarning('A form control with the requested name already exists; reusing it.');\n this._formControl = existingControl as FormControl;\n // Still need to attach directive if needed\n if (this._formControlDirective) {\n this.attachFormControlDirective();\n }\n return;\n }\n\n // Construct a FormControl with an initial value.\n this._formControl = new FormControl(this.getModelPropertyValue(this.viewModel(), name, null));\n\n // Add a control to this group.\n try {\n if (existingControl === this._formControl) {\n // Already added\n } else if (existingControl) {\n formGroup.setControl(name, this._formControl);\n } else {\n formGroup.addControl(name, this._formControl);\n }\n } catch (error) {\n this.logError('Error adding form control.', error);\n }\n\n // A multicasting observable that emits an event every time the value of the control changes, in the UI or programmatically.\n if (this._formControlSubscription) {\n this._formControlSubscription.unsubscribe();\n }\n this._formControlSubscription = this._formControl.valueChanges.subscribe((value: unknown): void => {\n // Creates a deep clone of an object, falling back to a JSON round-trip\n // when the view model contains non-cloneable values (functions, DOM nodes, ...).\n let viewModel: unknown;\n\n try {\n viewModel = structuredClone(this.viewModel());\n } catch {\n try {\n viewModel = JSON.parse(JSON.stringify(this.viewModel()));\n } catch {\n viewModel = this.viewModel();\n }\n }\n\n // Sets the value at path of object.\n this.setModelPropertyValue(viewModel, name, value);\n // Directly set the signal to a new value, and notify any dependents.\n try {\n this.viewModel.set(viewModel);\n } catch (error) {\n this.logError('Error updating view model.', error);\n }\n });\n\n // Synchronizes a standalone FormControl instance to a form control element.\n this.attachFormControlDirective();\n } else if (typeof name === 'string') {\n this.logWarning('Unsafe form control name was ignored.');\n }\n }\n }\n\n /**\n * Disables/enables the control.\n */\n private setFormControlStatus(): void {\n if (!this._formControl) {\n return;\n }\n const attributes = this.configuration()?.attributes;\n if (!attributes) {\n return;\n }\n \n if (Object.hasOwn(attributes, 'disabled')) {\n const disabledAttr = attributes['disabled'];\n if (disabledAttr == null || disabledAttr === false || disabledAttr === '') {\n // Remove disabled state\n if (this._formControl.disabled) {\n try {\n this._formControl.enable({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n }\n try {\n this._formControl.updateValueAndValidity({ onlySelf: true, emitEvent: false });\n } catch (e) {\n }\n return;\n }\n // Evaluates JavaScript code and executes it.\n const isDisabled = this.evaluateExpression(disabledAttr, this.viewModel);\n if (isDisabled === true || (typeof isDisabled === 'string' && isDisabled === 'true')) {\n if (this._formControl.enabled || !this._formControl.disabled) {\n try {\n // Disables the control.\n this._formControl.disable({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n }\n } else if (isDisabled === false || isDisabled === '' || isDisabled === null || isDisabled === undefined || (typeof isDisabled === 'string' && isDisabled === 'false')) {\n if (this._formControl.disabled) {\n try {\n // Enables the control.\n this._formControl.enable({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n }\n } else if (typeof isDisabled === 'boolean') {\n if (isDisabled && this._formControl.enabled) {\n try {\n this._formControl.disable({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n } else if (!isDisabled && this._formControl.disabled) {\n try {\n this._formControl.enable({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n }\n }\n }\n }\n\n /**\n * Add synchronous validators to this control.\n */\n private setFormControlValidators(): void {\n if (!this._formControl) {\n return;\n }\n\n // Always remove previously managed validators, even when the current\n // configuration has no validator-bearing attributes.\n if (this._managedValidatorFns.length > 0) {\n try {\n this._formControl.removeValidators(this._managedValidatorFns);\n } catch (e) {\n // Ignore\n }\n \n this._managedValidatorFns = [];\n \n try {\n this._formControl.updateValueAndValidity({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n }\n\n const attributes = this.configuration()?.attributes;\n if (attributes && Object.keys(attributes).length > 0 && this._componentRef?.location?.nativeElement) {\n const validators: ValidatorFn[] = [];\n // Validator that requires the control's value to be greater than or equal to the provided number.\n if (Object.hasOwn(attributes, 'min')) {\n const min = this.evaluateExpression(attributes['min'], this.viewModel);\n if (typeof(min) === 'number' && !isNaN(min)) {\n validators.push(Validators.min(min));\n }\n }\n\n // Validator that requires the control's value to be less than or equal to the provided number.\n if (Object.hasOwn(attributes, 'max')) {\n const max = this.evaluateExpression(attributes['max'], this.viewModel);\n if (typeof(max) === 'number' && !isNaN(max)) {\n validators.push(Validators.max(max));\n }\n }\n\n // Validator that requires the control have a non-empty value.\n if (Object.hasOwn(attributes, 'required')) {\n const required = this.evaluateExpression(attributes['required'], this.viewModel);\n if (required === true) {\n validators.push(Validators.required);\n }\n }\n\n // Validator that requires the control's value pass an email validation test.\n if (Object.hasOwn(attributes, 'email')) {\n const email = this.evaluateExpression(attributes['email'], this.viewModel);\n if (email === true) {\n validators.push(Validators.email);\n }\n }\n\n // Validator that requires the length of the control's value to be less than or equal to the provided maximum length.\n if (Object.hasOwn(attributes, 'maxlength')) {\n const maxLength = this.evaluateExpression(attributes['maxlength'], this.viewModel);\n if (typeof(maxLength) === 'number' && !isNaN(maxLength) && maxLength >= 0) {\n validators.push(Validators.maxLength(maxLength));\n }\n }\n\n // Validator that requires the length of the control's value to be greater than or equal to the provided minimum length.\n if (Object.hasOwn(attributes, 'minlength')) {\n const minLength = this.evaluateExpression(attributes['minlength'], this.viewModel);\n if (typeof(minLength) === 'number' && !isNaN(minLength) && minLength >= 0) {\n validators.push(Validators.minLength(minLength));\n }\n }\n\n // Validator that requires the control's value to match a regex pattern.\n // Configuration patterns are untrusted: cap their size and reject\n // nested quantifiers that can trigger catastrophic backtracking.\n if (Object.hasOwn(attributes, 'pattern')) {\n const pattern = this.evaluateExpression(attributes['pattern'], this.viewModel);\n const patternValidator = this.createPatternValidator(pattern);\n if (patternValidator) {\n validators.push(patternValidator);\n }\n }\n\n // Track and add the newly built managed validators.\n if (validators.length > 0) {\n this._managedValidatorFns = validators;\n try {\n this._formControl.addValidators(this._managedValidatorFns);\n } catch (e) {\n // Ignore\n }\n } else {\n this._managedValidatorFns = [];\n }\n // Recalculates the value and validation status of the control whenever the\n // managed validator set changes (including when it becomes empty).\n try {\n this._formControl.updateValueAndValidity({\n onlySelf: true,\n emitEvent: false\n });\n } catch (e) {\n // Ignore\n }\n } else {\n this._managedValidatorFns = [];\n }\n }\n\n /**\n * Builds a defensive `pattern` validator. Invalid, oversized or potentially\n * catastrophic regular expressions are ignored instead of blocking the UI.\n */\n private createPatternValidator(pattern: unknown): ValidatorFn | null {\n let regex: RegExp;\n\n if (typeof pattern === 'string') {\n if (pattern.length === 0 || pattern.length > MAX_PATTERN_LENGTH) {\n this.logWarning('Pattern validator was ignored because its source is empty or too long.');\n return null;\n }\n if (this.isUnsafeRegex(pattern)) {\n this.logWarning('Pattern validator was ignored because the expression is potentially unsafe.');\n return null;\n }\n\n try {\n const anchored = (pattern.startsWith('^') ? '' : '^') + pattern + (pattern.endsWith('$') ? '' : '$');\n regex = new RegExp(anchored);\n } catch (error) {\n this.logError('Pattern validator was ignored because the expression is invalid.', error);\n return null;\n }\n } else if (pattern instanceof RegExp) {\n if (pattern.source.length > MAX_PATTERN_LENGTH || this.isUnsafeRegex(pattern.source)) {\n this.logWarning('Pattern validator was ignored because the expression is potentially unsafe.');\n return null;\n }\n regex = pattern;\n } else {\n return null;\n }\n\n const baseValidator = Validators.pattern(regex);\n\n return (control: AbstractControl): ValidationErrors | null => {\n const value = control.value;\n\n if (value == null) {\n return baseValidator(control);\n }\n if (typeof value !== 'string' && typeof value !== 'number') {\n return { pattern: { requiredPattern: regex.toString() } };\n }\n if (typeof value === 'string' && value.length > MAX_PATTERN_INPUT_LENGTH) {\n return { pattern: { requiredPattern: regex.toString() } };\n }\n\n return baseValidator(control);\n };\n }\n\n /**\n * Heuristic check for regular expressions with nested/ambiguous quantifiers\n * (e.g. `(a+)+`, `(a*)*`, `(\\d+){2,}`) that can cause exponential backtracking.\n */\n private isUnsafeRegex(source: string): boolean {\n if (source.length > MAX_PATTERN_LENGTH) {\n return true;\n }\n if (/\\((?:[^()\\\\]|\\\\.)*[+*](?:[^()\\\\]|\\\\.)*\\)(?:[+*]|\\{\\d)/.test(source)) {\n return true;\n }\n if (/\\\\[1-9][+*{]/.test(source)) {\n return true;\n }\n if (/\\((?:\\.\\*|\\.\\+)[^)]*\\)[+*{]/.test(source)) {\n return true;\n }\n return false;\n }\n\n /**\n * Synchronizes a standalone FormControl instance to a form control element.\n */\n private attachFormControlDirective(): void {\n if (this._formControlDirective && this._componentRef?.injector && this._formControl) {\n try {\n const valueAccessors: ControlValueAccessor[] | null = this._componentRef.injector.get<ControlValueAccessor[] | null>(NG_VALUE_ACCESSOR, null);\n \n this._formControlDirective.valueAccessor = Array.isArray(valueAccessors) && valueAccessors.length > 0 ? valueAccessors[0] : null;\n this._formControlDirective.form = this._formControl;\n\n // A callback method that is invoked immediately after the default change detector has checked data-bound properties if at least one has changed, and before the view and content children are checked.\n this._formControlDirective.ngOnChanges({\n form: {\n firstChange: true,\n currentValue: this._formControl,\n previousValue: undefined,\n isFirstChange: (): true => true\n }\n });\n } catch (error) {\n this.logError('Error attaching form control directive.', error);\n }\n }\n }\n\n /**\n * Parses a dot/bracket path. Returns `null` when the path is malformed or\n * contains prototype-related segments (`__proto__`, `prototype`,\n * `constructor`), which protects both the view model and `FormGroup`.\n */\n private parsePath(property: Array<string> | string | null | undefined): string[] | null {\n if (property == null) {\n return null;\n }\n\n let pathArray: string[] | null = null;\n\n if (Array.isArray(property)) {\n pathArray = property\n .filter((segment: unknown): boolean => segment != null && segment !== '')\n .map((segment: unknown): string => String(segment));\n } else if (typeof property === 'string') {\n // Regex: ensure that we do not have '.' and brackets inside a segment.\n pathArray = property.match(/([^[.\\]])+/g);\n }\n\n if (!pathArray || pathArray.length === 0 || pathArray.length > MAX_PATH_DEPTH) {\n return null;\n }\n\n for (const segment of pathArray) {\n if (segment.length > MAX_PATH_SEGMENT_LENGTH) {\n return null;\n }\n if (FORBIDDEN_PATH_SEGMENTS.has(segment.toLowerCase())) {\n return null;\n }\n }\n\n return pathArray;\n }\n\n private isSafePath(property: Array<string> | string): boolean {\n return this.parsePath(property) !== null;\n }\n\n private defineOwn(target: object, key: string, value: unknown): void {\n Object.defineProperty(target, key, {\n value,\n writable: true,\n enumerable: true,\n configurable: true\n });\n }\n\n /**\n * Gets the value at path of object. If the resolved value is undefined, the defaultValue is returned in its place.\n * Only own properties are read; prototype-chain reads are blocked.\n * @param model The object.\n * @param property The path.\n * @param defaultValue The resolved value.\n */\n private getModelPropertyValue(model: unknown, property: Array<string> | string, defaultValue: unknown): unknown {\n if (model == null) {\n return defaultValue;\n }\n\n const pathArray = this.parsePath(property);\n if (!pathArray) {\n return defaultValue;\n }\n\n try {\n let current: unknown = model;\n\n for (const key of pathArray) {\n if (current == null) {\n return defaultValue;\n }\n const container = Object(current) as Record<string, unknown>;\n if (!Object.hasOwn(container, key)) {\n return defaultValue;\n }\n current = container[key];\n }\n\n return current != null ? current : defaultValue;\n } catch {\n return defaultValue;\n }\n }\n\n /**\n * Sets the value at path of object. If a portion of path doesn't exist, it's created.\n * Arrays are created for missing index properties while objects are created for all other missing properties.\n * Only own properties are traversed and written; prototype-related segments are rejected.\n * This method mutates object.\n * @param model The object.\n * @param property The path.\n * @param value The value.\n */\n private setModelPropertyValue(model: unknown, property: Array<string> | string, value: unknown): void {\n if (model == null) {\n return;\n }\n\n const pathArray = this.parsePath(property);\n if (!pathArray) {\n return;\n }\n\n try {\n let current: any = model;\n\n for (let index = 0; index < pathArray.length; index++) {\n const key = pathArray[index];\n const isLast = index === pathArray.length - 1;\n\n if (current == null || (typeof current !== 'object' && typeof current !== 'function')) {\n return;\n }\n\n if (isLast) {\n this.defineOwn(current, key, value);\n return;\n }\n\n const isNumericKey = /^\\d+$/.test(key);\n const existing = Object.hasOwn(current, key) ? current[key] : undefined;\n\n if (existing == null) {\n // Create array if key is numeric, otherwise object.\n const next: unknown = isNumericKey ? [] : {};\n this.defineOwn(current, key, next);\n current = next;\n } else if (isNumericKey && !Array.isArray(existing)) {\n // Try to convert to array if needed.\n if (typeof existing !== 'object') {\n return;\n }\n const next: unknown[] = [];\n this.defineOwn(current, key, next);\n current = next;\n } else if (!isNumericKey && typeof existing !== 'object') {\n const next: Record<string, unknown> = {};\n this.defineOwn(current, key, next);\n current = next;\n } else {\n current = existing;\n }\n }\n } catch (error) {\n this.logError('Error setting model property value.', error);\n }\n }\n\n /**\n * Updates specified input names to new values.\n */\n private setInputs(): void {\n const inputs = this.configuration()?.inputs;\n\n if (!inputs || typeof inputs !== 'object' || !this._componentRef) {\n return;\n }\n\n for (const inputName of Object.keys(inputs)) {\n try {\n // Updates a specified input name to a new value.\n this._componentRef.setInput(inputName, this.evaluateExpression(inputs[inputName], this.viewModel));\n } catch (error) {\n this.logError(`Error setting dynamic input \"${inputName}\".`, error);\n }\n }\n }\n\n /**\n * Set attribute values for an element in the DOM.\n *\n * Attribute names and values are validated: event handlers (`on*`),\n * namespaced attributes, `style`/`srcdoc`/`formaction` and unsafe URL\n * schemes are never applied. Non-primitive values are ignored so that\n * configuration data cannot invoke `toString()`/`toJSON()` hooks.\n */\n private setAttributes(): void {\n const attributes = this.configuration()?.attributes;\n const element = this._componentRef?.location?.nativeElement;\n\n if (!attributes || typeof attributes !== 'object' || !element) {\n return;\n }\n\n for (const attributeName of Object.keys(attributes)) {\n if (!this.isAllowedAttribute(attributeName)) {\n this.logWarning(`Attribute \"${attributeName}\" is not allowed and was skipped.`);\n continue;\n }\n\n try {\n const value = this.evaluateExpression(attributes[attributeName], this.viewModel);\n const stringValue = this.attributeValueToString(value);\n\n if (stringValue === undefined) {\n continue;\n }\n\n // Returns element's first attribute whose qualified name is qualifiedName, and null if there is no such attribute otherwise.\n const currentAttr = element.getAttribute(attributeName) as string | null;\n if (stringValue === currentAttr) {\n continue;\n }\n\n if (stringValue === null) {\n this._renderer.removeAttribute(element, attributeName);\n continue;\n }\n\n if (URL_ATTRIBUTES.has(attributeName.toLowerCase()) && !this.isSafeUrl(stringValue)) {\n this.logWarning(`Unsafe URL for attribute \"${attributeName}\" was ignored.`);\n continue;\n }\n\n this._renderer.setAttribute(element, attributeName, stringValue);\n } catch (error) {\n this.logError(`Error setting dynamic attribute \"${attributeName}\".`, error);\n }\n }\n }\n\n private isAllowedAttribute(name: string): boolean {\n if (typeof name !== 'string' || name.length === 0 || name.length > MAX_ATTRIBUTE_NAME_LENGTH) {\n return false;\n }\n\n const lower = name.toLowerCase();\n\n if (lower.startsWith('on')) {\n return false;\n }\n\n // Reject namespaces, whitespace and other non-standard attribute names.\n if (!/^[a-z][a-z0-9_.-]*$/i.test(name)) {\n return false;\n }\n\n if (lower.startsWith('data-') || lower.startsWith('aria-')) {\n return true;\n }\n\n return ALLOWED_ATTRIBUTES.has(lower);\n }\n\n /**\n * Returns `undefined` to skip the attribute entirely, `null` to remove it,\n * or a safe string value.\n */\n private attributeValueToString(value: unknown): string | null | undefined {\n if (value == null) {\n return null;\n }\n\n const type = typeof value;\n\n if (type !== 'string' && type !== 'number' && type !== 'boolean' && type !== 'bigint') {\n this.logWarning('Non-primitive attribute values are ignored.');\n return undefined;\n }\n\n const stringValue = String(value);\n\n if (stringValue.length > MAX_ATTRIBUTE_VALUE_LENGTH) {\n this.logWarning('Attribute value is too long and was ignored.');\n return undefined;\n }\n\n return stringValue;\n }\n\n private isSafeUrl(value: string): boolean {\n // Browsers ignore control characters and whitespace inside URL schemes.\n const normalized = value.replace(/[\\u0000-\\u0020\\u007f]/g, '').toLowerCase();\n\n if (normalized.length === 0) {\n return true;\n }\n\n const scheme = /^([a-z][a-z0-9+.-]*):/.exec(normalized);\n\n if (!scheme) {\n // Relative URL, fragment or query string.\n return true;\n }\n\n return scheme[1] === 'http' || scheme[1] === 'https' || scheme[1] === 'mailto' || scheme[1] === 'tel';\n }\n\n /**\n * Evaluates an expression with a small, allowlisted interpreter. No `eval`,\n * `Function` or other string-to-code primitive is used.\n * @param value The expression or literal value.\n * @param vmParam The view model (signal or plain value).\n * @param eventParam The event payload.\n * @returns Evaluated expression, `undefined` when the expression is rejected,\n * or the original value when it is a literal.\n */\n private evaluateExpression(value: unknown, vmParam?: unknown, eventParam?: unknown): unknown {\n if (typeof value !== 'string') {\n return value;\n }\n\n const hasVm = value.includes('$vm');\n const hasEvent = value.includes('$event');\n\n if (!hasVm && !hasEvent) {\n return value;\n }\n\n if ((hasVm && vmParam == null) || (hasEvent && eventParam == null)) {\n return value;\n }\n\n try {\n const viewModelInput = vmParam;\n const $vm = typeof viewModelInput === 'function' ? viewModelInput : (): unknown => viewModelInput;\n\n return evaluateSafeExpression(value, {\n $vm,\n $event: eventParam,\n $ev: eventParam\n });\n } catch {\n this.logWarning('Expression could not be evaluated safely and was ignored.');\n return undefined;\n }\n }\n\n private getViewModelValue(): unknown {\n const model = this.viewModel;\n return typeof model === 'function' ? (model as () => unknown)() : model;\n }\n\n private logWarning(message: string): void {\n if (isDevMode()) {\n console.warn(`[fg-dynamic] ${message}`);\n }\n }\n\n private logError(message: string, error?: unknown): void {\n if (!isDevMode()) {\n return;\n }\n const detail = error instanceof Error ? ` (${error.name})` : '';\n console.error(`[fg-dynamic] ${message}${detail}`);\n }\n\n /**\n * Cleans up every dynamically created resource: subscriptions, form control, value accessor directive and component reference.\n * Used both on component type change and on destroy.\n */\n private cleanup(): void {\n // Disposes the resources held by the output subscriptions.\n if (this._outputsSubscriptions) {\n this._outputsSubscriptions.forEach((s: Subscription): void => {\n try {\n s.unsubscribe();\n } catch (e) {\n // Ignore\n }\n });\n }\n\n this._outputsSubscriptions = [];\n this._currentOutputsConfig = undefined;\n\n // Disposes the resources held by the form control subscription.\n if (this._formControlSubscription) {\n try {\n this._formControlSubscription.unsubscribe();\n } catch (e) {\n // Ignore\n }\n }\n\n this._formControlSubscription = undefined;\n\n // Remove the managed control from the form group.\n if (this._formControl && this.formGroup()) {\n try {\n const attributes = this.configuration()?.attributes;\n const attributeName = attributes?.['name'];\n\n if (attributeName) {\n const controlName = this.evaluateExpression(attributeName, this.viewModel) as string;\n\n // Only remove the control if it is the one this component created, so that\n // a pre-existing control registered under the same name is left untouched.\n // Unsafe names (prototype segments) are never passed to `FormGroup`.\n if (typeof controlName === 'string' && controlName.length > 0 && this.isSafePath(controlName)) {\n const formGroup = this.formGroup();\n if (formGroup.get(controlName) === this._formControl) {\n try {\n formGroup.removeControl(controlName);\n } catch (e) {\n // Ignore\n }\n }\n }\n }\n } catch (e) {\n // Ignore\n }\n }\n\n this._formControl = undefined;\n this._managedValidatorFns = [];\n\n // A callback method that performs custom clean-up, invoked immediately before a directive, pipe, or service instance is destroyed.\n if (this._formControlDirective) {\n try {\n this._formControlDirective.ngOnDestroy();\n } catch (e) {\n // Ignore\n }\n }\n\n this._formControlDirective = undefined;\n\n // Destroys the component instance and all of the data structures associated with it.\n if (this._componentRef) {\n try {\n this._componentRef.destroy();\n } catch (e) {\n // Ignore\n }\n }\n \n this._componentRef = undefined;\n }\n\n /**\n * A callback method that performs custom clean-up, invoked immediately before a directive, pipe, or service instance is destroyed.\n */\n\tngOnDestroy(): void {\n this.cleanup();\n\t}\n}\n"],"mappings":";;;AAqBA,MAAM,oBAAoB;AAC1B,MAAM,aAAa;AACnB,MAAM,kBAAkB;AACxB,MAAM,uBAAuB;AAC7B,MAAM,uBAAuB;AAE7B,MAAM,uCAA4C,IAAI,IAAI;CACtD;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACH,CAAA;AAED,MAAM,cAAiC;CACnC;CAAO;CAAO;CAAM;CAAM;CAAM;CAAM;CAAM;CAAM;CAAM;CAAM;CAAM;CAAO;CAC3E;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;CAAK;AAC7F;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;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,WAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,GAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,iBAAA;EAAA,CAAA;EAAA,WAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,mBAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,iBAAe;IACjF,MAAM;IACT,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,eAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAC4E,eAAa;IACtF,MAAM;IACT,UAAA;GAAA,CAAA;EAAA,CAAA;CAAA;AAAA,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fg-dynamic-component",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"author": "Francesco Guagnano <guagnanofrancesco11@gmail.com>",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
|
-
"url": "https://github.com/ciccio-
|
|
8
|
+
"url": "https://github.com/ciccio-1337/fg-dynamic-component.git"
|
|
9
9
|
},
|
|
10
10
|
"keywords": [
|
|
11
11
|
"angular",
|
|
@@ -18,24 +18,23 @@
|
|
|
18
18
|
"life-cycle"
|
|
19
19
|
],
|
|
20
20
|
"peerDependencies": {
|
|
21
|
-
"@angular/common": "
|
|
22
|
-
"@angular/core": "
|
|
23
|
-
},
|
|
24
|
-
"dependencies": {
|
|
25
|
-
"tslib": "2.6.2"
|
|
21
|
+
"@angular/common": "22.1.6",
|
|
22
|
+
"@angular/core": "22.1.6"
|
|
26
23
|
},
|
|
27
24
|
"sideEffects": false,
|
|
28
25
|
"module": "fesm2022/fg-dynamic-component.mjs",
|
|
29
|
-
"typings": "
|
|
26
|
+
"typings": "types/fg-dynamic-component.d.ts",
|
|
30
27
|
"exports": {
|
|
31
28
|
"./package.json": {
|
|
32
29
|
"default": "./package.json"
|
|
33
30
|
},
|
|
34
31
|
".": {
|
|
35
|
-
"types": "./
|
|
36
|
-
"esm2022": "./esm2022/fg-dynamic-component.mjs",
|
|
37
|
-
"esm": "./esm2022/fg-dynamic-component.mjs",
|
|
32
|
+
"types": "./types/fg-dynamic-component.d.ts",
|
|
38
33
|
"default": "./fesm2022/fg-dynamic-component.mjs"
|
|
39
34
|
}
|
|
35
|
+
},
|
|
36
|
+
"type": "module",
|
|
37
|
+
"dependencies": {
|
|
38
|
+
"tslib": "^2.3.0"
|
|
40
39
|
}
|
|
41
40
|
}
|