vue-devui 1.0.0-rc.8 → 1.0.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 +188 -149
- package/alert/index.es.js +14 -9
- package/alert/index.umd.js +1 -1
- package/alert/style.css +1 -1
- package/auto-complete/index.es.js +8392 -418
- package/auto-complete/index.umd.js +29 -5
- package/auto-complete/style.css +1 -1
- package/avatar/index.es.js +59 -74
- package/avatar/index.umd.js +1 -1
- package/badge/index.es.js +10 -4
- package/badge/index.umd.js +1 -1
- package/badge/style.css +1 -1
- package/button/index.es.js +191 -53
- package/button/index.umd.js +17 -17
- package/button/style.css +1 -1
- package/card/index.es.js +7 -3
- package/card/index.umd.js +1 -1
- package/card/style.css +1 -1
- package/checkbox/index.es.js +8050 -241
- package/checkbox/index.umd.js +27 -1
- package/checkbox/style.css +1 -1
- package/{date-picker → collapse}/index.d.ts +0 -0
- package/collapse/index.es.js +213 -0
- package/collapse/index.umd.js +1 -0
- package/{date-picker → collapse}/package.json +1 -1
- package/collapse/style.css +1 -0
- package/countdown/index.es.js +56 -13
- package/countdown/index.umd.js +1 -1
- package/date-picker-pro/index.d.ts +7 -0
- package/date-picker-pro/index.es.js +12022 -0
- package/date-picker-pro/index.umd.js +27 -0
- package/date-picker-pro/package.json +7 -0
- package/date-picker-pro/style.css +1 -0
- package/drawer/index.es.js +24 -7
- package/drawer/index.umd.js +1 -1
- package/drawer/style.css +1 -1
- package/dropdown/index.es.js +190 -165
- package/dropdown/index.umd.js +1 -1
- package/dropdown/style.css +1 -1
- package/editable-select/index.es.js +785 -145
- package/editable-select/index.umd.js +1 -1
- package/editable-select/style.css +1 -1
- package/form/index.es.js +399 -300
- package/form/index.umd.js +16 -16
- package/form/style.css +1 -1
- package/fullscreen/index.es.js +2 -2
- package/fullscreen/index.umd.js +1 -1
- package/grid/index.es.js +8 -6
- package/grid/index.umd.js +1 -1
- package/icon/index.es.js +185 -23
- package/icon/index.umd.js +1 -1
- package/icon/style.css +1 -0
- package/image-preview/index.es.js +2 -2
- package/image-preview/index.umd.js +1 -1
- package/image-preview/style.css +1 -1
- package/input/index.es.js +8220 -45
- package/input/index.umd.js +27 -1
- package/input/style.css +1 -1
- package/input-number/index.es.js +279 -204
- package/input-number/index.umd.js +1 -1
- package/input-number/style.css +1 -1
- package/layout/index.es.js +3 -3
- package/layout/index.umd.js +1 -1
- package/loading/index.es.js +53 -53
- package/loading/index.umd.js +1 -1
- package/loading/style.css +1 -1
- package/mention/index.d.ts +7 -0
- package/mention/index.es.js +8319 -0
- package/mention/index.umd.js +36 -0
- package/mention/package.json +7 -0
- package/mention/style.css +1 -0
- package/menu/index.d.ts +7 -0
- package/menu/index.es.js +921 -0
- package/menu/index.umd.js +1 -0
- package/menu/package.json +7 -0
- package/menu/style.css +1 -0
- package/message/index.d.ts +7 -0
- package/message/index.es.js +539 -0
- package/message/index.umd.js +1 -0
- package/message/package.json +7 -0
- package/message/style.css +1 -0
- package/modal/index.es.js +451 -173
- package/modal/index.umd.js +1 -1
- package/modal/style.css +1 -1
- package/notification/index.es.js +212 -70
- package/notification/index.umd.js +1 -1
- package/notification/style.css +1 -1
- package/nuxt/components/CheckboxButton.js +3 -0
- package/nuxt/components/Collapse.js +3 -0
- package/nuxt/components/CollapseItem.js +3 -0
- package/nuxt/components/DRangeDatePickerPro.js +3 -0
- package/nuxt/components/DatePickerPro.js +3 -0
- package/nuxt/components/Icon.js +1 -0
- package/nuxt/components/IconGroup.js +3 -0
- package/nuxt/components/LABEL_DATA.js +3 -0
- package/nuxt/components/Mention.js +3 -0
- package/nuxt/components/Menu.js +3 -0
- package/nuxt/components/MenuItem.js +3 -0
- package/nuxt/components/Message.js +3 -0
- package/nuxt/components/Option.js +3 -0
- package/nuxt/components/OptionGroup.js +3 -0
- package/nuxt/components/RadioButton.js +3 -0
- package/nuxt/components/Step.js +3 -0
- package/nuxt/components/Steps.js +3 -0
- package/nuxt/components/SubMenu.js +3 -0
- package/nuxt/components/TABLE_TOKEN.js +3 -0
- package/nuxt/components/TimePicker.js +3 -0
- package/nuxt/components/TimeSelect.js +3 -0
- package/nuxt/components/animationInjectionKey.js +3 -0
- package/nuxt/components/collapseItemProps.js +3 -0
- package/nuxt/components/collapseProps.js +3 -0
- package/nuxt/components/datePickerProCommonProps.js +3 -0
- package/nuxt/components/datePickerProPanelProps.js +3 -0
- package/nuxt/components/datePickerProProps.js +3 -0
- package/nuxt/components/iconProps.js +1 -0
- package/nuxt/components/mentionProps.js +3 -0
- package/nuxt/components/messageProps.js +3 -0
- package/nuxt/components/paginationInjectionKey.js +3 -0
- package/nuxt/components/roundInjectionKey.js +3 -0
- package/nuxt/components/skeletonItemProps.js +3 -0
- package/nuxt/components/stepProps.js +3 -0
- package/nuxt/components/stepsProps.js +3 -0
- package/nuxt/components/svgIconProps.js +3 -0
- package/nuxt/components/tableProps.js +3 -0
- package/nuxt/components/timerPickerPanelProps.js +3 -0
- package/nuxt/components/treeNodeProps.js +3 -0
- package/overlay/index.es.js +89 -142
- package/overlay/index.umd.js +1 -1
- package/overlay/style.css +1 -1
- package/package.json +8 -4
- package/pagination/index.es.js +10180 -129
- package/pagination/index.umd.js +27 -1
- package/pagination/style.css +1 -1
- package/panel/index.es.js +4 -0
- package/panel/index.umd.js +1 -1
- package/panel/style.css +1 -1
- package/popover/index.es.js +262 -229
- package/popover/index.umd.js +15 -15
- package/popover/style.css +1 -1
- package/progress/index.es.js +2 -2
- package/progress/index.umd.js +2 -2
- package/progress/style.css +1 -1
- package/radio/index.es.js +7954 -156
- package/radio/index.umd.js +27 -1
- package/radio/style.css +1 -1
- package/rate/index.es.js +16 -8
- package/rate/index.umd.js +1 -1
- package/rate/style.css +1 -1
- package/result/index.es.js +170 -22
- package/result/index.umd.js +1 -1
- package/result/style.css +1 -1
- package/search/index.es.js +3829 -1042
- package/search/index.umd.js +18 -18
- package/search/style.css +1 -1
- package/select/index.es.js +9202 -495
- package/select/index.umd.js +27 -1
- package/select/style.css +1 -1
- package/skeleton/index.es.js +89 -263
- package/skeleton/index.umd.js +1 -1
- package/skeleton/style.css +1 -1
- package/slider/index.es.js +118 -145
- package/slider/index.umd.js +1 -1
- package/slider/style.css +1 -1
- package/splitter/index.es.js +454 -233
- package/splitter/index.umd.js +13 -13
- package/splitter/style.css +1 -1
- package/statistic/index.es.js +34 -16
- package/statistic/index.umd.js +1 -1
- package/statistic/style.css +1 -1
- package/status/index.es.js +6 -2
- package/status/index.umd.js +1 -1
- package/status/style.css +1 -1
- package/steps/index.d.ts +7 -0
- package/steps/index.es.js +387 -0
- package/steps/index.umd.js +1 -0
- package/steps/package.json +7 -0
- package/steps/style.css +1 -0
- package/style.css +1 -1
- package/switch/index.es.js +7787 -62
- package/switch/index.umd.js +27 -1
- package/switch/style.css +1 -1
- package/table/index.es.js +5225 -1726
- package/table/index.umd.js +18 -18
- package/table/style.css +1 -1
- package/tabs/index.es.js +303 -102
- package/tabs/index.umd.js +1 -1
- package/tabs/style.css +1 -1
- package/tag/index.es.js +11 -8
- package/tag/index.umd.js +1 -1
- package/tag/style.css +1 -1
- package/textarea/index.es.js +7876 -41
- package/textarea/index.umd.js +35 -1
- package/textarea/style.css +1 -1
- package/time-picker/index.d.ts +7 -0
- package/time-picker/index.es.js +9549 -0
- package/time-picker/index.umd.js +27 -0
- package/time-picker/package.json +7 -0
- package/time-picker/style.css +1 -0
- package/time-select/index.d.ts +7 -0
- package/time-select/index.es.js +9607 -0
- package/time-select/index.umd.js +27 -0
- package/time-select/package.json +7 -0
- package/time-select/style.css +1 -0
- package/timeline/index.es.js +170 -22
- package/timeline/index.umd.js +1 -1
- package/timeline/style.css +1 -1
- package/tooltip/index.es.js +286 -238
- package/tooltip/index.umd.js +14 -14
- package/tooltip/style.css +1 -1
- package/tree/index.es.js +11342 -793
- package/tree/index.umd.js +27 -1
- package/tree/style.css +1 -1
- package/upload/index.es.js +458 -102
- package/upload/index.umd.js +1 -1
- package/upload/style.css +1 -1
- package/vue-devui.es.js +20475 -11072
- package/vue-devui.umd.js +31 -24
- package/date-picker/index.es.js +0 -1097
- package/date-picker/index.umd.js +0 -1
- package/date-picker/style.css +0 -1
- package/nuxt/components/DatePicker.js +0 -3
- package/nuxt/components/FormControl.js +0 -3
- package/nuxt/components/FormLabel.js +0 -3
- package/nuxt/components/Loading.js +0 -3
- package/nuxt/components/StickSlider.js +0 -3
- package/nuxt/components/formControlProps.js +0 -3
- package/nuxt/components/overlayEmits.js +0 -3
- package/nuxt/components/overlayProps.js +0 -3
package/result/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, toRefs, createVNode } from "vue";
|
|
1
|
+
import { defineComponent, toRefs, computed, createVNode, resolveDynamicComponent, mergeProps } from "vue";
|
|
2
2
|
const resultProps = {
|
|
3
3
|
icon: {
|
|
4
4
|
type: String,
|
|
@@ -13,6 +13,7 @@ const resultProps = {
|
|
|
13
13
|
default: ""
|
|
14
14
|
}
|
|
15
15
|
};
|
|
16
|
+
const DEFAULT_PREFIX = "icon";
|
|
16
17
|
const iconProps = {
|
|
17
18
|
name: {
|
|
18
19
|
type: String,
|
|
@@ -20,43 +21,190 @@ const iconProps = {
|
|
|
20
21
|
required: true
|
|
21
22
|
},
|
|
22
23
|
size: {
|
|
23
|
-
type: String,
|
|
24
|
+
type: [Number, String],
|
|
24
25
|
default: "inherit"
|
|
25
26
|
},
|
|
26
27
|
color: {
|
|
27
28
|
type: String,
|
|
28
29
|
default: "inherit"
|
|
29
30
|
},
|
|
31
|
+
component: {
|
|
32
|
+
type: Object,
|
|
33
|
+
default: null
|
|
34
|
+
},
|
|
30
35
|
classPrefix: {
|
|
31
36
|
type: String,
|
|
32
|
-
default:
|
|
37
|
+
default: DEFAULT_PREFIX
|
|
38
|
+
},
|
|
39
|
+
operable: {
|
|
40
|
+
type: Boolean,
|
|
41
|
+
default: false
|
|
42
|
+
},
|
|
43
|
+
disabled: {
|
|
44
|
+
type: Boolean,
|
|
45
|
+
default: false
|
|
46
|
+
},
|
|
47
|
+
rotate: {
|
|
48
|
+
type: [Number, String]
|
|
33
49
|
}
|
|
34
50
|
};
|
|
35
|
-
|
|
36
|
-
name:
|
|
37
|
-
|
|
51
|
+
const svgIconProps = {
|
|
52
|
+
name: {
|
|
53
|
+
type: String,
|
|
54
|
+
default: "",
|
|
55
|
+
required: true
|
|
56
|
+
},
|
|
57
|
+
color: {
|
|
58
|
+
type: String,
|
|
59
|
+
default: "inherit"
|
|
60
|
+
},
|
|
61
|
+
size: {
|
|
62
|
+
type: [Number, String],
|
|
63
|
+
default: "inherit"
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
function createBem(namespace, element, modifier) {
|
|
67
|
+
let cls = namespace;
|
|
68
|
+
if (element) {
|
|
69
|
+
cls += `__${element}`;
|
|
70
|
+
}
|
|
71
|
+
if (modifier) {
|
|
72
|
+
cls += `--${modifier}`;
|
|
73
|
+
}
|
|
74
|
+
return cls;
|
|
75
|
+
}
|
|
76
|
+
function useNamespace(block, needDot = false) {
|
|
77
|
+
const namespace = needDot ? `.devui-${block}` : `devui-${block}`;
|
|
78
|
+
const b = () => createBem(namespace);
|
|
79
|
+
const e = (element) => element ? createBem(namespace, element) : "";
|
|
80
|
+
const m = (modifier) => modifier ? createBem(namespace, "", modifier) : "";
|
|
81
|
+
const em = (element, modifier) => element && modifier ? createBem(namespace, element, modifier) : "";
|
|
82
|
+
return {
|
|
83
|
+
b,
|
|
84
|
+
e,
|
|
85
|
+
m,
|
|
86
|
+
em
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
var icon = "";
|
|
90
|
+
var svgIcon = defineComponent({
|
|
91
|
+
name: "DSvgIcon",
|
|
92
|
+
props: svgIconProps,
|
|
38
93
|
setup(props) {
|
|
39
94
|
const {
|
|
40
95
|
name,
|
|
41
|
-
size,
|
|
42
96
|
color,
|
|
43
|
-
|
|
97
|
+
size
|
|
44
98
|
} = toRefs(props);
|
|
99
|
+
const ns = useNamespace("svg-icon");
|
|
100
|
+
const iconName = computed(() => `#icon-${name.value}`);
|
|
101
|
+
const iconSize = computed(() => {
|
|
102
|
+
return typeof size.value === "number" ? `${size.value}px` : size.value;
|
|
103
|
+
});
|
|
104
|
+
const styles = {
|
|
105
|
+
width: iconSize.value,
|
|
106
|
+
height: iconSize.value
|
|
107
|
+
};
|
|
45
108
|
return () => {
|
|
46
|
-
return
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
109
|
+
return createVNode("svg", {
|
|
110
|
+
"class": ns.b(),
|
|
111
|
+
"style": styles
|
|
112
|
+
}, [createVNode("use", {
|
|
113
|
+
"xlink:href": iconName.value,
|
|
114
|
+
"fill": color.value
|
|
115
|
+
}, null)]);
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
});
|
|
119
|
+
function isUrl(value) {
|
|
120
|
+
return /^((http|https):)?\/\//.test(value);
|
|
121
|
+
}
|
|
122
|
+
function useIconDom(props, ctx) {
|
|
123
|
+
const {
|
|
124
|
+
component,
|
|
125
|
+
name,
|
|
126
|
+
size,
|
|
127
|
+
color,
|
|
128
|
+
classPrefix,
|
|
129
|
+
rotate
|
|
130
|
+
} = toRefs(props);
|
|
131
|
+
const ns = useNamespace("icon");
|
|
132
|
+
const iconSize = computed(() => {
|
|
133
|
+
return typeof size.value === "number" ? `${size.value}px` : size.value;
|
|
134
|
+
});
|
|
135
|
+
const IconComponent = component.value ? resolveDynamicComponent(component.value) : resolveDynamicComponent(svgIcon);
|
|
136
|
+
const imgIconDom = () => {
|
|
137
|
+
return createVNode("img", mergeProps({
|
|
138
|
+
"src": name.value,
|
|
139
|
+
"alt": name.value.split("/")[name.value.split("/").length - 1],
|
|
140
|
+
"class": [(rotate == null ? void 0 : rotate.value) === "infinite" && ns.m("spin")],
|
|
141
|
+
"style": {
|
|
142
|
+
width: iconSize.value || "",
|
|
143
|
+
transform: `rotate(${rotate == null ? void 0 : rotate.value}deg)`,
|
|
144
|
+
verticalAlign: "middle"
|
|
145
|
+
}
|
|
146
|
+
}, ctx.attrs), null);
|
|
147
|
+
};
|
|
148
|
+
const svgIconDom = () => {
|
|
149
|
+
return createVNode(IconComponent, mergeProps({
|
|
150
|
+
"name": name.value,
|
|
151
|
+
"color": color.value,
|
|
152
|
+
"size": iconSize.value,
|
|
153
|
+
"class": [(rotate == null ? void 0 : rotate.value) === "infinite" && ns.m("spin")],
|
|
154
|
+
"style": {
|
|
155
|
+
transform: `rotate(${rotate == null ? void 0 : rotate.value}deg)`
|
|
156
|
+
}
|
|
157
|
+
}, ctx.attrs), null);
|
|
158
|
+
};
|
|
159
|
+
const fontIconDom = () => {
|
|
160
|
+
const fontIconClass = /^icon-/.test(name.value) ? name.value : `${classPrefix.value}-${name.value}`;
|
|
161
|
+
return createVNode("i", mergeProps({
|
|
162
|
+
"class": [classPrefix.value, fontIconClass, (rotate == null ? void 0 : rotate.value) === "infinite" && ns.m("spin")],
|
|
163
|
+
"style": {
|
|
164
|
+
fontSize: iconSize.value,
|
|
165
|
+
color: color.value,
|
|
166
|
+
transform: `rotate(${rotate == null ? void 0 : rotate.value}deg)`
|
|
167
|
+
}
|
|
168
|
+
}, ctx.attrs), null);
|
|
169
|
+
};
|
|
170
|
+
const iconDom = () => {
|
|
171
|
+
return component.value ? svgIconDom() : isUrl(name.value) ? imgIconDom() : fontIconDom();
|
|
172
|
+
};
|
|
173
|
+
return {
|
|
174
|
+
iconDom
|
|
175
|
+
};
|
|
176
|
+
}
|
|
177
|
+
var Icon = defineComponent({
|
|
178
|
+
name: "DIcon",
|
|
179
|
+
props: iconProps,
|
|
180
|
+
emits: ["click"],
|
|
181
|
+
setup(props, ctx) {
|
|
182
|
+
const {
|
|
183
|
+
disabled,
|
|
184
|
+
operable
|
|
185
|
+
} = toRefs(props);
|
|
186
|
+
const {
|
|
187
|
+
iconDom
|
|
188
|
+
} = useIconDom(props, ctx);
|
|
189
|
+
const ns = useNamespace("icon");
|
|
190
|
+
const wrapClassed = computed(() => ({
|
|
191
|
+
[ns.e("container")]: true,
|
|
192
|
+
[ns.m("disabled")]: disabled.value,
|
|
193
|
+
[ns.m("operable")]: operable.value,
|
|
194
|
+
[ns.m("no-slots")]: !Object.keys(ctx.slots).length
|
|
195
|
+
}));
|
|
196
|
+
const onClick = (e) => {
|
|
197
|
+
if (disabled.value) {
|
|
198
|
+
return;
|
|
199
|
+
}
|
|
200
|
+
ctx.emit("click", e);
|
|
201
|
+
};
|
|
202
|
+
return () => {
|
|
203
|
+
var _a, _b, _c, _d;
|
|
204
|
+
return createVNode("div", {
|
|
205
|
+
"class": wrapClassed.value,
|
|
206
|
+
"onClick": onClick
|
|
207
|
+
}, [(_b = (_a = ctx.slots).prefix) == null ? void 0 : _b.call(_a), iconDom(), (_d = (_c = ctx.slots).suffix) == null ? void 0 : _d.call(_c)]);
|
|
60
208
|
};
|
|
61
209
|
}
|
|
62
210
|
});
|
package/result/index.umd.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(u,e){typeof exports=="object"&&typeof module!="undefined"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(u=typeof globalThis!="undefined"?globalThis:u||self,e(u.index={},u.Vue))})(this,function(u,e){"use strict";const y={icon:{type:String,default:"info"},title:{type:String,default:""},desc:{type:String,default:""}},b={name:{type:String,default:"",required:!0},size:{type:[Number,String],default:"inherit"},color:{type:String,default:"inherit"},component:{type:Object,default:null},classPrefix:{type:String,default:"icon"},operable:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},rotate:{type:[Number,String]}},h={name:{type:String,default:"",required:!0},color:{type:String,default:"inherit"},size:{type:[Number,String],default:"inherit"}};function f(o,s,l){let n=o;return s&&(n+=`__${s}`),l&&(n+=`--${l}`),n}function v(o,s=!1){const l=s?`.devui-${o}`:`devui-${o}`;return{b:()=>f(l),e:t=>t?f(l,t):"",m:t=>t?f(l,"",t):"",em:(t,c)=>t&&c?f(l,t,c):""}}var z="",N=e.defineComponent({name:"DSvgIcon",props:h,setup(o){const{name:s,color:l,size:n}=e.toRefs(o),r=v("svg-icon"),i=e.computed(()=>`#icon-${s.value}`),a=e.computed(()=>typeof n.value=="number"?`${n.value}px`:n.value),t={width:a.value,height:a.value};return()=>e.createVNode("svg",{class:r.b(),style:t},[e.createVNode("use",{"xlink:href":i.value,fill:l.value},null)])}});function S(o){return/^((http|https):)?\/\//.test(o)}function D(o,s){const{component:l,name:n,size:r,color:i,classPrefix:a,rotate:t}=e.toRefs(o),c=v("icon"),d=e.computed(()=>typeof r.value=="number"?`${r.value}px`:r.value),p=l.value?e.resolveDynamicComponent(l.value):e.resolveDynamicComponent(N),m=()=>e.createVNode("img",e.mergeProps({src:n.value,alt:n.value.split("/")[n.value.split("/").length-1],class:[(t==null?void 0:t.value)==="infinite"&&c.m("spin")],style:{width:d.value||"",transform:`rotate(${t==null?void 0:t.value}deg)`,verticalAlign:"middle"}},s.attrs),null),$=()=>e.createVNode(p,e.mergeProps({name:n.value,color:i.value,size:d.value,class:[(t==null?void 0:t.value)==="infinite"&&c.m("spin")],style:{transform:`rotate(${t==null?void 0:t.value}deg)`}},s.attrs),null),C=()=>{const P=/^icon-/.test(n.value)?n.value:`${a.value}-${n.value}`;return e.createVNode("i",e.mergeProps({class:[a.value,P,(t==null?void 0:t.value)==="infinite"&&c.m("spin")],style:{fontSize:d.value,color:i.value,transform:`rotate(${t==null?void 0:t.value}deg)`}},s.attrs),null)};return{iconDom:()=>l.value?$():S(n.value)?m():C()}}var _=e.defineComponent({name:"DIcon",props:b,emits:["click"],setup(o,s){const{disabled:l,operable:n}=e.toRefs(o),{iconDom:r}=D(o,s),i=v("icon"),a=e.computed(()=>({[i.e("container")]:!0,[i.m("disabled")]:l.value,[i.m("operable")]:n.value,[i.m("no-slots")]:!Object.keys(s.slots).length})),t=c=>{l.value||s.emit("click",c)};return()=>{var c,d,p,m;return e.createVNode("div",{class:a.value,onClick:t},[(d=(c=s.slots).prefix)==null?void 0:d.call(c),r(),(m=(p=s.slots).suffix)==null?void 0:m.call(p)])}}}),R="",g=e.defineComponent({name:"DResult",props:y,setup(o,s){let l;return function(n){n.success="right-o",n.danger="error-o",n.warning="warning-o",n.info="info-o"}(l||(l={})),()=>{var n,r,i,a;return e.createVNode("div",{class:"devui-result"},[s.slots.icon?e.createVNode("div",null,[(n=s.slots)==null?void 0:n.icon()]):e.createVNode(_,{name:l[o.icon]||"",class:`devui-result__icon-${o.icon}`,size:"64px"},null),e.createVNode("div",{class:"devui-result__title"},[s.slots.title?(r=s.slots)==null?void 0:r.title():o.title]),e.createVNode("div",{class:"devui-result__desc"},[s.slots.desc?(i=s.slots)==null?void 0:i.desc():o.desc]),e.createVNode("div",{class:"devui-result__extra"},[s.slots.extra?(a=s.slots)==null?void 0:a.extra():""])])}}}),V={title:"Result \u7ED3\u679C",category:"\u53CD\u9988",status:"100%",install(o){o.component(g.name,g)}};u.Result=g,u.default=V,u.resultProps=y,Object.defineProperty(u,"__esModule",{value:!0}),u[Symbol.toStringTag]="Module"});
|
package/result/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.devui-result{display:flex;justify-content:center;align-items:center;flex-direction:column;text-align:center;box-sizing:border-box;padding:30px}.devui-result__icon-success:before{color:var(--devui-success, #50d4ab)}.devui-result__icon-danger:before{color:var(--devui-danger, #f66f6a)}.devui-result__icon-warning:before{color:var(--devui-warning, #fac20a)}.devui-result__icon-info:before{color:var(--devui-info, #5e7ce0)}.devui-result__title{margin-top:20px;color:var(--devui-text, #252b3a);font-size:var(--devui-font-size-lg, 14px)}.devui-result__desc{margin-top:10px;color:var(--devui-text-weak, #575d6c);font-size:var(--devui-font-size-md,
|
|
1
|
+
.devui-icon__container{display:inline-block;color:var(--devui-icon-fill, #71757f)}.devui-icon__container>*:not(:last-child){vertical-align:middle;margin-right:8px}.devui-icon__container i{vertical-align:middle;transition:all var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1))}.devui-icon--no-slots i,.devui-icon--no-slots img{display:block}.devui-icon--disabled{color:var(--devui-disabled-text, #adb0b8);cursor:not-allowed}.devui-icon--disabled i{color:var(--devui-disabled-text, #adb0b8)}.devui-icon--operable:not(.devui-icon--disabled){cursor:pointer;transition:color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1))}.devui-icon--operable:not(.devui-icon--disabled) i{cursor:pointer}.devui-icon--operable:hover:not(.devui-icon--disabled){color:var(--devui-icon-fill-hover, #252b3a)}.devui-icon--operable:hover:not(.devui-icon--disabled).devui-icon__container{background-color:var(--devui-icon-background-hover, var(--devui-list-item-hover-bg, #f2f2f3))}.devui-icon--operable:hover:not(.devui-icon--disabled) i{color:var(--devui-icon-fill-hover, #252b3a)}.devui-icon--operable:active:not(.devui-icon--disabled){color:var(--devui-icon-active-color, var(--devui-icon-fill-active, #252b3a))}.devui-icon--operable:active:not(.devui-icon--disabled).devui-icon__container{background-color:var(--devui-icon-background-active, var(--devui-list-item-active-bg, #f2f5fc))}.devui-icon--operable:active:not(.devui-icon--disabled) i{color:var(--devui-icon-active-color, var(--devui-icon-fill-active, #252b3a))}.devui-icon--operable.devui-icon__container{height:32px;line-height:32px;padding:0 8px;margin-left:-8px;border-radius:var(--devui-border-radius, 2px);transition:all var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1))}.devui-icon--spin{animation:iconSpin 2.5s linear infinite}.devui-svg-icon{vertical-align:middle}@keyframes iconSpin{0%{transform:rotate(0)}50%{transform:rotate(180deg)}to{transform:rotate(360deg)}}.devui-result{display:flex;justify-content:center;align-items:center;flex-direction:column;text-align:center;box-sizing:border-box;padding:30px}.devui-result__icon-success:before{color:var(--devui-success, #50d4ab)}.devui-result__icon-danger:before{color:var(--devui-danger, #f66f6a)}.devui-result__icon-warning:before{color:var(--devui-warning, #fac20a)}.devui-result__icon-info:before{color:var(--devui-info, #5e7ce0)}.devui-result__title{margin-top:20px;color:var(--devui-text, #252b3a);font-size:var(--devui-font-size-lg, 14px)}.devui-result__desc{margin-top:10px;color:var(--devui-text-weak, #575d6c);font-size:var(--devui-font-size-md, 14px)}.devui-result__extra{margin-top:30px}
|