vxe-pc-ui 3.17.20 → 3.17.21
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/icon/style.css +1 -1
- package/es/slider/src/slider.js +189 -80
- package/es/slider/style.css +8 -15
- package/es/slider/style.min.css +1 -1
- package/es/space/src/space.js +34 -12
- package/es/space/style.css +1 -0
- package/es/space/style.min.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/es/vxe-slider/style.css +8 -15
- package/es/vxe-slider/style.min.css +1 -1
- package/es/vxe-space/style.css +1 -0
- package/es/vxe-space/style.min.css +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +250 -105
- package/lib/index.umd.min.js +1 -1
- package/lib/slider/src/slider.js +204 -87
- package/lib/slider/src/slider.min.js +1 -1
- package/lib/slider/style/style.css +8 -15
- package/lib/slider/style/style.min.css +1 -1
- package/lib/space/src/space.js +40 -13
- package/lib/space/src/space.min.js +1 -1
- package/lib/space/style/style.css +1 -0
- package/lib/space/style/style.min.css +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/vxe-slider/style/style.css +8 -15
- package/lib/vxe-slider/style/style.min.css +1 -1
- package/lib/vxe-space/style/style.css +1 -0
- package/lib/vxe-space/style/style.min.css +1 -1
- package/package.json +2 -2
- package/packages/slider/src/slider.ts +187 -79
- package/packages/space/src/space.ts +39 -12
- package/styles/components/slider.scss +8 -13
- package/styles/components/space.scss +1 -0
- package/types/components/slider.d.ts +9 -2
- package/types/components/space.d.ts +2 -0
- /package/es/icon/{iconfont.1787911531497.ttf → iconfont.1787994741699.ttf} +0 -0
- /package/es/icon/{iconfont.1787911531497.woff → iconfont.1787994741699.woff} +0 -0
- /package/es/icon/{iconfont.1787911531497.woff2 → iconfont.1787994741699.woff2} +0 -0
- /package/es/{iconfont.1787911531497.ttf → iconfont.1787994741699.ttf} +0 -0
- /package/es/{iconfont.1787911531497.woff → iconfont.1787994741699.woff} +0 -0
- /package/es/{iconfont.1787911531497.woff2 → iconfont.1787994741699.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1787911531497.ttf → iconfont.1787994741699.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1787911531497.woff → iconfont.1787994741699.woff} +0 -0
- /package/lib/icon/style/{iconfont.1787911531497.woff2 → iconfont.1787994741699.woff2} +0 -0
- /package/lib/{iconfont.1787911531497.ttf → iconfont.1787994741699.ttf} +0 -0
- /package/lib/{iconfont.1787911531497.woff → iconfont.1787994741699.woff} +0 -0
- /package/lib/{iconfont.1787911531497.woff2 → iconfont.1787994741699.woff2} +0 -0
|
@@ -41,6 +41,10 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
41
41
|
separator: {
|
|
42
42
|
type: String as PropType<VxeSpacePropTypes.Separator>,
|
|
43
43
|
default: () => getConfig().space.separator
|
|
44
|
+
},
|
|
45
|
+
align: {
|
|
46
|
+
type: String as PropType<VxeSpacePropTypes.Align>,
|
|
47
|
+
default: () => getConfig().space.align
|
|
44
48
|
}
|
|
45
49
|
},
|
|
46
50
|
data () {
|
|
@@ -62,7 +66,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
62
66
|
const $xeSpace = this
|
|
63
67
|
const props = $xeSpace
|
|
64
68
|
|
|
65
|
-
const { gap } = props
|
|
69
|
+
const { align, gap } = props
|
|
66
70
|
const stys: VxeComponentStyleType = {}
|
|
67
71
|
let rowGap: string | number = ''
|
|
68
72
|
let columGap: string | number = ''
|
|
@@ -78,6 +82,9 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
78
82
|
columGap = gap.columGap || ''
|
|
79
83
|
}
|
|
80
84
|
}
|
|
85
|
+
if (align) {
|
|
86
|
+
stys['align-items'] = align
|
|
87
|
+
}
|
|
81
88
|
if (!eqEmptyValue(rowGap)) {
|
|
82
89
|
stys['--vxe-ui-space-current-row-gap'] = toCssUnit(rowGap)
|
|
83
90
|
}
|
|
@@ -99,15 +106,42 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
99
106
|
//
|
|
100
107
|
// Render
|
|
101
108
|
//
|
|
102
|
-
|
|
109
|
+
renderItems (h: CreateElement) {
|
|
103
110
|
const $xeSpace = this
|
|
104
111
|
const props = $xeSpace
|
|
105
112
|
const slots = $xeSpace.$scopedSlots
|
|
106
113
|
|
|
107
|
-
const {
|
|
114
|
+
const { separator, itemClassName } = props
|
|
115
|
+
const itemVNs: VNode[] = []
|
|
116
|
+
const defaultSlot = slots.default
|
|
117
|
+
const separatorSlot = slots.separator
|
|
118
|
+
if (defaultSlot) {
|
|
119
|
+
XEUtils.each(defaultSlot({}), (itemVN, index, items) => {
|
|
120
|
+
itemVNs.push(
|
|
121
|
+
h('div', {
|
|
122
|
+
key: 'i' + index,
|
|
123
|
+
class: ['vxe-space--item', getPropClass(itemClassName, { index })]
|
|
124
|
+
}, [itemVN])
|
|
125
|
+
)
|
|
126
|
+
if ((separator || separatorSlot) && index < items.length - 1) {
|
|
127
|
+
itemVNs.push(
|
|
128
|
+
h('div', {
|
|
129
|
+
key: 's' + index,
|
|
130
|
+
class: 'vxe-space--separator'
|
|
131
|
+
}, separatorSlot ? separatorSlot({}) : ('' + separator))
|
|
132
|
+
)
|
|
133
|
+
}
|
|
134
|
+
})
|
|
135
|
+
}
|
|
136
|
+
return itemVNs
|
|
137
|
+
},
|
|
138
|
+
renderVN (h: CreateElement): VNode {
|
|
139
|
+
const $xeSpace = this
|
|
140
|
+
const props = $xeSpace
|
|
141
|
+
|
|
142
|
+
const { vertical, wrap, className } = props
|
|
108
143
|
const wrapperStyle = $xeSpace.computeWrapperStyle
|
|
109
144
|
const vSize = $xeSpace.computeSize
|
|
110
|
-
const defaultSlot = slots.default
|
|
111
145
|
return h('div', {
|
|
112
146
|
ref: 'refElem',
|
|
113
147
|
class: ['vxe-space', getPropClass(className, {}), {
|
|
@@ -116,14 +150,7 @@ export default /* define-vxe-component start */ defineVxeComponent({
|
|
|
116
150
|
'is--vertical': vertical
|
|
117
151
|
}],
|
|
118
152
|
style: wrapperStyle
|
|
119
|
-
},
|
|
120
|
-
? (defaultSlot({}) || []).map((itemVN, index) => {
|
|
121
|
-
return h('div', {
|
|
122
|
-
key: index,
|
|
123
|
-
class: ['vxe-space--item', getPropClass(itemClassName, { index })]
|
|
124
|
-
}, [itemVN])
|
|
125
|
-
})
|
|
126
|
-
: [])
|
|
153
|
+
}, $xeSpace.renderItems(h))
|
|
127
154
|
}
|
|
128
155
|
},
|
|
129
156
|
render (this: any, h) {
|
|
@@ -50,7 +50,7 @@ $sliderThemeList: (
|
|
|
50
50
|
.vxe-slider {
|
|
51
51
|
position: relative;
|
|
52
52
|
display: block;
|
|
53
|
-
padding: 0.
|
|
53
|
+
padding: 0.8em;
|
|
54
54
|
@for $index from 0 to list.length($sliderThemeList) {
|
|
55
55
|
$item: list.nth($sliderThemeList, $index + 1);
|
|
56
56
|
&.theme--#{map.get($item, name)} {
|
|
@@ -80,10 +80,10 @@ $sliderThemeList: (
|
|
|
80
80
|
}
|
|
81
81
|
.vxe-slider--bar-btn {
|
|
82
82
|
&:hover {
|
|
83
|
-
transform: scale(1.2);
|
|
83
|
+
transform: translate(-50%, -50%) scale(1.2);
|
|
84
84
|
}
|
|
85
85
|
&:active {
|
|
86
|
-
transform: scale(1.1);
|
|
86
|
+
transform: translate(-50%, -50%) scale(1.1);
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
}
|
|
@@ -122,19 +122,14 @@ $sliderThemeList: (
|
|
|
122
122
|
|
|
123
123
|
.vxe-slider--bar-btn {
|
|
124
124
|
position: absolute;
|
|
125
|
-
width:
|
|
126
|
-
height:
|
|
127
|
-
top:
|
|
125
|
+
width: 1.2em;
|
|
126
|
+
height: 1.2em;
|
|
127
|
+
top: 50%;
|
|
128
|
+
transform: translate(-50%, -50%);
|
|
128
129
|
border-radius: 50%;
|
|
129
|
-
border:
|
|
130
|
+
border: 2px solid var(--vxe-ui-font-primary-color);
|
|
130
131
|
background-color: #fff;
|
|
131
132
|
cursor: pointer;
|
|
132
133
|
z-index: 1;
|
|
133
134
|
@include baseMixin.createAnimationTransition(transform, 0.1s);
|
|
134
|
-
}
|
|
135
|
-
.vxe-slider--start-btn {
|
|
136
|
-
left: -0.45em;
|
|
137
|
-
}
|
|
138
|
-
.vxe-slider--end-btn {
|
|
139
|
-
right: -0.45em;
|
|
140
135
|
}
|
|
@@ -19,6 +19,8 @@ export interface VxeSliderPrivateRef extends SliderPrivateRef { }
|
|
|
19
19
|
export namespace VxeSliderPropTypes {
|
|
20
20
|
export type Size = VxeComponentSizeType
|
|
21
21
|
export type ModelValue = number | string | null | (number | string | null)[]
|
|
22
|
+
export type StartValue = number | string | null
|
|
23
|
+
export type EndValue = number | string | null
|
|
22
24
|
export type Max = number | string
|
|
23
25
|
export type Min = number | string
|
|
24
26
|
export type Vertical = boolean
|
|
@@ -33,6 +35,8 @@ export namespace VxeSliderPropTypes {
|
|
|
33
35
|
export interface VxeSliderProps {
|
|
34
36
|
size?: VxeSliderPropTypes.Size
|
|
35
37
|
value?: VxeSliderPropTypes.ModelValue
|
|
38
|
+
startValue?: VxeSliderPropTypes.StartValue
|
|
39
|
+
endValue?: VxeSliderPropTypes.EndValue
|
|
36
40
|
max?: VxeSliderPropTypes.Max
|
|
37
41
|
min?: VxeSliderPropTypes.Min
|
|
38
42
|
vertical?: VxeSliderPropTypes.Vertical
|
|
@@ -49,11 +53,12 @@ export interface SliderPrivateComputed {
|
|
|
49
53
|
export interface VxeSliderPrivateComputed extends SliderPrivateComputed { }
|
|
50
54
|
|
|
51
55
|
export interface SliderReactData {
|
|
52
|
-
startValue: number
|
|
53
|
-
endValue: number
|
|
54
56
|
}
|
|
55
57
|
export interface SliderInternalData {
|
|
56
58
|
_isUp?: boolean
|
|
59
|
+
currValue: number
|
|
60
|
+
startValue: number
|
|
61
|
+
endValue: number
|
|
57
62
|
}
|
|
58
63
|
|
|
59
64
|
export interface SliderMethods {
|
|
@@ -65,6 +70,8 @@ export interface VxeSliderPrivateMethods extends SliderPrivateMethods { }
|
|
|
65
70
|
|
|
66
71
|
export type VxeSliderEmits = [
|
|
67
72
|
'modelValue',
|
|
73
|
+
'update:startValue',
|
|
74
|
+
'update:endValue',
|
|
68
75
|
'change',
|
|
69
76
|
'track-dragstart',
|
|
70
77
|
'track-dragover',
|
|
@@ -23,6 +23,7 @@ export namespace VxeSpacePropTypes {
|
|
|
23
23
|
export type ClassName = string
|
|
24
24
|
export type ItemClassName = string
|
|
25
25
|
export type Separator = string
|
|
26
|
+
export type Align = 'stretch' | 'start' | 'end' | 'center' | 'baseline' | '' | null
|
|
26
27
|
}
|
|
27
28
|
|
|
28
29
|
export interface VxeSpaceProps {
|
|
@@ -45,6 +46,7 @@ export interface VxeSpaceProps {
|
|
|
45
46
|
* 分隔符
|
|
46
47
|
*/
|
|
47
48
|
separator?: VxeSpacePropTypes.Separator
|
|
49
|
+
align?: VxeSpacePropTypes.Align
|
|
48
50
|
}
|
|
49
51
|
|
|
50
52
|
export interface SpacePrivateComputed {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|