@yuuvis/client-framework 3.7.1 → 3.8.1

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.
@@ -1,5 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { Component, NgModule } from '@angular/core';
3
+ import { NgTemplateOutlet } from '@angular/common';
3
4
  import * as i1 from '@angular/forms';
4
5
  import { ReactiveFormsModule } from '@angular/forms';
5
6
  import * as i2 from '@angular/material/checkbox';
@@ -9,15 +10,16 @@ import { MatFormFieldModule } from '@angular/material/form-field';
9
10
  import * as i4 from '@angular/material/slide-toggle';
10
11
  import { MatSlideToggleModule } from '@angular/material/slide-toggle';
11
12
  import { StringComponent, DataGridComponent, OrganizationComponent, OrganizationSetComponent, CatalogComponent, DynamicCatalogComponent, I18nCatalogComponent, NumberComponent, NumberRangeComponent, DatetimeComponent, DatetimeRangeComponent } from '@yuuvis/client-framework/forms';
12
- import { ObjectMetadataElementTemplateDirective, ObjectMetadataElementLabelDirective, ObjectMetadataElementErrorDirective } from '@yuuvis/client-framework/metadata-form';
13
+ import { ObjectMetadataElementTemplateDirective, ObjectMetadataElementRawDirective, ObjectMetadataElementLabelDirective, ObjectMetadataElementErrorDirective } from '@yuuvis/client-framework/metadata-form';
13
14
 
