Background
As part of #3017, the first sub-area to split out is the form infrastructure itself.
Current dependency points include:
src/components/ui/form/UIForm.vue
src/components/ui/form/UIFormItem.vue
src/components/ui/form/UIFormItemInternal.vue
Problem
This part is more than a thin wrapper over naive-ui.
Current implementation details include:
UIForm wraps NForm
UIFormItem wraps NFormItem
UIFormItemInternal imports formItemInjectionKey from naive-ui/es/_mixins/use-form-item
- we hijack the internal form-item injection to intercept blur/input behavior
- validation timing includes custom blur delay, debounced input validation, and IME composition handling
This means the form infrastructure depends not only on public naive-ui components, but also on internal APIs that are especially fragile.
Goal
Replace the naive-ui form container / form item infrastructure with an internal implementation that preserves the behavior expected by the rest of XBuilder.
Scope
- replace
NForm usage in UIForm
- replace
NFormItem usage in UIFormItem
- remove the dependency on
formItemInjectionKey and other naive-ui internal plumbing
- preserve current validation behavior, including submit flow, validation state display, blur/input-triggered validation, and IME-safe handling
Notes
This issue is about form orchestration and validation plumbing. Specific input controls should be handled in separate child issues.
Background
As part of #3017, the first sub-area to split out is the form infrastructure itself.
Current dependency points include:
src/components/ui/form/UIForm.vuesrc/components/ui/form/UIFormItem.vuesrc/components/ui/form/UIFormItemInternal.vueProblem
This part is more than a thin wrapper over
naive-ui.Current implementation details include:
UIFormwrapsNFormUIFormItemwrapsNFormItemUIFormItemInternalimportsformItemInjectionKeyfromnaive-ui/es/_mixins/use-form-itemThis means the form infrastructure depends not only on public
naive-uicomponents, but also on internal APIs that are especially fragile.Goal
Replace the
naive-uiform container / form item infrastructure with an internal implementation that preserves the behavior expected by the rest of XBuilder.Scope
NFormusage inUIFormNFormItemusage inUIFormItemformItemInjectionKeyand othernaive-uiinternal plumbingNotes
This issue is about form orchestration and validation plumbing. Specific input controls should be handled in separate child issues.