@myrmidon/cadmus-item-editor 12.0.0 → 13.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -346,10 +346,10 @@ class EditedItemRepository {
346
346
  });
347
347
  });
348
348
  }
349
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: EditedItemRepository, deps: [{ token: i1.AppRepository }, { token: i7.ItemService }], target: i0.ɵɵFactoryTarget.Injectable });
350
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: EditedItemRepository, providedIn: 'root' });
349
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: EditedItemRepository, deps: [{ token: i1.AppRepository }, { token: i7.ItemService }], target: i0.ɵɵFactoryTarget.Injectable });
350
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: EditedItemRepository, providedIn: 'root' });
351
351
  }
352
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: EditedItemRepository, decorators: [{
352
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: EditedItemRepository, decorators: [{
353
353
  type: Injectable,
354
354
  args: [{ providedIn: 'root' }]
355
355
  }], ctorParameters: () => [{ type: i1.AppRepository }, { type: i7.ItemService }] });
@@ -455,10 +455,10 @@ class PartsScopeEditorComponent {
455
455
  });
456
456
  });
457
457
  }
458
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: PartsScopeEditorComponent, deps: [{ token: i1$1.FormBuilder }, { token: i7.FacetService }, { token: i3.DialogService }, { token: i1.AppRepository }, { token: i5.ColorService }, { token: EditedItemRepository }], target: i0.ɵɵFactoryTarget.Component });
459
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.3", type: PartsScopeEditorComponent, isStandalone: true, selector: "cadmus-parts-scope-editor", inputs: { parts: { classPropertyName: "parts", publicName: "parts", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { setScopeRequest: "setScopeRequest" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"submit()\">\n <table id=\"parts\">\n <thead>\n <tr>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th>scope</th>\n <th>modified</th>\n <th>user</th>\n </tr>\n </thead>\n <tbody>\n @for (ctl of checks.controls; track ctl; let i = $index) {\n <tr formArrayName=\"checks\">\n <td class=\"fit-width\">\n <mat-checkbox [formControlName]=\"i\"></mat-checkbox>\n </td>\n <td>\n <span\n class=\"model-type\"\n [style.background-color]=\"\n getPartColor($any(parts())[i].typeId, $any(parts())[i].roleId)\n \"\n [style.color]=\"\n getContrastColor($any(parts())[i].typeId, $any(parts())[i].roleId)\n \"\n >{{ getTypeIdName($any(parts())[i].typeId) }}</span\n >\n </td>\n <td>{{ getRoleIdName($any(parts())[i].roleId) }}</td>\n <td>{{ $any(parts())[i].thesaurusScope }}</td>\n <td>\n {{ $any(parts())[i].timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </td>\n <td>{{ $any(parts())[i].userId }}</td>\n </tr>\n }\n </tbody>\n </table>\n <div class=\"form-row\">\n <mat-form-field>\n <mat-label>scope</mat-label>\n <input matInput formControlName=\"scope\" />\n @if (scope.hasError('maxLength') && (scope.dirty || scope.touched)) {\n <mat-error>too long</mat-error>\n } @if (scope.hasError('pattern') && (scope.dirty || scope.touched)) {\n <mat-error>invalid scope</mat-error>\n }\n </mat-form-field>\n <button\n mat-flat-button\n class=\"mat-primary\"\n type=\"submit\"\n [disabled]=\"form.invalid || readonly\"\n matTooltip=\"Assign the scope to the checked parts\"\n >\n assign\n </button>\n </div>\n</form>\n", styles: ["table{width:100%;border-collapse:collapse}tbody tr:nth-child(odd){background-color:#e2e2e2}th{text-align:left;font-weight:400;color:silver}td.fit-width{width:1px;white-space:nowrap}span.model-type{padding:4px;border-radius:6px}table#parts{border-collapse:separate;border-spacing:0 8px}.form-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.form-row *{flex:0 0 auto}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormArrayName, selector: "[formArrayName]", inputs: ["formArrayName"] }, { kind: "component", type: 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: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: DatePipe, name: "date" }] });
458
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: PartsScopeEditorComponent, deps: [{ token: i1$1.FormBuilder }, { token: i7.FacetService }, { token: i3.DialogService }, { token: i1.AppRepository }, { token: i5.ColorService }, { token: EditedItemRepository }], target: i0.ɵɵFactoryTarget.Component });
459
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.0", type: PartsScopeEditorComponent, isStandalone: true, selector: "cadmus-parts-scope-editor", inputs: { parts: { classPropertyName: "parts", publicName: "parts", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { setScopeRequest: "setScopeRequest" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"submit()\">\n <table id=\"parts\">\n <thead>\n <tr>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th>scope</th>\n <th>modified</th>\n <th>user</th>\n </tr>\n </thead>\n <tbody>\n @for (ctl of checks.controls; track ctl; let i = $index) {\n <tr formArrayName=\"checks\">\n <td class=\"fit-width\">\n <mat-checkbox [formControlName]=\"i\"></mat-checkbox>\n </td>\n <td>\n <span\n class=\"model-type\"\n [style.background-color]=\"\n getPartColor($any(parts())[i].typeId, $any(parts())[i].roleId)\n \"\n [style.color]=\"\n getContrastColor($any(parts())[i].typeId, $any(parts())[i].roleId)\n \"\n >{{ getTypeIdName($any(parts())[i].typeId) }}</span\n >\n </td>\n <td>{{ getRoleIdName($any(parts())[i].roleId) }}</td>\n <td>{{ $any(parts())[i].thesaurusScope }}</td>\n <td>\n {{ $any(parts())[i].timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </td>\n <td>{{ $any(parts())[i].userId }}</td>\n </tr>\n }\n </tbody>\n </table>\n <div class=\"form-row\">\n <mat-form-field>\n <mat-label>scope</mat-label>\n <input matInput formControlName=\"scope\" />\n @if (scope.hasError('maxLength') && (scope.dirty || scope.touched)) {\n <mat-error>too long</mat-error>\n } @if (scope.hasError('pattern') && (scope.dirty || scope.touched)) {\n <mat-error>invalid scope</mat-error>\n }\n </mat-form-field>\n <button\n mat-flat-button\n class=\"mat-primary\"\n type=\"submit\"\n [disabled]=\"form.invalid || readonly\"\n matTooltip=\"Assign the scope to the checked parts\"\n >\n assign\n </button>\n </div>\n</form>\n", styles: ["table{width:100%;border-collapse:collapse}tbody tr:nth-child(odd){background-color:#e2e2e2}th{text-align:left;font-weight:400;color:silver}td.fit-width{width:1px;white-space:nowrap}span.model-type{padding:4px;border-radius:6px}table#parts{border-collapse:separate;border-spacing:0 8px}.form-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.form-row *{flex:0 0 auto}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormArrayName, selector: "[formArrayName]", inputs: ["formArrayName"] }, { kind: "component", type: 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: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: DatePipe, name: "date" }] });
460
460
  }
