@xy-planning-network/trees 0.10.3 → 0.10.5
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/trees.es.js +15 -14
- package/dist/trees.umd.js +2 -2
- package/package.json +1 -1
- package/src/lib-components/forms/MultiCheckboxes.vue +20 -24
- package/src/lib-components/overlays/ContentModal.vue +3 -1
- package/types/lib-components/indicators/InlineAlert.vue.d.ts +1 -1
- package/types/lib-components/overlays/ContentModal.vue.d.ts +5 -0
package/dist/trees.es.js
CHANGED
|
@@ -5241,6 +5241,7 @@ const rc = /* @__PURE__ */ v("span", { class: "sr-only" }, "Open options", -1),
|
|
|
5241
5241
|
__name: "ContentModal",
|
|
5242
5242
|
props: {
|
|
5243
5243
|
modelValue: { type: Boolean },
|
|
5244
|
+
btnText: { default: "Go back" },
|
|
5244
5245
|
title: { default: "" }
|
|
5245
5246
|
},
|
|
5246
5247
|
emits: ["update:modelValue"],
|
|
@@ -5307,7 +5308,7 @@ const rc = /* @__PURE__ */ v("span", { class: "sr-only" }, "Open options", -1),
|
|
|
5307
5308
|
type: "button",
|
|
5308
5309
|
class: "inline-flex justify-center w-full xy-btn",
|
|
5309
5310
|
onClick: a[0] || (a[0] = (o) => e(!1))
|
|
5310
|
-
},
|
|
5311
|
+
}, U(r.btnText), 1)
|
|
5311
5312
|
])
|
|
5312
5313
|
])
|
|
5313
5314
|
]),
|
|
@@ -9342,7 +9343,7 @@ const wf = /* @__PURE__ */ gf(vf, [["render", yf]]), xf = { class: "absolute ins
|
|
|
9342
9343
|
const n = t, { aria: e, inputID: r, isDisabled: a, modelState: o, errorState: s, validate: i } = st(n), l = (y, x) => {
|
|
9343
9344
|
const D = y.target.checked;
|
|
9344
9345
|
Array.isArray(o.value) || (o.value = []), D ? o.value.push(x) : o.value.splice(o.value.indexOf(x), 1), i(y);
|
|
9345
|
-
}, c = A(() => Array.isArray(o.value) ? o.value.length : 0), u = A(() => n.min ||
|
|
9346
|
+
}, c = A(() => Array.isArray(o.value) ? o.value.length : 0), u = A(() => n.min || null), d = A(() => n.max || null), p = A(() => u.value !== null && c.value < u.value ? `Please select at least ${u.value} of these options.` : d.value !== null && c.value > d.value ? `Please limit your selection to ${d.value} of these options.` : u.value !== null && d.value !== null && (c.value < u.value || c.value > d.value) ? `Please select between ${u.value} and ${d.value} of these options.` : ""), g = O(null), b = () => {
|
|
9346
9347
|
var y;
|
|
9347
9348
|
s.value || (s.value = p.value, (y = g.value) == null || y.setCustomValidity(p.value));
|
|
9348
9349
|
};
|
|
@@ -9356,7 +9357,7 @@ const wf = /* @__PURE__ */ gf(vf, [["render", yf]]), xf = { class: "absolute ins
|
|
|
9356
9357
|
E(sn, {
|
|
9357
9358
|
id: m(e).labelledby,
|
|
9358
9359
|
label: y.label,
|
|
9359
|
-
required: u.value
|
|
9360
|
+
required: !!u.value
|
|
9360
9361
|
}, null, 8, ["id", "label", "required"]),
|
|
9361
9362
|
y.help ? (w(), B(Ee, {
|
|
9362
9363
|
key: 0,
|
|
@@ -9371,16 +9372,6 @@ const wf = /* @__PURE__ */ gf(vf, [["render", yf]]), xf = { class: "absolute ins
|
|
|
9371
9372
|
text: m(s)
|
|
9372
9373
|
}, null, 8, ["id", "text"])
|
|
9373
9374
|
])) : V("", !0),
|
|
9374
|
-
p.value ? (w(), k("input", {
|
|
9375
|
-
key: 1,
|
|
9376
|
-
ref_key: "errorInput",
|
|
9377
|
-
ref: g,
|
|
9378
|
-
required: "",
|
|
9379
|
-
class: "sr-only top-1 left-1",
|
|
9380
|
-
"aria-hidden": "",
|
|
9381
|
-
type: "checkbox",
|
|
9382
|
-
onInvalid: b
|
|
9383
|
-
}, null, 544)) : V("", !0),
|
|
9384
9375
|
v("div", rh, [
|
|
9385
9376
|
v("div", {
|
|
9386
9377
|
class: N(["grid gap-y-5", {
|
|
@@ -9430,7 +9421,17 @@ const wf = /* @__PURE__ */ gf(vf, [["render", yf]]), xf = { class: "absolute ins
|
|
|
9430
9421
|
]);
|
|
9431
9422
|
}), 128))
|
|
9432
9423
|
], 2)
|
|
9433
|
-
])
|
|
9424
|
+
]),
|
|
9425
|
+
p.value ? (w(), k("input", {
|
|
9426
|
+
key: 1,
|
|
9427
|
+
ref_key: "errorInput",
|
|
9428
|
+
ref: g,
|
|
9429
|
+
required: "",
|
|
9430
|
+
class: "sr-only top-1 left-1",
|
|
9431
|
+
"aria-hidden": "",
|
|
9432
|
+
type: "checkbox",
|
|
9433
|
+
onInvalid: b
|
|
9434
|
+
}, null, 544)) : V("", !0)
|
|
9434
9435
|
], 8, th));
|
|
9435
9436
|
}
|
|
9436
9437
|
}), lh = ["aria-labelledby", "aria-describedby", "aria-errormessage"], uh = { key: 0 }, ch = { class: "flex" }, dh = { class: "flex items-center h-5" }, fh = ["id", "aria-describedby", "aria-labelledby", "checked", "disabled", "name", "value", "onChange"], ph = { class: "ml-3" }, mh = /* @__PURE__ */ I({
|