@yourself.create/ngx-form-designer 0.0.4 → 0.0.6
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/uch-web-ngx-form-designer.mjs +2000 -1214
- package/fesm2022/uch-web-ngx-form-designer.mjs.map +1 -1
- package/lib/data/data-provider.d.ts +9 -0
- package/lib/form-core/models.d.ts +3 -13
- package/lib/form-designer/data-panel/data-panel.component.d.ts +4 -2
- package/lib/form-designer/designer-state.service.d.ts +34 -0
- package/lib/form-designer/dynamic-properties/dynamic-properties.component.d.ts +3 -5
- package/lib/form-designer/inspector-sections/inspector-transform-section.component.d.ts +12 -0
- package/lib/form-designer/layout-canvas.component.d.ts +11 -1
- package/lib/form-designer/properties-panel.component.d.ts +4 -0
- package/lib/form-renderer/json-form-renderer.component.d.ts +27 -2
- package/lib/form-renderer/layout-node.component.d.ts +10 -0
- package/lib/widgets/field-widgets/select/select-widget.component.d.ts +12 -2
- package/lib/widgets/widget-definition.d.ts +1 -1
- package/package.json +1 -1
|
@@ -52,15 +52,24 @@ export declare class DefaultDataProvider extends DataProvider {
|
|
|
52
52
|
resolveValue(field: FieldSchema, value: unknown): Promise<string>;
|
|
53
53
|
private getRawRows;
|
|
54
54
|
private getGlobalRows;
|
|
55
|
+
private getOptionRowContexts;
|
|
56
|
+
private resolveCollectionRowContexts;
|
|
55
57
|
private resolveCollectionRows;
|
|
58
|
+
private extractRowContexts;
|
|
56
59
|
private extractRows;
|
|
57
60
|
private selectScalarRow;
|
|
61
|
+
private selectOptionContext;
|
|
58
62
|
private applyRowFilters;
|
|
63
|
+
private applyOptionRowFilters;
|
|
64
|
+
private matchesRowFilters;
|
|
59
65
|
private resolveFilters;
|
|
60
66
|
private resolveFilterValue;
|
|
61
67
|
private toOptionValue;
|
|
62
68
|
private toRowRecord;
|
|
63
69
|
private mapRowToOption;
|
|
70
|
+
private mapContextToOption;
|
|
71
|
+
private resolveOptionLabelPrefix;
|
|
72
|
+
private formatOptionLabel;
|
|
64
73
|
private getRuntimeOptions;
|
|
65
74
|
private shouldSuppressRemoteAccess;
|
|
66
75
|
private shouldUseLocalResolution;
|
|
@@ -114,12 +114,9 @@ export interface FieldSchema {
|
|
|
114
114
|
appearance?: 'outline' | 'fill' | 'standard';
|
|
115
115
|
readonly?: boolean;
|
|
116
116
|
disabled?: boolean;
|
|
117
|
-
prefixIcon?: string;
|
|
118
|
-
suffixIcon?: string;
|
|
119
117
|
html5?: Html5ValidationProps;
|
|
120
118
|
validation?: ValidationRule[];
|
|
121
119
|
dependencies?: DependencyRule[];
|
|
122
|
-
conditionalVisibility?: ConditionalVisibility;
|
|
123
120
|
rules?: FormRule[];
|
|
124
121
|
dataConfig?: DataSourceConfig;
|
|
125
122
|
events?: WidgetEventBinding[];
|
|
@@ -142,8 +139,9 @@ export interface DataSourceConfig {
|
|
|
142
139
|
contextKey?: string;
|
|
143
140
|
datasourceId?: string;
|
|
144
141
|
rowsPath?: string;
|
|
145
|
-
|
|
146
|
-
|
|
142
|
+
formatNumericOptionLabels?: boolean;
|
|
143
|
+
optionLabelPrefixPath?: string;
|
|
144
|
+
optionLabelPrefixFieldId?: string;
|
|
147
145
|
rowSelectionMode?: 'first' | 'selected';
|
|
148
146
|
selectionFieldId?: string;
|
|
149
147
|
selectionMatchPath?: string;
|
|
@@ -285,11 +283,6 @@ export interface DataDependencyBinding {
|
|
|
285
283
|
fieldId: string;
|
|
286
284
|
paramKey: string;
|
|
287
285
|
}
|
|
288
|
-
export interface ConditionalVisibility {
|
|
289
|
-
fieldName: string;
|
|
290
|
-
operator: 'equals' | 'notEquals' | 'contains' | 'isEmpty' | 'isNotEmpty' | 'greaterThan' | 'lessThan';
|
|
291
|
-
value?: unknown;
|
|
292
|
-
}
|
|
293
286
|
export interface OptionSchema {
|
|
294
287
|
label: string;
|
|
295
288
|
value: string | number;
|
|
@@ -365,7 +358,4 @@ export interface FormSchema {
|
|
|
365
358
|
fields: FieldSchema[];
|
|
366
359
|
layout: LayoutNode;
|
|
367
360
|
ui?: FormUIConfig;
|
|
368
|
-
submitButtonText?: string;
|
|
369
|
-
resetButtonText?: string;
|
|
370
|
-
showResetButton?: boolean;
|
|
371
361
|
}
|
|
@@ -32,6 +32,8 @@ export declare class DataPanelComponent implements OnChanges {
|
|
|
32
32
|
selectionFieldId?: string;
|
|
33
33
|
selectionMatchPath?: string;
|
|
34
34
|
childRowsPath?: string;
|
|
35
|
+
formatNumericOptionLabels: boolean;
|
|
36
|
+
optionLabelPrefixPath?: string;
|
|
35
37
|
rootPathOptions: string[];
|
|
36
38
|
rowPathOptions: string[];
|
|
37
39
|
staticValue?: any;
|
|
@@ -97,6 +99,7 @@ export declare class DataPanelComponent implements OnChanges {
|
|
|
97
99
|
showRowsPathControls(): boolean;
|
|
98
100
|
showScalarMappingControls(): boolean;
|
|
99
101
|
showOptionMappingControls(): boolean;
|
|
102
|
+
showOptionLabelFormattingControls(): boolean;
|
|
100
103
|
showStaticOptionsEditor(): boolean;
|
|
101
104
|
showStaticScalarEditor(): boolean;
|
|
102
105
|
staticScalarLabel(): string;
|
|
@@ -107,8 +110,7 @@ export declare class DataPanelComponent implements OnChanges {
|
|
|
107
110
|
availableRowPaths(): string[];
|
|
108
111
|
availableParentRowPaths(): string[];
|
|
109
112
|
availableChildCollectionPaths(): string[];
|
|
110
|
-
private
|
|
111
|
-
private shouldPersistStructuredValuePath;
|
|
113
|
+
private shouldPersistOptionLabelFormatting;
|
|
112
114
|
private usesOptionMapping;
|
|
113
115
|
private scalarTargetPath;
|
|
114
116
|
private readScalarTargetValue;
|
|
@@ -30,6 +30,7 @@ export interface DesignerFieldMoveOptions {
|
|
|
30
30
|
position?: 'before' | 'after';
|
|
31
31
|
index?: number;
|
|
32
32
|
}
|
|
33
|
+
type RelativeInsertPosition = 'before' | 'after';
|
|
33
34
|
interface DragDropEventLike {
|
|
34
35
|
previousContainer: unknown;
|
|
35
36
|
container: unknown;
|
|
@@ -69,6 +70,10 @@ export declare class DesignerStateService {
|
|
|
69
70
|
fields: FieldSchema[];
|
|
70
71
|
scopePath: string[];
|
|
71
72
|
} | null>;
|
|
73
|
+
readonly pendingFieldInsert: import("@angular/core").WritableSignal<{
|
|
74
|
+
referenceFieldId: string;
|
|
75
|
+
position: RelativeInsertPosition;
|
|
76
|
+
} | null>;
|
|
72
77
|
private readonly history;
|
|
73
78
|
private readonly historyIndex;
|
|
74
79
|
private readonly historyLength;
|
|
@@ -78,6 +83,16 @@ export declare class DesignerStateService {
|
|
|
78
83
|
constructor();
|
|
79
84
|
readonly layoutIndex: import("@angular/core").Signal<LayoutIndex>;
|
|
80
85
|
readonly selectedNode: import("@angular/core").Signal<LayoutNode | null>;
|
|
86
|
+
readonly selectedEntry: import("@angular/core").Signal<LayoutIndexEntry | null>;
|
|
87
|
+
readonly selectedColumnId: import("@angular/core").Signal<string | null>;
|
|
88
|
+
readonly selectedRowId: import("@angular/core").Signal<string | null>;
|
|
89
|
+
readonly canInsertColumnBeforeSelection: import("@angular/core").Signal<boolean>;
|
|
90
|
+
readonly canInsertColumnAfterSelection: import("@angular/core").Signal<boolean>;
|
|
91
|
+
readonly canInsertRowInSelectedColumn: import("@angular/core").Signal<boolean>;
|
|
92
|
+
readonly canInsertRowBeforeSelection: import("@angular/core").Signal<boolean>;
|
|
93
|
+
readonly canInsertRowAfterSelection: import("@angular/core").Signal<boolean>;
|
|
94
|
+
readonly canArmFieldInsertBeforeSelection: import("@angular/core").Signal<boolean>;
|
|
95
|
+
readonly canArmFieldInsertAfterSelection: import("@angular/core").Signal<boolean>;
|
|
81
96
|
readonly selectedField: import("@angular/core").Signal<FieldSchema | null>;
|
|
82
97
|
updateSchema(schema: FormSchema): void;
|
|
83
98
|
setFlavor(flavor: DesignerFlavor): void;
|
|
@@ -88,6 +103,8 @@ export declare class DesignerStateService {
|
|
|
88
103
|
selectNode(id: string | null): void;
|
|
89
104
|
toggleNodeSelection(id: string): void;
|
|
90
105
|
isNodeSelected(nodeId: string): boolean;
|
|
106
|
+
isSelectionRowAncestor(nodeId: string): boolean;
|
|
107
|
+
isSelectionColumnAncestor(nodeId: string): boolean;
|
|
91
108
|
composeScopedNodeId(scopePath: string[], nodeId: string): string;
|
|
92
109
|
getSelectedScopeFields(): FieldSchema[];
|
|
93
110
|
isSelectionInScope(scopePath: string[]): boolean;
|
|
@@ -117,6 +134,13 @@ export declare class DesignerStateService {
|
|
|
117
134
|
private insertNodeIntoLayout;
|
|
118
135
|
handleDrop(event: DragDropEventLike, targetColId: string): void;
|
|
119
136
|
pushField(widgetDef: WidgetDefinition): void;
|
|
137
|
+
insertColumnBeforeSelection(): void;
|
|
138
|
+
insertColumnAfterSelection(): void;
|
|
139
|
+
insertRowBeforeSelection(): void;
|
|
140
|
+
insertRowAfterSelection(): void;
|
|
141
|
+
insertRowInSelectedColumn(): void;
|
|
142
|
+
armFieldInsertBeforeSelection(): void;
|
|
143
|
+
armFieldInsertAfterSelection(): void;
|
|
120
144
|
insertField(options: DesignerFieldInsertOptions): DesignerFieldInsertResult | null;
|
|
121
145
|
deleteFields(fieldIds: string[]): void;
|
|
122
146
|
moveField(fieldId: string, options: DesignerFieldMoveOptions): boolean;
|
|
@@ -170,10 +194,19 @@ export declare class DesignerStateService {
|
|
|
170
194
|
*/
|
|
171
195
|
private updateNodeInTree;
|
|
172
196
|
private resolveEntry;
|
|
197
|
+
private findSelectionColumnEntry;
|
|
198
|
+
private findSelectionRowEntry;
|
|
199
|
+
private findAncestorEntryByType;
|
|
173
200
|
private resolveSchemaAtScope;
|
|
174
201
|
private findFieldByIdInScope;
|
|
175
202
|
private resolveInsertionScopePath;
|
|
176
203
|
private resolveTargetColumnForFieldInsert;
|
|
204
|
+
private resolveColumnInsertTarget;
|
|
205
|
+
private insertColumnRelativeToSelection;
|
|
206
|
+
private resolveRelativeRowInsertTarget;
|
|
207
|
+
private insertRowRelativeToSelection;
|
|
208
|
+
private armFieldInsertForSelection;
|
|
209
|
+
private getSelectedFieldReference;
|
|
177
210
|
private resolveFieldWidgetDefinition;
|
|
178
211
|
private normalizeFieldTypeAlias;
|
|
179
212
|
private normalizeLookupValue;
|
|
@@ -188,6 +221,7 @@ export declare class DesignerStateService {
|
|
|
188
221
|
private clampIndex;
|
|
189
222
|
private isLayoutNode;
|
|
190
223
|
private detachNode;
|
|
224
|
+
private pruneEmptyRows;
|
|
191
225
|
private findWidgetByRefId;
|
|
192
226
|
private findParentCol;
|
|
193
227
|
private removeWidgetByRefId;
|
|
@@ -11,7 +11,7 @@ export declare class DynamicPropertiesComponent implements OnChanges {
|
|
|
11
11
|
onPropertyChange?: () => void;
|
|
12
12
|
private readonly designerCtx;
|
|
13
13
|
protected readonly validatorTypeOptions: NativeSelectOption<string>[];
|
|
14
|
-
protected readonly
|
|
14
|
+
protected readonly builtinValidatorOptions: NativeSelectOption<string>[];
|
|
15
15
|
get properties(): PropertySection[];
|
|
16
16
|
getFieldReferenceCandidates(field: PropertyField): FieldSchema[];
|
|
17
17
|
fieldReferenceOptions(field: PropertyField): NativeSelectOption<string>[];
|
|
@@ -91,10 +91,8 @@ export declare class DynamicPropertiesComponent implements OnChanges {
|
|
|
91
91
|
addValidator(path: string): void;
|
|
92
92
|
removeValidator(path: string, index: number): void;
|
|
93
93
|
updateValidator(path: string, index: number, field: string, value: any): void;
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
disableConditional(path: string): void;
|
|
97
|
-
updateConditional(path: string, field: string, value: any): void;
|
|
94
|
+
private createDefaultValidationRule;
|
|
95
|
+
private defaultValidationMessage;
|
|
98
96
|
static ɵfac: i0.ɵɵFactoryDeclaration<DynamicPropertiesComponent, never>;
|
|
99
97
|
static ɵcmp: i0.ɵɵComponentDeclaration<DynamicPropertiesComponent, "app-dynamic-properties", never, { "onPropertyChange": { "alias": "onPropertyChange"; "required": false; }; "config": { "alias": "config"; "required": false; }; "readOnly": { "alias": "readOnly"; "required": false; }; "includeSections": { "alias": "includeSections"; "required": false; }; "excludeSections": { "alias": "excludeSections"; "required": false; }; "allFields": { "alias": "allFields"; "required": false; }; }, { "configChange": "configChange"; }, never, never, true, never>;
|
|
100
98
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { StyleTokenSet } from '../../form-core/models';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
type TransformKey = 'transformX' | 'transformY' | 'transformZ' | 'rotate' | 'scale';
|
|
4
|
+
export declare class InspectorTransformSectionComponent {
|
|
5
|
+
readonly style: import("@angular/core").InputSignal<Partial<StyleTokenSet>>;
|
|
6
|
+
readonly styleChange: import("@angular/core").OutputEmitterRef<Partial<StyleTokenSet>>;
|
|
7
|
+
protected numberValue(key: TransformKey, fallback: number): number;
|
|
8
|
+
protected updateTransform(key: TransformKey, value: unknown): void;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<InspectorTransformSectionComponent, never>;
|
|
10
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<InspectorTransformSectionComponent, "inspector-transform-section", never, { "style": { "alias": "style"; "required": false; "isSignal": true; }; }, { "styleChange": "styleChange"; }, never, never, true, never>;
|
|
11
|
+
}
|
|
12
|
+
export {};
|
|
@@ -4,7 +4,7 @@ import * as i0 from "@angular/core";
|
|
|
4
4
|
export declare class LayoutCanvasComponent implements AfterViewInit {
|
|
5
5
|
state: DesignerStateService;
|
|
6
6
|
private readonly destroyRef;
|
|
7
|
-
readonly previewMode: import("@angular/core").InputSignal<"
|
|
7
|
+
readonly previewMode: import("@angular/core").InputSignal<"route" | "overlay">;
|
|
8
8
|
readonly previewRequested: import("@angular/core").OutputEmitterRef<void>;
|
|
9
9
|
fileInput: ElementRef<HTMLInputElement>;
|
|
10
10
|
root: ElementRef<HTMLDivElement>;
|
|
@@ -20,6 +20,7 @@ export declare class LayoutCanvasComponent implements AfterViewInit {
|
|
|
20
20
|
readonly showLiveSchemaEditor: import("@angular/core").WritableSignal<boolean>;
|
|
21
21
|
readonly liveSchemaEditorText: import("@angular/core").WritableSignal<string>;
|
|
22
22
|
readonly liveSchemaEditorError: import("@angular/core").WritableSignal<string>;
|
|
23
|
+
readonly openContextSubmenu: import("@angular/core").WritableSignal<"insert" | null>;
|
|
23
24
|
readonly liveSchemaEditorOptions: Record<string, unknown>;
|
|
24
25
|
private readonly pageBaseSize;
|
|
25
26
|
private readonly minZoom;
|
|
@@ -35,6 +36,15 @@ export declare class LayoutCanvasComponent implements AfterViewInit {
|
|
|
35
36
|
closeContextMenu(): void;
|
|
36
37
|
groupSelected(): void;
|
|
37
38
|
ungroupSelected(): void;
|
|
39
|
+
hasStructuralInsertActions(): boolean;
|
|
40
|
+
toggleInsertSubmenu(): void;
|
|
41
|
+
insertColumnBeforeSelection(): void;
|
|
42
|
+
insertColumnAfterSelection(): void;
|
|
43
|
+
insertRowInSelectedColumn(): void;
|
|
44
|
+
insertRowBeforeSelection(): void;
|
|
45
|
+
insertRowAfterSelection(): void;
|
|
46
|
+
armFieldInsertBeforeSelection(): void;
|
|
47
|
+
armFieldInsertAfterSelection(): void;
|
|
38
48
|
onCanvasContextMenu(event: MouseEvent): void;
|
|
39
49
|
cut(): void;
|
|
40
50
|
copy(): void;
|
|
@@ -3,9 +3,12 @@ import { DesignerStateService } from './designer-state.service';
|
|
|
3
3
|
import { WidgetDefinition, DataBindingContract } from '../widgets/widget-definition';
|
|
4
4
|
import { WidgetNode, FieldSchema, FormRule, StyleTokenSet } from '../form-core/models';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
+
type LayoutInspectorTab = 'Style' | 'Settings';
|
|
6
7
|
export declare class PropertiesPanelComponent {
|
|
7
8
|
state: DesignerStateService;
|
|
8
9
|
private injector;
|
|
10
|
+
protected readonly layoutInspectorTabs: readonly LayoutInspectorTab[];
|
|
11
|
+
protected readonly activeLayoutInspectorTab: import("@angular/core").WritableSignal<LayoutInspectorTab>;
|
|
9
12
|
protected readonly spacingOptions: {
|
|
10
13
|
label: string;
|
|
11
14
|
value: string;
|
|
@@ -79,3 +82,4 @@ export declare class PropertiesPanelComponent {
|
|
|
79
82
|
static ɵfac: i0.ɵɵFactoryDeclaration<PropertiesPanelComponent, never>;
|
|
80
83
|
static ɵcmp: i0.ɵɵComponentDeclaration<PropertiesPanelComponent, "app-properties-panel", never, {}, {}, never, never, true, never>;
|
|
81
84
|
}
|
|
85
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OnInit, OnChanges, SimpleChanges, EventEmitter, OnDestroy } from '@angular/core';
|
|
2
|
-
import { DesignerEventApiDefinition, FieldDisplayLabel, FormSchema, UploadedFileRef, WidgetEventApiExecutor } from '../form-core/models';
|
|
2
|
+
import { DesignerEventApiDefinition, FieldSchema, FieldDisplayLabel, FormSchema, UploadedFileRef, WidgetEventApiExecutor } from '../form-core/models';
|
|
3
3
|
import { FormEngine } from '../form-core/form-engine';
|
|
4
4
|
import { DesignerStateService } from '../form-designer/designer-state.service';
|
|
5
5
|
import { type FieldDataAccessMap, type RuntimeFieldDataAccessApi } from '../data/runtime-field-data-access-registry.service';
|
|
@@ -7,6 +7,7 @@ import * as i0 from "@angular/core";
|
|
|
7
7
|
export interface FormFieldValue {
|
|
8
8
|
fieldName: string;
|
|
9
9
|
fieldValue: unknown;
|
|
10
|
+
fieldType?: FieldSchema['type'];
|
|
10
11
|
fieldLabel?: FieldDisplayLabel;
|
|
11
12
|
fileType?: string | string[];
|
|
12
13
|
data?: string | string[];
|
|
@@ -17,6 +18,24 @@ export type CombinedFormValues = Record<string, FormFieldValue | FormValueMap>;
|
|
|
17
18
|
export interface FormValidationResult {
|
|
18
19
|
errors: Record<string, string[]>;
|
|
19
20
|
isValid: boolean;
|
|
21
|
+
fields?: Record<string, FormFieldValidationState>;
|
|
22
|
+
}
|
|
23
|
+
export interface FormFieldValidationState {
|
|
24
|
+
fieldId: string;
|
|
25
|
+
fieldName: string;
|
|
26
|
+
label?: string;
|
|
27
|
+
visible: boolean;
|
|
28
|
+
required: boolean;
|
|
29
|
+
valid: boolean;
|
|
30
|
+
errors: string[];
|
|
31
|
+
validators: FormFieldValidatorState[];
|
|
32
|
+
}
|
|
33
|
+
export interface FormFieldValidatorState {
|
|
34
|
+
name: string;
|
|
35
|
+
source: 'required' | 'html5' | 'custom';
|
|
36
|
+
active: boolean;
|
|
37
|
+
value?: unknown;
|
|
38
|
+
message?: string;
|
|
20
39
|
}
|
|
21
40
|
export interface FormSubmitResult {
|
|
22
41
|
values: FormValueMap;
|
|
@@ -79,7 +98,12 @@ export declare class JsonFormRendererComponent implements OnInit, OnChanges, OnD
|
|
|
79
98
|
private inferDatasourceValueType;
|
|
80
99
|
onNodeSelect(nodeId: string): void;
|
|
81
100
|
onSubmit(event: Event): Promise<void>;
|
|
82
|
-
|
|
101
|
+
getValidationResult(revalidate?: boolean): FormValidationResult;
|
|
102
|
+
private buildFieldValidationState;
|
|
103
|
+
private describeFieldValidators;
|
|
104
|
+
private hasRequiredValidation;
|
|
105
|
+
private isValidationRuleActive;
|
|
106
|
+
private isValidationEmpty;
|
|
83
107
|
private uploadPendingFiles;
|
|
84
108
|
private uploadPendingFilesInSchema;
|
|
85
109
|
private getPendingFiles;
|
|
@@ -93,6 +117,7 @@ export declare class JsonFormRendererComponent implements OnInit, OnChanges, OnD
|
|
|
93
117
|
private readFileBytes;
|
|
94
118
|
private encodeBytesToBase64;
|
|
95
119
|
private toSingleOrList;
|
|
120
|
+
private normalizeFileFieldSubmitValue;
|
|
96
121
|
private getUploadedFileRefs;
|
|
97
122
|
private buildFieldLabelMetadata;
|
|
98
123
|
private mergeFileMetadata;
|
|
@@ -50,6 +50,8 @@ export declare class LayoutNodeComponent implements OnInit, OnChanges, OnDestroy
|
|
|
50
50
|
private static readonly MAX_COLUMN_SPAN;
|
|
51
51
|
constructor(_widgetDefs: WidgetDefinition[][], designerState: DesignerStateService, cdr: ChangeDetectorRef, el: ElementRef);
|
|
52
52
|
get isSelected(): boolean;
|
|
53
|
+
get isRowSelectionAncestor(): boolean;
|
|
54
|
+
get isColumnSelectionAncestor(): boolean;
|
|
53
55
|
get isResizing(): boolean;
|
|
54
56
|
protected isNodeSelected(nodeId: string): boolean;
|
|
55
57
|
onWidgetClick(e: Event): void;
|
|
@@ -65,6 +67,11 @@ export declare class LayoutNodeComponent implements OnInit, OnChanges, OnDestroy
|
|
|
65
67
|
duplicateNode(): void;
|
|
66
68
|
insertRowInColumn(): void;
|
|
67
69
|
wrapWidgetInRow(): void;
|
|
70
|
+
decreaseSelectedColumnSpan(): void;
|
|
71
|
+
increaseSelectedColumnSpan(): void;
|
|
72
|
+
canDecreaseSelectedColumnSpan(): boolean;
|
|
73
|
+
canIncreaseSelectedColumnSpan(): boolean;
|
|
74
|
+
getSelectedColumnSpanLabel(): string;
|
|
68
75
|
getNodeTypeLabel(): string;
|
|
69
76
|
ngOnInit(): void;
|
|
70
77
|
ngOnDestroy(): void;
|
|
@@ -94,6 +101,9 @@ export declare class LayoutNodeComponent implements OnInit, OnChanges, OnDestroy
|
|
|
94
101
|
asCol(node: LayoutNode): ColumnNode;
|
|
95
102
|
private applyVerticalResize;
|
|
96
103
|
private applyColumnResize;
|
|
104
|
+
private adjustSelectedColumnSpan;
|
|
105
|
+
private getSelectedColumnSpan;
|
|
106
|
+
private getSelectedColumnEntry;
|
|
97
107
|
getColClasses(node: LayoutNode): string;
|
|
98
108
|
getColContainerClasses(node: LayoutNode): string;
|
|
99
109
|
private getEffectiveSpan;
|
|
@@ -16,12 +16,14 @@ export declare class SelectWidgetComponent implements OnInit, OnDestroy {
|
|
|
16
16
|
loading: boolean;
|
|
17
17
|
loadError: string | null;
|
|
18
18
|
options: OptionSchema[];
|
|
19
|
+
private rawOptions;
|
|
19
20
|
protected readonly searchTerms$: Subject<string>;
|
|
20
21
|
private requestId;
|
|
21
22
|
private currentSearchTerm;
|
|
22
23
|
private runtimeManagedField;
|
|
23
24
|
private runtimeOptionsLoaded;
|
|
24
25
|
private readonly dependencyValueSnapshot;
|
|
26
|
+
private readonly displayDependencyValueSnapshot;
|
|
25
27
|
private cachedStyleSource;
|
|
26
28
|
private cachedWrapperStyles;
|
|
27
29
|
private cachedControlCssVars;
|
|
@@ -65,12 +67,14 @@ export declare class SelectWidgetComponent implements OnInit, OnDestroy {
|
|
|
65
67
|
onPillMouseDown(event: MouseEvent): void;
|
|
66
68
|
onPillClick(): void;
|
|
67
69
|
private getDependencyFieldIds;
|
|
70
|
+
private getDisplayDependencyFieldIds;
|
|
68
71
|
private toCssVarMap;
|
|
69
72
|
private loadOptions;
|
|
70
73
|
private syncEnabledState;
|
|
71
74
|
private ensureRuntimeOptionsLoaded;
|
|
72
|
-
private
|
|
73
|
-
private
|
|
75
|
+
private seedValueSnapshotFromValues;
|
|
76
|
+
private resolveFieldNames;
|
|
77
|
+
private haveFieldValuesChanged;
|
|
74
78
|
private hasSelectedValue;
|
|
75
79
|
private handleConfigChange;
|
|
76
80
|
private getConfigSignature;
|
|
@@ -78,6 +82,11 @@ export declare class SelectWidgetComponent implements OnInit, OnDestroy {
|
|
|
78
82
|
private stringifyValue;
|
|
79
83
|
private getAccessibleLabel;
|
|
80
84
|
private syncTemplateBindingCaches;
|
|
85
|
+
private setOptionsFromRaw;
|
|
86
|
+
private applyDisplayFormatting;
|
|
87
|
+
private formatOptionLabel;
|
|
88
|
+
private resolveOptionLabelPrefix;
|
|
89
|
+
private formatNumericLabel;
|
|
81
90
|
private toSafeNonNegativeInt;
|
|
82
91
|
private areApiCallsSuppressed;
|
|
83
92
|
private withSelectedValueFallbackOptions;
|
|
@@ -87,6 +96,7 @@ export declare class SelectWidgetComponent implements OnInit, OnDestroy {
|
|
|
87
96
|
private hasMeaningfulValue;
|
|
88
97
|
private syncStoredFieldLabel;
|
|
89
98
|
private getStoredFieldLabel;
|
|
99
|
+
private shouldUseStoredFallbackLabel;
|
|
90
100
|
private setStoredFieldLabel;
|
|
91
101
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectWidgetComponent, never>;
|
|
92
102
|
static ɵcmp: i0.ɵɵComponentDeclaration<SelectWidgetComponent, "app-select-widget", never, { "config": { "alias": "config"; "required": false; }; "engine": { "alias": "engine"; "required": false; }; "control": { "alias": "control"; "required": false; }; }, {}, never, never, true, never>;
|
|
@@ -8,7 +8,7 @@ export interface WidgetConfig {
|
|
|
8
8
|
required?: boolean;
|
|
9
9
|
[key: string]: any;
|
|
10
10
|
}
|
|
11
|
-
export type PropertyFieldType = 'text' | 'textarea' | 'number' | 'select' | 'checkbox' | 'slide-toggle' | 'color' | 'color-swatch' | '
|
|
11
|
+
export type PropertyFieldType = 'text' | 'textarea' | 'number' | 'select' | 'checkbox' | 'slide-toggle' | 'color' | 'color-swatch' | 'padding' | 'margin' | 'shadow' | 'border' | 'options-editor' | 'validators-editor' | 'custom' | 'field-reference' | 'dimension' | 'edge-box' | 'box-model' | 'range-number' | 'select-icon';
|
|
12
12
|
export interface PropertyField {
|
|
13
13
|
key: string;
|
|
14
14
|
type: PropertyFieldType;
|