bge-ui 1.2.1 → 1.2.2
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/dist/index.js +2 -2
- package/dist/style.css +5 -6
- package/package.json +1 -1
- package/src/button/index.vue +1 -0
- package/src/dialog/index.vue +1 -1
- package/src/slider/index.vue +5 -7
package/dist/index.js
CHANGED
|
@@ -10625,8 +10625,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
10625
10625
|
function setPosition(percent) {
|
|
10626
10626
|
state.sliderBarStyle = `width: ${percent}%`;
|
|
10627
10627
|
state.sliderButtonStyle = `left: ${percent}%`;
|
|
10628
|
-
state.stopValue =
|
|
10629
|
-
state.newValue =
|
|
10628
|
+
state.stopValue = Math.floor(percent / 100 * (Object.values(props.marks).length - 1));
|
|
10629
|
+
state.newValue = Math.floor(percent);
|
|
10630
10630
|
emit("input", state.newValue);
|
|
10631
10631
|
emit("update:modelValue", state.newValue);
|
|
10632
10632
|
setTimeout(() => {
|
package/dist/style.css
CHANGED
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
border-radius: var(--radius-small, 4px);
|
|
6
6
|
padding: 8px 16px;
|
|
7
7
|
font-size: 14px;
|
|
8
|
+
line-height: 24px;
|
|
8
9
|
font-weight: 500;
|
|
9
10
|
border: none;
|
|
10
11
|
outline: none;
|
|
@@ -1006,7 +1007,7 @@ to {
|
|
|
1006
1007
|
top: 50%;
|
|
1007
1008
|
transform: translate(-50%, -50%);
|
|
1008
1009
|
height: 160px;
|
|
1009
|
-
padding:
|
|
1010
|
+
padding: 16px 0;
|
|
1010
1011
|
overflow: hidden;
|
|
1011
1012
|
}
|
|
1012
1013
|
.bge-dialog .bge-dialog__header {
|
|
@@ -1453,11 +1454,11 @@ to {
|
|
|
1453
1454
|
position: absolute;
|
|
1454
1455
|
}
|
|
1455
1456
|
.bge-slider .bge-slider__runway .slider-button-wrapper {
|
|
1456
|
-
height:
|
|
1457
|
-
width:
|
|
1457
|
+
height: 14px;
|
|
1458
|
+
width: 14px;
|
|
1458
1459
|
position: absolute;
|
|
1459
1460
|
z-index: 100;
|
|
1460
|
-
top: -
|
|
1461
|
+
top: -7px;
|
|
1461
1462
|
transform: translateX(-50%);
|
|
1462
1463
|
background-color: transparent;
|
|
1463
1464
|
text-align: center;
|
|
@@ -1470,13 +1471,11 @@ to {
|
|
|
1470
1471
|
.bge-slider .bge-slider__runway .slider-button-wrapper .slider-button {
|
|
1471
1472
|
background: var(--bg-slider-selected, #4F5C71);
|
|
1472
1473
|
position: relative;
|
|
1473
|
-
top: 6px;
|
|
1474
1474
|
width: 14px;
|
|
1475
1475
|
height: 14px;
|
|
1476
1476
|
border-radius: 50%;
|
|
1477
1477
|
transition: 0.2s;
|
|
1478
1478
|
user-select: none;
|
|
1479
|
-
vertical-align: middle;
|
|
1480
1479
|
display: inline-block;
|
|
1481
1480
|
}
|
|
1482
1481
|
.bge-slider .bge-slider__runway .slider-button-wrapper .slider-button:hover {
|
package/package.json
CHANGED
package/src/button/index.vue
CHANGED
package/src/dialog/index.vue
CHANGED
package/src/slider/index.vue
CHANGED
|
@@ -146,8 +146,8 @@ const tooltip = ref()
|
|
|
146
146
|
function setPosition (percent: any) {
|
|
147
147
|
state.sliderBarStyle = `width: ${percent}%`
|
|
148
148
|
state.sliderButtonStyle = `left: ${percent}%`
|
|
149
|
-
state.stopValue =
|
|
150
|
-
state.newValue =
|
|
149
|
+
state.stopValue = Math.floor(percent / 100 * (Object.values(props.marks).length - 1))
|
|
150
|
+
state.newValue = Math.floor(percent)
|
|
151
151
|
emit('input', state.newValue)
|
|
152
152
|
emit('update:modelValue', state.newValue)
|
|
153
153
|
setTimeout(() => {
|
|
@@ -189,11 +189,11 @@ watch(() => props.modelValue, (val: number) => {
|
|
|
189
189
|
}
|
|
190
190
|
|
|
191
191
|
.slider-button-wrapper {
|
|
192
|
-
height:
|
|
193
|
-
width:
|
|
192
|
+
height: 14px;
|
|
193
|
+
width: 14px;
|
|
194
194
|
position: absolute;
|
|
195
195
|
z-index: 100;
|
|
196
|
-
top: -
|
|
196
|
+
top: -7px;
|
|
197
197
|
transform: translateX(-50%);
|
|
198
198
|
background-color: transparent;
|
|
199
199
|
text-align: center;
|
|
@@ -207,13 +207,11 @@ watch(() => props.modelValue, (val: number) => {
|
|
|
207
207
|
// border: solid 4px rgba(255, 214, 51, 0.16);
|
|
208
208
|
background: var(--bg-slider-selected, #4F5C71);
|
|
209
209
|
position: relative;
|
|
210
|
-
top: 6px;
|
|
211
210
|
width: 14px;
|
|
212
211
|
height: 14px;
|
|
213
212
|
border-radius: 50%;
|
|
214
213
|
transition: 0.2s;
|
|
215
214
|
user-select: none;
|
|
216
|
-
vertical-align: middle;
|
|
217
215
|
display: inline-block;
|
|
218
216
|
|
|
219
217
|
&:hover {
|