@alfresco/adf-core 9.1.0-17089916964 → 9.1.0-17091577515
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/fesm2022/adf-core.mjs
CHANGED
|
@@ -18311,7 +18311,7 @@ class CardViewTextItemComponent extends BaseCardView {
|
|
|
18311
18311
|
return String(Math.trunc(Number(value)));
|
|
18312
18312
|
}
|
|
18313
18313
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: CardViewTextItemComponent, deps: [{ token: ClipboardService }, { token: TranslationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
18314
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.6", type: CardViewTextItemComponent, isStandalone: true, selector: "adf-card-view-textitem", inputs: { displayEmpty: "displayEmpty", copyToClipboardAction: "copyToClipboardAction", useChipsForMultiValueProperty: "useChipsForMultiValueProperty", multiValueSeparator: "multiValueSeparator", displayLabelForChips: "displayLabelForChips" }, host: { classAttribute: "adf-card-view-textitem" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div [ngSwitch]=\"templateType\">\n <div *ngSwitchDefault>\n <mat-form-field\n subscriptSizing=\"dynamic\"\n class=\"adf-property-field adf-card-textitem-field\"\n [ngClass]=\"{\n 'adf-property-read-only': !isEditable\n }\"\n >\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n >\n {{ property.label | translate }}\n </mat-label>\n\n <input\n matInput\n *ngIf=\"!property.multiline\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-not-editable': !editable\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n (dblclick)=\"copyToClipboard(property.displayValue)\"\n [title]=\"'CORE.METADATA.ACTIONS.COPY_TO_CLIPBOARD' | translate\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n (keydown)=\"undoText($event)\"\n />\n <textarea\n matInput\n *ngIf=\"property.multiline\"\n title=\"{{ property.label | translate }}\"\n [cdkTextareaAutosize]=\"true\"\n [cdkAutosizeMinRows]=\"1\"\n [cdkAutosizeMaxRows]=\"5\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n >\n </textarea>\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'chipsTemplate'\"\n class=\"adf-property-field adf-textitem-chip-list-container\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <mat-label\n *ngIf=\"showLabelForChips\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <mat-chip-grid #chipElement class=\"adf-textitem-chip-list\">\n <mat-chip-row *ngFor=\"let propertyValue of editedValue; let idx = index\" [removable]=\"isEditable\" (removed)=\"removeValueFromList(idx)\">\n {{ propertyValue }}\n <mat-icon *ngIf=\"isEditable\" matChipRemove>cancel</mat-icon>\n </mat-chip-row>\n </mat-chip-grid>\n\n <mat-form-field\n *ngIf=\"isEditable\"\n class=\"adf-property-field adf-textitem-chip-list-input\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <input\n matInput\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"editedValue ? '' : (property.default | translate)\"\n [attr.aria-label]=\"property.label | translate\"\n [matChipInputFor]=\"chipElement\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValueToList($event)\"\n [attr.data-automation-id]=\"'card-textitem-editchipinput-' + property.key\"\n />\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'clickableTemplate'\"\n role=\"button\"\n class=\"adf-textitem-clickable\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n [attr.data-automation-id]=\"'card-textitem-toggle-' + property.key\"\n tabindex=\"0\"\n (keyup.enter)=\"clicked()\"\n (click)=\"clicked()\"\n >\n <mat-form-field class=\"adf-property-field adf-card-textitem-field \" [floatLabel]=\"property.default ? 'always' : null\">\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <input\n matInput\n [type]=\"property.inputType\"\n class=\"adf-property-value\"\n title=\"{{ property.label | translate }}\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-textitem-clickable-value': isClickable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-has-icon-suffix': showClickableIcon\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [(ngModel)]=\"editedValue\"\n (blur)=\"update()\"\n (keydown.enter)=\"update()\"\n [readonly]=\"!isEditable\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n />\n <button\n mat-icon-button\n matSuffix\n *ngIf=\"showClickableIcon\"\n class=\"adf-textitem-action\"\n [attr.title]=\"'CORE.METADATA.ACTIONS.EDIT' | translate\"\n [attr.data-automation-id]=\"'card-textitem-clickable-icon-' + property.key\"\n >\n <mat-icon class=\"adf-textitem-icon\">{{ property?.icon }}</mat-icon>\n </button>\n </mat-form-field>\n </div>\n\n <div *ngSwitchCase=\"'emptyTemplate'\">\n <span class=\"adf-textitem-default-value\">{{ property.default | translate }}</span>\n </div>\n\n <mat-error *ngIf=\"isEditable && hasErrors\" class=\"adf-textitem-error\" [attr.data-automation-id]=\"'card-textitem-error-' + property.key\">\n <ul>\n <li *ngFor=\"let error of errors\">{{ error.message | translate : error }}</li>\n </ul>\n </mat-error>\n</div>\n", styles: [".adf-card-view-textitem .adf-textitem-error{font-size:var(--theme-caption-font-size);padding-top:6px}.adf-card-view-textitem .adf-textitem-error:before{display:none}.adf-card-view-textitem .adf-textitem-error ul{margin:0;padding:0;list-style-type:none}.adf-card-view-textitem .adf-textitem-error ul li{margin:0;padding:0}.adf-card-view-textitem .adf-textitem-action{width:30px;height:30px;padding:0;line-height:20px;color:var(--adf-theme-foreground-text-color-025)}.adf-card-view-textitem .adf-textitem-action:hover,.adf-card-view-textitem .adf-textitem-action:focus{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-action .mat-mdc-button-touch-target{width:30px;height:30px}.adf-card-view-textitem .mat-mdc-form-field-icon-suffix{position:absolute;right:1px;bottom:7px}.adf-card-view-textitem .adf-textitem-chip-list-container .mat-mdc-floating-label{margin-top:6px}.adf-card-view-textitem .adf-textitem-clickable{cursor:pointer;padding-top:3px}.adf-card-view-textitem .adf-textitem-clickable .adf-textitem-action:hover{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-clickable .adf-property-field .mat-mdc-input-element{color:var(--theme-primary-color);cursor:pointer}.adf-card-view-textitem .adf-textitem-default-value{color:var(--adf-theme-foreground-text-color-054)}.adf-card-view-textitem .adf-property-read-only:not(:has(.adf-property-readonly-value)){border-bottom:1px solid var(--adf-metadata-property-panel-border-color)}.adf-card-view-textitem .adf-property-value-not-editable{color:var(--adf-metadata-property-panel-title-color)}.adf-card-view-textitem .adf-property-value-has-icon-suffix{padding-right:34px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.adf-card-view-textitem .mdc-line-ripple:before,.adf-card-view-textitem .mdc-line-ripple:after{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i2$4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i2$4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i2$4.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i2$4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3$1.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: i6.CdkTextareaAutosize, selector: "textarea[cdkTextareaAutosize]", inputs: ["cdkAutosizeMinRows", "cdkAutosizeMaxRows", "cdkTextareaAutosize", "placeholder"], exportAs: ["cdkTextareaAutosize"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i4.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: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i8.MatChipGrid, selector: "mat-chip-grid", inputs: ["disabled", "placeholder", "required", "value", "errorStateMatcher"], outputs: ["change", "valueChange"] }, { kind: "directive", type: i8.MatChipInput, selector: "input[matChipInputFor]", inputs: ["matChipInputFor", "matChipInputAddOnBlur", "matChipInputSeparatorKeyCodes", "placeholder", "id", "disabled"], outputs: ["matChipInputTokenEnd"], exportAs: ["matChipInput", "matChipInputFor"] }, { kind: "directive", type: i8.MatChipRemove, selector: "[matChipRemove]" }, { kind: "component", type: i8.MatChipRow, selector: "mat-chip-row, [mat-chip-row], mat-basic-chip-row, [mat-basic-chip-row]", inputs: ["editable"], outputs: ["edited"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1$3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2$2.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatSnackBarModule }], encapsulation: i0.ViewEncapsulation.None }); }
|
|
18314
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.6", type: CardViewTextItemComponent, isStandalone: true, selector: "adf-card-view-textitem", inputs: { displayEmpty: "displayEmpty", copyToClipboardAction: "copyToClipboardAction", useChipsForMultiValueProperty: "useChipsForMultiValueProperty", multiValueSeparator: "multiValueSeparator", displayLabelForChips: "displayLabelForChips" }, host: { classAttribute: "adf-card-view-textitem" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div [ngSwitch]=\"templateType\">\n <div *ngSwitchDefault>\n <mat-form-field\n subscriptSizing=\"dynamic\"\n [floatLabel]=\"'always'\"\n class=\"adf-property-field adf-card-textitem-field\"\n [ngClass]=\"{\n 'adf-property-read-only': !isEditable\n }\"\n >\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n >\n {{ property.label | translate }}\n </mat-label>\n\n <input\n matInput\n *ngIf=\"!property.multiline\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-not-editable': !editable\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n (dblclick)=\"copyToClipboard(property.displayValue)\"\n [title]=\"'CORE.METADATA.ACTIONS.COPY_TO_CLIPBOARD' | translate\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n (keydown)=\"undoText($event)\"\n />\n <textarea\n matInput\n *ngIf=\"property.multiline\"\n title=\"{{ property.label | translate }}\"\n [cdkTextareaAutosize]=\"true\"\n [cdkAutosizeMinRows]=\"1\"\n [cdkAutosizeMaxRows]=\"5\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n >\n </textarea>\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'chipsTemplate'\"\n class=\"adf-property-field adf-textitem-chip-list-container\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <mat-label\n *ngIf=\"showLabelForChips\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <mat-chip-grid #chipElement class=\"adf-textitem-chip-list\">\n <mat-chip-row *ngFor=\"let propertyValue of editedValue; let idx = index\" [removable]=\"isEditable\" (removed)=\"removeValueFromList(idx)\">\n {{ propertyValue }}\n <mat-icon *ngIf=\"isEditable\" matChipRemove>cancel</mat-icon>\n </mat-chip-row>\n </mat-chip-grid>\n\n <mat-form-field\n *ngIf=\"isEditable\"\n class=\"adf-property-field adf-textitem-chip-list-input\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <input\n matInput\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"editedValue ? '' : (property.default | translate)\"\n [attr.aria-label]=\"property.label | translate\"\n [matChipInputFor]=\"chipElement\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValueToList($event)\"\n [attr.data-automation-id]=\"'card-textitem-editchipinput-' + property.key\"\n />\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'clickableTemplate'\"\n role=\"button\"\n class=\"adf-textitem-clickable\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n [attr.data-automation-id]=\"'card-textitem-toggle-' + property.key\"\n tabindex=\"0\"\n (keyup.enter)=\"clicked()\"\n (click)=\"clicked()\"\n >\n <mat-form-field class=\"adf-property-field adf-card-textitem-field \" [floatLabel]=\"property.default ? 'always' : null\">\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <input\n matInput\n [type]=\"property.inputType\"\n class=\"adf-property-value\"\n title=\"{{ property.label | translate }}\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-textitem-clickable-value': isClickable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-has-icon-suffix': showClickableIcon\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [(ngModel)]=\"editedValue\"\n (blur)=\"update()\"\n (keydown.enter)=\"update()\"\n [readonly]=\"!isEditable\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n />\n <button\n mat-icon-button\n matSuffix\n *ngIf=\"showClickableIcon\"\n class=\"adf-textitem-action\"\n [attr.title]=\"'CORE.METADATA.ACTIONS.EDIT' | translate\"\n [attr.data-automation-id]=\"'card-textitem-clickable-icon-' + property.key\"\n >\n <mat-icon class=\"adf-textitem-icon\">{{ property?.icon }}</mat-icon>\n </button>\n </mat-form-field>\n </div>\n\n <div *ngSwitchCase=\"'emptyTemplate'\">\n <span class=\"adf-textitem-default-value\">{{ property.default | translate }}</span>\n </div>\n\n <mat-error *ngIf=\"isEditable && hasErrors\" class=\"adf-textitem-error\" [attr.data-automation-id]=\"'card-textitem-error-' + property.key\">\n <ul>\n <li *ngFor=\"let error of errors\">{{ error.message | translate : error }}</li>\n </ul>\n </mat-error>\n</div>\n", styles: [".adf-card-view-textitem .adf-textitem-error{font-size:var(--theme-caption-font-size);padding-top:6px}.adf-card-view-textitem .adf-textitem-error:before{display:none}.adf-card-view-textitem .adf-textitem-error ul{margin:0;padding:0;list-style-type:none}.adf-card-view-textitem .adf-textitem-error ul li{margin:0;padding:0}.adf-card-view-textitem .adf-textitem-action{width:30px;height:30px;padding:0;line-height:20px;color:var(--adf-theme-foreground-text-color-025)}.adf-card-view-textitem .adf-textitem-action:hover,.adf-card-view-textitem .adf-textitem-action:focus{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-action .mat-mdc-button-touch-target{width:30px;height:30px}.adf-card-view-textitem .mat-mdc-form-field-icon-suffix{position:absolute;right:1px;bottom:7px}.adf-card-view-textitem .adf-textitem-chip-list-container .mat-mdc-floating-label{margin-top:6px}.adf-card-view-textitem .adf-textitem-clickable{cursor:pointer;padding-top:3px}.adf-card-view-textitem .adf-textitem-clickable .adf-textitem-action:hover{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-clickable .adf-property-field .mat-mdc-input-element{color:var(--theme-primary-color);cursor:pointer}.adf-card-view-textitem .adf-textitem-default-value{color:var(--adf-theme-foreground-text-color-054)}.adf-card-view-textitem .adf-property-read-only:not(:has(.adf-property-readonly-value)){border-bottom:1px solid var(--adf-metadata-property-panel-border-color)}.adf-card-view-textitem .adf-property-value-not-editable{color:var(--adf-metadata-property-panel-title-color)}.adf-card-view-textitem .adf-property-value-has-icon-suffix{padding-right:34px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.adf-card-view-textitem .mdc-line-ripple:before,.adf-card-view-textitem .mdc-line-ripple:after{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i2$4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i2$4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i2$4.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i2$4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3$1.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: i6.CdkTextareaAutosize, selector: "textarea[cdkTextareaAutosize]", inputs: ["cdkAutosizeMinRows", "cdkAutosizeMaxRows", "cdkTextareaAutosize", "placeholder"], exportAs: ["cdkTextareaAutosize"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i4.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: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i8.MatChipGrid, selector: "mat-chip-grid", inputs: ["disabled", "placeholder", "required", "value", "errorStateMatcher"], outputs: ["change", "valueChange"] }, { kind: "directive", type: i8.MatChipInput, selector: "input[matChipInputFor]", inputs: ["matChipInputFor", "matChipInputAddOnBlur", "matChipInputSeparatorKeyCodes", "placeholder", "id", "disabled"], outputs: ["matChipInputTokenEnd"], exportAs: ["matChipInput", "matChipInputFor"] }, { kind: "directive", type: i8.MatChipRemove, selector: "[matChipRemove]" }, { kind: "component", type: i8.MatChipRow, selector: "mat-chip-row, [mat-chip-row], mat-basic-chip-row, [mat-basic-chip-row]", inputs: ["editable"], outputs: ["edited"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1$3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2$2.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatSnackBarModule }], encapsulation: i0.ViewEncapsulation.None }); }
|
|
18315
18315
|
}
|
|
18316
18316
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: CardViewTextItemComponent, decorators: [{
|
|
18317
18317
|
type: Component,
|
|
@@ -18326,7 +18326,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImpor
|
|
|
18326
18326
|
FormsModule,
|
|
18327
18327
|
MatButtonModule,
|
|
18328
18328
|
MatSnackBarModule
|
|
18329
|
-
], encapsulation: ViewEncapsulation.None, host: { class: 'adf-card-view-textitem' }, template: "<div [ngSwitch]=\"templateType\">\n <div *ngSwitchDefault>\n <mat-form-field\n subscriptSizing=\"dynamic\"\n class=\"adf-property-field adf-card-textitem-field\"\n [ngClass]=\"{\n 'adf-property-read-only': !isEditable\n }\"\n >\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n >\n {{ property.label | translate }}\n </mat-label>\n\n <input\n matInput\n *ngIf=\"!property.multiline\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-not-editable': !editable\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n (dblclick)=\"copyToClipboard(property.displayValue)\"\n [title]=\"'CORE.METADATA.ACTIONS.COPY_TO_CLIPBOARD' | translate\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n (keydown)=\"undoText($event)\"\n />\n <textarea\n matInput\n *ngIf=\"property.multiline\"\n title=\"{{ property.label | translate }}\"\n [cdkTextareaAutosize]=\"true\"\n [cdkAutosizeMinRows]=\"1\"\n [cdkAutosizeMaxRows]=\"5\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n >\n </textarea>\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'chipsTemplate'\"\n class=\"adf-property-field adf-textitem-chip-list-container\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <mat-label\n *ngIf=\"showLabelForChips\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <mat-chip-grid #chipElement class=\"adf-textitem-chip-list\">\n <mat-chip-row *ngFor=\"let propertyValue of editedValue; let idx = index\" [removable]=\"isEditable\" (removed)=\"removeValueFromList(idx)\">\n {{ propertyValue }}\n <mat-icon *ngIf=\"isEditable\" matChipRemove>cancel</mat-icon>\n </mat-chip-row>\n </mat-chip-grid>\n\n <mat-form-field\n *ngIf=\"isEditable\"\n class=\"adf-property-field adf-textitem-chip-list-input\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <input\n matInput\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"editedValue ? '' : (property.default | translate)\"\n [attr.aria-label]=\"property.label | translate\"\n [matChipInputFor]=\"chipElement\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValueToList($event)\"\n [attr.data-automation-id]=\"'card-textitem-editchipinput-' + property.key\"\n />\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'clickableTemplate'\"\n role=\"button\"\n class=\"adf-textitem-clickable\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n [attr.data-automation-id]=\"'card-textitem-toggle-' + property.key\"\n tabindex=\"0\"\n (keyup.enter)=\"clicked()\"\n (click)=\"clicked()\"\n >\n <mat-form-field class=\"adf-property-field adf-card-textitem-field \" [floatLabel]=\"property.default ? 'always' : null\">\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <input\n matInput\n [type]=\"property.inputType\"\n class=\"adf-property-value\"\n title=\"{{ property.label | translate }}\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-textitem-clickable-value': isClickable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-has-icon-suffix': showClickableIcon\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [(ngModel)]=\"editedValue\"\n (blur)=\"update()\"\n (keydown.enter)=\"update()\"\n [readonly]=\"!isEditable\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n />\n <button\n mat-icon-button\n matSuffix\n *ngIf=\"showClickableIcon\"\n class=\"adf-textitem-action\"\n [attr.title]=\"'CORE.METADATA.ACTIONS.EDIT' | translate\"\n [attr.data-automation-id]=\"'card-textitem-clickable-icon-' + property.key\"\n >\n <mat-icon class=\"adf-textitem-icon\">{{ property?.icon }}</mat-icon>\n </button>\n </mat-form-field>\n </div>\n\n <div *ngSwitchCase=\"'emptyTemplate'\">\n <span class=\"adf-textitem-default-value\">{{ property.default | translate }}</span>\n </div>\n\n <mat-error *ngIf=\"isEditable && hasErrors\" class=\"adf-textitem-error\" [attr.data-automation-id]=\"'card-textitem-error-' + property.key\">\n <ul>\n <li *ngFor=\"let error of errors\">{{ error.message | translate : error }}</li>\n </ul>\n </mat-error>\n</div>\n", styles: [".adf-card-view-textitem .adf-textitem-error{font-size:var(--theme-caption-font-size);padding-top:6px}.adf-card-view-textitem .adf-textitem-error:before{display:none}.adf-card-view-textitem .adf-textitem-error ul{margin:0;padding:0;list-style-type:none}.adf-card-view-textitem .adf-textitem-error ul li{margin:0;padding:0}.adf-card-view-textitem .adf-textitem-action{width:30px;height:30px;padding:0;line-height:20px;color:var(--adf-theme-foreground-text-color-025)}.adf-card-view-textitem .adf-textitem-action:hover,.adf-card-view-textitem .adf-textitem-action:focus{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-action .mat-mdc-button-touch-target{width:30px;height:30px}.adf-card-view-textitem .mat-mdc-form-field-icon-suffix{position:absolute;right:1px;bottom:7px}.adf-card-view-textitem .adf-textitem-chip-list-container .mat-mdc-floating-label{margin-top:6px}.adf-card-view-textitem .adf-textitem-clickable{cursor:pointer;padding-top:3px}.adf-card-view-textitem .adf-textitem-clickable .adf-textitem-action:hover{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-clickable .adf-property-field .mat-mdc-input-element{color:var(--theme-primary-color);cursor:pointer}.adf-card-view-textitem .adf-textitem-default-value{color:var(--adf-theme-foreground-text-color-054)}.adf-card-view-textitem .adf-property-read-only:not(:has(.adf-property-readonly-value)){border-bottom:1px solid var(--adf-metadata-property-panel-border-color)}.adf-card-view-textitem .adf-property-value-not-editable{color:var(--adf-metadata-property-panel-title-color)}.adf-card-view-textitem .adf-property-value-has-icon-suffix{padding-right:34px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.adf-card-view-textitem .mdc-line-ripple:before,.adf-card-view-textitem .mdc-line-ripple:after{display:none}\n"] }]
|
|
18329
|
+
], encapsulation: ViewEncapsulation.None, host: { class: 'adf-card-view-textitem' }, template: "<div [ngSwitch]=\"templateType\">\n <div *ngSwitchDefault>\n <mat-form-field\n subscriptSizing=\"dynamic\"\n [floatLabel]=\"'always'\"\n class=\"adf-property-field adf-card-textitem-field\"\n [ngClass]=\"{\n 'adf-property-read-only': !isEditable\n }\"\n >\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n >\n {{ property.label | translate }}\n </mat-label>\n\n <input\n matInput\n *ngIf=\"!property.multiline\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-not-editable': !editable\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n (dblclick)=\"copyToClipboard(property.displayValue)\"\n [title]=\"'CORE.METADATA.ACTIONS.COPY_TO_CLIPBOARD' | translate\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n (keydown)=\"undoText($event)\"\n />\n <textarea\n matInput\n *ngIf=\"property.multiline\"\n title=\"{{ property.label | translate }}\"\n [cdkTextareaAutosize]=\"true\"\n [cdkAutosizeMinRows]=\"1\"\n [cdkAutosizeMaxRows]=\"5\"\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [formControl]=\"textInput\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n >\n </textarea>\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'chipsTemplate'\"\n class=\"adf-property-field adf-textitem-chip-list-container\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <mat-label\n *ngIf=\"showLabelForChips\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <mat-chip-grid #chipElement class=\"adf-textitem-chip-list\">\n <mat-chip-row *ngFor=\"let propertyValue of editedValue; let idx = index\" [removable]=\"isEditable\" (removed)=\"removeValueFromList(idx)\">\n {{ propertyValue }}\n <mat-icon *ngIf=\"isEditable\" matChipRemove>cancel</mat-icon>\n </mat-chip-row>\n </mat-chip-grid>\n\n <mat-form-field\n *ngIf=\"isEditable\"\n class=\"adf-property-field adf-textitem-chip-list-input\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n >\n <input\n matInput\n class=\"adf-property-value\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-property-readonly-value': isReadonlyProperty\n }\"\n title=\"{{ property.label | translate }}\"\n [placeholder]=\"editedValue ? '' : (property.default | translate)\"\n [attr.aria-label]=\"property.label | translate\"\n [matChipInputFor]=\"chipElement\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValueToList($event)\"\n [attr.data-automation-id]=\"'card-textitem-editchipinput-' + property.key\"\n />\n </mat-form-field>\n </div>\n\n <div\n *ngSwitchCase=\"'clickableTemplate'\"\n role=\"button\"\n class=\"adf-textitem-clickable\"\n [ngClass]=\"{ 'adf-property-read-only': !isEditable }\"\n [attr.data-automation-id]=\"'card-textitem-toggle-' + property.key\"\n tabindex=\"0\"\n (keyup.enter)=\"clicked()\"\n (click)=\"clicked()\"\n >\n <mat-form-field class=\"adf-property-field adf-card-textitem-field \" [floatLabel]=\"property.default ? 'always' : null\">\n <mat-label\n *ngIf=\"showProperty || isEditable\"\n [attr.data-automation-id]=\"'card-textitem-label-' + property.key\"\n class=\"adf-property-label\"\n [ngClass]=\"{ 'adf-property-value-editable': editable }\"\n >\n {{ property.label | translate }}\n </mat-label>\n <input\n matInput\n [type]=\"property.inputType\"\n class=\"adf-property-value\"\n title=\"{{ property.label | translate }}\"\n [ngClass]=\"{\n 'adf-property-value-editable': editable,\n 'adf-textitem-clickable-value': isClickable,\n 'adf-property-readonly-value': isReadonlyProperty,\n 'adf-property-value-has-error': isEditable && hasErrors,\n 'adf-property-value-has-icon-suffix': showClickableIcon\n }\"\n [placeholder]=\"property.default\"\n [attr.aria-label]=\"property.label | translate\"\n [(ngModel)]=\"editedValue\"\n (blur)=\"update()\"\n (keydown.enter)=\"update()\"\n [readonly]=\"!isEditable\"\n [attr.data-automation-id]=\"'card-textitem-value-' + property.key\"\n />\n <button\n mat-icon-button\n matSuffix\n *ngIf=\"showClickableIcon\"\n class=\"adf-textitem-action\"\n [attr.title]=\"'CORE.METADATA.ACTIONS.EDIT' | translate\"\n [attr.data-automation-id]=\"'card-textitem-clickable-icon-' + property.key\"\n >\n <mat-icon class=\"adf-textitem-icon\">{{ property?.icon }}</mat-icon>\n </button>\n </mat-form-field>\n </div>\n\n <div *ngSwitchCase=\"'emptyTemplate'\">\n <span class=\"adf-textitem-default-value\">{{ property.default | translate }}</span>\n </div>\n\n <mat-error *ngIf=\"isEditable && hasErrors\" class=\"adf-textitem-error\" [attr.data-automation-id]=\"'card-textitem-error-' + property.key\">\n <ul>\n <li *ngFor=\"let error of errors\">{{ error.message | translate : error }}</li>\n </ul>\n </mat-error>\n</div>\n", styles: [".adf-card-view-textitem .adf-textitem-error{font-size:var(--theme-caption-font-size);padding-top:6px}.adf-card-view-textitem .adf-textitem-error:before{display:none}.adf-card-view-textitem .adf-textitem-error ul{margin:0;padding:0;list-style-type:none}.adf-card-view-textitem .adf-textitem-error ul li{margin:0;padding:0}.adf-card-view-textitem .adf-textitem-action{width:30px;height:30px;padding:0;line-height:20px;color:var(--adf-theme-foreground-text-color-025)}.adf-card-view-textitem .adf-textitem-action:hover,.adf-card-view-textitem .adf-textitem-action:focus{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-action .mat-mdc-button-touch-target{width:30px;height:30px}.adf-card-view-textitem .mat-mdc-form-field-icon-suffix{position:absolute;right:1px;bottom:7px}.adf-card-view-textitem .adf-textitem-chip-list-container .mat-mdc-floating-label{margin-top:6px}.adf-card-view-textitem .adf-textitem-clickable{cursor:pointer;padding-top:3px}.adf-card-view-textitem .adf-textitem-clickable .adf-textitem-action:hover{color:var(--adf-theme-foreground-text-color)}.adf-card-view-textitem .adf-textitem-clickable .adf-property-field .mat-mdc-input-element{color:var(--theme-primary-color);cursor:pointer}.adf-card-view-textitem .adf-textitem-default-value{color:var(--adf-theme-foreground-text-color-054)}.adf-card-view-textitem .adf-property-read-only:not(:has(.adf-property-readonly-value)){border-bottom:1px solid var(--adf-metadata-property-panel-border-color)}.adf-card-view-textitem .adf-property-value-not-editable{color:var(--adf-metadata-property-panel-title-color)}.adf-card-view-textitem .adf-property-value-has-icon-suffix{padding-right:34px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.adf-card-view-textitem .mdc-line-ripple:before,.adf-card-view-textitem .mdc-line-ripple:after{display:none}\n"] }]
|
|
18330
18330
|
}], ctorParameters: () => [{ type: ClipboardService }, { type: TranslationService }, { type: i0.ChangeDetectorRef }], propDecorators: { displayEmpty: [{
|
|
18331
18331
|
type: Input
|
|
18332
18332
|
}], copyToClipboardAction: [{
|
|
@@ -26636,7 +26636,7 @@ class DynamicChipListComponent {
|
|
|
26636
26636
|
do {
|
|
26637
26637
|
chipsWidth = Math.max(chips.reduce((width, val, index) => {
|
|
26638
26638
|
width += val._elementRef.nativeElement.getBoundingClientRect().width + chipMargin;
|
|
26639
|
-
const availableSpace = (index
|
|
26639
|
+
const availableSpace = (index === chips.length - 1 && width <= containerWidth) ? containerWidth : containerWidth - viewMoreBtnWidth;
|
|
26640
26640
|
if (availableSpace >= width - chipMargin) {
|
|
26641
26641
|
chipsToDisplay = (this.paginationData ? chipsToDisplay : index) + 1;
|
|
26642
26642
|
lastIndex++;
|