@acrodata/gui 3.1.0 → 3.2.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.
- package/combobox/combobox.scss +13 -19
- package/fesm2022/acrodata-gui.mjs +5 -15
- package/fesm2022/acrodata-gui.mjs.map +1 -1
- package/image-select/image-select.scss +9 -11
- package/index.d.ts +3 -5
- package/package.json +3 -3
package/combobox/combobox.scss
CHANGED
|
@@ -1,20 +1,16 @@
|
|
|
1
1
|
.gui-combobox {
|
|
2
|
-
.ng-select {
|
|
3
|
-
padding-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
margin-right: -0.5rem;
|
|
7
|
-
|
|
8
|
-
&.ng-select-multiple .ng-value {
|
|
9
|
-
flex-direction: row-reverse;
|
|
10
|
-
}
|
|
2
|
+
.mat-mdc-form-field .ng-select {
|
|
3
|
+
padding-inline: 0.5rem;
|
|
4
|
+
margin-inline: -0.5rem;
|
|
5
|
+
}
|
|
11
6
|
|
|
12
|
-
|
|
7
|
+
.ng-select {
|
|
8
|
+
.ng-value-remove {
|
|
13
9
|
font-family: math;
|
|
14
10
|
font-size: 10px;
|
|
15
11
|
}
|
|
16
12
|
|
|
17
|
-
.ng-clear
|
|
13
|
+
.ng-clear {
|
|
18
14
|
font-family: math;
|
|
19
15
|
font-size: 12px;
|
|
20
16
|
}
|
|
@@ -27,15 +23,13 @@
|
|
|
27
23
|
&.ng-dropdown-panel {
|
|
28
24
|
padding: 0.5rem 0;
|
|
29
25
|
|
|
30
|
-
.ng-
|
|
31
|
-
.
|
|
32
|
-
|
|
33
|
-
|
|
26
|
+
.ng-option {
|
|
27
|
+
padding: 0 0.5rem;
|
|
28
|
+
line-height: var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height));
|
|
29
|
+
}
|
|
34
30
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
}
|
|
31
|
+
.ng-tag-label {
|
|
32
|
+
line-height: 1;
|
|
39
33
|
}
|
|
40
34
|
}
|
|
41
35
|
}
|
|
@@ -587,11 +587,6 @@ class GuiCombobox {
|
|
|
587
587
|
this.onChange = () => { };
|
|
588
588
|
this.onTouched = () => { };
|
|
589
589
|
}
|
|
590
|
-
ngAfterViewInit() {
|
|
591
|
-
// Add additional class for ng-select's dropdown panel
|
|
592
|
-
const { ngSelect } = this.mtxSelect;
|
|
593
|
-
ngSelect.classes = (ngSelect.classes || '') + ' gui-combobox';
|
|
594
|
-
}
|
|
595
590
|
writeValue(value) {
|
|
596
591
|
this.value = value;
|
|
597
592
|
this.cdr.markForCheck();
|
|
@@ -619,7 +614,7 @@ class GuiCombobox {
|
|
|
619
614
|
useExisting: forwardRef(() => GuiCombobox),
|
|
620
615
|
multi: true,
|
|
621
616
|
},
|
|
622
|
-
], viewQueries: [{ propertyName: "mtxSelect", first: true, predicate: MtxSelect, descendants: true }], ngImport: i0, template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n [appendTo]=\"appendTo\"\n [items]=\"config.options || []\"\n bindLabel=\"label\"\n bindValue=\"value\"\n [multiple]=\"config.multiple || false\"\n [addTag]=\"addTagFn\"\n [closeOnSelect]=\"!config.multiple\"\n [deselectOnClick]=\"true\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-option-tmp let-item=\"item\">\n <div class=\"ng-option-label\" [style.font-family]=\"config.useFont ? item.value : ''\">\n {{ item.label }}\n </div>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-combobox .ng-select{padding-
|
|
617
|
+
], viewQueries: [{ propertyName: "mtxSelect", first: true, predicate: MtxSelect, descendants: true }], ngImport: i0, template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n panelClass=\"gui-combobox\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n [appendTo]=\"appendTo\"\n [items]=\"config.options || []\"\n bindLabel=\"label\"\n bindValue=\"value\"\n [multiple]=\"config.multiple || false\"\n [addTag]=\"addTagFn\"\n [closeOnSelect]=\"!config.multiple\"\n [deselectOnClick]=\"true\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-option-tmp let-item=\"item\">\n <div class=\"ng-option-label\" [style.font-family]=\"config.useFont ? item.value : ''\">\n {{ item.label }}\n </div>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-combobox .mat-mdc-form-field .ng-select{padding-inline:.5rem;margin-inline:-.5rem}.gui-combobox .ng-select .ng-value-remove{font-family:math;font-size:10px}.gui-combobox .ng-select .ng-clear{font-family:math;font-size:12px}.gui-combobox .ng-select .ng-arrow{vertical-align:-1px}.gui-combobox.ng-dropdown-panel{padding:.5rem 0}.gui-combobox.ng-dropdown-panel .ng-option{padding:0 .5rem;line-height:var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height))}.gui-combobox.ng-dropdown-panel .ng-tag-label{line-height:1}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "component", type: MtxSelect, selector: "mtx-select", inputs: ["addTag", "addTagText", "appendTo", "bindLabel", "bindValue", "closeOnSelect", "clearable", "clearAllText", "clearOnBackspace", "compareWith", "panelPosition", "groupBy", "groupValue", "bufferAmount", "selectableGroup", "selectableGroupAsModel", "hideSelected", "loading", "loadingText", "markFirst", "maxSelectedItems", "multiple", "notFoundText", "searchable", "readonly", "searchFn", "searchWhileComposing", "selectOnTab", "trackByFn", "openOnEnter", "minTermLength", "editableSearchTerm", "keyDownFn", "virtualScroll", "typeToSearchText", "typeahead", "panelDisabled", "fixedPlaceholder", "preventToggleOnRightClick", "clearSearchOnAdd", "deselectOnClick", "tabIndex", "inputId", "inputAttrs", "panelClass", "items", "value", "id", "placeholder", "disabled", "required", "errorStateMatcher", "ariaLabel", "ariaLabelledby", "ariaDescribedby"], outputs: ["blur", "focus", "change", "open", "close", "search", "clear", "add", "remove", "scroll", "scrollToEnd"], exportAs: ["mtxSelect"] }, { kind: "directive", type: MtxSelectOptionTemplate, selector: "[ng-option-tmp]" }, { kind: "component", type: GuiFieldLabel, selector: "gui-field-label", inputs: ["config", "index"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
623
618
|
}
|
|
624
619
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.2", ngImport: i0, type: GuiCombobox, decorators: [{
|
|
625
620
|
type: Component,
|
|
@@ -640,7 +635,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.2", ngImpor
|
|
|
640
635
|
MtxSelect,
|
|
641
636
|
MtxSelectOptionTemplate,
|
|
642
637
|
GuiFieldLabel,
|
|
643
|
-
], template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n [appendTo]=\"appendTo\"\n [items]=\"config.options || []\"\n bindLabel=\"label\"\n bindValue=\"value\"\n [multiple]=\"config.multiple || false\"\n [addTag]=\"addTagFn\"\n [closeOnSelect]=\"!config.multiple\"\n [deselectOnClick]=\"true\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-option-tmp let-item=\"item\">\n <div class=\"ng-option-label\" [style.font-family]=\"config.useFont ? item.value : ''\">\n {{ item.label }}\n </div>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-combobox .ng-select{padding-
|
|
638
|
+
], template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n panelClass=\"gui-combobox\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n [appendTo]=\"appendTo\"\n [items]=\"config.options || []\"\n bindLabel=\"label\"\n bindValue=\"value\"\n [multiple]=\"config.multiple || false\"\n [addTag]=\"addTagFn\"\n [closeOnSelect]=\"!config.multiple\"\n [deselectOnClick]=\"true\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-option-tmp let-item=\"item\">\n <div class=\"ng-option-label\" [style.font-family]=\"config.useFont ? item.value : ''\">\n {{ item.label }}\n </div>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-combobox .mat-mdc-form-field .ng-select{padding-inline:.5rem;margin-inline:-.5rem}.gui-combobox .ng-select .ng-value-remove{font-family:math;font-size:10px}.gui-combobox .ng-select .ng-clear{font-family:math;font-size:12px}.gui-combobox .ng-select .ng-arrow{vertical-align:-1px}.gui-combobox.ng-dropdown-panel{padding:.5rem 0}.gui-combobox.ng-dropdown-panel .ng-option{padding:0 .5rem;line-height:var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height))}.gui-combobox.ng-dropdown-panel .ng-tag-label{line-height:1}\n"] }]
|
|
644
639
|
}], propDecorators: { mtxSelect: [{
|
|
645
640
|
type: ViewChild,
|
|
646
641
|
args: [MtxSelect]
|
|
@@ -956,7 +951,7 @@ class GuiFillPicker {
|
|
|
956
951
|
useExisting: forwardRef(() => GuiFillPicker),
|
|
957
952
|
multi: true,
|
|
958
953
|
},
|
|
959
|
-
], usesOnChanges: true, ngImport: i0, template: "@if (type === 'all') {\n <div class=\"gui-fill-picker-header\">\n <mat-button-toggle-group\n [(ngModel)]=\"selectedType\"\n hideSingleSelectionIndicator\n (ngModelChange)=\"onTypeChange()\"\n >\n @for (t of types; track $index) {\n <mat-button-toggle [value]=\"t.value\" [title]=\"t.label\">\n <mat-icon [svgIcon]=\"t.value\" />\n </mat-button-toggle>\n }\n </mat-button-toggle-group>\n </div>\n}\n\n<div class=\"gui-fill-picker-body\">\n @if (selectedType === 'solid') {\n <color-picker [(ngModel)]=\"fillValue.solid\" (ngModelChange)=\"onColorChange()\" />\n } @else if (selectedType === 'gradient') {\n <gradient-picker [(ngModel)]=\"fillValue.gradient\" (ngModelChange)=\"onGradientChange()\" />\n } @else if (selectedType === 'image') {\n <gui-file-uploader\n type=\"image\"\n [(ngModel)]=\"fillValue.image\"\n (ngModelChange)=\"onImageChange()\"\n />\n }\n</div>\n", styles: [".gui-fill-picker{display:block;width:15rem;border-radius:.5rem;background-color:var(--mat-expansion-container-background-color, var(--mat-sys-surface));color:var(--mat-expansion-container-text-color, var(--mat-sys-on-surface));box-shadow:inset 0 0 1px #ffffffa3,0 2px 4px #00000029,0 8px 16px #0000001f,0 0 1px #0000001f}.gui-fill-picker .color-picker{--cp-container-width: auto;--cp-container-padding: 0;--cp-container-shape: 0;--cp-container-elevation-shadow: none;--cp-container-background-color: transparent;--cp-container-text-color: var(--mat-form-field-filled-input-text-color, var(--mat-sys-on-surface))}.gui-fill-picker .gradient-picker{--gp-container-width: auto;--gp-container-vertical-padding: 0;--gp-container-margin: -4px -12px;--gp-container-shape: 0;--gp-container-elevation-shadow: none;--gp-container-background-color: transparent;--gp-container-text-color: var(--mat-form-field-filled-input-text-color, var(--mat-sys-on-surface));--gp-input-background-color: var(--mat-form-field-filled-container-color, var(--mat-sys-surface-variant));--gp-radio-button-selected-background-color: var(--mat-button-toggle-selected-state-background-color, var(--mat-sys-secondary-container));--gp-radio-button-selected-outline-color: var(--mat-button-toggle-divider-color, var(--mat-sys-outline))}.gui-fill-picker-header{padding:.375rem .375rem 0;line-height:1;--mat-button-toggle-shape: 0;--mat-button-toggle-height: 1}.gui-fill-picker-header .mat-button-toggle-group-appearance-standard{gap:.25rem;border:none}.gui-fill-picker-header .mat-button-toggle-group-appearance-standard .mat-button-toggle-appearance-standard+.mat-button-toggle-appearance-standard{border:none}.gui-fill-picker-header .mat-button-toggle-appearance-standard{border-radius:.25rem}.gui-fill-picker-header .mat-button-toggle-appearance-standard .mat-button-toggle-label-content{padding:0}.gui-fill-picker-body{padding:.75rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatButtonToggleGroup, selector: "mat-button-toggle-group", inputs: ["appearance", "name", "vertical", "value", "multiple", "disabled", "disabledInteractive", "hideSingleSelectionIndicator", "hideMultipleSelectionIndicator"], outputs: ["valueChange", "change"], exportAs: ["matButtonToggleGroup"] }, { kind: "component", type: MatButtonToggle, selector: "mat-button-toggle", inputs: ["aria-label", "aria-labelledby", "id", "name", "value", "tabIndex", "disableRipple", "appearance", "checked", "disabled", "disabledInteractive"], outputs: ["change"], exportAs: ["matButtonToggle"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: ColorPicker, selector: "color-picker", inputs: ["format", "
|
|
954
|
+
], usesOnChanges: true, ngImport: i0, template: "@if (type === 'all') {\n <div class=\"gui-fill-picker-header\">\n <mat-button-toggle-group\n [(ngModel)]=\"selectedType\"\n hideSingleSelectionIndicator\n (ngModelChange)=\"onTypeChange()\"\n >\n @for (t of types; track $index) {\n <mat-button-toggle [value]=\"t.value\" [title]=\"t.label\">\n <mat-icon [svgIcon]=\"t.value\" />\n </mat-button-toggle>\n }\n </mat-button-toggle-group>\n </div>\n}\n\n<div class=\"gui-fill-picker-body\">\n @if (selectedType === 'solid') {\n <color-picker [(ngModel)]=\"fillValue.solid\" (ngModelChange)=\"onColorChange()\" />\n } @else if (selectedType === 'gradient') {\n <gradient-picker [(ngModel)]=\"fillValue.gradient\" (ngModelChange)=\"onGradientChange()\" />\n } @else if (selectedType === 'image') {\n <gui-file-uploader\n type=\"image\"\n [(ngModel)]=\"fillValue.image\"\n (ngModelChange)=\"onImageChange()\"\n />\n }\n</div>\n", styles: [".gui-fill-picker{display:block;width:15rem;border-radius:.5rem;background-color:var(--mat-expansion-container-background-color, var(--mat-sys-surface));color:var(--mat-expansion-container-text-color, var(--mat-sys-on-surface));box-shadow:inset 0 0 1px #ffffffa3,0 2px 4px #00000029,0 8px 16px #0000001f,0 0 1px #0000001f}.gui-fill-picker .color-picker{--cp-container-width: auto;--cp-container-padding: 0;--cp-container-shape: 0;--cp-container-elevation-shadow: none;--cp-container-background-color: transparent;--cp-container-text-color: var(--mat-form-field-filled-input-text-color, var(--mat-sys-on-surface))}.gui-fill-picker .gradient-picker{--gp-container-width: auto;--gp-container-vertical-padding: 0;--gp-container-margin: -4px -12px;--gp-container-shape: 0;--gp-container-elevation-shadow: none;--gp-container-background-color: transparent;--gp-container-text-color: var(--mat-form-field-filled-input-text-color, var(--mat-sys-on-surface));--gp-input-background-color: var(--mat-form-field-filled-container-color, var(--mat-sys-surface-variant));--gp-radio-button-selected-background-color: var(--mat-button-toggle-selected-state-background-color, var(--mat-sys-secondary-container));--gp-radio-button-selected-outline-color: var(--mat-button-toggle-divider-color, var(--mat-sys-outline))}.gui-fill-picker-header{padding:.375rem .375rem 0;line-height:1;--mat-button-toggle-shape: 0;--mat-button-toggle-height: 1}.gui-fill-picker-header .mat-button-toggle-group-appearance-standard{gap:.25rem;border:none}.gui-fill-picker-header .mat-button-toggle-group-appearance-standard .mat-button-toggle-appearance-standard+.mat-button-toggle-appearance-standard{border:none}.gui-fill-picker-header .mat-button-toggle-appearance-standard{border-radius:.25rem}.gui-fill-picker-header .mat-button-toggle-appearance-standard .mat-button-toggle-label-content{padding:0}.gui-fill-picker-body{padding:.75rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatButtonToggleGroup, selector: "mat-button-toggle-group", inputs: ["appearance", "name", "vertical", "value", "multiple", "disabled", "disabledInteractive", "hideSingleSelectionIndicator", "hideMultipleSelectionIndicator"], outputs: ["valueChange", "change"], exportAs: ["matButtonToggleGroup"] }, { kind: "component", type: MatButtonToggle, selector: "mat-button-toggle", inputs: ["aria-label", "aria-labelledby", "id", "name", "value", "tabIndex", "disableRipple", "appearance", "checked", "disabled", "disabledInteractive"], outputs: ["change"], exportAs: ["matButtonToggle"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: ColorPicker, selector: "color-picker", inputs: ["format", "value", "hideAlpha", "disabled"], outputs: ["formatChange", "valueChange", "colorChange"] }, { kind: "component", type: GradientPicker, selector: "gradient-picker", inputs: ["value", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: GuiFileUploader, selector: "gui-file-uploader", inputs: ["config", "disabled", "type", "name", "accept"], outputs: ["fileChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
960
955
|
}
|
|
961
956
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.2", ngImport: i0, type: GuiFillPicker, decorators: [{
|
|
962
957
|
type: Component,
|
|
@@ -1067,11 +1062,6 @@ class GuiImageSelect {
|
|
|
1067
1062
|
this.onChange = () => { };
|
|
1068
1063
|
this.onTouched = () => { };
|
|
1069
1064
|
}
|
|
1070
|
-
ngAfterViewInit() {
|
|
1071
|
-
// Add additional class for ng-select's dropdown panel
|
|
1072
|
-
const { ngSelect } = this.mtxSelect;
|
|
1073
|
-
ngSelect.classes = (ngSelect.classes || '') + ' gui-image-select';
|
|
1074
|
-
}
|
|
1075
1065
|
writeValue(value) {
|
|
1076
1066
|
this.value = value;
|
|
1077
1067
|
this.cdr.markForCheck();
|
|
@@ -1096,7 +1086,7 @@ class GuiImageSelect {
|
|
|
1096
1086
|
useExisting: forwardRef(() => GuiImageSelect),
|
|
1097
1087
|
multi: true,
|
|
1098
1088
|
},
|
|
1099
|
-
], viewQueries: [{ propertyName: "mtxSelect", first: true, predicate: MtxSelect, descendants: true }], ngImport: i0, template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n [items]=\"config.options || []\"\n [appendTo]=\"appendTo\"\n bindValue=\"value\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-label-tmp let-opt=\"item\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n <ng-template ng-option-tmp let-opt=\"item\" let-index=\"index\" let-search=\"searchTerm\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-image-select.ng-dropdown-panel .ng-
|
|
1089
|
+
], viewQueries: [{ propertyName: "mtxSelect", first: true, predicate: MtxSelect, descendants: true }], ngImport: i0, template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n panelClass=\"gui-image-select\"\n [items]=\"config.options || []\"\n [appendTo]=\"appendTo\"\n bindValue=\"value\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-label-tmp let-opt=\"item\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n <ng-template ng-option-tmp let-opt=\"item\" let-index=\"index\" let-search=\"searchTerm\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-image-select.ng-dropdown-panel .ng-option img,.gui-image-select .ng-select .ng-value img{height:100%;max-width:7.5rem;object-fit:contain;border-radius:.25rem;background-color:var(--mat-option-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.gui-image-select{--mat-form-field-container-vertical-padding: 0}.gui-image-select .ng-select{padding:0 .5rem;margin:0 -.5rem}.gui-image-select .ng-select .ng-value-container{height:4rem}.gui-image-select .ng-select .ng-value{display:inline-flex;align-items:center;gap:.5rem;height:100%;padding:.5rem 0}.gui-image-select .ng-select .ng-clear{font-family:math;font-size:12px}.gui-image-select .ng-select .ng-arrow{vertical-align:-1px}.gui-image-select.ng-dropdown-panel .ng-option{display:flex;align-items:center;gap:.5rem;height:4rem;padding:.5rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "component", type: MtxSelect, selector: "mtx-select", inputs: ["addTag", "addTagText", "appendTo", "bindLabel", "bindValue", "closeOnSelect", "clearable", "clearAllText", "clearOnBackspace", "compareWith", "panelPosition", "groupBy", "groupValue", "bufferAmount", "selectableGroup", "selectableGroupAsModel", "hideSelected", "loading", "loadingText", "markFirst", "maxSelectedItems", "multiple", "notFoundText", "searchable", "readonly", "searchFn", "searchWhileComposing", "selectOnTab", "trackByFn", "openOnEnter", "minTermLength", "editableSearchTerm", "keyDownFn", "virtualScroll", "typeToSearchText", "typeahead", "panelDisabled", "fixedPlaceholder", "preventToggleOnRightClick", "clearSearchOnAdd", "deselectOnClick", "tabIndex", "inputId", "inputAttrs", "panelClass", "items", "value", "id", "placeholder", "disabled", "required", "errorStateMatcher", "ariaLabel", "ariaLabelledby", "ariaDescribedby"], outputs: ["blur", "focus", "change", "open", "close", "search", "clear", "add", "remove", "scroll", "scrollToEnd"], exportAs: ["mtxSelect"] }, { kind: "directive", type: MtxSelectLabelTemplate, selector: "[ng-label-tmp]" }, { kind: "directive", type: MtxSelectOptionTemplate, selector: "[ng-option-tmp]" }, { kind: "component", type: GuiFieldLabel, selector: "gui-field-label", inputs: ["config", "index"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1100
1090
|
}
|
|
1101
1091
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.2", ngImport: i0, type: GuiImageSelect, decorators: [{
|
|
1102
1092
|
type: Component,
|
|
@@ -1118,7 +1108,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.2", ngImpor
|
|
|
1118
1108
|
MtxSelectLabelTemplate,
|
|
1119
1109
|
MtxSelectOptionTemplate,
|
|
1120
1110
|
GuiFieldLabel,
|
|
1121
|
-
], template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n [items]=\"config.options || []\"\n [appendTo]=\"appendTo\"\n bindValue=\"value\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-label-tmp let-opt=\"item\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n <ng-template ng-option-tmp let-opt=\"item\" let-index=\"index\" let-search=\"searchTerm\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-image-select.ng-dropdown-panel .ng-
|
|
1111
|
+
], template: "<mat-form-field>\n @if (config.prefix) {\n <span matPrefix>{{ config.prefix }}</span>\n }\n <mtx-select\n panelClass=\"gui-image-select\"\n [items]=\"config.options || []\"\n [appendTo]=\"appendTo\"\n bindValue=\"value\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n [placeholder]=\"config.placeholder || ''\"\n (change)=\"onValueChange()\"\n >\n <ng-template ng-label-tmp let-opt=\"item\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n <ng-template ng-option-tmp let-opt=\"item\" let-index=\"index\" let-search=\"searchTerm\">\n <img [src]=\"opt.src\" [alt]=\"opt.label\" />\n <span>{{ opt.label }}</span>\n </ng-template>\n </mtx-select>\n @if (config.suffix) {\n <span matSuffix>{{ config.suffix }}</span>\n }\n @if (config.parentType === 'inline') {\n <mat-hint>\n <gui-field-label [config]=\"config\" />\n </mat-hint>\n }\n</mat-form-field>\n", styles: [".gui-image-select.ng-dropdown-panel .ng-option img,.gui-image-select .ng-select .ng-value img{height:100%;max-width:7.5rem;object-fit:contain;border-radius:.25rem;background-color:var(--mat-option-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.gui-image-select{--mat-form-field-container-vertical-padding: 0}.gui-image-select .ng-select{padding:0 .5rem;margin:0 -.5rem}.gui-image-select .ng-select .ng-value-container{height:4rem}.gui-image-select .ng-select .ng-value{display:inline-flex;align-items:center;gap:.5rem;height:100%;padding:.5rem 0}.gui-image-select .ng-select .ng-clear{font-family:math;font-size:12px}.gui-image-select .ng-select .ng-arrow{vertical-align:-1px}.gui-image-select.ng-dropdown-panel .ng-option{display:flex;align-items:center;gap:.5rem;height:4rem;padding:.5rem}\n"] }]
|
|
1122
1112
|
}], propDecorators: { mtxSelect: [{
|
|
1123
1113
|
type: ViewChild,
|
|
1124
1114
|
args: [MtxSelect]
|