@effect-app/vue-components 0.1.0 → 0.1.1
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
|
-
(function(){"use strict";try{if(typeof document<"u"){var
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var n=document.createElement("style");if(n.appendChild(document.createTextNode(".omega-input .v-input__details:has(.v-messages:empty){grid-template-rows:0fr;transition:all .2s}.omega-input .v-messages:empty{min-height:0}.omega-input .v-input__details:has(.v-messages){transition:all .2s;overflow:hidden;min-height:0;display:grid;grid-template-rows:1fr}.omega-input .v-messages{transition:all .2s}.omega-input .v-messages>*{transition-duration:0s!important}.omega-input [role=alert]:has(.v-messages:empty){padding:0}.omega-input .v-btn{cursor:pointer;width:auto;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none;display:block;min-width:auto;height:auto;padding:.5em .5em .5em 1em}")),document.head.appendChild(n),window.customElements){const e=window.customElements.define;window.customElements.define=function(o,t){const a=t.prototype.connectedCallback;return t.prototype.connectedCallback=function(){if(a&&a.call(this),this.shadowRoot){const i=document.createElement("style");i.appendChild(document.createTextNode(".omega-input .v-input__details:has(.v-messages:empty){grid-template-rows:0fr;transition:all .2s}.omega-input .v-messages:empty{min-height:0}.omega-input .v-input__details:has(.v-messages){transition:all .2s;overflow:hidden;min-height:0;display:grid;grid-template-rows:1fr}.omega-input .v-messages{transition:all .2s}.omega-input .v-messages>*{transition-duration:0s!important}.omega-input [role=alert]:has(.v-messages:empty){padding:0}.omega-input .v-btn{cursor:pointer;width:auto;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none;display:block;min-width:auto;height:auto;padding:.5em .5em .5em 1em}")),this.shadowRoot.appendChild(i)}},e.call(window.customElements,o,t)}}}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
|
|
2
2
|
import { defineComponent as C, getCurrentInstance as L, useId as O, computed as n, watch as V, onMounted as S, ref as $, watchEffect as A, useAttrs as P, renderSlot as D, normalizeProps as M, guardReactiveProps as R, createBlock as T, createCommentVNode as U, unref as z, openBlock as F } from "vue";
|
|
3
3
|
import { useStore as N } from "@tanstack/vue-form";
|
|
4
4
|
import { useOmegaErrors as j } from "./vue-components.es4.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as V, resolveComponent as
|
|
1
|
+
import { defineComponent as V, resolveComponent as n, createElementBlock as m, openBlock as r, createBlock as l, createCommentVNode as p, mergeProps as i, normalizeClass as g, createVNode as s, unref as t, withCtx as v } from "vue";
|
|
2
2
|
import { mdiRefresh as u } from "@mdi/js";
|
|
3
3
|
const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
4
4
|
__name: "OmegaInputVuetify",
|
|
@@ -6,8 +6,8 @@ const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
|
6
6
|
inputProps: {}
|
|
7
7
|
},
|
|
8
8
|
setup(C) {
|
|
9
|
-
return (e,
|
|
10
|
-
const d =
|
|
9
|
+
return (e, o) => {
|
|
10
|
+
const d = n("v-text-field"), h = n("v-textarea"), f = n("v-select"), P = n("v-icon"), y = n("v-btn"), b = n("v-autocomplete");
|
|
11
11
|
return r(), m("div", q, [
|
|
12
12
|
e.inputProps.type === "email" || e.inputProps.type === "string" ? (r(), l(d, i({
|
|
13
13
|
key: 0,
|
|
@@ -52,14 +52,14 @@ const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
|
52
52
|
"error-messages": e.inputProps.errorMessages,
|
|
53
53
|
error: e.inputProps.error
|
|
54
54
|
}, e.$attrs, {
|
|
55
|
-
"onUpdate:modelValue":
|
|
55
|
+
"onUpdate:modelValue": o[0] || (o[0] = (a) => {
|
|
56
56
|
e.inputProps.field.handleChange(Number(a));
|
|
57
57
|
}),
|
|
58
58
|
onBlur: e.inputProps.setRealDirty
|
|
59
59
|
}), null, 16, ["id", "required", "min", "max", "type", "name", "label", "model-value", "error-messages", "error", "onBlur"])) : p("", !0),
|
|
60
60
|
e.inputProps.type === "select" || e.inputProps.type === "multiple" ? (r(), m("div", {
|
|
61
61
|
key: 3,
|
|
62
|
-
class:
|
|
62
|
+
class: g(e.inputProps.type !== "multiple" && "d-flex")
|
|
63
63
|
}, [
|
|
64
64
|
s(f, i({
|
|
65
65
|
id: e.inputProps.id,
|
|
@@ -76,13 +76,13 @@ const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
|
76
76
|
"onUpdate:modelValue": e.inputProps.field.handleChange,
|
|
77
77
|
onBlur: e.inputProps.setRealDirty
|
|
78
78
|
}), null, 16, ["id", "required", "multiple", "chips", "name", "model-value", "label", "items", "error-messages", "error", "onUpdate:modelValue", "onBlur"]),
|
|
79
|
-
e.inputProps.type === "select" ? (r(), l(
|
|
79
|
+
e.inputProps.type === "select" ? (r(), l(y, {
|
|
80
80
|
key: 0,
|
|
81
81
|
"variant-btn": "secondary",
|
|
82
82
|
"variant-icon": t(u),
|
|
83
83
|
class: "mr-2",
|
|
84
84
|
title: "Reset",
|
|
85
|
-
onClick:
|
|
85
|
+
onClick: o[1] || (o[1] = (a) => e.inputProps.field.handleChange(void 0))
|
|
86
86
|
}, {
|
|
87
87
|
default: v(() => [
|
|
88
88
|
s(P, { icon: t(u) }, null, 8, ["icon"])
|
|
@@ -92,9 +92,7 @@ const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
|
92
92
|
], 2)) : p("", !0),
|
|
93
93
|
e.inputProps.type === "autocomplete" || e.inputProps.type === "autocompletemultiple" ? (r(), m("div", {
|
|
94
94
|
key: 4,
|
|
95
|
-
class:
|
|
96
|
-
e.inputProps.type !== "autocompletemultiple" && "d-flex align-center"
|
|
97
|
-
)
|
|
95
|
+
class: g(e.inputProps.type !== "autocompletemultiple" && "d-flex")
|
|
98
96
|
}, [
|
|
99
97
|
s(b, i({
|
|
100
98
|
id: e.inputProps.id,
|
|
@@ -111,13 +109,13 @@ const q = { class: "omega-input" }, U = /* @__PURE__ */ V({
|
|
|
111
109
|
"onUpdate:modelValue": e.inputProps.field.handleChange,
|
|
112
110
|
onBlur: e.inputProps.setRealDirty
|
|
113
111
|
}), null, 16, ["id", "multiple", "required", "name", "model-value", "label", "items", "error-messages", "error", "chips", "onUpdate:modelValue", "onBlur"]),
|
|
114
|
-
e.inputProps.type === "autocomplete" ? (r(), l(
|
|
112
|
+
e.inputProps.type === "autocomplete" ? (r(), l(y, {
|
|
115
113
|
key: 0,
|
|
116
114
|
"variant-btn": "secondary",
|
|
117
115
|
"variant-icon": t(u),
|
|
118
116
|
class: "mr-2",
|
|
119
117
|
title: "Reset",
|
|
120
|
-
onClick:
|
|
118
|
+
onClick: o[2] || (o[2] = (a) => e.inputProps.field.handleChange(void 0))
|
|
121
119
|
}, {
|
|
122
120
|
default: v(() => [
|
|
123
121
|
s(P, { icon: t(u) }, null, 8, ["icon"])
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(){"use strict";try{if(typeof document<"u"){var
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var n=document.createElement("style");if(n.appendChild(document.createTextNode(".omega-input .v-input__details:has(.v-messages:empty){grid-template-rows:0fr;transition:all .2s}.omega-input .v-messages:empty{min-height:0}.omega-input .v-input__details:has(.v-messages){transition:all .2s;overflow:hidden;min-height:0;display:grid;grid-template-rows:1fr}.omega-input .v-messages{transition:all .2s}.omega-input .v-messages>*{transition-duration:0s!important}.omega-input [role=alert]:has(.v-messages:empty){padding:0}.omega-input .v-btn{cursor:pointer;width:auto;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none;display:block;min-width:auto;height:auto;padding:.5em .5em .5em 1em}")),document.head.appendChild(n),window.customElements){const e=window.customElements.define;window.customElements.define=function(o,t){const a=t.prototype.connectedCallback;return t.prototype.connectedCallback=function(){if(a&&a.call(this),this.shadowRoot){const i=document.createElement("style");i.appendChild(document.createTextNode(".omega-input .v-input__details:has(.v-messages:empty){grid-template-rows:0fr;transition:all .2s}.omega-input .v-messages:empty{min-height:0}.omega-input .v-input__details:has(.v-messages){transition:all .2s;overflow:hidden;min-height:0;display:grid;grid-template-rows:1fr}.omega-input .v-messages{transition:all .2s}.omega-input .v-messages>*{transition-duration:0s!important}.omega-input [role=alert]:has(.v-messages:empty){padding:0}.omega-input .v-btn{cursor:pointer;width:auto;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none;display:block;min-width:auto;height:auto;padding:.5em .5em .5em 1em}")),this.shadowRoot.appendChild(i)}},e.call(window.customElements,o,t)}}}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
|
|
2
2
|
import o from "./vue-components.es18.js";
|
|
3
3
|
|
|
4
4
|
export {
|
package/package.json
CHANGED
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
/>
|
|
55
55
|
<div
|
|
56
56
|
v-if="inputProps.type === 'select' || inputProps.type === 'multiple'"
|
|
57
|
-
:class="inputProps.type !== 'multiple' && 'd-flex
|
|
57
|
+
:class="inputProps.type !== 'multiple' && 'd-flex'"
|
|
58
58
|
>
|
|
59
59
|
<v-select
|
|
60
60
|
:id="inputProps.id"
|
|
@@ -88,9 +88,7 @@
|
|
|
88
88
|
inputProps.type === 'autocomplete' ||
|
|
89
89
|
inputProps.type === 'autocompletemultiple'
|
|
90
90
|
"
|
|
91
|
-
:class="
|
|
92
|
-
inputProps.type !== 'autocompletemultiple' && 'd-flex align-center'
|
|
93
|
-
"
|
|
91
|
+
:class="inputProps.type !== 'autocompletemultiple' && 'd-flex'"
|
|
94
92
|
>
|
|
95
93
|
<v-autocomplete
|
|
96
94
|
:id="inputProps.id"
|
|
@@ -156,9 +154,20 @@ defineProps<{
|
|
|
156
154
|
}
|
|
157
155
|
}
|
|
158
156
|
|
|
159
|
-
v-
|
|
160
|
-
|
|
157
|
+
[role="alert"]:has(.v-messages:empty) {
|
|
158
|
+
padding: 0;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.v-btn {
|
|
161
162
|
cursor: pointer;
|
|
163
|
+
padding: 0;
|
|
164
|
+
width: auto;
|
|
165
|
+
appearance: none;
|
|
166
|
+
box-shadow: none;
|
|
167
|
+
display: block;
|
|
168
|
+
min-width: auto;
|
|
169
|
+
height: auto;
|
|
170
|
+
padding: 0.5em 0.5em 0.5em 1em;
|
|
162
171
|
}
|
|
163
172
|
}
|
|
164
173
|
</style>
|