ngx-wapp-components 3.4.2 → 3.4.3-alpha.2
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/fesm2022/ngx-wapp-components-home-preview.mjs +1041 -0
- package/fesm2022/ngx-wapp-components-home-preview.mjs.map +1 -0
- package/fesm2022/ngx-wapp-components-schema-form.mjs +1018 -0
- package/fesm2022/ngx-wapp-components-schema-form.mjs.map +1 -0
- package/fesm2022/ngx-wapp-components.mjs +825 -576
- package/fesm2022/ngx-wapp-components.mjs.map +1 -1
- package/home-preview/README.md +53 -0
- package/package.json +25 -2
- package/schema-form/README.md +151 -0
- package/types/ngx-wapp-components-home-preview.d.ts +572 -0
- package/types/ngx-wapp-components-schema-form.d.ts +253 -0
- package/types/ngx-wapp-components.d.ts +402 -338
- package/types/ngx-wapp-components.d.ts.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngx-wapp-components-schema-form.mjs","sources":["../../../projects/wapp-components/schema-form/src/lib/models/w-json-schema.model.ts","../../../projects/wapp-components/schema-form/src/lib/models/w-schema-form-translations.model.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-secret-field/w-schema-form-secret-field.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-secret-field/w-schema-form-secret-field.component.html","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-color-field/w-schema-form-color-field.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-color-field/w-schema-form-color-field.component.html","../../../projects/wapp-components/schema-form/src/lib/w-schema-form/schema-inspection.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-field-wrapper/w-schema-form-field-wrapper.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-field-wrapper/w-schema-form-field-wrapper.component.html","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-group/w-schema-form-group.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-group/w-schema-form-group.component.html","../../../projects/wapp-components/schema-form/src/lib/w-schema-form/native-control.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-multiselect/w-schema-form-multiselect.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-multiselect/w-schema-form-multiselect.component.html","../../../projects/wapp-components/schema-form/src/lib/w-schema-form-toggle/w-schema-form-toggle.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form/w-schema-form-field-types.module.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form/w-schema-form.component.ts","../../../projects/wapp-components/schema-form/src/lib/w-schema-form/w-schema-form.component.html","../../../projects/wapp-components/schema-form/src/public-api.ts","../../../projects/wapp-components/schema-form/src/ngx-wapp-components-schema-form.ts"],"sourcesContent":["/** JSON Schema dialects accepted by `w-schema-form`. */\r\nexport type WSchemaFormDialect = 'draft-07' | '2020-12';\r\n\r\n/** Single types accepted by `w-schema-form`. Arrays only as `uniqueItems` + `items` enum or const options. */\r\nexport type WJsonSchemaType = 'object' | 'string' | 'number' | 'integer' | 'boolean' | 'array';\r\n\r\n/**\r\n * `x-wapping-secret` annotation (central design of connectors-management).\r\n * The browser ignores its content; it only marks the field as a secret.\r\n */\r\nexport interface WJsonSchemaSecretAnnotation {\r\n vaultProfile?: string;\r\n nameTemplate?: string;\r\n}\r\n\r\n/**\r\n * Presentation groups of `x-wapping-group` (SFP-001), listed in their visual order. The annotation is only\r\n * accepted on direct properties of the root; it never changes the model, the JSON Pointers or the validation.\r\n */\r\nexport const W_SCHEMA_FORM_GROUPS = ['connector', 'connection', 'capabilities', 'mapping'] as const;\r\n\r\nexport type WSchemaFormGroup = typeof W_SCHEMA_FORM_GROUPS[number];\r\n\r\n/**\r\n * Group declared at the root with `x-wapping-groups` (SFP-007). When the schema declares groups,\r\n * `x-wapping-group` must use one of their keys and the groups are shown in the declared order.\r\n */\r\nexport interface WSchemaFormDeclaredGroup {\r\n key: string;\r\n title: string;\r\n description?: string;\r\n}\r\n\r\n/**\r\n * Option of `oneOf`/`anyOf` (SFP-004): shown by `title`, stored by `const`. Accepted on scalar fields and on the\r\n * `items` of `uniqueItems` arrays; any other use of `oneOf`/`anyOf` is a configuration error.\r\n */\r\nexport interface WJsonSchemaOption {\r\n const: unknown;\r\n title?: string;\r\n description?: string;\r\n}\r\n\r\n/**\r\n * JSON Schema accepted as input. Only the keywords listed in the design are supported;\r\n * any other keyword is reported as a configuration error at runtime.\r\n */\r\nexport interface WJsonSchema {\r\n $schema?: string;\r\n $id?: string;\r\n $comment?: string;\r\n title?: string;\r\n description?: string;\r\n type?: WJsonSchemaType;\r\n properties?: Record<string, WJsonSchema>;\r\n required?: string[];\r\n additionalProperties?: false;\r\n enum?: unknown[];\r\n const?: unknown;\r\n default?: unknown;\r\n minimum?: number;\r\n maximum?: number;\r\n minLength?: number;\r\n maxLength?: number;\r\n pattern?: string;\r\n items?: WJsonSchema;\r\n uniqueItems?: boolean;\r\n $ref?: string;\r\n $defs?: Record<string, WJsonSchema>;\r\n definitions?: Record<string, WJsonSchema>;\r\n readOnly?: boolean;\r\n writeOnly?: boolean;\r\n 'x-wapping-secret'?: WJsonSchemaSecretAnnotation;\r\n /** Rendering annotation for supported custom fields and consumer-provided reference selectors. */\r\n 'x-wapping-widget'?: 'color' | 'image' | 'menu-item' | 'service-program' | 'product-list' | 'store';\r\n /** Group of a direct property of the root: a fixed group (SFP-001) or a declared key (SFP-007). */\r\n 'x-wapping-group'?: WSchemaFormGroup | string;\r\n /** Groups declared at the root (SFP-007). */\r\n 'x-wapping-groups'?: WSchemaFormDeclaredGroup[];\r\n /** Unsupported keywords are accepted by the type and rejected explicitly at runtime. */\r\n [keyword: string]: unknown;\r\n}\r\n","/** Label and help text override for a field identified by JSON Pointer (SFC-D07). */\r\nexport interface WSchemaFormFieldTranslation {\r\n label?: string;\r\n description?: string;\r\n /**\r\n * Display labels of `enum` options (single select and `uniqueItems` enum arrays), keyed by the technical value.\r\n * Only the shown text changes: the model and the emitted configuration keep the technical value. A value\r\n * without label (or with an empty one) is shown as the technical value (CM-012).\r\n */\r\n options?: Readonly<Record<string, string>>;\r\n}\r\n\r\nexport interface WSchemaFormTranslations {\r\n configurationError: string;\r\n invalidValues: string;\r\n secretConfigured: string;\r\n secretPending: string;\r\n secretReplaceHint: string;\r\n showSecret: string;\r\n hideSecret: string;\r\n /** Visible label of the select-all checkbox used by enum array fields. */\r\n selectAll?: string;\r\n /** Optional overrides of schema `title`/`description`, keyed by JSON Pointer (e.g. `/account/clientId`). */\r\n fields?: Readonly<Record<string, WSchemaFormFieldTranslation>>;\r\n /**\r\n * Optional headings of the groups, keyed by group: the fixed `x-wapping-group` groups (missing ones keep the\r\n * Spanish defaults, SFP-001) or the keys declared with `x-wapping-groups` (missing ones keep the schema title,\r\n * SFP-007).\r\n */\r\n groups?: Readonly<Record<string, string>>;\r\n}\r\n\r\n/** Default Spanish texts. Frozen: consumers must pass their own object instead of mutating this one. */\r\nexport const W_SCHEMA_FORM_DEFAULT_TRANSLATIONS: Readonly<WSchemaFormTranslations> = Object.freeze({\r\n configurationError: 'No se puede mostrar el formulario: la configuración o el esquema no son válidos.',\r\n invalidValues: 'Revisa los valores marcados antes de guardar.',\r\n secretConfigured: 'Configurado',\r\n secretPending: 'Pendiente',\r\n secretReplaceHint: 'Déjalo vacío para conservar el valor actual o escribe uno nuevo para sustituirlo.',\r\n showSecret: 'Mostrar valor',\r\n hideSecret: 'Ocultar valor',\r\n selectAll: 'Seleccionar todo',\r\n groups: Object.freeze({\r\n connector: 'Conector',\r\n connection: 'Conexión',\r\n capabilities: 'Capacidades',\r\n mapping: 'Mapeo'\r\n })\r\n});\r\n","import { Component, DestroyRef, OnInit, inject } from '@angular/core';\r\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\r\nimport { FormControl, ReactiveFormsModule } from '@angular/forms';\r\nimport { FieldType, FormlyFieldConfig, FormlyFieldProps } from '@ngx-formly/core';\r\nimport { ButtonModule } from 'primeng/button';\r\nimport { InputTextModule } from 'primeng/inputtext';\r\n\r\n/** Formly type name of the secret field (internal to `w-schema-form`). */\r\nexport const W_SCHEMA_FORM_SECRET_FIELD_TYPE = 'w-schema-form-secret';\r\n\r\n/** Props set by `w-schema-form` on a secret field. The control is never part of the form model. */\r\nexport interface WSchemaFormSecretFieldProps extends FormlyFieldProps {\r\n secretControl: FormControl<string>;\r\n secretStatusText: string;\r\n secretHint?: string;\r\n showSecretLabel: string;\r\n hideSecretLabel: string;\r\n}\r\n\r\n/**\r\n * Password entry for `writeOnly` + `x-wapping-secret` fields (SF-006, SF-008). It starts empty,\r\n * never receives a stored value and uses `autocomplete=\"new-password\"` (SFC-D06).\r\n */\r\n@Component({\r\n selector: 'w-schema-form-secret-field',\r\n standalone: true,\r\n imports: [ReactiveFormsModule, InputTextModule, ButtonModule],\r\n templateUrl: './w-schema-form-secret-field.component.html',\r\n styleUrls: ['./w-schema-form-secret-field.component.scss']\r\n})\r\nexport class WSchemaFormSecretFieldComponent extends FieldType<FormlyFieldConfig<WSchemaFormSecretFieldProps>>\r\n implements OnInit {\r\n private readonly destroyRef = inject(DestroyRef);\r\n control = new FormControl<string>('', { nonNullable: true });\r\n statusText = '';\r\n hint?: string;\r\n visible = false;\r\n inputType: 'password' | 'text' = 'password';\r\n toggleLabel = '';\r\n\r\n get statusId(): string {\r\n return `${this.id}-status`;\r\n }\r\n\r\n get hintId(): string {\r\n return `${this.id}-hint`;\r\n }\r\n\r\n get describedBy(): string {\r\n return this.hint ? `${this.statusId} ${this.hintId}` : this.statusId;\r\n }\r\n\r\n ngOnInit(): void {\r\n this.control = this.props.secretControl;\r\n this.statusText = this.props.secretStatusText;\r\n this.hint = this.props.secretHint;\r\n this.applyVisibility(false);\r\n // When `w-schema-form` discards the typed value (submit, input change, destroy) the entry hides again.\r\n this.control.valueChanges.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(value => {\r\n if (value === '' && this.visible) {\r\n this.applyVisibility(false);\r\n }\r\n });\r\n }\r\n\r\n toggleVisibility(): void {\r\n this.applyVisibility(!this.visible);\r\n }\r\n\r\n private applyVisibility(visible: boolean): void {\r\n this.visible = visible;\r\n this.inputType = visible ? 'text' : 'password';\r\n this.toggleLabel = visible ? this.props.hideSecretLabel : this.props.showSecretLabel;\r\n }\r\n}\r\n","<div class=\"w-schema-form-secret\">\r\n <div class=\"w-schema-form-secret__entry\">\r\n <input\r\n pInputText\r\n class=\"w-schema-form-secret__input\"\r\n [id]=\"id\"\r\n [type]=\"inputType\"\r\n autocomplete=\"new-password\"\r\n spellcheck=\"false\"\r\n [formControl]=\"control\"\r\n [attr.aria-describedby]=\"describedBy\" />\r\n <button\r\n type=\"button\"\r\n pButton\r\n [text]=\"true\"\r\n class=\"w-schema-form-secret__toggle\"\r\n [attr.aria-label]=\"toggleLabel\"\r\n [attr.aria-pressed]=\"visible\"\r\n [attr.aria-controls]=\"id\"\r\n (click)=\"toggleVisibility()\">\r\n <i pButtonIcon class=\"pi\" [class.pi-eye]=\"!visible\" [class.pi-eye-slash]=\"visible\" aria-hidden=\"true\"></i>\r\n </button>\r\n </div>\r\n <small [id]=\"statusId\" class=\"w-schema-form-secret__status\">{{ statusText }}</small>\r\n @if (hint) {\r\n <small [id]=\"hintId\" class=\"w-schema-form-secret__hint\">{{ hint }}</small>\r\n }\r\n</div>\r\n","import { Component } from '@angular/core';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { FieldType, FieldTypeConfig, FormlyModule } from '@ngx-formly/core';\r\nimport { ColorPickerModule } from 'primeng/colorpicker';\r\nimport { InputTextModule } from 'primeng/inputtext';\r\n\r\n/** Formly type name of the color field (internal to `w-schema-form`). */\r\nexport const W_SCHEMA_FORM_COLOR_FIELD_TYPE = 'w-schema-form-color';\r\n\r\nconst HEX_COLOR = /^#[0-9A-Fa-f]{6}$/;\r\n\r\n/**\r\n * Text entry plus PrimeNG color picker for `x-wapping-widget: \"color\"` string fields (SF-010).\r\n * Both edit the same control; the picker only follows valid `#rrggbb` values (SFCW-D05).\r\n */\r\n@Component({\r\n selector: 'w-schema-form-color-field',\r\n standalone: true,\r\n imports: [ReactiveFormsModule, FormsModule, FormlyModule, InputTextModule, ColorPickerModule],\r\n templateUrl: './w-schema-form-color-field.component.html',\r\n styleUrls: ['./w-schema-form-color-field.component.scss']\r\n})\r\nexport class WSchemaFormColorFieldComponent extends FieldType<FieldTypeConfig> {\r\n get pickerValue(): string | null {\r\n const value: unknown = this.formControl.value;\r\n return typeof value === 'string' && HEX_COLOR.test(value) ? value : null;\r\n }\r\n\r\n onPick(value: unknown): void {\r\n if (typeof value !== 'string' || !HEX_COLOR.test(value) || value === this.formControl.value) {\r\n return;\r\n }\r\n this.formControl.setValue(value);\r\n this.formControl.markAsDirty();\r\n this.formControl.markAsTouched();\r\n }\r\n}\r\n","<div class=\"w-schema-form-color\" [class.w-schema-form-color--empty]=\"!pickerValue\">\r\n <input\r\n pInputText\r\n class=\"w-schema-form-color__input\"\r\n type=\"text\"\r\n spellcheck=\"false\"\r\n autocomplete=\"off\"\r\n [id]=\"id\"\r\n [formControl]=\"formControl\"\r\n [formlyAttributes]=\"field\" />\r\n <p-colorpicker\r\n class=\"w-schema-form-color__picker\"\r\n format=\"hex\"\r\n appendTo=\"body\"\r\n [ngModel]=\"pickerValue\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n [disabled]=\"formControl.disabled\"\r\n (ngModelChange)=\"onPick($event)\">\r\n </p-colorpicker>\r\n</div>\r\n","import {\r\n W_SCHEMA_FORM_GROUPS, WJsonSchema, WSchemaFormDeclaredGroup, WSchemaFormDialect\r\n} from '../models/w-json-schema.model';\r\n\r\nexport const DRAFT_07_URI = 'http://json-schema.org/draft-07/schema#';\r\nexport const DRAFT_2020_12_URI = 'https://json-schema.org/draft/2020-12/schema';\r\nexport const SECRET_KEYWORD = 'x-wapping-secret';\r\n/** Rendering annotation for custom Formly fields. */\r\nexport const WIDGET_KEYWORD = 'x-wapping-widget';\r\nexport const COLOR_WIDGET = 'color';\r\nexport const IMAGE_WIDGET = 'image';\r\nexport const REFERENCE_WIDGETS: ReadonlySet<string> = new Set([\r\n 'menu-item', 'service-program', 'product-list', 'store'\r\n]);\r\nexport const GROUP_KEYWORD = 'x-wapping-group';\r\n/** SFP-007: groups declared at the root of the schema (key, title, optional description, order). */\r\nexport const GROUPS_KEYWORD = 'x-wapping-groups';\r\n/** Internal Formly prop carrying the JSON Pointer of a property field. */\r\nexport const POINTER_PROP = 'wSchemaFormPointer';\r\n\r\nconst ALLOWED_KEYWORDS: ReadonlySet<string> = new Set([\r\n '$schema', '$id', '$comment', 'title', 'description', 'type', 'properties', 'required',\r\n 'additionalProperties', 'enum', 'const', 'default', 'minimum', 'maximum', 'minLength',\r\n 'maxLength', 'pattern', 'items', 'uniqueItems', '$ref', '$defs', 'definitions', 'readOnly',\r\n 'writeOnly', 'oneOf', 'anyOf', SECRET_KEYWORD, WIDGET_KEYWORD, GROUP_KEYWORD, GROUPS_KEYWORD\r\n]);\r\nconst OPTION_KEYWORDS: ReadonlySet<string> = new Set(['const', 'title', 'description']);\r\nconst OPTION_LISTS = ['oneOf', 'anyOf'] as const;\r\nconst ROOT_PROPERTY = /^#\\/properties\\/[^/]+$/;\r\nconst GROUPS: ReadonlySet<unknown> = new Set(W_SCHEMA_FORM_GROUPS);\r\nconst GROUP_KEY = /^[a-z][a-zA-Z0-9-]*$/;\r\nconst GROUP_MEMBERS: ReadonlySet<string> = new Set(['key', 'title', 'description']);\r\nconst SUPPORTED_TYPES: ReadonlySet<string> = new Set(['object', 'string', 'number', 'integer', 'boolean', 'array']);\r\nconst LOCAL_REFERENCE = /^#\\/(\\$defs|definitions)\\/[^/]+$/;\r\n\r\n/** Configuration problem of the schema or of the inputs. Messages never contain values. */\r\nexport class SchemaFormConfigurationError extends Error {}\r\n\r\nexport type JsonRecord = Record<string, unknown>;\r\n\r\nexport function isRecord(value: unknown): value is JsonRecord {\r\n return typeof value === 'object' && value !== null && !Array.isArray(value);\r\n}\r\n\r\n/** SFP-004: options declared as `oneOf`/`anyOf` of `const` (+ optional `title`), shown by title, stored by const. */\r\nexport function hasConstOptions(schema: unknown): boolean {\r\n return isRecord(schema) && OPTION_LISTS.some(keyword => isConstOptionList(schema[keyword]));\r\n}\r\n\r\nfunction isConstOptionList(value: unknown): boolean {\r\n return Array.isArray(value) && value.length > 0 && value.every(option =>\r\n isRecord(option) && Object.prototype.hasOwnProperty.call(option, 'const') &&\r\n Object.keys(option).every(keyword => OPTION_KEYWORDS.has(keyword)) &&\r\n (option['title'] === undefined || typeof option['title'] === 'string'));\r\n}\r\n\r\nexport function escapePointerSegment(segment: string): string {\r\n return segment.replace(/~/g, '~0').replace(/\\//g, '~1');\r\n}\r\n\r\nexport function pointerSegments(pointer: string): string[] {\r\n return pointer.split('/').slice(1).map(segment => segment.replace(/~1/g, '/').replace(/~0/g, '~'));\r\n}\r\n\r\n/** SF-003: the declared `$schema` and the `dialect` input must agree; without both, draft-07 (SFC-D05). */\r\nexport function resolveDialect(schema: WJsonSchema, dialect: WSchemaFormDialect | undefined): WSchemaFormDialect {\r\n if (dialect !== undefined && dialect !== 'draft-07' && dialect !== '2020-12') {\r\n throw new SchemaFormConfigurationError('Unsupported dialect input.');\r\n }\r\n let declared: WSchemaFormDialect | undefined;\r\n if (schema.$schema !== undefined) {\r\n if (schema.$schema === DRAFT_07_URI) {\r\n declared = 'draft-07';\r\n } else if (schema.$schema === DRAFT_2020_12_URI) {\r\n declared = '2020-12';\r\n } else {\r\n throw new SchemaFormConfigurationError('Unsupported JSON Schema dialect declared in $schema.');\r\n }\r\n }\r\n if (dialect !== undefined && declared !== undefined && dialect !== declared) {\r\n throw new SchemaFormConfigurationError('The dialect input does not match the $schema declared by the schema.');\r\n }\r\n return declared ?? dialect ?? 'draft-07';\r\n}\r\n\r\n/**\r\n * SF-004/SF-005/SF-006: checks the closed list of constructions and returns the JSON Pointers of the\r\n * secret fields (string + writeOnly + x-wapping-secret, only along the `properties` chain).\r\n */\r\nexport function inspectSchema(schema: WJsonSchema): string[] {\r\n if (schema.type !== 'object') {\r\n throw new SchemaFormConfigurationError('The schema root must be an object schema.');\r\n }\r\n const groups = readDeclaredGroups(schema);\r\n const secrets: string[] = [];\r\n visit(schema, '#', '', secrets, groups ? new Set(groups.map(group => group.key)) : GROUPS);\r\n return secrets;\r\n}\r\n\r\n/** SFP-007: the declared groups of the root, or undefined when the schema does not declare them. */\r\nexport function readDeclaredGroups(schema: WJsonSchema): WSchemaFormDeclaredGroup[] | undefined {\r\n if (!(GROUPS_KEYWORD in schema)) {\r\n return undefined;\r\n }\r\n const groups = (schema as JsonRecord)[GROUPS_KEYWORD];\r\n const keys = new Set<string>();\r\n const valid = Array.isArray(groups) && groups.length > 0 && groups.every(group => {\r\n if (!isRecord(group) || !Object.keys(group).every(member => GROUP_MEMBERS.has(member))) {\r\n return false;\r\n }\r\n const { key, title, description } = group;\r\n if (typeof key !== 'string' || !GROUP_KEY.test(key) || keys.has(key) ||\r\n typeof title !== 'string' || title.trim() === '' ||\r\n (description !== undefined && typeof description !== 'string')) {\r\n return false;\r\n }\r\n keys.add(key);\r\n return true;\r\n });\r\n if (!valid) {\r\n throw new SchemaFormConfigurationError(\r\n `${GROUPS_KEYWORD} must be a non-empty list of groups with a unique key, a title and an optional description.`);\r\n }\r\n return groups as WSchemaFormDeclaredGroup[];\r\n}\r\n\r\nfunction visit(node: unknown, at: string, instancePath: string | null, secrets: string[],\r\n groups: ReadonlySet<unknown>): void {\r\n if (!isRecord(node)) {\r\n throw new SchemaFormConfigurationError(`The schema at ${at} must be an object.`);\r\n }\r\n for (const keyword of Object.keys(node)) {\r\n if (!ALLOWED_KEYWORDS.has(keyword)) {\r\n throw new SchemaFormConfigurationError(`Unsupported keyword \"${keyword}\" at ${at}.`);\r\n }\r\n }\r\n if (GROUPS_KEYWORD in node && at !== '#') {\r\n throw new SchemaFormConfigurationError(`${GROUPS_KEYWORD} is supported only at the root, not at ${at}.`);\r\n }\r\n const type = node['type'];\r\n if (type !== undefined && (typeof type !== 'string' || !SUPPORTED_TYPES.has(type))) {\r\n throw new SchemaFormConfigurationError(`Unsupported type at ${at}; a single supported type is required.`);\r\n }\r\n if ('additionalProperties' in node && node['additionalProperties'] !== false) {\r\n throw new SchemaFormConfigurationError(`Only additionalProperties false is supported at ${at}.`);\r\n }\r\n for (const keyword of OPTION_LISTS) {\r\n if (keyword in node && (!isConstOptionList(node[keyword]) || type === 'object' || type === 'array' ||\r\n 'enum' in node || 'properties' in node)) {\r\n throw new SchemaFormConfigurationError(\r\n `${keyword} is supported only as a list of const options of a scalar field at ${at}.`);\r\n }\r\n }\r\n if ('$ref' in node) {\r\n const reference = node['$ref'];\r\n if (typeof reference !== 'string' || !LOCAL_REFERENCE.test(reference)) {\r\n throw new SchemaFormConfigurationError(`Only local references to $defs or definitions are supported at ${at}.`);\r\n }\r\n }\r\n if (type === 'array' || 'items' in node || 'uniqueItems' in node) {\r\n const items = node['items'];\r\n if (type !== 'array' || node['uniqueItems'] !== true || !isRecord(items) ||\r\n !(Array.isArray(items['enum']) || hasConstOptions(items))) {\r\n throw new SchemaFormConfigurationError(`Arrays are supported only with uniqueItems and an items enum at ${at}.`);\r\n }\r\n visit(items, `${at}/items`, null, secrets, groups);\r\n }\r\n if ('properties' in node) {\r\n const properties = node['properties'];\r\n if (!isRecord(properties)) {\r\n throw new SchemaFormConfigurationError(`properties must be an object at ${at}.`);\r\n }\r\n for (const [name, child] of Object.entries(properties)) {\r\n const segment = escapePointerSegment(name);\r\n visit(child, `${at}/properties/${segment}`, instancePath === null ? null : `${instancePath}/${segment}`, secrets,\r\n groups);\r\n }\r\n }\r\n for (const definitionsKeyword of ['$defs', 'definitions']) {\r\n if (definitionsKeyword in node) {\r\n const definitions = node[definitionsKeyword];\r\n if (!isRecord(definitions)) {\r\n throw new SchemaFormConfigurationError(`${definitionsKeyword} must be an object at ${at}.`);\r\n }\r\n for (const [name, child] of Object.entries(definitions)) {\r\n visit(child, `${at}/${definitionsKeyword}/${escapePointerSegment(name)}`, null, secrets, groups);\r\n }\r\n }\r\n }\r\n if (SECRET_KEYWORD in node) {\r\n if (!isRecord(node[SECRET_KEYWORD]) || type !== 'string' || node['writeOnly'] !== true ||\r\n instancePath === null || instancePath === '') {\r\n throw new SchemaFormConfigurationError(\r\n `${SECRET_KEYWORD} requires a string property with writeOnly true outside arrays and definitions at ${at}.`);\r\n }\r\n secrets.push(instancePath);\r\n }\r\n if (WIDGET_KEYWORD in node) {\r\n const widget = node[WIDGET_KEYWORD];\r\n const colorOrImage = widget === COLOR_WIDGET || widget === IMAGE_WIDGET;\r\n const reference = typeof widget === 'string' && REFERENCE_WIDGETS.has(widget);\r\n if ((!colorOrImage && !reference) ||\r\n (colorOrImage && type !== 'string') ||\r\n (reference && type !== 'integer') ||\r\n 'enum' in node || 'const' in node || node['writeOnly'] === true || SECRET_KEYWORD in node) {\r\n throw new SchemaFormConfigurationError(\r\n `${WIDGET_KEYWORD} supports color/image on editable strings and reference selectors on editable integers without enum or const at ${at}.`);\r\n }\r\n }\r\n if (GROUP_KEYWORD in node && (!ROOT_PROPERTY.test(at) || !groups.has(node[GROUP_KEYWORD]))) {\r\n throw new SchemaFormConfigurationError(\r\n `${GROUP_KEYWORD} requires one of ${[...groups].join(', ')} on a direct property of the root at ${at}.`);\r\n }\r\n}\r\n\r\n/** Reads the property schema at a JSON Pointer following only `properties`. */\r\nexport function readPropertySchema(schema: WJsonSchema, pointer: string): WJsonSchema {\r\n let current: WJsonSchema = schema;\r\n for (const segment of pointerSegments(pointer)) {\r\n const next = current.properties?.[segment];\r\n if (!next) {\r\n throw new SchemaFormConfigurationError('A secret path does not exist in the schema.');\r\n }\r\n current = next;\r\n }\r\n return current;\r\n}\r\n\r\n/** Public schema: secret properties and their `required` entries removed (design, Secretos). */\r\nexport function buildPublicSchema(schema: WJsonSchema, secretPaths: ReadonlyArray<string>): WJsonSchema {\r\n const copy = structuredClone(schema);\r\n for (const path of secretPaths) {\r\n const segments = pointerSegments(path);\r\n const name = segments.pop() as string;\r\n const parent = readPropertySchema(copy, segments.map(s => `/${escapePointerSegment(s)}`).join(''));\r\n if (parent.properties) {\r\n delete parent.properties[name];\r\n }\r\n if (parent.required) {\r\n parent.required = parent.required.filter(required => required !== name);\r\n }\r\n }\r\n return copy;\r\n}\r\n\r\n/**\r\n * Copy for Formly where each property carries its JSON Pointer (labels by pointer and secrets). Properties that\r\n * reference a local object definition (`$ref` to `$defs`/`definitions` with `properties`) are expanded per use\r\n * site, so the nested fields get the pointer of the instance they edit (SF-004, SFC-D07). Validation keeps using\r\n * the original schema; this copy is only rendered.\r\n */\r\nexport function annotatePointers(schema: WJsonSchema): WJsonSchema {\r\n const copy = structuredClone(schema);\r\n annotate(copy, '', schema, []);\r\n return copy;\r\n}\r\n\r\nfunction annotate(node: WJsonSchema, pointer: string, root: WJsonSchema, expanding: ReadonlyArray<string>): void {\r\n const properties = node.properties ?? {};\r\n for (const name of Object.keys(properties)) {\r\n const childPointer = `${pointer}/${escapePointerSegment(name)}`;\r\n let child = properties[name];\r\n let chain = expanding;\r\n const reference = child.$ref;\r\n if (typeof reference === 'string') {\r\n const target = resolveLocalReference(root, reference);\r\n if (isRecord(target) && isRecord(target['properties'])) {\r\n if (expanding.includes(reference)) {\r\n throw new SchemaFormConfigurationError(`Recursive local reference ${reference} is not supported.`);\r\n }\r\n const { $ref: _reference, ...siblings } = child;\r\n child = { ...(structuredClone(target) as WJsonSchema), ...siblings };\r\n properties[name] = child;\r\n chain = [...expanding, reference];\r\n }\r\n }\r\n child['widget'] = { formlyConfig: { props: { [POINTER_PROP]: childPointer } } };\r\n annotate(child, childPointer, root, chain);\r\n }\r\n}\r\n\r\nfunction resolveLocalReference(root: WJsonSchema, reference: string): unknown {\r\n const match = LOCAL_REFERENCE.exec(reference);\r\n if (!match) {\r\n return undefined;\r\n }\r\n const definitions = root[match[1]];\r\n const name = pointerSegments(reference).pop() as string;\r\n return isRecord(definitions) ? definitions[name] : undefined;\r\n}\r\n\r\n/** True when the values contain an own property at the JSON Pointer (any value, including null). */\r\nexport function hasValueAt(values: JsonRecord, pointer: string): boolean {\r\n let current: unknown = values;\r\n for (const segment of pointerSegments(pointer)) {\r\n if (!isRecord(current) || !Object.prototype.hasOwnProperty.call(current, segment)) {\r\n return false;\r\n }\r\n current = current[segment];\r\n }\r\n return true;\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { FieldWrapper, FormlyModule } from '@ngx-formly/core';\r\nimport { TooltipModule } from 'primeng/tooltip';\r\n\r\n/** Formly wrapper name used by every leaf field of `w-schema-form` (internal). */\r\nexport const W_SCHEMA_FORM_FIELD_WRAPPER = 'w-schema-form-field';\r\n\r\n/**\r\n * Label, required marker, validation message and `description` as a help tooltip. It follows the help icon +\r\n * PrimeNG `pTooltip` pattern of the library `w-input-label` (which lives in the primary entry point and is not\r\n * standalone, so it cannot be imported here without coupling the entry points).\r\n */\r\n@Component({\r\n selector: 'w-schema-form-field-wrapper',\r\n standalone: true,\r\n imports: [FormlyModule, TooltipModule],\r\n templateUrl: './w-schema-form-field-wrapper.component.html',\r\n styleUrls: ['./w-schema-form-field-wrapper.component.scss']\r\n})\r\nexport class WSchemaFormFieldWrapperComponent extends FieldWrapper {\r\n get showLabel(): boolean {\r\n return !!this.props.label && this.props['hideLabel'] !== true;\r\n }\r\n\r\n get helpId(): string {\r\n return `${this.id}-help`;\r\n }\r\n}\r\n","<div class=\"w-schema-form-field\">\r\n @if (showLabel || props.description) {\r\n <div class=\"w-schema-form-field__label\">\r\n @if (showLabel) {\r\n <label class=\"w-schema-form-field__label-text\" [for]=\"id\">\r\n {{ props.label }}\r\n @if (props.required && props['hideRequiredMarker'] !== true) {\r\n <span class=\"w-schema-form-field__required\" aria-hidden=\"true\">*</span>\r\n }\r\n </label>\r\n }\r\n @if (props.description) {\r\n <span\r\n class=\"w-schema-form-field__help\"\r\n role=\"img\"\r\n tabindex=\"0\"\r\n [id]=\"helpId\"\r\n [attr.aria-label]=\"props.description\"\r\n [pTooltip]=\"props.description\"\r\n tooltipPosition=\"right\"\r\n tooltipEvent=\"both\">\r\n <svg width=\"12\" height=\"12\" viewBox=\"0 0 12 12\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" aria-hidden=\"true\">\r\n <path d=\"M6 0C2.7 0 0 2.7 0 6C0 9.3 2.7 12 6 12C9.3 12 12 9.3 12 6C12 2.7 9.3 0 6 0ZM6 9.75C5.586 9.75 5.25 9.414 5.25 9C5.25 8.586 5.586 8.25 6 8.25C6.414 8.25 6.75 8.586 6.75 9C6.75 9.414 6.414 9.75 6 9.75ZM7.21725 6.069C6.8445 6.38925 6.75 6.49725 6.75 6.75C6.75 7.16475 6.414 7.5 6 7.5C5.586 7.5 5.25 7.16475 5.25 6.75C5.25 5.7795 5.84625 5.268 6.2415 4.92975C6.61425 4.611 6.70875 4.50225 6.70875 4.25025C6.70875 4.113 6.70875 3.75 6.00075 3.75C5.67375 3.768 5.325 3.918 5.05725 4.17075C4.7565 4.45425 4.281 4.44 3.99675 4.14C3.7125 3.8385 3.726 3.36375 4.0275 3.0795C4.554 2.58375 5.24025 2.289 5.96175 2.2515H5.964C7.323 2.2515 8.20875 3.05475 8.20875 4.251C8.20875 5.22075 7.6125 5.73225 7.218 6.06975L7.21725 6.069Z\" />\r\n </svg>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <ng-container #fieldComponent></ng-container>\r\n @if (showError) {\r\n <small class=\"w-schema-form-field__error\">\r\n <formly-validation-message [field]=\"field\"></formly-validation-message>\r\n </small>\r\n }\r\n</div>\r\n","import { Component } from '@angular/core';\r\nimport { FieldWrapper } from '@ngx-formly/core';\r\n\r\n/** Formly wrapper name of the `x-wapping-group` presentation groups (internal). */\r\nexport const W_SCHEMA_FORM_GROUP_WRAPPER = 'w-schema-form-group';\r\n\r\n/** Class set on the field group rendered inside the wrapper. */\r\nexport const W_SCHEMA_FORM_GROUP_FIELDS_CLASS = 'w-schema-form-group__fields';\r\n\r\n/**\r\n * Presentation group (SFP-001): a `fieldset` with its heading as `legend`. The wrapped field group has no key,\r\n * so grouping never adds model entries nor changes the JSON Pointers of the fields.\r\n */\r\n@Component({\r\n selector: 'w-schema-form-group',\r\n standalone: true,\r\n templateUrl: './w-schema-form-group.component.html',\r\n styleUrls: ['./w-schema-form-group.component.scss']\r\n})\r\nexport class WSchemaFormGroupComponent extends FieldWrapper {}\r\n","<fieldset class=\"w-schema-form-group\">\r\n <legend class=\"w-schema-form-group__legend\">{{ props.label }}</legend>\r\n @if (props.description) {\r\n <p class=\"w-schema-form-group__description\">{{ props.description }}</p>\r\n }\r\n <ng-container #fieldComponent></ng-container>\r\n</fieldset>\r\n","import { FormlyFieldProps } from '@ngx-formly/core';\r\n\r\n/**\r\n * Gives the native control rendered by a Wapping control the accessible name of the field wrapper\r\n * (`<label for>`), its help and its required state, without changing the public API of the control (SFP-002).\r\n */\r\nexport function linkNativeControl(input: HTMLElement | null, id: string, props: FormlyFieldProps): void {\r\n if (!input) {\r\n return;\r\n }\r\n input.id = id;\r\n if (props.description) {\r\n input.setAttribute('aria-describedby', `${id}-help`);\r\n }\r\n if (props.required) {\r\n input.setAttribute('aria-required', 'true');\r\n }\r\n}\r\n","import { AfterViewInit, Component, ElementRef, inject } from '@angular/core';\r\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\r\nimport { WappComponentsModule } from 'ngx-wapp-components';\r\nimport { linkNativeControl } from '../w-schema-form/native-control';\r\n\r\n/** Formly type name of `uniqueItems` enum arrays (internal; does not replace the global `select` type). */\r\nexport const W_SCHEMA_FORM_MULTISELECT_TYPE = 'w-schema-form-multiselect';\r\n\r\n/**\r\n * Enum array rendered with the library `w-edit-multiselect` (SFP-002). Options keep their technical value and\r\n * show the translated label (CM-012); label, help and error come from the field wrapper.\r\n */\r\n@Component({\r\n selector: 'w-schema-form-multiselect',\r\n standalone: true,\r\n imports: [WappComponentsModule],\r\n templateUrl: './w-schema-form-multiselect.component.html'\r\n})\r\nexport class WSchemaFormMultiselectComponent extends FieldType<FieldTypeConfig> implements AfterViewInit {\r\n private readonly host: ElementRef<HTMLElement> = inject(ElementRef);\r\n\r\n get selectOptions(): ReadonlyArray<unknown> {\r\n return Array.isArray(this.props.options) ? this.props.options : [];\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n linkNativeControl(this.host.nativeElement.querySelector('input[role=\"combobox\"]'), this.id, this.props);\r\n }\r\n}\r\n","<!-- The wrapper shows the required marker and the validation message: the control does not repeat them. -->\r\n<w-edit-multiselect\r\n [formControl]=\"formControl\"\r\n [showLabel]=\"false\"\r\n [options]=\"selectOptions\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"false\"\r\n [showToggleAll]=\"selectOptions.length >= 2\"\r\n [selectAllLabel]=\"props['selectAllLabel'] ?? ''\"\r\n [placeholder]=\"props.placeholder ?? ''\"\r\n appendTo=\"body\"\r\n requiredErrorDescription=\"\">\r\n</w-edit-multiselect>\r\n","import { AfterViewInit, Component, DoCheck, ElementRef, inject } from '@angular/core';\r\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\r\nimport { FormControl } from '@angular/forms';\r\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\r\nimport { WappComponentsModule } from 'ngx-wapp-components';\r\nimport { linkNativeControl } from '../w-schema-form/native-control';\r\n\r\n/** Formly type name of boolean fields (internal; does not replace the global `checkbox`/`boolean` types). */\r\nexport const W_SCHEMA_FORM_TOGGLE_TYPE = 'w-schema-form-toggle';\r\n\r\n/** Field prop with the boolean schema `default`, shown while the value is absent but never materialized. */\r\nexport const W_SCHEMA_FORM_TOGGLE_DEFAULT_PROP = 'schemaDefault';\r\n\r\n/**\r\n * Boolean field rendered with the library `w-edit-toggle` (SFP-002). Label, help and error come from the\r\n * field wrapper; an absent value is not materialized as `false` (nor as the schema default) until the user\r\n * changes the toggle. While absent, the switch shows the effective value: the schema `default`, or off.\r\n */\r\n@Component({\r\n selector: 'w-schema-form-toggle',\r\n standalone: true,\r\n imports: [WappComponentsModule],\r\n template: '<w-edit-toggle [formControl]=\"displayControl\" [label]=\"noLabel\"></w-edit-toggle>'\r\n})\r\nexport class WSchemaFormToggleComponent extends FieldType<FieldTypeConfig> implements DoCheck, AfterViewInit {\r\n // `w-edit-toggle` renders its own label only when `label` is defined; the wrapper already renders it.\r\n protected readonly noLabel = undefined as unknown as string;\r\n protected readonly displayControl = new FormControl<boolean>(false, { nonNullable: true });\r\n private readonly host: ElementRef<HTMLElement> = inject(ElementRef);\r\n\r\n constructor() {\r\n super();\r\n this.displayControl.valueChanges.pipe(takeUntilDestroyed()).subscribe(value => {\r\n const control = this.formControl;\r\n if (control && control.value !== value) {\r\n control.setValue(value);\r\n control.markAsDirty();\r\n control.markAsTouched();\r\n }\r\n });\r\n }\r\n\r\n ngDoCheck(): void {\r\n const control = this.field?.formControl;\r\n if (!control) {\r\n return;\r\n }\r\n const value: unknown = control.value;\r\n const effective = typeof value === 'boolean' ? value : this.props[W_SCHEMA_FORM_TOGGLE_DEFAULT_PROP] === true;\r\n if (this.displayControl.value !== effective) {\r\n this.displayControl.setValue(effective, { emitEvent: false });\r\n }\r\n if (control.disabled !== this.displayControl.disabled) {\r\n if (control.disabled) {\r\n this.displayControl.disable({ emitEvent: false });\r\n } else {\r\n this.displayControl.enable({ emitEvent: false });\r\n }\r\n }\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n linkNativeControl(this.host.nativeElement.querySelector('input[role=\"switch\"]'), this.id, this.props);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { FormlyModule } from '@ngx-formly/core';\r\nimport {\r\n W_SCHEMA_FORM_FIELD_WRAPPER,\r\n WSchemaFormFieldWrapperComponent\r\n} from '../w-schema-form-field-wrapper/w-schema-form-field-wrapper.component';\r\nimport { W_SCHEMA_FORM_GROUP_WRAPPER, WSchemaFormGroupComponent } from '../w-schema-form-group/w-schema-form-group.component';\r\nimport {\r\n W_SCHEMA_FORM_MULTISELECT_TYPE,\r\n WSchemaFormMultiselectComponent\r\n} from '../w-schema-form-multiselect/w-schema-form-multiselect.component';\r\nimport {\r\n W_SCHEMA_FORM_SECRET_FIELD_TYPE,\r\n WSchemaFormSecretFieldComponent\r\n} from '../w-schema-form-secret-field/w-schema-form-secret-field.component';\r\nimport {\r\n W_SCHEMA_FORM_COLOR_FIELD_TYPE,\r\n WSchemaFormColorFieldComponent\r\n} from '../w-schema-form-color-field/w-schema-form-color-field.component';\r\nimport { W_SCHEMA_FORM_TOGGLE_TYPE, WSchemaFormToggleComponent } from '../w-schema-form-toggle/w-schema-form-toggle.component';\r\n\r\n/**\r\n * Registers the internal field types and wrappers with the same mechanism used by\r\n * @ngx-formly/primeng (`FormlyModule.forChild`). Formly adds them to the root `FormlyConfig` of the consumer\r\n * application (see the entry point README); the names are prefixed to avoid collisions.\r\n */\r\n@NgModule({\r\n imports: [\r\n WSchemaFormSecretFieldComponent,\r\n WSchemaFormColorFieldComponent,\r\n WSchemaFormFieldWrapperComponent,\r\n WSchemaFormGroupComponent,\r\n WSchemaFormToggleComponent,\r\n WSchemaFormMultiselectComponent,\r\n FormlyModule.forChild({\r\n wrappers: [\r\n { name: W_SCHEMA_FORM_FIELD_WRAPPER, component: WSchemaFormFieldWrapperComponent },\r\n { name: W_SCHEMA_FORM_GROUP_WRAPPER, component: WSchemaFormGroupComponent }\r\n ],\r\n types: [\r\n {\r\n name: W_SCHEMA_FORM_SECRET_FIELD_TYPE,\r\n component: WSchemaFormSecretFieldComponent,\r\n wrappers: [W_SCHEMA_FORM_FIELD_WRAPPER]\r\n },\r\n {\r\n name: W_SCHEMA_FORM_COLOR_FIELD_TYPE,\r\n component: WSchemaFormColorFieldComponent,\r\n wrappers: [W_SCHEMA_FORM_FIELD_WRAPPER]\r\n },\r\n { name: W_SCHEMA_FORM_TOGGLE_TYPE, component: WSchemaFormToggleComponent },\r\n { name: W_SCHEMA_FORM_MULTISELECT_TYPE, component: WSchemaFormMultiselectComponent }\r\n ]\r\n })\r\n ]\r\n})\r\nexport class WSchemaFormFieldTypesModule {}\r\n","import { Component, EventEmitter, Input, OnChanges, OnDestroy, Output, inject } from '@angular/core';\r\nimport { AbstractControl, FormControl, FormGroup, ReactiveFormsModule } from '@angular/forms';\r\nimport { FormlyFieldConfig, FormlyModule } from '@ngx-formly/core';\r\nimport { FormlyJsonschema } from '@ngx-formly/core/json-schema';\r\nimport { FormlyPrimeNGModule } from '@ngx-formly/primeng';\r\nimport Ajv, { ErrorObject, Options, ValidateFunction } from 'ajv';\r\nimport Ajv2020 from 'ajv/dist/2020';\r\nimport { Subscription } from 'rxjs';\r\nimport {\r\n W_SCHEMA_FORM_GROUPS, WJsonSchema, WSchemaFormDeclaredGroup, WSchemaFormDialect\r\n} from '../models/w-json-schema.model';\r\nimport { WSchemaFormSecretState } from '../models/w-schema-form-secret-state.model';\r\nimport { WSchemaFormError, WSchemaFormState } from '../models/w-schema-form-state.model';\r\nimport { WSchemaFormSubmit } from '../models/w-schema-form-submit.model';\r\nimport { W_SCHEMA_FORM_DEFAULT_TRANSLATIONS, WSchemaFormTranslations } from '../models/w-schema-form-translations.model';\r\nimport {\r\n W_SCHEMA_FORM_SECRET_FIELD_TYPE,\r\n WSchemaFormSecretFieldProps\r\n} from '../w-schema-form-secret-field/w-schema-form-secret-field.component';\r\nimport { W_SCHEMA_FORM_COLOR_FIELD_TYPE } from '../w-schema-form-color-field/w-schema-form-color-field.component';\r\nimport { WSchemaFormImageUpload } from '../models/w-schema-form-image-upload.model';\r\nimport {\r\n COLOR_WIDGET,\r\n IMAGE_WIDGET,\r\n GROUP_KEYWORD,\r\n GROUPS_KEYWORD,\r\n REFERENCE_WIDGETS,\r\n POINTER_PROP,\r\n SECRET_KEYWORD,\r\n WIDGET_KEYWORD,\r\n SchemaFormConfigurationError,\r\n annotatePointers,\r\n buildPublicSchema,\r\n hasConstOptions,\r\n hasValueAt,\r\n inspectSchema,\r\n isRecord,\r\n readDeclaredGroups,\r\n readPropertySchema,\r\n resolveDialect\r\n} from './schema-inspection';\r\nimport { WSchemaFormFieldTypesModule } from './w-schema-form-field-types.module';\r\nimport { W_SCHEMA_FORM_FIELD_WRAPPER } from '../w-schema-form-field-wrapper/w-schema-form-field-wrapper.component';\r\nimport {\r\n W_SCHEMA_FORM_GROUP_FIELDS_CLASS,\r\n W_SCHEMA_FORM_GROUP_WRAPPER\r\n} from '../w-schema-form-group/w-schema-form-group.component';\r\nimport { W_SCHEMA_FORM_MULTISELECT_TYPE } from '../w-schema-form-multiselect/w-schema-form-multiselect.component';\r\nimport { W_SCHEMA_FORM_TOGGLE_DEFAULT_PROP, W_SCHEMA_FORM_TOGGLE_TYPE } from '../w-schema-form-toggle/w-schema-form-toggle.component';\r\n\r\ntype FormlySchema = Parameters<FormlyJsonschema['toFieldConfig']>[0];\r\n\r\ninterface SecretEntry {\r\n path: string;\r\n hasValue: boolean;\r\n control: FormControl<string>;\r\n validator: ValidateFunction<string>;\r\n}\r\n\r\n/** Formly type registered by a consumer that provides image upload integration. */\r\nexport const W_SCHEMA_FORM_IMAGE_FIELD_TYPE = 'w-schema-form-image';\r\n\r\nexport interface WSchemaFormReferenceOption {\r\n value: number;\r\n label: string;\r\n}\r\n\r\n/**\r\n * JSON Schema form (CM-007). Emits the public configuration and the secret replacements separately and\r\n * never preloads, stores or reports secret values (SF-001..SF-009).\r\n */\r\n@Component({\r\n selector: 'w-schema-form',\r\n standalone: true,\r\n imports: [ReactiveFormsModule, FormlyModule, FormlyPrimeNGModule, WSchemaFormFieldTypesModule],\r\n templateUrl: './w-schema-form.component.html',\r\n styleUrls: ['./w-schema-form.component.scss']\r\n})\r\nexport class WSchemaFormComponent implements OnChanges, OnDestroy {\r\n @Input({ required: true }) schema: WJsonSchema | null = null;\r\n @Input({ required: true }) values: Record<string, unknown> | null = null;\r\n @Input() dialect?: WSchemaFormDialect;\r\n @Input() secretStates: ReadonlyArray<WSchemaFormSecretState> | null = [];\r\n @Input() translations: Readonly<WSchemaFormTranslations> | null = W_SCHEMA_FORM_DEFAULT_TRANSLATIONS;\r\n @Input() imageUpload: WSchemaFormImageUpload | null = null;\r\n /** Options are supplied by the consuming application and scoped to the current business. */\r\n @Input() referenceOptions: Readonly<Record<string, ReadonlyArray<WSchemaFormReferenceOption>>> = {};\r\n @Output() stateChange = new EventEmitter<WSchemaFormState>();\r\n @Output() validSubmit = new EventEmitter<WSchemaFormSubmit>();\r\n /** Copy of the public configuration after each user edit (HP-001); never secrets or materialized defaults. */\r\n @Output() valueChange = new EventEmitter<Record<string, unknown>>();\r\n\r\n // Internal rendering state: consumers observe `stateChange` and `validSubmit` only.\r\n protected form = new FormGroup<Record<string, AbstractControl<unknown>>>({});\r\n protected fields: FormlyFieldConfig[] = [];\r\n protected model: Record<string, unknown> = {};\r\n protected state: WSchemaFormState = { status: 'error', errors: [], secrets: [] };\r\n /** Consumer translations merged over the defaults (a null or partial input never breaks the template). */\r\n protected texts: Readonly<WSchemaFormTranslations> = W_SCHEMA_FORM_DEFAULT_TRANSLATIONS;\r\n\r\n private readonly formlyJsonschema = inject(FormlyJsonschema);\r\n private validator?: ValidateFunction<Record<string, unknown>>;\r\n private secrets: SecretEntry[] = [];\r\n private secretSubscriptions = new Subscription();\r\n private lastEmittedPublicValues = '';\r\n\r\n ngOnChanges(): void {\r\n this.reset();\r\n const translations: Partial<WSchemaFormTranslations> = this.translations ?? {};\r\n this.texts = {\r\n ...W_SCHEMA_FORM_DEFAULT_TRANSLATIONS,\r\n ...translations,\r\n groups: { ...W_SCHEMA_FORM_DEFAULT_TRANSLATIONS.groups, ...translations.groups }\r\n };\r\n const secretStates = this.secretStates ?? [];\r\n\r\n if (!this.schema || this.schema.type !== 'object' ||\r\n !this.values || typeof this.values !== 'object' || Array.isArray(this.values)) {\r\n this.fail('An object schema and explicit object values are required.');\r\n return;\r\n }\r\n\r\n try {\r\n const schema = structuredClone(this.schema);\r\n const dialect = resolveDialect(schema, this.dialect);\r\n const secretPaths = inspectSchema(schema);\r\n this.assertSecretInputs(secretPaths, this.values, secretStates);\r\n const ajv = createAjv(dialect);\r\n this.validator = ajv.compile<Record<string, unknown>>(buildPublicSchema(schema, secretPaths));\r\n this.secrets = secretPaths.map(path => ({\r\n path,\r\n hasValue: secretStates.some(state => state.path === path && state.hasValue === true),\r\n control: new FormControl<string>('', { nonNullable: true }),\r\n validator: ajv.compile<string>(structuredClone(readPropertySchema(schema, path)))\r\n }));\r\n this.model = structuredClone(this.values);\r\n this.lastEmittedPublicValues = JSON.stringify(this.model) ?? '';\r\n const groups = new Map<FormlyFieldConfig, string>();\r\n const root = this.formlyJsonschema.toFieldConfig(annotatePointers(schema) as FormlySchema, {\r\n ignoreImplicitStringDefaults: true,\r\n map: (field, source) => {\r\n const mapped = this.mapField(field, source);\r\n const group: unknown = (source as WJsonSchema)[GROUP_KEYWORD];\r\n if (typeof group === 'string') {\r\n // inspectSchema accepts the annotation only on direct properties of the root.\r\n groups.set(mapped, group);\r\n }\r\n return mapped;\r\n }\r\n });\r\n this.fields = this.groupFields(root.fieldGroup ?? [], groups, readDeclaredGroups(schema));\r\n } catch (error: unknown) {\r\n this.reset();\r\n this.fail(error instanceof Error ? error.message : 'The schema could not be prepared.');\r\n return;\r\n }\r\n\r\n for (const secret of this.secrets) {\r\n this.secretSubscriptions.add(secret.control.valueChanges.subscribe(() => this.validate()));\r\n }\r\n this.validate();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.reset();\r\n }\r\n\r\n protected onModelChange(model: Record<string, unknown>): void {\r\n this.model = model;\r\n this.validate();\r\n this.emitPublicValues();\r\n }\r\n\r\n submit(): void {\r\n this.form.markAllAsTouched();\r\n this.validate();\r\n if (this.state.status !== 'valid') {\r\n return;\r\n }\r\n const submission: WSchemaFormSubmit = {\r\n configuration: structuredClone(this.model),\r\n secrets: this.secrets\r\n .filter(secret => secret.control.value !== '')\r\n .map(secret => ({ path: secret.path, value: secret.control.value }))\r\n };\r\n // SFC-D06: the typed secret leaves the component memory as soon as it is emitted.\r\n for (const secret of this.secrets) {\r\n secret.control.reset('');\r\n }\r\n this.validSubmit.emit(submission);\r\n }\r\n\r\n private validate(): void {\r\n if (!this.validator) {\r\n return;\r\n }\r\n\r\n const configurationValid = this.validator(this.model);\r\n const errors: WSchemaFormError[] = (this.validator.errors ?? []).map(error => toDiagnostic(error, ''));\r\n let secretsValid = true;\r\n for (const secret of this.secrets) {\r\n if (secret.control.value !== '' && !secret.validator(secret.control.value)) {\r\n secretsValid = false;\r\n errors.push(...(secret.validator.errors ?? []).map(error => toDiagnostic(error, secret.path)));\r\n }\r\n }\r\n this.state = {\r\n status: configurationValid && secretsValid && this.form.valid && !this.form.pending ? 'valid' : 'invalid',\r\n errors,\r\n secrets: this.secrets.map(secret => ({\r\n path: secret.path,\r\n hasValue: secret.hasValue,\r\n replacementPending: secret.control.value !== ''\r\n }))\r\n };\r\n this.stateChange.emit(this.state);\r\n }\r\n\r\n private emitPublicValues(): void {\r\n const configuration = structuredClone(this.model);\r\n const serialized = JSON.stringify(configuration);\r\n // Formly can report the same model more than once per edit; consumers only see real changes.\r\n if (serialized === undefined || serialized === this.lastEmittedPublicValues) {\r\n return;\r\n }\r\n\r\n this.lastEmittedPublicValues = serialized;\r\n this.valueChange.emit(configuration);\r\n }\r\n\r\n private fail(message: string): void {\r\n this.state = {\r\n status: 'error',\r\n errors: [{ instancePath: '', keyword: 'configuration', message }],\r\n secrets: []\r\n };\r\n this.stateChange.emit(this.state);\r\n }\r\n\r\n /** Discards controls, validators and typed secret values (SF-003, SF-008). */\r\n private reset(): void {\r\n this.secretSubscriptions.unsubscribe();\r\n this.secretSubscriptions = new Subscription();\r\n for (const secret of this.secrets) {\r\n secret.control.reset('');\r\n }\r\n this.secrets = [];\r\n this.form = new FormGroup<Record<string, AbstractControl<unknown>>>({});\r\n this.fields = [];\r\n this.model = {};\r\n this.validator = undefined;\r\n }\r\n\r\n /** SF-006/SF-007: secret states must target declared secrets and values must not carry secrets. */\r\n private assertSecretInputs(\r\n secretPaths: ReadonlyArray<string>,\r\n values: Record<string, unknown>,\r\n secretStates: ReadonlyArray<WSchemaFormSecretState>\r\n ): void {\r\n for (const state of secretStates) {\r\n if (!isRecord(state) || !secretPaths.includes(state.path)) {\r\n throw new SchemaFormConfigurationError('secretStates contains a path that the schema does not mark as secret.');\r\n }\r\n }\r\n for (const path of secretPaths) {\r\n if (hasValueAt(values, path)) {\r\n throw new SchemaFormConfigurationError(`The values contain an entry at the secret path ${path}.`);\r\n }\r\n }\r\n }\r\n\r\n private mapField(field: FormlyFieldConfig, schema: FormlySchema): FormlyFieldConfig {\r\n // Schema defaults must not materialize overrides that the business did not edit.\r\n delete field.defaultValue;\r\n const props = field.props ?? (field.props = {});\r\n const pointer: unknown = props[POINTER_PROP];\r\n delete props[POINTER_PROP];\r\n if (typeof pointer === 'string') {\r\n const override = this.texts.fields?.[pointer];\r\n props.label = override?.label ?? props.label ?? (typeof field.key === 'string' ? field.key : undefined);\r\n props.description = override?.description ?? props.description;\r\n const optionLabels = override?.options;\r\n if (optionLabels && Array.isArray(props.options)) {\r\n props.options = props.options.map((option: unknown) => translateOption(option, optionLabels));\r\n }\r\n if (schema.type !== 'object' && !(schema.type === undefined && schema.properties)) {\r\n field.wrappers = [W_SCHEMA_FORM_FIELD_WRAPPER];\r\n }\r\n const secret = this.secrets.find(entry => entry.path === pointer);\r\n if (secret) {\r\n return this.mapSecretField(field, secret);\r\n }\r\n }\r\n\r\n if (Object.prototype.hasOwnProperty.call(schema, 'const')) {\r\n // Fixed values are shown but never edited nor materialized.\r\n field.type = 'input';\r\n props.type = 'text';\r\n props.disabled = true;\r\n props.readonly = true;\r\n props.placeholder = typeof schema.const === 'string' ? schema.const : JSON.stringify(schema.const);\r\n field.parsers = [];\r\n return field;\r\n }\r\n\r\n const hasOptions = !!schema.enum || hasConstOptions(schema);\r\n switch (schema.type) {\r\n case 'object':\r\n delete field.type;\r\n break;\r\n case 'string':\r\n case 'number':\r\n case 'integer':\r\n field.type = hasOptions ? 'select' : 'input';\r\n props.type = schema.type === 'string' ? 'text' : 'number';\r\n // Clearing a control is not an implicit request to inherit a missing override.\r\n field.parsers = schema.type === 'string' || hasOptions ? [] : [\r\n (value: unknown, current?: FormlyFieldConfig): unknown => {\r\n if (!current?.formControl?.dirty) {\r\n return typeof current?.key === 'string' ? current.model?.[current.key] : value;\r\n }\r\n if (value === '' || value === undefined || value === null) {\r\n return null;\r\n }\r\n return typeof value === 'string' ? Number(value) : value;\r\n }\r\n ];\r\n const widget = (schema as Record<string, unknown>)[WIDGET_KEYWORD];\r\n if (typeof widget === 'string' && REFERENCE_WIDGETS.has(widget)) {\r\n field.type = 'select';\r\n props.options = [...(this.referenceOptions[widget] ?? [])];\r\n field.parsers = [];\r\n break;\r\n }\r\n if (schema.type === 'string' && widget === COLOR_WIDGET) {\r\n // SFCW-D04: an emptied color removes the override instead of storing an empty string.\r\n field.type = W_SCHEMA_FORM_COLOR_FIELD_TYPE;\r\n field.parsers = [(value: unknown): unknown => (value === '' ? undefined : value)];\r\n }\r\n if (schema.type === 'string' && widget === IMAGE_WIDGET) {\r\n if (!this.imageUpload || !this.imageUpload.uploadUrl || !this.imageUpload.headers) {\r\n throw new SchemaFormConfigurationError(\r\n 'Image fields require an uploadUrl, headers and imageUploadConfig in the imageUpload input.');\r\n }\r\n field.type = W_SCHEMA_FORM_IMAGE_FIELD_TYPE;\r\n field.parsers = [(value: unknown): unknown => (value === '' ? undefined : value)];\r\n props['imageUpload'] = this.imageUpload;\r\n }\r\n break;\r\n case 'boolean':\r\n field.type = W_SCHEMA_FORM_TOGGLE_TYPE;\r\n if (typeof schema.default === 'boolean') {\r\n props[W_SCHEMA_FORM_TOGGLE_DEFAULT_PROP] = schema.default;\r\n }\r\n break;\r\n case 'array':\r\n // inspectSchema only lets through uniqueItems arrays whose items are an enum.\r\n field.type = W_SCHEMA_FORM_MULTISELECT_TYPE;\r\n props['multiple'] = true;\r\n props['selectAllLabel'] = this.texts.selectAll ?? W_SCHEMA_FORM_DEFAULT_TRANSLATIONS.selectAll;\r\n field.parsers = [];\r\n break;\r\n case undefined:\r\n if (hasOptions) {\r\n field.type = 'select';\r\n field.parsers = [];\r\n break;\r\n }\r\n if (schema.properties) {\r\n delete field.type;\r\n break;\r\n }\r\n throw new SchemaFormConfigurationError('A field without type must declare enum, const or properties.');\r\n default:\r\n throw new SchemaFormConfigurationError(\r\n 'The schema form supports object, string, number, integer, boolean, enum, const and enum array fields only.');\r\n }\r\n return field;\r\n }\r\n\r\n /**\r\n * SFP-001: ungrouped root fields first, then one keyless group per non-empty `x-wapping-group` in the fixed\r\n * order. SFP-007: with `x-wapping-groups` the groups, their order and their headings are the declared ones\r\n * (translation of the key, else the schema title) and the description is shown under the heading. Without\r\n * annotations the structure is unchanged.\r\n */\r\n private groupFields(\r\n fields: FormlyFieldConfig[],\r\n groups: ReadonlyMap<FormlyFieldConfig, string>,\r\n declared: ReadonlyArray<WSchemaFormDeclaredGroup> | undefined\r\n ): FormlyFieldConfig[] {\r\n if (!fields.some(field => groups.has(field))) {\r\n return fields;\r\n }\r\n const headings: ReadonlyArray<WSchemaFormDeclaredGroup> = declared?.map(group => ({\r\n key: group.key,\r\n title: this.translations?.groups?.[group.key] || group.title,\r\n description: group.description\r\n })) ?? W_SCHEMA_FORM_GROUPS.map(group => ({\r\n key: group,\r\n title: this.texts.groups?.[group] || W_SCHEMA_FORM_DEFAULT_TRANSLATIONS.groups?.[group] || group\r\n }));\r\n const grouped: FormlyFieldConfig[] = fields.filter(field => !groups.has(field));\r\n for (const group of headings) {\r\n const members = fields.filter(field => groups.get(field) === group.key);\r\n if (members.length > 0) {\r\n grouped.push({\r\n wrappers: [W_SCHEMA_FORM_GROUP_WRAPPER],\r\n fieldGroupClassName: W_SCHEMA_FORM_GROUP_FIELDS_CLASS,\r\n props: { label: group.title, description: group.description },\r\n fieldGroup: members\r\n });\r\n }\r\n }\r\n return grouped;\r\n }\r\n\r\n private mapSecretField(field: FormlyFieldConfig, secret: SecretEntry): FormlyFieldConfig {\r\n // Without key the field has no control in the form nor entry in the model: the value never\r\n // reaches `configuration`, `stateChange` or the diagnostics.\r\n delete field.key;\r\n field.type = W_SCHEMA_FORM_SECRET_FIELD_TYPE;\r\n field.validators = {};\r\n field.parsers = [];\r\n const translations = this.texts;\r\n const secretProps: Partial<WSchemaFormSecretFieldProps> = {\r\n secretControl: secret.control,\r\n secretStatusText: secret.hasValue ? translations.secretConfigured : translations.secretPending,\r\n secretHint: secret.hasValue ? translations.secretReplaceHint : undefined,\r\n showSecretLabel: translations.showSecret,\r\n hideSecretLabel: translations.hideSecret\r\n };\r\n Object.assign(field.props ?? (field.props = {}), secretProps);\r\n return field;\r\n }\r\n}\r\n\r\nfunction createAjv(dialect: WSchemaFormDialect): Ajv | Ajv2020 {\r\n const options: Options = { allErrors: true, ownProperties: true, verbose: false, logger: false };\r\n const ajv = dialect === '2020-12' ? new Ajv2020(options) : new Ajv(options);\r\n // Annotation keywords: strict mode stays enabled for every other unknown keyword.\r\n ajv.addKeyword(SECRET_KEYWORD);\r\n ajv.addKeyword(WIDGET_KEYWORD);\r\n ajv.addKeyword(GROUP_KEYWORD);\r\n ajv.addKeyword(GROUPS_KEYWORD);\r\n return ajv;\r\n}\r\n\r\n/** CM-012: only the label of an enum option is translated; its value stays the technical one. */\r\nfunction translateOption(option: unknown, labels: Readonly<Record<string, string>>): unknown {\r\n if (!isRecord(option)) {\r\n return option;\r\n }\r\n const value = option['value'];\r\n if (typeof value !== 'string' && typeof value !== 'number') {\r\n return option;\r\n }\r\n const key = String(value);\r\n const label = Object.prototype.hasOwnProperty.call(labels, key) ? labels[key] : undefined;\r\n return typeof label === 'string' && label !== '' ? { ...option, label } : option;\r\n}\r\n\r\nfunction toDiagnostic({ instancePath, keyword, message }: ErrorObject, basePath: string): WSchemaFormError {\r\n return { instancePath: `${basePath}${instancePath}`, keyword, message };\r\n}\r\n","<div class=\"w-schema-form\">\r\n @if (state.status === 'error') {\r\n <p role=\"alert\" class=\"w-error-message w-schema-form__alert\">{{ texts.configurationError }}</p>\r\n } @else {\r\n <formly-form\r\n class=\"w-schema-form__fields\"\r\n [form]=\"form\"\r\n [fields]=\"fields\"\r\n [model]=\"model\"\r\n (modelChange)=\"onModelChange($event)\">\r\n </formly-form>\r\n @if (state.status === 'invalid') {\r\n <p role=\"alert\" class=\"w-error-message w-schema-form__alert\">{{ texts.invalidValues }}</p>\r\n }\r\n }\r\n</div>\r\n","/*\r\n * Public API Surface of ngx-wapp-components/schema-form\r\n * Secondary entry point (SFC-D02): requires the optional peers @ngx-formly/core,\r\n * @ngx-formly/primeng and ajv. The primary entry point does not depend on them.\r\n */\r\n\r\nexport * from './lib/models/w-json-schema.model';\r\nexport * from './lib/models/w-schema-form-secret-state.model';\r\nexport * from './lib/models/w-schema-form-state.model';\r\nexport * from './lib/models/w-schema-form-submit.model';\r\nexport * from './lib/models/w-schema-form-translations.model';\r\nexport * from './lib/models/w-schema-form-image-upload.model';\r\nexport * from './lib/w-schema-form/w-schema-form.component';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i2","i3","i1"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAeA;;;AAGG;AACI,MAAM,oBAAoB,GAAG,CAAC,WAAW,EAAE,YAAY,EAAE,cAAc,EAAE,SAAS;;ACazF;AACO,MAAM,kCAAkC,GAAsC,MAAM,CAAC,MAAM,CAAC;AACjG,IAAA,kBAAkB,EAAE,kFAAkF;AACtG,IAAA,aAAa,EAAE,+CAA+C;AAC9D,IAAA,gBAAgB,EAAE,aAAa;AAC/B,IAAA,aAAa,EAAE,WAAW;AAC1B,IAAA,iBAAiB,EAAE,mFAAmF;AACtG,IAAA,UAAU,EAAE,eAAe;AAC3B,IAAA,UAAU,EAAE,eAAe;AAC3B,IAAA,SAAS,EAAE,kBAAkB;AAC7B,IAAA,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC;AACpB,QAAA,SAAS,EAAE,UAAU;AACrB,QAAA,UAAU,EAAE,UAAU;AACtB,QAAA,YAAY,EAAE,aAAa;AAC3B,QAAA,OAAO,EAAE;KACV;AACF,CAAA;;ACz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