@charpente-ui/vue 1.0.0-beta.3 → 1.0.0-beta.4
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/charpente.js +22 -19
- package/dist/charpente.umd.cjs +1 -1
- package/dist/components/BaseLabel.d.ts +8 -1
- package/package.json +1 -1
package/dist/charpente.js
CHANGED
|
@@ -24,10 +24,10 @@ const T = /* @__PURE__ */ n({
|
|
|
24
24
|
}),
|
|
25
25
|
emits: ["update:modelValue"],
|
|
26
26
|
setup(t) {
|
|
27
|
-
const e = m(t, "modelValue"), o = c(),
|
|
28
|
-
return (
|
|
27
|
+
const e = m(t, "modelValue"), o = c(), s = p(() => o.id || v());
|
|
28
|
+
return (l, a) => _((u(), d("input", i({ type: "checkbox" }, l.$attrs, {
|
|
29
29
|
"onUpdate:modelValue": a[0] || (a[0] = (r) => e.value = r),
|
|
30
|
-
id:
|
|
30
|
+
id: s.value,
|
|
31
31
|
value: t.value
|
|
32
32
|
}), null, 16, y)), [
|
|
33
33
|
[b, e.value]
|
|
@@ -42,10 +42,10 @@ const T = /* @__PURE__ */ n({
|
|
|
42
42
|
},
|
|
43
43
|
emits: ["update:modelValue"],
|
|
44
44
|
setup(t) {
|
|
45
|
-
const e = m(t, "modelValue"), o = c(),
|
|
46
|
-
return (
|
|
45
|
+
const e = m(t, "modelValue"), o = c(), s = p(() => o.id || v());
|
|
46
|
+
return (l, a) => _((u(), d("input", i(l.$attrs, {
|
|
47
47
|
"onUpdate:modelValue": a[0] || (a[0] = (r) => e.value = r),
|
|
48
|
-
id:
|
|
48
|
+
id: s.value
|
|
49
49
|
}), null, 16, U)), [
|
|
50
50
|
[x, e.value]
|
|
51
51
|
]);
|
|
@@ -57,8 +57,11 @@ const T = /* @__PURE__ */ n({
|
|
|
57
57
|
for: {}
|
|
58
58
|
},
|
|
59
59
|
setup(t) {
|
|
60
|
-
|
|
61
|
-
|
|
60
|
+
const e = t;
|
|
61
|
+
return (o, s) => (u(), d("label", i(o.$attrs, {
|
|
62
|
+
for: e.for
|
|
63
|
+
}), [
|
|
64
|
+
f(o.$slots, "default")
|
|
62
65
|
], 16, R));
|
|
63
66
|
}
|
|
64
67
|
}), S = ["id", "value"], E = /* @__PURE__ */ n({
|
|
@@ -72,10 +75,10 @@ const T = /* @__PURE__ */ n({
|
|
|
72
75
|
}),
|
|
73
76
|
emits: ["update:modelValue"],
|
|
74
77
|
setup(t) {
|
|
75
|
-
const e = m(t, "modelValue"), o = c(),
|
|
76
|
-
return (
|
|
78
|
+
const e = m(t, "modelValue"), o = c(), s = p(() => o.id || v());
|
|
79
|
+
return (l, a) => _((u(), d("input", i({ type: "radio" }, l.$attrs, {
|
|
77
80
|
"onUpdate:modelValue": a[0] || (a[0] = (r) => e.value = r),
|
|
78
|
-
id:
|
|
81
|
+
id: s.value,
|
|
79
82
|
value: t.value
|
|
80
83
|
}), null, 16, S)), [
|
|
81
84
|
[A, e.value]
|
|
@@ -90,12 +93,12 @@ const T = /* @__PURE__ */ n({
|
|
|
90
93
|
},
|
|
91
94
|
emits: ["update:modelValue"],
|
|
92
95
|
setup(t) {
|
|
93
|
-
const e = m(t, "modelValue"), o = c(),
|
|
94
|
-
return (
|
|
96
|
+
const e = m(t, "modelValue"), o = c(), s = p(() => o.id || v());
|
|
97
|
+
return (l, a) => _((u(), d("select", i(l.$attrs, {
|
|
95
98
|
"onUpdate:modelValue": a[0] || (a[0] = (r) => e.value = r),
|
|
96
|
-
id:
|
|
99
|
+
id: s.value
|
|
97
100
|
}), [
|
|
98
|
-
f(
|
|
101
|
+
f(l.$slots, "default")
|
|
99
102
|
], 16, g)), [
|
|
100
103
|
[k, e.value]
|
|
101
104
|
]);
|
|
@@ -109,11 +112,11 @@ const T = /* @__PURE__ */ n({
|
|
|
109
112
|
},
|
|
110
113
|
emits: ["update:modelValue"],
|
|
111
114
|
setup(t) {
|
|
112
|
-
const e = m(t, "modelValue"), o = c(),
|
|
113
|
-
return (
|
|
114
|
-
id:
|
|
115
|
+
const e = m(t, "modelValue"), o = c(), s = p(() => o.id || v());
|
|
116
|
+
return (l, a) => _((u(), d("textarea", i({
|
|
117
|
+
id: s.value,
|
|
115
118
|
"onUpdate:modelValue": a[0] || (a[0] = (r) => e.value = r)
|
|
116
|
-
},
|
|
119
|
+
}, l.$attrs), null, 16, D)), [
|
|
117
120
|
[I, e.value]
|
|
118
121
|
]);
|
|
119
122
|
}
|
package/dist/charpente.umd.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(n,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(n=typeof globalThis<"u"?globalThis:n||self,e(n.Charpente={},n.Vue))})(this,(function(n,e){"use strict";const i=e.defineComponent({inheritAttrs:!1,__name:"BaseButton",props:{as:{default:"button"}},setup(o){return(t,s)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.as),e.normalizeProps(e.guardReactiveProps(t.$attrs)),{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3},16))}}),m=["id","value"],c=e.defineComponent({inheritAttrs:!1,__name:"BaseCheckbox",props:e.mergeModels({value:{}},{modelValue:{type:[Boolean,Array]},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),
|
|
1
|
+
(function(n,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(n=typeof globalThis<"u"?globalThis:n||self,e(n.Charpente={},n.Vue))})(this,(function(n,e){"use strict";const i=e.defineComponent({inheritAttrs:!1,__name:"BaseButton",props:{as:{default:"button"}},setup(o){return(t,s)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.as),e.normalizeProps(e.guardReactiveProps(t.$attrs)),{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3},16))}}),m=["id","value"],c=e.defineComponent({inheritAttrs:!1,__name:"BaseCheckbox",props:e.mergeModels({value:{}},{modelValue:{type:[Boolean,Array]},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),r=e.computed(()=>s.id||e.useId());return(a,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({type:"checkbox"},a.$attrs,{"onUpdate:modelValue":l[0]||(l[0]=d=>t.value=d),id:r.value,value:o.value}),null,16,m)),[[e.vModelCheckbox,t.value]])}}),p=["id"],u=e.defineComponent({inheritAttrs:!1,__name:"BaseInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),r=e.computed(()=>s.id||e.useId());return(a,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps(a.$attrs,{"onUpdate:modelValue":l[0]||(l[0]=d=>t.value=d),id:r.value}),null,16,p)),[[e.vModelDynamic,t.value]])}}),f=["for"],_=e.defineComponent({inheritAttrs:!1,__name:"BaseLabel",props:{for:{}},setup(o){const t=o;return(s,r)=>(e.openBlock(),e.createElementBlock("label",e.mergeProps(s.$attrs,{for:t.for}),[e.renderSlot(s.$slots,"default")],16,f))}}),h=["id","value"],B=e.defineComponent({inheritAttrs:!1,__name:"BaseRadio",props:e.mergeModels({value:{}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),r=e.computed(()=>s.id||e.useId());return(a,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({type:"radio"},a.$attrs,{"onUpdate:modelValue":l[0]||(l[0]=d=>t.value=d),id:r.value,value:o.value}),null,16,h)),[[e.vModelRadio,t.value]])}}),V=["id"],$=e.defineComponent({inheritAttrs:!1,__name:"BaseSelect",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),r=e.computed(()=>s.id||e.useId());return(a,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("select",e.mergeProps(a.$attrs,{"onUpdate:modelValue":l[0]||(l[0]=d=>t.value=d),id:r.value}),[e.renderSlot(a.$slots,"default")],16,V)),[[e.vModelSelect,t.value]])}}),C=["id"],k=e.defineComponent({inheritAttrs:!1,__name:"BaseTextarea",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),s=e.useAttrs(),r=e.computed(()=>s.id||e.useId());return(a,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("textarea",e.mergeProps({id:r.value,"onUpdate:modelValue":l[0]||(l[0]=d=>t.value=d)},a.$attrs),null,16,C)),[[e.vModelText,t.value]])}});n.CButton=i,n.CCheckbox=c,n.CInput=u,n.CLabel=_,n.CRadio=B,n.CSelect=$,n.CTextarea=k,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})}));
|
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
type __VLS_Props = {
|
|
2
2
|
for?: string;
|
|
3
3
|
};
|
|
4
|
-
declare function __VLS_template():
|
|
4
|
+
declare function __VLS_template(): {
|
|
5
|
+
attrs: Partial<{}>;
|
|
6
|
+
slots: {
|
|
7
|
+
default?(_: {}): any;
|
|
8
|
+
};
|
|
9
|
+
refs: {};
|
|
10
|
+
rootEl: any;
|
|
11
|
+
};
|
|
5
12
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
6
13
|
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
7
14
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|