lh-ui-next 0.2.1-beta.1 → 0.2.1-beta.11
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 +1 -1
- package/lib/css/dev.css +1 -1
- package/lib/lh-ui-next.mjs +54 -19
- package/lib/lh-ui-next.umd.js +1 -1
- package/package.json +1 -1
- package/static/css/lhseer/dom.less +7 -0
- package/static/css/package/checkbox.less +37 -5
- package/static/css/package/date.less +9 -0
- package/static/css/package/slider.less +17 -22
- package/static/css/theme-compact-blue/main.css +1 -1
- package/static/css/theme-compact-dark/main.css +1 -1
- package/static/css/theme-compact-dark/main.less +1 -1
- package/static/css/theme-compact-dark/theme-compact-blue-dark.less +4852 -0
- package/static/css/theme-loose-blue/main.css +1 -1
- package/static/css/theme-loose-orange/main.css +1 -1
- package/static/iconFontComponent/iconfont.css +566 -566
- package/static/iconFontComponent/iconfont.json +968 -968
- package/static/iconFontComponent/iconfont.svg +293 -293
- package/static/css/compact/dark.less +0 -173
package/README.md
CHANGED
|
@@ -5,7 +5,7 @@ alpha version is use to self-test; beta version is use to public survey.for exam
|
|
|
5
5
|
1.0.0-alpha.1
|
|
6
6
|
1.0.0-test.2
|
|
7
7
|
## Official version : "0.2.0",
|
|
8
|
-
## test version : "0.2.1-beta.
|
|
8
|
+
## test version : "0.2.1-beta.11,
|
|
9
9
|
## npmmirror
|
|
10
10
|
When cnpm sync execution is unsuccessful,you can go the website(http://www.npmmirror.com/package/lh-ui-next) and press sync button to
|
|
11
11
|
manual trigger the sync event
|
package/lib/css/dev.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;-webkit-tap-highlight-color:transparent;tap-highlight-color:transparent;outline:0}body,html{margin:0;max-height:100%;height:100%}body{overflow-y:hidden;width:100%;font-family:"Microsoft YaHei";font-size:12px}td,th{font-size:12px}img{width:auto;height:auto}a,a:focus,a:hover{text-decoration:none;outline:0}ul{margin:0;padding:0}li{list-style:none}button:focus{outline:0}select:focus{outline:0}::-ms-clear,::-ms-reveal{display:none}p{margin-block-start:0;margin-block-end:0}input{font-family:"Microsoft YaHei";-webkit-appearance:none;outline:0}input:focus{outline:0}textarea{font-family:"Microsoft YaHei";resize:none;padding:0}textarea:focus{outline:0;resize:none}pre{font-family:"Microsoft YaHei"}body,html{margin:0;max-height:100%;height:100%}body{overflow-y:hidden;width:100%;font-family:"Microsoft YaHei";font-size:12px}.pointer{cursor:pointer}#app{width:100%;height:100%;overflow-y:auto;background-color:#
|
|
1
|
+
*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;-webkit-tap-highlight-color:transparent;tap-highlight-color:transparent;outline:0}body,html{margin:0;max-height:100%;height:100%}body{overflow-y:hidden;width:100%;font-family:"Microsoft YaHei";font-size:12px}td,th{font-size:12px}img{width:auto;height:auto}a,a:focus,a:hover{text-decoration:none;outline:0}ul{margin:0;padding:0}li{list-style:none}button:focus{outline:0}select:focus{outline:0}::-ms-clear,::-ms-reveal{display:none}p{margin-block-start:0;margin-block-end:0}input{font-family:"Microsoft YaHei";-webkit-appearance:none;outline:0}input:focus{outline:0}textarea{font-family:"Microsoft YaHei";resize:none;padding:0}textarea:focus{outline:0;resize:none}pre{font-family:"Microsoft YaHei"}input[type=number]{-moz-appearance:textfield}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}body,html{margin:0;max-height:100%;height:100%}body{overflow-y:hidden;width:100%;font-family:"Microsoft YaHei";font-size:12px}.pointer{cursor:pointer}#app{width:100%;height:100%;overflow-y:auto;background-color:#f5f5f6}.date-picker-dialog{padding:16px}.date-picker-dialog .date-bordor{background:#fff;border:1px solid rgba(0,0,0,.15);opacity:1;border-radius:2px;padding:8px;position:relative}.date-picker-dialog .date-bordor .date-picker-left{width:80px;position:absolute;left:8px;top:1px}.date-picker-dialog .date-bordor .date-picker-right{width:100px;position:absolute;left:116px;top:1px}.date-picker-dialog .date-bordor .icon_component_date{color:rgba(0,0,0,.25);vertical-align:middle;font-size:14px}.date-picker-dialog .date-bordor .lh-input .lh-input-cornInput{border:none}.date-picker-dialog .date-bordor .lh-input__prefix{display:none}.date-picker-dialog .date-bordor .lh-input-cornInput{padding-left:8px}.date-picker-dialog .date-bordor .lh-input.is-prefix.mini .lh-input-cornInput{padding-left:8px}.date-picker-dialog .date-bordor .icon_component_arrow_right{color:rgba(0,0,0,.25);font-size:14px;vertical-align:middle}
|
package/lib/lh-ui-next.mjs
CHANGED
|
@@ -199,12 +199,7 @@ const kt = {
|
|
|
199
199
|
}, _t = ["type", "name", "placeholder", "required", "min", "max", "step", "pattern", "title", "minlength", "maxlength", "disabled", "readonly", "autofocus"], vt = ["title"], xt = ["title"];
|
|
200
200
|
function St(e, t, i, s, l, n) {
|
|
201
201
|
return r(), d("span", {
|
|
202
|
-
class: f(["lh-input", [
|
|
203
|
-
i.disabled ? "lh-input-disabled" : "",
|
|
204
|
-
i.size,
|
|
205
|
-
i.prefixIcon ? "is-prefix" : "",
|
|
206
|
-
i.suffixIcon ? "is-suffix" : ""
|
|
207
|
-
]])
|
|
202
|
+
class: f(["lh-input", [i.disabled ? "lh-input-disabled" : "", i.size, i.prefixIcon ? "is-prefix" : "", i.suffixIcon ? "is-suffix" : ""]])
|
|
208
203
|
}, [
|
|
209
204
|
v(h("input", {
|
|
210
205
|
class: "lh-input-cornInput",
|
|
@@ -1017,6 +1012,11 @@ const Ue = /* @__PURE__ */ x(Mt, [["render", Ft]]), Et = {
|
|
|
1017
1012
|
type: Boolean,
|
|
1018
1013
|
required: !1,
|
|
1019
1014
|
default: !0
|
|
1015
|
+
},
|
|
1016
|
+
//item点击之前的事件
|
|
1017
|
+
itemClickPreEvent: {
|
|
1018
|
+
type: [Function, String],
|
|
1019
|
+
default: ""
|
|
1020
1020
|
}
|
|
1021
1021
|
},
|
|
1022
1022
|
data() {
|
|
@@ -1114,7 +1114,7 @@ const Ue = /* @__PURE__ */ x(Mt, [["render", Ft]]), Et = {
|
|
|
1114
1114
|
},
|
|
1115
1115
|
//点击li的时候
|
|
1116
1116
|
itemClick(e) {
|
|
1117
|
-
if (e.disabled)
|
|
1117
|
+
if (e.disabled || typeof this.itemClickPreEvent == "function" && !this.itemClickPreEvent(e))
|
|
1118
1118
|
return !1;
|
|
1119
1119
|
this.selectType == 1 && (this.manualStatus = !1), this.changeClick(e.value), this.$emit("itemClick", e);
|
|
1120
1120
|
},
|
|
@@ -2389,6 +2389,11 @@ const Zi = {
|
|
|
2389
2389
|
indeterminate: {
|
|
2390
2390
|
type: Boolean,
|
|
2391
2391
|
default: !1
|
|
2392
|
+
},
|
|
2393
|
+
appearance: {
|
|
2394
|
+
type: String,
|
|
2395
|
+
default: "square"
|
|
2396
|
+
//square 正方形 circle圆圈
|
|
2392
2397
|
}
|
|
2393
2398
|
},
|
|
2394
2399
|
watch: {
|
|
@@ -2416,7 +2421,7 @@ const Zi = {
|
|
|
2416
2421
|
}, Qi = { class: "lh-checkbox-outbox" }, $i = ["disabled"], el = { class: "lh-checkbox-text" };
|
|
2417
2422
|
function tl(e, t, i, s, l, n) {
|
|
2418
2423
|
return r(), d("label", {
|
|
2419
|
-
class: f(["lh-checkbox", [i.size == "mini" ? "mini" : "", i.disabled ? "disabled" : "", l.myValue ? "checked" : ""]])
|
|
2424
|
+
class: f(["lh-checkbox", [i.size == "mini" ? "mini" : "", i.size == "big" ? "big" : "", i.disabled ? "disabled" : "", l.myValue ? "checked" : "", i.appearance]])
|
|
2420
2425
|
}, [
|
|
2421
2426
|
h("span", Qi, [
|
|
2422
2427
|
h("span", {
|
|
@@ -6419,11 +6424,21 @@ const ra = {
|
|
|
6419
6424
|
},
|
|
6420
6425
|
//改变年份
|
|
6421
6426
|
yearClick(e) {
|
|
6422
|
-
this.type === "year"
|
|
6427
|
+
if (this.type === "year") {
|
|
6428
|
+
if (this.yearDisable(e))
|
|
6429
|
+
return;
|
|
6430
|
+
this.showDate.year = e, this.selectDate = e.toString(), this.$emit("yearClick", this.selectDate);
|
|
6431
|
+
} else
|
|
6432
|
+
this.showDate.year = e, this.dateType = "month";
|
|
6433
|
+
this.headerValueChange();
|
|
6423
6434
|
},
|
|
6424
6435
|
//改变月份
|
|
6425
6436
|
monthClick(e) {
|
|
6426
6437
|
this.type === "month" ? (this.selectDate = this.showDate.year.toString() + "-" + (e > 9 ? e : "0" + e.toString()), this.$emit("monthClick", this.selectDate)) : (this.showDate.month = e, this.dateType = "date"), this.headerValueChange();
|
|
6438
|
+
},
|
|
6439
|
+
//根据pickerOptions中的disabledYear函数来确定年份可点击状态
|
|
6440
|
+
yearDisable(e) {
|
|
6441
|
+
return typeof this.pickerOptions.disabledYear == "function" ? this.pickerOptions.disabledYear(e) : !1;
|
|
6427
6442
|
}
|
|
6428
6443
|
},
|
|
6429
6444
|
computed: {
|
|
@@ -6541,7 +6556,7 @@ function Ma(e, t, i, s, l, n) {
|
|
|
6541
6556
|
h("tbody", null, [
|
|
6542
6557
|
(r(!0), d(g, null, y(n.decadesList, (a) => (r(), d("tr", null, [
|
|
6543
6558
|
(r(!0), d(g, null, y(a, (o) => (r(), d("td", {
|
|
6544
|
-
class: f({ selected: o === e.showDate.year }),
|
|
6559
|
+
class: f({ selected: o === e.showDate.year, disabled: n.yearDisable(o) }),
|
|
6545
6560
|
onClick: E((c) => n.yearClick(o), ["stop"])
|
|
6546
6561
|
}, [
|
|
6547
6562
|
h("a", za, b(o), 1)
|
|
@@ -8916,7 +8931,7 @@ Se.install = function(e) {
|
|
|
8916
8931
|
const _r = {
|
|
8917
8932
|
name: "lhSlider",
|
|
8918
8933
|
componentName: "lhSlider",
|
|
8919
|
-
emits: ["update:modelValue"],
|
|
8934
|
+
emits: ["update:modelValue", "dragEndCallback"],
|
|
8920
8935
|
props: {
|
|
8921
8936
|
modelValue: {
|
|
8922
8937
|
type: [Number, Array],
|
|
@@ -8972,7 +8987,19 @@ const _r = {
|
|
|
8972
8987
|
watch: {
|
|
8973
8988
|
modelValue: {
|
|
8974
8989
|
deep: !0,
|
|
8975
|
-
handler() {
|
|
8990
|
+
handler: function(e) {
|
|
8991
|
+
if (e === "" || e === null) {
|
|
8992
|
+
this.$emit("update:modelValue", this.min);
|
|
8993
|
+
return;
|
|
8994
|
+
}
|
|
8995
|
+
if (e > this.max) {
|
|
8996
|
+
this.$emit("update:modelValue", this.max);
|
|
8997
|
+
return;
|
|
8998
|
+
}
|
|
8999
|
+
if (e < this.min) {
|
|
9000
|
+
this.$emit("update:modelValue", this.min);
|
|
9001
|
+
return;
|
|
9002
|
+
}
|
|
8976
9003
|
this.buttonPosition(), this.formatTooltipEvent();
|
|
8977
9004
|
}
|
|
8978
9005
|
}
|
|
@@ -9005,24 +9032,32 @@ const _r = {
|
|
|
9005
9032
|
},
|
|
9006
9033
|
//拖动结束
|
|
9007
9034
|
dragEnd: function(e) {
|
|
9008
|
-
document.onmousemove = null
|
|
9009
|
-
|
|
9010
|
-
|
|
9011
|
-
|
|
9012
|
-
|
|
9035
|
+
if (document.onmousemove = null, this.$refs.sliderButtonWrapper1)
|
|
9036
|
+
for (let t = 0; t < this.$refs.sliderButtonWrapper1.classList.length; t++)
|
|
9037
|
+
this.$refs.sliderButtonWrapper1.classList[t] == "grabbing" && this.$refs.sliderButtonWrapper1.classList.remove("grabbing");
|
|
9038
|
+
if (this.$refs.sliderButtonWrapper2)
|
|
9039
|
+
for (let t = 0; t < this.$refs.sliderButtonWrapper2.classList.length; t++)
|
|
9040
|
+
this.$refs.sliderButtonWrapper2.classList[t] == "grabbing" && this.$refs.sliderButtonWrapper2.classList.remove("grabbing");
|
|
9041
|
+
this.dragEndCallback();
|
|
9013
9042
|
},
|
|
9014
9043
|
//点击轨道移动滑块
|
|
9015
9044
|
clickRunway() {
|
|
9016
9045
|
if (!this.disabled) {
|
|
9017
|
-
let e =
|
|
9046
|
+
let e = window.event, t = this.$refs.sliderRunway, i = this.vertical ? this.height.substring(0, this.height.length - 2) * 1 - e.clientY + t.getBoundingClientRect().top : e.clientX - t.getBoundingClientRect().left;
|
|
9018
9047
|
if (typeof this.modelValue == "number")
|
|
9019
9048
|
this.moveSlider(i, 1);
|
|
9020
9049
|
else {
|
|
9021
9050
|
let s = this.vertical ? this.drag1.style.bottom.substring(0, this.drag1.style.bottom.length - 2) * 1 : this.drag1.style.left.substring(0, this.drag1.style.left.length - 2) * 1, l = this.vertical ? this.drag2.style.bottom.substring(0, this.drag2.style.bottom.length - 2) * 1 : this.drag2.style.left.substring(0, this.drag2.style.left.length - 2) * 1, n = Math.abs(s - i), a = Math.abs(l - i);
|
|
9022
|
-
n <= a ? this.moveSlider(i, 1) : this.moveSlider(i, 2);
|
|
9051
|
+
n <= a ? (this.moveSlider(i, 1), this.dragEndCallback()) : (this.moveSlider(i, 2), this.dragEndCallback());
|
|
9023
9052
|
}
|
|
9024
9053
|
}
|
|
9025
9054
|
},
|
|
9055
|
+
//拖拽以及点击结束之后的回调事件
|
|
9056
|
+
dragEndCallback() {
|
|
9057
|
+
setTimeout(() => {
|
|
9058
|
+
this.$emit("dragEndCallback", this.modelValue);
|
|
9059
|
+
}, 0);
|
|
9060
|
+
},
|
|
9026
9061
|
//移动滑块
|
|
9027
9062
|
moveSlider(e, t) {
|
|
9028
9063
|
let i = "";
|