@varlet/ui 2.7.4-alpha.1675865250542 → 2.7.5
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/es/card/Card.mjs +7 -2
- package/es/chip/Chip.mjs +9 -3
- package/es/col/Col.mjs +7 -2
- package/es/image/Image.mjs +8 -3
- package/es/index.bundle.mjs +1 -1
- package/es/index.mjs +1 -1
- package/es/picker/Picker.mjs +4 -3
- package/es/row/Row.mjs +8 -3
- package/es/snackbar/style/index.mjs +1 -1
- package/es/varlet.esm.js +1031 -1015
- package/highlight/web-types.en-US.json +2 -2
- package/highlight/web-types.zh-CN.json +2 -2
- package/lib/varlet.cjs.js +36 -15
- package/package.json +5 -5
- package/types/snackbar.d.ts +0 -1
- package/umd/varlet.js +6 -6
package/es/card/Card.mjs
CHANGED
|
@@ -36,7 +36,7 @@ function __render__(_ctx, _cache) {
|
|
|
36
36
|
zIndex: _ctx.floated ? _ctx.zIndex : undefined
|
|
37
37
|
}),
|
|
38
38
|
onClick: _cache[0] || (_cache[0] = function () {
|
|
39
|
-
return _ctx.
|
|
39
|
+
return _ctx.handleClick && _ctx.handleClick(...arguments);
|
|
40
40
|
})
|
|
41
41
|
}, [_createElementVNode("div", {
|
|
42
42
|
ref: "cardFloater",
|
|
@@ -246,6 +246,10 @@ var __sfc__ = defineComponent({
|
|
|
246
246
|
call(props['onUpdate:floating'], false);
|
|
247
247
|
};
|
|
248
248
|
|
|
249
|
+
var handleClick = e => {
|
|
250
|
+
call(props.onClick, e);
|
|
251
|
+
};
|
|
252
|
+
|
|
249
253
|
watch(() => props.floating, value => {
|
|
250
254
|
if (isRow.value) return;
|
|
251
255
|
nextTick(() => {
|
|
@@ -275,7 +279,8 @@ var __sfc__ = defineComponent({
|
|
|
275
279
|
isRow,
|
|
276
280
|
close,
|
|
277
281
|
showFloatingButtons,
|
|
278
|
-
floated
|
|
282
|
+
floated,
|
|
283
|
+
handleClick
|
|
279
284
|
};
|
|
280
285
|
}
|
|
281
286
|
|
package/es/chip/Chip.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import VarIcon from '../icon/index.mjs';
|
|
2
2
|
import { defineComponent, computed } from 'vue';
|
|
3
3
|
import { props } from './props.mjs';
|
|
4
|
-
import { createNamespace } from '../utils/components.mjs';
|
|
4
|
+
import { call, createNamespace } from '../utils/components.mjs';
|
|
5
5
|
var {
|
|
6
6
|
n,
|
|
7
7
|
classes
|
|
@@ -25,7 +25,7 @@ function __render__(_ctx, _cache) {
|
|
|
25
25
|
key: 0,
|
|
26
26
|
class: _normalizeClass(_ctx.n('--close')),
|
|
27
27
|
onClick: _cache[0] || (_cache[0] = function () {
|
|
28
|
-
return _ctx.
|
|
28
|
+
return _ctx.handleClose && _ctx.handleClose(...arguments);
|
|
29
29
|
})
|
|
30
30
|
}, [_createVNode(_component_var_icon, {
|
|
31
31
|
name: "" + (_ctx.iconName ? _ctx.iconName : 'close-circle')
|
|
@@ -85,11 +85,17 @@ var __sfc__ = defineComponent({
|
|
|
85
85
|
var roundClass = round ? n('--round') : null;
|
|
86
86
|
return [n("--" + size), blockClass, plainTypeClass, roundClass];
|
|
87
87
|
});
|
|
88
|
+
|
|
89
|
+
var handleClose = e => {
|
|
90
|
+
call(props.onClose, e);
|
|
91
|
+
};
|
|
92
|
+
|
|
88
93
|
return {
|
|
89
94
|
n,
|
|
90
95
|
classes,
|
|
91
96
|
chipStyles,
|
|
92
|
-
contentClass
|
|
97
|
+
contentClass,
|
|
98
|
+
handleClose
|
|
93
99
|
};
|
|
94
100
|
}
|
|
95
101
|
|
package/es/col/Col.mjs
CHANGED
|
@@ -19,7 +19,7 @@ function __render__(_ctx, _cache) {
|
|
|
19
19
|
paddingRight: _ctx.toSizeUnit(_ctx.padding.right)
|
|
20
20
|
}),
|
|
21
21
|
onClick: _cache[0] || (_cache[0] = function () {
|
|
22
|
-
return _ctx.
|
|
22
|
+
return _ctx.handleClick && _ctx.handleClick(...arguments);
|
|
23
23
|
})
|
|
24
24
|
}, [_renderSlot(_ctx.$slots, "default")], 6
|
|
25
25
|
/* CLASS, STYLE */
|
|
@@ -69,6 +69,10 @@ var __sfc__ = defineComponent({
|
|
|
69
69
|
return classes;
|
|
70
70
|
};
|
|
71
71
|
|
|
72
|
+
var handleClick = e => {
|
|
73
|
+
call(props.onClick, e);
|
|
74
|
+
};
|
|
75
|
+
|
|
72
76
|
watch([() => props.span, () => props.offset], () => {
|
|
73
77
|
row == null ? void 0 : row.computePadding();
|
|
74
78
|
});
|
|
@@ -81,7 +85,8 @@ var __sfc__ = defineComponent({
|
|
|
81
85
|
toSizeUnit,
|
|
82
86
|
getSize,
|
|
83
87
|
span,
|
|
84
|
-
offset
|
|
88
|
+
offset,
|
|
89
|
+
handleClick
|
|
85
90
|
};
|
|
86
91
|
}
|
|
87
92
|
|
package/es/image/Image.mjs
CHANGED
|
@@ -44,7 +44,7 @@ function __render__(_ctx, _cache) {
|
|
|
44
44
|
return _ctx.handleError && _ctx.handleError(...arguments);
|
|
45
45
|
}),
|
|
46
46
|
onClick: _cache[2] || (_cache[2] = function () {
|
|
47
|
-
return _ctx.
|
|
47
|
+
return _ctx.handleClick && _ctx.handleClick(...arguments);
|
|
48
48
|
})
|
|
49
49
|
}, null, 46
|
|
50
50
|
/* CLASS, STYLE, PROPS, HYDRATE_EVENTS */
|
|
@@ -64,7 +64,7 @@ function __render__(_ctx, _cache) {
|
|
|
64
64
|
return _ctx.handleError && _ctx.handleError(...arguments);
|
|
65
65
|
}),
|
|
66
66
|
onClick: _cache[5] || (_cache[5] = function () {
|
|
67
|
-
return _ctx.
|
|
67
|
+
return _ctx.handleClick && _ctx.handleClick(...arguments);
|
|
68
68
|
})
|
|
69
69
|
}, null, 46
|
|
70
70
|
/* CLASS, STYLE, PROPS, HYDRATE_EVENTS */
|
|
@@ -108,12 +108,17 @@ var __sfc__ = defineComponent({
|
|
|
108
108
|
!lazy && call(onError, e);
|
|
109
109
|
};
|
|
110
110
|
|
|
111
|
+
var handleClick = e => {
|
|
112
|
+
call(props.onClick, e);
|
|
113
|
+
};
|
|
114
|
+
|
|
111
115
|
return {
|
|
112
116
|
n,
|
|
113
117
|
classes,
|
|
114
118
|
toSizeUnit,
|
|
115
119
|
handleLoad,
|
|
116
|
-
handleError
|
|
120
|
+
handleError,
|
|
121
|
+
handleClick
|
|
117
122
|
};
|
|
118
123
|
}
|
|
119
124
|
|
package/es/index.bundle.mjs
CHANGED
|
@@ -217,7 +217,7 @@ import './time-picker/style/index.mjs'
|
|
|
217
217
|
import './tooltip/style/index.mjs'
|
|
218
218
|
import './uploader/style/index.mjs'
|
|
219
219
|
|
|
220
|
-
const version = '2.7.
|
|
220
|
+
const version = '2.7.5'
|
|
221
221
|
|
|
222
222
|
function install(app) {
|
|
223
223
|
ActionSheet.install && app.use(ActionSheet)
|
package/es/index.mjs
CHANGED
|
@@ -144,7 +144,7 @@ export * from './time-picker/index.mjs'
|
|
|
144
144
|
export * from './tooltip/index.mjs'
|
|
145
145
|
export * from './uploader/index.mjs'
|
|
146
146
|
|
|
147
|
-
const version = '2.7.
|
|
147
|
+
const version = '2.7.5'
|
|
148
148
|
|
|
149
149
|
function install(app) {
|
|
150
150
|
ActionSheet.install && app.use(ActionSheet)
|
package/es/picker/Picker.mjs
CHANGED
|
@@ -14,7 +14,7 @@ var {
|
|
|
14
14
|
var MOMENTUM_RECORD_TIME = 300;
|
|
15
15
|
var MOMENTUM_ALLOW_DISTANCE = 15;
|
|
16
16
|
var sid = 0;
|
|
17
|
-
import { renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, resolveComponent as _resolveComponent, normalizeClass as _normalizeClass, withCtx as _withCtx, createVNode as _createVNode, createElementVNode as _createElementVNode,
|
|
17
|
+
import { renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, resolveComponent as _resolveComponent, normalizeClass as _normalizeClass, withCtx as _withCtx, createVNode as _createVNode, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, renderList as _renderList, Fragment as _Fragment, normalizeStyle as _normalizeStyle, withModifiers as _withModifiers, mergeProps as _mergeProps, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from "vue";
|
|
18
18
|
|
|
19
19
|
var _withScopeId = n => (_pushScopeId(""), n = n(), _popScopeId(), n);
|
|
20
20
|
|
|
@@ -42,7 +42,8 @@ function __render__(_ctx, _cache) {
|
|
|
42
42
|
}), {
|
|
43
43
|
default: _withCtx(() => [_createElementVNode("div", _mergeProps({
|
|
44
44
|
class: _ctx.n()
|
|
45
|
-
}, _ctx.$attrs), [
|
|
45
|
+
}, _ctx.$attrs), [_ctx.toolbar ? (_openBlock(), _createElementBlock("div", {
|
|
46
|
+
key: 0,
|
|
46
47
|
class: _normalizeClass(_ctx.n('toolbar'))
|
|
47
48
|
}, [_renderSlot(_ctx.$slots, "cancel", {}, () => [_createVNode(_component_var_button, {
|
|
48
49
|
class: _normalizeClass(_ctx.n('cancel-button')),
|
|
@@ -80,7 +81,7 @@ function __render__(_ctx, _cache) {
|
|
|
80
81
|
/* PROPS */
|
|
81
82
|
, ["class", "text-color", "onClick"])])], 2
|
|
82
83
|
/* CLASS */
|
|
83
|
-
), _createElementVNode("div", {
|
|
84
|
+
)) : _createCommentVNode("v-if", true), _createElementVNode("div", {
|
|
84
85
|
class: _normalizeClass(_ctx.n('columns')),
|
|
85
86
|
style: _normalizeStyle({
|
|
86
87
|
height: _ctx.columnHeight + "px"
|
package/es/row/Row.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import { defineComponent, computed, watch } from 'vue';
|
|
|
2
2
|
import { props } from './props.mjs';
|
|
3
3
|
import { useCols } from './provide.mjs';
|
|
4
4
|
import { toPxNum } from '../utils/elements.mjs';
|
|
5
|
-
import { createNamespace } from '../utils/components.mjs';
|
|
5
|
+
import { call, createNamespace } from '../utils/components.mjs';
|
|
6
6
|
var {
|
|
7
7
|
n,
|
|
8
8
|
classes
|
|
@@ -18,7 +18,7 @@ function __render__(_ctx, _cache) {
|
|
|
18
18
|
margin: _ctx.average ? "0 -" + _ctx.average + "px" : undefined
|
|
19
19
|
}),
|
|
20
20
|
onClick: _cache[0] || (_cache[0] = function () {
|
|
21
|
-
return _ctx.
|
|
21
|
+
return _ctx.handleClick && _ctx.handleClick(...arguments);
|
|
22
22
|
})
|
|
23
23
|
}, [_renderSlot(_ctx.$slots, "default")], 6
|
|
24
24
|
/* CLASS, STYLE */
|
|
@@ -49,6 +49,10 @@ var __sfc__ = defineComponent({
|
|
|
49
49
|
});
|
|
50
50
|
};
|
|
51
51
|
|
|
52
|
+
var handleClick = e => {
|
|
53
|
+
call(props.onClick, e);
|
|
54
|
+
};
|
|
55
|
+
|
|
52
56
|
var rowProvider = {
|
|
53
57
|
computePadding
|
|
54
58
|
};
|
|
@@ -58,7 +62,8 @@ var __sfc__ = defineComponent({
|
|
|
58
62
|
return {
|
|
59
63
|
n,
|
|
60
64
|
classes,
|
|
61
|
-
average
|
|
65
|
+
average,
|
|
66
|
+
handleClick
|
|
62
67
|
};
|
|
63
68
|
}
|
|
64
69
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import '../../styles/common.css'
|
|
2
|
-
import '../SnackbarSfc.css'
|
|
3
2
|
import '../../styles/elevation.css'
|
|
4
3
|
import '../../loading/loading.css'
|
|
5
4
|
import '../../button/button.css'
|
|
6
5
|
import '../../icon/icon.css'
|
|
7
6
|
import '../snackbar.css'
|
|
8
7
|
import '../coreSfc.css'
|
|
8
|
+
import '../SnackbarSfc.css'
|