14
15
  class MetadataDefaultTemplatesComponent {
15
16
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataDefaultTemplatesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
16
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: MetadataDefaultTemplatesComponent, isStandalone: true, selector: "yuv-metadata-default-templates", ngImport: i0, template: "<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n >\n >\n </yuv-number>\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n", styles: ["mat-hint:not(:empty){padding-bottom:var(--ymt-spacing-xs)}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: StringComponent, selector: "yuv-string", inputs: ["multiselect", "rows", "readonly", "autofocus", "classifications", "situation", "regex", "minLength", "maxLength"] }, { kind: "component", type: DataGridComponent, selector: "yuv-data-grid", inputs: ["situation", "formElement", "formControl", "classifications", "readonly", "formFieldContext", "size"] }, { kind: "component", type: OrganizationComponent, selector: "yuv-organization", inputs: ["situation", "multiselect", "classifications", "readonly", "excludeMe", "withMetadata"] }, { kind: "component", type: OrganizationSetComponent, selector: "yuv-organization-set", inputs: ["situation", "multiselect", "readonly", "withMetadata", "autocompleteMinLength", "classifications", "types"] }, { kind: "component", type: CatalogComponent, selector: "yuv-catalog", inputs: ["readonly", "multiple", "options", "classifications", "situation"] }, { kind: "component", type: DynamicCatalogComponent, selector: "yuv-dynamic-catalog", inputs: ["catalog", "readonly", "multiple", "situation"] }, { kind: "component", type: I18nCatalogComponent, selector: "yuv-i18n-catalog", inputs: ["readonly", "multiple", "propertyName", "options", "classifications", "situation"] }, { kind: "component", type: NumberComponent, selector: "yuv-number", inputs: ["scale", "precision", "grouping", "groupPattern", "readonly", "minValue", "maxValue", "classifications"] }, { kind: "component", type: NumberRangeComponent, selector: "yuv-number-range", inputs: ["scale", "precision", "grouping", "pattern", "readonly", "classifications", "minValue", "maxValue", "situation"] }, { kind: "component", type: DatetimeComponent, selector: "yuv-datetime", inputs: ["locale", "onlyFutureDates", "readonly", "calendar", "withTime"] }, { kind: "component", type: DatetimeRangeComponent, selector: "yuv-datetime-range", inputs: ["withTime", "readonly", "operator", "situation"] }, { kind: "directive", type: ObjectMetadataElementTemplateDirective, selector: "[yuvMetadataElementTemplate]", inputs: ["yuvMetadataElementTemplate", "situation", "propertyType", "propertyName"] }, { kind: "directive", type: ObjectMetadataElementLabelDirective, selector: "[yuvObjectMetadataElementLabel]", inputs: ["yuvObjectMetadataElementLabel"] }, { kind: "directive", type: ObjectMetadataElementErrorDirective, selector: "[yuvObjectMetadataElementError]", inputs: ["yuvObjectMetadataElementError"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i2.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "ngmodule", type: MatSlideToggleModule }, { kind: "component", type: i4.MatSlideToggle, selector: "mat-slide-toggle", inputs: ["name", "id", "labelPosition", "aria-label", "aria-labelledby", "aria-describedby", "required", "color", "disabled", "disableRipple", "tabIndex", "checked", "hideIcon", "disabledInteractive"], outputs: ["change", "toggleChange"], exportAs: ["matSlideToggle"] }] }); }
17
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: MetadataDefaultTemplatesComponent, isStandalone: true, selector: "yuv-metadata-default-templates", ngImport: i0, template: "<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template #rawString yuvMetadataElementRaw=\"default\" propertyType=\"string\" let-ctx>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawString; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template #rawCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog\" let-ctx>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template #rawI18nCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawI18nCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template #rawDynamicCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDynamicCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template #rawOrganization yuvMetadataElementRaw=\"default\" propertyType=\"string:organization\" let-ctx>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganization; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template #rawOrganizationSet yuvMetadataElementRaw=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganizationSet; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template #rawInteger yuvMetadataElementRaw=\"default\" propertyType=\"integer\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawInteger; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template #rawDecimal yuvMetadataElementRaw=\"default\" propertyType=\"decimal\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDecimal; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template #rawDatetime yuvMetadataElementRaw=\"default\" propertyType=\"datetime\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDatetime; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template #rawTable yuvMetadataElementRaw=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <ng-container *ngTemplateOutlet=\"rawTable; context: { $implicit: ctx }\" />\n</ng-template>\n", styles: ["mat-hint:not(:empty){padding-bottom:var(--ymt-spacing-xs)}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: StringComponent, selector: "yuv-string", inputs: ["multiselect", "rows", "readonly", "autofocus", "classifications", "situation", "regex", "minLength", "maxLength"] }, { kind: "component", type: DataGridComponent, selector: "yuv-data-grid", inputs: ["situation", "formElement", "formControl", "classifications", "readonly", "formFieldContext", "size"] }, { kind: "component", type: OrganizationComponent, selector: "yuv-organization", inputs: ["situation", "multiselect", "classifications", "readonly", "excludeMe", "withMetadata"] }, { kind: "component", type: OrganizationSetComponent, selector: "yuv-organization-set", inputs: ["situation", "multiselect", "readonly", "withMetadata", "autocompleteMinLength", "classifications", "types"] }, { kind: "component", type: CatalogComponent, selector: "yuv-catalog", inputs: ["readonly", "multiple", "options", "classifications", "situation"] }, { kind: "component", type: DynamicCatalogComponent, selector: "yuv-dynamic-catalog", inputs: ["catalog", "readonly", "multiple", "situation"] }, { kind: "component", type: I18nCatalogComponent, selector: "yuv-i18n-catalog", inputs: ["readonly", "multiple", "propertyName", "options", "classifications", "situation"] }, { kind: "component", type: NumberComponent, selector: "yuv-number", inputs: ["scale", "precision", "grouping", "groupPattern", "readonly", "minValue", "maxValue", "classifications"] }, { kind: "component", type: NumberRangeComponent, selector: "yuv-number-range", inputs: ["scale", "precision", "grouping", "pattern", "readonly", "classifications", "minValue", "maxValue", "situation"] }, { kind: "component", type: DatetimeComponent, selector: "yuv-datetime", inputs: ["locale", "onlyFutureDates", "readonly", "calendar", "withTime"] }, { kind: "component", type: DatetimeRangeComponent, selector: "yuv-datetime-range", inputs: ["withTime", "readonly", "operator", "situation"] }, { kind: "directive", type: ObjectMetadataElementTemplateDirective, selector: "[yuvMetadataElementTemplate]", inputs: ["yuvMetadataElementTemplate", "situation", "propertyType", "propertyName"] }, { kind: "directive", type: ObjectMetadataElementRawDirective, selector: "[yuvMetadataElementRaw]", inputs: ["yuvMetadataElementRaw", "situation", "propertyType", "propertyName"] }, { kind: "directive", type: ObjectMetadataElementLabelDirective, selector: "[yuvObjectMetadataElementLabel]", inputs: ["yuvObjectMetadataElementLabel"] }, { kind: "directive", type: ObjectMetadataElementErrorDirective, selector: "[yuvObjectMetadataElementError]", inputs: ["yuvObjectMetadataElementError"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i2.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "ngmodule", type: MatSlideToggleModule }, { kind: "component", type: i4.MatSlideToggle, selector: "mat-slide-toggle", inputs: ["name", "id", "labelPosition", "aria-label", "aria-labelledby", "aria-describedby", "required", "color", "disabled", "disableRipple", "tabIndex", "checked", "hideIcon", "disabledInteractive"], outputs: ["change", "toggleChange"], exportAs: ["matSlideToggle"] }] }); }
17
18
  }
18
19
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataDefaultTemplatesComponent, decorators: [{
19
20
  type: Component,
20
21
  args: [{ selector: 'yuv-metadata-default-templates', standalone: true, imports: [
22
+ NgTemplateOutlet,
21
23
  ReactiveFormsModule,
22
24
  StringComponent,
23
25
  DataGridComponent,
@@ -31,13 +33,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
31
33
  DatetimeComponent,
32
34
  DatetimeRangeComponent,
33
35
  ObjectMetadataElementTemplateDirective,
36
+ ObjectMetadataElementRawDirective,
34
37
  ObjectMetadataElementLabelDirective,
35
38
  ObjectMetadataElementErrorDirective,
36
39
  MatCheckboxModule,
37
40
  MatFormFieldModule,
38
- MatSlideToggleModule,
39
- MatFormFieldModule
40
- ], template: "<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n >\n >\n </yuv-number>\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n", styles: ["mat-hint:not(:empty){padding-bottom:var(--ymt-spacing-xs)}\n"] }]
41
+ MatSlideToggleModule
42
+ ], template: "<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template #rawString yuvMetadataElementRaw=\"default\" propertyType=\"string\" let-ctx>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawString; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template #rawCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog\" let-ctx>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template #rawI18nCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawI18nCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template #rawDynamicCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDynamicCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template #rawOrganization yuvMetadataElementRaw=\"default\" propertyType=\"string:organization\" let-ctx>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganization; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template #rawOrganizationSet yuvMetadataElementRaw=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganizationSet; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template #rawInteger yuvMetadataElementRaw=\"default\" propertyType=\"integer\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawInteger; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template #rawDecimal yuvMetadataElementRaw=\"default\" propertyType=\"decimal\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDecimal; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template #rawDatetime yuvMetadataElementRaw=\"default\" propertyType=\"datetime\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDatetime; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template #rawTable yuvMetadataElementRaw=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <ng-container *ngTemplateOutlet=\"rawTable; context: { $implicit: ctx }\" />\n</ng-template>\n", styles: ["mat-hint:not(:empty){padding-bottom:var(--ymt-spacing-xs)}\n"] }]
41
43
  }] });
