@atscript/vue-form 0.1.113 → 0.1.114
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/{as-array-BQik4ae9.mjs → as-array-DMMA0WhA.mjs} +3 -3
- package/dist/{as-array-D4bvUQHP.cjs → as-array-opoGhD7Q.cjs} +3 -3
- package/dist/as-array.cjs +1 -1
- package/dist/as-array.mjs +1 -1
- package/dist/{as-checkbox-DwLRHmXj.mjs → as-checkbox-Bg5MN2x8.mjs} +1 -1
- package/dist/{as-checkbox-sgF16SuJ.cjs → as-checkbox-C-NoKSv6.cjs} +1 -1
- package/dist/as-checkbox.cjs +1 -1
- package/dist/as-checkbox.mjs +1 -1
- package/dist/{as-collapsible-Cml8bp79.mjs → as-collapsible-_RN5621d.mjs} +1 -1
- package/dist/{as-collapsible-MXTigQ95.cjs → as-collapsible-nMEolKb7.cjs} +1 -1
- package/dist/as-collapsible.cjs +1 -1
- package/dist/as-collapsible.mjs +1 -1
- package/dist/{as-date-hCCTd52o.cjs → as-date-DCZ0t3-h.cjs} +1 -1
- package/dist/{as-date-CfCa2Kp1.mjs → as-date-DF8WzVgY.mjs} +1 -1
- package/dist/as-date.cjs +1 -1
- package/dist/as-date.mjs +1 -1
- package/dist/{as-datetime-DDlWca2Q.cjs → as-datetime-BhhbOw99.cjs} +1 -1
- package/dist/{as-datetime-B1I_zREk.mjs → as-datetime-wuk9i8Tz.mjs} +1 -1
- package/dist/as-datetime.cjs +1 -1
- package/dist/as-datetime.mjs +1 -1
- package/dist/{as-decimal-C8Yf5dS7.cjs → as-decimal-B1_3ivMF.cjs} +1 -1
- package/dist/{as-decimal-Cg17vyjS.mjs → as-decimal-CVp3Wtrz.mjs} +1 -1
- package/dist/as-decimal.cjs +1 -1
- package/dist/as-decimal.mjs +1 -1
- package/dist/{as-field-DKzUSrFN.cjs → as-field-BC3LdGue.cjs} +87 -18
- package/dist/{as-field-ByxmIAOc.mjs → as-field-oZeBwI9U.mjs} +77 -20
- package/dist/{as-field-shell-DLvPV8WS.mjs → as-field-shell-BErcR8c9.mjs} +1 -1
- package/dist/{as-field-shell-C4epFfvE.cjs → as-field-shell-_XX9G3PP.cjs} +1 -1
- package/dist/as-field-shell.cjs +1 -1
- package/dist/as-field-shell.mjs +1 -1
- package/dist/as-field.cjs +1 -1
- package/dist/as-field.d.cts +1 -1
- package/dist/as-field.d.mts +1 -1
- package/dist/as-field.mjs +1 -1
- package/dist/{as-field.vue-A2cJj-Ih.d.cts → as-field.vue-BHOc-pFM.d.cts} +1 -1
- package/dist/{as-field.vue-CmjIDgQ5.d.mts → as-field.vue-BOTSEvA_.d.mts} +1 -1
- package/dist/{as-form-SfA1ec67.mjs → as-form-KXdLWQMq.mjs} +3 -3
- package/dist/{as-form-BsiXHc3s.cjs → as-form-qrsfdEOq.cjs} +3 -3
- package/dist/as-form.cjs +1 -1
- package/dist/as-form.d.cts +1 -1
- package/dist/as-form.d.mts +1 -1
- package/dist/as-form.mjs +1 -1
- package/dist/{as-form.vue-CT-dv0XM.d.mts → as-form.vue-DJZ7Ub54.d.mts} +101 -4
- package/dist/{as-form.vue-CnMuotCg.d.cts → as-form.vue-DLFb1NRU.d.cts} +101 -4
- package/dist/{as-input-Bp1Ltp15.cjs → as-input-CGJZNsPn.cjs} +1 -1
- package/dist/{as-input-DF--i7kY.mjs → as-input-CLdDhrzx.mjs} +1 -1
- package/dist/as-input.cjs +1 -1
- package/dist/as-input.mjs +1 -1
- package/dist/as-iterator-CaXKhPjU.mjs +99 -0
- package/dist/as-iterator-Cs1qZXGu.cjs +116 -0
- package/dist/as-iterator.cjs +1 -1
- package/dist/as-iterator.d.cts +1 -1
- package/dist/as-iterator.d.mts +1 -1
- package/dist/as-iterator.mjs +1 -1
- package/dist/{as-iterator.vue-BZeozFr-.d.cts → as-iterator.vue-DYDv_Gbh.d.cts} +7 -0
- package/dist/{as-iterator.vue-C8HW6n25.d.mts → as-iterator.vue-diVHA64A.d.mts} +7 -0
- package/dist/{as-multi-select-mp-aM3LV.mjs → as-multi-select-BzXxFUZU.mjs} +1 -1
- package/dist/{as-multi-select-b1l34vP5.cjs → as-multi-select-DcBATdiH.cjs} +1 -1
- package/dist/as-multi-select.cjs +1 -1
- package/dist/as-multi-select.mjs +1 -1
- package/dist/{as-number-joydTMcJ.cjs → as-number-Bv33W-S9.cjs} +1 -1
- package/dist/{as-number-De9zTltV.mjs → as-number-Cros_r8k.mjs} +1 -1
- package/dist/as-number.cjs +1 -1
- package/dist/as-number.mjs +1 -1
- package/dist/{as-object-BusF5Jv5.mjs → as-object-BJG7f5tQ.mjs} +3 -3
- package/dist/{as-object-Bl9YE25G.cjs → as-object-DindiCq4.cjs} +3 -3
- package/dist/as-object.cjs +1 -1
- package/dist/as-object.mjs +1 -1
- package/dist/{as-radio-SwpgM1xP.mjs → as-radio-CNeg0NQ0.mjs} +1 -1
- package/dist/{as-radio-Dlmxk1vr.cjs → as-radio-CjrO1d-4.cjs} +1 -1
- package/dist/as-radio.cjs +1 -1
- package/dist/as-radio.mjs +1 -1
- package/dist/{as-ref-BCpvUq8E.cjs → as-ref-CMDYGqL6.cjs} +1 -1
- package/dist/{as-ref-8JnEuan0.mjs → as-ref-v00Tyeum.mjs} +1 -1
- package/dist/as-ref.cjs +1 -1
- package/dist/as-ref.mjs +1 -1
- package/dist/{as-select-C3ukCyGQ.mjs → as-select-BZUE0TJD.mjs} +1 -1
- package/dist/{as-select-CtSNZXtC.cjs → as-select-CeFTgQo6.cjs} +1 -1
- package/dist/as-select.cjs +1 -1
- package/dist/as-select.mjs +1 -1
- package/dist/{as-time-nAPtGL3t.cjs → as-time-BMwVQp45.cjs} +1 -1
- package/dist/{as-time-QJ9YiVj9.mjs → as-time-CQ2GWcPn.mjs} +1 -1
- package/dist/as-time.cjs +1 -1
- package/dist/as-time.mjs +1 -1
- package/dist/{as-tuple-DYt_Glpl.cjs → as-tuple-Ca4bIuag.cjs} +3 -3
- package/dist/{as-tuple-Bwh1YCYN.mjs → as-tuple-H0qDsZKS.mjs} +3 -3
- package/dist/as-tuple.cjs +1 -1
- package/dist/as-tuple.mjs +1 -1
- package/dist/{as-union-DdaPBWj0.mjs → as-union-Car_1kUS.mjs} +1 -1
- package/dist/{as-union-CGaixalf.cjs → as-union-CovWOnmN.cjs} +1 -1
- package/dist/as-union.cjs +1 -1
- package/dist/as-union.mjs +1 -1
- package/dist/index.cjs +63 -21
- package/dist/index.d.cts +4 -4
- package/dist/index.d.mts +4 -4
- package/dist/index.mjs +43 -24
- package/dist/{use-form-context-DpGiGUvJ.cjs → use-form-context-B6ZnzfxG.cjs} +2 -7
- package/dist/{use-form-context-D6J1WTyG.mjs → use-form-context-cDW2GW4-.mjs} +5 -10
- package/package.json +4 -4
- package/dist/as-iterator-CDzc27DB.cjs +0 -65
- package/dist/as-iterator-D1SisoDg.mjs +0 -60
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { a as CHANGE_HANDLER_KEY, n as useAsUnionVariant, r as useFormContext } from "./use-form-context-
|
|
2
|
-
import { t as as_field_default } from "./as-field-
|
|
3
|
-
import { t as as_collapsible_default } from "./as-collapsible-
|
|
1
|
+
import { a as CHANGE_HANDLER_KEY, n as useAsUnionVariant, r as useFormContext } from "./use-form-context-cDW2GW4-.mjs";
|
|
2
|
+
import { t as as_field_default } from "./as-field-oZeBwI9U.mjs";
|
|
3
|
+
import { t as as_collapsible_default } from "./as-collapsible-_RN5621d.mjs";
|
|
4
4
|
import { t as as_variant_picker_default } from "./as-variant-picker-B3GLhKyt.mjs";
|
|
5
5
|
import { t as useAsDropdown } from "./use-as-dropdown-B2Shb7wn.mjs";
|
|
6
6
|
import { t as useAsOptionalAddFlow } from "./use-as-optional-add-flow-BdjKNx9P.mjs";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const require_use_form_context = require("./use-form-context-
|
|
2
|
-
const require_as_field = require("./as-field-
|
|
3
|
-
const require_as_collapsible = require("./as-collapsible-
|
|
1
|
+
const require_use_form_context = require("./use-form-context-B6ZnzfxG.cjs");
|
|
2
|
+
const require_as_field = require("./as-field-BC3LdGue.cjs");
|
|
3
|
+
const require_as_collapsible = require("./as-collapsible-nMEolKb7.cjs");
|
|
4
4
|
const require_as_variant_picker = require("./as-variant-picker-JlEhh7YO.cjs");
|
|
5
5
|
const require_use_as_dropdown = require("./use-as-dropdown-Bj9toVdw.cjs");
|
|
6
6
|
const require_use_as_optional_add_flow = require("./use-as-optional-add-flow-CD8seN3C.cjs");
|
package/dist/as-array.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_array = require("./as-array-
|
|
1
|
+
const require_as_array = require("./as-array-opoGhD7Q.cjs");
|
|
2
2
|
module.exports = require_as_array.as_array_default;
|
package/dist/as-array.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_array_default } from "./as-array-
|
|
1
|
+
import { t as as_array_default } from "./as-array-DMMA0WhA.mjs";
|
|
2
2
|
export { as_array_default as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as as_field_shell_default } from "./as-field-shell-
|
|
1
|
+
import { t as as_field_shell_default } from "./as-field-shell-BErcR8c9.mjs";
|
|
2
2
|
import { n as as_optional_clear_default } from "./as-variant-picker-B3GLhKyt.mjs";
|
|
3
3
|
import { computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, defineComponent, mergeProps, normalizeClass, openBlock, ref, toDisplayString, unref, watchEffect, withCtx } from "vue";
|
|
4
4
|
//#region src/composables/use-as-tri-state-checkbox.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_as_field_shell = require("./as-field-shell-
|
|
1
|
+
const require_as_field_shell = require("./as-field-shell-_XX9G3PP.cjs");
|
|
2
2
|
const require_as_variant_picker = require("./as-variant-picker-JlEhh7YO.cjs");
|
|
3
3
|
let vue = require("vue");
|
|
4
4
|
//#region src/composables/use-as-tri-state-checkbox.ts
|
package/dist/as-checkbox.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_checkbox = require("./as-checkbox-
|
|
1
|
+
const require_as_checkbox = require("./as-checkbox-C-NoKSv6.cjs");
|
|
2
2
|
module.exports = require_as_checkbox.as_checkbox_default;
|
package/dist/as-checkbox.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_checkbox_default } from "./as-checkbox-
|
|
1
|
+
import { t as as_checkbox_default } from "./as-checkbox-Bg5MN2x8.mjs";
|
|
2
2
|
export { as_checkbox_default as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as formatIndexedLabelParts } from "./use-form-context-
|
|
1
|
+
import { t as formatIndexedLabelParts } from "./use-form-context-cDW2GW4-.mjs";
|
|
2
2
|
import { i as useAsNestedSectionsStore, t as DESCENDANT_ERROR_COUNTS_KEY } from "./use-as-nested-sections-store-Dfo971PK.mjs";
|
|
3
3
|
import { r as useAsFocusFirstAfter } from "./focus-after-toggle-Dtl3P6CS.mjs";
|
|
4
4
|
import { computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, defineComponent, inject, normalizeClass, onBeforeUnmount, onMounted, openBlock, renderSlot, resolveDynamicComponent, toDisplayString, vShow, withCtx, withDirectives } from "vue";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_use_form_context = require("./use-form-context-
|
|
1
|
+
const require_use_form_context = require("./use-form-context-B6ZnzfxG.cjs");
|
|
2
2
|
const require_use_as_nested_sections_store = require("./use-as-nested-sections-store-u1VgBJAP.cjs");
|
|
3
3
|
const require_focus_after_toggle = require("./focus-after-toggle-CWxiPZWi.cjs");
|
|
4
4
|
let vue = require("vue");
|
package/dist/as-collapsible.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_collapsible = require("./as-collapsible-
|
|
1
|
+
const require_as_collapsible = require("./as-collapsible-nMEolKb7.cjs");
|
|
2
2
|
module.exports = require_as_collapsible.as_collapsible_default;
|
package/dist/as-collapsible.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_collapsible_default } from "./as-collapsible-
|
|
1
|
+
import { t as as_collapsible_default } from "./as-collapsible-_RN5621d.mjs";
|
|
2
2
|
export { as_collapsible_default as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_as_field_shell = require("./as-field-shell-
|
|
1
|
+
const require_as_field_shell = require("./as-field-shell-_XX9G3PP.cjs");
|
|
2
2
|
const require_as_adornment_shell = require("./as-adornment-shell-DptUMWNk.cjs");
|
|
3
3
|
const require_use_as_date = require("./use-as-date-CslHBPmQ.cjs");
|
|
4
4
|
let vue = require("vue");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as as_field_shell_default } from "./as-field-shell-
|
|
1
|
+
import { t as as_field_shell_default } from "./as-field-shell-BErcR8c9.mjs";
|
|
2
2
|
import { t as as_adornment_shell_default } from "./as-adornment-shell-C4A2fnDp.mjs";
|
|
3
3
|
import { n as as_date_control_default, t as useAsDate } from "./use-as-date-B6RGkjjB.mjs";
|
|
4
4
|
import { computed, createBlock, createVNode, defineComponent, guardReactiveProps, mergeProps, normalizeProps, openBlock, unref, withCtx } from "vue";
|
package/dist/as-date.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_date = require("./as-date-
|
|
1
|
+
const require_as_date = require("./as-date-DCZ0t3-h.cjs");
|
|
2
2
|
module.exports = require_as_date.as_date_default;
|
package/dist/as-date.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_date_default } from "./as-date-
|
|
1
|
+
import { t as as_date_default } from "./as-date-DF8WzVgY.mjs";
|
|
2
2
|
export { as_date_default as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_as_field_shell = require("./as-field-shell-
|
|
1
|
+
const require_as_field_shell = require("./as-field-shell-_XX9G3PP.cjs");
|
|
2
2
|
const require_as_adornment_shell = require("./as-adornment-shell-DptUMWNk.cjs");
|
|
3
3
|
const require_use_as_date = require("./use-as-date-CslHBPmQ.cjs");
|
|
4
4
|
let vue = require("vue");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as as_field_shell_default } from "./as-field-shell-
|
|
1
|
+
import { t as as_field_shell_default } from "./as-field-shell-BErcR8c9.mjs";
|
|
2
2
|
import { t as as_adornment_shell_default } from "./as-adornment-shell-C4A2fnDp.mjs";
|
|
3
3
|
import { n as as_date_control_default, t as useAsDate } from "./use-as-date-B6RGkjjB.mjs";
|
|
4
4
|
import { computed, createBlock, createVNode, defineComponent, guardReactiveProps, mergeProps, normalizeProps, openBlock, unref, withCtx } from "vue";
|
package/dist/as-datetime.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_datetime = require("./as-datetime-
|
|
1
|
+
const require_as_datetime = require("./as-datetime-BhhbOw99.cjs");
|
|
2
2
|
module.exports = require_as_datetime.as_datetime_default;
|
package/dist/as-datetime.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_datetime_default } from "./as-datetime-
|
|
1
|
+
import { t as as_datetime_default } from "./as-datetime-wuk9i8Tz.mjs";
|
|
2
2
|
export { as_datetime_default as default };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_use_as_locale = require("./use-as-locale-C4z5stwD.cjs");
|
|
2
|
-
const require_as_field_shell = require("./as-field-shell-
|
|
2
|
+
const require_as_field_shell = require("./as-field-shell-_XX9G3PP.cjs");
|
|
3
3
|
let vue = require("vue");
|
|
4
4
|
let _atscript_ui = require("@atscript/ui");
|
|
5
5
|
//#region src/composables/_shape.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as useAsLocale } from "./use-as-locale-BrFdAgnU.mjs";
|
|
2
|
-
import { t as as_field_shell_default } from "./as-field-shell-
|
|
2
|
+
import { t as as_field_shell_default } from "./as-field-shell-BErcR8c9.mjs";
|
|
3
3
|
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, defineComponent, guardReactiveProps, nextTick, normalizeClass, normalizeProps, openBlock, ref, toDisplayString, unref, watch, withCtx } from "vue";
|
|
4
4
|
import { enforceScale, formatDecimalForDisplay, getDecimalSeparator, getThousandsSeparator, groupInteger, joinDecimalString, parseDecimalInput, splitDecimalString } from "@atscript/ui";
|
|
5
5
|
//#region src/composables/_shape.ts
|
package/dist/as-decimal.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_decimal = require("./as-decimal-
|
|
1
|
+
const require_as_decimal = require("./as-decimal-B1_3ivMF.cjs");
|
|
2
2
|
module.exports = require_as_decimal.as_decimal_default;
|
package/dist/as-decimal.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_decimal_default } from "./as-decimal-
|
|
1
|
+
import { t as as_decimal_default } from "./as-decimal-CVp3Wtrz.mjs";
|
|
2
2
|
export { as_decimal_default as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_use_form_context = require("./use-form-context-
|
|
1
|
+
const require_use_form_context = require("./use-form-context-B6ZnzfxG.cjs");
|
|
2
2
|
const require_use_as_locale = require("./use-as-locale-C4z5stwD.cjs");
|
|
3
3
|
let vue = require("vue");
|
|
4
4
|
let _atscript_ui = require("@atscript/ui");
|
|
@@ -83,6 +83,76 @@ function useAsField(opts) {
|
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
85
|
//#endregion
|
|
86
|
+
//#region src/composables/use-as-field-scope.ts
|
|
87
|
+
/**
|
|
88
|
+
* Shared inert scope for static-only resolution — no reactive reads.
|
|
89
|
+
* Module-level singleton (also used by AsField's allStatic fast path).
|
|
90
|
+
*/
|
|
91
|
+
const emptyScope = {
|
|
92
|
+
v: void 0,
|
|
93
|
+
data: {},
|
|
94
|
+
context: {},
|
|
95
|
+
entry: void 0
|
|
96
|
+
};
|
|
97
|
+
/**
|
|
98
|
+
* Child-field scope building + annotation resolution for custom CONTAINER
|
|
99
|
+
* renderers (tabbed shells, side-nav layouts) that partition or decorate a
|
|
100
|
+
* structured field's children without mounting `<AsField>` for each one.
|
|
101
|
+
*
|
|
102
|
+
* Returns plain functions — no internal computeds. Wrap calls in your own
|
|
103
|
+
* `computed` to inherit reactivity over form data.
|
|
104
|
+
*/
|
|
105
|
+
function useAsFieldScope() {
|
|
106
|
+
const { buildPath, getByPath, buildScope } = require_use_form_context.useFormContext("useAsFieldScope");
|
|
107
|
+
function absolutePath(field) {
|
|
108
|
+
return buildPath(field.path);
|
|
109
|
+
}
|
|
110
|
+
function scopeFor(field, opts) {
|
|
111
|
+
const base = buildScope(getByPath(buildPath(field.path)));
|
|
112
|
+
if (!opts?.withEntry) return base;
|
|
113
|
+
return (0, _atscript_ui_fns.buildFieldEntry)(field.prop, base, field.path, {
|
|
114
|
+
type: field.type,
|
|
115
|
+
name: field.name
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
function resolveProp(field, fnKey, staticKey, opts) {
|
|
119
|
+
const hasFn = fnKey !== void 0 && (0, _atscript_ui.hasFieldMeta)(field.prop, fnKey);
|
|
120
|
+
if (!hasFn && (staticKey === void 0 || !(0, _atscript_ui.hasFieldMeta)(field.prop, staticKey))) return;
|
|
121
|
+
const scope = hasFn ? scopeFor(field, { withEntry: opts?.withEntry }) : emptyScope;
|
|
122
|
+
return (0, _atscript_ui.resolveFieldProp)(field.prop, fnKey ?? "", staticKey, scope, opts);
|
|
123
|
+
}
|
|
124
|
+
return {
|
|
125
|
+
absolutePath,
|
|
126
|
+
scopeFor,
|
|
127
|
+
resolveProp
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
//#endregion
|
|
131
|
+
//#region src/composables/use-as-optional-field.ts
|
|
132
|
+
/**
|
|
133
|
+
* Optional-field enable/clear for custom container renderers — the same
|
|
134
|
+
* behavior AsField wires onto `onToggleOptional`, usable without mounting
|
|
135
|
+
* `<AsField>` for the field.
|
|
136
|
+
*/
|
|
137
|
+
function useAsOptionalField(field) {
|
|
138
|
+
const { rootFormData, formContext, buildPath, getByPath, setByPath } = require_use_form_context.useFormContext("useAsOptionalField");
|
|
139
|
+
const handleChange = (0, vue.inject)(require_use_form_context.CHANGE_HANDLER_KEY, () => {});
|
|
140
|
+
const enabled = (0, vue.computed)(() => getByPath(buildPath(field.path)) != null);
|
|
141
|
+
function toggle(on) {
|
|
142
|
+
const path = buildPath(field.path);
|
|
143
|
+
if (on) {
|
|
144
|
+
const resolver = (0, _atscript_ui.createFormValueResolver)(rootFormData().value, formContext.value);
|
|
145
|
+
setByPath(path, (0, _atscript_ui.createFormData)(field.prop, resolver).value);
|
|
146
|
+
} else setByPath(path, void 0);
|
|
147
|
+
handleChange("update", path, getByPath(path));
|
|
148
|
+
}
|
|
149
|
+
return {
|
|
150
|
+
optional: field.prop.optional ?? false,
|
|
151
|
+
enabled,
|
|
152
|
+
toggle
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
//#endregion
|
|
86
156
|
//#region src/composables/use-as-data.ts
|
|
87
157
|
const EMPTY_PATH = (0, vue.computed)(() => "");
|
|
88
158
|
const EMPTY_DATA = (0, vue.computed)(() => void 0);
|
|
@@ -110,8 +180,7 @@ function useAsData() {
|
|
|
110
180
|
return (0, vue.computed)(() => {
|
|
111
181
|
const w = wrapped.value;
|
|
112
182
|
if (!w) return void 0;
|
|
113
|
-
|
|
114
|
-
return (0, _atscript_ui.getByPath)(w, prefix ? `${prefix}.${name}` : name);
|
|
183
|
+
return (0, _atscript_ui.getByPath)(w, (0, _atscript_ui.joinPath)(pathPrefix.value, name));
|
|
115
184
|
});
|
|
116
185
|
}
|
|
117
186
|
return {
|
|
@@ -126,12 +195,6 @@ const _hoisted_1 = {
|
|
|
126
195
|
key: 1,
|
|
127
196
|
class: "as-field-missing"
|
|
128
197
|
};
|
|
129
|
-
const emptyScope = {
|
|
130
|
-
v: void 0,
|
|
131
|
-
data: {},
|
|
132
|
-
context: {},
|
|
133
|
-
entry: void 0
|
|
134
|
-
};
|
|
135
198
|
//#endregion
|
|
136
199
|
//#region src/components/as-field.vue
|
|
137
200
|
var as_field_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
@@ -287,13 +350,7 @@ var as_field_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
287
350
|
function setModel(value) {
|
|
288
351
|
setByPath(absolutePath.value, value);
|
|
289
352
|
}
|
|
290
|
-
|
|
291
|
-
if (enabled) {
|
|
292
|
-
const resolver = (0, _atscript_ui.createFormValueResolver)(rootFormData().value, formContext.value);
|
|
293
|
-
setModel((0, _atscript_ui.createFormData)(props.field.prop, resolver).value);
|
|
294
|
-
} else setModel(void 0);
|
|
295
|
-
handleChange("update", absolutePath.value, getModel());
|
|
296
|
-
}
|
|
353
|
+
const { toggle: toggleOptional } = useAsOptionalField(props.field);
|
|
297
354
|
const resolvedComponent = (0, vue.computed)(() => {
|
|
298
355
|
if (componentName) return components?.value?.[componentName];
|
|
299
356
|
const map = types?.value;
|
|
@@ -320,7 +377,7 @@ var as_field_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
320
377
|
if (props.field.allStatic) {
|
|
321
378
|
hasCustomValidators = false;
|
|
322
379
|
disabled = (0, _atscript_ui.getFieldMeta)(prop, _atscript_ui.UI_FORM_DISABLED) !== void 0;
|
|
323
|
-
hidden = (0, _atscript_ui.
|
|
380
|
+
hidden = (0, _atscript_ui.hasFieldMeta)(prop, _atscript_ui.UI_FORM_HIDDEN);
|
|
324
381
|
optional = props.field.prop.optional ?? false;
|
|
325
382
|
readonly = (0, _atscript_ui.getFieldMeta)(prop, _atscript_ui.META_READONLY) !== void 0;
|
|
326
383
|
required = props.field.phantom ? void 0 : hasMetaRequired;
|
|
@@ -346,7 +403,7 @@ var as_field_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
346
403
|
const bs = needsBaseScope || needsFullScope ? (0, vue.computed)(() => buildScope(getModel())) : void 0;
|
|
347
404
|
const boolOpts = { staticAsBoolean: true };
|
|
348
405
|
disabled = maybeComputed(hasFn.has("disabled"), () => (0, _atscript_ui.resolveFieldProp)(prop, _atscript_ui.UI_FORM_FN_DISABLED, _atscript_ui.UI_FORM_DISABLED, bs.value, boolOpts) ?? false, (0, _atscript_ui.getFieldMeta)(prop, _atscript_ui.UI_FORM_DISABLED) !== void 0);
|
|
349
|
-
hidden = maybeComputed(hasFn.has("hidden"), () => (0, _atscript_ui.
|
|
406
|
+
hidden = maybeComputed(hasFn.has("hidden"), () => (0, _atscript_ui.isFieldHidden)(prop, bs.value), (0, _atscript_ui.getFieldMeta)(prop, _atscript_ui.UI_FORM_HIDDEN) !== void 0);
|
|
350
407
|
optional = props.field.prop.optional ?? false;
|
|
351
408
|
readonly = maybeComputed(hasFn.has("readonly"), () => (0, _atscript_ui.resolveFieldProp)(prop, _atscript_ui.UI_FORM_FN_READONLY, _atscript_ui.META_READONLY, bs.value, boolOpts) ?? false, (0, _atscript_ui.getFieldMeta)(prop, _atscript_ui.META_READONLY) !== void 0);
|
|
352
409
|
required = props.field.phantom ? void 0 : hasMetaRequired;
|
|
@@ -512,3 +569,15 @@ Object.defineProperty(exports, "useAsField", {
|
|
|
512
569
|
return useAsField;
|
|
513
570
|
}
|
|
514
571
|
});
|
|
572
|
+
Object.defineProperty(exports, "useAsFieldScope", {
|
|
573
|
+
enumerable: true,
|
|
574
|
+
get: function() {
|
|
575
|
+
return useAsFieldScope;
|
|
576
|
+
}
|
|
577
|
+
});
|
|
578
|
+
Object.defineProperty(exports, "useAsOptionalField", {
|
|
579
|
+
enumerable: true,
|
|
580
|
+
get: function() {
|
|
581
|
+
return useAsOptionalField;
|
|
582
|
+
}
|
|
583
|
+
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { _ as TYPES_KEY, a as CHANGE_HANDLER_KEY, c as ERRORS_KEY, d as FORM_PATCH_KEY, f as FORM_STATE_KEY, g as ROOT_DATA_KEY, h as PATH_PREFIX_KEY, i as ACTION_HANDLER_KEY, l as FORM_CONTEXT_KEY, m as LEVEL_KEY, o as COMPONENTS_KEY, p as HIDE_ROOT_TITLE_KEY, r as useFormContext, s as DISMISS_EXTERNAL_AT_KEY, u as FORM_DATA_KEY } from "./use-form-context-
|
|
1
|
+
import { _ as TYPES_KEY, a as CHANGE_HANDLER_KEY, c as ERRORS_KEY, d as FORM_PATCH_KEY, f as FORM_STATE_KEY, g as ROOT_DATA_KEY, h as PATH_PREFIX_KEY, i as ACTION_HANDLER_KEY, l as FORM_CONTEXT_KEY, m as LEVEL_KEY, o as COMPONENTS_KEY, p as HIDE_ROOT_TITLE_KEY, r as useFormContext, s as DISMISS_EXTERNAL_AT_KEY, u as FORM_DATA_KEY } from "./use-form-context-cDW2GW4-.mjs";
|
|
2
2
|
import { n as useAsLocale } from "./use-as-locale-BrFdAgnU.mjs";
|
|
3
3
|
import { computed, createBlock, createElementBlock, defineComponent, inject, isRef, mergeProps, onUnmounted, openBlock, provide, ref, resolveDynamicComponent, toDisplayString, unref, useId, watch } from "vue";
|
|
4
|
-
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_UNIT, DB_UNIT_REF, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_LABEL, META_READONLY, META_REQUIRED, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED,
|
|
4
|
+
import { DB_AMOUNT_CURRENCY, DB_AMOUNT_CURRENCY_REF, DB_COLUMN_PRECISION, DB_UNIT, DB_UNIT_REF, EXPECT_MAX_LENGTH, META_DEFAULT, META_DESCRIPTION, META_LABEL, META_READONLY, META_REQUIRED, UI_FORM_ACTION, UI_FORM_ATTR, UI_FORM_AUTOCOMPLETE, UI_FORM_CLASSES, UI_FORM_COMPONENT, UI_FORM_DISABLED, UI_FORM_FN_CLASSES, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_DISABLED, UI_FORM_FN_HINT, UI_FORM_FN_LABEL, UI_FORM_FN_PLACEHOLDER, UI_FORM_FN_PREFIX, UI_FORM_FN_READONLY, UI_FORM_FN_STYLES, 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_PLACEHOLDER, UI_FORM_PREFIX, UI_FORM_PREFIX_ICON, UI_FORM_PREFIX_REF, UI_FORM_STYLES, UI_FORM_SUFFIX, UI_FORM_SUFFIX_ICON, UI_FORM_SUFFIX_REF, UI_FORM_VALIDATE, WF_ACTION_WITH_DATA, buildGridClasses, createFieldValidator, createFormData, createFormValueResolver, extractValueHelp, getByPath, getCurrencyDecimals, getCurrencyDisplayParts, getFieldMeta, hasFieldMeta, isArrayField, isFieldHidden, isObjectField, isTupleField, isUnionField, joinPath, resolveAttrs, resolveFieldProp, resolveFormProp, resolveGridSpec, resolveOptions, resolveSingularLabel } from "@atscript/ui";
|
|
5
5
|
import { buildFieldEntry } from "@atscript/ui-fns";
|
|
6
6
|
//#region src/composables/use-as-field.ts
|
|
7
7
|
function useAsField(opts) {
|
|
@@ -83,6 +83,76 @@ function useAsField(opts) {
|
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
85
|
//#endregion
|
|
86
|
+
//#region src/composables/use-as-field-scope.ts
|
|
87
|
+
/**
|
|
88
|
+
* Shared inert scope for static-only resolution — no reactive reads.
|
|
89
|
+
* Module-level singleton (also used by AsField's allStatic fast path).
|
|
90
|
+
*/
|
|
91
|
+
const emptyScope = {
|
|
92
|
+
v: void 0,
|
|
93
|
+
data: {},
|
|
94
|
+
context: {},
|
|
95
|
+
entry: void 0
|
|
96
|
+
};
|
|
97
|
+
/**
|
|
98
|
+
* Child-field scope building + annotation resolution for custom CONTAINER
|
|
99
|
+
* renderers (tabbed shells, side-nav layouts) that partition or decorate a
|
|
100
|
+
* structured field's children without mounting `<AsField>` for each one.
|
|
101
|
+
*
|
|
102
|
+
* Returns plain functions — no internal computeds. Wrap calls in your own
|
|
103
|
+
* `computed` to inherit reactivity over form data.
|
|
104
|
+
*/
|
|
105
|
+
function useAsFieldScope() {
|
|
106
|
+
const { buildPath, getByPath, buildScope } = useFormContext("useAsFieldScope");
|
|
107
|
+
function absolutePath(field) {
|
|
108
|
+
return buildPath(field.path);
|
|
109
|
+
}
|
|
110
|
+
function scopeFor(field, opts) {
|
|
111
|
+
const base = buildScope(getByPath(buildPath(field.path)));
|
|
112
|
+
if (!opts?.withEntry) return base;
|
|
113
|
+
return buildFieldEntry(field.prop, base, field.path, {
|
|
114
|
+
type: field.type,
|
|
115
|
+
name: field.name
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
function resolveProp(field, fnKey, staticKey, opts) {
|
|
119
|
+
const hasFn = fnKey !== void 0 && hasFieldMeta(field.prop, fnKey);
|
|
120
|
+
if (!hasFn && (staticKey === void 0 || !hasFieldMeta(field.prop, staticKey))) return;
|
|
121
|
+
const scope = hasFn ? scopeFor(field, { withEntry: opts?.withEntry }) : emptyScope;
|
|
122
|
+
return resolveFieldProp(field.prop, fnKey ?? "", staticKey, scope, opts);
|
|
123
|
+
}
|
|
124
|
+
return {
|
|
125
|
+
absolutePath,
|
|
126
|
+
scopeFor,
|
|
127
|
+
resolveProp
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
//#endregion
|
|
131
|
+
//#region src/composables/use-as-optional-field.ts
|
|
132
|
+
/**
|
|
133
|
+
* Optional-field enable/clear for custom container renderers — the same
|
|
134
|
+
* behavior AsField wires onto `onToggleOptional`, usable without mounting
|
|
135
|
+
* `<AsField>` for the field.
|
|
136
|
+
*/
|
|
137
|
+
function useAsOptionalField(field) {
|
|
138
|
+
const { rootFormData, formContext, buildPath, getByPath, setByPath } = useFormContext("useAsOptionalField");
|
|
139
|
+
const handleChange = inject(CHANGE_HANDLER_KEY, () => {});
|
|
140
|
+
const enabled = computed(() => getByPath(buildPath(field.path)) != null);
|
|
141
|
+
function toggle(on) {
|
|
142
|
+
const path = buildPath(field.path);
|
|
143
|
+
if (on) {
|
|
144
|
+
const resolver = createFormValueResolver(rootFormData().value, formContext.value);
|
|
145
|
+
setByPath(path, createFormData(field.prop, resolver).value);
|
|
146
|
+
} else setByPath(path, void 0);
|
|
147
|
+
handleChange("update", path, getByPath(path));
|
|
148
|
+
}
|
|
149
|
+
return {
|
|
150
|
+
optional: field.prop.optional ?? false,
|
|
151
|
+
enabled,
|
|
152
|
+
toggle
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
//#endregion
|
|
86
156
|
//#region src/composables/use-as-data.ts
|
|
87
157
|
const EMPTY_PATH = computed(() => "");
|
|
88
158
|
const EMPTY_DATA = computed(() => void 0);
|
|
@@ -110,8 +180,7 @@ function useAsData() {
|
|
|
110
180
|
return computed(() => {
|
|
111
181
|
const w = wrapped.value;
|
|
112
182
|
if (!w) return void 0;
|
|
113
|
-
|
|
114
|
-
return getByPath(w, prefix ? `${prefix}.${name}` : name);
|
|
183
|
+
return getByPath(w, joinPath(pathPrefix.value, name));
|
|
115
184
|
});
|
|
116
185
|
}
|
|
117
186
|
return {
|
|
@@ -126,12 +195,6 @@ const _hoisted_1 = {
|
|
|
126
195
|
key: 1,
|
|
127
196
|
class: "as-field-missing"
|
|
128
197
|
};
|
|
129
|
-
const emptyScope = {
|
|
130
|
-
v: void 0,
|
|
131
|
-
data: {},
|
|
132
|
-
context: {},
|
|
133
|
-
entry: void 0
|
|
134
|
-
};
|
|
135
198
|
//#endregion
|
|
136
199
|
//#region src/components/as-field.vue
|
|
137
200
|
var as_field_default = /* @__PURE__ */ defineComponent({
|
|
@@ -287,13 +350,7 @@ var as_field_default = /* @__PURE__ */ defineComponent({
|
|
|
287
350
|
function setModel(value) {
|
|
288
351
|
setByPath(absolutePath.value, value);
|
|
289
352
|
}
|
|
290
|
-
|
|
291
|
-
if (enabled) {
|
|
292
|
-
const resolver = createFormValueResolver(rootFormData().value, formContext.value);
|
|
293
|
-
setModel(createFormData(props.field.prop, resolver).value);
|
|
294
|
-
} else setModel(void 0);
|
|
295
|
-
handleChange("update", absolutePath.value, getModel());
|
|
296
|
-
}
|
|
353
|
+
const { toggle: toggleOptional } = useAsOptionalField(props.field);
|
|
297
354
|
const resolvedComponent = computed(() => {
|
|
298
355
|
if (componentName) return components?.value?.[componentName];
|
|
299
356
|
const map = types?.value;
|
|
@@ -320,7 +377,7 @@ var as_field_default = /* @__PURE__ */ defineComponent({
|
|
|
320
377
|
if (props.field.allStatic) {
|
|
321
378
|
hasCustomValidators = false;
|
|
322
379
|
disabled = getFieldMeta(prop, UI_FORM_DISABLED) !== void 0;
|
|
323
|
-
hidden =
|
|
380
|
+
hidden = hasFieldMeta(prop, UI_FORM_HIDDEN);
|
|
324
381
|
optional = props.field.prop.optional ?? false;
|
|
325
382
|
readonly = getFieldMeta(prop, META_READONLY) !== void 0;
|
|
326
383
|
required = props.field.phantom ? void 0 : hasMetaRequired;
|
|
@@ -346,7 +403,7 @@ var as_field_default = /* @__PURE__ */ defineComponent({
|
|
|
346
403
|
const bs = needsBaseScope || needsFullScope ? computed(() => buildScope(getModel())) : void 0;
|
|
347
404
|
const boolOpts = { staticAsBoolean: true };
|
|
348
405
|
disabled = maybeComputed(hasFn.has("disabled"), () => resolveFieldProp(prop, UI_FORM_FN_DISABLED, UI_FORM_DISABLED, bs.value, boolOpts) ?? false, getFieldMeta(prop, UI_FORM_DISABLED) !== void 0);
|
|
349
|
-
hidden = maybeComputed(hasFn.has("hidden"), () =>
|
|
406
|
+
hidden = maybeComputed(hasFn.has("hidden"), () => isFieldHidden(prop, bs.value), getFieldMeta(prop, UI_FORM_HIDDEN) !== void 0);
|
|
350
407
|
optional = props.field.prop.optional ?? false;
|
|
351
408
|
readonly = maybeComputed(hasFn.has("readonly"), () => resolveFieldProp(prop, UI_FORM_FN_READONLY, META_READONLY, bs.value, boolOpts) ?? false, getFieldMeta(prop, META_READONLY) !== void 0);
|
|
352
409
|
required = props.field.phantom ? void 0 : hasMetaRequired;
|
|
@@ -494,4 +551,4 @@ var as_field_default = /* @__PURE__ */ defineComponent({
|
|
|
494
551
|
}
|
|
495
552
|
});
|
|
496
553
|
//#endregion
|
|
497
|
-
export { useAsData as n,
|
|
554
|
+
export { useAsField as a, useAsFieldScope as i, useAsData as n, useAsOptionalField as r, as_field_default as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as useAsUnionVariant, t as formatIndexedLabelParts } from "./use-form-context-
|
|
1
|
+
import { n as useAsUnionVariant, t as formatIndexedLabelParts } from "./use-form-context-cDW2GW4-.mjs";
|
|
2
2
|
import { r as useAsFocusFirstAfter } from "./focus-after-toggle-Dtl3P6CS.mjs";
|
|
3
3
|
import { n as as_optional_clear_default, t as as_variant_picker_default } from "./as-variant-picker-B3GLhKyt.mjs";
|
|
4
4
|
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, defineComponent, normalizeClass, normalizeStyle, openBlock, ref, renderSlot, toDisplayString, unref, vShow, withDirectives, withKeys, withModifiers } from "vue";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_use_form_context = require("./use-form-context-
|
|
1
|
+
const require_use_form_context = require("./use-form-context-B6ZnzfxG.cjs");
|
|
2
2
|
const require_focus_after_toggle = require("./focus-after-toggle-CWxiPZWi.cjs");
|
|
3
3
|
const require_as_variant_picker = require("./as-variant-picker-JlEhh7YO.cjs");
|
|
4
4
|
let vue = require("vue");
|
package/dist/as-field-shell.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_field_shell = require("./as-field-shell-
|
|
1
|
+
const require_as_field_shell = require("./as-field-shell-_XX9G3PP.cjs");
|
|
2
2
|
module.exports = require_as_field_shell.as_field_shell_default;
|
package/dist/as-field-shell.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_field_shell_default } from "./as-field-shell-
|
|
1
|
+
import { t as as_field_shell_default } from "./as-field-shell-BErcR8c9.mjs";
|
|
2
2
|
export { as_field_shell_default as default };
|
package/dist/as-field.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_field = require("./as-field-
|
|
1
|
+
const require_as_field = require("./as-field-BC3LdGue.cjs");
|
|
2
2
|
module.exports = require_as_field.as_field_default;
|
package/dist/as-field.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as _default } from "./as-field.vue-
|
|
1
|
+
import { t as _default } from "./as-field.vue-BHOc-pFM.cjs";
|
|
2
2
|
export = _default;
|
package/dist/as-field.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as _default } from "./as-field.vue-
|
|
1
|
+
import { t as _default } from "./as-field.vue-BOTSEvA_.mjs";
|
|
2
2
|
export { _default as default };
|
package/dist/as-field.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_field_default } from "./as-field-
|
|
1
|
+
import { t as as_field_default } from "./as-field-oZeBwI9U.mjs";
|
|
2
2
|
export { as_field_default as default };
|
|
@@ -2,7 +2,6 @@ import * as vue from "vue";
|
|
|
2
2
|
import { FormFieldDef } from "@atscript/ui";
|
|
3
3
|
|
|
4
4
|
//#region src/components/as-field.vue.d.ts
|
|
5
|
-
declare const _default: typeof __VLS_export;
|
|
6
5
|
declare const __VLS_export: <TFormData = any, TFormContext = any>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
7
6
|
props: vue.PublicProps & __VLS_PrettifyLocal<{
|
|
8
7
|
field: FormFieldDef;
|
|
@@ -21,6 +20,7 @@ declare const __VLS_export: <TFormData = any, TFormContext = any>(__VLS_props: N
|
|
|
21
20
|
}>) => vue.VNode & {
|
|
22
21
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
23
22
|
};
|
|
23
|
+
declare const _default: typeof __VLS_export;
|
|
24
24
|
type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K] } : { [K in keyof T as K]: T[K] }) & {};
|
|
25
25
|
//#endregion
|
|
26
26
|
export { _default as t };
|
|
@@ -2,7 +2,6 @@ import * as vue from "vue";
|
|
|
2
2
|
import { FormFieldDef } from "@atscript/ui";
|
|
3
3
|
|
|
4
4
|
//#region src/components/as-field.vue.d.ts
|
|
5
|
-
declare const _default: typeof __VLS_export;
|
|
6
5
|
declare const __VLS_export: <TFormData = any, TFormContext = any>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
7
6
|
props: vue.PublicProps & __VLS_PrettifyLocal<{
|
|
8
7
|
field: FormFieldDef;
|
|
@@ -21,6 +20,7 @@ declare const __VLS_export: <TFormData = any, TFormContext = any>(__VLS_props: N
|
|
|
21
20
|
}>) => vue.VNode & {
|
|
22
21
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
23
22
|
};
|
|
23
|
+
declare const _default: typeof __VLS_export;
|
|
24
24
|
type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K] } : { [K in keyof T as K]: T[K] }) & {};
|
|
25
25
|
//#endregion
|
|
26
26
|
export { _default as t };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { _ as TYPES_KEY, a as CHANGE_HANDLER_KEY, c as ERRORS_KEY, d as FORM_PATCH_KEY, f as FORM_STATE_KEY, g as ROOT_DATA_KEY, h as PATH_PREFIX_KEY, i as ACTION_HANDLER_KEY, l as FORM_CONTEXT_KEY, o as COMPONENTS_KEY, p as HIDE_ROOT_TITLE_KEY, s as DISMISS_EXTERNAL_AT_KEY, u as FORM_DATA_KEY } from "./use-form-context-
|
|
1
|
+
import { _ as TYPES_KEY, a as CHANGE_HANDLER_KEY, c as ERRORS_KEY, d as FORM_PATCH_KEY, f as FORM_STATE_KEY, g as ROOT_DATA_KEY, h as PATH_PREFIX_KEY, i as ACTION_HANDLER_KEY, l as FORM_CONTEXT_KEY, o as COMPONENTS_KEY, p as HIDE_ROOT_TITLE_KEY, s as DISMISS_EXTERNAL_AT_KEY, u as FORM_DATA_KEY } from "./use-form-context-cDW2GW4-.mjs";
|
|
2
2
|
import { i as useAsNestedSectionsStore, n as provideAsNestedSectionsStore, t as DESCENDANT_ERROR_COUNTS_KEY } from "./use-as-nested-sections-store-Dfo971PK.mjs";
|
|
3
3
|
import { t as CLIENT_FACTORY_KEY } from "./use-as-value-help-DrISSxCz.mjs";
|
|
4
|
-
import { t as as_field_default } from "./as-field-
|
|
5
|
-
import { t as as_iterator_default } from "./as-iterator-
|
|
4
|
+
import { t as as_field_default } from "./as-field-oZeBwI9U.mjs";
|
|
5
|
+
import { t as as_iterator_default } from "./as-iterator-CaXKhPjU.mjs";
|
|
6
6
|
import { computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, guardReactiveProps, inject, mergeProps, nextTick, normalizeProps, openBlock, provide, reactive, ref, renderSlot, toDisplayString, toRaw, toValue, unref, watch, watchEffect, withModifiers } from "vue";
|
|
7
7
|
import { META_DESCRIPTION, META_LABEL, UI_FORM_FN_DESCRIPTION, UI_FORM_FN_SUBMIT_DISABLED, UI_FORM_FN_SUBMIT_TEXT, UI_FORM_FN_TITLE, UI_FORM_SUBMIT_TEXT, buildDescendantErrorCounts, buildFormDiff, buildFormRebase, collectDirtyPaths, deepClone, getDeclaredFormActions, getFormValidator, iteratePathAncestors, mergeErrorMaps, resolveFormProp, setByPath, unionVariantChanged } from "@atscript/ui";
|
|
8
8
|
//#region src/composables/use-as-form-patch.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_use_form_context = require("./use-form-context-
|
|
1
|
+
const require_use_form_context = require("./use-form-context-B6ZnzfxG.cjs");
|
|
2
2
|
const require_use_as_nested_sections_store = require("./use-as-nested-sections-store-u1VgBJAP.cjs");
|
|
3
3
|
const require_use_as_value_help = require("./use-as-value-help-BsAriqCI.cjs");
|
|
4
|
-
const require_as_field = require("./as-field-
|
|
5
|
-
const require_as_iterator = require("./as-iterator-
|
|
4
|
+
const require_as_field = require("./as-field-BC3LdGue.cjs");
|
|
5
|
+
const require_as_iterator = require("./as-iterator-Cs1qZXGu.cjs");
|
|
6
6
|
let vue = require("vue");
|
|
7
7
|
let _atscript_ui = require("@atscript/ui");
|
|
8
8
|
//#region src/composables/use-as-form-patch.ts
|
package/dist/as-form.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_form = require("./as-form-
|
|
1
|
+
const require_as_form = require("./as-form-qrsfdEOq.cjs");
|
|
2
2
|
module.exports = require_as_form.as_form_default;
|
package/dist/as-form.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as _default, t as Props } from "./as-form.vue-
|
|
1
|
+
import { n as _default, t as Props } from "./as-form.vue-DLFb1NRU.cjs";
|
|
2
2
|
export { Props, _default as default };
|
package/dist/as-form.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as _default, t as Props } from "./as-form.vue-
|
|
1
|
+
import { n as _default, t as Props } from "./as-form.vue-DJZ7Ub54.mjs";
|
|
2
2
|
export { Props, _default as default };
|
package/dist/as-form.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_form_default } from "./as-form-
|
|
1
|
+
import { t as as_form_default } from "./as-form-KXdLWQMq.mjs";
|
|
2
2
|
export { as_form_default as default };
|