@chobantonov/jsonforms-extended-spec 0.0.0-stage → 0.3.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/LICENSE +21 -0
- package/README.md +126 -2
- package/conformance/authoring.json +2680 -0
- package/conformance/behavior.json +1602 -0
- package/conformance/config-consumption.json +1542 -0
- package/conformance/expected-invalid.json +20 -0
- package/docs/audit.md +150 -0
- package/docs/conditional-fields.md +122 -0
- package/docs/draft-07-visual-support.md +43 -0
- package/docs/external-resources-proposal.md +536 -0
- package/docs/implementation-guide.md +233 -0
- package/docs/implementation-pitfalls.md +968 -0
- package/docs/implementation-web-typescript.md +41 -0
- package/docs/renderer-and-demo.md +1347 -0
- package/docs/renderer-selection.md +99 -0
- package/docs/spec.md +8470 -0
- package/docs/todo.md +166 -0
- package/examples/README.md +127 -0
- package/examples/additional-errors/README.md +176 -0
- package/examples/additional-errors/config.json +3 -0
- package/examples/additional-errors/data.json +11 -0
- package/examples/additional-errors/schema.json +56 -0
- package/examples/additional-errors/translations.json +64 -0
- package/examples/additional-errors/uischema.json +158 -0
- package/examples/additional-items-pagination/README.md +8 -0
- package/examples/additional-items-pagination/config.json +10 -0
- package/examples/additional-items-pagination/data.json +22 -0
- package/examples/additional-items-pagination/schema.json +30 -0
- package/examples/additional-items-pagination/translations.json +16 -0
- package/examples/additional-items-pagination/uischema.json +39 -0
- package/examples/additional-properties/README.md +203 -0
- package/examples/additional-properties/config.json +5 -0
- package/examples/additional-properties/data.json +31 -0
- package/examples/additional-properties/schema.json +78 -0
- package/examples/additional-properties/translations.json +80 -0
- package/examples/additional-properties/uischema.json +104 -0
- package/examples/ag-grid/README.md +62 -0
- package/examples/ag-grid/config.json +14 -0
- package/examples/ag-grid/data.json +124 -0
- package/examples/ag-grid/schema.json +48 -0
- package/examples/ag-grid/translations.json +58 -0
- package/examples/ag-grid/uischema.json +671 -0
- package/examples/array-choices/README.md +150 -0
- package/examples/array-choices/config.json +4 -0
- package/examples/array-choices/data.json +10 -0
- package/examples/array-choices/schema.json +68 -0
- package/examples/array-choices/translations.json +64 -0
- package/examples/array-choices/uischema.json +97 -0
- package/examples/array-controls/README.md +237 -0
- package/examples/array-controls/config.json +4 -0
- package/examples/array-controls/data.json +147 -0
- package/examples/array-controls/schema.json +374 -0
- package/examples/array-controls/translations.json +186 -0
- package/examples/array-controls/uischema.json +685 -0
- package/examples/array-detail-modes/README.md +11 -0
- package/examples/array-detail-modes/data.json +38 -0
- package/examples/array-detail-modes/schema.json +89 -0
- package/examples/array-detail-modes/translations.json +36 -0
- package/examples/array-detail-modes/uischema.json +73 -0
- package/examples/array-detail-modes/uischemas.d.mts +2 -0
- package/examples/array-detail-modes/uischemas.json +15 -0
- package/examples/boolean-controls/README.md +109 -0
- package/examples/boolean-controls/config.json +3 -0
- package/examples/boolean-controls/data.json +27 -0
- package/examples/boolean-controls/schema.json +98 -0
- package/examples/boolean-controls/translations.json +94 -0
- package/examples/boolean-controls/uischema.json +126 -0
- package/examples/button-actions/README.md +259 -0
- package/examples/button-actions/config.json +7 -0
- package/examples/button-actions/data.json +5 -0
- package/examples/button-actions/host.mjs +14 -0
- package/examples/button-actions/schema.json +20 -0
- package/examples/button-actions/translations.json +60 -0
- package/examples/button-actions/uischema.json +179 -0
- package/examples/catalog.json +634 -0
- package/examples/categorization/README.md +132 -0
- package/examples/categorization/config.json +7 -0
- package/examples/categorization/data.json +8 -0
- package/examples/categorization/schema.json +29 -0
- package/examples/categorization/translations.json +72 -0
- package/examples/categorization/uischema.json +288 -0
- package/examples/choice-controls/README.md +136 -0
- package/examples/choice-controls/config.json +10 -0
- package/examples/choice-controls/data.json +61 -0
- package/examples/choice-controls/schema.json +406 -0
- package/examples/choice-controls/translations.json +154 -0
- package/examples/choice-controls/uischema.json +575 -0
- package/examples/choice-controls/uischemas.d.mts +2 -0
- package/examples/choice-controls/uischemas.json +16 -0
- package/examples/code-editor/README.md +74 -0
- package/examples/code-editor/data.json +8 -0
- package/examples/code-editor/schema.json +28 -0
- package/examples/code-editor/translations.json +20 -0
- package/examples/code-editor/uischema.json +77 -0
- package/examples/collection-pagination/README.md +5 -0
- package/examples/collection-pagination/config.json +1 -0
- package/examples/collection-pagination/data.json +64 -0
- package/examples/collection-pagination/schema.json +23 -0
- package/examples/collection-pagination/translations.json +14 -0
- package/examples/collection-pagination/uischema.json +14 -0
- package/examples/color-control/README.md +154 -0
- package/examples/color-control/config.json +7 -0
- package/examples/color-control/data.json +11 -0
- package/examples/color-control/schema.json +61 -0
- package/examples/color-control/translations.json +76 -0
- package/examples/color-control/uischema.json +106 -0
- package/examples/combinators/README.md +223 -0
- package/examples/combinators/config.json +9 -0
- package/examples/combinators/data.json +23 -0
- package/examples/combinators/schema.json +232 -0
- package/examples/combinators/translations.json +178 -0
- package/examples/combinators/uischema.json +158 -0
- package/examples/conditional-fields/README.md +27 -0
- package/examples/conditional-fields/config.json +5 -0
- package/examples/conditional-fields/data.json +7 -0
- package/examples/conditional-fields/schema.json +59 -0
- package/examples/conditional-fields/translations.json +32 -0
- package/examples/conditional-fields/uischema.json +131 -0
- package/examples/container-validation-indicator/README.md +187 -0
- package/examples/container-validation-indicator/config.json +9 -0
- package/examples/container-validation-indicator/data.json +68 -0
- package/examples/container-validation-indicator/schema.json +222 -0
- package/examples/container-validation-indicator/translations.json +120 -0
- package/examples/container-validation-indicator/uischema.json +98 -0
- package/examples/cron-control/README.md +155 -0
- package/examples/cron-control/data.json +15 -0
- package/examples/cron-control/schema.json +72 -0
- package/examples/cron-control/translations.json +80 -0
- package/examples/cron-control/uischema.json +91 -0
- package/examples/destructive-confirmation/README.md +210 -0
- package/examples/destructive-confirmation/config.json +17 -0
- package/examples/destructive-confirmation/data.json +86 -0
- package/examples/destructive-confirmation/schema.json +204 -0
- package/examples/destructive-confirmation/translations.json +112 -0
- package/examples/destructive-confirmation/uischema.json +105 -0
- package/examples/draft-07-metaschema/README.md +11 -0
- package/examples/draft-07-metaschema/config.json +3 -0
- package/examples/draft-07-metaschema/data.json +25 -0
- package/examples/draft-07-metaschema/schema.json +172 -0
- package/examples/draft-07-metaschema/translations.json +10 -0
- package/examples/draft-07-metaschema/uischema.json +14 -0
- package/examples/dynamic-playground/README.md +95 -0
- package/examples/dynamic-playground/config.json +8 -0
- package/examples/dynamic-playground/configuration.json +152 -0
- package/examples/dynamic-playground/data.json +15 -0
- package/examples/dynamic-playground/dynamic-uischema.json +379 -0
- package/examples/dynamic-playground/host.mjs +37 -0
- package/examples/dynamic-playground/schema.json +48 -0
- package/examples/dynamic-playground/translations.json +76 -0
- package/examples/dynamic-playground/uischema.json +36 -0
- package/examples/editor-details/README.md +10 -0
- package/examples/editor-details/data.json +18 -0
- package/examples/editor-details/schema.json +49 -0
- package/examples/editor-details/translations.json +28 -0
- package/examples/editor-details/uischema.json +53 -0
- package/examples/editor-details/uischemas.d.mts +2 -0
- package/examples/editor-details/uischemas.json +14 -0
- package/examples/file-control/README.md +108 -0
- package/examples/file-control/data.json +28 -0
- package/examples/file-control/schema.json +89 -0
- package/examples/file-control/translations.json +46 -0
- package/examples/file-control/uischema.json +152 -0
- package/examples/group-layout/README.md +149 -0
- package/examples/group-layout/config.json +10 -0
- package/examples/group-layout/data.json +9 -0
- package/examples/group-layout/schema.json +51 -0
- package/examples/group-layout/translations.json +62 -0
- package/examples/group-layout/uischema.json +249 -0
- package/examples/index.d.ts +17 -0
- package/examples/index.js +69 -0
- package/examples/input-adornments/README.md +68 -0
- package/examples/input-adornments/data.json +41 -0
- package/examples/input-adornments/schema.json +207 -0
- package/examples/input-adornments/translations.json +106 -0
- package/examples/input-adornments/uischema.json +695 -0
- package/examples/job-application/README.md +23 -0
- package/examples/job-application/config.json +10 -0
- package/examples/job-application/data.json +68 -0
- package/examples/job-application/schema.json +196 -0
- package/examples/job-application/translations.json +388 -0
- package/examples/job-application/uischema.json +218 -0
- package/examples/job-application/uischemas.json +153 -0
- package/examples/json-editor/README.md +28 -0
- package/examples/json-editor/schema.json +1 -0
- package/examples/json-editor/translations.json +10 -0
- package/examples/json-editor/uischema.json +16 -0
- package/examples/json-inference/README.md +33 -0
- package/examples/json-inference/translations.json +10 -0
- package/examples/json-inference/uischema.json +16 -0
- package/examples/kitchen-sink/README.md +86 -0
- package/examples/kitchen-sink/config.json +14 -0
- package/examples/kitchen-sink/data.json +263 -0
- package/examples/kitchen-sink/invalid-data.json +263 -0
- package/examples/kitchen-sink/schema.json +515 -0
- package/examples/kitchen-sink/translations.json +270 -0
- package/examples/kitchen-sink/uischema.json +722 -0
- package/examples/label-interpolation/README.md +241 -0
- package/examples/label-interpolation/config.json +14 -0
- package/examples/label-interpolation/data.json +13 -0
- package/examples/label-interpolation/schema.json +64 -0
- package/examples/label-interpolation/translations.json +94 -0
- package/examples/label-interpolation/uischema.json +379 -0
- package/examples/layout-sizing/README.md +162 -0
- package/examples/layout-sizing/config.json +10 -0
- package/examples/layout-sizing/data.json +14 -0
- package/examples/layout-sizing/schema.json +58 -0
- package/examples/layout-sizing/translations.json +42 -0
- package/examples/layout-sizing/uischema.json +558 -0
- package/examples/markup-label/README.md +109 -0
- package/examples/markup-label/config.json +16 -0
- package/examples/markup-label/data.json +5 -0
- package/examples/markup-label/schema.json +24 -0
- package/examples/markup-label/translations.json +40 -0
- package/examples/markup-label/uischema.json +149 -0
- package/examples/mixed-control/README.md +164 -0
- package/examples/mixed-control/config.json +11 -0
- package/examples/mixed-control/data.json +70 -0
- package/examples/mixed-control/schema.json +221 -0
- package/examples/mixed-control/translations.json +158 -0
- package/examples/mixed-control/uischema.json +211 -0
- package/examples/null-control/README.md +111 -0
- package/examples/null-control/config.json +4 -0
- package/examples/null-control/data.json +6 -0
- package/examples/null-control/schema.json +36 -0
- package/examples/null-control/translations.json +42 -0
- package/examples/null-control/uischema.json +56 -0
- package/examples/numeric-controls/README.md +94 -0
- package/examples/numeric-controls/config.json +4 -0
- package/examples/numeric-controls/data.json +8 -0
- package/examples/numeric-controls/schema.json +52 -0
- package/examples/numeric-controls/translations.json +56 -0
- package/examples/numeric-controls/uischema.json +77 -0
- package/examples/object-control/README.md +220 -0
- package/examples/object-control/config.json +4 -0
- package/examples/object-control/data.json +62 -0
- package/examples/object-control/schema.json +252 -0
- package/examples/object-control/translations.json +160 -0
- package/examples/object-control/uischema.json +275 -0
- package/examples/object-control/uischemas.d.mts +2 -0
- package/examples/object-control/uischemas.json +59 -0
- package/examples/password-control/README.md +119 -0
- package/examples/password-control/config.json +3 -0
- package/examples/password-control/data.json +18 -0
- package/examples/password-control/schema.json +65 -0
- package/examples/password-control/translations.json +64 -0
- package/examples/password-control/uischema.json +94 -0
- package/examples/pre-touch-errors/README.md +176 -0
- package/examples/pre-touch-errors/config.json +4 -0
- package/examples/pre-touch-errors/data.json +5 -0
- package/examples/pre-touch-errors/schema.json +56 -0
- package/examples/pre-touch-errors/translations.json +68 -0
- package/examples/pre-touch-errors/uischema.json +85 -0
- package/examples/presentation/README.md +148 -0
- package/examples/presentation/config.json +9 -0
- package/examples/presentation/data.json +6 -0
- package/examples/presentation/schema.json +21 -0
- package/examples/presentation/translations.json +64 -0
- package/examples/presentation/uischema.json +210 -0
- package/examples/property-pagination/README.md +5 -0
- package/examples/property-pagination/config.json +1 -0
- package/examples/property-pagination/data.json +17 -0
- package/examples/property-pagination/schema.json +14 -0
- package/examples/property-pagination/translations.json +10 -0
- package/examples/property-pagination/uischema.json +24 -0
- package/examples/recursive-tree/README.md +49 -0
- package/examples/recursive-tree/config.json +1 -0
- package/examples/recursive-tree/data.json +40 -0
- package/examples/recursive-tree/schema.json +89 -0
- package/examples/recursive-tree/translations.json +42 -0
- package/examples/recursive-tree/uischema.json +84 -0
- package/examples/recursive-tree/uischemas.d.mts +2 -0
- package/examples/recursive-tree/uischemas.json +51 -0
- package/examples/split-layout/README.md +123 -0
- package/examples/split-layout/config.json +3 -0
- package/examples/split-layout/data.json +13 -0
- package/examples/split-layout/schema.json +50 -0
- package/examples/split-layout/translations.json +50 -0
- package/examples/split-layout/uischema.json +204 -0
- package/examples/string-controls/README.md +159 -0
- package/examples/string-controls/config.json +5 -0
- package/examples/string-controls/data.json +13 -0
- package/examples/string-controls/schema.json +70 -0
- package/examples/string-controls/translations.json +76 -0
- package/examples/string-controls/uischema.json +148 -0
- package/examples/table-row-details/README.md +69 -0
- package/examples/table-row-details/config.json +7 -0
- package/examples/table-row-details/data.json +280 -0
- package/examples/table-row-details/schema.json +61 -0
- package/examples/table-row-details/translations.json +56 -0
- package/examples/table-row-details/uischema.json +1303 -0
- package/examples/template-layout/README.md +250 -0
- package/examples/template-layout/config.json +9 -0
- package/examples/template-layout/data.json +20 -0
- package/examples/template-layout/host.mjs +13 -0
- package/examples/template-layout/schema.json +48 -0
- package/examples/template-layout/translations.json +70 -0
- package/examples/template-layout/uischema.json +177 -0
- package/examples/template-slots/README.md +19 -0
- package/examples/template-slots/data.json +4 -0
- package/examples/template-slots/schema.json +11 -0
- package/examples/template-slots/translations.json +26 -0
- package/examples/template-slots/uischema.json +47 -0
- package/examples/template-slots/uischemas.d.mts +2 -0
- package/examples/template-slots/uischemas.json +56 -0
- package/examples/temporal-controls/README.md +325 -0
- package/examples/temporal-controls/data.json +44 -0
- package/examples/temporal-controls/schema.json +208 -0
- package/examples/temporal-controls/translations.json +156 -0
- package/examples/temporal-controls/uischema.json +297 -0
- package/examples/tree-max-depth/README.md +5 -0
- package/examples/tree-max-depth/config.json +3 -0
- package/examples/tree-max-depth/data.json +31 -0
- package/examples/tree-max-depth/schema.json +258 -0
- package/examples/tree-max-depth/translations.json +42 -0
- package/examples/tree-max-depth/uischema.json +16 -0
- package/examples/tree-max-depth/uischemas.d.mts +2 -0
- package/examples/tree-max-depth/uischemas.json +50 -0
- package/examples/tuple-control/README.md +335 -0
- package/examples/tuple-control/config.json +4 -0
- package/examples/tuple-control/data.json +61 -0
- package/examples/tuple-control/schema.json +218 -0
- package/examples/tuple-control/translations.json +142 -0
- package/examples/tuple-control/uischema.json +128 -0
- package/examples/tuple-control/uischemas.d.mts +2 -0
- package/examples/tuple-control/uischemas.json +125 -0
- package/examples/validator-profile/README.md +197 -0
- package/examples/validator-profile/config.json +9 -0
- package/examples/validator-profile/data.json +16 -0
- package/examples/validator-profile/schema.json +139 -0
- package/examples/validator-profile/translations.json +34 -0
- package/examples/validator-profile/uischema.json +59 -0
- package/package.json +83 -3
- package/provenance.json +140 -0
- package/schemas/README.md +82 -0
- package/schemas/example.schema.json +37 -0
- package/schemas/jsonforms-config.schema.json +427 -0
- package/schemas/jsonforms-dynamic-uischema.schema.json +220 -0
- package/schemas/jsonforms-extended-config.schema.json +332 -0
- package/schemas/jsonforms-extended-uischema.schema.json +1932 -0
- package/schemas/jsonforms-rule.schema.json +104 -0
- package/schemas/jsonforms-uischema.schema.json +1434 -0
- package/typescript/README.md +546 -0
- package/typescript/lib/authoring/cssLength.d.ts +33 -0
- package/typescript/lib/authoring/cssLength.js +25 -0
- package/typescript/lib/authoring/dynamic.d.ts +73 -0
- package/typescript/lib/authoring/dynamic.js +8 -0
- package/typescript/lib/authoring/forSchema.d.ts +385 -0
- package/typescript/lib/authoring/forSchema.js +84 -0
- package/typescript/lib/authoring/schemaTypes.d.ts +111 -0
- package/typescript/lib/authoring/schemaTypes.js +15 -0
- package/typescript/lib/index.d.ts +4 -0
- package/typescript/lib/index.js +20 -0
- package/typescript/package.json +1 -0
- package/typescript/src/authoring/cssLength.ts +79 -0
- package/typescript/src/authoring/dynamic.ts +96 -0
- package/typescript/src/authoring/forSchema.ts +428 -0
- package/typescript/src/authoring/schemaTypes.ts +143 -0
- package/typescript/src/index.ts +4 -0
- package/typescript/test/schemaContract.test.ts +638 -0
- package/typescript/test/tsconfig.json +10 -0
- package/typescript/test/typedAuthoring.test.ts +151 -0
- package/typescript/test/typedAuthoringCoverage.test.ts +178 -0
- package/typescript/test/typedAuthoringCssLength.test.ts +81 -0
- package/typescript/test/typedAuthoringNames.test.ts +90 -0
- package/typescript/test/typedDynamic.test.ts +88 -0
- package/typescript/tsconfig.json +15 -0
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# Numeric controls: numbers and integers
|
|
2
|
+
|
|
3
|
+
**Example ID:** `numeric-controls`\
|
|
4
|
+
**Demo entry:** **Spec: Numeric controls: numbers and integers** (`#spec-numeric-controls`)\
|
|
5
|
+
**Domain:** office stock line\
|
|
6
|
+
**Specs covered:**
|
|
7
|
+
|
|
8
|
+
- [Numeric controls: numbers and integers](../../docs/spec.md#1819-scalar-controls-and-temporal-editing)
|
|
9
|
+
- [Numeric parsing and representation limits](../../docs/spec.md#1819-scalar-controls-and-temporal-editing)
|
|
10
|
+
- [Slider control](../../docs/spec.md#1819-scalar-controls-and-temporal-editing)
|
|
11
|
+
|
|
12
|
+
The three go together: they are the same value seen through three editors, and
|
|
13
|
+
the parsing rules apply to all of them.
|
|
14
|
+
|
|
15
|
+
## Files
|
|
16
|
+
|
|
17
|
+
| File | Role |
|
|
18
|
+
| --- | --- |
|
|
19
|
+
| `schema.json` | Integer and number properties with bounds, `multipleOf`, an exclusive bound, a negative range and a slider-eligible property. |
|
|
20
|
+
| `uischema.json` | The same values through plain entry, `options.step` and `options.slider`. |
|
|
21
|
+
| `data.json` | Deliberately invalid in two places, and valid-but-easily-mishandled in several others. |
|
|
22
|
+
| `config.json` | `restrict: true` and `showUnfocusedDescription`, both top level. |
|
|
23
|
+
| `translations.json` | English and Bulgarian keyword error messages. |
|
|
24
|
+
|
|
25
|
+
## Validation state
|
|
26
|
+
|
|
27
|
+
Validated with Ajv (`allErrors`, `strict: false`), the supplied data produces
|
|
28
|
+
exactly two errors:
|
|
29
|
+
|
|
30
|
+
| Instance path | Keyword | Message |
|
|
31
|
+
| --- | --- | --- |
|
|
32
|
+
| `/batchCount` | `multipleOf` | must be multiple of 2 |
|
|
33
|
+
| `/weightKg` | `exclusiveMinimum` | must be > 0 |
|
|
34
|
+
|
|
35
|
+
Everything else is valid, including the values most likely to be mishandled.
|
|
36
|
+
|
|
37
|
+
## What to try
|
|
38
|
+
|
|
39
|
+
**Type `1.9` into Quantity.** It must stay `1.9` and report "must be integer".
|
|
40
|
+
It must not become `1`. `parseInt('1.9')` is `1`, which silently commits a
|
|
41
|
+
different number from the one on screen - the specification names this case,
|
|
42
|
+
and it was the behaviour here until recently.
|
|
43
|
+
|
|
44
|
+
**Type `1e3` into Quantity.** It must become `1000`, not `1`. The spec: an
|
|
45
|
+
integer editor may refuse exponent syntax, "but it must not interpret 1e3 as
|
|
46
|
+
1".
|
|
47
|
+
|
|
48
|
+
**Clear a field.** It must become empty, not `0`. `Number('')` is `0`, so a
|
|
49
|
+
parser that does not test emptiness first turns clearing into committing a
|
|
50
|
+
zero.
|
|
51
|
+
|
|
52
|
+
**Zero and negative values are real data.** Quantity is `0`, weight is `0`,
|
|
53
|
+
discount is `0` and tolerance is `-2.5`. None is an empty field, and none
|
|
54
|
+
should be replaced by a default or a placeholder. The slider shows `0` rather
|
|
55
|
+
than jumping to its `default` of `10` - the truthiness fallback the spec
|
|
56
|
+
forbids, and the bug this example was written to catch.
|
|
57
|
+
|
|
58
|
+
**Switch the demo to Bulgarian.** The error messages carry `{limit}` and
|
|
59
|
+
`{multipleOf}` placeholders filled from `error.params`. Core does no
|
|
60
|
+
interpolation of its own - the spec puts that on the translator - so a catalog
|
|
61
|
+
message renders literally unless the translator substitutes.
|
|
62
|
+
|
|
63
|
+
## Adapter checks
|
|
64
|
+
|
|
65
|
+
Compare `options.step` with the schema's `multipleOf`, test inclusive and
|
|
66
|
+
exclusive bounds with `restrict`, and verify that zero is shown as a real
|
|
67
|
+
value. An unset slider needs a visible and accessible unset state. Numeric
|
|
68
|
+
entry must avoid committing non-finite numbers or silently losing precision.
|
|
69
|
+
These checks require interaction with the selected renderer, beyond schema
|
|
70
|
+
validation of the fixture.
|
|
71
|
+
|
|
72
|
+
## Fallback behaviour
|
|
73
|
+
|
|
74
|
+
| Situation | Result |
|
|
75
|
+
| --- | --- |
|
|
76
|
+
| No `options.step` | Falls back to the renderer default, not to the schema's `multipleOf` (a known gap). |
|
|
77
|
+
| `slider: true` on a property without `minimum`/`maximum`/`default` | The range tester rejects it and ordinary numeric entry is used. |
|
|
78
|
+
| Unparseable entry | Nothing is committed; the previous value stands. `NaN` and `±Infinity` are never written to form data. |
|
|
79
|
+
|
|
80
|
+
## Conformance scope
|
|
81
|
+
|
|
82
|
+
This walkthrough describes the portable contract. Renderer support must be checked
|
|
83
|
+
by a host adapter; the package validates the authored assets, not live UI behavior.
|
|
84
|
+
|
|
85
|
+
## Standalone host setup
|
|
86
|
+
|
|
87
|
+
Load the JSON assets listed in [the catalog](../catalog.json) into a host
|
|
88
|
+
with the relevant renderer capabilities. No framework registration module is
|
|
89
|
+
required by this package.
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
## Feature navigation
|
|
93
|
+
|
|
94
|
+
Explore one feature at a time using the tabs: **Integers**, **Numbers**, **Slider**. Tab titles are localized in English and Bulgarian. The tabs share the existing form data.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"title": "Office stock line",
|
|
5
|
+
"properties": {
|
|
6
|
+
"quantity": {
|
|
7
|
+
"type": "integer",
|
|
8
|
+
"title": "Quantity",
|
|
9
|
+
"minimum": 0,
|
|
10
|
+
"description": "Whole units only. Typing 1.9 must not silently become 1."
|
|
11
|
+
},
|
|
12
|
+
"batchCount": {
|
|
13
|
+
"type": "integer",
|
|
14
|
+
"title": "Batches",
|
|
15
|
+
"minimum": 1,
|
|
16
|
+
"maximum": 40,
|
|
17
|
+
"multipleOf": 2,
|
|
18
|
+
"description": "Requested in pairs, so valid values are 2, 4, 6 ... 40."
|
|
19
|
+
},
|
|
20
|
+
"unitPrice": {
|
|
21
|
+
"type": "number",
|
|
22
|
+
"title": "Unit price",
|
|
23
|
+
"minimum": 0,
|
|
24
|
+
"multipleOf": 0.01,
|
|
25
|
+
"description": "Currency, so two decimal places."
|
|
26
|
+
},
|
|
27
|
+
"weightKg": {
|
|
28
|
+
"type": "number",
|
|
29
|
+
"title": "Weight (kg)",
|
|
30
|
+
"exclusiveMinimum": 0,
|
|
31
|
+
"maximum": 1200,
|
|
32
|
+
"description": "Must be greater than zero, never exactly zero."
|
|
33
|
+
},
|
|
34
|
+
"discountPercent": {
|
|
35
|
+
"type": "number",
|
|
36
|
+
"title": "Discount",
|
|
37
|
+
"minimum": 0,
|
|
38
|
+
"maximum": 100,
|
|
39
|
+
"default": 10,
|
|
40
|
+
"multipleOf": 5,
|
|
41
|
+
"description": "Rendered as a slider; the range tester needs minimum, maximum and default."
|
|
42
|
+
},
|
|
43
|
+
"toleranceMm": {
|
|
44
|
+
"type": "number",
|
|
45
|
+
"title": "Tolerance (mm)",
|
|
46
|
+
"minimum": -5,
|
|
47
|
+
"maximum": 5,
|
|
48
|
+
"description": "Negative values are ordinary data, not an empty field."
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"required": ["quantity", "unitPrice"]
|
|
52
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"en": {
|
|
3
|
+
"error.minimum": "Enter a value of at least {limit}.",
|
|
4
|
+
"error.maximum": "Enter a value no greater than {limit}.",
|
|
5
|
+
"error.multipleOf": "Enter a multiple of {multipleOf}.",
|
|
6
|
+
"error.type": "Enter a whole number.",
|
|
7
|
+
"error.exclusiveMinimum": "Enter a value greater than {limit}.",
|
|
8
|
+
"error.required": "This field is required.",
|
|
9
|
+
"featureNavigation.section1.label": "Integers",
|
|
10
|
+
"featureNavigation.section2.label": "Numbers",
|
|
11
|
+
"featureNavigation.section3.label": "Slider",
|
|
12
|
+
"specNumericControls.schema.label": "Office stock line",
|
|
13
|
+
"specNumericControls.schema.properties.quantity.label": "Quantity",
|
|
14
|
+
"specNumericControls.schema.properties.quantity.description": "Whole units only. Typing 1.9 must not silently become 1.",
|
|
15
|
+
"specNumericControls.schema.properties.batchCount.label": "Batches",
|
|
16
|
+
"specNumericControls.schema.properties.batchCount.description": "Requested in pairs, so valid values are 2, 4, 6 ... 40.",
|
|
17
|
+
"specNumericControls.schema.properties.unitPrice.label": "Unit price",
|
|
18
|
+
"specNumericControls.schema.properties.unitPrice.description": "Currency, so two decimal places.",
|
|
19
|
+
"specNumericControls.schema.properties.weightKg.label": "Weight (kg)",
|
|
20
|
+
"specNumericControls.schema.properties.weightKg.description": "Must be greater than zero, never exactly zero.",
|
|
21
|
+
"specNumericControls.schema.properties.discountPercent.label": "Discount",
|
|
22
|
+
"specNumericControls.schema.properties.discountPercent.description": "Rendered as a slider; the range tester needs minimum, maximum and default.",
|
|
23
|
+
"specNumericControls.schema.properties.toleranceMm.label": "Tolerance (mm)",
|
|
24
|
+
"specNumericControls.schema.properties.toleranceMm.description": "Negative values are ordinary data, not an empty field.",
|
|
25
|
+
"specNumericControls.ui.elements.0.elements.0.elements.0.text": "Integer entry",
|
|
26
|
+
"specNumericControls.ui.elements.0.elements.1.elements.0.text": "Number entry",
|
|
27
|
+
"specNumericControls.ui.elements.0.elements.2.elements.0.text": "The same number as a slider"
|
|
28
|
+
},
|
|
29
|
+
"bg": {
|
|
30
|
+
"error.minimum": "Въведете стойност поне {limit}.",
|
|
31
|
+
"error.maximum": "Въведете стойност не по-голяма от {limit}.",
|
|
32
|
+
"error.multipleOf": "Въведете число, кратно на {multipleOf}.",
|
|
33
|
+
"error.type": "Въведете цяло число.",
|
|
34
|
+
"error.exclusiveMinimum": "Въведете стойност по-голяма от {limit}.",
|
|
35
|
+
"error.required": "Полето е задължително.",
|
|
36
|
+
"featureNavigation.section1.label": "Цели числа",
|
|
37
|
+
"featureNavigation.section2.label": "Числа",
|
|
38
|
+
"featureNavigation.section3.label": "Плъзгач",
|
|
39
|
+
"specNumericControls.schema.label": "Ред от офисната наличност",
|
|
40
|
+
"specNumericControls.schema.properties.quantity.label": "Количество",
|
|
41
|
+
"specNumericControls.schema.properties.quantity.description": "Само цели единици. Въвеждането на 1.9 не трябва мълчаливо да се превръща в 1.",
|
|
42
|
+
"specNumericControls.schema.properties.batchCount.label": "Партиди",
|
|
43
|
+
"specNumericControls.schema.properties.batchCount.description": "Заявяват се по двойки: допустимите стойности са 2, 4, 6 ... 40.",
|
|
44
|
+
"specNumericControls.schema.properties.unitPrice.label": "Единична цена",
|
|
45
|
+
"specNumericControls.schema.properties.unitPrice.description": "Парична стойност с два знака след десетичния разделител.",
|
|
46
|
+
"specNumericControls.schema.properties.weightKg.label": "Тегло (кг)",
|
|
47
|
+
"specNumericControls.schema.properties.weightKg.description": "Трябва да е по-голямо от нула, никога точно нула.",
|
|
48
|
+
"specNumericControls.schema.properties.discountPercent.label": "Отстъпка",
|
|
49
|
+
"specNumericControls.schema.properties.discountPercent.description": "Показва се като плъзгач; изборът му изисква minimum, maximum и default.",
|
|
50
|
+
"specNumericControls.schema.properties.toleranceMm.label": "Допуск (мм)",
|
|
51
|
+
"specNumericControls.schema.properties.toleranceMm.description": "Отрицателните стойности са данни, а не празно поле.",
|
|
52
|
+
"specNumericControls.ui.elements.0.elements.0.elements.0.text": "Въвеждане на цели числа",
|
|
53
|
+
"specNumericControls.ui.elements.0.elements.1.elements.0.text": "Въвеждане на числа",
|
|
54
|
+
"specNumericControls.ui.elements.0.elements.2.elements.0.text": "Същото число чрез плъзгач"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
{
|
|
2
|
+
"type": "VerticalLayout",
|
|
3
|
+
"elements": [
|
|
4
|
+
{
|
|
5
|
+
"type": "Categorization",
|
|
6
|
+
"elements": [
|
|
7
|
+
{
|
|
8
|
+
"type": "Category",
|
|
9
|
+
"label": "Integers",
|
|
10
|
+
"i18n": "featureNavigation.section1",
|
|
11
|
+
"elements": [
|
|
12
|
+
{
|
|
13
|
+
"type": "Label",
|
|
14
|
+
"text": "Integer entry"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"type": "Control",
|
|
18
|
+
"scope": "#/properties/quantity"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"type": "Control",
|
|
22
|
+
"scope": "#/properties/batchCount",
|
|
23
|
+
"options": {
|
|
24
|
+
"step": 2
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"type": "Category",
|
|
31
|
+
"label": "Numbers",
|
|
32
|
+
"i18n": "featureNavigation.section2",
|
|
33
|
+
"elements": [
|
|
34
|
+
{
|
|
35
|
+
"type": "Label",
|
|
36
|
+
"text": "Number entry"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"type": "Control",
|
|
40
|
+
"scope": "#/properties/unitPrice",
|
|
41
|
+
"options": {
|
|
42
|
+
"step": 0.01,
|
|
43
|
+
"placeholder": "0.00"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"type": "Control",
|
|
48
|
+
"scope": "#/properties/weightKg"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"type": "Control",
|
|
52
|
+
"scope": "#/properties/toleranceMm"
|
|
53
|
+
}
|
|
54
|
+
]
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"type": "Category",
|
|
58
|
+
"label": "Slider",
|
|
59
|
+
"i18n": "featureNavigation.section3",
|
|
60
|
+
"elements": [
|
|
61
|
+
{
|
|
62
|
+
"type": "Label",
|
|
63
|
+
"text": "The same number as a slider"
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"type": "Control",
|
|
67
|
+
"scope": "#/properties/discountPercent",
|
|
68
|
+
"options": {
|
|
69
|
+
"slider": true
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
]
|
|
73
|
+
}
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
]
|
|
77
|
+
}
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
# Example: object control
|
|
2
|
+
|
|
3
|
+
**Example ID:** `object-control`\
|
|
4
|
+
**Demo entry:** **Spec: Object control** (`#spec-object-control`)\
|
|
5
|
+
**Domain:** customer profile\
|
|
6
|
+
**Specs covered:**
|
|
7
|
+
|
|
8
|
+
- [Object controls and additional-property editing](../../docs/spec.md#1816-object-controls-and-dynamic-properties)
|
|
9
|
+
- [Object-level errors and errors without rendered targets](../../docs/spec.md#1816-object-controls-and-dynamic-properties)
|
|
10
|
+
- [Honest rendering of invalid data](../../docs/spec.md#1816-object-controls-and-dynamic-properties)
|
|
11
|
+
|
|
12
|
+
An object control's whole job is to produce **other** controls, so there are
|
|
13
|
+
only two questions worth asking of it: where the nested form came from, and
|
|
14
|
+
what happens to an error that belongs to the object rather than to any field
|
|
15
|
+
inside it.
|
|
16
|
+
|
|
17
|
+
Neither has a single answer. The first has three sources and a precedence
|
|
18
|
+
order with one rule that surprises people; the second has three outcomes
|
|
19
|
+
depending on where core maps the error.
|
|
20
|
+
|
|
21
|
+
> **Dynamic properties are a separate example.** Keys that are data rather than
|
|
22
|
+
> schema — `additionalProperties`, `patternProperties`, `propertyNames`,
|
|
23
|
+
> renaming, the empty-name policy — are covered in
|
|
24
|
+
> [additional-properties](../additional-properties/README.md). This example is
|
|
25
|
+
> about objects whose properties the schema declares.
|
|
26
|
+
|
|
27
|
+
## Files
|
|
28
|
+
|
|
29
|
+
| File | Role |
|
|
30
|
+
| --- | --- |
|
|
31
|
+
| `schema.json` | Ten objects: seven that differ in where their layout comes from, three that fail in ways no single field can explain. |
|
|
32
|
+
| `uischema.json` | Five controls carry `options.detail`, in four different forms; the rest take what they are given. |
|
|
33
|
+
| `uischemas.json` | Registry entries for `address` and `handover`. A **`.ts` file**, because a registry entry carries a tester function and a function is not JSON. The `handover` entry is never used, on purpose. |
|
|
34
|
+
| `data.json` | Two required properties missing, one empty object, one undeclared key, one unmet dependency. The objects that demonstrate layout are all valid, so the error table stays about errors. |
|
|
35
|
+
| `config.json` | `showUnfocusedDescription` and `restrict`, both top level. |
|
|
36
|
+
| `translations.json` | English and Bulgarian, including messages for the three object-level failures. |
|
|
37
|
+
|
|
38
|
+
## What the form contains
|
|
39
|
+
|
|
40
|
+
```text
|
|
41
|
+
Customer profile
|
|
42
|
+
Identity generated layout -> legalName required and missing
|
|
43
|
+
Contact options.detail -> Phone before Email, reversing the schema
|
|
44
|
+
Address registered UI schema -> Street/Postcode, City, then...
|
|
45
|
+
Coordinates nested object -> ...an object inside the nested form
|
|
46
|
+
Handover detail: "GENERATE" -> beats its own registry entry
|
|
47
|
+
---
|
|
48
|
+
Schedule detail: Categorization -> a detail is any layout
|
|
49
|
+
Notes detail with no "type" -> silently ignored
|
|
50
|
+
---
|
|
51
|
+
Compliance detail: Group(Group) -> outer label dropped, inner kept
|
|
52
|
+
---
|
|
53
|
+
Preferences minProperties: 1, {} -> fails on the object
|
|
54
|
+
Routing additionalProperties: false, holds "legacyZone"
|
|
55
|
+
Billing dependencies, PO without a cost centre
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
## Validation state
|
|
59
|
+
|
|
60
|
+
Validated with Ajv (`allErrors`, `strict: false`), the supplied data is
|
|
61
|
+
**invalid**, with five errors:
|
|
62
|
+
|
|
63
|
+
| Keyword | Path | Belongs to |
|
|
64
|
+
| --- | --- | --- |
|
|
65
|
+
| `required` | `/identity` | the missing `legalName` |
|
|
66
|
+
| `required` | `/address` | the missing `city` |
|
|
67
|
+
| `minProperties` | `/preferences` | **the object** |
|
|
68
|
+
| `additionalProperties` | `/routing` | **the object** |
|
|
69
|
+
| `dependencies` | `/billing` | **the object** |
|
|
70
|
+
|
|
71
|
+
Two field errors and three object errors. The split is the point.
|
|
72
|
+
|
|
73
|
+
## Expected behaviour
|
|
74
|
+
|
|
75
|
+
### Where the layout comes from
|
|
76
|
+
|
|
77
|
+
**Identity** has neither `options.detail` nor a registry entry, so the layout is
|
|
78
|
+
**generated** from the schema — which means schema property order: Legal name,
|
|
79
|
+
then Trading name.
|
|
80
|
+
|
|
81
|
+
**Contact** carries `options.detail` on its control, and that detail puts
|
|
82
|
+
**Phone before Email** — the reverse of the schema's order. The reversal is
|
|
83
|
+
what proves the detail was used, and that its scopes (`#/properties/phone`)
|
|
84
|
+
resolved against *the object*, not the root.
|
|
85
|
+
|
|
86
|
+
**Address** carries no detail. Its layout comes from the **UI-schema registry**,
|
|
87
|
+
whose tester matches on the schema's title, and puts Street and Postcode on one
|
|
88
|
+
row above City. The practical difference from `options.detail` is reach:
|
|
89
|
+
`options.detail` is part of the serialized UI model and travels with the form,
|
|
90
|
+
while a registry entry is host code that applies to every matching object
|
|
91
|
+
wherever it appears.
|
|
92
|
+
|
|
93
|
+
**Coordinates** is an object inside Address, dispatched at its own data path
|
|
94
|
+
from the registered layout — nesting is just dispatch, all the way down.
|
|
95
|
+
|
|
96
|
+
**Handover** has a registry entry *and* `detail: "GENERATE"` on its control.
|
|
97
|
+
GENERATE wins, so the layout is generated in schema order — Contact name,
|
|
98
|
+
Window, Gate code. The registry entry reverses that order precisely so the
|
|
99
|
+
difference is visible: had it been used, Gate code would come first.
|
|
100
|
+
|
|
101
|
+
This is the precedence rule that catches people out. `"GENERATE"` is not the
|
|
102
|
+
same as having no detail — it is an instruction, and it **outranks the
|
|
103
|
+
registry**. Resolution runs:
|
|
104
|
+
|
|
105
|
+
1. `options.detail` — `"GENERATE"`, or an object with a `type`
|
|
106
|
+
2. a matching registry entry
|
|
107
|
+
3. a layout generated from the schema
|
|
108
|
+
|
|
109
|
+
### A detail is any layout, and need not be complete
|
|
110
|
+
|
|
111
|
+
**Schedule**'s detail is a `Categorization`, and renders as tabs. Anything that
|
|
112
|
+
dispatches works; a detail is not restricted to rows of controls.
|
|
113
|
+
|
|
114
|
+
A detail also need not name every property. One naming a single control renders
|
|
115
|
+
that control and nothing else — the rest are simply not shown, with no error
|
|
116
|
+
and no leftover.
|
|
117
|
+
|
|
118
|
+
### A detail object with no `type` is not a detail
|
|
119
|
+
|
|
120
|
+
**Notes** carries this, and it does nothing at all:
|
|
121
|
+
|
|
122
|
+
```json
|
|
123
|
+
{ "options": { "detail": { "elements": [ … ] } } }
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
`findUISchema` accepts a detail object only when its `type` is a string, so
|
|
127
|
+
this one is skipped in silence and the generated layout is used instead —
|
|
128
|
+
which is why **both** of Notes's properties appear, though the detail names
|
|
129
|
+
one.
|
|
130
|
+
|
|
131
|
+
Nothing warns you. The form renders, and it ignores what you wrote. If a detail
|
|
132
|
+
appears to have no effect, this is the first thing to check.
|
|
133
|
+
|
|
134
|
+
### The outermost Group supplies the object boundary
|
|
135
|
+
|
|
136
|
+
**Compliance** uses an outer `Group` labelled *"Object group"*, containing
|
|
137
|
+
another `Group` labelled *"Nested group"*. Both are preserved, including their
|
|
138
|
+
labels and layout behavior. The renderer does not add another object frame
|
|
139
|
+
around the outer Group.
|
|
140
|
+
|
|
141
|
+
Generated nested object details use a Group, while the root uses a
|
|
142
|
+
VerticalLayout. Additional Properties belongs inside the object boundary,
|
|
143
|
+
without another enclosing border. Dynamic-only objects omit the empty static
|
|
144
|
+
layout. Untitled nested objects keep their boundary; ordinary VerticalLayouts
|
|
145
|
+
that directly bind fields remain unframed.
|
|
146
|
+
|
|
147
|
+
### Errors that have a control to land on
|
|
148
|
+
|
|
149
|
+
**Legal name** and **City** are both marked and both explain themselves. City's
|
|
150
|
+
is two levels down, inside a registered layout, which changes nothing: the
|
|
151
|
+
error is mapped to `address.city` and that control displays it.
|
|
152
|
+
|
|
153
|
+
### Errors that belong to the object or dynamic-property section
|
|
154
|
+
|
|
155
|
+
| Error | Feedback location |
|
|
156
|
+
| --- | --- |
|
|
157
|
+
| `dependencies` on Billing | Cost centre, when validation maps the failure to that property. |
|
|
158
|
+
| `additionalProperties` on Routing | Error indicator beside Additional Properties, identifying `legacyZone`. |
|
|
159
|
+
| `minProperties` on Preferences | Object-level feedback: beside an object Group title, or above unframed fields. |
|
|
160
|
+
|
|
161
|
+
Object feedback does not summarize child-field errors. Existing invalid values
|
|
162
|
+
remain editable; no property is silently removed or synthesized to satisfy a
|
|
163
|
+
constraint. Correcting the relevant data clears the message after validation.
|
|
164
|
+
|
|
165
|
+
### Validity and localization
|
|
166
|
+
|
|
167
|
+
All five fixture errors contribute to form validity. Their visibility in the
|
|
168
|
+
host's data panel is not a substitute for feedback inside the form. English and
|
|
169
|
+
Bulgarian validation messages are provided in `translations.json`.
|
|
170
|
+
|
|
171
|
+
## Fallback behaviour
|
|
172
|
+
|
|
173
|
+
| Situation | Result |
|
|
174
|
+
| --- | --- |
|
|
175
|
+
| No `detail`, nothing registered | A layout generated from the schema, in property order. |
|
|
176
|
+
| `options.detail` is an object with a `type` | It wins; scopes are relative to the object. |
|
|
177
|
+
| `options.detail` is `"GENERATE"` | A generated layout, **outranking** a matching registry entry. |
|
|
178
|
+
| `options.detail` is an object with no `type` | Ignored in silence; resolution continues to the registry, then to generation. |
|
|
179
|
+
| `options.detail` names only some properties | Only those render. The rest are absent, not empty. |
|
|
180
|
+
| A registry entry matches | Used when the control has no usable `detail` of its own. |
|
|
181
|
+
| The detail's outermost element is a `Group` | Preserved; supplies the object boundary and contains Additional Properties. |
|
|
182
|
+
| A `Group` deeper inside the detail | Kept, with its label. |
|
|
183
|
+
| Object nested in object | Dispatched at its own data path, with no frame of its own. |
|
|
184
|
+
| An error core maps onto a property with a control | Displayed there. |
|
|
185
|
+
| A disallowed additional property | Identified by the Additional Properties error indicator. |
|
|
186
|
+
| An error at the object's own path | Shown beside the object Group title or above its unframed fields. |
|
|
187
|
+
| Any of the above | Counts towards validity, and the data is left exactly as it is. |
|
|
188
|
+
|
|
189
|
+
## Conformance scope
|
|
190
|
+
|
|
191
|
+
This walkthrough describes the portable contract. Renderer support must be checked
|
|
192
|
+
by a host adapter; the package validates the authored assets, not live UI behavior.
|
|
193
|
+
|
|
194
|
+
## Standalone host setup
|
|
195
|
+
|
|
196
|
+
- Register the trusted tester functions exported by uischemas.json.
|
|
197
|
+
|
|
198
|
+
Import `uischemas` from [uischemas.json](uischemas.json) and register its entries.
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
## Feature navigation
|
|
202
|
+
|
|
203
|
+
The example separates its demonstrations into five tabs instead of one long form:
|
|
204
|
+
|
|
205
|
+
- **Generated layout:** the default object layout.
|
|
206
|
+
- **Explicit detail:** horizontal layout and nested tabs.
|
|
207
|
+
- **Registry and fallback:** registered layouts, GENERATE, and incomplete detail.
|
|
208
|
+
- **Group layouts:** outer and nested groups.
|
|
209
|
+
- **Object validation:** property count, additional properties, and dependencies.
|
|
210
|
+
|
|
211
|
+
Tab labels and introductions are available in English and Bulgarian. All tabs
|
|
212
|
+
continue to edit the same form data, with their existing schemas and constraints.
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
## Object title and frame comparisons
|
|
216
|
+
|
|
217
|
+
The Static fields, Dynamic fields, and Static and dynamic fields tabs each compare
|
|
218
|
+
a titled object with an explicitly untitled (`label: false`) object. Titles appear
|
|
219
|
+
once; dynamic-only objects have no empty static-field frame. One object boundary
|
|
220
|
+
contains static fields and Additional Properties without a second section border.
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
{
|
|
2
|
+
"identity": {
|
|
3
|
+
"tradingName": "Cascade Supplies"
|
|
4
|
+
},
|
|
5
|
+
"contact": {
|
|
6
|
+
"email": "support@example.test",
|
|
7
|
+
"phone": "+1 503 555 0113"
|
|
8
|
+
},
|
|
9
|
+
"address": {
|
|
10
|
+
"line1": "1200 NW Naito Pkwy",
|
|
11
|
+
"postcode": "97209",
|
|
12
|
+
"geo": {
|
|
13
|
+
"lat": 45.5272,
|
|
14
|
+
"lng": -122.6819
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"handover": {
|
|
18
|
+
"contactName": "A. Ferreira",
|
|
19
|
+
"window": "08:00-10:00",
|
|
20
|
+
"gateCode": "4417"
|
|
21
|
+
},
|
|
22
|
+
"schedule": {
|
|
23
|
+
"startsOn": "2026-10-02",
|
|
24
|
+
"appointment": "2026-10-04"
|
|
25
|
+
},
|
|
26
|
+
"notes": {
|
|
27
|
+
"forCoordinator": "Call on arrival",
|
|
28
|
+
"forOffice": "Room 3"
|
|
29
|
+
},
|
|
30
|
+
"compliance": {
|
|
31
|
+
"needsApproval": "none",
|
|
32
|
+
"permit": "OR-2291"
|
|
33
|
+
},
|
|
34
|
+
"preferences": {},
|
|
35
|
+
"routing": {
|
|
36
|
+
"office": "T-4",
|
|
37
|
+
"legacyZone": "west"
|
|
38
|
+
},
|
|
39
|
+
"billing": {
|
|
40
|
+
"purchaseOrder": "PO-88213"
|
|
41
|
+
},
|
|
42
|
+
"staticTitled": {
|
|
43
|
+
"reference": "REF-104"
|
|
44
|
+
},
|
|
45
|
+
"staticUntitled": {
|
|
46
|
+
"reference": "REF-104"
|
|
47
|
+
},
|
|
48
|
+
"dynamicTitled": {
|
|
49
|
+
"department": "Operations"
|
|
50
|
+
},
|
|
51
|
+
"dynamicUntitled": {
|
|
52
|
+
"department": "Operations"
|
|
53
|
+
},
|
|
54
|
+
"mixedTitled": {
|
|
55
|
+
"reference": "REF-104",
|
|
56
|
+
"department": "Operations"
|
|
57
|
+
},
|
|
58
|
+
"mixedUntitled": {
|
|
59
|
+
"reference": "REF-104",
|
|
60
|
+
"department": "Operations"
|
|
61
|
+
}
|
|
62
|
+
}
|