@yuuvis/client-framework 2.9.1 → 2.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -147,6 +147,7 @@ class ListComponent {
147
147
  if (this.#lastSelection !== undefined && this.#lastSelection <= items.length) {
148
148
  this.select(this.#lastSelection);
149
149
  }
150
+ this.#preselectItem();
150
151
  });
151
152
  });
152
153
  this.#selection = [];
@@ -366,9 +367,6 @@ class ListComponent {
366
367
  this.select(itemIndexToSelect);
367
368
  }
368
369
  }
369
- ngAfterContentInit() {
370
- this.#preselectItem();
371
- }
372
370
  ngOnDestroy() {
373
371
  this.#keyManager?.destroy();
374
372
  }
@@ -1 +1 @@
1
- {"version":3,"file":"yuuvis-client-framework-list.mjs","sources":["../../../../../libs/yuuvis/client-framework/list/src/lib/list-item.directive.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list.component.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list-tile/list-tile.component.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list-tile/list-tile.component.html","../../../../../libs/yuuvis/client-framework/list/src/lib/list.module.ts","../../../../../libs/yuuvis/client-framework/list/src/yuuvis-client-framework-list.ts"],"sourcesContent":["import { Highlightable } from '@angular/cdk/a11y';\nimport { AfterViewInit, Directive, ElementRef, HostListener, inject, input, Input, linkedSignal } from '@angular/core';\nimport { Utils } from '@yuuvis/client-core';\n\n/**\n * Directive for list items. It is used in the `yuvList` component\n * to keep track of active and selected items. Every element with this\n * directive will be treated as a list item and can be selected and focused.\n * \n *```html\n * <yuv-list (itemSelect)=\"itemSelected($event)\">\n * <div yuvListItem>Entry #1</div>\n * <div yuvListItem>Entry #2</div>\n * </yuv-list>\n * ```\n */\n@Directive({\n selector: '[yuvListItem]',\n standalone: true,\n host: {\n '[attr.aria-current]': 'activeInput()',\n '[attr.aria-selected]': 'selectedInput()'\n }\n})\nexport class ListItemDirective implements Highlightable, AfterViewInit {\n #elRef = inject(ElementRef);\n\n onClick?: (evt: MouseEvent) => void;\n\n // TO SATISFY THE HIGHLIGHTABLE INTERFACE\n @Input() disabled?: boolean | undefined;\n\n /**\n * Whether the item is active or not. \n */\n active = input<boolean>(false);\n /**\n * Whether the item is selected or not. \n */\n selected = input<boolean>(false);\n\n selectedInput = linkedSignal({\n source: this.selected,\n computation: (newOptions: any, previous: any) => (newOptions !== previous ? newOptions : previous)\n });\n\n activeInput = linkedSignal({\n source: this.active,\n computation: (newOptions: any, previous: any) => (newOptions !== previous ? newOptions : previous)\n });\n\n focusableChildren: Element[] = [];\n focusedIndex = -1;\n\n @HostListener('click', ['$event']) onHostClick(evt: MouseEvent) {\n if (!this.disabled && this.onClick) {\n this.#elRef.nativeElement.parentElement.focus();\n this.onClick(evt);\n }\n }\n\n setActiveStyles(): void {\n this.activeInput.set(true);\n this.#scrollIntoView();\n }\n\n setInactiveStyles(): void {\n this.activeInput.set(false);\n }\n\n focusNext() {\n \n }\n\n focusPrevious() {\n }\n\n #scrollIntoView() {\n const el = this.#elRef.nativeElement as HTMLElement;\n const { bottom, top, left, right } = el.getBoundingClientRect();\n const containerRect = this.#elRef.nativeElement.parentElement.getBoundingClientRect();\n\n const offsetY =\n top <= containerRect.top\n ? containerRect.top - top > 0\n ? (containerRect.top - top) * -1\n : 0\n : bottom - containerRect.bottom > 0\n ? bottom - containerRect.bottom\n : 0;\n const offsetX =\n left <= containerRect.left\n ? containerRect.left - left > 0\n ? (containerRect.left - left) * -1\n : 0\n : right - containerRect.right > 0\n ? right - containerRect.right\n : 0;\n\n if (offsetX || offsetY) (this.#elRef.nativeElement.parentElement as HTMLElement).scrollBy(offsetX, offsetY);\n }\n\n ngAfterViewInit(): void {\n // get all focusable elements and set tabindex to -1\n this.focusableChildren = Utils.getFocusableChildren(this.#elRef.nativeElement);\n this.focusableChildren.forEach((el) => el.setAttribute('tabindex', '-1'));\n }\n}\n","import { A11yModule, ActiveDescendantKeyManager } from '@angular/cdk/a11y';\nimport { Directionality } from '@angular/cdk/bidi';\nimport { CommonModule } from '@angular/common';\nimport {\n Component,\n ElementRef,\n HostAttributeToken,\n HostListener,\n OnDestroy,\n ViewEncapsulation,\n contentChildren,\n effect,\n inject,\n input,\n output,\n untracked,\n AfterContentInit\n} from '@angular/core';\nimport { ListItemDirective } from './list-item.directive';\nimport { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\n\n/**\n * Component rendering a simple list of items. It supports keyboard\n * navigation and takes care of accessibility. To create a list just wrap\n * `yuvListItem` elements into this component:\n *\n * ```html\n * <yuv-list (itemSelect)=\"itemSelected($event)\">\n * <div yuvListItem>Entry #1</div>\n * <div yuvListItem>Entry #2</div>\n * </yuv-list>\n * ```\n */\n@Component({\n selector: 'yuv-list',\n standalone: true,\n imports: [CommonModule, A11yModule],\n template: '<ng-content></ng-content>',\n styleUrl: './list.component.scss',\n encapsulation: ViewEncapsulation.None,\n host: {\n role: 'listbox',\n tabindex: '0',\n '[class.self-handle-selection]': 'selfHandleSelection()'\n }\n})\nexport class ListComponent implements AfterContentInit, OnDestroy {\n #dir = inject(Directionality);\n #elRef = inject(ElementRef);\n\n @HostListener('keydown', ['$event']) onKeydown(event: KeyboardEvent) {\n if (this.disableSelection()) return;\n if (event.code === 'Escape') {\n this.clear();\n }\n\n if (event.code === 'Space' || (this.selectOnEnter && event.code === 'Enter')) {\n // prevent default behavior of space in scroll environments\n if (this.#preventEmit()) return;\n event.preventDefault();\n const aii: number = this.#keyManager.activeItemIndex !== null ? this.#keyManager.activeItemIndex : -1;\n if (aii >= 0) {\n this.#select(aii);\n this.#emitSelection();\n }\n } else this.#keyManager?.onKeydown(event);\n }\n\n @HostListener('focus') onFocus() {\n // set timeout to check if the focus is coming from an item being clicked\n setTimeout(() => {\n // if there already is an active item, we do not want to set the focus again\n if (this.#keyManager.activeItemIndex === -1 && this.items().length > 0) {\n const indexToFocus = this.#selection.length > 0 ? this.#selection[0] : 0;\n this.#keyManager.setActiveItem(indexToFocus);\n this.itemFocus.emit(indexToFocus);\n this.#updateActiveItemState();\n }\n }, 300);\n }\n\n items = contentChildren(ListItemDirective);\n #itemsEffect = effect(() => {\n const items = this.items();\n if (this.#keyManager) this.#keyManager.destroy();\n untracked(() => {\n this.#keyManager = this.horizontal\n ? new ActiveDescendantKeyManager(items).withWrap().withHorizontalOrientation(this.#dir.value)\n : new ActiveDescendantKeyManager(items).withWrap();\n\n this.#keyManager.change.subscribe((activeIndex) => {\n if (activeIndex !== null) {\n this.#updateActiveItemState();\n this.itemFocus.emit(activeIndex);\n }\n });\n\n if (!this.selfHandleClick()) {\n items.forEach((item, index) => {\n item.onClick = (evt: MouseEvent) => {\n this.select(index, evt.shiftKey, evt.ctrlKey);\n };\n item.activeInput.set(false);\n });\n }\n if (this.#lastSelection !== undefined && this.#lastSelection <= items.length) {\n this.select(this.#lastSelection);\n }\n });\n });\n\n #keyManager!: ActiveDescendantKeyManager<ListItemDirective>;\n #selection: number[] = [];\n #lastSelection?: number;\n\n /**\n * Function that returns `true` if selection changes should be prevented.\n * This can be used to temporarily block selection changes, e.g. while\n * there is a pending change inside another component that refers to the\n * current selection.\n */\n preventChangeUntil = input<() => boolean>(() => false);\n /**\n * If `true`, multiple items can be selected at once.\n * @default false\n */\n multiselect = input<boolean>(false);\n /**\n * If `true`, the component will handle selection itself. This means that\n * the parent component will be responsible for styling the selected and\n * focused items. If `false`, the component will take care of visualizing\n * the selection and focus states.\n * @default false\n */\n selfHandleSelection = input<boolean>(false);\n /**\n * By default the list handles click events on its items to select them.\n * If this input is set to `true`, the parent component has to handle\n * click events itself and call the `select()` method accordingly.\n *\n * If you for example use the `ClickDoubleDirective` on the list items,\n * you have to set this input to `true` to prevent the list from\n * selecting items on single click.\n * @default false\n */\n selfHandleClick = input<boolean>(false);\n /**\n * If `true`, the list will select an item automatically on initialization.\n * First, list will search for an item item that has the \"selected\"-attribute\n * and is not disabled. If no such item exists, the first item will be selected.\n * @default false\n */\n autoSelect = input<boolean, BooleanInput>(false, { transform: (value: BooleanInput) => coerceBooleanProperty(value) });\n /**\n * Emits the selected items indices.\n */\n itemSelect = output<number[]>();\n /**\n * Emits the index of the item that has focus.\n * @type {output<number>}\n */\n itemFocus = output<number>();\n\n selectOnEnter: boolean = (inject(new HostAttributeToken('selectOnEnter'), { optional: true }) || 'false') === 'true';\n horizontal: boolean = (inject(new HostAttributeToken('horizontal'), { optional: true }) || 'false') === 'true';\n\n /**\n * If `true`, the list will not allow selection of items.\n * This is useful for lists that are used for display purposes only.\n */\n disableSelection = input<boolean>(false);\n\n focus() {\n this.#elRef.nativeElement.focus();\n }\n\n scrollToTop() {\n this.#elRef.nativeElement.scrollTo({ top: 0, behavior: 'smooth' });\n }\n\n /**\n * Shift the current selection by the given offset. Used for dynamically\n * adding items to the list without losing the current selection.\n * @param offset Number of items to shift the selection by. \n */\n shiftSelectionBy(offset: number): void {\n if (this.#keyManager?.activeItemIndex) this.#keyManager.setActiveItem(this.#keyManager.activeItemIndex + offset);\n this.#selection = this.#selection.map((i) => i + offset);\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n }\n\n /**\n * Select multiple items by their indices.\n */\n multiSelect(index: number[]): void {\n if (this.#preventEmit()) return;\n if (!this.multiselect() || this.disableSelection()) return;\n this.#selection = index.filter((i) => i >= 0 && i < this.items().length);\n this.#selection.sort();\n\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n this.#emitSelection();\n }\n\n /**\n * Selects a single item by its index.\n * @param index Index of the item to select.\n * @param shiftKey If `true`, selection will be extended from the last selected item to the given index.\n * @param ctrlKey If `true`, the item at the given index will be toggled in the selection.\n */\n select(index: number, shiftKey = false, ctrlKey = false) {\n if (this.#preventEmit()) return;\n if (this.disableSelection() || index < 0) return;\n if (index >= this.items().length) index = this.items().length - 1;\n\n this.#select(index, shiftKey, ctrlKey);\n if (this.#keyManager) this.#keyManager.setActiveItem(index);\n this.#emitSelection();\n }\n\n #preventEmit() {\n const preventUntilIsTrue = this.preventChangeUntil();\n return preventUntilIsTrue();\n }\n\n /**\n * Clear the current selection.\n * @param silent If `true`, the `itemSelect` event will not be emitted.\n */\n clear(silent = false) {\n if (this.#preventEmit()) return;\n if (this.#selection.length !== 0) {\n this.#select(-1);\n this.#keyManager.setActiveItem(-1);\n if (!silent) this.#emitSelection();\n }\n }\n\n #select(index: number, shiftKey = false, ctrlKey = false) {\n if (index === -1) this.#selection = [];\n else {\n if (this.multiselect()) {\n this.#selection = this.#selection.filter((i) => i !== index);\n if (ctrlKey) {\n this.#selection.push(index);\n } else if (shiftKey) {\n if (this.#lastSelection) {\n for (let i = this.#lastSelection < index ? this.#lastSelection : index; i < (this.#lastSelection > index ? this.#lastSelection : index); i++) {\n this.#selection.push(i);\n }\n } else {\n this.#selection = [index];\n }\n } else {\n this.#selection = [index];\n }\n } else this.#selection = [index];\n }\n this.#lastSelection = this.#selection.length === 0 ? undefined : index;\n this.#selection.sort();\n\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n }\n\n #updateActiveItemState() {\n const activeIndex = this.#keyManager.activeItemIndex;\n this.items().forEach((item: ListItemDirective, i: number) => {\n item.activeInput.set(i === activeIndex);\n });\n }\n\n #emitSelection() {\n this.itemSelect.emit(this.#selection);\n }\n\n #preselectItem() {\n const items = this.items();\n const autoSelect = this.autoSelect();\n let itemIndexToSelect = -1;\n\n // If the list has no items, do nothing.\n if (items.length < 1) return;\n\n // Find the first item that has the \"selected\"-attribute and is not disabled\n itemIndexToSelect = items.findIndex((item) => item.selected() && !item.disabled);\n\n // If no valid item index is given, but autoSelect is true, select the first item\n if (itemIndexToSelect === -1 && autoSelect) {\n itemIndexToSelect = 0;\n }\n\n // If there is a valid item index, select that item, otherwise do nothing\n if (itemIndexToSelect !== -1) {\n this.select(itemIndexToSelect);\n }\n }\n\n ngAfterContentInit(): void {\n this.#preselectItem();\n }\n\n ngOnDestroy(): void {\n this.#keyManager?.destroy();\n }\n}\n","import { Component, contentChild, TemplateRef, viewChild } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ListItemDirective } from '../list-item.directive';\n\n@Component({\n selector: 'yuv-list-tile',\n imports: [CommonModule],\n templateUrl: './list-tile.component.html',\n styleUrl: './list-tile.component.scss',\n // hostDirectives: [ListItemDirective]\n})\nexport class ListTileComponent {\n iconSlot = contentChild<TemplateRef<any>>('iconSlot', {\n descendants: true\n });\n titleSlot = contentChild<TemplateRef<any>>('titleSlot');\n descriptionSlot = contentChild<TemplateRef<any>>('descriptionSlot');\n asideSlot = contentChild<TemplateRef<any>>('asideSlot');\n actionsSlot = contentChild<TemplateRef<any>>('actionsSlot', {\n descendants: true\n });\n badgesSlot = contentChild<TemplateRef<any>>('badgesSlot');\n metaSlot = contentChild<TemplateRef<any>>('metaSlot');\n extensionSlot = contentChild<TemplateRef<any>>('extensionSlot');\n}\n","<ng-content></ng-content>\n<div class=\"tile\">\n <div data-slot=\"icon\">\n <ng-container *ngTemplateOutlet=\"iconSlot() || null\"></ng-container>\n </div>\n <div class=\"slots\"> \n <div data-slot=\"title-description\">\n <div data-slot=\"title\">\n <ng-container *ngTemplateOutlet=\"titleSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"description\">\n <ng-container *ngTemplateOutlet=\"descriptionSlot() || null\"></ng-container>\n </div>\n </div>\n <div data-slot=\"actions\">\n <ng-container *ngTemplateOutlet=\"actionsSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"aside\">\n <ng-container *ngTemplateOutlet=\"asideSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"meta\">\n <ng-container *ngTemplateOutlet=\"metaSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"badges\">\n <ng-container *ngTemplateOutlet=\"badgesSlot() || null\"></ng-container>\n </div>\n <div class=\"extension\">\n <ng-container *ngTemplateOutlet=\"extensionSlot() || null\"></ng-container>\n </div>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { ListItemDirective } from './list-item.directive';\nimport { ListComponent } from './list.component';\nimport { ListTileComponent } from './list-tile/list-tile.component';\n\n@NgModule({\n imports: [ListComponent, ListItemDirective, ListTileComponent],\n exports: [ListComponent, ListItemDirective, ListTileComponent]\n})\nexport class YuvListModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAIA;;;;;;;;;;;AAWG;MASU,iBAAiB,CAAA;AAR9B,IAAA,WAAA,GAAA;AASE,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,UAAU,CAAC;AAO3B;;AAEG;AACH,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK,CAAU,KAAK,CAAC;AAC9B;;AAEG;AACH,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAU,KAAK,CAAC;QAEhC,IAAa,CAAA,aAAA,GAAG,YAAY,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,QAAQ;YACrB,WAAW,EAAE,CAAC,UAAe,EAAE,QAAa,MAAM,UAAU,KAAK,QAAQ,GAAG,UAAU,GAAG,QAAQ;AAClG,SAAA,CAAC;QAEF,IAAW,CAAA,WAAA,GAAG,YAAY,CAAC;YACzB,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,WAAW,EAAE,CAAC,UAAe,EAAE,QAAa,MAAM,UAAU,KAAK,QAAQ,GAAG,UAAU,GAAG,QAAQ;AAClG,SAAA,CAAC;QAEF,IAAiB,CAAA,iBAAA,GAAc,EAAE;QACjC,IAAY,CAAA,YAAA,GAAG,CAAC,CAAC;AAuDlB;AAlFC,IAAA,MAAM;AA6B6B,IAAA,WAAW,CAAC,GAAe,EAAA;QAC5D,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,OAAO,EAAE;YAClC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,aAAa,CAAC,KAAK,EAAE;AAC/C,YAAA,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC;;;IAIrB,eAAe,GAAA;AACb,QAAA,I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AiB,CAAA,EAAA,OAAA,EAAA,CACnD,aAAa,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,CAAA,CAAA;gHAElD,aAAa,EAAA,OAAA,EAAA,CAHd,aAAa,EAAqB,iBAAiB,CAAA,EAAA,CAAA,CAAA;;4FAGlD,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;AAC9D,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,iBAAiB,EAAE,iBAAiB;AAC9D,iBAAA;;;ACRD;;AAEG;;;;"}
1
+ {"version":3,"file":"yuuvis-client-framework-list.mjs","sources":["../../../../../libs/yuuvis/client-framework/list/src/lib/list-item.directive.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list.component.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list-tile/list-tile.component.ts","../../../../../libs/yuuvis/client-framework/list/src/lib/list-tile/list-tile.component.html","../../../../../libs/yuuvis/client-framework/list/src/lib/list.module.ts","../../../../../libs/yuuvis/client-framework/list/src/yuuvis-client-framework-list.ts"],"sourcesContent":["import { Highlightable } from '@angular/cdk/a11y';\nimport { AfterViewInit, Directive, ElementRef, HostListener, inject, input, Input, linkedSignal } from '@angular/core';\nimport { Utils } from '@yuuvis/client-core';\n\n/**\n * Directive for list items. It is used in the `yuvList` component\n * to keep track of active and selected items. Every element with this\n * directive will be treated as a list item and can be selected and focused.\n * \n *```html\n * <yuv-list (itemSelect)=\"itemSelected($event)\">\n * <div yuvListItem>Entry #1</div>\n * <div yuvListItem>Entry #2</div>\n * </yuv-list>\n * ```\n */\n@Directive({\n selector: '[yuvListItem]',\n standalone: true,\n host: {\n '[attr.aria-current]': 'activeInput()',\n '[attr.aria-selected]': 'selectedInput()'\n }\n})\nexport class ListItemDirective implements Highlightable, AfterViewInit {\n #elRef = inject(ElementRef);\n\n onClick?: (evt: MouseEvent) => void;\n\n // TO SATISFY THE HIGHLIGHTABLE INTERFACE\n @Input() disabled?: boolean | undefined;\n\n /**\n * Whether the item is active or not. \n */\n active = input<boolean>(false);\n /**\n * Whether the item is selected or not. \n */\n selected = input<boolean>(false);\n\n selectedInput = linkedSignal({\n source: this.selected,\n computation: (newOptions: any, previous: any) => (newOptions !== previous ? newOptions : previous)\n });\n\n activeInput = linkedSignal({\n source: this.active,\n computation: (newOptions: any, previous: any) => (newOptions !== previous ? newOptions : previous)\n });\n\n focusableChildren: Element[] = [];\n focusedIndex = -1;\n\n @HostListener('click', ['$event']) onHostClick(evt: MouseEvent) {\n if (!this.disabled && this.onClick) {\n this.#elRef.nativeElement.parentElement.focus();\n this.onClick(evt);\n }\n }\n\n setActiveStyles(): void {\n this.activeInput.set(true);\n this.#scrollIntoView();\n }\n\n setInactiveStyles(): void {\n this.activeInput.set(false);\n }\n\n focusNext() {\n \n }\n\n focusPrevious() {\n }\n\n #scrollIntoView() {\n const el = this.#elRef.nativeElement as HTMLElement;\n const { bottom, top, left, right } = el.getBoundingClientRect();\n const containerRect = this.#elRef.nativeElement.parentElement.getBoundingClientRect();\n\n const offsetY =\n top <= containerRect.top\n ? containerRect.top - top > 0\n ? (containerRect.top - top) * -1\n : 0\n : bottom - containerRect.bottom > 0\n ? bottom - containerRect.bottom\n : 0;\n const offsetX =\n left <= containerRect.left\n ? containerRect.left - left > 0\n ? (containerRect.left - left) * -1\n : 0\n : right - containerRect.right > 0\n ? right - containerRect.right\n : 0;\n\n if (offsetX || offsetY) (this.#elRef.nativeElement.parentElement as HTMLElement).scrollBy(offsetX, offsetY);\n }\n\n ngAfterViewInit(): void {\n // get all focusable elements and set tabindex to -1\n this.focusableChildren = Utils.getFocusableChildren(this.#elRef.nativeElement);\n this.focusableChildren.forEach((el) => el.setAttribute('tabindex', '-1'));\n }\n}\n","import { A11yModule, ActiveDescendantKeyManager } from '@angular/cdk/a11y';\nimport { Directionality } from '@angular/cdk/bidi';\nimport { CommonModule } from '@angular/common';\nimport {\n Component,\n ElementRef,\n HostAttributeToken,\n HostListener,\n OnDestroy,\n ViewEncapsulation,\n contentChildren,\n effect,\n inject,\n input,\n output,\n untracked,\n AfterContentInit\n} from '@angular/core';\nimport { ListItemDirective } from './list-item.directive';\nimport { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\n\n/**\n * Component rendering a simple list of items. It supports keyboard\n * navigation and takes care of accessibility. To create a list just wrap\n * `yuvListItem` elements into this component:\n *\n * ```html\n * <yuv-list (itemSelect)=\"itemSelected($event)\">\n * <div yuvListItem>Entry #1</div>\n * <div yuvListItem>Entry #2</div>\n * </yuv-list>\n * ```\n */\n@Component({\n selector: 'yuv-list',\n standalone: true,\n imports: [CommonModule, A11yModule],\n template: '<ng-content></ng-content>',\n styleUrl: './list.component.scss',\n encapsulation: ViewEncapsulation.None,\n host: {\n role: 'listbox',\n tabindex: '0',\n '[class.self-handle-selection]': 'selfHandleSelection()'\n }\n})\nexport class ListComponent implements OnDestroy {\n #dir = inject(Directionality);\n #elRef = inject(ElementRef);\n\n @HostListener('keydown', ['$event']) onKeydown(event: KeyboardEvent) {\n if (this.disableSelection()) return;\n if (event.code === 'Escape') {\n this.clear();\n }\n\n if (event.code === 'Space' || (this.selectOnEnter && event.code === 'Enter')) {\n // prevent default behavior of space in scroll environments\n if (this.#preventEmit()) return;\n event.preventDefault();\n const aii: number = this.#keyManager.activeItemIndex !== null ? this.#keyManager.activeItemIndex : -1;\n if (aii >= 0) {\n this.#select(aii);\n this.#emitSelection();\n }\n } else this.#keyManager?.onKeydown(event);\n }\n\n @HostListener('focus') onFocus() {\n // set timeout to check if the focus is coming from an item being clicked\n setTimeout(() => {\n // if there already is an active item, we do not want to set the focus again\n if (this.#keyManager.activeItemIndex === -1 && this.items().length > 0) {\n const indexToFocus = this.#selection.length > 0 ? this.#selection[0] : 0;\n this.#keyManager.setActiveItem(indexToFocus);\n this.itemFocus.emit(indexToFocus);\n this.#updateActiveItemState();\n }\n }, 300);\n }\n\n items = contentChildren(ListItemDirective);\n #itemsEffect = effect(() => {\n const items = this.items();\n if (this.#keyManager) this.#keyManager.destroy();\n untracked(() => {\n this.#keyManager = this.horizontal\n ? new ActiveDescendantKeyManager(items).withWrap().withHorizontalOrientation(this.#dir.value)\n : new ActiveDescendantKeyManager(items).withWrap();\n\n this.#keyManager.change.subscribe((activeIndex) => {\n if (activeIndex !== null) {\n this.#updateActiveItemState();\n this.itemFocus.emit(activeIndex);\n }\n });\n\n if (!this.selfHandleClick()) {\n items.forEach((item, index) => {\n item.onClick = (evt: MouseEvent) => {\n this.select(index, evt.shiftKey, evt.ctrlKey);\n };\n item.activeInput.set(false);\n });\n }\n if (this.#lastSelection !== undefined && this.#lastSelection <= items.length) {\n this.select(this.#lastSelection);\n }\n this.#preselectItem();\n });\n });\n\n #keyManager!: ActiveDescendantKeyManager<ListItemDirective>;\n #selection: number[] = [];\n #lastSelection?: number;\n\n /**\n * Function that returns `true` if selection changes should be prevented.\n * This can be used to temporarily block selection changes, e.g. while\n * there is a pending change inside another component that refers to the\n * current selection.\n */\n preventChangeUntil = input<() => boolean>(() => false);\n /**\n * If `true`, multiple items can be selected at once.\n * @default false\n */\n multiselect = input<boolean>(false);\n /**\n * If `true`, the component will handle selection itself. This means that\n * the parent component will be responsible for styling the selected and\n * focused items. If `false`, the component will take care of visualizing\n * the selection and focus states.\n * @default false\n */\n selfHandleSelection = input<boolean>(false);\n /**\n * By default the list handles click events on its items to select them.\n * If this input is set to `true`, the parent component has to handle\n * click events itself and call the `select()` method accordingly.\n *\n * If you for example use the `ClickDoubleDirective` on the list items,\n * you have to set this input to `true` to prevent the list from\n * selecting items on single click.\n * @default false\n */\n selfHandleClick = input<boolean>(false);\n /**\n * If `true`, the list will select an item automatically on initialization.\n * First, list will search for an item item that has the \"selected\"-attribute\n * and is not disabled. If no such item exists, the first item will be selected.\n * @default false\n */\n autoSelect = input<boolean, BooleanInput>(false, { transform: (value: BooleanInput) => coerceBooleanProperty(value) });\n /**\n * Emits the selected items indices.\n */\n itemSelect = output<number[]>();\n /**\n * Emits the index of the item that has focus.\n * @type {output<number>}\n */\n itemFocus = output<number>();\n\n selectOnEnter: boolean = (inject(new HostAttributeToken('selectOnEnter'), { optional: true }) || 'false') === 'true';\n horizontal: boolean = (inject(new HostAttributeToken('horizontal'), { optional: true }) || 'false') === 'true';\n\n /**\n * If `true`, the list will not allow selection of items.\n * This is useful for lists that are used for display purposes only.\n */\n disableSelection = input<boolean>(false);\n\n focus() {\n this.#elRef.nativeElement.focus();\n }\n\n scrollToTop() {\n this.#elRef.nativeElement.scrollTo({ top: 0, behavior: 'smooth' });\n }\n\n /**\n * Shift the current selection by the given offset. Used for dynamically\n * adding items to the list without losing the current selection.\n * @param offset Number of items to shift the selection by. \n */\n shiftSelectionBy(offset: number): void {\n if (this.#keyManager?.activeItemIndex) this.#keyManager.setActiveItem(this.#keyManager.activeItemIndex + offset);\n this.#selection = this.#selection.map((i) => i + offset);\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n }\n\n /**\n * Select multiple items by their indices.\n */\n multiSelect(index: number[]): void {\n if (this.#preventEmit()) return;\n if (!this.multiselect() || this.disableSelection()) return;\n this.#selection = index.filter((i) => i >= 0 && i < this.items().length);\n this.#selection.sort();\n\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n this.#emitSelection();\n }\n\n /**\n * Selects a single item by its index.\n * @param index Index of the item to select.\n * @param shiftKey If `true`, selection will be extended from the last selected item to the given index.\n * @param ctrlKey If `true`, the item at the given index will be toggled in the selection.\n */\n select(index: number, shiftKey = false, ctrlKey = false) {\n if (this.#preventEmit()) return;\n if (this.disableSelection() || index < 0) return;\n if (index >= this.items().length) index = this.items().length - 1;\n\n this.#select(index, shiftKey, ctrlKey);\n if (this.#keyManager) this.#keyManager.setActiveItem(index);\n this.#emitSelection();\n }\n\n #preventEmit() {\n const preventUntilIsTrue = this.preventChangeUntil();\n return preventUntilIsTrue();\n }\n\n /**\n * Clear the current selection.\n * @param silent If `true`, the `itemSelect` event will not be emitted.\n */\n clear(silent = false) {\n if (this.#preventEmit()) return;\n if (this.#selection.length !== 0) {\n this.#select(-1);\n this.#keyManager.setActiveItem(-1);\n if (!silent) this.#emitSelection();\n }\n }\n\n #select(index: number, shiftKey = false, ctrlKey = false) {\n if (index === -1) this.#selection = [];\n else {\n if (this.multiselect()) {\n this.#selection = this.#selection.filter((i) => i !== index);\n if (ctrlKey) {\n this.#selection.push(index);\n } else if (shiftKey) {\n if (this.#lastSelection) {\n for (let i = this.#lastSelection < index ? this.#lastSelection : index; i < (this.#lastSelection > index ? this.#lastSelection : index); i++) {\n this.#selection.push(i);\n }\n } else {\n this.#selection = [index];\n }\n } else {\n this.#selection = [index];\n }\n } else this.#selection = [index];\n }\n this.#lastSelection = this.#selection.length === 0 ? undefined : index;\n this.#selection.sort();\n\n this.items().forEach((item: ListItemDirective, i: number) => item.selectedInput.set(this.#selection.includes(i)));\n }\n\n #updateActiveItemState() {\n const activeIndex = this.#keyManager.activeItemIndex;\n this.items().forEach((item: ListItemDirective, i: number) => {\n item.activeInput.set(i === activeIndex);\n });\n }\n\n #emitSelection() {\n this.itemSelect.emit(this.#selection);\n }\n\n #preselectItem() {\n const items = this.items();\n const autoSelect = this.autoSelect();\n let itemIndexToSelect = -1;\n\n // If the list has no items, do nothing.\n if (items.length < 1) return;\n\n // Find the first item that has the \"selected\"-attribute and is not disabled\n itemIndexToSelect = items.findIndex((item) => item.selected() && !item.disabled);\n\n // If no valid item index is given, but autoSelect is true, select the first item\n if (itemIndexToSelect === -1 && autoSelect) {\n itemIndexToSelect = 0;\n }\n\n // If there is a valid item index, select that item, otherwise do nothing\n if (itemIndexToSelect !== -1) {\n this.select(itemIndexToSelect);\n }\n }\n\n ngOnDestroy(): void {\n this.#keyManager?.destroy();\n }\n}\n","import { Component, contentChild, TemplateRef, viewChild } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ListItemDirective } from '../list-item.directive';\n\n@Component({\n selector: 'yuv-list-tile',\n imports: [CommonModule],\n templateUrl: './list-tile.component.html',\n styleUrl: './list-tile.component.scss',\n // hostDirectives: [ListItemDirective]\n})\nexport class ListTileComponent {\n iconSlot = contentChild<TemplateRef<any>>('iconSlot', {\n descendants: true\n });\n titleSlot = contentChild<TemplateRef<any>>('titleSlot');\n descriptionSlot = contentChild<TemplateRef<any>>('descriptionSlot');\n asideSlot = contentChild<TemplateRef<any>>('asideSlot');\n actionsSlot = contentChild<TemplateRef<any>>('actionsSlot', {\n descendants: true\n });\n badgesSlot = contentChild<TemplateRef<any>>('badgesSlot');\n metaSlot = contentChild<TemplateRef<any>>('metaSlot');\n extensionSlot = contentChild<TemplateRef<any>>('extensionSlot');\n}\n","<ng-content></ng-content>\n<div class=\"tile\">\n <div data-slot=\"icon\">\n <ng-container *ngTemplateOutlet=\"iconSlot() || null\"></ng-container>\n </div>\n <div class=\"slots\"> \n <div data-slot=\"title-description\">\n <div data-slot=\"title\">\n <ng-container *ngTemplateOutlet=\"titleSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"description\">\n <ng-container *ngTemplateOutlet=\"descriptionSlot() || null\"></ng-container>\n </div>\n </div>\n <div data-slot=\"actions\">\n <ng-container *ngTemplateOutlet=\"actionsSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"aside\">\n <ng-container *ngTemplateOutlet=\"asideSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"meta\">\n <ng-container *ngTemplateOutlet=\"metaSlot() || null\"></ng-container>\n </div>\n <div data-slot=\"badges\">\n <ng-container *ngTemplateOutlet=\"badgesSlot() || null\"></ng-container>\n </div>\n <div class=\"extension\">\n <ng-container *ngTemplateOutlet=\"extensionSlot() || null\"></ng-container>\n </div>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { ListItemDirective } from './list-item.directive';\nimport { ListComponent } from './list.component';\nimport { ListTileComponent } from './list-tile/list-tile.component';\n\n@NgModule({\n imports: [ListComponent, ListItemDirective, ListTileComponent],\n exports: [ListComponent, ListItemDirective, ListTileComponent]\n})\nexport class YuvListModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAIA;;;;;;;;;;;AAWG;MASU,iBAAiB,CAAA;AAR9B,IAAA,WAAA,GAAA;AASE,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,UAAU,CAAC;AAO3B;;AAEG;AACH,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK,CAAU,KAAK,CAAC;AAC9B;;AAEG;AACH,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAU,KAAK,CAAC;QAEhC,IAAa,CAAA,aAAA,GAAG,YAAY,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,QAAQ;YACrB,WAAW,EAAE,CAAC,UAAe,EAAE,QAAa,MAAM,UAAU,KAAK,QAAQ,GAAG,UAAU,GAAG,QAAQ;AAClG,SAAA,CAAC;QAEF,IAAW,CAAA,WAAA,GAAG,YAAY,CAAC;YACzB,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,WAAW,EAAE,CAAC,UAAe,EAAE,QAAa,MAAM,UAAU,KAAK,QAAQ,GAAG,UAAU,GAAG,QAAQ;AAClG,SAAA,CAAC;QAEF,IAAiB,CAAA,iBAAA,GAAc,EAAE;QACjC,IAAY,CAAA,YAAA,GAAG,CAAC,CAAC;AAuDlB;AAlFC,IAAA,MAAM;AA6B6B,IAAA,WAAW,CAAC,GAAe,EAAA;QAC5D,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,OAAO,EAAE;YAClC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,aAAa,CAAC,KAAK,EAAE;AAC/C,YAAA,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC;;;IAIrB,eAAe,GAAA;AACb,QAAA,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,IAA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iBAAiB,CAAA,EAAA,CAAA,CAAA;gHAElD,aAAa,EAAA,OAAA,EAAA,CAHd,aAAa,EAAqB,iBAAiB,CAAA,EAAA,CAAA,CAAA;;4FAGlD,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;AAC9D,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,iBAAiB,EAAE,iBAAiB;AAC9D,iBAAA;;;ACRD;;AAEG;;;;"}
@@ -372,13 +372,13 @@ class MetadataFormFieldComponent {
372
372
  #system;
373
373
  #ngControl;
374
374
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: MetadataFormFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
375
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", 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-warning-container);--label-color: var(--ymt-on-warning-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 }); }
375
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", 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 }); }
376
376
  }
377
377
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: MetadataFormFieldComponent, decorators: [{
378
378
  type: Component,
379
379
  args: [{ selector: 'yuv-metadata-form-field', standalone: true, imports: [NgClass, NgTemplateOutlet, MatFormFieldModule], hostDirectives: [NoopValueAccessorDirective], encapsulation: ViewEncapsulation.None, host: {
380
380
  class: 'yuv-metadata-form-field'
381
- }, 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-warning-container);--label-color: var(--ymt-on-warning-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"] }]
381
+ }, 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"] }]
382
382
  }] });
383
383
 
384
384
  /**
@@ -1,8 +1,8 @@
1
1
  import * as i0 from '@angular/core';
2
- import { inject, input, computed, Component, signal, Injectable, effect, viewChildren, linkedSignal, output, Input, untracked, NgModule, Pipe } from '@angular/core';
2
+ import { inject, input, computed, Component, signal, Injectable, effect, viewChild, linkedSignal, output, viewChildren, Input, untracked, NgModule, Pipe } from '@angular/core';
3
3
  import * as i2 from '@angular/common';
4
4
  import { CommonModule } from '@angular/common';
5
- import { takeUntilDestroyed, rxResource, toSignal } from '@angular/core/rxjs-interop';
5
+ import { takeUntilDestroyed, toSignal, rxResource } from '@angular/core/rxjs-interop';
6
6
  import * as i3 from '@angular/material/icon';
7
7
  import { MatIconModule } from '@angular/material/icon';
8
8
  import * as i1$1 from '@yuuvis/client-core';
@@ -12,7 +12,7 @@ import * as i1 from '@yuuvis/material/panes';
12
12
  import { YmtPanesModule } from '@yuuvis/material/panes';
13
13
  import { MatTooltipModule } from '@angular/material/tooltip';
14
14
  import { BusyOverlayDirective, RetentionBadgeComponent } from '@yuuvis/client-framework/common';
15
- import { finalize, catchError, of, map } from 'rxjs';
15
+ import { finalize, of, map } from 'rxjs';
16
16
  import * as i2$2 from '@angular/material/tabs';
17
17
  import { MatTabsModule } from '@angular/material/tabs';
18
18
  import { ObjectPreviewComponent } from '@yuuvis/client-framework/object-preview';
@@ -352,42 +352,53 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
352
352
  class ObjectMetadataSectionComponent {
353
353
  constructor() {
354
354
  this.#system = inject(SystemService);
355
- this.objectForms = viewChildren(ObjectFormComponent);
356
- this._formOptions = signal(undefined);
355
+ this.objectForm = viewChild(ObjectFormComponent);
357
356
  this.section = input.required();
358
357
  this.expandedInput = input(false, { alias: 'expanded' });
359
358
  this.elementExtensions = input([]);
360
359
  this.readonly = input();
361
360
  this.expanded = linkedSignal(this.expandedInput);
362
- this.#formOptionsResource = rxResource({
363
- request: () => ({ section: this.section(), extended: this.expanded() }),
364
- loader: ({ request }) => {
365
- if (request.extended && request.section) {
366
- return this.#system.getObjectTypeForm(request.section.id, request.section.situation || Situation.EDIT).pipe(catchError(() => of(undefined)), map((formModel) => ({ formModel, data: request.section?.data || {} })));
367
- }
368
- else {
369
- return of(undefined);
370
- }
361
+ this.busy = signal(false);
362
+ this.formOptions = signal(undefined);
363
+ this.#formOptionsEffect = effect(() => {
364
+ // load object form on expand if not yet loaded.
365
+ // Don't use rxResource here because it messes with the state of the formOptions
366
+ const section = this.section();
367
+ const expanded = this.expanded();
368
+ if (!this.formOptions() && section && expanded) {
369
+ this.busy.set(true);
370
+ this.#system.getObjectTypeForm(section.id, section.situation || Situation.EDIT).subscribe({
371
+ next: (formModel) => {
372
+ this.formOptions.set({ formModel, data: section?.data || {} });
373
+ this.busy.set(false);
374
+ },
375
+ error: (e) => {
376
+ console.error('Error loading form options', e);
377
+ this.formOptions.set(undefined);
378
+ this.busy.set(false);
379
+ }
380
+ });
371
381
  }
372
382
  });
373
- this.formOptions = this.#formOptionsResource.value;
374
- this.busy = this.#formOptionsResource.isLoading;
375
383
  this.statusChanged = output();
376
384
  }
377
385
  #system;
378
- #formOptionsResource;
386
+ #formOptionsEffect;
379
387
  resetForm() {
380
- this.objectForms()?.forEach((f) => f.resetForm());
388
+ this.objectForm()?.resetForm();
381
389
  }
382
390
  setFormPristine() {
383
- this.objectForms()?.forEach((f) => f.setFormPristine());
391
+ this.objectForm()?.setFormPristine();
384
392
  }
385
393
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ObjectMetadataSectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
386
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ObjectMetadataSectionComponent, isStandalone: true, selector: "yuv-object-metadata-section", inputs: { section: { classPropertyName: "section", publicName: "section", isSignal: true, isRequired: true, transformFunction: null }, expandedInput: { classPropertyName: "expandedInput", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, elementExtensions: { classPropertyName: "elementExtensions", publicName: "elementExtensions", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { statusChanged: "statusChanged" }, viewQueries: [{ propertyName: "objectForms", predicate: ObjectFormComponent, descendants: true, isSignal: true }], ngImport: i0, template: "@let _section = section();\n@let fo = formOptions();\n\n<h3>\n <button\n type=\"button\"\n [attr.aria-expanded]=\"expanded()\"\n class=\"accordion-trigger\"\n [attr.aria-controls]=\"'sect_' + _section.id\"\n [id]=\"'accordion_' + _section.id\"\n (click)=\"expanded.set(!expanded())\"\n [attr.aria-busy]=\"busy()\"\n >\n @if (_section.icon) {\n @if (_section.svgIcon) {\n <mat-icon [svgIcon]=\"_section.icon\"></mat-icon>\n } @else {\n <mat-icon>{{ _section.icon }}</mat-icon>\n }\n }\n <span>{{ _section.label }}</span>\n @if (busy()) {\n <mat-spinner diameter=\"24\"></mat-spinner>\n }\n <mat-icon class=\"arr\">keyboard_arrow_down</mat-icon>\n </button>\n</h3>\n<div [id]=\"'sect_' + _section.id\" role=\"region\" [attr.aria-labelledby]=\"'accordion_' + _section.id\" class=\"accordion-panel\">\n @if (fo && expanded()) {\n <yuv-object-form [readonly]=\"readonly()\" [formOptions]=\"fo\" [elementExtensions]=\"elementExtensions()\" (statusChanged)=\"statusChanged.emit($event)\"></yuv-object-form>\n }\n</div>\n", styles: [":host{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host h3{margin:0;padding:0;display:flex}:host h3 button{margin:var(--ymt-spacing-2xs);border-radius:calc(var(--_object-metadata-section-corner) * .5);flex:1;padding:var(--ymt-spacing-xs);cursor:pointer;display:flex;gap:var(--ymt-spacing-xs);align-items:center;font-weight:700;color:var(--ymt-text-color-subtle);background-color:transparent;border:none}:host h3 button:hover{background-color:var(--ymt-hover-background)}:host h3 button:focus-visible{background-color:var(--ymt-hover-background);outline:2px solid var(--ymt-outline);outline-offset:-2px}:host h3 button[aria-expanded=true] mat-icon.arr{transform:rotate(180deg)}:host h3 button span{flex:1;text-align:start}:host h3 button mat-icon{margin-inline-end:var(--ymt-spacing-xs);transition:transform .3s ease}:host details{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host details:not(:last-child){margin-block-end:var(--ymt-spacing-m)}:host details[open] yuv-icon.arr{transform:rotate(180deg)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i2$1.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "component", type: ObjectFormComponent, selector: "yuv-object-form", inputs: ["formOptions", "inert", "readonly", "elementExtensions", "isInnerTableForm"], outputs: ["statusChanged", "onFormReady"] }] }); }
394
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ObjectMetadataSectionComponent, isStandalone: true, selector: "yuv-object-metadata-section", inputs: { section: { classPropertyName: "section", publicName: "section", isSignal: true, isRequired: true, transformFunction: null }, expandedInput: { classPropertyName: "expandedInput", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, elementExtensions: { classPropertyName: "elementExtensions", publicName: "elementExtensions", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { statusChanged: "statusChanged" }, host: { properties: { "class.invalid": "objectForm()?.form?.invalid", "class.dirty": "objectForm()?.form?.dirty" } }, viewQueries: [{ propertyName: "objectForm", first: true, predicate: ObjectFormComponent, descendants: true, isSignal: true }], ngImport: i0, template: "@let _section = section();\n@let fo = formOptions();\n\n<h3>\n <button\n type=\"button\"\n [attr.aria-expanded]=\"expanded()\"\n class=\"accordion-trigger\"\n [attr.aria-controls]=\"'sect_' + _section.id\"\n [id]=\"'accordion_' + _section.id\"\n (click)=\"expanded.set(!expanded())\"\n [attr.aria-busy]=\"busy()\"\n >\n @if (_section.icon) {\n @if (_section.svgIcon) {\n <mat-icon [svgIcon]=\"_section.icon\"></mat-icon>\n } @else {\n <mat-icon>{{ _section.icon }}</mat-icon>\n }\n }\n <span >{{ _section.label }}</span>\n @if (busy()) {\n <mat-spinner diameter=\"24\"></mat-spinner>\n }\n <mat-icon class=\"arr\">keyboard_arrow_down</mat-icon>\n </button>\n</h3>\n<div [id]=\"'sect_' + _section.id\" role=\"region\" [attr.aria-labelledby]=\"'accordion_' + _section.id\" class=\"accordion-panel\">\n @if (fo) {\n <yuv-object-form\n #objectForm\n [hidden]=\"!expanded()\"\n [readonly]=\"readonly()\"\n [formOptions]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"statusChanged.emit($event)\"\n ></yuv-object-form>\n }\n</div>\n", styles: [":host{--section-state-border-color: var(--ymt-outline-variant);--section-state-outline-color: transparent;background-color:var(--_object-metadata-section-background);border:1px solid var(--section-state-border-color);border-radius:var(--_object-metadata-section-corner);outline:3px solid var(--section-state-outline-color)}:host.invalid{--section-state-border-color: var(--ymt-danger);--section-state-outline-color: rgb(from var(--ymt-danger) r g b /.2)}:host.dirty:not(.invalid){--section-state-border-color: var(--ymt-success);--section-state-outline-color: rgb(from var(--ymt-success) r g b /.2)}:host h3{margin:0;padding:0;display:flex}:host h3 button{margin:var(--ymt-spacing-2xs);border-radius:calc(var(--_object-metadata-section-corner) * .5);flex:1;padding:var(--ymt-spacing-xs);cursor:pointer;display:flex;gap:var(--ymt-spacing-xs);align-items:center;font-weight:700;color:var(--ymt-text-color-subtle);background-color:transparent;border:none}:host h3 button:hover{background-color:var(--ymt-hover-background)}:host h3 button:focus-visible{background-color:var(--ymt-hover-background);outline:2px solid var(--ymt-outline);outline-offset:-2px}:host h3 button[aria-expanded=true] mat-icon.arr{transform:rotate(180deg)}:host h3 button span{flex:1;text-align:start}:host h3 button mat-icon{margin-inline-end:var(--ymt-spacing-xs);transition:transform .3s ease}:host details{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host details:not(:last-child){margin-block-end:var(--ymt-spacing-m)}:host details[open] yuv-icon.arr{transform:rotate(180deg)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i2$1.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "component", type: ObjectFormComponent, selector: "yuv-object-form", inputs: ["formOptions", "inert", "readonly", "elementExtensions", "isInnerTableForm"], outputs: ["statusChanged", "onFormReady"] }] }); }
387
395
  }
388
396
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ObjectMetadataSectionComponent, decorators: [{
389
397
  type: Component,
390
- args: [{ selector: 'yuv-object-metadata-section', imports: [CommonModule, MatIconModule, MatProgressSpinnerModule, ObjectFormComponent], template: "@let _section = section();\n@let fo = formOptions();\n\n<h3>\n <button\n type=\"button\"\n [attr.aria-expanded]=\"expanded()\"\n class=\"accordion-trigger\"\n [attr.aria-controls]=\"'sect_' + _section.id\"\n [id]=\"'accordion_' + _section.id\"\n (click)=\"expanded.set(!expanded())\"\n [attr.aria-busy]=\"busy()\"\n >\n @if (_section.icon) {\n @if (_section.svgIcon) {\n <mat-icon [svgIcon]=\"_section.icon\"></mat-icon>\n } @else {\n <mat-icon>{{ _section.icon }}</mat-icon>\n }\n }\n <span>{{ _section.label }}</span>\n @if (busy()) {\n <mat-spinner diameter=\"24\"></mat-spinner>\n }\n <mat-icon class=\"arr\">keyboard_arrow_down</mat-icon>\n </button>\n</h3>\n<div [id]=\"'sect_' + _section.id\" role=\"region\" [attr.aria-labelledby]=\"'accordion_' + _section.id\" class=\"accordion-panel\">\n @if (fo && expanded()) {\n <yuv-object-form [readonly]=\"readonly()\" [formOptions]=\"fo\" [elementExtensions]=\"elementExtensions()\" (statusChanged)=\"statusChanged.emit($event)\"></yuv-object-form>\n }\n</div>\n", styles: [":host{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host h3{margin:0;padding:0;display:flex}:host h3 button{margin:var(--ymt-spacing-2xs);border-radius:calc(var(--_object-metadata-section-corner) * .5);flex:1;padding:var(--ymt-spacing-xs);cursor:pointer;display:flex;gap:var(--ymt-spacing-xs);align-items:center;font-weight:700;color:var(--ymt-text-color-subtle);background-color:transparent;border:none}:host h3 button:hover{background-color:var(--ymt-hover-background)}:host h3 button:focus-visible{background-color:var(--ymt-hover-background);outline:2px solid var(--ymt-outline);outline-offset:-2px}:host h3 button[aria-expanded=true] mat-icon.arr{transform:rotate(180deg)}:host h3 button span{flex:1;text-align:start}:host h3 button mat-icon{margin-inline-end:var(--ymt-spacing-xs);transition:transform .3s ease}:host details{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host details:not(:last-child){margin-block-end:var(--ymt-spacing-m)}:host details[open] yuv-icon.arr{transform:rotate(180deg)}\n"] }]
398
+ args: [{ selector: 'yuv-object-metadata-section', imports: [CommonModule, MatIconModule, MatProgressSpinnerModule, ObjectFormComponent], host: {
399
+ '[class.invalid]': 'objectForm()?.form?.invalid',
400
+ '[class.dirty]': 'objectForm()?.form?.dirty'
401
+ }, template: "@let _section = section();\n@let fo = formOptions();\n\n<h3>\n <button\n type=\"button\"\n [attr.aria-expanded]=\"expanded()\"\n class=\"accordion-trigger\"\n [attr.aria-controls]=\"'sect_' + _section.id\"\n [id]=\"'accordion_' + _section.id\"\n (click)=\"expanded.set(!expanded())\"\n [attr.aria-busy]=\"busy()\"\n >\n @if (_section.icon) {\n @if (_section.svgIcon) {\n <mat-icon [svgIcon]=\"_section.icon\"></mat-icon>\n } @else {\n <mat-icon>{{ _section.icon }}</mat-icon>\n }\n }\n <span >{{ _section.label }}</span>\n @if (busy()) {\n <mat-spinner diameter=\"24\"></mat-spinner>\n }\n <mat-icon class=\"arr\">keyboard_arrow_down</mat-icon>\n </button>\n</h3>\n<div [id]=\"'sect_' + _section.id\" role=\"region\" [attr.aria-labelledby]=\"'accordion_' + _section.id\" class=\"accordion-panel\">\n @if (fo) {\n <yuv-object-form\n #objectForm\n [hidden]=\"!expanded()\"\n [readonly]=\"readonly()\"\n [formOptions]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"statusChanged.emit($event)\"\n ></yuv-object-form>\n }\n</div>\n", styles: [":host{--section-state-border-color: var(--ymt-outline-variant);--section-state-outline-color: transparent;background-color:var(--_object-metadata-section-background);border:1px solid var(--section-state-border-color);border-radius:var(--_object-metadata-section-corner);outline:3px solid var(--section-state-outline-color)}:host.invalid{--section-state-border-color: var(--ymt-danger);--section-state-outline-color: rgb(from var(--ymt-danger) r g b /.2)}:host.dirty:not(.invalid){--section-state-border-color: var(--ymt-success);--section-state-outline-color: rgb(from var(--ymt-success) r g b /.2)}:host h3{margin:0;padding:0;display:flex}:host h3 button{margin:var(--ymt-spacing-2xs);border-radius:calc(var(--_object-metadata-section-corner) * .5);flex:1;padding:var(--ymt-spacing-xs);cursor:pointer;display:flex;gap:var(--ymt-spacing-xs);align-items:center;font-weight:700;color:var(--ymt-text-color-subtle);background-color:transparent;border:none}:host h3 button:hover{background-color:var(--ymt-hover-background)}:host h3 button:focus-visible{background-color:var(--ymt-hover-background);outline:2px solid var(--ymt-outline);outline-offset:-2px}:host h3 button[aria-expanded=true] mat-icon.arr{transform:rotate(180deg)}:host h3 button span{flex:1;text-align:start}:host h3 button mat-icon{margin-inline-end:var(--ymt-spacing-xs);transition:transform .3s ease}:host details{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner)}:host details:not(:last-child){margin-block-end:var(--ymt-spacing-m)}:host details[open] yuv-icon.arr{transform:rotate(180deg)}\n"] }]
391
402
  }] });
392
403
 
393
404
  class ObjectMetadataComponent {
@@ -401,13 +412,13 @@ class ObjectMetadataComponent {
401
412
  this.user = toSignal(this.#userService.user$);
402
413
  this.hasWritePermission = computed(() => {
403
414
  const flavoredDmsObject = this.flavoredDmsObject();
404
- const object = this.dmsObject();
415
+ const object = this._dmsObject();
405
416
  const o = flavoredDmsObject ? flavoredDmsObject.object : object;
406
417
  return o?.permissions?.writeIndexData || false;
407
418
  });
408
419
  this.objectForms = viewChildren(ObjectFormComponent);
409
420
  this.objectMetadataSectionForms = viewChildren(ObjectMetadataSectionComponent);
410
- this._dmsObject = undefined;
421
+ this._dmsObject = signal(undefined);
411
422
  this.#formSubscriptions = [];
412
423
  this.busySaving = signal(false);
413
424
  this.busyLoading = signal(false);
@@ -435,7 +446,7 @@ class ObjectMetadataComponent {
435
446
  this.dmsObject = input();
436
447
  this.#dmsObjectEffect = effect(() => {
437
448
  const object = this.dmsObject();
438
- this._dmsObject = object;
449
+ this._dmsObject.set(object);
439
450
  });
440
451
  /**
441
452
  * @deprecated This input will be removed in the future.
@@ -455,7 +466,7 @@ class ObjectMetadataComponent {
455
466
  */
456
467
  this.statusChanged = output();
457
468
  this.#mainFormOptionsRecource = rxResource({
458
- request: this.dmsObject,
469
+ request: this._dmsObject,
459
470
  loader: ({ request }) => {
460
471
  if (!request)
461
472
  return of(undefined);
@@ -474,7 +485,7 @@ class ObjectMetadataComponent {
474
485
  this.flavors = input(undefined);
475
486
  // forms off allpied flavors
476
487
  this.flavorFormOptions = linkedSignal({
477
- source: () => ({ object: this.dmsObject(), flavors: this.flavors() }),
488
+ source: () => ({ object: this._dmsObject(), flavors: this.flavors() }),
478
489
  computation: ({ object, flavors }) => {
479
490
  const mappedFlavors = (flavors || []).reduce((acc, curr) => ({ ...acc, [curr.sot]: curr }), {});
480
491
  if (!object)
@@ -508,11 +519,12 @@ class ObjectMetadataComponent {
508
519
  *
509
520
  */
510
521
  #init(object, flavors) {
511
- if (object && (!this._dmsObject || this._dmsObject !== object)) {
522
+ const o = this._dmsObject();
523
+ if (object && (!o || o !== object)) {
512
524
  this.#objectToForm(object, flavors);
513
525
  }
514
526
  if (object)
515
- this._dmsObject = object;
527
+ this._dmsObject.set(object);
516
528
  }
517
529
  #mainFormOptionsRecource;
518
530
  /**
@@ -532,10 +544,6 @@ class ObjectMetadataComponent {
532
544
  icon: mappedFlavors[id]?.icon,
533
545
  svgIcon: mappedFlavors[id]?.svgIcon,
534
546
  data: object.data
535
- // formOptions: {
536
- // formModel: res[id],
537
- // data: object.data
538
- // }
539
547
  })));
540
548
  this.#system.getObjectTypeForms([object.objectTypeId], this.situation()).subscribe({
541
549
  next: (res) => {
@@ -546,21 +554,6 @@ class ObjectMetadataComponent {
546
554
  disabled: this.formDisabled || !object.permissions?.writeIndexData
547
555
  }
548
556
  : undefined);
549
- // this.flavorFormOptions.set(
550
- // Object.keys(res)
551
- // .filter((id) => id !== object.objectTypeId)
552
- // .map((id) => ({
553
- // id,
554
- // label: res[id].label,
555
- // icon: mappedFlavors[id]?.icon,
556
- // svgIcon: mappedFlavors[id]?.svgIcon,
557
- // data: object.data,
558
- // // formOptions: {
559
- // // formModel: res[id],
560
- // // data: object.data
561
- // // }
562
- // }))
563
- // );
564
557
  this.busyLoading.set(false);
565
558
  },
566
559
  error: () => {
@@ -604,13 +597,14 @@ class ObjectMetadataComponent {
604
597
  }
605
598
  save() {
606
599
  // TODO: this._dmsObject should be this.dmsObject() once this.#init() is removed
607
- const object = this._dmsObject;
600
+ const object = this._dmsObject();
608
601
  if (object && this.combinedFormState) {
609
602
  this.busySaving.set(true);
610
603
  this.#dmsService.updateDmsObject(object.id, this.combinedFormState.data).subscribe({
611
- next: () => {
604
+ next: (updatedObject) => {
605
+ this._dmsObject.set(updatedObject);
612
606
  this.setFormPristine();
613
- this.indexDataSaved.emit(object);
607
+ this.indexDataSaved.emit(updatedObject);
614
608
  this.#finishPending();
615
609
  this.controlsVisible.set(false);
616
610
  this.busySaving.set(false);
@@ -637,6 +631,11 @@ class ObjectMetadataComponent {
637
631
  }
638
632
  (this.objectForms()?.length || this.objectMetadataSectionForms()?.length) && this.#formStates.clear();
639
633
  }
634
+ updateFormValue(data) {
635
+ if (this.objectForms()?.length) {
636
+ this.objectForms().forEach((f) => f.setFormData(data));
637
+ }
638
+ }
640
639
  setFormPristine() {
641
640
  if (this.objectForms()?.length) {
642
641
  this.objectForms().forEach((f) => f.setFormPristine());
@@ -661,7 +660,7 @@ class ObjectMetadataComponent {
661
660
  this.#formSubscriptions.forEach((s) => s.unsubscribe());
662
661
  }
663
662
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ObjectMetadataComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
664
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ObjectMetadataComponent, isStandalone: true, selector: "yuv-object-metadata", inputs: { disableControls: { classPropertyName: "disableControls", publicName: "disableControls", isSignal: true, isRequired: false, transformFunction: null }, disableBasicMetadata: { classPropertyName: "disableBasicMetadata", publicName: "disableBasicMetadata", isSignal: true, isRequired: false, transformFunction: null }, elementExtensions: { classPropertyName: "elementExtensions", publicName: "elementExtensions", isSignal: true, isRequired: false, transformFunction: null }, situation: { classPropertyName: "situation", publicName: "situation", isSignal: true, isRequired: false, transformFunction: null }, formDisabled: { classPropertyName: "formDisabled", publicName: "formDisabled", isSignal: false, isRequired: false, transformFunction: null }, dmsObject: { classPropertyName: "dmsObject", publicName: "dmsObject", isSignal: true, isRequired: false, transformFunction: null }, flavoredDmsObject: { classPropertyName: "flavoredDmsObject", publicName: "flavoredDmsObject", isSignal: true, isRequired: false, transformFunction: null }, flavors: { classPropertyName: "flavors", publicName: "flavors", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { indexDataSaved: "indexDataSaved", statusChanged: "statusChanged" }, host: { properties: { "class.empty": "empty()", "class.loading": "busyLoading()" } }, viewQueries: [{ propertyName: "objectForms", predicate: ObjectFormComponent, descendants: true, isSignal: true }, { propertyName: "objectMetadataSectionForms", predicate: ObjectMetadataSectionComponent, descendants: true, isSignal: true }], ngImport: i0, template: "<main [yuvBusyOverlay]=\"busySaving() || busyLoading() || mainFormOptionsIsLoading()\">\n @if (empty()) {\n <p>{{ 'yuv.object-metadata.empty.message' | translate }}</p>\n }\n @if (!mainFormOptions()) {\n <yuv-object-form\n [readonly]=\"!hasWritePermission()\"\n [formOptions]=\"mainFormOptions()\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"onFormStatusChanged('main', $event)\"\n ></yuv-object-form>\n }\n @for (fo of flavorFormOptions(); track $index) {\n <yuv-object-metadata-section\n [readonly]=\"!hasWritePermission()\"\n [section]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n [expanded]=\"$index === 0\"\n (statusChanged)=\"onFormStatusChanged(fo.id, $event)\"\n ></yuv-object-metadata-section>\n }\n\n <!-- base data -->\n @let object = dmsObject() ?? _dmsObject;\n @if (object && !disableBasicMetadata()) {\n <yuv-object-summary-data [dmsObject]=\"object\"></yuv-object-summary-data>\n }\n</main>\n\n<footer [attr.inert]=\"disableControls() || !controlsVisible() || null\">\n <div class=\"container\">\n <button\n ymtButton=\"secondary\"\n button-size=\"small\"\n [disabled]=\"busySaving() || busyLoading()\"\n (click)=\"resetForm()\"\n [hidden]=\"!combinedFormState?.dirty\"\n [disabled]=\"!combinedFormState?.dirty\"\n >\n {{ 'yuv.object-metadata.button.reset' | translate }}\n </button>\n <button\n ymtButton=\"primary\"\n button-size=\"small\"\n (click)=\"save()\"\n [disabled]=\"!combinedFormState?.dirty || combinedFormState?.invalid || busySaving() || busyLoading()\"\n >\n {{ 'yuv.object-metadata.button.save' | translate }}\n </button>\n </div>\n</footer>\n", styles: [":host{--_object-metadata-panel-background: var(--object-metadata-panel-background, var(--ymt-surface-container-low));--_object-metadata-section-background: var(--object-metadata-section-background, var(--ymt-surface));--_object-metadata-section-corner: var(--object-metadata-section-corner, var(--ymt-corner-m));--_object-metadata-footer-background: var(--object-metadata-footer-background, var(--ymt-surface-container));--_object-metadata-footer-height: 4rem;display:grid;grid-template-rows:1fr auto;grid-template-columns:1fr;height:100%;overflow:hidden;position:relative;background-color:var(--_object-metadata-panel-background)}:host.empty main{justify-content:center;align-items:center}:host.loading main>*{opacity:0}:host main{grid-row:1/span 3;grid-column:1;overflow-y:auto;width:100%;display:flex;flex-flow:column;padding:var(--ymt-spacing-3xl) var(--ymt-spacing-l) var(--_object-metadata-footer-height) var(--ymt-spacing-l)}:host footer{grid-row:-1;grid-column:1;padding:var(--ymt-spacing-l);opacity:0;z-index:101}:host footer .container{background:var(--_object-metadata-footer-background);padding:var(--ymt-spacing-s);display:flex;align-items:center;justify-content:end;gap:var(--ymt-spacing-s);border-radius:var(--ymt-corner-full)}:host footer:not([inert]){animation:controlsAppear .2s ease-in-out forwards}:host main yuv-object-metadata-section{margin-block-end:var(--ymt-spacing-m)}:host main yuv-object-summary-data{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner);padding:var(--ymt-spacing-m)}@keyframes controlsAppear{0%{opacity:0;translate:0 var(--ymt-spacing-m)}to{opacity:1;translate:0 0}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ObjectFormComponent, selector: "yuv-object-form", inputs: ["formOptions", "inert", "readonly", "elementExtensions", "isInnerTableForm"], outputs: ["statusChanged", "onFormReady"] }, { kind: "component", type: ObjectSummaryDataComponent, selector: "yuv-object-summary-data", inputs: ["dmsObject", "flavors", "showAppliedFlavors"] }, { kind: "directive", type: BusyOverlayDirective, selector: "[yuvBusyOverlay]", inputs: ["yuvBusyOverlay", "yuvBusyOverlayConfig", "yuvBusyError"], outputs: ["yuvBusyErrorDismiss"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "component", type: ObjectMetadataSectionComponent, selector: "yuv-object-metadata-section", inputs: ["section", "expanded", "elementExtensions", "readonly"], outputs: ["statusChanged"] }, { kind: "directive", type: YmtButtonDirective, selector: "button[ymtButton], a[ymtButton]", inputs: ["ymtButton", "disabled", "aria-disabled", "disableRipple", "disabledInteractive", "button-size"] }] }); }
663
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ObjectMetadataComponent, isStandalone: true, selector: "yuv-object-metadata", inputs: { disableControls: { classPropertyName: "disableControls", publicName: "disableControls", isSignal: true, isRequired: false, transformFunction: null }, disableBasicMetadata: { classPropertyName: "disableBasicMetadata", publicName: "disableBasicMetadata", isSignal: true, isRequired: false, transformFunction: null }, elementExtensions: { classPropertyName: "elementExtensions", publicName: "elementExtensions", isSignal: true, isRequired: false, transformFunction: null }, situation: { classPropertyName: "situation", publicName: "situation", isSignal: true, isRequired: false, transformFunction: null }, formDisabled: { classPropertyName: "formDisabled", publicName: "formDisabled", isSignal: false, isRequired: false, transformFunction: null }, dmsObject: { classPropertyName: "dmsObject", publicName: "dmsObject", isSignal: true, isRequired: false, transformFunction: null }, flavoredDmsObject: { classPropertyName: "flavoredDmsObject", publicName: "flavoredDmsObject", isSignal: true, isRequired: false, transformFunction: null }, flavors: { classPropertyName: "flavors", publicName: "flavors", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { indexDataSaved: "indexDataSaved", statusChanged: "statusChanged" }, host: { properties: { "class.empty": "empty()", "class.loading": "busyLoading()" } }, viewQueries: [{ propertyName: "objectForms", predicate: ObjectFormComponent, descendants: true, isSignal: true }, { propertyName: "objectMetadataSectionForms", predicate: ObjectMetadataSectionComponent, descendants: true, isSignal: true }], ngImport: i0, template: "<main [yuvBusyOverlay]=\"busySaving() || busyLoading() || mainFormOptionsIsLoading()\">\n @if (empty()) {\n <p>{{ 'yuv.object-metadata.empty.message' | translate }}</p>\n }\n @if (!mainFormOptions()) {\n <yuv-object-form\n [readonly]=\"!hasWritePermission()\"\n [formOptions]=\"mainFormOptions()\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"onFormStatusChanged('main', $event)\"\n ></yuv-object-form>\n }\n @for (fo of flavorFormOptions(); track $index) {\n <yuv-object-metadata-section\n [readonly]=\"!hasWritePermission()\"\n [section]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n [expanded]=\"$index === 0\"\n (statusChanged)=\"onFormStatusChanged(fo.id, $event)\"\n ></yuv-object-metadata-section>\n }\n\n <!-- base data -->\n @let object = dmsObject() ?? _dmsObject();\n @if (object && !disableBasicMetadata()) {\n <yuv-object-summary-data [dmsObject]=\"object\"></yuv-object-summary-data>\n }\n</main>\n\n<footer [attr.inert]=\"disableControls() || !controlsVisible() || null\">\n <div class=\"container\">\n <button\n ymtButton=\"secondary\"\n button-size=\"small\"\n [disabled]=\"busySaving() || busyLoading()\"\n (click)=\"resetForm()\"\n [hidden]=\"!combinedFormState?.dirty\"\n [disabled]=\"!combinedFormState?.dirty\"\n >\n {{ 'yuv.object-metadata.button.reset' | translate }}\n </button>\n <button\n ymtButton=\"primary\"\n button-size=\"small\"\n (click)=\"save()\"\n [disabled]=\"!combinedFormState?.dirty || combinedFormState?.invalid || busySaving() || busyLoading()\"\n >\n {{ 'yuv.object-metadata.button.save' | translate }}\n </button>\n </div>\n</footer>\n", styles: [":host{--_object-metadata-panel-background: var(--object-metadata-panel-background, var(--ymt-surface-container-low));--_object-metadata-section-background: var(--object-metadata-section-background, var(--ymt-surface));--_object-metadata-section-corner: var(--object-metadata-section-corner, var(--ymt-corner-m));--_object-metadata-footer-background: var(--object-metadata-footer-background, var(--ymt-surface-container));--_object-metadata-footer-height: 4rem;display:grid;grid-template-rows:1fr auto;grid-template-columns:1fr;height:100%;overflow:hidden;position:relative;background-color:var(--_object-metadata-panel-background)}:host.empty main{justify-content:center;align-items:center}:host.loading main>*{opacity:0}:host main{grid-row:1/span 3;grid-column:1;overflow-y:auto;width:100%;display:flex;flex-flow:column;padding:var(--ymt-spacing-3xl) var(--ymt-spacing-l) var(--_object-metadata-footer-height) var(--ymt-spacing-l)}:host footer{grid-row:-1;grid-column:1;padding:var(--ymt-spacing-l);opacity:0;z-index:101}:host footer .container{background:var(--_object-metadata-footer-background);padding:var(--ymt-spacing-s);display:flex;align-items:center;justify-content:end;gap:var(--ymt-spacing-s);border-radius:var(--ymt-corner-full)}:host footer:not([inert]){animation:controlsAppear .2s ease-in-out forwards}:host main yuv-object-metadata-section{margin-block-end:var(--ymt-spacing-m)}:host main yuv-object-summary-data{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner);padding:var(--ymt-spacing-m)}@keyframes controlsAppear{0%{opacity:0;translate:0 var(--ymt-spacing-m)}to{opacity:1;translate:0 0}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ObjectFormComponent, selector: "yuv-object-form", inputs: ["formOptions", "inert", "readonly", "elementExtensions", "isInnerTableForm"], outputs: ["statusChanged", "onFormReady"] }, { kind: "component", type: ObjectSummaryDataComponent, selector: "yuv-object-summary-data", inputs: ["dmsObject", "flavors", "showAppliedFlavors"] }, { kind: "directive", type: BusyOverlayDirective, selector: "[yuvBusyOverlay]", inputs: ["yuvBusyOverlay", "yuvBusyOverlayConfig", "yuvBusyError"], outputs: ["yuvBusyErrorDismiss"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "component", type: ObjectMetadataSectionComponent, selector: "yuv-object-metadata-section", inputs: ["section", "expanded", "elementExtensions", "readonly"], outputs: ["statusChanged"] }, { kind: "directive", type: YmtButtonDirective, selector: "button[ymtButton], a[ymtButton]", inputs: ["ymtButton", "disabled", "aria-disabled", "disableRipple", "disabledInteractive", "button-size"] }] }); }
665
664
  }
666
665
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ObjectMetadataComponent, decorators: [{
667
666
  type: Component,
@@ -679,7 +678,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
679
678
  ], host: {
680
679
  '[class.empty]': 'empty()',
681
680
  '[class.loading]': 'busyLoading()'
682
- }, template: "<main [yuvBusyOverlay]=\"busySaving() || busyLoading() || mainFormOptionsIsLoading()\">\n @if (empty()) {\n <p>{{ 'yuv.object-metadata.empty.message' | translate }}</p>\n }\n @if (!mainFormOptions()) {\n <yuv-object-form\n [readonly]=\"!hasWritePermission()\"\n [formOptions]=\"mainFormOptions()\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"onFormStatusChanged('main', $event)\"\n ></yuv-object-form>\n }\n @for (fo of flavorFormOptions(); track $index) {\n <yuv-object-metadata-section\n [readonly]=\"!hasWritePermission()\"\n [section]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n [expanded]=\"$index === 0\"\n (statusChanged)=\"onFormStatusChanged(fo.id, $event)\"\n ></yuv-object-metadata-section>\n }\n\n <!-- base data -->\n @let object = dmsObject() ?? _dmsObject;\n @if (object && !disableBasicMetadata()) {\n <yuv-object-summary-data [dmsObject]=\"object\"></yuv-object-summary-data>\n }\n</main>\n\n<footer [attr.inert]=\"disableControls() || !controlsVisible() || null\">\n <div class=\"container\">\n <button\n ymtButton=\"secondary\"\n button-size=\"small\"\n [disabled]=\"busySaving() || busyLoading()\"\n (click)=\"resetForm()\"\n [hidden]=\"!combinedFormState?.dirty\"\n [disabled]=\"!combinedFormState?.dirty\"\n >\n {{ 'yuv.object-metadata.button.reset' | translate }}\n </button>\n <button\n ymtButton=\"primary\"\n button-size=\"small\"\n (click)=\"save()\"\n [disabled]=\"!combinedFormState?.dirty || combinedFormState?.invalid || busySaving() || busyLoading()\"\n >\n {{ 'yuv.object-metadata.button.save' | translate }}\n </button>\n </div>\n</footer>\n", styles: [":host{--_object-metadata-panel-background: var(--object-metadata-panel-background, var(--ymt-surface-container-low));--_object-metadata-section-background: var(--object-metadata-section-background, var(--ymt-surface));--_object-metadata-section-corner: var(--object-metadata-section-corner, var(--ymt-corner-m));--_object-metadata-footer-background: var(--object-metadata-footer-background, var(--ymt-surface-container));--_object-metadata-footer-height: 4rem;display:grid;grid-template-rows:1fr auto;grid-template-columns:1fr;height:100%;overflow:hidden;position:relative;background-color:var(--_object-metadata-panel-background)}:host.empty main{justify-content:center;align-items:center}:host.loading main>*{opacity:0}:host main{grid-row:1/span 3;grid-column:1;overflow-y:auto;width:100%;display:flex;flex-flow:column;padding:var(--ymt-spacing-3xl) var(--ymt-spacing-l) var(--_object-metadata-footer-height) var(--ymt-spacing-l)}:host footer{grid-row:-1;grid-column:1;padding:var(--ymt-spacing-l);opacity:0;z-index:101}:host footer .container{background:var(--_object-metadata-footer-background);padding:var(--ymt-spacing-s);display:flex;align-items:center;justify-content:end;gap:var(--ymt-spacing-s);border-radius:var(--ymt-corner-full)}:host footer:not([inert]){animation:controlsAppear .2s ease-in-out forwards}:host main yuv-object-metadata-section{margin-block-end:var(--ymt-spacing-m)}:host main yuv-object-summary-data{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner);padding:var(--ymt-spacing-m)}@keyframes controlsAppear{0%{opacity:0;translate:0 var(--ymt-spacing-m)}to{opacity:1;translate:0 0}}\n"] }]
681
+ }, template: "<main [yuvBusyOverlay]=\"busySaving() || busyLoading() || mainFormOptionsIsLoading()\">\n @if (empty()) {\n <p>{{ 'yuv.object-metadata.empty.message' | translate }}</p>\n }\n @if (!mainFormOptions()) {\n <yuv-object-form\n [readonly]=\"!hasWritePermission()\"\n [formOptions]=\"mainFormOptions()\"\n [elementExtensions]=\"elementExtensions()\"\n (statusChanged)=\"onFormStatusChanged('main', $event)\"\n ></yuv-object-form>\n }\n @for (fo of flavorFormOptions(); track $index) {\n <yuv-object-metadata-section\n [readonly]=\"!hasWritePermission()\"\n [section]=\"fo\"\n [elementExtensions]=\"elementExtensions()\"\n [expanded]=\"$index === 0\"\n (statusChanged)=\"onFormStatusChanged(fo.id, $event)\"\n ></yuv-object-metadata-section>\n }\n\n <!-- base data -->\n @let object = dmsObject() ?? _dmsObject();\n @if (object && !disableBasicMetadata()) {\n <yuv-object-summary-data [dmsObject]=\"object\"></yuv-object-summary-data>\n }\n</main>\n\n<footer [attr.inert]=\"disableControls() || !controlsVisible() || null\">\n <div class=\"container\">\n <button\n ymtButton=\"secondary\"\n button-size=\"small\"\n [disabled]=\"busySaving() || busyLoading()\"\n (click)=\"resetForm()\"\n [hidden]=\"!combinedFormState?.dirty\"\n [disabled]=\"!combinedFormState?.dirty\"\n >\n {{ 'yuv.object-metadata.button.reset' | translate }}\n </button>\n <button\n ymtButton=\"primary\"\n button-size=\"small\"\n (click)=\"save()\"\n [disabled]=\"!combinedFormState?.dirty || combinedFormState?.invalid || busySaving() || busyLoading()\"\n >\n {{ 'yuv.object-metadata.button.save' | translate }}\n </button>\n </div>\n</footer>\n", styles: [":host{--_object-metadata-panel-background: var(--object-metadata-panel-background, var(--ymt-surface-container-low));--_object-metadata-section-background: var(--object-metadata-section-background, var(--ymt-surface));--_object-metadata-section-corner: var(--object-metadata-section-corner, var(--ymt-corner-m));--_object-metadata-footer-background: var(--object-metadata-footer-background, var(--ymt-surface-container));--_object-metadata-footer-height: 4rem;display:grid;grid-template-rows:1fr auto;grid-template-columns:1fr;height:100%;overflow:hidden;position:relative;background-color:var(--_object-metadata-panel-background)}:host.empty main{justify-content:center;align-items:center}:host.loading main>*{opacity:0}:host main{grid-row:1/span 3;grid-column:1;overflow-y:auto;width:100%;display:flex;flex-flow:column;padding:var(--ymt-spacing-3xl) var(--ymt-spacing-l) var(--_object-metadata-footer-height) var(--ymt-spacing-l)}:host footer{grid-row:-1;grid-column:1;padding:var(--ymt-spacing-l);opacity:0;z-index:101}:host footer .container{background:var(--_object-metadata-footer-background);padding:var(--ymt-spacing-s);display:flex;align-items:center;justify-content:end;gap:var(--ymt-spacing-s);border-radius:var(--ymt-corner-full)}:host footer:not([inert]){animation:controlsAppear .2s ease-in-out forwards}:host main yuv-object-metadata-section{margin-block-end:var(--ymt-spacing-m)}:host main yuv-object-summary-data{background-color:var(--_object-metadata-section-background);border:1px solid var(--ymt-outline-variant);border-radius:var(--_object-metadata-section-corner);padding:var(--ymt-spacing-m)}@keyframes controlsAppear{0%{opacity:0;translate:0 var(--ymt-spacing-m)}to{opacity:1;translate:0 0}}\n"] }]
683
682
  }], propDecorators: { formDisabled: [{
684
683
  type: Input
685
684
  }] } });