@praxisui/dynamic-form 10.0.0-rc.3 → 10.0.0-rc.30
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/README.md
CHANGED
|
@@ -29,6 +29,14 @@ Peer dependencies:
|
|
|
29
29
|
- `@praxisui/ai`, `@praxisui/core`, `@praxisui/dynamic-fields`, `@praxisui/metadata-editor`, `@praxisui/rich-content`, `@praxisui/settings-panel`, `@praxisui/visual-builder` `^9.0.0-beta.12`
|
|
30
30
|
- `rxjs` `^7.8.0`
|
|
31
31
|
|
|
32
|
+
## Original item revision on submit
|
|
33
|
+
|
|
34
|
+
In edit mode, the form keeps a single strong `ETag` together with the item representation returned by its hydration GET (`readUrl`, custom `getById` endpoint or ordinary resource GET). Automatic PUT/PATCH sends that exact tag as `If-Match`; it never performs another GET during submit to acquire a newer revision. A successful response that contains the corresponding item representation replaces both cached data and revision from that same response, including server normalization. A command acknowledgment or incomplete representation cannot rotate the original item snapshot. A shared CRUD cache read by another consumer cannot replace the form's original revision.
|
|
35
|
+
|
|
36
|
+
The snapshot is transient and belongs to the resource identity, read/write target and API context. Preparation, reads and writes share a generation: switching away and back, reloading or destroying the surface cannot make an old callback current again. Obsolete automatic responses do not emit submit result events, run result hooks, publish field errors or reset a newer submit's loading state. If an obsolete preparation hook retained the reused form group, the draft requires explicit reload before another write. Changing those bindings requires hydration again. Missing or weak read ETags are not converted into versions; unversioned endpoints remain usable, while a versioned host can reject a missing precondition with `428`. After `412`/`428`, or a successful versioned write without its next ETag, automatic submission requires an explicit reload. Closing and reopening a surface or retrying its initialization loads the new representation; retrying submit alone cannot silently refresh the revision.
|
|
37
|
+
|
|
38
|
+
Explicit `submitResourceVersion` and the existing cross-resource version target inputs retain their command semantics and precedence. They remain host-owned inputs; same-resource editing needs no additional authoring fields. Backend authorization, concurrency and lifecycle policy remain authoritative.
|
|
39
|
+
|
|
32
40
|
## Reactive backend determinations
|
|
33
41
|
|
|
34
42
|
When the exact request schema from `/schemas/filtered` publishes root-level `x-ui.reactiveDeterminations`, the form executes the Metadata-compiled backend capability after a valid source changes and applies server-derived draft values. After edit/create hydration, an already populated source is also validated before the draft can be reported as stable; an empty initial source settles as not applicable without an HTTP call. The projection is one closed graph: if any definition is malformed, the complete projection is rejected instead of partially executing. It remains backend-owned, tenant-neutral and transient: it is never copied to `FormConfig` and cannot be authored as a callback, URL or local write policy.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
|
-
"generatedAt": "2026-10-
|
|
3
|
+
"generatedAt": "2026-10-16T15:16:17.774Z",
|
|
4
4
|
"packageName": "@praxisui/dynamic-form",
|
|
5
|
-
"packageVersion": "10.0.0-rc.
|
|
5
|
+
"packageVersion": "10.0.0-rc.30",
|
|
6
6
|
"sourceRegistry": "praxis-component-registry-ingestion",
|
|
7
7
|
"sourceRegistryVersion": "1.0.0",
|
|
8
8
|
"componentCount": 2,
|
|
@@ -272,6 +272,13 @@
|
|
|
272
272
|
"required": false,
|
|
273
273
|
"description": "Projeção de contextSnapshot.presentation para hosts e Page Builder. Tamanhos em pixels; null remove ajustes explícitos. Não altera mode nem presentationModeGlobal."
|
|
274
274
|
},
|
|
275
|
+
{
|
|
276
|
+
"name": "presentationPreset",
|
|
277
|
+
"type": "FormPresentationPreset",
|
|
278
|
+
"required": false,
|
|
279
|
+
"description": "Preset visual nativo para modo apresentação: corporate-dossier, editorial-card, compact-presentation ou default.",
|
|
280
|
+
"label": "Preset de Apresentação"
|
|
281
|
+
},
|
|
275
282
|
{
|
|
276
283
|
"name": "presentationModeGlobal",
|
|
277
284
|
"type": "boolean | null",
|
|
@@ -890,7 +897,6 @@
|
|
|
890
897
|
}
|
|
891
898
|
],
|
|
892
899
|
"configEditor": {
|
|
893
|
-
"component": "[ref:PraxisDynamicFormWidgetConfigEditor]",
|
|
894
900
|
"title": "Configurar formulário"
|
|
895
901
|
},
|
|
896
902
|
"authoringManifestRef": {
|
|
@@ -9200,9 +9206,9 @@
|
|
|
9200
9206
|
{
|
|
9201
9207
|
"chunkIndex": 0,
|
|
9202
9208
|
"chunkKind": "summary",
|
|
9203
|
-
"content": "Component ID: praxis-dynamic-form\nSelector: praxis-dynamic-form\nFriendly Name: Praxis Dynamic Form\nDescription: Formulario dinamico com layout por secoes/linhas/colunas e campos renderizados por metadados.\nCategory: form\nLib/Package: @praxisui/dynamic-form\nTags: widget, form, configurable, hasWizard, stable\nInputs:\n - resourcePath (string)\n - resourceId (string | number | null)\n - initialValue (Record<string, unknown> | null)\n - emptyState (PraxisDynamicFormEmptyState | null)\n - editorialContext (Record<string, unknown> | null)\n - mode ('create' | 'edit' | 'view')\n - config (FormConfig)\n - actions (FormConfig['actions'] | null)\n - schemaSource ('resource' | 'filter')\n - schemaUrl (string | null)\n - readUrl (string | null)\n - apiEndpointKey (ApiEndpoint | string | null)\n - apiUrlEntry (ApiUrlEntry | null)\n - submitUrl (string | null)\n - submitMethod ('post' | 'put' | 'patch' | null)\n - submitIdempotencyKey (string | null)\n - submitCorrelationId (string | null)\n - submitResourceVersion (string | number | null)\n - submitResourceVersionTargetResourceKey (string | null)\n - submitResourceVersionTargetIdField (string | null)\n - responseSchemaUrl (string | null)\n - enableCustomization (boolean)\n - showAiAssistant (boolean)\n - formId (string)\n - componentInstanceId (string)\n - configPersistenceStrategy ('local-first' | 'input-first')\n - layout (FormLayout)\n - generatedLayoutPreset ('default' | 'compactPresentation')\n - layoutPolicy (DynamicFormLayoutPolicy | null)\n - backConfig (BackConfig)\n - hooks (FormHooksLayout)\n - removeEmptyContainersOnSave (boolean)\n - reactiveValidation (boolean | null)\n - reactiveValidationDebounceMs (number | null)\n - notifyIfOutdated ('inline' | 'snackbar' | 'both' | 'none')\n - snoozeMs (number)\n - autoOpenSettingsOnOutdated (boolean)\n - readonlyModeGlobal (boolean | null)\n - disabledModeGlobal (boolean | null)\n - presentation (DynamicFormPresentationSnapshot | null)\n - presentationModeGlobal (boolean | null)\n - fieldIconPolicy ('all' | 'presentation-only' | 'none')\n - visibleGlobal (boolean | null)\n - customEndpoints (EndpointConfig)\nOutputs:\n - formSubmit (FormSubmitEvent)\n - formCancel (void)\n - formReset (void)\n - configChange (FormConfig)\n - configPatchChange (DynamicFormConfigPatchChangeEvent)\n - formReady (FormReadyEvent)\n - valueChange (FormValueChangeEvent)\n - payloadPreviewChange (FormPayloadPreviewEvent)\n - syncCompleted (SyncResult)\n - initializationError (FormInitializationError)\n - enableCustomizationChange (boolean)\n - customAction (FormCustomActionEvent)\n - actionConfirmation (FormActionConfirmationEvent)\n - schemaStatusChange ({ outdated: boolean; serverHash?: string; lastVerifiedAt?: string; formId?: string })\n - reactiveDeterminationExecuted (ReactiveDeterminationExecutionEvent)\n - reactiveDeterminationPendingChange (boolean)\n",
|
|
9209
|
+
"content": "Component ID: praxis-dynamic-form\nSelector: praxis-dynamic-form\nFriendly Name: Praxis Dynamic Form\nDescription: Formulario dinamico com layout por secoes/linhas/colunas e campos renderizados por metadados.\nCategory: form\nLib/Package: @praxisui/dynamic-form\nTags: widget, form, configurable, hasWizard, stable\nInputs:\n - resourcePath (string)\n - resourceId (string | number | null)\n - initialValue (Record<string, unknown> | null)\n - emptyState (PraxisDynamicFormEmptyState | null)\n - editorialContext (Record<string, unknown> | null)\n - mode ('create' | 'edit' | 'view')\n - config (FormConfig)\n - actions (FormConfig['actions'] | null)\n - schemaSource ('resource' | 'filter')\n - schemaUrl (string | null)\n - readUrl (string | null)\n - apiEndpointKey (ApiEndpoint | string | null)\n - apiUrlEntry (ApiUrlEntry | null)\n - submitUrl (string | null)\n - submitMethod ('post' | 'put' | 'patch' | null)\n - submitIdempotencyKey (string | null)\n - submitCorrelationId (string | null)\n - submitResourceVersion (string | number | null)\n - submitResourceVersionTargetResourceKey (string | null)\n - submitResourceVersionTargetIdField (string | null)\n - responseSchemaUrl (string | null)\n - enableCustomization (boolean)\n - showAiAssistant (boolean)\n - formId (string)\n - componentInstanceId (string)\n - configPersistenceStrategy ('local-first' | 'input-first')\n - layout (FormLayout)\n - generatedLayoutPreset ('default' | 'compactPresentation')\n - layoutPolicy (DynamicFormLayoutPolicy | null)\n - backConfig (BackConfig)\n - hooks (FormHooksLayout)\n - removeEmptyContainersOnSave (boolean)\n - reactiveValidation (boolean | null)\n - reactiveValidationDebounceMs (number | null)\n - notifyIfOutdated ('inline' | 'snackbar' | 'both' | 'none')\n - snoozeMs (number)\n - autoOpenSettingsOnOutdated (boolean)\n - readonlyModeGlobal (boolean | null)\n - disabledModeGlobal (boolean | null)\n - presentation (DynamicFormPresentationSnapshot | null)\n - presentationPreset (FormPresentationPreset)\n - presentationModeGlobal (boolean | null)\n - fieldIconPolicy ('all' | 'presentation-only' | 'none')\n - visibleGlobal (boolean | null)\n - customEndpoints (EndpointConfig)\nOutputs:\n - formSubmit (FormSubmitEvent)\n - formCancel (void)\n - formReset (void)\n - configChange (FormConfig)\n - configPatchChange (DynamicFormConfigPatchChangeEvent)\n - formReady (FormReadyEvent)\n - valueChange (FormValueChangeEvent)\n - payloadPreviewChange (FormPayloadPreviewEvent)\n - syncCompleted (SyncResult)\n - initializationError (FormInitializationError)\n - enableCustomizationChange (boolean)\n - customAction (FormCustomActionEvent)\n - actionConfirmation (FormActionConfirmationEvent)\n - schemaStatusChange ({ outdated: boolean; serverHash?: string; lastVerifiedAt?: string; formId?: string })\n - reactiveDeterminationExecuted (ReactiveDeterminationExecutionEvent)\n - reactiveDeterminationPendingChange (boolean)\n",
|
|
9204
9210
|
"sourcePointer": "projects/praxis-dynamic-form/src/lib/praxis-dynamic-form.metadata.ts",
|
|
9205
|
-
"contentHash": "
|
|
9211
|
+
"contentHash": "8425658a28ef61e2ebcf2ce2cc5b45835050556a4f810e83a4c167290dfcd80a",
|
|
9206
9212
|
"sourceKind": "component_definition",
|
|
9207
9213
|
"sourceId": "praxis-dynamic-form",
|
|
9208
9214
|
"corpusVersion": "1.0.0"
|
|
@@ -10354,7 +10360,6 @@
|
|
|
10354
10360
|
}
|
|
10355
10361
|
],
|
|
10356
10362
|
"configEditor": {
|
|
10357
|
-
"component": "[ref:PraxisFilterFormWidgetConfigEditor]",
|
|
10358
10363
|
"title": "Configurar filtro"
|
|
10359
10364
|
},
|
|
10360
10365
|
"authoringManifestRef": {
|
|
@@ -95,6 +95,22 @@ Regra operacional:
|
|
|
95
95
|
- se o loader da coluna for localizado, apenas ele e atualizado;
|
|
96
96
|
- se o loader nao puder ser localizado, o runtime usa fallback seguro de rebuild do form.
|
|
97
97
|
|
|
98
|
+
## Saved configuration after request schema removal
|
|
99
|
+
|
|
100
|
+
When reconciling saved configuration with the current request schema, Core retains
|
|
101
|
+
removed schema-backed fields for authored layout continuity, but marks them hidden,
|
|
102
|
+
disabled and `submitPolicy: "omit"`. A required orphan with a null value therefore
|
|
103
|
+
does not invalidate the group, and a value still returned by the read projection
|
|
104
|
+
cannot reenter the request payload through `getRawValue()`.
|
|
105
|
+
|
|
106
|
+
A field whose `source` is absent is schema-backed for this reconciliation. Explicit
|
|
107
|
+
`source: "local"` fields preserve existing local/transient policies and may opt into
|
|
108
|
+
submission with `submitPolicy: "include"`. Hidden fields still present in the request
|
|
109
|
+
schema remain submit-eligible; do not turn all hidden controls into omitted fields.
|
|
110
|
+
If the server publishes a retained field again, current server validation, visibility,
|
|
111
|
+
enabled state and submit semantics replace the orphan state. No host payload strip,
|
|
112
|
+
new flag or layout deletion is needed.
|
|
113
|
+
|
|
98
114
|
## Melhorias no DynamicFieldLoader
|
|
99
115
|
|
|
100
116
|
O guard de rerender do loader passou a incluir no snapshot:
|