@atscript/ui 0.1.206 → 0.1.208
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/form/create-form-def.cjs +16 -18
- package/dist/form/create-form-def.mjs +15 -17
- package/dist/form/decimal-format.cjs +8 -3
- package/dist/form/decimal-format.d.cts +8 -2
- package/dist/form/decimal-format.d.mts +8 -2
- package/dist/form/decimal-format.mjs +8 -3
- package/dist/form/form-actions.cjs +9 -0
- package/dist/form/form-actions.d.cts +7 -1
- package/dist/form/form-actions.d.mts +7 -1
- package/dist/form/form-actions.mjs +9 -1
- package/dist/form/measurement.cjs +58 -0
- package/dist/form/measurement.d.cts +36 -1
- package/dist/form/measurement.d.mts +36 -1
- package/dist/form/measurement.mjs +57 -2
- package/dist/form/omit-derived.cjs +11 -0
- package/dist/form/omit-derived.d.cts +8 -1
- package/dist/form/omit-derived.d.mts +8 -1
- package/dist/form/omit-derived.mjs +11 -1
- package/dist/form/optional-mode.cjs +7 -7
- package/dist/form/optional-mode.d.cts +2 -1
- package/dist/form/optional-mode.d.mts +2 -1
- package/dist/form/optional-mode.mjs +8 -8
- package/dist/form/path-utils.cjs +10 -0
- package/dist/form/path-utils.d.cts +8 -1
- package/dist/form/path-utils.d.mts +8 -1
- package/dist/form/path-utils.mjs +10 -1
- package/dist/form/types.cjs +5 -0
- package/dist/form/types.d.cts +14 -0
- package/dist/form/types.d.mts +14 -0
- package/dist/form/types.mjs +5 -1
- package/dist/form/validate.cjs +56 -5
- package/dist/form/validate.d.cts +30 -2
- package/dist/form/validate.d.mts +30 -2
- package/dist/form/validate.mjs +56 -6
- package/dist/index.cjs +42 -6
- package/dist/index.d.cts +20 -12
- package/dist/index.d.mts +20 -12
- package/dist/index.mjs +23 -15
- package/dist/plugin/annotations.cjs +33 -14
- package/dist/plugin/annotations.mjs +34 -15
- package/dist/plugin/value-help-validation.cjs +26 -6
- package/dist/plugin/value-help-validation.mjs +26 -7
- package/dist/shared/annotation-keys.cjs +3 -0
- package/dist/shared/annotation-keys.d.cts +2 -1
- package/dist/shared/annotation-keys.d.mts +2 -1
- package/dist/shared/annotation-keys.mjs +3 -1
- package/dist/shared/dev.cjs +22 -0
- package/dist/shared/dev.d.cts +4 -0
- package/dist/shared/dev.d.mts +4 -0
- package/dist/shared/dev.mjs +22 -0
- package/dist/shared/field-resolver.cjs +21 -1
- package/dist/shared/field-resolver.d.cts +15 -1
- package/dist/shared/field-resolver.d.mts +15 -1
- package/dist/shared/field-resolver.mjs +20 -2
- package/dist/shared/merge-filters.cjs +28 -0
- package/dist/shared/merge-filters.d.cts +13 -0
- package/dist/shared/merge-filters.d.mts +13 -0
- package/dist/shared/merge-filters.mjs +28 -0
- package/dist/shared/meta-cache.cjs +5 -4
- package/dist/shared/meta-cache.d.cts +3 -2
- package/dist/shared/meta-cache.d.mts +3 -2
- package/dist/shared/meta-cache.mjs +5 -4
- package/dist/shared/resolve-component.cjs +27 -0
- package/dist/shared/resolve-component.d.cts +22 -0
- package/dist/shared/resolve-component.d.mts +22 -0
- package/dist/shared/resolve-component.mjs +27 -0
- package/dist/shared/stable-key.cjs +28 -0
- package/dist/shared/stable-key.d.cts +13 -0
- package/dist/shared/stable-key.d.mts +13 -0
- package/dist/shared/stable-key.mjs +28 -0
- package/dist/shared/to-date.cjs +65 -0
- package/dist/shared/to-date.d.cts +35 -0
- package/dist/shared/to-date.d.mts +35 -0
- package/dist/shared/to-date.mjs +64 -0
- package/dist/shared/value-label.cjs +14 -2
- package/dist/shared/value-label.d.cts +23 -6
- package/dist/shared/value-label.d.mts +23 -6
- package/dist/shared/value-label.mjs +14 -3
- package/dist/table/create-table-def.cjs +53 -13
- package/dist/table/create-table-def.mjs +53 -15
- package/dist/table/types.d.cts +15 -13
- package/dist/table/types.d.mts +15 -13
- package/dist/value-help/client-store.cjs +43 -0
- package/dist/value-help/client-store.d.mts +1 -0
- package/dist/value-help/client-store.mjs +40 -0
- package/dist/value-help/display-value.cjs +30 -0
- package/dist/value-help/display-value.d.cts +45 -0
- package/dist/value-help/display-value.d.mts +45 -0
- package/dist/value-help/display-value.mjs +30 -0
- package/dist/value-help/distinct-client.cjs +80 -7
- package/dist/value-help/distinct-client.d.cts +31 -36
- package/dist/value-help/distinct-client.d.mts +31 -36
- package/dist/value-help/distinct-client.mjs +80 -7
- package/dist/value-help/extract-ref.cjs +15 -4
- package/dist/value-help/extract-ref.d.cts +6 -1
- package/dist/value-help/extract-ref.d.mts +6 -1
- package/dist/value-help/extract-ref.mjs +16 -6
- package/dist/value-help/index.d.mts +6 -3
- package/dist/value-help/options.cjs +70 -8
- package/dist/value-help/options.d.cts +57 -4
- package/dist/value-help/options.d.mts +57 -4
- package/dist/value-help/options.mjs +67 -9
- package/dist/value-help/resolve-options.cjs +9 -7
- package/dist/value-help/resolve-options.d.cts +8 -9
- package/dist/value-help/resolve-options.d.mts +8 -9
- package/dist/value-help/resolve-options.mjs +9 -7
- package/dist/value-help/resolve.cjs +29 -8
- package/dist/value-help/resolve.d.cts +22 -5
- package/dist/value-help/resolve.d.mts +22 -5
- package/dist/value-help/resolve.mjs +29 -8
- package/dist/value-help/scope.cjs +3 -7
- package/dist/value-help/scope.mjs +3 -7
- package/dist/value-help/source.cjs +72 -0
- package/dist/value-help/source.d.cts +55 -0
- package/dist/value-help/source.d.mts +55 -0
- package/dist/value-help/source.mjs +71 -0
- package/dist/value-help/texts.cjs +318 -0
- package/dist/value-help/texts.d.cts +53 -0
- package/dist/value-help/texts.d.mts +53 -0
- package/dist/value-help/texts.mjs +313 -0
- package/dist/value-help/types.d.cts +10 -0
- package/dist/value-help/types.d.mts +10 -0
- package/dist/value-help/value-help-client.cjs +24 -20
- package/dist/value-help/value-help-client.d.cts +10 -5
- package/dist/value-help/value-help-client.d.mts +10 -5
- package/dist/value-help/value-help-client.mjs +22 -18
- package/package.json +10 -10
package/dist/index.cjs
CHANGED
|
@@ -9,24 +9,30 @@ const require_extract_ref = require("./value-help/extract-ref.cjs");
|
|
|
9
9
|
const require_clone = require("./form/clone.cjs");
|
|
10
10
|
const require_path_utils = require("./form/path-utils.cjs");
|
|
11
11
|
const require_skipped_nav = require("./form/skipped-nav.cjs");
|
|
12
|
+
const require_decimal_format = require("./form/decimal-format.cjs");
|
|
13
|
+
const require_measurement = require("./form/measurement.cjs");
|
|
12
14
|
const require_create_form_def = require("./form/create-form-def.cjs");
|
|
13
15
|
const require_optional_mode = require("./form/optional-mode.cjs");
|
|
14
16
|
const require_loaded_empty = require("./form/loaded-empty.cjs");
|
|
15
17
|
const require_form_actions = require("./form/form-actions.cjs");
|
|
16
18
|
const require_dict_paths = require("./value-help/dict-paths.cjs");
|
|
17
19
|
const require_resolve_options = require("./value-help/resolve-options.cjs");
|
|
20
|
+
const require_merge_filters = require("./shared/merge-filters.cjs");
|
|
18
21
|
const require_str = require("./shared/str.cjs");
|
|
19
|
-
const require_measurement = require("./form/measurement.cjs");
|
|
20
22
|
const require_value_label = require("./shared/value-label.cjs");
|
|
21
23
|
const require_create_table_def = require("./table/create-table-def.cjs");
|
|
22
24
|
const require_value_kind = require("./table/value-kind.cjs");
|
|
23
|
-
const require_value_help_client = require("./value-help/value-help-client.cjs");
|
|
24
|
-
const require_scope = require("./value-help/scope.cjs");
|
|
25
25
|
const require_options = require("./value-help/options.cjs");
|
|
26
|
-
const require_distinct_client = require("./value-help/distinct-client.cjs");
|
|
27
26
|
const require_client_factory = require("./client-factory.cjs");
|
|
28
27
|
const require_meta_cache = require("./shared/meta-cache.cjs");
|
|
29
28
|
const require_resolve = require("./value-help/resolve.cjs");
|
|
29
|
+
const require_source = require("./value-help/source.cjs");
|
|
30
|
+
const require_texts = require("./value-help/texts.cjs");
|
|
31
|
+
const require_value_help_client = require("./value-help/value-help-client.cjs");
|
|
32
|
+
const require_scope = require("./value-help/scope.cjs");
|
|
33
|
+
const require_stable_key = require("./shared/stable-key.cjs");
|
|
34
|
+
const require_distinct_client = require("./value-help/distinct-client.cjs");
|
|
35
|
+
const require_display_value = require("./value-help/display-value.cjs");
|
|
30
36
|
const require_error_utils = require("./form/error-utils.cjs");
|
|
31
37
|
const require_validate = require("./form/validate.cjs");
|
|
32
38
|
const require_diff = require("./form/diff.cjs");
|
|
@@ -37,7 +43,9 @@ const require_rebase = require("./form/rebase.cjs");
|
|
|
37
43
|
const require_union_detect = require("./form/union-detect.cjs");
|
|
38
44
|
const require_grid = require("./form/grid.cjs");
|
|
39
45
|
const require_labels = require("./form/labels.cjs");
|
|
40
|
-
const
|
|
46
|
+
const require_dev = require("./shared/dev.cjs");
|
|
47
|
+
const require_resolve_component = require("./shared/resolve-component.cjs");
|
|
48
|
+
const require_to_date = require("./shared/to-date.cjs");
|
|
41
49
|
const require_column_resolver = require("./table/column-resolver.cjs");
|
|
42
50
|
const require_navigate_href = require("./table/navigate-href.cjs");
|
|
43
51
|
const require_model_routes = require("./nav/model-routes.cjs");
|
|
@@ -52,6 +60,8 @@ exports.DB_UNIT_REF = require_annotation_keys.DB_UNIT_REF;
|
|
|
52
60
|
exports.DEFAULT_BOOLEAN_LABELS = require_extract_literals.DEFAULT_BOOLEAN_LABELS;
|
|
53
61
|
exports.DEFAULT_COL_SPAN = require_grid.DEFAULT_COL_SPAN;
|
|
54
62
|
exports.DEFAULT_ROW_SPAN = require_grid.DEFAULT_ROW_SPAN;
|
|
63
|
+
exports.DEV = require_dev.DEV;
|
|
64
|
+
exports.EXPECT_ARRAY_UNIQUE_ITEMS = require_annotation_keys.EXPECT_ARRAY_UNIQUE_ITEMS;
|
|
55
65
|
exports.EXPECT_MAX_LENGTH = require_annotation_keys.EXPECT_MAX_LENGTH;
|
|
56
66
|
exports.FORM_ERROR_KEY = require_error_utils.FORM_ERROR_KEY;
|
|
57
67
|
exports.META_DEFAULT = require_annotation_keys.META_DEFAULT;
|
|
@@ -143,6 +153,7 @@ exports.buildFormRebase = require_rebase.buildFormRebase;
|
|
|
143
153
|
exports.buildGridClasses = require_grid.buildGridClasses;
|
|
144
154
|
exports.buildModelRoutes = require_model_routes.buildModelRoutes;
|
|
145
155
|
exports.buildUnionVariants = require_create_form_def.buildUnionVariants;
|
|
156
|
+
exports.codeOf = require_value_label.codeOf;
|
|
146
157
|
exports.coerceNumericText = require_value_kind.coerceNumericText;
|
|
147
158
|
exports.collectDirtyPaths = require_dirty.collectDirtyPaths;
|
|
148
159
|
Object.defineProperty(exports, "compareExact", {
|
|
@@ -151,6 +162,7 @@ Object.defineProperty(exports, "compareExact", {
|
|
|
151
162
|
return _atscript_db_meta.compareExact;
|
|
152
163
|
}
|
|
153
164
|
});
|
|
165
|
+
exports.createDistinctPager = require_distinct_client.createDistinctPager;
|
|
154
166
|
exports.createFieldValidator = require_validate.createFieldValidator;
|
|
155
167
|
exports.createFormData = require_path_utils.createFormData;
|
|
156
168
|
exports.createFormDef = require_create_form_def.createFormDef;
|
|
@@ -164,6 +176,7 @@ exports.defaultResolver = require_field_resolver.defaultResolver;
|
|
|
164
176
|
exports.deleteByPath = require_path_utils.deleteByPath;
|
|
165
177
|
exports.deserializeServedType = require_model_texts.deserializeServedType;
|
|
166
178
|
exports.detectUnionVariant = require_path_utils.detectUnionVariant;
|
|
179
|
+
exports.displayValue = require_display_value.displayValue;
|
|
167
180
|
exports.emptiedValue = require_optional_mode.emptiedValue;
|
|
168
181
|
exports.enforceScale = require_decimal_format.enforceScale;
|
|
169
182
|
exports.escapeRegex = require_str.escapeRegex;
|
|
@@ -171,14 +184,15 @@ exports.extractFieldLiteralOptions = require_extract_literals.extractFieldLitera
|
|
|
171
184
|
exports.extractLiteralOptions = require_extract_literals.extractLiteralOptions;
|
|
172
185
|
exports.extractMeasurement = require_measurement.extractMeasurement;
|
|
173
186
|
exports.extractValueHelp = require_extract_ref.extractValueHelp;
|
|
174
|
-
exports.fetchDistinctValues = require_distinct_client.fetchDistinctValues;
|
|
175
187
|
exports.fieldText = require_model_texts.fieldText;
|
|
188
|
+
exports.formPayload = require_omit_derived.formPayload;
|
|
176
189
|
exports.formatDecimalForDisplay = require_decimal_format.formatDecimalForDisplay;
|
|
177
190
|
exports.getByPath = require_path_utils.getByPath;
|
|
178
191
|
exports.getColumn = require_column_resolver.getColumn;
|
|
179
192
|
exports.getCurrencyDecimals = require_decimal_format.getCurrencyDecimals;
|
|
180
193
|
exports.getCurrencyDisplayParts = require_decimal_format.getCurrencyDisplayParts;
|
|
181
194
|
exports.getDecimalSeparator = require_decimal_format.getDecimalSeparator;
|
|
195
|
+
exports.getDeclaredFormAction = require_form_actions.getDeclaredFormAction;
|
|
182
196
|
exports.getDeclaredFormActions = require_form_actions.getDeclaredFormActions;
|
|
183
197
|
exports.getDefaultClientFactory = require_client_factory.getDefaultClientFactory;
|
|
184
198
|
exports.getDefaultOptionalMode = require_optional_mode.getDefaultOptionalMode;
|
|
@@ -199,7 +213,10 @@ exports.hasFieldMeta = require_field_resolver.hasFieldMeta;
|
|
|
199
213
|
exports.invalidateValueHelpCache = require_value_help_client.invalidateValueHelpCache;
|
|
200
214
|
exports.isArrayField = require_types.isArrayField;
|
|
201
215
|
exports.isContainerKind = require_validate.isContainerKind;
|
|
216
|
+
exports.isFieldDisabled = require_field_resolver.isFieldDisabled;
|
|
202
217
|
exports.isFieldHidden = require_field_resolver.isFieldHidden;
|
|
218
|
+
exports.isFieldReadonly = require_field_resolver.isFieldReadonly;
|
|
219
|
+
exports.isFieldRequired = require_validate.isFieldRequired;
|
|
203
220
|
exports.isNumericText = require_value_kind.isNumericText;
|
|
204
221
|
exports.isObjectField = require_types.isObjectField;
|
|
205
222
|
exports.isPathDirty = require_dirty.isPathDirty;
|
|
@@ -211,31 +228,40 @@ exports.isUnionField = require_types.isUnionField;
|
|
|
211
228
|
exports.iteratePathAncestors = require_error_utils.iteratePathAncestors;
|
|
212
229
|
exports.joinDecimalString = require_decimal_format.joinDecimalString;
|
|
213
230
|
exports.joinPath = require_path_utils.joinPath;
|
|
231
|
+
exports.listsDictionary = require_options.listsDictionary;
|
|
232
|
+
exports.loadValueHelpTexts = require_texts.loadValueHelpTexts;
|
|
214
233
|
exports.markServedType = require_model_texts.markServedType;
|
|
215
234
|
exports.mergeErrorMaps = require_error_utils.mergeErrorMaps;
|
|
235
|
+
exports.mergeFilters = require_merge_filters.mergeFilters;
|
|
216
236
|
exports.navigateHrefFor = require_navigate_href.navigateHrefFor;
|
|
217
237
|
exports.normalizeLoadedEmpty = require_loaded_empty.normalizeLoadedEmpty;
|
|
238
|
+
exports.numberAdornment = require_measurement.numberAdornment;
|
|
218
239
|
exports.omitDerivedFields = require_omit_derived.omitDerivedFields;
|
|
219
240
|
exports.omitPaths = require_error_utils.omitPaths;
|
|
220
241
|
exports.omitSkippedNavFields = require_skipped_nav.omitSkippedNavFields;
|
|
221
242
|
exports.onMetaCacheReset = require_meta_cache.onMetaCacheReset;
|
|
222
243
|
exports.onUiLocaleChange = require_ui_texts.onUiLocaleChange;
|
|
244
|
+
exports.onValueHelpTexts = require_texts.onValueHelpTexts;
|
|
223
245
|
exports.optKey = require_resolve_options.optKey;
|
|
224
246
|
exports.optLabel = require_resolve_options.optLabel;
|
|
225
247
|
exports.optionLabel = require_resolve_options.optionLabel;
|
|
226
248
|
exports.optionValue = require_value_kind.optionValue;
|
|
249
|
+
exports.parentPrefix = require_path_utils.parentPrefix;
|
|
227
250
|
exports.parseColSpan = require_grid.parseColSpan;
|
|
228
251
|
exports.parseDecimalInput = require_decimal_format.parseDecimalInput;
|
|
229
252
|
exports.parseRowSpan = require_grid.parseRowSpan;
|
|
230
253
|
exports.parseStaticAttrs = require_field_resolver.parseStaticAttrs;
|
|
231
254
|
exports.parseStaticOptions = require_resolve_options.parseStaticOptions;
|
|
255
|
+
exports.refText = require_measurement.refText;
|
|
232
256
|
exports.resetDefaultClientFactory = require_client_factory.resetDefaultClientFactory;
|
|
233
257
|
exports.resetMetaCache = require_meta_cache.resetMetaCache;
|
|
234
258
|
exports.resetValueHelpCache = require_resolve.resetValueHelpCache;
|
|
235
259
|
exports.resolveAttrs = require_field_resolver.resolveAttrs;
|
|
260
|
+
exports.resolveComponent = require_resolve_component.resolveComponent;
|
|
236
261
|
exports.resolveFieldProp = require_field_resolver.resolveFieldProp;
|
|
237
262
|
exports.resolveFormProp = require_field_resolver.resolveFormProp;
|
|
238
263
|
exports.resolveGridSpec = require_grid.resolveGridSpec;
|
|
264
|
+
exports.resolveMeasurement = require_measurement.resolveMeasurement;
|
|
239
265
|
exports.resolveOptionalMode = require_optional_mode.resolveOptionalMode;
|
|
240
266
|
exports.resolveOptions = require_resolve_options.resolveOptions;
|
|
241
267
|
exports.resolveSingularLabel = require_labels.resolveSingularLabel;
|
|
@@ -252,13 +278,23 @@ exports.setResolver = require_field_resolver.setResolver;
|
|
|
252
278
|
exports.setUiLocale = require_ui_texts.setUiLocale;
|
|
253
279
|
exports.setValueHelpCacheTtl = require_value_help_client.setValueHelpCacheTtl;
|
|
254
280
|
exports.splitDecimalString = require_decimal_format.splitDecimalString;
|
|
281
|
+
exports.stableValueKey = require_stable_key.stableValueKey;
|
|
255
282
|
exports.str = require_str.str;
|
|
283
|
+
exports.toDate = require_to_date.toDate;
|
|
256
284
|
exports.unionVariantChanged = require_union_detect.unionVariantChanged;
|
|
257
285
|
exports.userText = require_model_texts.userText;
|
|
286
|
+
exports.utcDay = require_to_date.utcDay;
|
|
258
287
|
exports.validatorErrorsToMap = require_error_utils.validatorErrorsToMap;
|
|
288
|
+
exports.valueHelpColumns = require_source.valueHelpColumns;
|
|
259
289
|
exports.valueHelpDictPaths = require_dict_paths.valueHelpDictPaths;
|
|
290
|
+
exports.valueHelpDropdown = require_options.valueHelpDropdown;
|
|
260
291
|
exports.valueHelpFills = require_scope.valueHelpFills;
|
|
292
|
+
exports.valueHelpKey = require_extract_ref.valueHelpKey;
|
|
261
293
|
exports.valueHelpOptions = require_options.valueHelpOptions;
|
|
294
|
+
exports.valueHelpRowText = require_options.valueHelpRowText;
|
|
262
295
|
exports.valueHelpScope = require_scope.valueHelpScope;
|
|
263
296
|
exports.valueHelpSelect = require_value_help_client.valueHelpSelect;
|
|
297
|
+
exports.valueHelpSource = require_source.valueHelpSource;
|
|
298
|
+
exports.valueHelpText = require_texts.valueHelpText;
|
|
264
299
|
exports.valueLabelOf = require_value_label.valueLabelOf;
|
|
300
|
+
exports.valuePickerMode = require_options.valuePickerMode;
|
package/dist/index.d.cts
CHANGED
|
@@ -1,32 +1,36 @@
|
|
|
1
|
-
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.cjs";
|
|
1
|
+
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.cjs";
|
|
2
|
+
import { ValueLabel, ValueLabelArrangement, ValueText, arrangeText, codeOf, valueLabelOf } from "./shared/value-label.cjs";
|
|
2
3
|
import { TFormEntryOptions, ValueHelpInfo } from "./value-help/types.cjs";
|
|
3
4
|
import { FormArrayFieldDef, FormDef, FormFieldDef, FormObjectFieldDef, FormTupleFieldDef, FormUnionFieldDef, FormUnionVariant, TFormAction, isArrayField, isObjectField, isTupleField, isUnionField } from "./form/types.cjs";
|
|
4
5
|
import { CreateFormDefOptions, buildUnionVariants, createFormDef } from "./form/create-form-def.cjs";
|
|
5
6
|
import { TOptionalMode, emptiedValue, getDefaultOptionalMode, resolveOptionalMode, setDefaultOptionalMode } from "./form/optional-mode.cjs";
|
|
6
7
|
import { normalizeLoadedEmpty } from "./form/loaded-empty.cjs";
|
|
7
|
-
import { FormActionInfo, getDeclaredFormActions } from "./form/form-actions.cjs";
|
|
8
|
+
import { FormActionInfo, getDeclaredFormAction, getDeclaredFormActions } from "./form/form-actions.cjs";
|
|
8
9
|
import { UserTextT, deserializeServedType, fieldText, isServedType, markServedType, userText } from "./i18n/model-texts.cjs";
|
|
9
|
-
import { FieldResolver, StaticFieldResolver, TResolveOptions, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldHidden, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.cjs";
|
|
10
|
+
import { FieldResolver, StaticFieldResolver, TResolveOptions, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldDisabled, isFieldHidden, isFieldReadonly, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.cjs";
|
|
10
11
|
import { ClientFactory, ClientFactoryOptions, TypedClientFactory, getDefaultClientFactory, resetDefaultClientFactory, setDefaultClientFactory } from "./client-factory.cjs";
|
|
11
|
-
import {
|
|
12
|
+
import { Measurement, MeasurementInfo, extractMeasurement, numberAdornment, refText, resolveMeasurement } from "./form/measurement.cjs";
|
|
12
13
|
import { ColumnDef, ColumnValueKind, FieldMeta, MetaResponse, PaginationControl, RelationInfo, SearchIndexInfo, SortControl, TableActionsModel, TableDef, TableQueryState } from "./table/types.cjs";
|
|
13
14
|
import { UiT, UiTextParams, UiTexts, UiTranslate, activateUiTexts, createUiTexts, getUiTexts, onUiLocaleChange, setUiLocale } from "./i18n/ui-texts.cjs";
|
|
14
15
|
import { MetaCacheEntry, MetaEntryOptions, createMetaClient, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, onMetaCacheReset, resetMetaCache, retainMetaEntry, setMetaCacheIdentity, setMetaCacheMaxEntries } from "./shared/meta-cache.cjs";
|
|
16
|
+
import { ValueHelpSource, ValueHelpSourceOptions, valueHelpColumns, valueHelpSource } from "./value-help/source.cjs";
|
|
15
17
|
import { ResolvedValueHelp, resetValueHelpCache, resolveValueHelp } from "./value-help/resolve.cjs";
|
|
16
18
|
import { ValueHelpClient, ValueHelpResult, ValueHelpSearchOptions, invalidateValueHelpCache, setValueHelpCacheTtl, valueHelpSelect } from "./value-help/value-help-client.cjs";
|
|
17
19
|
import { valueHelpDictPaths } from "./value-help/dict-paths.cjs";
|
|
18
20
|
import { DEFAULT_BOOLEAN_LABELS, extractFieldLiteralOptions, extractLiteralOptions, isPureLiteralUnion } from "./value-help/extract-literals.cjs";
|
|
19
|
-
import { extractValueHelp } from "./value-help/extract-ref.cjs";
|
|
21
|
+
import { extractValueHelp, valueHelpKey } from "./value-help/extract-ref.cjs";
|
|
20
22
|
import { optKey, optLabel, optionLabel, parseStaticOptions, resolveOptions } from "./value-help/resolve-options.cjs";
|
|
21
23
|
import { ValueHelpFillWrite, ValueHelpScope, valueHelpFills, valueHelpScope } from "./value-help/scope.cjs";
|
|
22
|
-
import { VALUE_HELP_OPTIONS_CAP, valueHelpOptions } from "./value-help/options.cjs";
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
24
|
+
import { VALUE_HELP_OPTIONS_CAP, ValuePickerMode, listsDictionary, valueHelpDropdown, valueHelpOptions, valueHelpRowText, valuePickerMode } from "./value-help/options.cjs";
|
|
25
|
+
import { DistinctPager, DistinctPagerOptions, createDistinctPager, isPickerDeclined } from "./value-help/distinct-client.cjs";
|
|
26
|
+
import { ValueHelpTextOptions, loadValueHelpTexts, onValueHelpTexts, valueHelpText } from "./value-help/texts.cjs";
|
|
27
|
+
import { DisplayValueOptions, displayValue } from "./value-help/display-value.cjs";
|
|
28
|
+
import { TFormValueResolver, createFormData, createFormValueResolver, deleteByPath, detectUnionVariant, getByPath, joinPath, parentPrefix, setByPath } from "./form/path-utils.cjs";
|
|
25
29
|
import { CloneUnwrap, deepClone } from "./form/clone.cjs";
|
|
26
|
-
import { FormValidator, TFieldValidatorOptions, TFormValidatorCallOptions, UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, setDefaultValidatorPlugins } from "./form/validate.cjs";
|
|
30
|
+
import { FormValidator, TFieldValidatorOptions, TFormValidatorCallOptions, UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, isFieldRequired, setDefaultValidatorPlugins } from "./form/validate.cjs";
|
|
27
31
|
import { FormDiffOptions, FormDiffResult, FormFieldChange, buildFormDiff, deepEqual } from "./form/diff.cjs";
|
|
28
32
|
import { omitSkippedNavFields } from "./form/skipped-nav.cjs";
|
|
29
|
-
import { omitDerivedFields } from "./form/omit-derived.cjs";
|
|
33
|
+
import { formPayload, omitDerivedFields } from "./form/omit-derived.cjs";
|
|
30
34
|
import { collectDirtyPaths, isPathDirty } from "./form/dirty.cjs";
|
|
31
35
|
import { applyFormChanges } from "./form/apply.cjs";
|
|
32
36
|
import { FormRebaseOptions, FormRebaseResult, buildFormRebase } from "./form/rebase.cjs";
|
|
@@ -34,14 +38,18 @@ import { unionVariantChanged } from "./form/union-detect.cjs";
|
|
|
34
38
|
import { FORM_ERROR_KEY, buildDescendantErrorCounts, iteratePathAncestors, mergeErrorMaps, omitPaths, validatorErrorsToMap } from "./form/error-utils.cjs";
|
|
35
39
|
import { DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, GridSpanArgs, GridSpec, buildGridClasses, parseColSpan, parseRowSpan, resolveGridSpec } from "./form/grid.cjs";
|
|
36
40
|
import { resolveSingularLabel } from "./form/labels.cjs";
|
|
37
|
-
import { MeasurementInfo, extractMeasurement } from "./form/measurement.cjs";
|
|
38
41
|
import { CurrencyDisplay, DecimalParts, FormatDecimalOptions, enforceScale, formatDecimalForDisplay, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getThousandsSeparator, groupInteger, joinDecimalString, parseDecimalInput, splitDecimalString } from "./form/decimal-format.cjs";
|
|
39
42
|
import { createTableDef } from "./table/create-table-def.cjs";
|
|
40
43
|
import { NUMERIC_VALUE_KINDS, coerceNumericText, isNumericText, optionValue } from "./table/value-kind.cjs";
|
|
41
44
|
import { escapeRegex, str } from "./shared/str.cjs";
|
|
45
|
+
import { DEV } from "./shared/dev.cjs";
|
|
46
|
+
import { mergeFilters } from "./shared/merge-filters.cjs";
|
|
47
|
+
import { stableValueKey } from "./shared/stable-key.cjs";
|
|
48
|
+
import { resolveComponent } from "./shared/resolve-component.cjs";
|
|
49
|
+
import { DateValue, toDate, utcDay } from "./shared/to-date.cjs";
|
|
42
50
|
import { getColumn, getFilterableColumns, getSortableColumns } from "./table/column-resolver.cjs";
|
|
43
51
|
import { navigateHrefFor } from "./table/navigate-href.cjs";
|
|
44
52
|
import { TModelRoute, buildModelRoutes } from "./nav/model-routes.cjs";
|
|
45
53
|
import { ClientLike, TCrudOp, TCrudPermissions, TDbActionInfo, TDbActionIntent, TDbActionLevel, TDbActionProcessor } from "@atscript/db-client";
|
|
46
54
|
import { compareExact } from "@atscript/db/meta";
|
|
47
|
-
export { type ClientFactory, type ClientFactoryOptions, type ClientLike, type CloneUnwrap, type ColumnDef, type ColumnValueKind, type CreateFormDefOptions, type CurrencyDisplay, DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, type DecimalParts, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, type FieldMeta, type FieldResolver, type FormActionInfo, type FormArrayFieldDef, type FormDef, type FormDiffOptions, type FormDiffResult, type FormFieldChange, type FormFieldDef, type FormObjectFieldDef, type FormRebaseOptions, type FormRebaseResult, type FormTupleFieldDef, type FormUnionFieldDef, type FormUnionVariant, type FormValidator, type FormatDecimalOptions, type GridSpanArgs, type GridSpec, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, type MeasurementInfo, type MetaCacheEntry, type MetaEntryOptions, type MetaResponse, NUMERIC_VALUE_KINDS, type PaginationControl, type RelationInfo, type ResolvedValueHelp, type SearchIndexInfo, type SortControl, StaticFieldResolver, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TFieldValidatorOptions, type TFormAction, type TFormEntryOptions, type TFormValidatorCallOptions, type TFormValueResolver, type TModelRoute, type TOptionalMode, type TResolveOptions, type TableActionsModel, type TableDef, type TableQueryState, type TypedClientFactory, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, type UiT, type UiTextParams, type UiTexts, type UiTranslate, type UserTextT, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, type ValueHelpFillWrite, type ValueHelpInfo, type ValueHelpResult, type ValueHelpScope, type ValueHelpSearchOptions, type ValueLabel, type ValueLabelArrangement, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, coerceNumericText, collectDirtyPaths, compareExact, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp,
|
|
55
|
+
export { type ClientFactory, type ClientFactoryOptions, type ClientLike, type CloneUnwrap, type ColumnDef, type ColumnValueKind, type CreateFormDefOptions, type CurrencyDisplay, DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, DEV, type DateValue, type DecimalParts, type DisplayValueOptions, type DistinctPager, type DistinctPagerOptions, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, type FieldMeta, type FieldResolver, type FormActionInfo, type FormArrayFieldDef, type FormDef, type FormDiffOptions, type FormDiffResult, type FormFieldChange, type FormFieldDef, type FormObjectFieldDef, type FormRebaseOptions, type FormRebaseResult, type FormTupleFieldDef, type FormUnionFieldDef, type FormUnionVariant, type FormValidator, type FormatDecimalOptions, type GridSpanArgs, type GridSpec, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, type Measurement, type MeasurementInfo, type MetaCacheEntry, type MetaEntryOptions, type MetaResponse, NUMERIC_VALUE_KINDS, type PaginationControl, type RelationInfo, type ResolvedValueHelp, type SearchIndexInfo, type SortControl, StaticFieldResolver, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TFieldValidatorOptions, type TFormAction, type TFormEntryOptions, type TFormValidatorCallOptions, type TFormValueResolver, type TModelRoute, type TOptionalMode, type TResolveOptions, type TableActionsModel, type TableDef, type TableQueryState, type TypedClientFactory, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, type UiT, type UiTextParams, type UiTexts, type UiTranslate, type UserTextT, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, type ValueHelpFillWrite, type ValueHelpInfo, type ValueHelpResult, type ValueHelpScope, type ValueHelpSearchOptions, type ValueHelpSource, type ValueHelpSourceOptions, type ValueHelpTextOptions, type ValueLabel, type ValueLabelArrangement, type ValuePickerMode, type ValueText, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, codeOf, coerceNumericText, collectDirtyPaths, compareExact, createDistinctPager, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, displayValue, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp, fieldText, formPayload, formatDecimalForDisplay, getByPath, getColumn, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getDeclaredFormAction, getDeclaredFormActions, getDefaultClientFactory, getDefaultOptionalMode, getDefaultValidatorPlugins, getFieldMeta, getFilterableColumns, getFormValidator, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, getResolver, getSortableColumns, getThousandsSeparator, getUiTexts, groupInteger, hasComputedAnnotations, hasFieldMeta, invalidateValueHelpCache, isArrayField, isContainerKind, isFieldDisabled, isFieldHidden, isFieldReadonly, isFieldRequired, isNumericText, isObjectField, isPathDirty, isPickerDeclined, isPureLiteralUnion, isServedType, isTupleField, isUnionField, iteratePathAncestors, joinDecimalString, joinPath, listsDictionary, loadValueHelpTexts, markServedType, mergeErrorMaps, mergeFilters, navigateHrefFor, normalizeLoadedEmpty, numberAdornment, omitDerivedFields, omitPaths, omitSkippedNavFields, onMetaCacheReset, onUiLocaleChange, onValueHelpTexts, optKey, optLabel, optionLabel, optionValue, parentPrefix, parseColSpan, parseDecimalInput, parseRowSpan, parseStaticAttrs, parseStaticOptions, refText, resetDefaultClientFactory, resetMetaCache, resetValueHelpCache, resolveAttrs, resolveComponent, resolveFieldProp, resolveFormProp, resolveGridSpec, resolveMeasurement, resolveOptionalMode, resolveOptions, resolveSingularLabel, resolveStatic, resolveValueHelp, retainMetaEntry, setByPath, setDefaultClientFactory, setDefaultOptionalMode, setDefaultValidatorPlugins, setMetaCacheIdentity, setMetaCacheMaxEntries, setResolver, setUiLocale, setValueHelpCacheTtl, splitDecimalString, stableValueKey, str, toDate, unionVariantChanged, userText, utcDay, validatorErrorsToMap, valueHelpColumns, valueHelpDictPaths, valueHelpDropdown, valueHelpFills, valueHelpKey, valueHelpOptions, valueHelpRowText, valueHelpScope, valueHelpSelect, valueHelpSource, valueHelpText, valueLabelOf, valuePickerMode };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,32 +1,36 @@
|
|
|
1
|
-
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.mjs";
|
|
1
|
+
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.mjs";
|
|
2
|
+
import { ValueLabel, ValueLabelArrangement, ValueText, arrangeText, codeOf, valueLabelOf } from "./shared/value-label.mjs";
|
|
2
3
|
import { TFormEntryOptions, ValueHelpInfo } from "./value-help/types.mjs";
|
|
3
4
|
import { FormArrayFieldDef, FormDef, FormFieldDef, FormObjectFieldDef, FormTupleFieldDef, FormUnionFieldDef, FormUnionVariant, TFormAction, isArrayField, isObjectField, isTupleField, isUnionField } from "./form/types.mjs";
|
|
4
5
|
import { CreateFormDefOptions, buildUnionVariants, createFormDef } from "./form/create-form-def.mjs";
|
|
5
6
|
import { TOptionalMode, emptiedValue, getDefaultOptionalMode, resolveOptionalMode, setDefaultOptionalMode } from "./form/optional-mode.mjs";
|
|
6
7
|
import { normalizeLoadedEmpty } from "./form/loaded-empty.mjs";
|
|
7
|
-
import { FormActionInfo, getDeclaredFormActions } from "./form/form-actions.mjs";
|
|
8
|
+
import { FormActionInfo, getDeclaredFormAction, getDeclaredFormActions } from "./form/form-actions.mjs";
|
|
8
9
|
import { UserTextT, deserializeServedType, fieldText, isServedType, markServedType, userText } from "./i18n/model-texts.mjs";
|
|
9
|
-
import { FieldResolver, StaticFieldResolver, TResolveOptions, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldHidden, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.mjs";
|
|
10
|
+
import { FieldResolver, StaticFieldResolver, TResolveOptions, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldDisabled, isFieldHidden, isFieldReadonly, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.mjs";
|
|
10
11
|
import { ClientFactory, ClientFactoryOptions, TypedClientFactory, getDefaultClientFactory, resetDefaultClientFactory, setDefaultClientFactory } from "./client-factory.mjs";
|
|
11
|
-
import {
|
|
12
|
+
import { Measurement, MeasurementInfo, extractMeasurement, numberAdornment, refText, resolveMeasurement } from "./form/measurement.mjs";
|
|
12
13
|
import { ColumnDef, ColumnValueKind, FieldMeta, MetaResponse, PaginationControl, RelationInfo, SearchIndexInfo, SortControl, TableActionsModel, TableDef, TableQueryState } from "./table/types.mjs";
|
|
13
14
|
import { UiT, UiTextParams, UiTexts, UiTranslate, activateUiTexts, createUiTexts, getUiTexts, onUiLocaleChange, setUiLocale } from "./i18n/ui-texts.mjs";
|
|
14
15
|
import { MetaCacheEntry, MetaEntryOptions, createMetaClient, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, onMetaCacheReset, resetMetaCache, retainMetaEntry, setMetaCacheIdentity, setMetaCacheMaxEntries } from "./shared/meta-cache.mjs";
|
|
16
|
+
import { ValueHelpSource, ValueHelpSourceOptions, valueHelpColumns, valueHelpSource } from "./value-help/source.mjs";
|
|
15
17
|
import { ResolvedValueHelp, resetValueHelpCache, resolveValueHelp } from "./value-help/resolve.mjs";
|
|
16
18
|
import { ValueHelpClient, ValueHelpResult, ValueHelpSearchOptions, invalidateValueHelpCache, setValueHelpCacheTtl, valueHelpSelect } from "./value-help/value-help-client.mjs";
|
|
17
19
|
import { valueHelpDictPaths } from "./value-help/dict-paths.mjs";
|
|
18
20
|
import { DEFAULT_BOOLEAN_LABELS, extractFieldLiteralOptions, extractLiteralOptions, isPureLiteralUnion } from "./value-help/extract-literals.mjs";
|
|
19
|
-
import { extractValueHelp } from "./value-help/extract-ref.mjs";
|
|
21
|
+
import { extractValueHelp, valueHelpKey } from "./value-help/extract-ref.mjs";
|
|
20
22
|
import { optKey, optLabel, optionLabel, parseStaticOptions, resolveOptions } from "./value-help/resolve-options.mjs";
|
|
21
23
|
import { ValueHelpFillWrite, ValueHelpScope, valueHelpFills, valueHelpScope } from "./value-help/scope.mjs";
|
|
22
|
-
import { VALUE_HELP_OPTIONS_CAP, valueHelpOptions } from "./value-help/options.mjs";
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
24
|
+
import { VALUE_HELP_OPTIONS_CAP, ValuePickerMode, listsDictionary, valueHelpDropdown, valueHelpOptions, valueHelpRowText, valuePickerMode } from "./value-help/options.mjs";
|
|
25
|
+
import { DistinctPager, DistinctPagerOptions, createDistinctPager, isPickerDeclined } from "./value-help/distinct-client.mjs";
|
|
26
|
+
import { ValueHelpTextOptions, loadValueHelpTexts, onValueHelpTexts, valueHelpText } from "./value-help/texts.mjs";
|
|
27
|
+
import { DisplayValueOptions, displayValue } from "./value-help/display-value.mjs";
|
|
28
|
+
import { TFormValueResolver, createFormData, createFormValueResolver, deleteByPath, detectUnionVariant, getByPath, joinPath, parentPrefix, setByPath } from "./form/path-utils.mjs";
|
|
25
29
|
import { CloneUnwrap, deepClone } from "./form/clone.mjs";
|
|
26
|
-
import { FormValidator, TFieldValidatorOptions, TFormValidatorCallOptions, UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, setDefaultValidatorPlugins } from "./form/validate.mjs";
|
|
30
|
+
import { FormValidator, TFieldValidatorOptions, TFormValidatorCallOptions, UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, isFieldRequired, setDefaultValidatorPlugins } from "./form/validate.mjs";
|
|
27
31
|
import { FormDiffOptions, FormDiffResult, FormFieldChange, buildFormDiff, deepEqual } from "./form/diff.mjs";
|
|
28
32
|
import { omitSkippedNavFields } from "./form/skipped-nav.mjs";
|
|
29
|
-
import { omitDerivedFields } from "./form/omit-derived.mjs";
|
|
33
|
+
import { formPayload, omitDerivedFields } from "./form/omit-derived.mjs";
|
|
30
34
|
import { collectDirtyPaths, isPathDirty } from "./form/dirty.mjs";
|
|
31
35
|
import { applyFormChanges } from "./form/apply.mjs";
|
|
32
36
|
import { FormRebaseOptions, FormRebaseResult, buildFormRebase } from "./form/rebase.mjs";
|
|
@@ -34,14 +38,18 @@ import { unionVariantChanged } from "./form/union-detect.mjs";
|
|
|
34
38
|
import { FORM_ERROR_KEY, buildDescendantErrorCounts, iteratePathAncestors, mergeErrorMaps, omitPaths, validatorErrorsToMap } from "./form/error-utils.mjs";
|
|
35
39
|
import { DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, GridSpanArgs, GridSpec, buildGridClasses, parseColSpan, parseRowSpan, resolveGridSpec } from "./form/grid.mjs";
|
|
36
40
|
import { resolveSingularLabel } from "./form/labels.mjs";
|
|
37
|
-
import { MeasurementInfo, extractMeasurement } from "./form/measurement.mjs";
|
|
38
41
|
import { CurrencyDisplay, DecimalParts, FormatDecimalOptions, enforceScale, formatDecimalForDisplay, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getThousandsSeparator, groupInteger, joinDecimalString, parseDecimalInput, splitDecimalString } from "./form/decimal-format.mjs";
|
|
39
42
|
import { createTableDef } from "./table/create-table-def.mjs";
|
|
40
43
|
import { NUMERIC_VALUE_KINDS, coerceNumericText, isNumericText, optionValue } from "./table/value-kind.mjs";
|
|
41
44
|
import { escapeRegex, str } from "./shared/str.mjs";
|
|
45
|
+
import { DEV } from "./shared/dev.mjs";
|
|
46
|
+
import { mergeFilters } from "./shared/merge-filters.mjs";
|
|
47
|
+
import { stableValueKey } from "./shared/stable-key.mjs";
|
|
48
|
+
import { resolveComponent } from "./shared/resolve-component.mjs";
|
|
49
|
+
import { DateValue, toDate, utcDay } from "./shared/to-date.mjs";
|
|
42
50
|
import { getColumn, getFilterableColumns, getSortableColumns } from "./table/column-resolver.mjs";
|
|
43
51
|
import { navigateHrefFor } from "./table/navigate-href.mjs";
|
|
44
52
|
import { TModelRoute, buildModelRoutes } from "./nav/model-routes.mjs";
|
|
45
53
|
import { compareExact } from "@atscript/db/meta";
|
|
46
54
|
import { ClientLike, TCrudOp, TCrudPermissions, TDbActionInfo, TDbActionIntent, TDbActionLevel, TDbActionProcessor } from "@atscript/db-client";
|
|
47
|
-
export { type ClientFactory, type ClientFactoryOptions, type ClientLike, type CloneUnwrap, type ColumnDef, type ColumnValueKind, type CreateFormDefOptions, type CurrencyDisplay, DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, type DecimalParts, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, type FieldMeta, type FieldResolver, type FormActionInfo, type FormArrayFieldDef, type FormDef, type FormDiffOptions, type FormDiffResult, type FormFieldChange, type FormFieldDef, type FormObjectFieldDef, type FormRebaseOptions, type FormRebaseResult, type FormTupleFieldDef, type FormUnionFieldDef, type FormUnionVariant, type FormValidator, type FormatDecimalOptions, type GridSpanArgs, type GridSpec, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, type MeasurementInfo, type MetaCacheEntry, type MetaEntryOptions, type MetaResponse, NUMERIC_VALUE_KINDS, type PaginationControl, type RelationInfo, type ResolvedValueHelp, type SearchIndexInfo, type SortControl, StaticFieldResolver, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TFieldValidatorOptions, type TFormAction, type TFormEntryOptions, type TFormValidatorCallOptions, type TFormValueResolver, type TModelRoute, type TOptionalMode, type TResolveOptions, type TableActionsModel, type TableDef, type TableQueryState, type TypedClientFactory, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, type UiT, type UiTextParams, type UiTexts, type UiTranslate, type UserTextT, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, type ValueHelpFillWrite, type ValueHelpInfo, type ValueHelpResult, type ValueHelpScope, type ValueHelpSearchOptions, type ValueLabel, type ValueLabelArrangement, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, coerceNumericText, collectDirtyPaths, compareExact, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp,
|
|
55
|
+
export { type ClientFactory, type ClientFactoryOptions, type ClientLike, type CloneUnwrap, type ColumnDef, type ColumnValueKind, type CreateFormDefOptions, type CurrencyDisplay, DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, DEV, type DateValue, type DecimalParts, type DisplayValueOptions, type DistinctPager, type DistinctPagerOptions, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, type FieldMeta, type FieldResolver, type FormActionInfo, type FormArrayFieldDef, type FormDef, type FormDiffOptions, type FormDiffResult, type FormFieldChange, type FormFieldDef, type FormObjectFieldDef, type FormRebaseOptions, type FormRebaseResult, type FormTupleFieldDef, type FormUnionFieldDef, type FormUnionVariant, type FormValidator, type FormatDecimalOptions, type GridSpanArgs, type GridSpec, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, type Measurement, type MeasurementInfo, type MetaCacheEntry, type MetaEntryOptions, type MetaResponse, NUMERIC_VALUE_KINDS, type PaginationControl, type RelationInfo, type ResolvedValueHelp, type SearchIndexInfo, type SortControl, StaticFieldResolver, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TFieldValidatorOptions, type TFormAction, type TFormEntryOptions, type TFormValidatorCallOptions, type TFormValueResolver, type TModelRoute, type TOptionalMode, type TResolveOptions, type TableActionsModel, type TableDef, type TableQueryState, type TypedClientFactory, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, type UiT, type UiTextParams, type UiTexts, type UiTranslate, type UserTextT, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, type ValueHelpFillWrite, type ValueHelpInfo, type ValueHelpResult, type ValueHelpScope, type ValueHelpSearchOptions, type ValueHelpSource, type ValueHelpSourceOptions, type ValueHelpTextOptions, type ValueLabel, type ValueLabelArrangement, type ValuePickerMode, type ValueText, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, codeOf, coerceNumericText, collectDirtyPaths, compareExact, createDistinctPager, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, displayValue, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp, fieldText, formPayload, formatDecimalForDisplay, getByPath, getColumn, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getDeclaredFormAction, getDeclaredFormActions, getDefaultClientFactory, getDefaultOptionalMode, getDefaultValidatorPlugins, getFieldMeta, getFilterableColumns, getFormValidator, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, getResolver, getSortableColumns, getThousandsSeparator, getUiTexts, groupInteger, hasComputedAnnotations, hasFieldMeta, invalidateValueHelpCache, isArrayField, isContainerKind, isFieldDisabled, isFieldHidden, isFieldReadonly, isFieldRequired, isNumericText, isObjectField, isPathDirty, isPickerDeclined, isPureLiteralUnion, isServedType, isTupleField, isUnionField, iteratePathAncestors, joinDecimalString, joinPath, listsDictionary, loadValueHelpTexts, markServedType, mergeErrorMaps, mergeFilters, navigateHrefFor, normalizeLoadedEmpty, numberAdornment, omitDerivedFields, omitPaths, omitSkippedNavFields, onMetaCacheReset, onUiLocaleChange, onValueHelpTexts, optKey, optLabel, optionLabel, optionValue, parentPrefix, parseColSpan, parseDecimalInput, parseRowSpan, parseStaticAttrs, parseStaticOptions, refText, resetDefaultClientFactory, resetMetaCache, resetValueHelpCache, resolveAttrs, resolveComponent, resolveFieldProp, resolveFormProp, resolveGridSpec, resolveMeasurement, resolveOptionalMode, resolveOptions, resolveSingularLabel, resolveStatic, resolveValueHelp, retainMetaEntry, setByPath, setDefaultClientFactory, setDefaultOptionalMode, setDefaultValidatorPlugins, setMetaCacheIdentity, setMetaCacheMaxEntries, setResolver, setUiLocale, setValueHelpCacheTtl, splitDecimalString, stableValueKey, str, toDate, unionVariantChanged, userText, utcDay, validatorErrorsToMap, valueHelpColumns, valueHelpDictPaths, valueHelpDropdown, valueHelpFills, valueHelpKey, valueHelpOptions, valueHelpRowText, valueHelpScope, valueHelpSelect, valueHelpSource, valueHelpText, valueLabelOf, valuePickerMode };
|
package/dist/index.mjs
CHANGED
|
@@ -1,44 +1,52 @@
|
|
|
1
|
-
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.mjs";
|
|
1
|
+
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, WF_ACTION_WITH_DATA } from "./shared/annotation-keys.mjs";
|
|
2
2
|
import { isArrayField, isObjectField, isTupleField, isUnionField } from "./form/types.mjs";
|
|
3
3
|
import { deserializeServedType, fieldText, isServedType, markServedType, userText } from "./i18n/model-texts.mjs";
|
|
4
|
-
import { StaticFieldResolver, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldHidden, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.mjs";
|
|
4
|
+
import { StaticFieldResolver, asArray, defaultResolver, getFieldMeta, getResolver, hasComputedAnnotations, hasFieldMeta, isFieldDisabled, isFieldHidden, isFieldReadonly, parseStaticAttrs, resolveAttrs, resolveFieldProp, resolveFormProp, resolveStatic, setResolver } from "./shared/field-resolver.mjs";
|
|
5
5
|
import { activateUiTexts, createUiTexts, getUiTexts, onUiLocaleChange, setUiLocale } from "./i18n/ui-texts.mjs";
|
|
6
6
|
import { DEFAULT_BOOLEAN_LABELS, extractFieldLiteralOptions, extractLiteralOptions, isPureLiteralUnion } from "./value-help/extract-literals.mjs";
|
|
7
|
-
import { extractValueHelp } from "./value-help/extract-ref.mjs";
|
|
7
|
+
import { extractValueHelp, valueHelpKey } from "./value-help/extract-ref.mjs";
|
|
8
8
|
import { deepClone } from "./form/clone.mjs";
|
|
9
|
-
import { createFormData, createFormValueResolver, deleteByPath, detectUnionVariant, getByPath, joinPath, setByPath } from "./form/path-utils.mjs";
|
|
9
|
+
import { createFormData, createFormValueResolver, deleteByPath, detectUnionVariant, getByPath, joinPath, parentPrefix, setByPath } from "./form/path-utils.mjs";
|
|
10
10
|
import { omitSkippedNavFields } from "./form/skipped-nav.mjs";
|
|
11
|
+
import { enforceScale, formatDecimalForDisplay, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getThousandsSeparator, groupInteger, joinDecimalString, parseDecimalInput, splitDecimalString } from "./form/decimal-format.mjs";
|
|
12
|
+
import { extractMeasurement, numberAdornment, refText, resolveMeasurement } from "./form/measurement.mjs";
|
|
11
13
|
import { buildUnionVariants, createFormDef } from "./form/create-form-def.mjs";
|
|
12
14
|
import { emptiedValue, getDefaultOptionalMode, resolveOptionalMode, setDefaultOptionalMode } from "./form/optional-mode.mjs";
|
|
13
15
|
import { normalizeLoadedEmpty } from "./form/loaded-empty.mjs";
|
|
14
|
-
import { getDeclaredFormActions } from "./form/form-actions.mjs";
|
|
16
|
+
import { getDeclaredFormAction, getDeclaredFormActions } from "./form/form-actions.mjs";
|
|
15
17
|
import { valueHelpDictPaths } from "./value-help/dict-paths.mjs";
|
|
16
18
|
import { optKey, optLabel, optionLabel, parseStaticOptions, resolveOptions } from "./value-help/resolve-options.mjs";
|
|
19
|
+
import { mergeFilters } from "./shared/merge-filters.mjs";
|
|
17
20
|
import { escapeRegex, str } from "./shared/str.mjs";
|
|
18
|
-
import {
|
|
19
|
-
import { arrangeText, valueLabelOf } from "./shared/value-label.mjs";
|
|
21
|
+
import { arrangeText, codeOf, valueLabelOf } from "./shared/value-label.mjs";
|
|
20
22
|
import { createTableDef } from "./table/create-table-def.mjs";
|
|
21
23
|
import { NUMERIC_VALUE_KINDS, coerceNumericText, isNumericText, optionValue } from "./table/value-kind.mjs";
|
|
22
|
-
import {
|
|
23
|
-
import { valueHelpFills, valueHelpScope } from "./value-help/scope.mjs";
|
|
24
|
-
import { VALUE_HELP_OPTIONS_CAP, valueHelpOptions } from "./value-help/options.mjs";
|
|
25
|
-
import { fetchDistinctValues, isPickerDeclined } from "./value-help/distinct-client.mjs";
|
|
24
|
+
import { VALUE_HELP_OPTIONS_CAP, listsDictionary, valueHelpDropdown, valueHelpOptions, valueHelpRowText, valuePickerMode } from "./value-help/options.mjs";
|
|
26
25
|
import { getDefaultClientFactory, resetDefaultClientFactory, setDefaultClientFactory } from "./client-factory.mjs";
|
|
27
26
|
import { createMetaClient, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, onMetaCacheReset, resetMetaCache, retainMetaEntry, setMetaCacheIdentity, setMetaCacheMaxEntries } from "./shared/meta-cache.mjs";
|
|
28
27
|
import { resetValueHelpCache, resolveValueHelp } from "./value-help/resolve.mjs";
|
|
28
|
+
import { valueHelpColumns, valueHelpSource } from "./value-help/source.mjs";
|
|
29
|
+
import { loadValueHelpTexts, onValueHelpTexts, valueHelpText } from "./value-help/texts.mjs";
|
|
30
|
+
import { ValueHelpClient, invalidateValueHelpCache, setValueHelpCacheTtl, valueHelpSelect } from "./value-help/value-help-client.mjs";
|
|
31
|
+
import { valueHelpFills, valueHelpScope } from "./value-help/scope.mjs";
|
|
32
|
+
import { stableValueKey } from "./shared/stable-key.mjs";
|
|
33
|
+
import { createDistinctPager, isPickerDeclined } from "./value-help/distinct-client.mjs";
|
|
34
|
+
import { displayValue } from "./value-help/display-value.mjs";
|
|
29
35
|
import { FORM_ERROR_KEY, buildDescendantErrorCounts, iteratePathAncestors, mergeErrorMaps, omitPaths, validatorErrorsToMap } from "./form/error-utils.mjs";
|
|
30
|
-
import { UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, setDefaultValidatorPlugins } from "./form/validate.mjs";
|
|
36
|
+
import { UI_FORM_VALIDATE_ERROR_CODE, createFieldValidator, getDefaultValidatorPlugins, getFormValidator, isContainerKind, isFieldRequired, setDefaultValidatorPlugins } from "./form/validate.mjs";
|
|
31
37
|
import { buildFormDiff, deepEqual } from "./form/diff.mjs";
|
|
32
|
-
import { omitDerivedFields } from "./form/omit-derived.mjs";
|
|
38
|
+
import { formPayload, omitDerivedFields } from "./form/omit-derived.mjs";
|
|
33
39
|
import { collectDirtyPaths, isPathDirty } from "./form/dirty.mjs";
|
|
34
40
|
import { applyFormChanges } from "./form/apply.mjs";
|
|
35
41
|
import { buildFormRebase } from "./form/rebase.mjs";
|
|
36
42
|
import { unionVariantChanged } from "./form/union-detect.mjs";
|
|
37
43
|
import { DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, buildGridClasses, parseColSpan, parseRowSpan, resolveGridSpec } from "./form/grid.mjs";
|
|
38
44
|
import { resolveSingularLabel } from "./form/labels.mjs";
|
|
39
|
-
import {
|
|
45
|
+
import { DEV } from "./shared/dev.mjs";
|
|
46
|
+
import { resolveComponent } from "./shared/resolve-component.mjs";
|
|
47
|
+
import { toDate, utcDay } from "./shared/to-date.mjs";
|
|
40
48
|
import { getColumn, getFilterableColumns, getSortableColumns } from "./table/column-resolver.mjs";
|
|
41
49
|
import { navigateHrefFor } from "./table/navigate-href.mjs";
|
|
42
50
|
import { buildModelRoutes } from "./nav/model-routes.mjs";
|
|
43
51
|
import { compareExact } from "@atscript/db/meta";
|
|
44
|
-
export { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, NUMERIC_VALUE_KINDS, StaticFieldResolver, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, coerceNumericText, collectDirtyPaths, compareExact, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp,
|
|
52
|
+
export { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_HTTP_PATH, DB_REL_FK, DB_UNIT, DB_UNIT_REF, DEFAULT_BOOLEAN_LABELS, DEFAULT_COL_SPAN, DEFAULT_ROW_SPAN, DEV, EXPECT_ARRAY_UNIQUE_ITEMS, EXPECT_MAX_LENGTH, FORM_ERROR_KEY, META_DEFAULT, META_DESCRIPTION, META_ID, META_LABEL, META_READONLY, META_REQUIRED, META_SENSITIVE, NUMERIC_VALUE_KINDS, StaticFieldResolver, UI_DICT_ATTR, UI_DICT_DESCR, UI_DICT_FILTERABLE, UI_DICT_LABEL, UI_DICT_SEARCHABLE, UI_DICT_SORTABLE, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_ATTR, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HIDDEN, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_OPTIONS, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_FN_VALUE, UI_FORM_GRID_COL_SPAN, UI_FORM_GRID_ROW_SPAN, UI_FORM_HIDDEN, UI_FORM_HINT, UI_FORM_LABEL_SINGULAR, UI_FORM_OPTIONAL_MODE, UI_FORM_OPTIONS, UI_FORM_ORDER, UI_FORM_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUBMIT_TEXT, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_TYPE, UI_FORM_VALIDATE, UI_FORM_VALIDATE_ERROR_CODE, UI_NAV_GROUP, UI_NAV_HIDDEN, UI_NAV_ORDER, UI_TABLE_ATTR, UI_TABLE_CLASSES, UI_TABLE_COMPONENT, UI_TABLE_EXCLUDE, UI_TABLE_FILL, UI_TABLE_FN_ATTR, UI_TABLE_FN_CLASSES, UI_TABLE_FN_PREFIX, UI_TABLE_FN_STYLES, UI_TABLE_ORDER, UI_TABLE_SELECT_WITH, UI_TABLE_STYLES, UI_TABLE_TYPE, UI_TABLE_WIDTH, UI_TYPE, UI_VALUE_LABEL, VALUE_HELP_OPTIONS_CAP, ValueHelpClient, WF_ACTION_WITH_DATA, activateUiTexts, applyFormChanges, arrangeText, asArray, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, buildGridClasses, buildModelRoutes, buildUnionVariants, codeOf, coerceNumericText, collectDirtyPaths, compareExact, createDistinctPager, createFieldValidator, createFormData, createFormDef, createFormValueResolver, createMetaClient, createTableDef, createUiTexts, deepClone, deepEqual, defaultResolver, deleteByPath, deserializeServedType, detectUnionVariant, displayValue, emptiedValue, enforceScale, escapeRegex, extractFieldLiteralOptions, extractLiteralOptions, extractMeasurement, extractValueHelp, fieldText, formPayload, formatDecimalForDisplay, getByPath, getColumn, getCurrencyDecimals, getCurrencyDisplayParts, getDecimalSeparator, getDeclaredFormAction, getDeclaredFormActions, getDefaultClientFactory, getDefaultOptionalMode, getDefaultValidatorPlugins, getFieldMeta, getFilterableColumns, getFormValidator, getMetaCacheIdentity, getMetaEntry, getMetaTableDef, getResolver, getSortableColumns, getThousandsSeparator, getUiTexts, groupInteger, hasComputedAnnotations, hasFieldMeta, invalidateValueHelpCache, isArrayField, isContainerKind, isFieldDisabled, isFieldHidden, isFieldReadonly, isFieldRequired, isNumericText, isObjectField, isPathDirty, isPickerDeclined, isPureLiteralUnion, isServedType, isTupleField, isUnionField, iteratePathAncestors, joinDecimalString, joinPath, listsDictionary, loadValueHelpTexts, markServedType, mergeErrorMaps, mergeFilters, navigateHrefFor, normalizeLoadedEmpty, numberAdornment, omitDerivedFields, omitPaths, omitSkippedNavFields, onMetaCacheReset, onUiLocaleChange, onValueHelpTexts, optKey, optLabel, optionLabel, optionValue, parentPrefix, parseColSpan, parseDecimalInput, parseRowSpan, parseStaticAttrs, parseStaticOptions, refText, resetDefaultClientFactory, resetMetaCache, resetValueHelpCache, resolveAttrs, resolveComponent, resolveFieldProp, resolveFormProp, resolveGridSpec, resolveMeasurement, resolveOptionalMode, resolveOptions, resolveSingularLabel, resolveStatic, resolveValueHelp, retainMetaEntry, setByPath, setDefaultClientFactory, setDefaultOptionalMode, setDefaultValidatorPlugins, setMetaCacheIdentity, setMetaCacheMaxEntries, setResolver, setUiLocale, setValueHelpCacheTtl, splitDecimalString, stableValueKey, str, toDate, unionVariantChanged, userText, utcDay, validatorErrorsToMap, valueHelpColumns, valueHelpDictPaths, valueHelpDropdown, valueHelpFills, valueHelpKey, valueHelpOptions, valueHelpRowText, valueHelpScope, valueHelpSelect, valueHelpSource, valueHelpText, valueLabelOf, valuePickerMode };
|
|
@@ -18,6 +18,23 @@ const BUILTIN_TYPES = [
|
|
|
18
18
|
"paragraph",
|
|
19
19
|
"action"
|
|
20
20
|
];
|
|
21
|
+
/**
|
|
22
|
+
* The optional `arrangement` of `@ui.valueLabel`, `@ui.dict.label` and
|
|
23
|
+
* `@ui.valueHelp.label`: how a code shows with its text.
|
|
24
|
+
*/
|
|
25
|
+
function arrangementArg(defaultNote) {
|
|
26
|
+
return {
|
|
27
|
+
optional: true,
|
|
28
|
+
name: "arrangement",
|
|
29
|
+
type: "string",
|
|
30
|
+
description: "How the code and its text are shown: `textKey` — `Berlin (BER)`; `keyText` — `BER (Berlin)`; `text` — `Berlin`. An empty text shows the code alone. " + defaultNote,
|
|
31
|
+
values: [
|
|
32
|
+
"textKey",
|
|
33
|
+
"keyText",
|
|
34
|
+
"text"
|
|
35
|
+
]
|
|
36
|
+
};
|
|
37
|
+
}
|
|
21
38
|
const COL_SPAN_VALUES = [
|
|
22
39
|
"1",
|
|
23
40
|
"2",
|
|
@@ -529,6 +546,17 @@ const uiAnnotations = { ui: {
|
|
|
529
546
|
},
|
|
530
547
|
validate: require_value_help_validation.validateColumn
|
|
531
548
|
}),
|
|
549
|
+
label: new _atscript_core.AnnotationSpec({
|
|
550
|
+
description: "The text of this binding's codes: a string field of the dictionary, instead of its `@ui.dict.label`. A code shows with the text of its dictionary row in table cells, export, filter chips, read-only form fields and the reference field while it is not focused; the pickers show it as each row's text. Sorting and filtering stay on the code. An `@ui.valueLabel` of the field wins where the row holds its text.\n\n**Example:**\n```atscript\n@db.rel.FK\n@ui.valueHelp.label 'fullName', 'text'\nassigneeId?: User.id\n```\n",
|
|
551
|
+
nodeType: ["prop"],
|
|
552
|
+
argument: [{
|
|
553
|
+
name: "field",
|
|
554
|
+
type: "string",
|
|
555
|
+
description: "A string field of the dictionary holding the text of the codes.",
|
|
556
|
+
fieldScope: require_value_help_validation.valueHelpScopes.bindingField
|
|
557
|
+
}, arrangementArg("Default: the dictionary's (`@ui.dict.label`), else `textKey`.")],
|
|
558
|
+
validate: require_value_help_validation.validateValueHelpLabel
|
|
559
|
+
}),
|
|
532
560
|
distinct: new _atscript_core.AnnotationSpec({
|
|
533
561
|
description: "Offers a **distinct-values picker** for this column in table filters: the values already stored, read from the table's own controller via `$groupBy`. Shown only when the server reports the field filterable and groupable, and the field has no dictionary binding, FK help or literal options. Not offered in forms.\n\n**Example:**\n```atscript\n@ui.valueHelp.distinct\ncity?: string\n```\n",
|
|
534
562
|
nodeType: ["prop", "type"],
|
|
@@ -554,7 +582,7 @@ const uiAnnotations = { ui: {
|
|
|
554
582
|
validate: require_value_help_validation.validateLiteralLabel
|
|
555
583
|
}),
|
|
556
584
|
valueLabel: new _atscript_core.AnnotationSpec({
|
|
557
|
-
description: "Shows this field's value — a code — together with its text, read from a string field of the same interface: in table cells, export, read-only form fields and the reference field while it is not focused.
|
|
585
|
+
description: "Shows this field's value — a code — together with its text, read from a string field of the same interface: in table cells, export, read-only form fields and the reference field while it is not focused. Wins over a dictionary label (`@ui.dict.label`, `@ui.valueHelp.label`) wherever the row is at hand; filter chips show the dictionary's. Sorting and filtering stay on the code. On a field with a value-help binding, let the pick fill the text (`@ui.valueHelp.fill`), or it goes stale after a pick. Not passed through references.\n\n**Example:**\n```atscript\n@ui.valueHelp City, 'code'\n@ui.valueHelp.fill 'cityName', 'name'\n@ui.valueLabel 'cityName'\ncity?: string\ncityName?: string\n```\n",
|
|
558
586
|
nodeType: ["prop"],
|
|
559
587
|
passedWhenReferred: false,
|
|
560
588
|
argument: [{
|
|
@@ -562,24 +590,15 @@ const uiAnnotations = { ui: {
|
|
|
562
590
|
type: "string",
|
|
563
591
|
description: "A string field of this interface holding the text of this field's value — not this field.",
|
|
564
592
|
valueScope: require_value_help_validation.valueLabelFields
|
|
565
|
-
},
|
|
566
|
-
optional: true,
|
|
567
|
-
name: "arrangement",
|
|
568
|
-
type: "string",
|
|
569
|
-
description: "How the code and its text are shown: `textKey` (default) — `Berlin (BER)`; `keyText` — `BER (Berlin)`; `text` — `Berlin`. An empty text shows the code alone.",
|
|
570
|
-
values: [
|
|
571
|
-
"textKey",
|
|
572
|
-
"keyText",
|
|
573
|
-
"text"
|
|
574
|
-
]
|
|
575
|
-
}],
|
|
593
|
+
}, arrangementArg("Default: `textKey`.")],
|
|
576
594
|
validate: require_value_help_validation.validateValueLabel
|
|
577
595
|
}),
|
|
578
596
|
dict: {
|
|
579
597
|
label: new _atscript_core.AnnotationSpec({
|
|
580
|
-
description: "
|
|
598
|
+
description: "The label of this dictionary's records: every code bound to it (`@db.rel.FK` or `@ui.valueHelp`) shows with this field's text — in table cells, export, filter chips, read-only form fields and the reference field while it is not focused — and the pickers show it as each row's text; a table of these records names a row an action runs on by it in the action dialog. A binding may name another field (`@ui.valueHelp.label`). Without it, codes show alone.\n\n**Example:**\n```atscript\n@ui.dict.label 'keyText'\nname: string\n```\n",
|
|
581
599
|
nodeType: ["prop"],
|
|
582
|
-
passedWhenReferred: false
|
|
600
|
+
passedWhenReferred: false,
|
|
601
|
+
argument: arrangementArg("Default: `textKey`.")
|
|
583
602
|
}),
|
|
584
603
|
descr: new _atscript_core.AnnotationSpec({
|
|
585
604
|
description: "Marks this field as the secondary description in value-help display",
|