@creatorsn/vfluent3 0.3.95 → 0.3.97
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.
|
@@ -15,6 +15,7 @@ export declare const FvSlider: import("../../types/plugins/component-plugin").Co
|
|
|
15
15
|
readonly maxinum?: number | undefined;
|
|
16
16
|
readonly mininum?: number | undefined;
|
|
17
17
|
readonly showLabel?: boolean | undefined;
|
|
18
|
+
readonly scaleColor?: string | undefined;
|
|
18
19
|
readonly iconWrapperBackground?: string | undefined;
|
|
19
20
|
};
|
|
20
21
|
}, {
|
|
@@ -79,6 +80,7 @@ export declare const FvSlider: import("../../types/plugins/component-plugin").Co
|
|
|
79
80
|
readonly maxinum?: number | undefined;
|
|
80
81
|
readonly mininum?: number | undefined;
|
|
81
82
|
readonly showLabel?: boolean | undefined;
|
|
83
|
+
readonly scaleColor?: string | undefined;
|
|
82
84
|
readonly iconWrapperBackground?: string | undefined;
|
|
83
85
|
};
|
|
84
86
|
}, {
|
|
@@ -140,6 +142,7 @@ export declare const FvSlider: import("../../types/plugins/component-plugin").Co
|
|
|
140
142
|
readonly maxinum?: number | undefined;
|
|
141
143
|
readonly mininum?: number | undefined;
|
|
142
144
|
readonly showLabel?: boolean | undefined;
|
|
145
|
+
readonly scaleColor?: string | undefined;
|
|
143
146
|
readonly iconWrapperBackground?: string | undefined;
|
|
144
147
|
};
|
|
145
148
|
}, {
|
|
@@ -14,6 +14,7 @@ declare const _default: {
|
|
|
14
14
|
readonly maxinum?: number | undefined;
|
|
15
15
|
readonly mininum?: number | undefined;
|
|
16
16
|
readonly showLabel?: boolean | undefined;
|
|
17
|
+
readonly scaleColor?: string | undefined;
|
|
17
18
|
readonly iconWrapperBackground?: string | undefined;
|
|
18
19
|
};
|
|
19
20
|
}, {
|
|
@@ -78,6 +79,7 @@ declare const _default: {
|
|
|
78
79
|
readonly maxinum?: number | undefined;
|
|
79
80
|
readonly mininum?: number | undefined;
|
|
80
81
|
readonly showLabel?: boolean | undefined;
|
|
82
|
+
readonly scaleColor?: string | undefined;
|
|
81
83
|
readonly iconWrapperBackground?: string | undefined;
|
|
82
84
|
};
|
|
83
85
|
}, {
|
|
@@ -139,6 +141,7 @@ declare const _default: {
|
|
|
139
141
|
readonly maxinum?: number | undefined;
|
|
140
142
|
readonly mininum?: number | undefined;
|
|
141
143
|
readonly showLabel?: boolean | undefined;
|
|
144
|
+
readonly scaleColor?: string | undefined;
|
|
142
145
|
readonly iconWrapperBackground?: string | undefined;
|
|
143
146
|
};
|
|
144
147
|
}, {
|
package/dist/vfluent3.js
CHANGED
|
@@ -18674,7 +18674,11 @@ const Qv = ["title"], Zv = { class: "fv-slider-unit-container" }, eb = {
|
|
|
18674
18674
|
return e < this.mininum ? e = this.mininum : e > this.maxinum && (e = this.maxinum), e = parseFloat(e).toFixed(0), e;
|
|
18675
18675
|
},
|
|
18676
18676
|
setPos() {
|
|
18677
|
-
|
|
18677
|
+
const e = this.maxinum - this.mininum;
|
|
18678
|
+
if (e <= 0 || !this.btnEl.width || !this.barEl.width || this.vertical && !this.barEl.height)
|
|
18679
|
+
return;
|
|
18680
|
+
const i = (this.progress - this.mininum) / e;
|
|
18681
|
+
this.vertical ? this.currentTop = i * (this.barEl.height - this.btnEl.height) : this.currentLeft = i * (this.barEl.width - this.btnEl.width);
|
|
18678
18682
|
},
|
|
18679
18683
|
setProgress(e = !1) {
|
|
18680
18684
|
if (!e) {
|
|
@@ -18724,6 +18728,9 @@ const Qv = ["title"], Zv = { class: "fv-slider-unit-container" }, eb = {
|
|
|
18724
18728
|
type: [Boolean, Number],
|
|
18725
18729
|
default: !1
|
|
18726
18730
|
},
|
|
18731
|
+
scaleColor: {
|
|
18732
|
+
default: ""
|
|
18733
|
+
},
|
|
18727
18734
|
color: {
|
|
18728
18735
|
default: ""
|
|
18729
18736
|
},
|
|
@@ -18737,13 +18744,14 @@ const Qv = ["title"], Zv = { class: "fv-slider-unit-container" }, eb = {
|
|
|
18737
18744
|
setup(e, { emit: i }) {
|
|
18738
18745
|
return (t, s) => (p(), y("div", {
|
|
18739
18746
|
class: T(["fv-Slider", [t.$theme, { vertical: e.vertical }]]),
|
|
18740
|
-
ref: "slider"
|
|
18747
|
+
ref: "slider",
|
|
18748
|
+
style: v({ "--fv-slider-unit-color": e.scaleColor })
|
|
18741
18749
|
}, [
|
|
18742
18750
|
u("div", {
|
|
18743
18751
|
class: "fv-slider-main",
|
|
18744
18752
|
ref: "bar",
|
|
18745
18753
|
style: v({
|
|
18746
|
-
background: t.progress >=
|
|
18754
|
+
background: Number(t.progress) >= Number(e.maxinum) ? e.color : e.background || ""
|
|
18747
18755
|
})
|
|
18748
18756
|
}, [
|
|
18749
18757
|
u("div", {
|
|
@@ -18805,7 +18813,7 @@ const Qv = ["title"], Zv = { class: "fv-slider-unit-container" }, eb = {
|
|
|
18805
18813
|
}, null, 4))), 128))
|
|
18806
18814
|
])
|
|
18807
18815
|
], 4)
|
|
18808
|
-
],
|
|
18816
|
+
], 6));
|
|
18809
18817
|
}
|
|
18810
18818
|
}), ib = Z(tb);
|
|
18811
18819
|
const sb = {
|