@docupace/ihub-config 1.1.20-alpha.0 → 1.1.21-admin.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/dist/config-extension.d.ts +12 -0
- package/dist/config-extension.d.ts.map +1 -1
- package/dist/config-extension.js +4 -0
- package/dist/config-extension.js.map +1 -1
- package/dist/config-service.d.ts +9 -2
- package/dist/config-service.d.ts.map +1 -1
- package/dist/config-service.js +77 -16
- package/dist/config-service.js.map +1 -1
- package/dist/mappers/config-mapper.d.ts.map +1 -1
- package/dist/mappers/config-mapper.js +2 -0
- package/dist/mappers/config-mapper.js.map +1 -1
- package/dist/model/graphs/config/fields.graphql +42 -24
- package/dist/model/graphs/config/menu.graphql +6 -0
- package/dist/model/graphs/config/page.graphql +8 -1
- package/dist/model/graphs/config/rules.graphql +82 -58
- package/dist/model/graphs/config/selectOptions.graphql +1 -0
- package/dist/model/graphs/config/table.graphql +3 -0
- package/dist/types/graphql.d.ts +374 -4
- package/dist/types/graphql.d.ts.map +1 -1
- package/dist/types/graphql.js.map +1 -1
- package/model/graphs/config/fields.graphql +42 -24
- package/model/graphs/config/menu.graphql +6 -0
- package/model/graphs/config/page.graphql +8 -1
- package/model/graphs/config/rules.graphql +82 -58
- package/model/graphs/config/selectOptions.graphql +1 -0
- package/model/graphs/config/table.graphql +3 -0
- package/package.json +3 -3
|
@@ -11,6 +11,10 @@ interface IField {
|
|
|
11
11
|
excludeFromQueryInput: Boolean
|
|
12
12
|
visibilityCondition: String
|
|
13
13
|
disabledCondition: String
|
|
14
|
+
"""
|
|
15
|
+
Always include this field in the mutation input, even if it is hidden or has not been modified by the user.
|
|
16
|
+
"""
|
|
17
|
+
skipDirtyCheck: Boolean
|
|
14
18
|
}
|
|
15
19
|
|
|
16
20
|
interface IDateRangeField {
|
|
@@ -28,8 +32,6 @@ interface IDateRangeField {
|
|
|
28
32
|
excludeFromQueryInput: Boolean
|
|
29
33
|
visibilityCondition: String
|
|
30
34
|
disabledCondition: String
|
|
31
|
-
validation: GenericFieldValidation
|
|
32
|
-
|
|
33
35
|
}
|
|
34
36
|
|
|
35
37
|
type InputField implements IField & IRowElement & IElement {
|
|
@@ -54,7 +56,6 @@ type InputField implements IField & IRowElement & IElement {
|
|
|
54
56
|
validation: InputValidation
|
|
55
57
|
visibilityCondition: String
|
|
56
58
|
disabledCondition: String
|
|
57
|
-
skipDirtyCheck: Boolean
|
|
58
59
|
# Start of text area configuration, see https://mui.com/material-ui/react-text-field/#multiline
|
|
59
60
|
multiline: Boolean # optional if at least one other text area parameter is provided
|
|
60
61
|
rows: Int
|
|
@@ -100,6 +101,36 @@ type ControlGroup implements IRowElement & IElement {
|
|
|
100
101
|
fields: [Fields!]!
|
|
101
102
|
}
|
|
102
103
|
|
|
104
|
+
# Renders the currently-linked records of a multi-valued reference attribute
|
|
105
|
+
# (`path`) as a table (`columns`, reusing Table's Column config), with a quick
|
|
106
|
+
# typeahead (`search`, reusing Table's SimpleSearch/QuerySelectOptions config)
|
|
107
|
+
# to find and add records of `dataType`, and a delete affordance per row.
|
|
108
|
+
# `rowMenuItems` (reusing Table's MenuItem config) adds further per-row actions,
|
|
109
|
+
# e.g. an `action: "details"` item with a `url` to navigate to that record's own
|
|
110
|
+
# details page.
|
|
111
|
+
type ReferenceTable implements IField & IRowElement & IElement {
|
|
112
|
+
cols: Int
|
|
113
|
+
defaultValue: String
|
|
114
|
+
disabledCondition: String
|
|
115
|
+
excludeFromQueryInput: Boolean
|
|
116
|
+
hidden: Boolean
|
|
117
|
+
label: String
|
|
118
|
+
name: String!
|
|
119
|
+
path: String!
|
|
120
|
+
readonly: Boolean
|
|
121
|
+
required: Boolean
|
|
122
|
+
requiredCondition: String
|
|
123
|
+
skipQuery: Boolean
|
|
124
|
+
visibilityCondition: String
|
|
125
|
+
dataType: String!
|
|
126
|
+
columns: [Column!]!
|
|
127
|
+
search: SimpleSearch
|
|
128
|
+
addLabel: String
|
|
129
|
+
confirmDelete: Boolean
|
|
130
|
+
maxRows: Int
|
|
131
|
+
rowMenuItems: [MenuItem!]
|
|
132
|
+
}
|
|
133
|
+
|
|
103
134
|
type PhoneField implements IField & IRowElement & IElement {
|
|
104
135
|
cols: Int
|
|
105
136
|
defaultValue: String
|
|
@@ -115,7 +146,7 @@ type PhoneField implements IField & IRowElement & IElement {
|
|
|
115
146
|
excludeFromQueryInput: Boolean
|
|
116
147
|
visibilityCondition: String
|
|
117
148
|
disabledCondition: String
|
|
118
|
-
validation:
|
|
149
|
+
validation: FieldValidation
|
|
119
150
|
}
|
|
120
151
|
|
|
121
152
|
type DateField implements IField & IRowElement & IElement {
|
|
@@ -134,7 +165,7 @@ type DateField implements IField & IRowElement & IElement {
|
|
|
134
165
|
disabledCondition: String
|
|
135
166
|
minDate: String # e.q. "now" or "2025-03-20"
|
|
136
167
|
maxDate: String # e.q. "now" or "2025-03-20"
|
|
137
|
-
validation:
|
|
168
|
+
validation: FieldValidation
|
|
138
169
|
}
|
|
139
170
|
|
|
140
171
|
type DateRangeField implements IDateRangeField & IRowElement & IElement {
|
|
@@ -153,7 +184,6 @@ type DateRangeField implements IDateRangeField & IRowElement & IElement {
|
|
|
153
184
|
excludeFromQueryInput: Boolean
|
|
154
185
|
visibilityCondition: String
|
|
155
186
|
disabledCondition: String
|
|
156
|
-
validation: GenericFieldValidation
|
|
157
187
|
}
|
|
158
188
|
|
|
159
189
|
type SelectField implements IField & IRowElement & IElement {
|
|
@@ -178,7 +208,7 @@ type SelectField implements IField & IRowElement & IElement {
|
|
|
178
208
|
excludeId: Boolean
|
|
179
209
|
helperText: String
|
|
180
210
|
autoSelectSingleOption: Boolean
|
|
181
|
-
validation:
|
|
211
|
+
validation: FieldValidation
|
|
182
212
|
}
|
|
183
213
|
|
|
184
214
|
type ToggleField implements IField & IRowElement & IElement {
|
|
@@ -200,7 +230,7 @@ type ToggleField implements IField & IRowElement & IElement {
|
|
|
200
230
|
visibilityCondition: String
|
|
201
231
|
disabledCondition: String
|
|
202
232
|
linkedFields: [String!]
|
|
203
|
-
validation:
|
|
233
|
+
validation: FieldValidation
|
|
204
234
|
}
|
|
205
235
|
|
|
206
236
|
type BooleanField implements IField & IRowElement & IElement {
|
|
@@ -218,7 +248,7 @@ type BooleanField implements IField & IRowElement & IElement {
|
|
|
218
248
|
visibilityCondition: String
|
|
219
249
|
disabledCondition: String
|
|
220
250
|
linkedFields: [String!]
|
|
221
|
-
validation:
|
|
251
|
+
validation: FieldValidation
|
|
222
252
|
}
|
|
223
253
|
|
|
224
254
|
type ChipSelectWithInputField implements IField & IRowElement & IElement {
|
|
@@ -262,7 +292,7 @@ type CustomField implements IField & IRowElement & IElement {
|
|
|
262
292
|
excludeFromQueryInput: Boolean
|
|
263
293
|
visibilityCondition: String
|
|
264
294
|
disabledCondition: String
|
|
265
|
-
validation:
|
|
295
|
+
validation: FieldValidation
|
|
266
296
|
}
|
|
267
297
|
|
|
268
298
|
type StatusChipField implements IField & IRowElement & IElement {
|
|
@@ -271,7 +301,7 @@ type StatusChipField implements IField & IRowElement & IElement {
|
|
|
271
301
|
label: String
|
|
272
302
|
name: String!
|
|
273
303
|
path: String!
|
|
274
|
-
validation:
|
|
304
|
+
validation: FieldValidation
|
|
275
305
|
}
|
|
276
306
|
|
|
277
307
|
type CheckboxGroupValue {
|
|
@@ -299,19 +329,9 @@ enum FieldValueType {
|
|
|
299
329
|
Float
|
|
300
330
|
}
|
|
301
331
|
|
|
302
|
-
type
|
|
303
|
-
custom : CustomFieldValidation
|
|
304
|
-
}
|
|
305
|
-
|
|
306
|
-
type CustomFieldValidation {
|
|
332
|
+
type FieldValidation {
|
|
307
333
|
expression: String
|
|
308
334
|
message: String
|
|
309
|
-
"""
|
|
310
|
-
Paths of other fields this expression reads. When one of these fields changes, this
|
|
311
|
-
field's validation is re-triggered so its error state stays in sync without requiring
|
|
312
|
-
the user to re-touch this field directly.
|
|
313
|
-
"""
|
|
314
|
-
dependentPaths: [String!]
|
|
315
335
|
}
|
|
316
336
|
|
|
317
337
|
type StringValidationRule {
|
|
@@ -343,13 +363,11 @@ type InputValidation {
|
|
|
343
363
|
format: [FormatValidationRule!]
|
|
344
364
|
min: FloatValidationRule
|
|
345
365
|
max: FloatValidationRule
|
|
346
|
-
custom: CustomFieldValidation
|
|
347
366
|
}
|
|
348
367
|
|
|
349
368
|
type ChipSelectValidation {
|
|
350
369
|
compatibleWith: CompatibleWithRule
|
|
351
370
|
uniqueInList: UniqueInListRule
|
|
352
|
-
custom : CustomFieldValidation
|
|
353
371
|
}
|
|
354
372
|
|
|
355
373
|
type CompatibleWithRule {
|
|
@@ -25,6 +25,12 @@ type MenuItem implements IMenuItem {
|
|
|
25
25
|
visibilityCondition: String
|
|
26
26
|
disabledCondition: String
|
|
27
27
|
config: JSON
|
|
28
|
+
"""
|
|
29
|
+
Child menu items. When present, this item acts as a collapsible group
|
|
30
|
+
header rather than a navigable leaf (consumers should treat a MenuItem
|
|
31
|
+
with `items` and no `url` as a group).
|
|
32
|
+
"""
|
|
33
|
+
items: [MenuItem!]
|
|
28
34
|
}
|
|
29
35
|
|
|
30
36
|
type ActionButton implements IMenuItem {
|
|
@@ -250,8 +250,15 @@ type Viewer {
|
|
|
250
250
|
}
|
|
251
251
|
|
|
252
252
|
type Breadcrumb {
|
|
253
|
-
label: String
|
|
253
|
+
label: String
|
|
254
254
|
path: String
|
|
255
255
|
isLabelExpression: Boolean
|
|
256
256
|
isPathExpression: Boolean
|
|
257
|
+
"""
|
|
258
|
+
Dot-notation paths (e.g. "name", "folder.title") to try, in order, against
|
|
259
|
+
the already-fetched page record to compute the breadcrumb label. Used only
|
|
260
|
+
when `isLabelExpression` is not set. If none of the paths resolve to a
|
|
261
|
+
non-empty value, the client falls back to the record's `id`.
|
|
262
|
+
"""
|
|
263
|
+
valuePaths: [String!]
|
|
257
264
|
}
|
|
@@ -1,80 +1,104 @@
|
|
|
1
|
-
|
|
2
1
|
type RuleGroup {
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
name: String
|
|
3
|
+
description: String
|
|
4
|
+
|
|
5
|
+
"""Type to apply the role group to. For example IContact or BaseWorkItem"""
|
|
6
|
+
type: String
|
|
7
|
+
"""Condition to define which rule groups will be applied. like for example custodian or registrationType"""
|
|
8
|
+
condition: String
|
|
9
|
+
|
|
10
|
+
"""Priority defined when multiple rule groups are matched. Higher value wins."""
|
|
11
|
+
priority: Int
|
|
12
|
+
fieldRules: [IFieldRule!]!
|
|
13
|
+
|
|
14
|
+
"""Custom validators that are not individual field rules (e.g. validation across multiple fields or collections)."""
|
|
15
|
+
validationRules: [ValidationRule!]
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
union ValidationRule = ArrayTotalRule
|
|
19
|
+
|
|
20
|
+
type ArrayTotalRule {
|
|
21
|
+
name: String
|
|
22
|
+
message: String!
|
|
23
|
+
|
|
24
|
+
"""Path to the collection whose elements should be validated."""
|
|
25
|
+
path: String!
|
|
26
|
+
|
|
27
|
+
"""Field from each matching collection element to include in the sum."""
|
|
28
|
+
fieldToSum: String!
|
|
29
|
+
|
|
30
|
+
"""Expected sum of the selected field values."""
|
|
31
|
+
expectedTotal: Int!
|
|
5
32
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
"""Condition to define which rule groups will be applied. like for example custodian or registrationType"""
|
|
9
|
-
condition: String
|
|
33
|
+
"""Optional condition used to select collection elements."""
|
|
34
|
+
filterCondition: String
|
|
10
35
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
fieldRules: [IFieldRule!]!
|
|
36
|
+
"""Determines whether empty data should be considered valid."""
|
|
37
|
+
emptyIsValid: Boolean
|
|
14
38
|
}
|
|
15
39
|
|
|
16
40
|
interface IFieldRule {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
41
|
+
defaultValue: String
|
|
42
|
+
messageLabel: String
|
|
43
|
+
path: String!
|
|
44
|
+
readonly: Boolean
|
|
45
|
+
required: Boolean
|
|
46
|
+
requiredCondition: String
|
|
47
|
+
availabilityCondition: String # maps to visibilityCondition on UI
|
|
24
48
|
}
|
|
25
49
|
|
|
26
50
|
type ListFieldRule implements IFieldRule {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
51
|
+
defaultValue: String
|
|
52
|
+
messageLabel: String
|
|
53
|
+
path: String!
|
|
54
|
+
readonly: Boolean
|
|
55
|
+
required: Boolean
|
|
56
|
+
requiredCondition: String
|
|
57
|
+
availabilityCondition: String # maps to visibilityCondition on UI
|
|
58
|
+
validationRules: [ListFieldValidationRule!]
|
|
59
|
+
validation: FieldValidation
|
|
36
60
|
}
|
|
37
61
|
|
|
38
|
-
type
|
|
39
|
-
|
|
40
|
-
|
|
62
|
+
type ListFieldValidationRule {
|
|
63
|
+
condition: String
|
|
64
|
+
errorMessage: String
|
|
41
65
|
}
|
|
42
66
|
|
|
43
67
|
type StringFieldRule implements IFieldRule {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
68
|
+
defaultValue: String
|
|
69
|
+
maxLength: Int
|
|
70
|
+
messageLabel: String
|
|
71
|
+
minLength: Int
|
|
72
|
+
path: String!
|
|
73
|
+
readonly: Boolean
|
|
74
|
+
required: Boolean
|
|
75
|
+
requiredCondition: String
|
|
76
|
+
type: FieldValueType
|
|
77
|
+
validation: InputValidation
|
|
78
|
+
availabilityCondition: String
|
|
55
79
|
}
|
|
56
80
|
|
|
57
81
|
type BooleanFieldRule implements IFieldRule {
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
82
|
+
defaultValue: String
|
|
83
|
+
messageLabel: String
|
|
84
|
+
path: String!
|
|
85
|
+
readonly: Boolean
|
|
86
|
+
required: Boolean
|
|
87
|
+
requiredCondition: String
|
|
88
|
+
validation: InputValidation
|
|
89
|
+
availabilityCondition: String
|
|
66
90
|
}
|
|
67
91
|
|
|
68
92
|
|
|
69
93
|
type DateFieldRule implements IFieldRule {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
94
|
+
defaultValue: String
|
|
95
|
+
messageLabel: String
|
|
96
|
+
path: String!
|
|
97
|
+
readonly: Boolean
|
|
98
|
+
required: Boolean
|
|
99
|
+
requiredCondition: String
|
|
100
|
+
availabilityCondition: String # maps to visibilityCondition on UI
|
|
101
|
+
minDate: String # e.q. "now" or "2025-03-20"
|
|
102
|
+
maxDate: String # e.q. "now" or "2025-03-20"
|
|
103
|
+
validation: FieldValidation
|
|
80
104
|
}
|
|
@@ -9,6 +9,7 @@ type SelectOptionsFilter {
|
|
|
9
9
|
type QuerySelectOptions implements ISelectOptions {
|
|
10
10
|
type: String
|
|
11
11
|
labelProp: String # defaults to "name" in ui
|
|
12
|
+
labelExpression: String # JS expression evaluated against each option (e.g. "`${option.name} (${option.internalId})`"); takes precedence over labelProp when set
|
|
12
13
|
valueProp: String # defaults to "id" in ui
|
|
13
14
|
queryName: String!
|
|
14
15
|
variableDefinitions: JSON
|
|
@@ -34,6 +34,7 @@ interface ITable {
|
|
|
34
34
|
expandable: Expandable
|
|
35
35
|
totals: [TotalsItem!]
|
|
36
36
|
config: JSON
|
|
37
|
+
globalName: String
|
|
37
38
|
}
|
|
38
39
|
|
|
39
40
|
type TotalsItem {
|
|
@@ -71,6 +72,8 @@ enum TablePinnedPosition {
|
|
|
71
72
|
|
|
72
73
|
type Toolbar {
|
|
73
74
|
columns: ToolbarColumns
|
|
75
|
+
configureColumns: ToolbarColumns
|
|
76
|
+
configureFilters: ToolbarColumns
|
|
74
77
|
}
|
|
75
78
|
|
|
76
79
|
type ToolbarColumns {
|