42
44
 
43
45
  class YuvMetadataFormDefaultsModule {
@@ -1 +1 @@
1
- {"version":3,"file":"yuuvis-client-framework-metadata-form-defaults.mjs","sources":["../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-default-templates/metadata-default-templates.component.ts","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-default-templates/metadata-default-templates.component.html","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-form-defaults.module.ts","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/yuuvis-client-framework-metadata-form-defaults.ts"],"sourcesContent":["import { Component } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatSlideToggleModule } from '@angular/material/slide-toggle';\nimport {\n CatalogComponent,\n DataGridComponent,\n DatetimeComponent,\n DatetimeRangeComponent,\n DynamicCatalogComponent,\n I18nCatalogComponent,\n NumberComponent,\n NumberRangeComponent,\n OrganizationComponent,\n OrganizationSetComponent,\n StringComponent\n} from '@yuuvis/client-framework/forms';\nimport {\n ObjectMetadataElementErrorDirective,\n ObjectMetadataElementLabelDirective,\n ObjectMetadataElementTemplateDirective\n} from '@yuuvis/client-framework/metadata-form';\n\n@Component({\n selector: 'yuv-metadata-default-templates',\n standalone: true,\n imports: [\n ReactiveFormsModule,\n StringComponent,\n DataGridComponent,\n OrganizationComponent,\n OrganizationSetComponent,\n CatalogComponent,\n DynamicCatalogComponent,\n I18nCatalogComponent,\n NumberComponent,\n NumberRangeComponent,\n DatetimeComponent,\n DatetimeRangeComponent,\n ObjectMetadataElementTemplateDirective,\n ObjectMetadataElementLabelDirective,\n ObjectMetadataElementErrorDirective,\n MatCheckboxModule,\n MatFormFieldModule,\n MatSlideToggleModule,\n MatFormFieldModule\n ],\n templateUrl: './metadata-default-templates.component.html',\n styleUrl: './metadata-default-templates.component.scss'\n})\nexport class MetadataDefaultTemplatesComponent {}\n","<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n >\n >\n </yuv-number>\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { MetadataDefaultTemplatesComponent } from './metadata-default-templates/metadata-default-templates.component';\n\n@NgModule({\n imports: [MetadataDefaultTemplatesComponent],\n exports: [MetadataDefaultTemplatesComponent],\n})\nexport class YuvMetadataFormDefaultsModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings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AA;;4FAGhC,6BAA6B,EAAA,UAAA,EAAA,CAAA;kBAJzC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,iCAAiC,CAAC;oBAC5C,OAAO,EAAE,CAAC,iCAAiC,CAAC;AAC7C,iBAAA;;;ACND;;AAEG;;;;"}
1
+ {"version":3,"file":"yuuvis-client-framework-metadata-form-defaults.mjs","sources":["../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-default-templates/metadata-default-templates.component.ts","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-default-templates/metadata-default-templates.component.html","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/lib/metadata-form-defaults.module.ts","../../../../../libs/yuuvis/client-framework/metadata-form-defaults/src/yuuvis-client-framework-metadata-form-defaults.ts"],"sourcesContent":["import { NgTemplateOutlet } from '@angular/common';\nimport { Component } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatSlideToggleModule } from '@angular/material/slide-toggle';\nimport {\n CatalogComponent,\n DataGridComponent,\n DatetimeComponent,\n DatetimeRangeComponent,\n DynamicCatalogComponent,\n I18nCatalogComponent,\n NumberComponent,\n NumberRangeComponent,\n OrganizationComponent,\n OrganizationSetComponent,\n StringComponent\n} from '@yuuvis/client-framework/forms';\nimport {\n ObjectMetadataElementErrorDirective,\n ObjectMetadataElementLabelDirective,\n ObjectMetadataElementRawDirective,\n ObjectMetadataElementTemplateDirective\n} from '@yuuvis/client-framework/metadata-form';\n\n@Component({\n selector: 'yuv-metadata-default-templates',\n standalone: true,\n imports: [\n NgTemplateOutlet,\n ReactiveFormsModule,\n StringComponent,\n DataGridComponent,\n OrganizationComponent,\n OrganizationSetComponent,\n CatalogComponent,\n DynamicCatalogComponent,\n I18nCatalogComponent,\n NumberComponent,\n NumberRangeComponent,\n DatetimeComponent,\n DatetimeRangeComponent,\n ObjectMetadataElementTemplateDirective,\n ObjectMetadataElementRawDirective,\n ObjectMetadataElementLabelDirective,\n ObjectMetadataElementErrorDirective,\n MatCheckboxModule,\n MatFormFieldModule,\n MatSlideToggleModule\n ],\n templateUrl: './metadata-default-templates.component.html',\n styleUrl: './metadata-default-templates.component.scss'\n})\nexport class MetadataDefaultTemplatesComponent {}\n","<!-- form element templates -->\n\n<!-- STRING -->\n<ng-template #rawString yuvMetadataElementRaw=\"default\" propertyType=\"string\" let-ctx>\n <yuv-string\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [rows]=\"ctx.field.rows\"\n [classifications]=\"ctx.field.classifications\"\n [regex]=\"ctx.field.regex\"\n [readonly]=\"ctx.field.readonly\"\n [minLength]=\"ctx.field.minLength\"\n [maxLength]=\"ctx.field.maxLength\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawString; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC) -->\n<ng-template #rawCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog\" let-ctx>\n <yuv-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (STATIC TRANSLATED) -->\n<ng-template #rawI18nCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <yuv-i18n-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [propertyName]=\"ctx.field.name\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:i18n\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawI18nCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- STRING CATALOG (DYNAMIC) -->\n<ng-template #rawDynamicCatalog yuvMetadataElementRaw=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <yuv-dynamic-catalog\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [catalog]=\"ctx.field.catalog\"\n [attr.data-name]=\"ctx.field.name\"\n [multiple]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:catalog:dynamic\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDynamicCatalog; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION -->\n<ng-template #rawOrganization yuvMetadataElementRaw=\"default\" propertyType=\"string:organization\" let-ctx>\n <yuv-organization\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n (userSelect)=\"ctx.field.dataMeta = $event\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganization; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- ORGANIZATION SET -->\n<ng-template #rawOrganizationSet yuvMetadataElementRaw=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <yuv-organization-set\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [multiselect]=\"ctx.field.cardinality === 'multi' || ctx.situation === 'SEARCH'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"string:organization:set\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawOrganizationSet; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- INTEGER -->\n<ng-template #rawInteger yuvMetadataElementRaw=\"default\" propertyType=\"integer\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"0\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [pattern]=\"ctx.field.pattern\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"integer\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawInteger; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- DECIMAL -->\n<ng-template #rawDecimal yuvMetadataElementRaw=\"default\" propertyType=\"decimal\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-number\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [grouping]=\"ctx.field.grouping\"\n [pattern]=\"ctx.field.pattern\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-number-range\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [precision]=\"ctx.field.precision\"\n [scale]=\"ctx.field.scale\"\n [pattern]=\"ctx.field.pattern\"\n [grouping]=\"ctx.field.grouping\"\n [minValue]=\"ctx.field.minValue\"\n [maxValue]=\"ctx.field.maxValue\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"decimal\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDecimal; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- BOOLEAN -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean\" let-ctx>\n <mat-checkbox\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n [indeterminate]=\"\n ctx.field.tristate === false ? false : ctx.ctrl.value !== true && ctx.ctrl.value !== false ? true : false\n \"\n />\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- BOOLEAN SWITCH -->\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"boolean:switch\" let-ctx>\n <mat-slide-toggle\n [formControl]=\"ctx.ctrl\"\n switch=\"true\"\n [attr.data-name]=\"ctx.field.name\"\n [disabled]=\"ctx.field.readonly\"\n ></mat-slide-toggle>\n <label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</label>\n</ng-template>\n\n<!-- DATETIME -->\n<ng-template #rawDatetime yuvMetadataElementRaw=\"default\" propertyType=\"datetime\" let-ctx>\n @if (ctx.situation !== 'SEARCH') {\n <yuv-datetime\n [required]=\"ctx.field.required\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n } @else {\n <yuv-datetime-range\n [required]=\"ctx.field.required\"\n [situation]=\"ctx.situation\"\n [readonly]=\"ctx.field.readonly\"\n [withTime]=\"ctx.field.resolution !== 'date'\"\n [formControl]=\"ctx.ctrl\"\n [attr.data-name]=\"ctx.field.name\"\n />\n }\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"datetime\" let-ctx>\n <mat-form-field>\n <mat-label [yuvObjectMetadataElementLabel]=\"ctx\">{{ ctx.label }}</mat-label>\n <ng-container *ngTemplateOutlet=\"rawDatetime; context: { $implicit: ctx }\" />\n <mat-hint>{{ ctx.description }}</mat-hint>\n <mat-error [yuvObjectMetadataElementError]=\"ctx.ctrl\" />\n </mat-form-field>\n</ng-template>\n\n<!-- TABLE -->\n<ng-template #rawTable yuvMetadataElementRaw=\"default\" propertyType=\"table\" let-ctx>\n <yuv-data-grid\n [situation]=\"ctx.situation\"\n [formControl]=\"ctx.ctrl\"\n [formElement]=\"ctx.field\"\n [attr.data-name]=\"ctx.field.name\"\n [classifications]=\"ctx.field.classifications\"\n [readonly]=\"ctx.field.readonly\"\n [formFieldContext]=\"ctx\"\n />\n</ng-template>\n<ng-template yuvMetadataElementTemplate=\"default\" propertyType=\"table\" let-ctx>\n <ng-container *ngTemplateOutlet=\"rawTable; context: { $implicit: ctx }\" />\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { MetadataDefaultTemplatesComponent } from './metadata-default-templates/metadata-default-templates.component';\n\n@NgModule({\n imports: [MetadataDefaultTemplatesComponent],\n exports: [MetadataDefaultTemplatesComponent],\n})\nexport class YuvMetadataFormDefaultsModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;MAsDa,iCAAiC,CAAA;+GAAjC,iCAAiC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAjC,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,iCAAiC,0FCtD9C,uuWA0RA,EAAA,MAAA,EAAA,CAAA,8DAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,ED5PI,gBAAgB,EAAA,QAAA,EAAA,oBAAA,EAAA,MAAA,EAAA,CAAA,yBAAA,EAAA,kBAAA,EAAA,0BAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAChB,mBAAmB,grBACnB,eAAe,EAAA,QAAA,EAAA,YAAA,EAAA,MAAA,EAAA,CAAA,aAAA,EAAA,MAAA,EAAA,UAAA,EAAA,WAAA,EAAA,iBAAA,EAAA,WAAA,EAAA,OAAA,EAAA,WAAA,EAAA,WAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EACf,iBAAiB,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,CAAA,WAAA,EAAA,aAAA,EAAA,aAAA,EAAA,iBAAA,EAAA,UAAA,EAAA,kBAAA,EAAA,MAAA,CAAA,EAAA,EAAA,EAAA,IAAA,E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}
@@ -28,6 +28,12 @@ class MetadataFormElementRegistry {
28
28
  this._edit = {};
29
29
  this._search = {};
30
30
  this._create = {};
31
+ // Parallel maps for raw (unwrapped) form element templates. Same keying and
32
+ // situation cascade as the wrapped maps above.
33
+ this._rawDefaults = {};
34
+ this._rawEdit = {};
35
+ this._rawSearch = {};
36
+ this._rawCreate = {};
31
37
  // registering a template by name will add this prefix to the given name
32
38
  this.NAME_PROPERTY_PREFIX = '@name:';
33
39
  }
@@ -107,6 +113,86 @@ class MetadataFormElementRegistry {
107
113
  _removeDefaultElementTemplate(propertyType) {
108
114
  delete this._defaults[propertyType];
109
115
  }
116
+ /**
117
+ * Get a raw (unwrapped) form element template — only the inner widget,
118
+ * without the surrounding `mat-form-field` / label / hint / error shell.
119
+ * Use this when composing the widget into a custom layout (e.g. smart-search).
120
+ * @param propertyType The internal type to get the template for
121
+ * @param situation Form situation
122
+ * @returns TemplateRef or undefined
123
+ */
124
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
125
+ getRawElementTemplate(propertyType, situation = Situation.EDIT) {
126
+ let map = { ...this._rawDefaults, ...this._rawEdit };
127
+ if (situation === Situation.SEARCH)
128
+ map = { ...this._rawDefaults, ...this._rawEdit, ...this._rawSearch };
129
+ else if (situation === Situation.CREATE)
130
+ map = { ...this._rawDefaults, ...this._rawEdit, ...this._rawCreate };
131
+ return map[propertyType];
132
+ }
133
+ /**
134
+ * Register a raw form element template for a certain internal type.
135
+ * @param propertyType The internal type to provide the template for
136
+ * @param templateRef The template
137
+ * @param situation Form situation to provide the form element for (defaults to EDIT)
138
+ */
139
+ addRawElementTemplate(propertyType,
140
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
141
+ templateRef, situation = Situation.EDIT) {
142
+ if (propertyType && templateRef) {
143
+ switch (situation) {
144
+ case Situation.SEARCH: {
145
+ this._rawSearch[propertyType] = templateRef;
146
+ break;
147
+ }
148
+ case Situation.CREATE: {
149
+ this._rawCreate[propertyType] = templateRef;
150
+ break;
151
+ }
152
+ default: {
153
+ this._rawEdit[propertyType] = templateRef;
154
+ }
155
+ }
156
+ }
157
+ }
158
+ /**
159
+ * Remove a registered raw form element template.
160
+ * @param propertyType The internal type to remove the template for
161
+ * @param situation Form situation
162
+ */
163
+ removeRawElementTemplate(propertyType, situation = Situation.EDIT) {
164
+ switch (situation) {
165
+ case Situation.SEARCH: {
166
+ delete this._rawSearch[propertyType];
167
+ break;
168
+ }
169
+ case Situation.CREATE: {
170
+ delete this._rawCreate[propertyType];
171
+ break;
172
+ }
173
+ default: {
174
+ delete this._rawEdit[propertyType];
175
+ }
176
+ }
177
+ }
178
+ /**
179
+ * Register a default raw form element template (used across all situations).
180
+ * @param propertyType The internal type to provide the template for
181
+ * @param templateRef The default template
182
+ */
183
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
184
+ _addDefaultRawElementTemplate(propertyType, templateRef) {
185
+ if (propertyType && templateRef) {
186
+ this._rawDefaults[propertyType] = templateRef;
187
+ }
188
+ }
189
+ /**
190
+ * Remove a registered default raw form element template.
191
+ * @param propertyType The internal type to remove the template for
192
+ */
193
+ _removeDefaultRawElementTemplate(propertyType) {
194
+ delete this._rawDefaults[propertyType];
195
+ }
110
196
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataFormElementRegistry, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
111
197
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataFormElementRegistry, providedIn: 'root' }); }
112
198
  }
@@ -321,6 +407,82 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
321
407
  }]