461
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: PartsScopeEditorComponent, decorators: [{
461
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: PartsScopeEditorComponent, decorators: [{
462
462
  type: Component,
463
463
  args: [{ selector: 'cadmus-parts-scope-editor', imports: [
464
464
  ReactiveFormsModule,
@@ -492,10 +492,10 @@ class ItemLookupDialogComponent {
492
492
  onItemLookupChange(value) {
493
493
  this.dialogRef.close(value);
494
494
  }
495
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemLookupDialogComponent, deps: [{ token: i2.MatDialogRef }, { token: MAT_DIALOG_DATA }, { token: i2$1.ItemRefLookupService }], target: i0.ɵɵFactoryTarget.Component });
496
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.3", type: ItemLookupDialogComponent, isStandalone: true, selector: "cadmus-item-lookup-dialog", ngImport: i0, template: "<div id=\"container\">\r\n <h3>Select Item</h3>\r\n <cadmus-ref-lookup\r\n [service]=\"itemLookupService\"\r\n label=\"item\"\r\n (itemChange)=\"onItemLookupChange($event)\"\r\n />\r\n</div>\r\n", styles: ["#container{padding:16px}\n"], dependencies: [{ kind: "component", type: RefLookupComponent, selector: "cadmus-ref-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "required", "hasMore", "linkTemplate", "optDialog", "options"], outputs: ["itemChange", "optionsChange", "moreRequest"] }] });
495
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemLookupDialogComponent, deps: [{ token: i2.MatDialogRef }, { token: MAT_DIALOG_DATA }, { token: i2$1.ItemRefLookupService }], target: i0.ɵɵFactoryTarget.Component });
496
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.0", type: ItemLookupDialogComponent, isStandalone: true, selector: "cadmus-item-lookup-dialog", ngImport: i0, template: "<div id=\"container\">\r\n <h3>Select Item</h3>\r\n <cadmus-ref-lookup\r\n [service]=\"itemLookupService\"\r\n label=\"item\"\r\n (itemChange)=\"onItemLookupChange($event)\"\r\n />\r\n</div>\r\n", styles: ["#container{padding:16px}\n"], dependencies: [{ kind: "component", type: RefLookupComponent, selector: "cadmus-ref-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "required", "hasMore", "linkTemplate", "optDialog", "options"], outputs: ["itemChange", "optionsChange", "moreRequest"] }] });
497
497
  }
498
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemLookupDialogComponent, decorators: [{
498
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemLookupDialogComponent, decorators: [{
499
499
  type: Component,
500
500
  args: [{ selector: 'cadmus-item-lookup-dialog', imports: [RefLookupComponent], template: "<div id=\"container\">\r\n <h3>Select Item</h3>\r\n <cadmus-ref-lookup\r\n [service]=\"itemLookupService\"\r\n label=\"item\"\r\n (itemChange)=\"onItemLookupChange($event)\"\r\n />\r\n</div>\r\n", styles: ["#container{padding:16px}\n"] }]
501
501
  }], ctorParameters: () => [{ type: i2.MatDialogRef }, { type: i2.MatDialogConfig, decorators: [{
@@ -549,10 +549,10 @@ class ItemGenerateDialogComponent {
549
549
  flags: flags,
550
550
  });
551
551
  }
552
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemGenerateDialogComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
553
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.3", type: ItemGenerateDialogComponent, isStandalone: true, selector: "cadmus-item-generate-dialog", ngImport: i0, template: "<div id=\"container\">\r\n <h3>Generate Items</h3>\r\n <form [formGroup]=\"form\" (submit)=\"apply()\">\r\n <!-- count -->\r\n <div>\r\n <mat-form-field class=\"input-nr\">\r\n <mat-label>count</mat-label>\r\n <input matInput type=\"number\" min=\"1\" [formControl]=\"itemCount\" />\r\n <mat-hint>number of items to generate</mat-hint>\r\n\r\n @if ($any(itemCount).errors?.required && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count required</mat-error>\r\n } @if ($any(itemCount).errors?.min && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count too low</mat-error>\r\n } @if ($any(itemCount).errors?.max && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count too high</mat-error>\r\n }\r\n </mat-form-field>\r\n </div>\r\n\r\n <!-- title -->\r\n <div>\r\n <mat-form-field>\r\n <mat-label>title</mat-label>\r\n <input matInput [formControl]=\"itemTitle\" />\r\n <mat-hint>title template ({{ 0 }}=N)</mat-hint>\r\n\r\n @if ($any(itemTitle).errors?.required && (itemTitle.dirty ||\r\n itemTitle.touched)) {\r\n <mat-error>title required</mat-error>\r\n } @if ($any(itemTitle).errors?.maxLength && (itemTitle.dirty ||\r\n itemTitle.touched)) {\r\n <mat-error>title too long</mat-error>\r\n }\r\n </mat-form-field>\r\n </div>\r\n\r\n <!-- flags -->\r\n @if (flags.length) {\r\n <div>\r\n <mat-form-field>\r\n <mat-label>flags</mat-label>\r\n <mat-select [formControl]=\"itemFlags\" multiple>\r\n @for (flag of flags; track flag.id) {\r\n <mat-option [value]=\"flag\">\r\n <span class=\"flag-bullet\" [style.color]=\"'#' + flag.colorKey\"\r\n >&#x2b24;</span\r\n >\r\n {{ flag.label }}</mat-option\r\n >\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n }\r\n\r\n <!-- apply button -->\r\n <div>\r\n <button\r\n mat-flat-button\r\n class=\"mat-primary\"\r\n type=\"submit\"\r\n [disabled]=\"form.invalid\"\r\n >\r\n generate\r\n </button>\r\n </div>\r\n </form>\r\n</div>\r\n", styles: ["#container{padding:16px}.flag-bullet{margin-right:.5em}.input-nr{width:5em}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MinValidator, selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]", inputs: ["min"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }] });
552
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemGenerateDialogComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
553
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.0", type: ItemGenerateDialogComponent, isStandalone: true, selector: "cadmus-item-generate-dialog", ngImport: i0, template: "<div id=\"container\">\r\n <h3>Generate Items</h3>\r\n <form [formGroup]=\"form\" (submit)=\"apply()\">\r\n <!-- count -->\r\n <div>\r\n <mat-form-field class=\"input-nr\">\r\n <mat-label>count</mat-label>\r\n <input matInput type=\"number\" min=\"1\" [formControl]=\"itemCount\" />\r\n <mat-hint>number of items to generate</mat-hint>\r\n\r\n @if ($any(itemCount).errors?.required && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count required</mat-error>\r\n } @if ($any(itemCount).errors?.min && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count too low</mat-error>\r\n } @if ($any(itemCount).errors?.max && (itemCount.dirty ||\r\n itemCount.touched)) {\r\n <mat-error>count too high</mat-error>\r\n }\r\n </mat-form-field>\r\n </div>\r\n\r\n <!-- title -->\r\n <div>\r\n <mat-form-field>\r\n <mat-label>title</mat-label>\r\n <input matInput [formControl]=\"itemTitle\" />\r\n <mat-hint>title template ({{ 0 }}=N)</mat-hint>\r\n\r\n @if ($any(itemTitle).errors?.required && (itemTitle.dirty ||\r\n itemTitle.touched)) {\r\n <mat-error>title required</mat-error>\r\n } @if ($any(itemTitle).errors?.maxLength && (itemTitle.dirty ||\r\n itemTitle.touched)) {\r\n <mat-error>title too long</mat-error>\r\n }\r\n </mat-form-field>\r\n </div>\r\n\r\n <!-- flags -->\r\n @if (flags.length) {\r\n <div>\r\n <mat-form-field>\r\n <mat-label>flags</mat-label>\r\n <mat-select [formControl]=\"itemFlags\" multiple>\r\n @for (flag of flags; track flag.id) {\r\n <mat-option [value]=\"flag\">\r\n <span class=\"flag-bullet\" [style.color]=\"'#' + flag.colorKey\"\r\n >&#x2b24;</span\r\n >\r\n {{ flag.label }}</mat-option\r\n >\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n }\r\n\r\n <!-- apply button -->\r\n <div>\r\n <button\r\n mat-flat-button\r\n class=\"mat-primary\"\r\n type=\"submit\"\r\n [disabled]=\"form.invalid\"\r\n >\r\n generate\r\n </button>\r\n </div>\r\n </form>\r\n</div>\r\n", styles: ["#container{padding:16px}.flag-bullet{margin-right:.5em}.input-nr{width:5em}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MinValidator, selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]", inputs: ["min"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }] });
554
554
  }
555
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemGenerateDialogComponent, decorators: [{
555
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemGenerateDialogComponent, decorators: [{
556
556
  type: Component,
557
557
  args: [{ selector: 'cadmus-item-generate-dialog', imports: [
558
558
  ReactiveFormsModule,
@@ -610,10 +610,10 @@ class MissingPartsComponent {
610
610
  requestAddPart(definition) {
611
611
  this.addRequest.emit(definition);
612
612
  }
613
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: MissingPartsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
614
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.3", type: MissingPartsComponent, isStandalone: true, selector: "cadmus-missing-parts", inputs: { facetDefinition: { classPropertyName: "facetDefinition", publicName: "facetDefinition", isSignal: true, isRequired: false, transformFunction: null }, partDefinitions: { classPropertyName: "partDefinitions", publicName: "partDefinitions", isSignal: true, isRequired: false, transformFunction: null }, parts: { classPropertyName: "parts", publicName: "parts", isSignal: true, isRequired: false, transformFunction: null }, typeThesaurus: { classPropertyName: "typeThesaurus", publicName: "typeThesaurus", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { addRequest: "addRequest" }, ngImport: i0, template: "@if (missingDefinitions.length) {\n<div>\n <h3><mat-icon class=\"mat-warn\">warning</mat-icon>&nbsp; Missing Parts</h3>\n <table>\n <tbody>\n @for (def of missingDefinitions; track def) {\n <tr>\n <td>\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Add this part\"\n (click)=\"requestAddPart(def)\"\n >\n <mat-icon>add_circle</mat-icon>\n </button>\n </td>\n <td matTooltip=\"def.description\">\n <cadmus-part-badge\n [partTypeIds]=\"def\"\n [facetDefinition]=\"facetDefinition()\"\n [typeThesaurus]=\"typeThesaurus()\"\n />\n </td>\n </tr>\n }\n </tbody>\n </table>\n</div>\n}\n", styles: [""], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: PartBadgeComponent, selector: "cadmus-part-badge", inputs: ["badgeType", "typeThesaurus", "facetDefinition", "partTypeIds"] }] });
613
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: MissingPartsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
614
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.0", type: MissingPartsComponent, isStandalone: true, selector: "cadmus-missing-parts", inputs: { facetDefinition: { classPropertyName: "facetDefinition", publicName: "facetDefinition", isSignal: true, isRequired: false, transformFunction: null }, partDefinitions: { classPropertyName: "partDefinitions", publicName: "partDefinitions", isSignal: true, isRequired: false, transformFunction: null }, parts: { classPropertyName: "parts", publicName: "parts", isSignal: true, isRequired: false, transformFunction: null }, typeThesaurus: { classPropertyName: "typeThesaurus", publicName: "typeThesaurus", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { addRequest: "addRequest" }, ngImport: i0, template: "@if (missingDefinitions.length) {\n<div>\n <h3><mat-icon class=\"mat-warn\">warning</mat-icon>&nbsp; Missing Parts</h3>\n <table>\n <tbody>\n @for (def of missingDefinitions; track def) {\n <tr>\n <td>\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Add this part\"\n (click)=\"requestAddPart(def)\"\n >\n <mat-icon>add_circle</mat-icon>\n </button>\n </td>\n <td matTooltip=\"def.description\">\n <cadmus-part-badge\n [partTypeIds]=\"def\"\n [facetDefinition]=\"facetDefinition()\"\n [typeThesaurus]=\"typeThesaurus()\"\n />\n </td>\n </tr>\n }\n </tbody>\n </table>\n</div>\n}\n", styles: [""], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: PartBadgeComponent, selector: "cadmus-part-badge", inputs: ["badgeType", "typeThesaurus", "facetDefinition", "partTypeIds"] }] });
615
615
  }
616
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: MissingPartsComponent, decorators: [{
616
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: MissingPartsComponent, decorators: [{
617
617
  type: Component,
618
618
  args: [{ selector: 'cadmus-missing-parts', imports: [MatIcon, MatIconButton, MatTooltip, PartBadgeComponent], template: "@if (missingDefinitions.length) {\n<div>\n <h3><mat-icon class=\"mat-warn\">warning</mat-icon>&nbsp; Missing Parts</h3>\n <table>\n <tbody>\n @for (def of missingDefinitions; track def) {\n <tr>\n <td>\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Add this part\"\n (click)=\"requestAddPart(def)\"\n >\n <mat-icon>add_circle</mat-icon>\n </button>\n </td>\n <td matTooltip=\"def.description\">\n <cadmus-part-badge\n [partTypeIds]=\"def\"\n [facetDefinition]=\"facetDefinition()\"\n [typeThesaurus]=\"typeThesaurus()\"\n />\n </td>\n </tr>\n }\n </tbody>\n </table>\n</div>\n}\n" }]
619
619
  }], ctorParameters: () => [] });
@@ -653,10 +653,10 @@ class HasPreviewPipe {
653
653
  const key = value.roleId ? `${value.typeId}|${value.roleId}` : value.typeId;
654
654
  return rKeys?.find((k) => k === key) ? true : false;
655
655
  }
656
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: HasPreviewPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
657
- static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "19.1.3", ngImport: i0, type: HasPreviewPipe, isStandalone: true, name: "hasPreview" });
656
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: HasPreviewPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
657
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "19.2.0", ngImport: i0, type: HasPreviewPipe, isStandalone: true, name: "hasPreview" });
658
658
  }
659
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: HasPreviewPipe, decorators: [{
659
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: HasPreviewPipe, decorators: [{
660
660
  type: Pipe,
661
661
  args: [{ name: 'hasPreview' }]
662
662
  }] });
@@ -1117,10 +1117,10 @@ class ItemEditorComponent {
1117
1117
  });
1118
1118
  });
