@effect-app/vue-components 0.2.4 → 0.2.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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as P, resolveComponent as i, createElementBlock as g, openBlock as o, createBlock as n, createCommentVNode as
|
|
1
|
+
import { defineComponent as P, resolveComponent as i, createElementBlock as g, openBlock as o, createBlock as n, createCommentVNode as l, mergeProps as s } from "vue";
|
|
2
2
|
const b = /* @__PURE__ */ P({
|
|
3
3
|
inheritAttrs: !1,
|
|
4
4
|
__name: "OmegaInputVuetify",
|
|
@@ -6,15 +6,15 @@ const b = /* @__PURE__ */ P({
|
|
|
6
6
|
inputProps: {}
|
|
7
7
|
},
|
|
8
8
|
emits: ["focus", "blur"],
|
|
9
|
-
setup(
|
|
9
|
+
setup(v) {
|
|
10
10
|
return (e, r) => {
|
|
11
11
|
const a = i("v-checkbox"), u = i("v-text-field"), t = i("v-textarea"), m = i("v-select"), d = i("v-autocomplete");
|
|
12
12
|
return o(), g("div", {
|
|
13
13
|
class: "omega-input",
|
|
14
|
-
onFocusout: r[
|
|
15
|
-
onFocusin: r[
|
|
14
|
+
onFocusout: r[4] || (r[4] = (p) => e.$emit("blur", p)),
|
|
15
|
+
onFocusin: r[5] || (r[5] = (p) => e.$emit("focus", p))
|
|
16
16
|
}, [
|
|
17
|
-
e.inputProps.type === "boolean" ? (o(), n(a,
|
|
17
|
+
e.inputProps.type === "boolean" ? (o(), n(a, s({
|
|
18
18
|
key: 0,
|
|
19
19
|
id: e.inputProps.id,
|
|
20
20
|
name: e.inputProps.name,
|
|
@@ -25,8 +25,8 @@ const b = /* @__PURE__ */ P({
|
|
|
25
25
|
}, e.$attrs, {
|
|
26
26
|
ripple: "",
|
|
27
27
|
onChange: r[0] || (r[0] = (p) => e.inputProps.field.handleChange(p.target.checked))
|
|
28
|
-
}), null, 16, ["id", "name", "label", "model-value", "error-messages", "error"])) :
|
|
29
|
-
e.inputProps.type === "email" || e.inputProps.type === "string" ? (o(), n(u,
|
|
28
|
+
}), null, 16, ["id", "name", "label", "model-value", "error-messages", "error"])) : l("", !0),
|
|
29
|
+
e.inputProps.type === "email" || e.inputProps.type === "string" ? (o(), n(u, s({
|
|
30
30
|
key: 1,
|
|
31
31
|
id: e.inputProps.id,
|
|
32
32
|
required: e.inputProps.required,
|
|
@@ -40,8 +40,8 @@ const b = /* @__PURE__ */ P({
|
|
|
40
40
|
error: e.inputProps.error
|
|
41
41
|
}, e.$attrs, {
|
|
42
42
|
"onUpdate:modelValue": e.inputProps.field.handleChange
|
|
43
|
-
}), null, 16, ["id", "required", "min-length", "max-length", "type", "name", "label", "model-value", "error-messages", "error", "onUpdate:modelValue"])) :
|
|
44
|
-
e.inputProps.type === "text" ? (o(), n(t,
|
|
43
|
+
}), null, 16, ["id", "required", "min-length", "max-length", "type", "name", "label", "model-value", "error-messages", "error", "onUpdate:modelValue"])) : l("", !0),
|
|
44
|
+
e.inputProps.type === "text" ? (o(), n(t, s({ key: 2 }, e.$attrs, {
|
|
45
45
|
id: e.inputProps.id,
|
|
46
46
|
required: e.inputProps.required,
|
|
47
47
|
"min-length": e.inputProps.minLength,
|
|
@@ -53,8 +53,8 @@ const b = /* @__PURE__ */ P({
|
|
|
53
53
|
"error-messages": e.inputProps.errorMessages,
|
|
54
54
|
error: e.inputProps.error,
|
|
55
55
|
"onUpdate:modelValue": e.inputProps.field.handleChange
|
|
56
|
-
}), null, 16, ["id", "required", "min-length", "max-length", "type", "name", "label", "model-value", "error-messages", "error", "onUpdate:modelValue"])) :
|
|
57
|
-
e.inputProps.type === "number" ? (o(), n(u,
|
|
56
|
+
}), null, 16, ["id", "required", "min-length", "max-length", "type", "name", "label", "model-value", "error-messages", "error", "onUpdate:modelValue"])) : l("", !0),
|
|
57
|
+
e.inputProps.type === "number" ? (o(), n(u, s({
|
|
58
58
|
key: 3,
|
|
59
59
|
id: e.inputProps.id,
|
|
60
60
|
required: e.inputProps.required,
|
|
@@ -70,8 +70,8 @@ const b = /* @__PURE__ */ P({
|
|
|
70
70
|
"onUpdate:modelValue": r[1] || (r[1] = (p) => {
|
|
71
71
|
e.inputProps.field.handleChange(Number(p));
|
|
72
72
|
})
|
|
73
|
-
}), null, 16, ["id", "required", "min", "max", "type", "name", "label", "model-value", "error-messages", "error"])) :
|
|
74
|
-
e.inputProps.type === "select" || e.inputProps.type === "multiple" ? (o(), n(m,
|
|
73
|
+
}), null, 16, ["id", "required", "min", "max", "type", "name", "label", "model-value", "error-messages", "error"])) : l("", !0),
|
|
74
|
+
e.inputProps.type === "select" || e.inputProps.type === "multiple" ? (o(), n(m, s({
|
|
75
75
|
key: 4,
|
|
76
76
|
id: e.inputProps.id,
|
|
77
77
|
clearable: e.inputProps.type === "select",
|
|
@@ -85,9 +85,10 @@ const b = /* @__PURE__ */ P({
|
|
|
85
85
|
"error-messages": e.inputProps.errorMessages,
|
|
86
86
|
error: e.inputProps.error
|
|
87
87
|
}, e.$attrs, {
|
|
88
|
+
onClear: r[2] || (r[2] = (p) => e.inputProps.field.handleChange(void 0)),
|
|
88
89
|
"onUpdate:modelValue": e.inputProps.field.handleChange
|
|
89
|
-
}), null, 16, ["id", "clearable", "required", "multiple", "chips", "name", "model-value", "label", "items", "error-messages", "error", "onUpdate:modelValue"])) :
|
|
90
|
-
e.inputProps.type === "autocomplete" || e.inputProps.type === "autocompletemultiple" ? (o(), n(d,
|
|
90
|
+
}), null, 16, ["id", "clearable", "required", "multiple", "chips", "name", "model-value", "label", "items", "error-messages", "error", "onUpdate:modelValue"])) : l("", !0),
|
|
91
|
+
e.inputProps.type === "autocomplete" || e.inputProps.type === "autocompletemultiple" ? (o(), n(d, s({
|
|
91
92
|
key: 5,
|
|
92
93
|
id: e.inputProps.id,
|
|
93
94
|
clearable: e.inputProps.type === "autocomplete",
|
|
@@ -101,8 +102,9 @@ const b = /* @__PURE__ */ P({
|
|
|
101
102
|
error: e.inputProps.error,
|
|
102
103
|
chips: e.inputProps.type === "autocompletemultiple"
|
|
103
104
|
}, e.$attrs, {
|
|
105
|
+
onClear: r[3] || (r[3] = (p) => e.inputProps.field.handleChange(void 0)),
|
|
104
106
|
"onUpdate:modelValue": e.inputProps.field.handleChange
|
|
105
|
-
}), null, 16, ["id", "clearable", "multiple", "required", "name", "model-value", "label", "items", "error-messages", "error", "chips", "onUpdate:modelValue"])) :
|
|
107
|
+
}), null, 16, ["id", "clearable", "multiple", "required", "name", "model-value", "label", "items", "error-messages", "error", "chips", "onUpdate:modelValue"])) : l("", !0)
|
|
106
108
|
], 32);
|
|
107
109
|
};
|
|
108
110
|
}
|
package/package.json
CHANGED
|
@@ -79,6 +79,7 @@
|
|
|
79
79
|
:error-messages="inputProps.errorMessages"
|
|
80
80
|
:error="inputProps.error"
|
|
81
81
|
v-bind="$attrs"
|
|
82
|
+
@clear="inputProps.field.handleChange(undefined)"
|
|
82
83
|
@update:model-value="inputProps.field.handleChange"
|
|
83
84
|
/>
|
|
84
85
|
|
|
@@ -99,6 +100,7 @@
|
|
|
99
100
|
:error="inputProps.error"
|
|
100
101
|
:chips="inputProps.type === 'autocompletemultiple'"
|
|
101
102
|
v-bind="$attrs"
|
|
103
|
+
@clear="inputProps.field.handleChange(undefined)"
|
|
102
104
|
@update:model-value="inputProps.field.handleChange"
|
|
103
105
|
/>
|
|
104
106
|
</div>
|