@charpente-ui/vue 1.1.2 → 1.2.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.
- package/README.md +19 -3
- package/dist/charpente.js +93 -65
- package/dist/charpente.umd.cjs +1 -1
- package/dist/components/BaseButton.d.ts +2 -2
- package/dist/components/BaseCheckbox.d.ts +4 -1
- package/dist/components/BaseFile.d.ts +11 -0
- package/dist/components/BaseForm.d.ts +1 -1
- package/dist/components/BaseSelect.d.ts +3 -3
- package/dist/components/__tests__/BaseFile.spec.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -61,7 +61,7 @@ npm install @charpente-ui/vue
|
|
|
61
61
|
These components are thin wrappers around native elements. They use `v-model` and automatically link with labels via
|
|
62
62
|
`useId()`. Full attribute inheritance.
|
|
63
63
|
|
|
64
|
-
2. **Selection Logic** _(CCheckbox, CRadio)_
|
|
64
|
+
2. **Selection Logic** _(CCheckbox, CRadio, CSelect)_
|
|
65
65
|
|
|
66
66
|
Managing checkbox arrays in Vue can be repetitive. **Charpente UI** simplifies this:
|
|
67
67
|
|
|
@@ -70,6 +70,21 @@ Managing checkbox arrays in Vue can be repetitive. **Charpente UI** simplifies t
|
|
|
70
70
|
<CCheckbox v-model="tags" value="bar"/>
|
|
71
71
|
```
|
|
72
72
|
|
|
73
|
+
`CCheckbox` also supports the `indeterminate` state for partial selections:
|
|
74
|
+
|
|
75
|
+
```vue
|
|
76
|
+
<CCheckbox v-model="allSelected" :indeterminate="someSelected"/>
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
`CSelect` supports multiple selection via the native `multiple` attribute:
|
|
80
|
+
|
|
81
|
+
```vue
|
|
82
|
+
<CSelect v-model="selectedItems" multiple>
|
|
83
|
+
<option value="foo">Foo</option>
|
|
84
|
+
<option value="bar">Bar</option>
|
|
85
|
+
</CSelect>
|
|
86
|
+
```
|
|
87
|
+
|
|
73
88
|
3. **Polymorphic Elements** _(CButton)_
|
|
74
89
|
|
|
75
90
|
The button can change its HTML tag while keeping its behavior.
|
|
@@ -84,10 +99,11 @@ The button can change its HTML tag while keeping its behavior.
|
|
|
84
99
|
| Name | Core Logic | Tag | Status |
|
|
85
100
|
|----------|----------------------------------------------------------------------------------|-------------|--------|
|
|
86
101
|
| Button | **Polymorphic:** Switches tags _(a, button, etc...)_ while keeping logic. | `CButton` | Ready |
|
|
87
|
-
| Checkbox | **Smart Toggle:** Handles array state and
|
|
102
|
+
| Checkbox | **Smart Toggle:** Handles array state, booleans, and indeterminate natively. | `CCheckbox` | Ready |
|
|
103
|
+
| File | **File Input:** Reactive file selection with `v-model` support. | `CFile` | Ready |
|
|
88
104
|
| Form | **Auto-Submit:** Integrated `preventDefault` and event handling. | `CForm` | Ready |
|
|
89
105
|
| Input | **Auto-ID:** Auto-links to labels via `useId()` and full attributes inheritance. | `CInput` | Ready |
|
|
90
106
|
| Label | **Context-Aware:** Simple, accessible binding for any input. | `CLabel` | Ready |
|
|
91
107
|
| Radio | **Selection:** Minimalist wrapper for native radio input. | `CRadio` | Ready |
|
|
92
|
-
| Select | **Native Wrapper:**
|
|
108
|
+
| Select | **Native Wrapper:** Single and multiple selection support. | `CSelect` | Ready |
|
|
93
109
|
| Textarea | **Flexible Binding:** Auto-ID and reactive model management. | `CTextarea` | Ready |
|
package/dist/charpente.js
CHANGED
|
@@ -1,54 +1,81 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as u, openBlock as d, createBlock as B, resolveDynamicComponent as M, normalizeProps as g, guardReactiveProps as b, withCtx as A, renderSlot as h, useModel as _, useAttrs as c, useId as p, useTemplateRef as V, computed as f, watchEffect as k, withDirectives as $, createElementBlock as i, mergeProps as m, vModelCheckbox as x, mergeModels as C, watch as y, withModifiers as R, vModelDynamic as w, vModelRadio as S, vModelSelect as U, vModelText as F } from "vue";
|
|
2
|
+
const H = /* @__PURE__ */ u({
|
|
3
3
|
inheritAttrs: !1,
|
|
4
4
|
__name: "BaseButton",
|
|
5
5
|
props: {
|
|
6
6
|
as: { default: "button" }
|
|
7
7
|
},
|
|
8
8
|
setup(t) {
|
|
9
|
-
return (e,
|
|
10
|
-
default:
|
|
11
|
-
|
|
9
|
+
return (e, s) => (d(), B(M(t.as), g(b(e.$attrs)), {
|
|
10
|
+
default: A(() => [
|
|
11
|
+
h(e.$slots, "default")
|
|
12
12
|
]),
|
|
13
13
|
_: 3
|
|
14
14
|
}, 16));
|
|
15
15
|
}
|
|
16
|
-
}),
|
|
16
|
+
}), T = ["id", "value"], J = /* @__PURE__ */ u({
|
|
17
17
|
inheritAttrs: !1,
|
|
18
18
|
__name: "BaseCheckbox",
|
|
19
|
-
props: /* @__PURE__ */
|
|
20
|
-
value: {}
|
|
19
|
+
props: /* @__PURE__ */ C({
|
|
20
|
+
value: {},
|
|
21
|
+
indeterminate: { type: Boolean }
|
|
21
22
|
}, {
|
|
22
23
|
modelValue: { type: [Boolean, Array] },
|
|
23
24
|
modelModifiers: {}
|
|
24
25
|
}),
|
|
25
26
|
emits: ["update:modelValue"],
|
|
26
27
|
setup(t) {
|
|
27
|
-
const e =
|
|
28
|
-
return (
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
const e = t, s = _(t, "modelValue"), l = c(), r = p(), n = V("input"), a = f(() => l.id || r);
|
|
29
|
+
return k(() => {
|
|
30
|
+
n.value && (n.value.indeterminate = !!e.indeterminate);
|
|
31
|
+
}), (o, v) => $((d(), i("input", m({
|
|
32
|
+
ref: "input",
|
|
33
|
+
type: "checkbox"
|
|
34
|
+
}, o.$attrs, {
|
|
35
|
+
"onUpdate:modelValue": v[0] || (v[0] = (I) => s.value = I),
|
|
36
|
+
id: a.value,
|
|
31
37
|
value: t.value
|
|
32
|
-
}), null, 16,
|
|
33
|
-
[
|
|
38
|
+
}), null, 16, T)), [
|
|
39
|
+
[x, s.value]
|
|
34
40
|
]);
|
|
35
41
|
}
|
|
36
|
-
}),
|
|
42
|
+
}), D = ["id"], K = /* @__PURE__ */ u({
|
|
43
|
+
inheritAttrs: !1,
|
|
44
|
+
__name: "BaseFile",
|
|
45
|
+
props: {
|
|
46
|
+
modelValue: {},
|
|
47
|
+
modelModifiers: {}
|
|
48
|
+
},
|
|
49
|
+
emits: ["update:modelValue"],
|
|
50
|
+
setup(t) {
|
|
51
|
+
const e = _(t, "modelValue"), s = c(), l = p(), r = V("input"), n = f(() => s.id || l);
|
|
52
|
+
function a(o) {
|
|
53
|
+
e.value = o.target.files;
|
|
54
|
+
}
|
|
55
|
+
return y(e, (o) => {
|
|
56
|
+
!o && r.value && (r.value.value = "");
|
|
57
|
+
}), (o, v) => (d(), i("input", m({
|
|
58
|
+
type: "file",
|
|
59
|
+
ref: "input"
|
|
60
|
+
}, o.$attrs, {
|
|
61
|
+
id: n.value,
|
|
62
|
+
onChange: a
|
|
63
|
+
}), null, 16, D));
|
|
64
|
+
}
|
|
65
|
+
}), P = ["id"], N = /* @__PURE__ */ u({
|
|
37
66
|
inheritAttrs: !1,
|
|
38
67
|
__name: "BaseForm",
|
|
39
68
|
emits: ["submit"],
|
|
40
69
|
setup(t, { emit: e }) {
|
|
41
|
-
const
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
id: s.value,
|
|
46
|
-
onSubmit: A(n, ["prevent"])
|
|
70
|
+
const s = c(), l = p(), r = e, n = f(() => s.id || l);
|
|
71
|
+
return (a, o) => (d(), i("form", m(a.$attrs, {
|
|
72
|
+
id: n.value,
|
|
73
|
+
onSubmit: o[0] || (o[0] = R((v) => r("submit", v), ["prevent"]))
|
|
47
74
|
}), [
|
|
48
|
-
|
|
49
|
-
], 16,
|
|
75
|
+
h(a.$slots, "default")
|
|
76
|
+
], 16, P));
|
|
50
77
|
}
|
|
51
|
-
}),
|
|
78
|
+
}), E = ["id"], O = /* @__PURE__ */ u({
|
|
52
79
|
inheritAttrs: !1,
|
|
53
80
|
__name: "BaseInput",
|
|
54
81
|
props: {
|
|
@@ -57,15 +84,15 @@ const z = /* @__PURE__ */ d({
|
|
|
57
84
|
},
|
|
58
85
|
emits: ["update:modelValue"],
|
|
59
86
|
setup(t) {
|
|
60
|
-
const e =
|
|
61
|
-
return (n,
|
|
62
|
-
"onUpdate:modelValue":
|
|
63
|
-
id:
|
|
64
|
-
}), null, 16,
|
|
65
|
-
[
|
|
87
|
+
const e = _(t, "modelValue"), s = c(), l = p(), r = f(() => s.id || l);
|
|
88
|
+
return (n, a) => $((d(), i("input", m(n.$attrs, {
|
|
89
|
+
"onUpdate:modelValue": a[0] || (a[0] = (o) => e.value = o),
|
|
90
|
+
id: r.value
|
|
91
|
+
}), null, 16, E)), [
|
|
92
|
+
[w, e.value]
|
|
66
93
|
]);
|
|
67
94
|
}
|
|
68
|
-
}),
|
|
95
|
+
}), L = ["for"], Q = /* @__PURE__ */ u({
|
|
69
96
|
inheritAttrs: !1,
|
|
70
97
|
__name: "BaseLabel",
|
|
71
98
|
props: {
|
|
@@ -73,16 +100,16 @@ const z = /* @__PURE__ */ d({
|
|
|
73
100
|
},
|
|
74
101
|
setup(t) {
|
|
75
102
|
const e = t;
|
|
76
|
-
return (
|
|
103
|
+
return (s, l) => (d(), i("label", m(s.$attrs, {
|
|
77
104
|
for: e.for
|
|
78
105
|
}), [
|
|
79
|
-
|
|
80
|
-
], 16,
|
|
106
|
+
h(s.$slots, "default")
|
|
107
|
+
], 16, L));
|
|
81
108
|
}
|
|
82
|
-
}),
|
|
109
|
+
}), z = ["id", "value"], W = /* @__PURE__ */ u({
|
|
83
110
|
inheritAttrs: !1,
|
|
84
111
|
__name: "BaseRadio",
|
|
85
|
-
props: /* @__PURE__ */
|
|
112
|
+
props: /* @__PURE__ */ C({
|
|
86
113
|
value: {}
|
|
87
114
|
}, {
|
|
88
115
|
modelValue: {},
|
|
@@ -90,16 +117,16 @@ const z = /* @__PURE__ */ d({
|
|
|
90
117
|
}),
|
|
91
118
|
emits: ["update:modelValue"],
|
|
92
119
|
setup(t) {
|
|
93
|
-
const e =
|
|
94
|
-
return (n,
|
|
95
|
-
"onUpdate:modelValue":
|
|
96
|
-
id:
|
|
120
|
+
const e = _(t, "modelValue"), s = c(), l = p(), r = f(() => s.id || l);
|
|
121
|
+
return (n, a) => $((d(), i("input", m({ type: "radio" }, n.$attrs, {
|
|
122
|
+
"onUpdate:modelValue": a[0] || (a[0] = (o) => e.value = o),
|
|
123
|
+
id: r.value,
|
|
97
124
|
value: t.value
|
|
98
|
-
}), null, 16,
|
|
99
|
-
[
|
|
125
|
+
}), null, 16, z)), [
|
|
126
|
+
[S, e.value]
|
|
100
127
|
]);
|
|
101
128
|
}
|
|
102
|
-
}),
|
|
129
|
+
}), j = ["id"], X = /* @__PURE__ */ u({
|
|
103
130
|
inheritAttrs: !1,
|
|
104
131
|
__name: "BaseSelect",
|
|
105
132
|
props: {
|
|
@@ -108,17 +135,17 @@ const z = /* @__PURE__ */ d({
|
|
|
108
135
|
},
|
|
109
136
|
emits: ["update:modelValue"],
|
|
110
137
|
setup(t) {
|
|
111
|
-
const e =
|
|
112
|
-
return (n,
|
|
113
|
-
"onUpdate:modelValue":
|
|
114
|
-
id:
|
|
138
|
+
const e = _(t, "modelValue"), s = c(), l = p(), r = f(() => s.id || l);
|
|
139
|
+
return (n, a) => $((d(), i("select", m(n.$attrs, {
|
|
140
|
+
"onUpdate:modelValue": a[0] || (a[0] = (o) => e.value = o),
|
|
141
|
+
id: r.value
|
|
115
142
|
}), [
|
|
116
|
-
|
|
117
|
-
], 16,
|
|
118
|
-
[
|
|
143
|
+
h(n.$slots, "default")
|
|
144
|
+
], 16, j)), [
|
|
145
|
+
[U, e.value]
|
|
119
146
|
]);
|
|
120
147
|
}
|
|
121
|
-
}),
|
|
148
|
+
}), q = ["id"], Y = /* @__PURE__ */ u({
|
|
122
149
|
inheritAttrs: !1,
|
|
123
150
|
__name: "BaseTextarea",
|
|
124
151
|
props: {
|
|
@@ -127,22 +154,23 @@ const z = /* @__PURE__ */ d({
|
|
|
127
154
|
},
|
|
128
155
|
emits: ["update:modelValue"],
|
|
129
156
|
setup(t) {
|
|
130
|
-
const e =
|
|
131
|
-
return (n,
|
|
132
|
-
"onUpdate:modelValue":
|
|
133
|
-
id:
|
|
134
|
-
}), null, 16,
|
|
135
|
-
[
|
|
157
|
+
const e = _(t, "modelValue"), s = c(), l = p(), r = f(() => s.id || l);
|
|
158
|
+
return (n, a) => $((d(), i("textarea", m(n.$attrs, {
|
|
159
|
+
"onUpdate:modelValue": a[0] || (a[0] = (o) => e.value = o),
|
|
160
|
+
id: r.value
|
|
161
|
+
}), null, 16, q)), [
|
|
162
|
+
[F, e.value]
|
|
136
163
|
]);
|
|
137
164
|
}
|
|
138
165
|
});
|
|
139
166
|
export {
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
167
|
+
H as CButton,
|
|
168
|
+
J as CCheckbox,
|
|
169
|
+
K as CFile,
|
|
170
|
+
N as CForm,
|
|
171
|
+
O as CInput,
|
|
172
|
+
Q as CLabel,
|
|
173
|
+
W as CRadio,
|
|
174
|
+
X as CSelect,
|
|
175
|
+
Y as CTextarea
|
|
148
176
|
};
|
package/dist/charpente.umd.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(r,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(r=typeof globalThis<"u"?globalThis:r||self,e(r.Charpente={},r.Vue))})(this,(function(r,e){"use strict";const
|
|
1
|
+
(function(r,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(r=typeof globalThis<"u"?globalThis:r||self,e(r.Charpente={},r.Vue))})(this,(function(r,e){"use strict";const c=e.defineComponent({inheritAttrs:!1,__name:"BaseButton",props:{as:{default:"button"}},setup(o){return(t,n)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.as),e.normalizeProps(e.guardReactiveProps(t.$attrs)),{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3},16))}}),p=["id","value"],u=e.defineComponent({inheritAttrs:!1,__name:"BaseCheckbox",props:e.mergeModels({value:{},indeterminate:{type:Boolean}},{modelValue:{type:[Boolean,Array]},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const t=o,n=e.useModel(o,"modelValue"),d=e.useAttrs(),i=e.useId(),a=e.useTemplateRef("input"),s=e.computed(()=>d.id||i);return e.watchEffect(()=>{a.value&&(a.value.indeterminate=!!t.indeterminate)}),(l,m)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({ref:"input",type:"checkbox"},l.$attrs,{"onUpdate:modelValue":m[0]||(m[0]=P=>n.value=P),id:s.value,value:o.value}),null,16,p)),[[e.vModelCheckbox,n.value]])}}),f=["id"],_=e.defineComponent({inheritAttrs:!1,__name:"BaseFile",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),n=e.useAttrs(),d=e.useId(),i=e.useTemplateRef("input"),a=e.computed(()=>n.id||d);function s(l){t.value=l.target.files}return e.watch(t,l=>{!l&&i.value&&(i.value.value="")}),(l,m)=>(e.openBlock(),e.createElementBlock("input",e.mergeProps({type:"file",ref:"input"},l.$attrs,{id:a.value,onChange:s}),null,16,f))}}),h=["id"],B=e.defineComponent({inheritAttrs:!1,__name:"BaseForm",emits:["submit"],setup(o,{emit:t}){const n=e.useAttrs(),d=e.useId(),i=t,a=e.computed(()=>n.id||d);return(s,l)=>(e.openBlock(),e.createElementBlock("form",e.mergeProps(s.$attrs,{id:a.value,onSubmit:l[0]||(l[0]=e.withModifiers(m=>i("submit",m),["prevent"]))}),[e.renderSlot(s.$slots,"default")],16,h))}}),$=["id"],C=e.defineComponent({inheritAttrs:!1,__name:"BaseInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),n=e.useAttrs(),d=e.useId(),i=e.computed(()=>n.id||d);return(a,s)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps(a.$attrs,{"onUpdate:modelValue":s[0]||(s[0]=l=>t.value=l),id:i.value}),null,16,$)),[[e.vModelDynamic,t.value]])}}),V=["for"],k=e.defineComponent({inheritAttrs:!1,__name:"BaseLabel",props:{for:{}},setup(o){const t=o;return(n,d)=>(e.openBlock(),e.createElementBlock("label",e.mergeProps(n.$attrs,{for:t.for}),[e.renderSlot(n.$slots,"default")],16,V))}}),I=["id","value"],g=e.defineComponent({inheritAttrs:!1,__name:"BaseRadio",props:e.mergeModels({value:{}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),n=e.useAttrs(),d=e.useId(),i=e.computed(()=>n.id||d);return(a,s)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({type:"radio"},a.$attrs,{"onUpdate:modelValue":s[0]||(s[0]=l=>t.value=l),id:i.value,value:o.value}),null,16,I)),[[e.vModelRadio,t.value]])}}),M=["id"],A=e.defineComponent({inheritAttrs:!1,__name:"BaseSelect",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),n=e.useAttrs(),d=e.useId(),i=e.computed(()=>n.id||d);return(a,s)=>e.withDirectives((e.openBlock(),e.createElementBlock("select",e.mergeProps(a.$attrs,{"onUpdate:modelValue":s[0]||(s[0]=l=>t.value=l),id:i.value}),[e.renderSlot(a.$slots,"default")],16,M)),[[e.vModelSelect,t.value]])}}),b=["id"],y=e.defineComponent({inheritAttrs:!1,__name:"BaseTextarea",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(o){const t=e.useModel(o,"modelValue"),n=e.useAttrs(),d=e.useId(),i=e.computed(()=>n.id||d);return(a,s)=>e.withDirectives((e.openBlock(),e.createElementBlock("textarea",e.mergeProps(a.$attrs,{"onUpdate:modelValue":s[0]||(s[0]=l=>t.value=l),id:i.value}),null,16,b)),[[e.vModelText,t.value]])}});r.CButton=c,r.CCheckbox=u,r.CFile=_,r.CForm=B,r.CInput=C,r.CLabel=k,r.CRadio=g,r.CSelect=A,r.CTextarea=y,Object.defineProperty(r,Symbol.toStringTag,{value:"Module"})}));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Component } from 'vue';
|
|
2
2
|
type __VLS_Props = {
|
|
3
|
-
as?: Component;
|
|
3
|
+
as?: Component | string;
|
|
4
4
|
};
|
|
5
5
|
declare function __VLS_template(): {
|
|
6
6
|
attrs: Partial<{}>;
|
|
@@ -12,7 +12,7 @@ declare function __VLS_template(): {
|
|
|
12
12
|
};
|
|
13
13
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
14
|
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
15
|
-
as: Component;
|
|
15
|
+
as: Component | string;
|
|
16
16
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
17
17
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
18
18
|
export default _default;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
type __VLS_Props = {
|
|
2
2
|
value?: string | number;
|
|
3
|
+
indeterminate?: boolean;
|
|
3
4
|
};
|
|
4
5
|
type __VLS_PublicProps = {
|
|
5
6
|
modelValue?: boolean | (string | number)[];
|
|
@@ -8,5 +9,7 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {}, {},
|
|
|
8
9
|
"update:modelValue": (value: boolean | (string | number)[]) => any;
|
|
9
10
|
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
10
11
|
"onUpdate:modelValue"?: ((value: boolean | (string | number)[]) => any) | undefined;
|
|
11
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
12
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
13
|
+
input: HTMLInputElement;
|
|
14
|
+
}, any>;
|
|
12
15
|
export default _default;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type __VLS_PublicProps = {
|
|
2
|
+
modelValue?: FileList | null;
|
|
3
|
+
};
|
|
4
|
+
declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
5
|
+
"update:modelValue": (value: FileList | null) => any;
|
|
6
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
7
|
+
"onUpdate:modelValue"?: ((value: FileList | null) => any) | undefined;
|
|
8
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
9
|
+
input: HTMLInputElement;
|
|
10
|
+
}, any>;
|
|
11
|
+
export default _default;
|
|
@@ -7,7 +7,7 @@ declare function __VLS_template(): {
|
|
|
7
7
|
rootEl: any;
|
|
8
8
|
};
|
|
9
9
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
10
|
-
declare const __VLS_component: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
10
|
+
declare const __VLS_component: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
11
11
|
submit: (event: Event) => any;
|
|
12
12
|
}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
|
|
13
13
|
onSubmit?: ((event: Event) => any) | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
type __VLS_PublicProps = {
|
|
2
|
-
modelValue?: string | number;
|
|
2
|
+
modelValue?: string | number | (string | number)[];
|
|
3
3
|
};
|
|
4
4
|
declare function __VLS_template(): {
|
|
5
5
|
attrs: Partial<{}>;
|
|
@@ -11,9 +11,9 @@ declare function __VLS_template(): {
|
|
|
11
11
|
};
|
|
12
12
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
13
13
|
declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
14
|
-
"update:modelValue": (value: string | number) => any;
|
|
14
|
+
"update:modelValue": (value: string | number | (string | number)[]) => any;
|
|
15
15
|
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
16
|
-
"onUpdate:modelValue"?: ((value: string | number) => any) | undefined;
|
|
16
|
+
"onUpdate:modelValue"?: ((value: string | number | (string | number)[]) => any) | undefined;
|
|
17
17
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
18
18
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
19
19
|
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { default as CButton } from './components/BaseButton';
|
|
2
2
|
export { default as CCheckbox } from './components/BaseCheckbox';
|
|
3
|
+
export { default as CFile } from './components/BaseFile';
|
|
3
4
|
export { default as CForm } from './components/BaseForm';
|
|
4
5
|
export { default as CInput } from './components/BaseInput';
|
|
5
6
|
export { default as CLabel } from './components/BaseLabel';
|