@silver-formily/element-plus 2.2.0 → 2.3.0
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.en-US.md +32 -32
- package/README.md +32 -32
- package/esm/__builtins__/index.mjs +19 -23
- package/esm/__builtins__/index.mjs.map +1 -1
- package/esm/__builtins__/shared/index.d.ts +0 -1
- package/esm/__builtins__/shared/index.mjs +17 -21
- package/esm/__builtins__/shared/index.mjs.map +1 -1
- package/esm/__builtins__/shared/loading.mjs +5 -5
- package/esm/__builtins__/shared/loading.mjs.map +1 -1
- package/esm/__builtins__/shared/use-enter-submit.d.ts +9 -0
- package/esm/__builtins__/shared/use-enter-submit.mjs +25 -0
- package/esm/__builtins__/shared/use-enter-submit.mjs.map +1 -0
- package/esm/autocomplete/autocomplete.d.ts +1222 -0
- package/esm/autocomplete/index.d.ts +639 -0
- package/esm/autocomplete/index.mjs +110 -0
- package/esm/autocomplete/index.mjs.map +1 -0
- package/esm/checkbox/index.d.ts +42 -42
- package/esm/color-picker/index.d.ts +210 -0
- package/esm/color-picker/index.mjs +14 -0
- package/esm/color-picker/index.mjs.map +1 -0
- package/esm/color-picker-panel/index.d.ts +129 -0
- package/esm/color-picker-panel/index.mjs +22 -0
- package/esm/color-picker-panel/index.mjs.map +1 -0
- package/esm/date-picker/index.mjs +12 -34
- package/esm/date-picker/index.mjs.map +1 -1
- package/esm/date-picker/utils.d.ts +4 -0
- package/esm/date-picker/utils.mjs +27 -0
- package/esm/date-picker/utils.mjs.map +1 -0
- package/esm/date-picker-panel/index.d.ts +143 -0
- package/esm/date-picker-panel/index.mjs +27 -0
- package/esm/date-picker-panel/index.mjs.map +1 -0
- package/esm/env.d.mjs +2 -0
- package/esm/env.d.mjs.map +1 -0
- package/esm/form-button-group/form-button-group.d.ts +1 -1
- package/esm/form-button-group/index.d.ts +3 -3
- package/esm/form-dialog/dialog-content.d.ts +789 -3
- package/esm/form-dialog/index.mjs +98 -87
- package/esm/form-dialog/index.mjs.map +1 -1
- package/esm/form-dialog/types.d.ts +1 -0
- package/esm/form-drawer/drawer-content.d.ts +919 -3
- package/esm/form-drawer/index.mjs +91 -81
- package/esm/form-drawer/index.mjs.map +1 -1
- package/esm/form-drawer/types.d.ts +1 -0
- package/esm/form-item/index.mjs +17 -17
- package/esm/form-item/index.mjs.map +1 -1
- package/esm/form-layout/form-layout.mjs +10 -10
- package/esm/form-layout/form-layout.mjs.map +1 -1
- package/esm/form-layout/utils.mjs +1 -1
- package/esm/form-layout/utils.mjs.map +1 -1
- package/esm/index.d.ts +6 -0
- package/esm/index.mjs +90 -78
- package/esm/index.mjs.map +1 -1
- package/esm/input-number/index.d.ts +21 -21
- package/esm/input-tag/index.d.ts +32 -0
- package/esm/input-tag/index.mjs +46 -0
- package/esm/input-tag/index.mjs.map +1 -0
- package/esm/input-tag/input-tag.d.ts +32 -0
- package/esm/mention/index.d.ts +50 -0
- package/esm/mention/index.mjs +93 -0
- package/esm/mention/index.mjs.map +1 -0
- package/esm/mention/mention.d.ts +51 -0
- package/esm/pagination/pagination.mjs.map +1 -1
- package/esm/preview-text/color-picker.d.ts +5 -0
- package/esm/preview-text/index.d.ts +5 -0
- package/esm/preview-text/index.mjs +180 -145
- package/esm/preview-text/index.mjs.map +1 -1
- package/esm/radio/index.d.ts +36 -36
- package/esm/rate/index.mjs.map +1 -1
- package/esm/segmented/index.mjs.map +1 -1
- package/esm/shared/overlay-elements.d.ts +6 -0
- package/esm/shared/overlay-elements.mjs +16 -0
- package/esm/shared/overlay-elements.mjs.map +1 -0
- package/esm/slider/index.mjs.map +1 -1
- package/esm/styles/preview-text/index.css +1 -1
- package/esm/switch/index.d.ts +12 -12
- package/esm/upload/index.d.ts +1 -1
- package/esm/upload/upload.d.ts +2 -2
- package/package.json +3 -1
- package/esm/__builtins__/shared/hooks.d.ts +0 -7
- package/esm/__builtins__/shared/hooks.mjs +0 -59
- package/esm/__builtins__/shared/hooks.mjs.map +0 -1
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { useField as S, connect as $, mapProps as P } from "@silver-formily/vue";
|
|
2
|
+
import { PreviewText as A } from "../preview-text/index.mjs";
|
|
3
|
+
import { defineComponent as R, useSlots as w, ref as C, computed as d, createBlock as F, openBlock as x, unref as u, mergeProps as z, createSlots as B, withCtx as n, renderSlot as r, normalizeProps as E, guardReactiveProps as K } from "vue";
|
|
4
|
+
import { ElAutocomplete as L } from "element-plus";
|
|
5
|
+
import { useCleanAttrs as O } from "../__builtins__/shared/utils.mjs";
|
|
6
|
+
import { mapReadPretty as b } from "../__builtins__/shared/transform-component.mjs";
|
|
7
|
+
const j = /* @__PURE__ */ R({
|
|
8
|
+
name: "FAutocomplete",
|
|
9
|
+
inheritAttrs: !1,
|
|
10
|
+
__name: "autocomplete",
|
|
11
|
+
props: {
|
|
12
|
+
options: {}
|
|
13
|
+
},
|
|
14
|
+
setup(m) {
|
|
15
|
+
const f = m, o = w(), { props: i } = O(), t = S(), p = C();
|
|
16
|
+
t.value?.inject({
|
|
17
|
+
getElAutocompleteRef: () => p
|
|
18
|
+
});
|
|
19
|
+
const c = d(() => {
|
|
20
|
+
const e = i.value.fetchSuggestions;
|
|
21
|
+
if (e)
|
|
22
|
+
return ((a, s) => e(a, s, t.value));
|
|
23
|
+
if (f.options)
|
|
24
|
+
return (a, s) => {
|
|
25
|
+
t.value.loading = !0;
|
|
26
|
+
const l = (a ?? "").toLowerCase(), y = i.value.valueKey ?? "value", k = l ? f.options.filter((h) => v(h, y, l)) : f.options;
|
|
27
|
+
s(k), t.value.loading = !1;
|
|
28
|
+
};
|
|
29
|
+
});
|
|
30
|
+
function v(e, a, s) {
|
|
31
|
+
const l = e?.[a];
|
|
32
|
+
return l == null ? !1 : String(l).toLowerCase().includes(s);
|
|
33
|
+
}
|
|
34
|
+
const g = d(() => ({
|
|
35
|
+
...i.value,
|
|
36
|
+
loading: i.value.loading ?? t.value?.loading,
|
|
37
|
+
fetchSuggestions: c.value
|
|
38
|
+
}));
|
|
39
|
+
return (e, a) => (x(), F(u(L), z({
|
|
40
|
+
ref_key: "autocompleteRef",
|
|
41
|
+
ref: p
|
|
42
|
+
}, g.value), B({ _: 2 }, [
|
|
43
|
+
o.default ? {
|
|
44
|
+
name: "default",
|
|
45
|
+
fn: n((s) => [
|
|
46
|
+
r(e.$slots, "default", E(K({ ...s, field: u(t) })))
|
|
47
|
+
]),
|
|
48
|
+
key: "0"
|
|
49
|
+
} : void 0,
|
|
50
|
+
o.header ? {
|
|
51
|
+
name: "header",
|
|
52
|
+
fn: n(() => [
|
|
53
|
+
r(e.$slots, "header", { field: u(t) })
|
|
54
|
+
]),
|
|
55
|
+
key: "1"
|
|
56
|
+
} : void 0,
|
|
57
|
+
o.footer ? {
|
|
58
|
+
name: "footer",
|
|
59
|
+
fn: n(() => [
|
|
60
|
+
r(e.$slots, "footer", { field: u(t) })
|
|
61
|
+
]),
|
|
62
|
+
key: "2"
|
|
63
|
+
} : void 0,
|
|
64
|
+
o.prefix ? {
|
|
65
|
+
name: "prefix",
|
|
66
|
+
fn: n(() => [
|
|
67
|
+
r(e.$slots, "prefix")
|
|
68
|
+
]),
|
|
69
|
+
key: "3"
|
|
70
|
+
} : void 0,
|
|
71
|
+
o.suffix ? {
|
|
72
|
+
name: "suffix",
|
|
73
|
+
fn: n(() => [
|
|
74
|
+
r(e.$slots, "suffix")
|
|
75
|
+
]),
|
|
76
|
+
key: "4"
|
|
77
|
+
} : void 0,
|
|
78
|
+
o.prepend ? {
|
|
79
|
+
name: "prepend",
|
|
80
|
+
fn: n(() => [
|
|
81
|
+
r(e.$slots, "prepend")
|
|
82
|
+
]),
|
|
83
|
+
key: "5"
|
|
84
|
+
} : void 0,
|
|
85
|
+
o.append ? {
|
|
86
|
+
name: "append",
|
|
87
|
+
fn: n(() => [
|
|
88
|
+
r(e.$slots, "append")
|
|
89
|
+
]),
|
|
90
|
+
key: "6"
|
|
91
|
+
} : void 0,
|
|
92
|
+
o.loading ? {
|
|
93
|
+
name: "loading",
|
|
94
|
+
fn: n(() => [
|
|
95
|
+
r(e.$slots, "loading")
|
|
96
|
+
]),
|
|
97
|
+
key: "7"
|
|
98
|
+
} : void 0
|
|
99
|
+
]), 1040));
|
|
100
|
+
}
|
|
101
|
+
}), J = $(
|
|
102
|
+
j,
|
|
103
|
+
P({ dataSource: "options", readOnly: "readonly", disabled: !0 }),
|
|
104
|
+
b(A.Input)
|
|
105
|
+
);
|
|
106
|
+
export {
|
|
107
|
+
J as Autocomplete,
|
|
108
|
+
J as default
|
|
109
|
+
};
|
|
110
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../src/autocomplete/autocomplete.vue","../../src/autocomplete/index.ts"],"sourcesContent":["<script setup lang=\"ts\">\r\nimport type { Field } from '@formily/core'\r\nimport type { AutocompleteInstance } from 'element-plus'\r\nimport type { AutocompleteData, AutocompleteFetchSuggestions } from 'element-plus/es/components/autocomplete'\r\nimport { useField } from '@silver-formily/vue'\r\nimport { ElAutocomplete } from 'element-plus'\r\nimport { computed, ref } from 'vue'\r\nimport { useCleanAttrs } from '../__builtins__'\r\n\r\ndefineOptions({\r\n name: 'FAutocomplete',\r\n inheritAttrs: false,\r\n})\r\n\r\nconst props = defineProps<{\r\n options?: AutocompleteData\r\n}>()\r\n\r\nconst slots = defineSlots<{\r\n default?: (scope: { item: AutocompleteData[number], field: Field | undefined }) => any\r\n header?: (scope: { field: Field | undefined }) => any\r\n footer?: (scope: { field: Field | undefined }) => any\r\n loading?: () => any\r\n prefix?: () => any\r\n suffix?: () => any\r\n prepend?: () => any\r\n append?: () => any\r\n}>()\r\n\r\nconst { props: attrs } = useCleanAttrs()\r\nconst fieldRef = useField<Field>()\r\nconst autocompleteRef = ref<AutocompleteInstance>()\r\n\r\nfieldRef.value?.inject({\r\n getElAutocompleteRef: () => autocompleteRef,\r\n})\r\n\r\nconst normalizedFetchSuggestions = computed<AutocompleteFetchSuggestions | undefined>(() => {\r\n const attrFetch = attrs.value.fetchSuggestions as AutocompleteFetchSuggestions | undefined\r\n if (attrFetch) {\r\n return ((queryString, cb) => {\r\n return (attrFetch as (...args: any[]) => any)(queryString, cb, fieldRef.value)\r\n }) as AutocompleteFetchSuggestions\r\n }\r\n\r\n if (!props.options) {\r\n return\r\n }\r\n\r\n return (queryString: string, cb) => {\r\n fieldRef.value.loading = true\r\n const keyword = (queryString ?? '').toLowerCase()\r\n const valueKey = (attrs.value.valueKey ?? 'value') as string\r\n const results = keyword\r\n ? props.options!.filter(option => matchOption(option, valueKey, keyword))\r\n : props.options!\r\n cb(results)\r\n fieldRef.value.loading = false\r\n }\r\n})\r\n\r\nfunction matchOption(option: AutocompleteData[number], valueKey: string, keyword: string) {\r\n const target = option?.[valueKey]\r\n if (target === undefined || target === null) {\r\n return false\r\n }\r\n return String(target).toLowerCase().includes(keyword)\r\n}\r\n\r\nconst autocompleteProps = computed(() => ({\r\n ...attrs.value,\r\n loading: attrs.value.loading ?? fieldRef.value?.loading,\r\n fetchSuggestions: normalizedFetchSuggestions.value,\r\n}))\r\n</script>\r\n\r\n<template>\r\n <ElAutocomplete ref=\"autocompleteRef\" v-bind=\"autocompleteProps\">\r\n <template v-if=\"slots.default\" #default=\"slotProps\">\r\n <slot name=\"default\" v-bind=\"{ ...slotProps, field: fieldRef }\" />\r\n </template>\r\n <template v-if=\"slots.header\" #header>\r\n <slot name=\"header\" :field=\"fieldRef\" />\r\n </template>\r\n <template v-if=\"slots.footer\" #footer>\r\n <slot name=\"footer\" :field=\"fieldRef\" />\r\n </template>\r\n <template v-if=\"slots.prefix\" #prefix>\r\n <slot name=\"prefix\" />\r\n </template>\r\n <template v-if=\"slots.suffix\" #suffix>\r\n <slot name=\"suffix\" />\r\n </template>\r\n <template v-if=\"slots.prepend\" #prepend>\r\n <slot name=\"prepend\" />\r\n </template>\r\n <template v-if=\"slots.append\" #append>\r\n <slot name=\"append\" />\r\n </template>\r\n <template v-if=\"slots.loading\" #loading>\r\n <slot name=\"loading\" />\r\n </template>\r\n </ElAutocomplete>\r\n</template>\r\n","import { connect, mapProps } from '@silver-formily/vue'\r\nimport { mapReadPretty } from '../__builtins__'\r\nimport { PreviewText } from '../preview-text'\r\nimport FAutocomplete from './autocomplete.vue'\r\n\r\nexport const Autocomplete = connect<typeof FAutocomplete>(\r\n FAutocomplete,\r\n mapProps({ dataSource: 'options', readOnly: 'readonly', disabled: true }),\r\n mapReadPretty(PreviewText.Input),\r\n)\r\n\r\nexport default Autocomplete\r\n"],"names":["props","__props","slots","_useSlots","attrs","useCleanAttrs","fieldRef","useField","autocompleteRef","ref","normalizedFetchSuggestions","computed","attrFetch","queryString","cb","keyword","valueKey","results","option","matchOption","target","autocompleteProps","_openBlock","_createBlock","_unref","_mergeProps","_createSlots","_withCtx","slotProps","_renderSlot","_ctx","_normalizeProps","_guardReactiveProps","Autocomplete","connect","FAutocomplete","mapProps","mapReadPretty","PreviewText"],"mappings":";;;;;;;;;;;;;;AAcA,UAAMA,IAAQC,GAIRC,IAAQC,EAAA,GAWR,EAAE,OAAOC,EAAA,IAAUC,EAAA,GACnBC,IAAWC,EAAA,GACXC,IAAkBC,EAAA;AAExB,IAAAH,EAAS,OAAO,OAAO;AAAA,MACrB,sBAAsB,MAAME;AAAA,IAAA,CAC7B;AAED,UAAME,IAA6BC,EAAmD,MAAM;AAC1F,YAAMC,IAAYR,EAAM,MAAM;AAC9B,UAAIQ;AACF,gBAAQ,CAACC,GAAaC,MACZF,EAAsCC,GAAaC,GAAIR,EAAS,KAAK;AAIjF,UAAKN,EAAM;AAIX,eAAO,CAACa,GAAqBC,MAAO;AAClC,UAAAR,EAAS,MAAM,UAAU;AACzB,gBAAMS,KAAWF,KAAe,IAAI,YAAA,GAC9BG,IAAYZ,EAAM,MAAM,YAAY,SACpCa,IAAUF,IACZf,EAAM,QAAS,OAAO,CAAAkB,MAAUC,EAAYD,GAAQF,GAAUD,CAAO,CAAC,IACtEf,EAAM;AACV,UAAAc,EAAGG,CAAO,GACVX,EAAS,MAAM,UAAU;AAAA,QAC3B;AAAA,IACF,CAAC;AAED,aAASa,EAAYD,GAAkCF,GAAkBD,GAAiB;AACxF,YAAMK,IAASF,IAASF,CAAQ;AAChC,aAA4BI,KAAW,OAC9B,KAEF,OAAOA,CAAM,EAAE,YAAA,EAAc,SAASL,CAAO;AAAA,IACtD;AAEA,UAAMM,IAAoBV,EAAS,OAAO;AAAA,MACxC,GAAGP,EAAM;AAAA,MACT,SAASA,EAAM,MAAM,WAAWE,EAAS,OAAO;AAAA,MAChD,kBAAkBI,EAA2B;AAAA,IAAA,EAC7C;sBAIAY,KAAAC,EAyBiBC,MAzBjBC,EAyBiB;AAAA,eAzBG;AAAA,MAAJ,KAAIjB;AAAA,IAAA,GAA0Ba,EAAA,KAAiB,GAAAK,EAAA,EAAA,GAAA,KAAA;AAAA,MAC7CxB,EAAM;cAAU;AAAA,QAC9B,IAAAyB,EAAA,CADuCC,MAAS;AAAA,UAChDC,EAAkEC,EAAA,QAAA,WAAAC,EAAAC,EAAA,EAAA,GAAhCJ,GAAS,OAASJ,EAAAlB,CAAA,EAAA,CAAQ,CAAA,CAAA;AAAA,QAAA;;;MAE9CJ,EAAM;cAAS;AAAA,cAC7B,MAAwC;AAAA,UAAxC2B,EAAwCC,EAAA,QAAA,UAAA,EAAnB,OAAON,EAAAlB,CAAA,EAAA,CAAQ;AAAA,QAAA;;;MAEtBJ,EAAM;cAAS;AAAA,cAC7B,MAAwC;AAAA,UAAxC2B,EAAwCC,EAAA,QAAA,UAAA,EAAnB,OAAON,EAAAlB,CAAA,EAAA,CAAQ;AAAA,QAAA;;;MAEtBJ,EAAM;cAAS;AAAA,cAC7B,MAAsB;AAAA,UAAtB2B,EAAsBC,EAAA,QAAA,QAAA;AAAA,QAAA;;;MAER5B,EAAM;cAAS;AAAA,cAC7B,MAAsB;AAAA,UAAtB2B,EAAsBC,EAAA,QAAA,QAAA;AAAA,QAAA;;;MAER5B,EAAM;cAAU;AAAA,cAC9B,MAAuB;AAAA,UAAvB2B,EAAuBC,EAAA,QAAA,SAAA;AAAA,QAAA;;;MAET5B,EAAM;cAAS;AAAA,cAC7B,MAAsB;AAAA,UAAtB2B,EAAsBC,EAAA,QAAA,QAAA;AAAA,QAAA;;;MAER5B,EAAM;cAAU;AAAA,cAC9B,MAAuB;AAAA,UAAvB2B,EAAuBC,EAAA,QAAA,SAAA;AAAA,QAAA;;;;;IC/FhBG,IAAeC;AAAA,EAC1BC;AAAAA,EACAC,EAAS,EAAE,YAAY,WAAW,UAAU,YAAY,UAAU,IAAM;AAAA,EACxEC,EAAcC,EAAY,KAAK;AACjC;"}
|
package/esm/checkbox/index.d.ts
CHANGED
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
export declare const Checkbox: {
|
|
2
2
|
new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('vue').ExtractPropTypes<{
|
|
3
|
-
value: {
|
|
4
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
5
|
-
default: undefined;
|
|
6
|
-
};
|
|
7
3
|
size: {
|
|
8
4
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
9
5
|
};
|
|
@@ -11,10 +7,17 @@ export declare const Checkbox: {
|
|
|
11
7
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
12
8
|
default: undefined;
|
|
13
9
|
};
|
|
10
|
+
border: {
|
|
11
|
+
type: import('vue').PropType<boolean>;
|
|
12
|
+
};
|
|
14
13
|
name: {
|
|
15
14
|
type: import('vue').PropType<string>;
|
|
16
15
|
default: undefined;
|
|
17
16
|
};
|
|
17
|
+
value: {
|
|
18
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
19
|
+
default: undefined;
|
|
20
|
+
};
|
|
18
21
|
disabled: {
|
|
19
22
|
type: import('vue').PropType<boolean>;
|
|
20
23
|
default: undefined;
|
|
@@ -37,9 +40,6 @@ export declare const Checkbox: {
|
|
|
37
40
|
type: import('vue').PropType<boolean>;
|
|
38
41
|
default: true;
|
|
39
42
|
};
|
|
40
|
-
border: {
|
|
41
|
-
type: import('vue').PropType<boolean>;
|
|
42
|
-
};
|
|
43
43
|
ariaControls: {
|
|
44
44
|
type: import('vue').PropType<string>;
|
|
45
45
|
};
|
|
@@ -91,10 +91,6 @@ export declare const Checkbox: {
|
|
|
91
91
|
M: {};
|
|
92
92
|
Defaults: {};
|
|
93
93
|
}, Readonly<import('vue').ExtractPropTypes<{
|
|
94
|
-
value: {
|
|
95
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
96
|
-
default: undefined;
|
|
97
|
-
};
|
|
98
94
|
size: {
|
|
99
95
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
100
96
|
};
|
|
@@ -102,10 +98,17 @@ export declare const Checkbox: {
|
|
|
102
98
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
103
99
|
default: undefined;
|
|
104
100
|
};
|
|
101
|
+
border: {
|
|
102
|
+
type: import('vue').PropType<boolean>;
|
|
103
|
+
};
|
|
105
104
|
name: {
|
|
106
105
|
type: import('vue').PropType<string>;
|
|
107
106
|
default: undefined;
|
|
108
107
|
};
|
|
108
|
+
value: {
|
|
109
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
110
|
+
default: undefined;
|
|
111
|
+
};
|
|
109
112
|
disabled: {
|
|
110
113
|
type: import('vue').PropType<boolean>;
|
|
111
114
|
default: undefined;
|
|
@@ -128,9 +131,6 @@ export declare const Checkbox: {
|
|
|
128
131
|
type: import('vue').PropType<boolean>;
|
|
129
132
|
default: true;
|
|
130
133
|
};
|
|
131
|
-
border: {
|
|
132
|
-
type: import('vue').PropType<boolean>;
|
|
133
|
-
};
|
|
134
134
|
ariaControls: {
|
|
135
135
|
type: import('vue').PropType<string>;
|
|
136
136
|
};
|
|
@@ -176,10 +176,6 @@ export declare const Checkbox: {
|
|
|
176
176
|
__isTeleport?: never;
|
|
177
177
|
__isSuspense?: never;
|
|
178
178
|
} & import('vue').ComponentOptionsBase<Readonly<import('vue').ExtractPropTypes<{
|
|
179
|
-
value: {
|
|
180
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
181
|
-
default: undefined;
|
|
182
|
-
};
|
|
183
179
|
size: {
|
|
184
180
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
185
181
|
};
|
|
@@ -187,10 +183,17 @@ export declare const Checkbox: {
|
|
|
187
183
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
188
184
|
default: undefined;
|
|
189
185
|
};
|
|
186
|
+
border: {
|
|
187
|
+
type: import('vue').PropType<boolean>;
|
|
188
|
+
};
|
|
190
189
|
name: {
|
|
191
190
|
type: import('vue').PropType<string>;
|
|
192
191
|
default: undefined;
|
|
193
192
|
};
|
|
193
|
+
value: {
|
|
194
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
195
|
+
default: undefined;
|
|
196
|
+
};
|
|
194
197
|
disabled: {
|
|
195
198
|
type: import('vue').PropType<boolean>;
|
|
196
199
|
default: undefined;
|
|
@@ -213,9 +216,6 @@ export declare const Checkbox: {
|
|
|
213
216
|
type: import('vue').PropType<boolean>;
|
|
214
217
|
default: true;
|
|
215
218
|
};
|
|
216
|
-
border: {
|
|
217
|
-
type: import('vue').PropType<boolean>;
|
|
218
|
-
};
|
|
219
219
|
ariaControls: {
|
|
220
220
|
type: import('vue').PropType<string>;
|
|
221
221
|
};
|
|
@@ -266,10 +266,6 @@ export declare const Checkbox: {
|
|
|
266
266
|
}) & import('vue').ObjectPlugin & {
|
|
267
267
|
CheckboxButton: {
|
|
268
268
|
new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('vue').ExtractPropTypes<{
|
|
269
|
-
value: {
|
|
270
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
271
|
-
default: undefined;
|
|
272
|
-
};
|
|
273
269
|
size: {
|
|
274
270
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
275
271
|
};
|
|
@@ -277,10 +273,17 @@ export declare const Checkbox: {
|
|
|
277
273
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
278
274
|
default: undefined;
|
|
279
275
|
};
|
|
276
|
+
border: {
|
|
277
|
+
type: import('vue').PropType<boolean>;
|
|
278
|
+
};
|
|
280
279
|
name: {
|
|
281
280
|
type: import('vue').PropType<string>;
|
|
282
281
|
default: undefined;
|
|
283
282
|
};
|
|
283
|
+
value: {
|
|
284
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
285
|
+
default: undefined;
|
|
286
|
+
};
|
|
284
287
|
disabled: {
|
|
285
288
|
type: import('vue').PropType<boolean>;
|
|
286
289
|
default: undefined;
|
|
@@ -303,9 +306,6 @@ export declare const Checkbox: {
|
|
|
303
306
|
type: import('vue').PropType<boolean>;
|
|
304
307
|
default: true;
|
|
305
308
|
};
|
|
306
|
-
border: {
|
|
307
|
-
type: import('vue').PropType<boolean>;
|
|
308
|
-
};
|
|
309
309
|
ariaControls: {
|
|
310
310
|
type: import('vue').PropType<string>;
|
|
311
311
|
};
|
|
@@ -357,10 +357,6 @@ export declare const Checkbox: {
|
|
|
357
357
|
M: {};
|
|
358
358
|
Defaults: {};
|
|
359
359
|
}, Readonly<import('vue').ExtractPropTypes<{
|
|
360
|
-
value: {
|
|
361
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
362
|
-
default: undefined;
|
|
363
|
-
};
|
|
364
360
|
size: {
|
|
365
361
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
366
362
|
};
|
|
@@ -368,10 +364,17 @@ export declare const Checkbox: {
|
|
|
368
364
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
369
365
|
default: undefined;
|
|
370
366
|
};
|
|
367
|
+
border: {
|
|
368
|
+
type: import('vue').PropType<boolean>;
|
|
369
|
+
};
|
|
371
370
|
name: {
|
|
372
371
|
type: import('vue').PropType<string>;
|
|
373
372
|
default: undefined;
|
|
374
373
|
};
|
|
374
|
+
value: {
|
|
375
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
376
|
+
default: undefined;
|
|
377
|
+
};
|
|
375
378
|
disabled: {
|
|
376
379
|
type: import('vue').PropType<boolean>;
|
|
377
380
|
default: undefined;
|
|
@@ -394,9 +397,6 @@ export declare const Checkbox: {
|
|
|
394
397
|
type: import('vue').PropType<boolean>;
|
|
395
398
|
default: true;
|
|
396
399
|
};
|
|
397
|
-
border: {
|
|
398
|
-
type: import('vue').PropType<boolean>;
|
|
399
|
-
};
|
|
400
400
|
ariaControls: {
|
|
401
401
|
type: import('vue').PropType<string>;
|
|
402
402
|
};
|
|
@@ -442,10 +442,6 @@ export declare const Checkbox: {
|
|
|
442
442
|
__isTeleport?: never;
|
|
443
443
|
__isSuspense?: never;
|
|
444
444
|
} & import('vue').ComponentOptionsBase<Readonly<import('vue').ExtractPropTypes<{
|
|
445
|
-
value: {
|
|
446
|
-
type: import('vue').PropType<string | number | boolean | object>;
|
|
447
|
-
default: undefined;
|
|
448
|
-
};
|
|
449
445
|
size: {
|
|
450
446
|
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
451
447
|
};
|
|
@@ -453,10 +449,17 @@ export declare const Checkbox: {
|
|
|
453
449
|
type: import('vue').PropType<string | number | boolean | object>;
|
|
454
450
|
default: undefined;
|
|
455
451
|
};
|
|
452
|
+
border: {
|
|
453
|
+
type: import('vue').PropType<boolean>;
|
|
454
|
+
};
|
|
456
455
|
name: {
|
|
457
456
|
type: import('vue').PropType<string>;
|
|
458
457
|
default: undefined;
|
|
459
458
|
};
|
|
459
|
+
value: {
|
|
460
|
+
type: import('vue').PropType<string | number | boolean | object>;
|
|
461
|
+
default: undefined;
|
|
462
|
+
};
|
|
460
463
|
disabled: {
|
|
461
464
|
type: import('vue').PropType<boolean>;
|
|
462
465
|
default: undefined;
|
|
@@ -479,9 +482,6 @@ export declare const Checkbox: {
|
|
|
479
482
|
type: import('vue').PropType<boolean>;
|
|
480
483
|
default: true;
|
|
481
484
|
};
|
|
482
|
-
border: {
|
|
483
|
-
type: import('vue').PropType<boolean>;
|
|
484
|
-
};
|
|
485
485
|
ariaControls: {
|
|
486
486
|
type: import('vue').PropType<string>;
|
|
487
487
|
};
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
import { ElColorPicker } from 'element-plus';
|
|
2
|
+
export type ColorPickerProps = typeof ElColorPicker;
|
|
3
|
+
export declare const ColorPicker: import('element-plus/es/utils/index.mjs').SFCWithInstall<import('vue').DefineComponent<{
|
|
4
|
+
emptyValues: {
|
|
5
|
+
type: import('vue').PropType<unknown[]>;
|
|
6
|
+
};
|
|
7
|
+
valueOnClear: {
|
|
8
|
+
type: import('vue').PropType<string | number | boolean | Function>;
|
|
9
|
+
default: undefined;
|
|
10
|
+
};
|
|
11
|
+
size: {
|
|
12
|
+
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
13
|
+
};
|
|
14
|
+
disabled: {
|
|
15
|
+
type: import('vue').PropType<boolean>;
|
|
16
|
+
default: undefined;
|
|
17
|
+
};
|
|
18
|
+
id: {
|
|
19
|
+
type: import('vue').PropType<string>;
|
|
20
|
+
};
|
|
21
|
+
modelValue: {
|
|
22
|
+
type: import('vue').PropType<string>;
|
|
23
|
+
default: undefined;
|
|
24
|
+
};
|
|
25
|
+
tabindex: {
|
|
26
|
+
type: import('vue').PropType<string | number>;
|
|
27
|
+
default: 0;
|
|
28
|
+
};
|
|
29
|
+
ariaLabel: {
|
|
30
|
+
type: import('vue').PropType<string>;
|
|
31
|
+
};
|
|
32
|
+
popperClass: {
|
|
33
|
+
type: import('vue').PropType<string | {
|
|
34
|
+
[x: string]: boolean;
|
|
35
|
+
} | (string | {
|
|
36
|
+
[x: string]: boolean;
|
|
37
|
+
} | (string | {
|
|
38
|
+
[x: string]: boolean;
|
|
39
|
+
} | (string | {
|
|
40
|
+
[x: string]: boolean;
|
|
41
|
+
} | (string | {
|
|
42
|
+
[x: string]: boolean;
|
|
43
|
+
} | (string | {
|
|
44
|
+
[x: string]: boolean;
|
|
45
|
+
} | (string | {
|
|
46
|
+
[x: string]: boolean;
|
|
47
|
+
} | (string | {
|
|
48
|
+
[x: string]: boolean;
|
|
49
|
+
} | (string | {
|
|
50
|
+
[x: string]: boolean;
|
|
51
|
+
} | (string | {
|
|
52
|
+
[x: string]: boolean;
|
|
53
|
+
} | (string | {
|
|
54
|
+
[x: string]: boolean;
|
|
55
|
+
} | (string | {
|
|
56
|
+
[x: string]: boolean;
|
|
57
|
+
} | /*elided*/ any)[])[])[])[])[])[])[])[])[])[])[]>;
|
|
58
|
+
};
|
|
59
|
+
popperStyle: {
|
|
60
|
+
type: import('vue').PropType<import('vue').StyleValue>;
|
|
61
|
+
default: undefined;
|
|
62
|
+
};
|
|
63
|
+
teleported: {
|
|
64
|
+
type: import('vue').PropType<boolean>;
|
|
65
|
+
default: true;
|
|
66
|
+
};
|
|
67
|
+
clearable: {
|
|
68
|
+
type: import('vue').PropType<boolean>;
|
|
69
|
+
default: true;
|
|
70
|
+
};
|
|
71
|
+
validateEvent: {
|
|
72
|
+
type: import('vue').PropType<boolean>;
|
|
73
|
+
default: true;
|
|
74
|
+
};
|
|
75
|
+
persistent: {
|
|
76
|
+
type: import('vue').PropType<boolean>;
|
|
77
|
+
default: true;
|
|
78
|
+
};
|
|
79
|
+
appendTo: {
|
|
80
|
+
type: import('vue').PropType<string | HTMLElement>;
|
|
81
|
+
};
|
|
82
|
+
showAlpha: {
|
|
83
|
+
type: import('vue').PropType<boolean>;
|
|
84
|
+
};
|
|
85
|
+
colorFormat: {
|
|
86
|
+
type: import('vue').PropType<string>;
|
|
87
|
+
};
|
|
88
|
+
predefine: {
|
|
89
|
+
type: import('vue').PropType<string[]>;
|
|
90
|
+
};
|
|
91
|
+
}, {
|
|
92
|
+
color: import('element-plus/es/components/color-picker-panel/src/utils/color.mjs').default;
|
|
93
|
+
show: () => void;
|
|
94
|
+
hide: () => void;
|
|
95
|
+
focus: () => void;
|
|
96
|
+
blur: () => void;
|
|
97
|
+
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
98
|
+
focus: (evt: FocusEvent) => void;
|
|
99
|
+
"update:modelValue": (val: string | null) => void;
|
|
100
|
+
change: (val: string | null) => void;
|
|
101
|
+
clear: () => void;
|
|
102
|
+
blur: (evt: FocusEvent) => void;
|
|
103
|
+
activeChange: (val: string | null) => void;
|
|
104
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
105
|
+
emptyValues: {
|
|
106
|
+
type: import('vue').PropType<unknown[]>;
|
|
107
|
+
};
|
|
108
|
+
valueOnClear: {
|
|
109
|
+
type: import('vue').PropType<string | number | boolean | Function>;
|
|
110
|
+
default: undefined;
|
|
111
|
+
};
|
|
112
|
+
size: {
|
|
113
|
+
type: import('vue').PropType<"" | "small" | "default" | "large">;
|
|
114
|
+
};
|
|
115
|
+
disabled: {
|
|
116
|
+
type: import('vue').PropType<boolean>;
|
|
117
|
+
default: undefined;
|
|
118
|
+
};
|
|
119
|
+
id: {
|
|
120
|
+
type: import('vue').PropType<string>;
|
|
121
|
+
};
|
|
122
|
+
modelValue: {
|
|
123
|
+
type: import('vue').PropType<string>;
|
|
124
|
+
default: undefined;
|
|
125
|
+
};
|
|
126
|
+
tabindex: {
|
|
127
|
+
type: import('vue').PropType<string | number>;
|
|
128
|
+
default: 0;
|
|
129
|
+
};
|
|
130
|
+
ariaLabel: {
|
|
131
|
+
type: import('vue').PropType<string>;
|
|
132
|
+
};
|
|
133
|
+
popperClass: {
|
|
134
|
+
type: import('vue').PropType<string | {
|
|
135
|
+
[x: string]: boolean;
|
|
136
|
+
} | (string | {
|
|
137
|
+
[x: string]: boolean;
|
|
138
|
+
} | (string | {
|
|
139
|
+
[x: string]: boolean;
|
|
140
|
+
} | (string | {
|
|
141
|
+
[x: string]: boolean;
|
|
142
|
+
} | (string | {
|
|
143
|
+
[x: string]: boolean;
|
|
144
|
+
} | (string | {
|
|
145
|
+
[x: string]: boolean;
|
|
146
|
+
} | (string | {
|
|
147
|
+
[x: string]: boolean;
|
|
148
|
+
} | (string | {
|
|
149
|
+
[x: string]: boolean;
|
|
150
|
+
} | (string | {
|
|
151
|
+
[x: string]: boolean;
|
|
152
|
+
} | (string | {
|
|
153
|
+
[x: string]: boolean;
|
|
154
|
+
} | (string | {
|
|
155
|
+
[x: string]: boolean;
|
|
156
|
+
} | (string | {
|
|
157
|
+
[x: string]: boolean;
|
|
158
|
+
} | /*elided*/ any)[])[])[])[])[])[])[])[])[])[])[]>;
|
|
159
|
+
};
|
|
160
|
+
popperStyle: {
|
|
161
|
+
type: import('vue').PropType<import('vue').StyleValue>;
|
|
162
|
+
default: undefined;
|
|
163
|
+
};
|
|
164
|
+
teleported: {
|
|
165
|
+
type: import('vue').PropType<boolean>;
|
|
166
|
+
default: true;
|
|
167
|
+
};
|
|
168
|
+
clearable: {
|
|
169
|
+
type: import('vue').PropType<boolean>;
|
|
170
|
+
default: true;
|
|
171
|
+
};
|
|
172
|
+
validateEvent: {
|
|
173
|
+
type: import('vue').PropType<boolean>;
|
|
174
|
+
default: true;
|
|
175
|
+
};
|
|
176
|
+
persistent: {
|
|
177
|
+
type: import('vue').PropType<boolean>;
|
|
178
|
+
default: true;
|
|
179
|
+
};
|
|
180
|
+
appendTo: {
|
|
181
|
+
type: import('vue').PropType<string | HTMLElement>;
|
|
182
|
+
};
|
|
183
|
+
showAlpha: {
|
|
184
|
+
type: import('vue').PropType<boolean>;
|
|
185
|
+
};
|
|
186
|
+
colorFormat: {
|
|
187
|
+
type: import('vue').PropType<string>;
|
|
188
|
+
};
|
|
189
|
+
predefine: {
|
|
190
|
+
type: import('vue').PropType<string[]>;
|
|
191
|
+
};
|
|
192
|
+
}>> & {
|
|
193
|
+
"onUpdate:modelValue"?: ((val: string | null) => any) | undefined;
|
|
194
|
+
onFocus?: ((evt: FocusEvent) => any) | undefined;
|
|
195
|
+
onChange?: ((val: string | null) => any) | undefined;
|
|
196
|
+
onBlur?: ((evt: FocusEvent) => any) | undefined;
|
|
197
|
+
onClear?: (() => any) | undefined;
|
|
198
|
+
onActiveChange?: ((val: string | null) => any) | undefined;
|
|
199
|
+
}, {
|
|
200
|
+
disabled: boolean;
|
|
201
|
+
tabindex: string | number;
|
|
202
|
+
modelValue: string | null;
|
|
203
|
+
valueOnClear: string | number | boolean | Function | null;
|
|
204
|
+
teleported: boolean;
|
|
205
|
+
validateEvent: boolean;
|
|
206
|
+
clearable: boolean;
|
|
207
|
+
popperStyle: string | false | import('vue').CSSProperties | import('vue').StyleValue[] | null;
|
|
208
|
+
persistent: boolean;
|
|
209
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>>;
|
|
210
|
+
export default ColorPicker;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { connect as r, mapProps as o } from "@silver-formily/vue";
|
|
2
|
+
import { ElColorPicker as e } from "element-plus";
|
|
3
|
+
import { PreviewText as t } from "../preview-text/index.mjs";
|
|
4
|
+
import { mapReadPretty as m } from "../__builtins__/shared/transform-component.mjs";
|
|
5
|
+
const c = r(
|
|
6
|
+
e,
|
|
7
|
+
o({ readOnly: "readonly", disabled: !0 }),
|
|
8
|
+
m(t.ColorPicker)
|
|
9
|
+
);
|
|
10
|
+
export {
|
|
11
|
+
c as ColorPicker,
|
|
12
|
+
c as default
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../src/color-picker/index.ts"],"sourcesContent":["import { connect, mapProps } from '@silver-formily/vue'\r\nimport { ElColorPicker } from 'element-plus'\r\nimport { mapReadPretty } from '../__builtins__'\r\nimport { PreviewText } from '../preview-text'\r\n\r\nexport type ColorPickerProps = typeof ElColorPicker\r\n\r\nexport const ColorPicker = connect<typeof ElColorPicker>(\r\n ElColorPicker,\r\n mapProps({ readOnly: 'readonly', disabled: true }),\r\n mapReadPretty(PreviewText.ColorPicker),\r\n)\r\n\r\nexport default ColorPicker\r\n"],"names":["ColorPicker","connect","ElColorPicker","mapProps","mapReadPretty","PreviewText"],"mappings":";;;;AAOO,MAAMA,IAAcC;AAAA,EACzBC;AAAA,EACAC,EAAS,EAAE,UAAU,YAAY,UAAU,IAAM;AAAA,EACjDC,EAAcC,EAAY,WAAW;AACvC;"}
|