322
408
  }], propDecorators: { yuvMetadataElementTemplate: [{ type: i0.Input, args: [{ isSignal: true, alias: "yuvMetadataElementTemplate", required: false }] }], situation: [{ type: i0.Input, args: [{ isSignal: true, alias: "situation", required: false }] }], propertyType: [{ type: i0.Input, args: [{ isSignal: true, alias: "propertyType", required: false }] }], propertyName: [{ type: i0.Input, args: [{ isSignal: true, alias: "propertyName", required: false }] }] } });
323
409
 
410
+ /**
411
+ * Directive to be applied to an `ng-template` that renders only the raw form
412
+ * widget for a metadata property (without the surrounding `mat-form-field`
413
+ * label/hint/error shell). The template is registered in the raw bucket of
414
+ * `MetadataFormElementRegistry`, parallel to the wrapped templates registered
415
+ * via `yuvMetadataElementTemplate`.
416
+ *
417
+ * Use this to expose a type-aware input that can be composed into custom
418
+ * layouts — for example smart-search, where conditions are built inline as
419
+ * a pill chain and a full form-field shell would be visually wrong.
420
+ *
421
+ * @example
422
+ * <ng-template #rawString yuvMetadataElementRaw="default" propertyType="string" let-ctx>
423
+ * <yuv-string [formControl]="ctx.ctrl" [required]="ctx.field.required" />
424
+ * </ng-template>
425
+ */
426
+ class ObjectMetadataElementRawDirective {
427
+ constructor() {
428
+ this.#registry = inject(MetadataFormElementRegistry);
429
+ this.#template = inject((TemplateRef));
430
+ /**
431
+ * Bucket to register the template. Use 'default' for templates that should be
432
+ * used across all situations.
433
+ */
434
+ this.yuvMetadataElementRaw = input(...(ngDevMode ? [undefined, { debugName: "yuvMetadataElementRaw" }] : /* istanbul ignore next */ []));
435
+ /**
436
+ * Situation to register the template for. Defaults to `EDIT`.
437
+ */
438
+ this.situation = input(Situation.EDIT, ...(ngDevMode ? [{ debugName: "situation" }] : /* istanbul ignore next */ []));
439
+ /**
440
+ * Internal property type to register the template under. You need to set
441
+ * either `propertyType` or `propertyName`. When both are set, `propertyName`
442
+ * wins because it is more precise.
443
+ */
444
+ this.propertyType = input(...(ngDevMode ? [undefined, { debugName: "propertyType" }] : /* istanbul ignore next */ []));
445
+ /**
446
+ * Register the raw template by metadata field name.
447
+ */
448
+ this.propertyName = input(...(ngDevMode ? [undefined, { debugName: "propertyName" }] : /* istanbul ignore next */ []));
449
+ }
450
+ #registry;
451
+ #template;
452
+ #registrationKey;
453
+ ngOnInit() {
454
+ const pn = this.propertyName();
455
+ this.#registrationKey = pn ? `${this.#registry.NAME_PROPERTY_PREFIX}${pn}` : this.propertyType();
456
+ if (!this.#registrationKey)
457
+ return;
458
+ if (this.yuvMetadataElementRaw() === 'default') {
459
+ this.#registry._addDefaultRawElementTemplate(this.#registrationKey, this.#template);
460
+ }
461
+ else {
462
+ this.#registry.addRawElementTemplate(this.#registrationKey, this.#template, this.situation());
463
+ }
464
+ }
465
+ ngOnDestroy() {
466
+ if (!this.#registrationKey)
467
+ return;
468
+ if (this.yuvMetadataElementRaw() === 'default') {
469
+ this.#registry._removeDefaultRawElementTemplate(this.#registrationKey);
470
+ }
471
+ else {
472
+ this.#registry.removeRawElementTemplate(this.#registrationKey, this.situation());
473
+ }
474
+ }
475
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ObjectMetadataElementRawDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
476
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.12", type: ObjectMetadataElementRawDirective, isStandalone: true, selector: "[yuvMetadataElementRaw]", inputs: { yuvMetadataElementRaw: { classPropertyName: "yuvMetadataElementRaw", publicName: "yuvMetadataElementRaw", isSignal: true, isRequired: false, transformFunction: null }, situation: { classPropertyName: "situation", publicName: "situation", isSignal: true, isRequired: false, transformFunction: null }, propertyType: { classPropertyName: "propertyType", publicName: "propertyType", isSignal: true, isRequired: false, transformFunction: null }, propertyName: { classPropertyName: "propertyName", publicName: "propertyName", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
477
+ }
478
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ObjectMetadataElementRawDirective, decorators: [{
479
+ type: Directive,
480
+ args: [{
481
+ selector: '[yuvMetadataElementRaw]',
482
+ standalone: true
483
+ }]
484
+ }], propDecorators: { yuvMetadataElementRaw: [{ type: i0.Input, args: [{ isSignal: true, alias: "yuvMetadataElementRaw", required: false }] }], situation: [{ type: i0.Input, args: [{ isSignal: true, alias: "situation", required: false }] }], propertyType: [{ type: i0.Input, args: [{ isSignal: true, alias: "propertyType", required: false }] }], propertyName: [{ type: i0.Input, args: [{ isSignal: true, alias: "propertyName", required: false }] }] } });
485
+
324
486
  /**
325
487
  * Component to render a metadata form field within an object form. These forms are
326
488
  * created to render and edit metadata of DMS objects. This component is used as a wrapper
@@ -335,12 +497,22 @@ class MetadataFormFieldComponent {
335
497
  this.readonly = false;
336
498
  this.formChangedSubject = input(...(ngDevMode ? [undefined, { debugName: "formChangedSubject" }] : /* istanbul ignore next */ []));
