@form-engine-ts/react 2.2.0 → 2.5.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/README.md +20 -0
- package/dist/index.cjs +959 -435
- package/dist/index.d.cts +146 -4
- package/dist/index.d.ts +146 -4
- package/dist/index.js +964 -439
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -72,6 +72,26 @@ controls `pages`, `localization`, and `conditions` authoring surfaces; each defa
|
|
|
72
72
|
set, locale addition becomes a selector containing only unregistered allowed locales, and the action is disabled at
|
|
73
73
|
`maxLocales`.
|
|
74
74
|
|
|
75
|
+
Visual Builder has two independent design-system extension layers. `components` replaces normalized primitives such as
|
|
76
|
+
`Button`, `TextInput`, `TextArea`, `Select`, `Checkbox`, `Section`, and `Fieldset`. `slots` replaces complete authoring
|
|
77
|
+
surfaces: `toolbar`, `fieldEditor`, `optionEditor`, `pages`, `localization`, or `translationActions`. Slot props expose
|
|
78
|
+
policy-aware `actions`; a custom `translationActions` slot can therefore call an application-specific AI mutation while
|
|
79
|
+
the standard manual localization editors remain unchanged.
|
|
80
|
+
|
|
81
|
+
Input primitives receive design-system-friendly `name`, `label`, `required`, `error`, and `helperText` props in addition
|
|
82
|
+
to their normalized string-value callbacks. The `translationActions` slot also receives `translationError`, the latest
|
|
83
|
+
`translationReport`, and `onClearTranslationError`, allowing a custom MUI action surface to represent the complete
|
|
84
|
+
translation lifecycle.
|
|
85
|
+
|
|
86
|
+
```tsx
|
|
87
|
+
<FormBuilder
|
|
88
|
+
schema={schema}
|
|
89
|
+
onChange={setSchema}
|
|
90
|
+
components={{ Button: MuiButtonAdapter, TextInput: MuiTextFieldAdapter }}
|
|
91
|
+
slots={{ translationActions: ArgsAiTranslationActions }}
|
|
92
|
+
/>
|
|
93
|
+
```
|
|
94
|
+
|
|
75
95
|
`FormRenderer` can also be used without an explicit provider:
|
|
76
96
|
|
|
77
97
|
```tsx
|