1119
1119
  }
1120
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemEditorComponent, deps: [{ token: i2$1.ItemRefLookupService }, { token: i2.MatDialog }, { token: i3$1.Router }, { token: i3$1.ActivatedRoute }, { token: i4.MatSnackBar }, { token: i1.AppRepository }, { token: EditedItemRepository }, { token: i7.ItemService }, { token: i8.LibraryRouteService }, { token: i3.DialogService }, { token: i10.AuthJwtService }, { token: i7.UserLevelService }, { token: i7.MessagingService }, { token: i1$1.FormBuilder }], target: i0.ɵɵFactoryTarget.Component });
1121
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.3", type: ItemEditorComponent, isStandalone: true, selector: "cadmus-item-editor", ngImport: i0, template: "<mat-card appearance=\"outlined\">\n <mat-card-header>\n <mat-card-title>\n {{ (item$ | async)?.title || \"Item\" }}\n </mat-card-title>\n <mat-card-subtitle>\n {{ (item$ | async)?.description }}\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n @if (id) {\n <p>\n ID:\n <input\n [cdkCopyToClipboard]=\"(item$ | async)?.id || ''\"\n type=\"text\"\n readonly=\"true\"\n spellcheck=\"false\"\n matTooltip=\"Click to copy\"\n [value]=\"(item$ | async)?.id\"\n class=\"id\"\n />\n </p>\n } @if (item$ | async; as item) {\n <p>\n Last saved {{ item.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }} by\n {{ item.userId }}.<br />\n Created {{ item.timeCreated | date : \"yyyy-MM-dd HH:mm:ss\" }} by\n {{ item.creatorId }}.\n </p>\n } @if (busy) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <!-- item content -->\n <mat-tab-group [selectedIndex]=\"id ? 1 : 0\">\n <!-- metadata -->\n <mat-tab label=\"Metadata\">\n <form [formGroup]=\"metadata\" (ngSubmit)=\"save()\">\n <div class=\"form-row\">\n <!-- title -->\n <mat-form-field style=\"flex: 1 0 auto\">\n <mat-label>title</mat-label>\n <input matInput type=\"text\" id=\"title\" [formControl]=\"title\" />\n @if ( title.hasError('required') && (title.touched || title.dirty)\n ) {\n <mat-error>enter title</mat-error>\n } @if ( title.hasError('maxLength') && (title.touched ||\n title.dirty) ) {\n <mat-error> title too long</mat-error>\n }\n </mat-form-field>\n\n <!-- sortKey -->\n <mat-form-field style=\"flex: 1 0 auto\">\n <mat-label>sort key</mat-label>\n <input\n matInput\n type=\"text\"\n id=\"sortKey\"\n [formControl]=\"sortKey\"\n />\n @if ( sortKey.hasError('required') && (sortKey.touched ||\n sortKey.dirty) ) {\n <mat-error>enter sort key</mat-error>\n } @if ( sortKey.hasError('maxLength') && (sortKey.touched ||\n sortKey.dirty) ) {\n <mat-error>sort key too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- description -->\n <div>\n <mat-form-field class=\"full-width\">\n <mat-label>description</mat-label>\n <textarea\n rows=\"2\"\n matInput\n id=\"description\"\n [formControl]=\"description\"\n ></textarea>\n @if ( description.hasError('required') && (description.touched ||\n description.dirty) ) {\n <mat-error>enter description</mat-error>\n } @if ( description.hasError('maxLength') && (description.touched\n || description.dirty) ) {\n <mat-error>description too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- facet -->\n <div class=\"form-row\">\n <mat-form-field>\n <mat-label>facet</mat-label>\n <mat-select [formControl]=\"facet\" required=\"true\">\n @for (f of facets$ | async; track f) {\n <mat-option [value]=\"f.id\">\n {{ f.label }}\n </mat-option>\n }\n </mat-select>\n <mat-error>please select a facet</mat-error>\n </mat-form-field>\n\n <!-- group -->\n <mat-form-field>\n <mat-label>group ID</mat-label>\n <input matInput [formControl]=\"group\" />\n @if ( group.hasError('maxLength') && (group.dirty ||\n group.touched) ) {\n <mat-error>too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- flags -->\n <fieldset>\n <legend>flags</legend>\n @if (flagDefinitions) {\n <div formArrayName=\"flagChecks\">\n @for (c of flagChecks.controls; track c; let i = $index) { @if\n (userLevel < 4 && flagDefinitions[i].isAdmin === true) {\n <span\n [style.color]=\"'#' + flagDefinitions[i].colorKey\"\n style=\"margin-left: 12px\"\n >&#x25c6;</span\n >\n &nbsp;\n {{ flagDefinitions[i].label }}\n } @else {\n <mat-checkbox class=\"flag\" [formControlName]=\"i\">\n <span [style.color]=\"'#' + flagDefinitions[i].colorKey\"\n >&#x2b24;</span\n >\n &nbsp;\n {{ flagDefinitions[i].label }}\n </mat-checkbox>\n } }\n </div>\n }\n </fieldset>\n <br />\n\n <!-- action buttons -->\n @if (userLevel > 1) {\n <div class=\"form-row\">\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n (click)=\"onGenerateItems()\"\n >\n <mat-icon>copy_all</mat-icon> generate\n </button>\n <button\n type=\"submit\"\n mat-flat-button\n class=\"mat-primary\"\n [disabled]=\"busy\"\n matTooltip=\"Save metadata\"\n (click)=\"save()\"\n >\n <mat-icon>save</mat-icon> save\n </button>\n </div>\n }\n </form>\n </mat-tab>\n\n <!-- parts -->\n @if (id) {\n <mat-tab label=\"Parts\">\n <div class=\"new-part\">\n <form [formGroup]=\"newPart\" class=\"form-row\">\n <mat-form-field>\n <mat-label>part</mat-label>\n <mat-select [formControl]=\"newPartType\" required>\n @for (p of newPartDefinitions$ | async; track p) {\n <mat-option [value]=\"p\">\n <span [style.color]=\"'#' + p.colorKey\" class=\"new-part-icon\"\n >&#x2b24;</span\n >\n {{ p.name }}\n @if (p.roleId) {\n <span class=\"new-part-role\">{{ p.roleId }}</span>\n }\n </mat-option>\n }\n </mat-select>\n <mat-error>part type required</mat-error>\n </mat-form-field>\n <button\n mat-flat-button\n class=\"mat-primary\"\n type=\"button\"\n [disabled]=\"userLevel < 2 || busy || !newPart.valid\"\n (click)=\"addPart()\"\n matTooltip=\"Add a new part of the selected type\"\n >\n <mat-icon>add_circle</mat-icon>\n part\n </button>\n </form>\n </div>\n <mat-divider></mat-divider>\n @for (group of partGroups$ | async; track group) {\n <mat-expansion-panel expanded=\"true\" class=\"group-header\">\n <mat-expansion-panel-header>\n <mat-panel-title\n ><strong>{{ group.label }}</strong></mat-panel-title\n >\n <mat-panel-description>{{\n group.parts.length\n }}</mat-panel-description>\n </mat-expansion-panel-header>\n <table class=\"parts-table\">\n <thead>\n <tr>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th class=\"noif-lt-xs\">modified</th>\n <th class=\"noif-lt-xs\">user</th>\n </tr>\n </thead>\n <tbody>\n @for (part of group.parts; track part) {\n <tr>\n <!-- edit -->\n <td class=\"fit-width\">\n <button\n mat-icon-button\n type=\"button\"\n [disabled]=\"busy\"\n (click)=\"editPart(part)\"\n matTooltip=\"Edit this part\"\n >\n <mat-icon class=\"mat-primary\">create</mat-icon>\n </button>\n <!-- delete -->\n @if ( user?.roles?.length && (user?.roles?.includes('admin')\n || user?.roles?.includes('editor') ||\n user?.roles?.includes('operator')) ) {\n <button\n mat-icon-button\n type=\"button\"\n [disabled]=\"userLevel < 2 || busy\"\n (click)=\"deletePart(part)\"\n matTooltip=\"Delete this part\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n }\n <!-- copy -->\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy this part ID\"\n [cdkCopyToClipboard]=\"part.id\"\n >\n <mat-icon>assignment</mat-icon>\n </button>\n <!-- copy into item -->\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy part into another item\"\n (click)=\"onCopyPart(part)\"\n >\n <mat-icon>open_in_new</mat-icon>\n </button>\n <!-- preview -->\n @if ( part | hasPreview : (previewJKeys$ | async) :\n (previewFKeys$ | async) ) {\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Preview this part\"\n (click)=\"previewPart(part)\"\n >\n <mat-icon>preview</mat-icon>\n </button>\n }\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"1\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"2\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td class=\"noif-lt-xs\">\n {{ part.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </td>\n <td class=\"noif-lt-xs\">{{ part.userId }}</td>\n </tr>\n }\n </tbody>\n </table>\n </mat-expansion-panel>\n }\n <cadmus-missing-parts\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [partDefinitions]=\"(facet$ | async)?.partDefinitions\"\n [parts]=\"(parts$ | async) || undefined\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n (addRequest)=\"addPart($event)\"\n />\n </mat-tab>\n } @if (id) {\n <mat-tab label=\"Layers\">\n @if (layerPartInfos$ | async; as parts) {\n <table id=\"layers\">\n <thead>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th>frr.</th>\n <th>last modified</th>\n </thead>\n <tbody>\n @for (part of parts; track part) {\n <tr>\n <td class=\"fit-width\">\n @if (!part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Edit this layer part\"\n (click)=\"editPart(part)\"\n >\n <mat-icon class=\"mat-primary\">edit</mat-icon>\n </button>\n } @if (part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Add this layer part\"\n [disabled]=\"userLevel < 2\"\n (click)=\"addLayerPart(part)\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n } @if (!part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Delete this layer part\"\n [disabled]=\"userLevel < 2\"\n (click)=\"deletePart(part)\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n } @if (!part.isAbsent) {\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy this part ID\"\n [cdkCopyToClipboard]=\"part.id\"\n >\n <mat-icon>assignment</mat-icon>\n </button>\n }\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"1\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"2\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td\n [ngClass]=\"{\n 'count-n': part.fragmentCount,\n 'count-z': !part.fragmentCount\n }\"\n >\n {{ part.fragmentCount }}\n </td>\n <td>\n @if (!part.isAbsent) {\n <span>\n {{ part.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </span>\n }\n </td>\n </tr>\n }\n </tbody>\n </table>\n }\n </mat-tab>\n } @if (parts$ | async; as parts) {\n <mat-tab label=\"Th-Scopes\">\n <!-- [parts]=\"parts | sort: 'typeId' | sort: 'roleId'\" -->\n <cadmus-parts-scope-editor\n [parts]=\"parts\"\n [readonly]=\"userLevel < 2 || busy ? true : false\"\n (setScopeRequest)=\"setPartsScope($event)\"\n />\n </mat-tab>\n }\n </mat-tab-group>\n </mat-card-content>\n</mat-card>\n", styles: [".full-width{width:100%}table{width:100%;border-collapse:collapse}th{font-weight:400;color:silver}td.fit-width{width:1px;white-space:nowrap}tbody tr:nth-child(odd){background-color:#e2e2e2}#layers td{padding:0 6px}div.new-part{margin-left:32px}span.new-part-role{color:gray;margin-left:8px;vertical-align:middle}span.new-part-icon{margin:0 4px;vertical-align:middle}td.count-n{text-align:center;color:#03c03c}td.count-z{text-align:center;color:#f34f41}input.id{font-family:Courier New,Courier,monospace;color:gray;min-width:22em}.flag{margin-left:10px}.form-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.form-row *{flex:0 0 auto}.group-header{border-top:1px solid silver}table.parts-table{width:100%}table.parts-table th{text-align:left}fieldset{border:1px solid silver;border-radius:6px;padding:6px;margin:8px 0}@media only screen and (max-width: 599px){.noif-lt-xs{display:none}}\n"], dependencies: [{ kind: "component", type: MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "component", type: MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "directive", type: MatCardSubtitle, selector: "mat-card-subtitle, [mat-card-subtitle], [matCardSubtitle]" }, { kind: "directive", type: MatCardContent, selector: "mat-card-content" }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass"], exportAs: ["matTab"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormArrayName, selector: "[formArrayName]", inputs: ["formArrayName"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "component", type: 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: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "directive", type: MatExpansionPanelDescription, selector: "mat-panel-description" }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: MissingPartsComponent, selector: "cadmus-missing-parts", inputs: ["facetDefinition", "partDefinitions", "parts", "typeThesaurus"], outputs: ["addRequest"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "pipe", type: HasPreviewPipe, name: "hasPreview" }, { kind: "component", type: PartsScopeEditorComponent, selector: "cadmus-parts-scope-editor", inputs: ["parts", "readonly"], outputs: ["setScopeRequest"] }, { kind: "component", type: PartBadgeComponent, selector: "cadmus-part-badge", inputs: ["badgeType", "typeThesaurus", "facetDefinition", "partTypeIds"] }] });
1120
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemEditorComponent, deps: [{ token: i2$1.ItemRefLookupService }, { token: i2.MatDialog }, { token: i3$1.Router }, { token: i3$1.ActivatedRoute }, { token: i4.MatSnackBar }, { token: i1.AppRepository }, { token: EditedItemRepository }, { token: i7.ItemService }, { token: i8.LibraryRouteService }, { token: i3.DialogService }, { token: i10.AuthJwtService }, { token: i7.UserLevelService }, { token: i7.MessagingService }, { token: i1$1.FormBuilder }], target: i0.ɵɵFactoryTarget.Component });
1121
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.0", type: ItemEditorComponent, isStandalone: true, selector: "cadmus-item-editor", ngImport: i0, template: "<mat-card appearance=\"outlined\">\n <mat-card-header>\n <mat-card-title>\n {{ (item$ | async)?.title || \"Item\" }}\n </mat-card-title>\n <mat-card-subtitle>\n {{ (item$ | async)?.description }}\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n @if (id) {\n <p>\n ID:\n <input\n [cdkCopyToClipboard]=\"(item$ | async)?.id || ''\"\n type=\"text\"\n readonly=\"true\"\n spellcheck=\"false\"\n matTooltip=\"Click to copy\"\n [value]=\"(item$ | async)?.id\"\n class=\"id\"\n />\n </p>\n } @if (item$ | async; as item) {\n <p>\n Last saved {{ item.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }} by\n {{ item.userId }}.<br />\n Created {{ item.timeCreated | date : \"yyyy-MM-dd HH:mm:ss\" }} by\n {{ item.creatorId }}.\n </p>\n } @if (busy) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <!-- item content -->\n <mat-tab-group [selectedIndex]=\"id ? 1 : 0\">\n <!-- metadata -->\n <mat-tab label=\"Metadata\">\n <form [formGroup]=\"metadata\" (ngSubmit)=\"save()\">\n <div class=\"form-row\">\n <!-- title -->\n <mat-form-field style=\"flex: 1 0 auto\">\n <mat-label>title</mat-label>\n <input matInput type=\"text\" id=\"title\" [formControl]=\"title\" />\n @if ( title.hasError('required') && (title.touched || title.dirty)\n ) {\n <mat-error>enter title</mat-error>\n } @if ( title.hasError('maxLength') && (title.touched ||\n title.dirty) ) {\n <mat-error> title too long</mat-error>\n }\n </mat-form-field>\n\n <!-- sortKey -->\n <mat-form-field style=\"flex: 1 0 auto\">\n <mat-label>sort key</mat-label>\n <input\n matInput\n type=\"text\"\n id=\"sortKey\"\n [formControl]=\"sortKey\"\n />\n @if ( sortKey.hasError('required') && (sortKey.touched ||\n sortKey.dirty) ) {\n <mat-error>enter sort key</mat-error>\n } @if ( sortKey.hasError('maxLength') && (sortKey.touched ||\n sortKey.dirty) ) {\n <mat-error>sort key too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- description -->\n <div>\n <mat-form-field class=\"full-width\">\n <mat-label>description</mat-label>\n <textarea\n rows=\"2\"\n matInput\n id=\"description\"\n [formControl]=\"description\"\n ></textarea>\n @if ( description.hasError('required') && (description.touched ||\n description.dirty) ) {\n <mat-error>enter description</mat-error>\n } @if ( description.hasError('maxLength') && (description.touched\n || description.dirty) ) {\n <mat-error>description too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- facet -->\n <div class=\"form-row\">\n <mat-form-field>\n <mat-label>facet</mat-label>\n <mat-select [formControl]=\"facet\" required=\"true\">\n @for (f of facets$ | async; track f) {\n <mat-option [value]=\"f.id\">\n {{ f.label }}\n </mat-option>\n }\n </mat-select>\n <mat-error>please select a facet</mat-error>\n </mat-form-field>\n\n <!-- group -->\n <mat-form-field>\n <mat-label>group ID</mat-label>\n <input matInput [formControl]=\"group\" />\n @if ( group.hasError('maxLength') && (group.dirty ||\n group.touched) ) {\n <mat-error>too long</mat-error>\n }\n </mat-form-field>\n </div>\n\n <!-- flags -->\n <fieldset>\n <legend>flags</legend>\n @if (flagDefinitions) {\n <div formArrayName=\"flagChecks\">\n @for (c of flagChecks.controls; track c; let i = $index) { @if\n (userLevel < 4 && flagDefinitions[i].isAdmin === true) {\n <span\n [style.color]=\"'#' + flagDefinitions[i].colorKey\"\n style=\"margin-left: 12px\"\n >&#x25c6;</span\n >\n &nbsp;\n {{ flagDefinitions[i].label }}\n } @else {\n <mat-checkbox class=\"flag\" [formControlName]=\"i\">\n <span [style.color]=\"'#' + flagDefinitions[i].colorKey\"\n >&#x2b24;</span\n >\n &nbsp;\n {{ flagDefinitions[i].label }}\n </mat-checkbox>\n } }\n </div>\n }\n </fieldset>\n <br />\n\n <!-- action buttons -->\n @if (userLevel > 1) {\n <div class=\"form-row\">\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n (click)=\"onGenerateItems()\"\n >\n <mat-icon>copy_all</mat-icon> generate\n </button>\n <button\n type=\"submit\"\n mat-flat-button\n class=\"mat-primary\"\n [disabled]=\"busy\"\n matTooltip=\"Save metadata\"\n (click)=\"save()\"\n >\n <mat-icon>save</mat-icon> save\n </button>\n </div>\n }\n </form>\n </mat-tab>\n\n <!-- parts -->\n @if (id) {\n <mat-tab label=\"Parts\">\n <div class=\"new-part\">\n <form [formGroup]=\"newPart\" class=\"form-row\">\n <mat-form-field>\n <mat-label>part</mat-label>\n <mat-select [formControl]=\"newPartType\" required>\n @for (p of newPartDefinitions$ | async; track p) {\n <mat-option [value]=\"p\">\n <span [style.color]=\"'#' + p.colorKey\" class=\"new-part-icon\"\n >&#x2b24;</span\n >\n {{ p.name }}\n @if (p.roleId) {\n <span class=\"new-part-role\">{{ p.roleId }}</span>\n }\n </mat-option>\n }\n </mat-select>\n <mat-error>part type required</mat-error>\n </mat-form-field>\n <button\n mat-flat-button\n class=\"mat-primary\"\n type=\"button\"\n [disabled]=\"userLevel < 2 || busy || !newPart.valid\"\n (click)=\"addPart()\"\n matTooltip=\"Add a new part of the selected type\"\n >\n <mat-icon>add_circle</mat-icon>\n part\n </button>\n </form>\n </div>\n <mat-divider></mat-divider>\n @for (group of partGroups$ | async; track group) {\n <mat-expansion-panel expanded=\"true\" class=\"group-header\">\n <mat-expansion-panel-header>\n <mat-panel-title\n ><strong>{{ group.label }}</strong></mat-panel-title\n >\n <mat-panel-description>{{\n group.parts.length\n }}</mat-panel-description>\n </mat-expansion-panel-header>\n <table class=\"parts-table\">\n <thead>\n <tr>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th class=\"noif-lt-xs\">modified</th>\n <th class=\"noif-lt-xs\">user</th>\n </tr>\n </thead>\n <tbody>\n @for (part of group.parts; track part) {\n <tr>\n <!-- edit -->\n <td class=\"fit-width\">\n <button\n mat-icon-button\n type=\"button\"\n [disabled]=\"busy\"\n (click)=\"editPart(part)\"\n matTooltip=\"Edit this part\"\n >\n <mat-icon class=\"mat-primary\">create</mat-icon>\n </button>\n <!-- delete -->\n @if ( user?.roles?.length && (user?.roles?.includes('admin')\n || user?.roles?.includes('editor') ||\n user?.roles?.includes('operator')) ) {\n <button\n mat-icon-button\n type=\"button\"\n [disabled]=\"userLevel < 2 || busy\"\n (click)=\"deletePart(part)\"\n matTooltip=\"Delete this part\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n }\n <!-- copy -->\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy this part ID\"\n [cdkCopyToClipboard]=\"part.id\"\n >\n <mat-icon>assignment</mat-icon>\n </button>\n <!-- copy into item -->\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy part into another item\"\n (click)=\"onCopyPart(part)\"\n >\n <mat-icon>open_in_new</mat-icon>\n </button>\n <!-- preview -->\n @if ( part | hasPreview : (previewJKeys$ | async) :\n (previewFKeys$ | async) ) {\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Preview this part\"\n (click)=\"previewPart(part)\"\n >\n <mat-icon>preview</mat-icon>\n </button>\n }\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"1\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"2\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td class=\"noif-lt-xs\">\n {{ part.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </td>\n <td class=\"noif-lt-xs\">{{ part.userId }}</td>\n </tr>\n }\n </tbody>\n </table>\n </mat-expansion-panel>\n }\n <cadmus-missing-parts\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [partDefinitions]=\"(facet$ | async)?.partDefinitions\"\n [parts]=\"(parts$ | async) || undefined\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n (addRequest)=\"addPart($event)\"\n />\n </mat-tab>\n } @if (id) {\n <mat-tab label=\"Layers\">\n @if (layerPartInfos$ | async; as parts) {\n <table id=\"layers\">\n <thead>\n <th></th>\n <th>type</th>\n <th>role</th>\n <th>frr.</th>\n <th>last modified</th>\n </thead>\n <tbody>\n @for (part of parts; track part) {\n <tr>\n <td class=\"fit-width\">\n @if (!part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Edit this layer part\"\n (click)=\"editPart(part)\"\n >\n <mat-icon class=\"mat-primary\">edit</mat-icon>\n </button>\n } @if (part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Add this layer part\"\n [disabled]=\"userLevel < 2\"\n (click)=\"addLayerPart(part)\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n } @if (!part.isAbsent) {\n <button\n type=\"button\"\n mat-icon-button\n matTooltip=\"Delete this layer part\"\n [disabled]=\"userLevel < 2\"\n (click)=\"deletePart(part)\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n } @if (!part.isAbsent) {\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Copy this part ID\"\n [cdkCopyToClipboard]=\"part.id\"\n >\n <mat-icon>assignment</mat-icon>\n </button>\n }\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"1\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td>\n <cadmus-part-badge\n [partTypeIds]=\"part\"\n [facetDefinition]=\"(facet$ | async) || undefined\"\n [badgeType]=\"2\"\n [typeThesaurus]=\"(typeThesaurus$ | async) || undefined\"\n />\n </td>\n <td\n [ngClass]=\"{\n 'count-n': part.fragmentCount,\n 'count-z': !part.fragmentCount\n }\"\n >\n {{ part.fragmentCount }}\n </td>\n <td>\n @if (!part.isAbsent) {\n <span>\n {{ part.timeModified | date : \"yyyy-MM-dd HH:mm:ss\" }}\n </span>\n }\n </td>\n </tr>\n }\n </tbody>\n </table>\n }\n </mat-tab>\n } @if (parts$ | async; as parts) {\n <mat-tab label=\"Th-Scopes\">\n <!-- [parts]=\"parts | sort: 'typeId' | sort: 'roleId'\" -->\n <cadmus-parts-scope-editor\n [parts]=\"parts\"\n [readonly]=\"userLevel < 2 || busy ? true : false\"\n (setScopeRequest)=\"setPartsScope($event)\"\n />\n </mat-tab>\n }\n </mat-tab-group>\n </mat-card-content>\n</mat-card>\n", styles: [".full-width{width:100%}table{width:100%;border-collapse:collapse}th{font-weight:400;color:silver}td.fit-width{width:1px;white-space:nowrap}tbody tr:nth-child(odd){background-color:#e2e2e2}#layers td{padding:0 6px}div.new-part{margin-left:32px}span.new-part-role{color:gray;margin-left:8px;vertical-align:middle}span.new-part-icon{margin:0 4px;vertical-align:middle}td.count-n{text-align:center;color:#03c03c}td.count-z{text-align:center;color:#f34f41}input.id{font-family:Courier New,Courier,monospace;color:gray;min-width:22em}.flag{margin-left:10px}.form-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.form-row *{flex:0 0 auto}.group-header{border-top:1px solid silver}table.parts-table{width:100%}table.parts-table th{text-align:left}fieldset{border:1px solid silver;border-radius:6px;padding:6px;margin:8px 0}@media only screen and (max-width: 599px){.noif-lt-xs{display:none}}\n"], dependencies: [{ kind: "component", type: MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "component", type: MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "directive", type: MatCardSubtitle, selector: "mat-card-subtitle, [mat-card-subtitle], [matCardSubtitle]" }, { kind: "directive", type: MatCardContent, selector: "mat-card-content" }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass"], exportAs: ["matTab"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormArrayName, selector: "[formArrayName]", inputs: ["formArrayName"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "component", type: 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: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "directive", type: MatExpansionPanelDescription, selector: "mat-panel-description" }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: MissingPartsComponent, selector: "cadmus-missing-parts", inputs: ["facetDefinition", "partDefinitions", "parts", "typeThesaurus"], outputs: ["addRequest"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "pipe", type: HasPreviewPipe, name: "hasPreview" }, { kind: "component", type: PartsScopeEditorComponent, selector: "cadmus-parts-scope-editor", inputs: ["parts", "readonly"], outputs: ["setScopeRequest"] }, { kind: "component", type: PartBadgeComponent, selector: "cadmus-part-badge", inputs: ["badgeType", "typeThesaurus", "facetDefinition", "partTypeIds"] }] });
1122
1122
  }
1123
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.3", ngImport: i0, type: ItemEditorComponent, decorators: [{
1123
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: ItemEditorComponent, decorators: [{
1124
1124
  type: Component,
1125
1125
  args: [{ selector: 'cadmus-item-editor', imports: [
1126
1126
  MatCard,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myrmidon/cadmus-item-editor",
3
- "version": "12.0.0",
3
+ "version": "13.0.0",
4
4
  "description": "Cadmus - item editor.",
5
5
  "keywords": [
6
6
  "Cadmus"
@@ -20,9 +20,9 @@
20
20
  "@myrmidon/ngx-mat-tools": "^0.0.1",
21
21
  "@myrmidon/paged-data-browsers": "^4.0.2",
22
22
  "@myrmidon/cadmus-core": "^11.0.0",
23
- "@myrmidon/cadmus-api": "^11.0.0",
23
+ "@myrmidon/cadmus-api": "^12.0.0",
24
24
  "@myrmidon/cadmus-ui": "^12.0.0",
25
- "@myrmidon/cadmus-state": "^11.0.0"
25
+ "@myrmidon/cadmus-state": "^12.0.0"
26
26
  },
27
27
  "dependencies": {
28
28
  "tslib": "^2.3.0"