337
499
  this.formField = input.required({ ...(ngDevMode ? { debugName: "formField" } : /* istanbul ignore next */ {}), alias: 'field' });
500
+ /**
501
+ * Which template variant to render. `default` renders the wrapped form field
502
+ * (mat-form-field with label, hint, error). `raw` renders only the inner
503
+ * widget — useful for composing into custom layouts such as smart-search.
504
+ */
505
+ this.variant = input('default', ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
338
506
  // elementTemplate = signal<TemplateRef<any> | undefined>(undefined);
339
507
  this.elementTemplate = computed(() => {
340
508
  const field = this.formField();
341
509
  // TODO: set readonly state based on ...????... schema?
342
510
  this.readonly = false;
343
- const templateByName = this.#registry.getElementTemplate(`${this.#registry.NAME_PROPERTY_PREFIX}${field.name}`, this.situation());
511
+ const isRaw = this.variant() === 'raw';
512
+ const lookup = isRaw
513
+ ? (key) => this.#registry.getRawElementTemplate(key, this.situation())
514
+ : (key) => this.#registry.getElementTemplate(key, this.situation());
515
+ const templateByName = lookup(`${this.#registry.NAME_PROPERTY_PREFIX}${field.name}`);
344
516
  if (templateByName) {
345
517
  return templateByName;
346
518
  }
@@ -348,7 +520,7 @@ class MetadataFormFieldComponent {
348
520
  if (!field._internalType) {
349
521
  field._internalType = this.#system.getInternalFormElementType(field.propertyType);
350
522
  }
351
- return this.#registry.getElementTemplate(field._internalType, this.situation());
523
+ return lookup(field._internalType);
352
524
  }
353
525
  }, ...(ngDevMode ? [{ debugName: "elementTemplate" }] : /* istanbul ignore next */ []));
354
526
  this.context = computed(() => {
@@ -374,18 +546,18 @@ class MetadataFormFieldComponent {
374
546
  #localization;
375
547
  #ngControl;
376
548
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataFormFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
377
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: MetadataFormFieldComponent, isStandalone: true, selector: "yuv-metadata-form-field", inputs: { formChangedSubject: { classPropertyName: "formChangedSubject", publicName: "formChangedSubject", isSignal: true, isRequired: false, transformFunction: null }, formField: { classPropertyName: "formField", publicName: "field", isSignal: true, isRequired: true, transformFunction: null }, situation: { classPropertyName: "situation", publicName: "situation", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "yuv-metadata-form-field" }, hostDirectives: [{ directive: i1.NoopValueAccessorDirective }], ngImport: i0, template: "@let field = formField();\n@let et = elementTemplate();\n\n@if (field) {\n <div class=\"form-field t-{{ field._internalType }}\" #formField [attr.data-name]=\"field.name\" [ngClass]=\"{ disabled: !!readonly }\">\n @if (et) {\n <ng-container *ngTemplateOutlet=\"et; context: { $implicit: context() }\"></ng-container>\n } @else {\n <em>\n <strong>{{ field._internalType }}</strong>\n </em>\n }\n </div>\n}\n", styles: [".yuv-metadata-form-field{--label-background-color: transparent;--label-color: inherit}.yuv-metadata-form-field .form-field{margin-block-end:1px;border-radius:.25em;display:flex;align-items:center}.yuv-metadata-form-field .form-field .yuv-label-invalid,.yuv-metadata-form-field .form-field .yuv-formfield-invalid{--label-background-color: var(--ymt-danger-container);--label-color: var(--ymt-on-danger-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-required,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-required{--label-background-color: var(--ymt-primary-container);--label-color: var(--ymt-on-primary-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-dirty,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-dirty{--label-background-color: var(--ymt-success-container);--label-color: var(--ymt-on-success-container)}.yuv-metadata-form-field .form-field .label,.yuv-metadata-form-field .form-field label{--transition-duration: 2s;position:relative;background-color:var(--label-background-color)!important;color:var(--label-color)!important;border-radius:2px;box-shadow:0 0 0 3px var(--label-background-color)}.yuv-metadata-form-field .form-field mat-form-field{flex:1}.yuv-metadata-form-field .form-field .yuv-label-marker-dirty:after{content:\"\";display:inline-block;background-color:var(--ymt-warning-container);border:1px solid var(--ymt-on-warning-container);border-radius:50%;width:.5em;height:.5em;margin-inline-start:.5em;margin-inline-end:.25em}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatFormFieldModule }], encapsulation: i0.ViewEncapsulation.None }); }
549
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: MetadataFormFieldComponent, isStandalone: true, selector: "yuv-metadata-form-field", inputs: { formChangedSubject: { classPropertyName: "formChangedSubject", publicName: "formChangedSubject", isSignal: true, isRequired: false, transformFunction: null }, formField: { classPropertyName: "formField", publicName: "field", isSignal: true, isRequired: true, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, situation: { classPropertyName: "situation", publicName: "situation", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "yuv-metadata-form-field" }, hostDirectives: [{ directive: i1.NoopValueAccessorDirective }], ngImport: i0, template: "@let field = formField();\n@let et = elementTemplate();\n\n@if (field) {\n <div\n [class]=\"'form-field t-' + field._internalType\"\n #formField\n [attr.data-name]=\"field.name\"\n [ngClass]=\"{ disabled: !!readonly, 'form-field--raw': variant() === 'raw' }\"\n >\n @if (et) {\n <ng-container *ngTemplateOutlet=\"et; context: { $implicit: context() }\"></ng-container>\n } @else {\n <em>\n <strong>{{ field._internalType }}</strong>\n </em>\n }\n </div>\n}\n", styles: [".yuv-metadata-form-field{--label-background-color: transparent;--label-color: inherit}.yuv-metadata-form-field .form-field{margin-block-end:1px;border-radius:.25em;display:flex;align-items:center}.yuv-metadata-form-field .form-field .yuv-label-invalid,.yuv-metadata-form-field .form-field .yuv-formfield-invalid{--label-background-color: var(--ymt-danger-container);--label-color: var(--ymt-on-danger-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-required,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-required{--label-background-color: var(--ymt-primary-container);--label-color: var(--ymt-on-primary-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-dirty,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-dirty{--label-background-color: var(--ymt-success-container);--label-color: var(--ymt-on-success-container)}.yuv-metadata-form-field .form-field .label,.yuv-metadata-form-field .form-field label{--transition-duration: 2s;position:relative;background-color:var(--label-background-color)!important;color:var(--label-color)!important;border-radius:2px;box-shadow:0 0 0 3px var(--label-background-color)}.yuv-metadata-form-field .form-field>*{flex:1}.yuv-metadata-form-field .form-field .yuv-label-marker-dirty:after{content:\"\";display:inline-block;background-color:var(--ymt-warning-container);border:1px solid var(--ymt-on-warning-container);border-radius:50%;width:.5em;height:.5em;margin-inline-start:.5em;margin-inline-end:.25em}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatFormFieldModule }], encapsulation: i0.ViewEncapsulation.None }); }
378
550
  }
379
551
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: MetadataFormFieldComponent, decorators: [{
380
552
  type: Component,
381
553
  args: [{ selector: 'yuv-metadata-form-field', standalone: true, imports: [NgClass, NgTemplateOutlet, MatFormFieldModule], hostDirectives: [NoopValueAccessorDirective], encapsulation: ViewEncapsulation.None, host: {
382
554
  class: 'yuv-metadata-form-field'
383
- }, template: "@let field = formField();\n@let et = elementTemplate();\n\n@if (field) {\n <div class=\"form-field t-{{ field._internalType }}\" #formField [attr.data-name]=\"field.name\" [ngClass]=\"{ disabled: !!readonly }\">\n @if (et) {\n <ng-container *ngTemplateOutlet=\"et; context: { $implicit: context() }\"></ng-container>\n } @else {\n <em>\n <strong>{{ field._internalType }}</strong>\n </em>\n }\n </div>\n}\n", styles: [".yuv-metadata-form-field{--label-background-color: transparent;--label-color: inherit}.yuv-metadata-form-field .form-field{margin-block-end:1px;border-radius:.25em;display:flex;align-items:center}.yuv-metadata-form-field .form-field .yuv-label-invalid,.yuv-metadata-form-field .form-field .yuv-formfield-invalid{--label-background-color: var(--ymt-danger-container);--label-color: var(--ymt-on-danger-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-required,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-required{--label-background-color: var(--ymt-primary-container);--label-color: var(--ymt-on-primary-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-dirty,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-dirty{--label-background-color: var(--ymt-success-container);--label-color: var(--ymt-on-success-container)}.yuv-metadata-form-field .form-field .label,.yuv-metadata-form-field .form-field label{--transition-duration: 2s;position:relative;background-color:var(--label-background-color)!important;color:var(--label-color)!important;border-radius:2px;box-shadow:0 0 0 3px var(--label-background-color)}.yuv-metadata-form-field .form-field mat-form-field{flex:1}.yuv-metadata-form-field .form-field .yuv-label-marker-dirty:after{content:\"\";display:inline-block;background-color:var(--ymt-warning-container);border:1px solid var(--ymt-on-warning-container);border-radius:50%;width:.5em;height:.5em;margin-inline-start:.5em;margin-inline-end:.25em}\n"] }]
384
- }], propDecorators: { formChangedSubject: [{ type: i0.Input, args: [{ isSignal: true, alias: "formChangedSubject", required: false }] }], formField: [{ type: i0.Input, args: [{ isSignal: true, alias: "field", required: true }] }], situation: [{ type: i0.Input, args: [{ isSignal: true, alias: "situation", required: false }] }] } });
555
+ }, template: "@let field = formField();\n@let et = elementTemplate();\n\n@if (field) {\n <div\n [class]=\"'form-field t-' + field._internalType\"\n #formField\n [attr.data-name]=\"field.name\"\n [ngClass]=\"{ disabled: !!readonly, 'form-field--raw': variant() === 'raw' }\"\n >\n @if (et) {\n <ng-container *ngTemplateOutlet=\"et; context: { $implicit: context() }\"></ng-container>\n } @else {\n <em>\n <strong>{{ field._internalType }}</strong>\n </em>\n }\n </div>\n}\n", styles: [".yuv-metadata-form-field{--label-background-color: transparent;--label-color: inherit}.yuv-metadata-form-field .form-field{margin-block-end:1px;border-radius:.25em;display:flex;align-items:center}.yuv-metadata-form-field .form-field .yuv-label-invalid,.yuv-metadata-form-field .form-field .yuv-formfield-invalid{--label-background-color: var(--ymt-danger-container);--label-color: var(--ymt-on-danger-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-required,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-required{--label-background-color: var(--ymt-primary-container);--label-color: var(--ymt-on-primary-container)}.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-label-dirty,.yuv-metadata-form-field .form-field :not(.yuv-label-invalid,.yuv-formfield-invalid).yuv-formfield-dirty{--label-background-color: var(--ymt-success-container);--label-color: var(--ymt-on-success-container)}.yuv-metadata-form-field .form-field .label,.yuv-metadata-form-field .form-field label{--transition-duration: 2s;position:relative;background-color:var(--label-background-color)!important;color:var(--label-color)!important;border-radius:2px;box-shadow:0 0 0 3px var(--label-background-color)}.yuv-metadata-form-field .form-field>*{flex:1}.yuv-metadata-form-field .form-field .yuv-label-marker-dirty:after{content:\"\";display:inline-block;background-color:var(--ymt-warning-container);border:1px solid var(--ymt-on-warning-container);border-radius:50%;width:.5em;height:.5em;margin-inline-start:.5em;margin-inline-end:.25em}\n"] }]
556
+ }], propDecorators: { formChangedSubject: [{ type: i0.Input, args: [{ isSignal: true, alias: "formChangedSubject", required: false }] }], formField: [{ type: i0.Input, args: [{ isSignal: true, alias: "field", required: true }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], situation: [{ type: i0.Input, args: [{ isSignal: true, alias: "situation", required: false }] }] } });
385
557
 
386
558
  /**
387
559
  * Generated bundle index. Do not edit.
388
560
  */
389
561
 
390
- export { MetadataFormElementRegistry, MetadataFormFieldComponent, ObjectMetadataElementErrorDirective, ObjectMetadataElementLabelDirective, ObjectMetadataElementTemplateDirective };
562
+ export { MetadataFormElementRegistry, MetadataFormFieldComponent, ObjectMetadataElementErrorDirective, ObjectMetadataElementLabelDirective, ObjectMetadataElementRawDirective, ObjectMetadataElementTemplateDirective };
391
563
  //# sourceMappingURL=yuuvis-client-framework-metadata-form.mjs.map