litos-ui 0.19.0 → 0.20.0
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/lib/{base-LvfO4mmL.js → base-Dyj1rzaK.js} +11 -12
- package/lib/base.d.ts +2 -2
- package/lib/base.js +14 -10
- package/lib/button/index.js +1 -1
- package/lib/{button-CC5NBWtI.js → button-CDYYpQu6.js} +3 -4
- package/lib/calendar/index.js +1 -1
- package/lib/{calendar-Clbg3qot.js → calendar-CvlUsN6w.js} +20 -23
- package/lib/carousel/index.js +1 -1
- package/lib/carousel/item.js +1 -1
- package/lib/{carousel-Dgirxwzb.js → carousel-DvkZ1YXq.js} +23 -19
- package/lib/check/checkbox.js +1 -1
- package/lib/check/checkbox_group.js +1 -1
- package/lib/check/radio.js +1 -1
- package/lib/check/radio_group.js +1 -1
- package/lib/{check-BDOpD_0-.js → check-DFlwStH9.js} +10 -13
- package/lib/{check-CrlZ7zVL.js → check-doQ2ZpQj.js} +10 -10
- package/lib/{checkbox-D_bZGoUD.js → checkbox-DhGHJXwI.js} +1 -1
- package/lib/collapse/index.js +1 -1
- package/lib/collapse/item.js +1 -1
- package/lib/{collapse-BRxYoeJx.js → collapse-B6-Rn05A.js} +8 -10
- package/lib/color_picker/index.js +1 -1
- package/lib/{color_picker-AaFcIczZ.js → color_picker-0a-IGZY9.js} +3 -3
- package/lib/date_picker/index.js +1 -1
- package/lib/{date_picker-HjkRma9j.js → date_picker-BDN2PAz5.js} +3 -7
- package/lib/date_picker_ori/index.js +1 -1
- package/lib/{date_picker_ori-1IOHZsan.js → date_picker_ori-BXFs1eET.js} +4 -6
- package/lib/description_panel/index.js +1 -1
- package/lib/{description_panel-DaqVcA6-.js → description_panel--AKXBzLL.js} +2 -6
- package/lib/dialog/dialog_container.js +1 -1
- package/lib/dialog/index.js +9 -7
- package/lib/{dialog_container-CcTyfoaD.js → dialog_container-Bq6HsKey.js} +7 -6
- package/lib/{esm-Cir9D6cn.js → esm-DAha108i.js} +67 -67
- package/lib/form/form_item.d.ts +1 -1
- package/lib/form/form_item.js +1 -1
- package/lib/form/index.d.ts +3 -3
- package/lib/form/index.js +1 -1
- package/lib/{form-BvZHaqAt.js → form-DJxvBiLy.js} +30 -32
- package/lib/{form_inner-52DR1IPu.js → form_inner-Cnwb6f_Q.js} +3 -5
- package/lib/{form_item-DtqChzc3.js → form_item-CFIkfH29.js} +3 -5
- package/lib/icon/arrow_down.js +1 -1
- package/lib/icon/arrow_left.js +1 -1
- package/lib/icon/arrow_right.js +1 -1
- package/lib/icon/arrow_up.js +1 -1
- package/lib/icon/base.js +1 -1
- package/lib/icon/calendar.js +1 -1
- package/lib/icon/caret_bottom.js +1 -1
- package/lib/icon/caret_top.js +1 -1
- package/lib/icon/close.js +1 -1
- package/lib/icon/close_filled.js +1 -1
- package/lib/icon/d_arrow_left.js +1 -1
- package/lib/icon/d_arrow_right.js +1 -1
- package/lib/icon/font_icon.js +1 -1
- package/lib/icon/info.js +1 -1
- package/lib/icon/loading.js +1 -1
- package/lib/icon/moon.js +1 -1
- package/lib/icon/more.js +1 -1
- package/lib/icon/reduction.js +1 -1
- package/lib/icon/refresh.js +1 -1
- package/lib/icon/refresh_left.js +1 -1
- package/lib/icon/refresh_right.js +1 -1
- package/lib/icon/search.js +1 -1
- package/lib/icon/select.js +1 -1
- package/lib/icon/sort.js +1 -1
- package/lib/icon/success.js +1 -1
- package/lib/icon/sun.js +1 -1
- package/lib/icon/theme_default.js +1 -1
- package/lib/icon/warn.js +1 -1
- package/lib/icon/zoom_in.js +1 -1
- package/lib/icon/zoom_out.js +1 -1
- package/lib/image/image_preview.js +1 -1
- package/lib/image/index.js +1 -1
- package/lib/{image-BCUhVAFo.js → image-CVQai6NX.js} +19 -19
- package/lib/{image_preview-BeJzfEoF.js → image_preview-DfQAKSJH.js} +3 -5
- package/lib/index.js +36 -36
- package/lib/input/index.js +3 -5
- package/lib/{item-42bYhAkZ.js → item-CQ2Sknbz.js} +1 -1
- package/lib/{item-Dq6M7lxw.js → item-DI6mQXtB.js} +5 -7
- package/lib/{item-CX8C9X57.js → item-D_ZOPXuE.js} +1 -1
- package/lib/list/index.js +1 -1
- package/lib/{list-Dz1Ya118.js → list-Dg5u5dgr.js} +1 -1
- package/lib/loading/index.js +6 -4
- package/lib/mask/index.js +1 -1
- package/lib/{mask-BlDl9u8F.js → mask-Bx-yNIJv.js} +2 -6
- package/lib/md_input/index.js +1 -1
- package/lib/{md_input-DN3ceqsw.js → md_input-BX3bujz8.js} +2 -2
- package/lib/menu/index.d.ts +10 -2
- package/lib/menu/index.js +1 -1
- package/lib/menu-DKscK5mw.js +274 -0
- package/lib/message/index.js +1 -1
- package/lib/modal/index.js +1 -1
- package/lib/modal/modal_box.js +4 -4
- package/lib/{modal-cjj3Nw1B.js → modal-iwxqmAqW.js} +11 -9
- package/lib/page_header/index.js +1 -1
- package/lib/{page_header-BfuWJIdd.js → page_header-ujV3pncE.js} +2 -4
- package/lib/pagination/index.d.ts +25 -18
- package/lib/pagination/index.js +1 -1
- package/lib/{pagination-DpOSOFwl.js → pagination-aRbGd3Rf.js} +86 -83
- package/lib/polygon/index.js +1 -1
- package/lib/{polygon-BY1FAACc.js → polygon-DhhovlrG.js} +1 -1
- package/lib/qrcode/index.js +1 -1
- package/lib/{qrcode-Bgr8gJzA.js → qrcode-Dip8uLSA.js} +1 -1
- package/lib/{radio-C7dkhgwc.js → radio-C9NPQWGI.js} +1 -1
- package/lib/select/index.js +1 -1
- package/lib/{select-Cis6kRjQ.js → select-BZMDj5VE.js} +33 -30
- package/lib/select_ori/index.js +1 -1
- package/lib/{select_ori-DcJbNYYr.js → select_ori-C7sUZxen.js} +3 -3
- package/lib/space/index.js +1 -1
- package/lib/{space-BT_dVhhv.js → space-CKuTk0YB.js} +6 -5
- package/lib/switch/index.js +1 -1
- package/lib/{switch-UyhlgW7F.js → switch-wh2-ivty.js} +11 -9
- package/lib/tabbar/index.js +1 -1
- package/lib/tabbar/item.js +1 -1
- package/lib/{tabbar-DO0kB58Y.js → tabbar-CBXK-_AV.js} +1 -1
- package/lib/table/index.d.ts +7 -3
- package/lib/table/index.js +1 -1
- package/lib/{table-saZMryiV.js → table-BQxMD2Ae.js} +32 -33
- package/lib/tabs/index.js +4 -2
- package/lib/tag/index.js +1 -1
- package/lib/{tag-BtDcKdxo.js → tag-Di1z9PoZ.js} +3 -5
- package/lib/theme/index.js +1 -1
- package/lib/theme/theme_color.js +4 -5
- package/lib/{theme-Barcq234.js → theme-CLbBS-in.js} +9 -10
- package/lib/utils/context_provide.js +1 -1
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/popover.js +1 -1
- package/lib/utils/transition.js +1 -1
- package/package.json +11 -11
- package/lib/menu-BOmVa4xN.js +0 -224
|
@@ -16,9 +16,7 @@ var n = ":host{display:inline-flex}.l-icon{fill:currentColor;vertical-align:midd
|
|
|
16
16
|
case "color":
|
|
17
17
|
this._state.color = r;
|
|
18
18
|
break;
|
|
19
|
-
case "size":
|
|
20
|
-
this._state.size = t(r);
|
|
21
|
-
break;
|
|
19
|
+
case "size": this._state.size = t(r);
|
|
22
20
|
}
|
|
23
21
|
}
|
|
24
22
|
connectedCallback() {
|
|
@@ -37,15 +35,16 @@ var n = ":host{display:inline-flex}.l-icon{fill:currentColor;vertical-align:midd
|
|
|
37
35
|
let e = this.createEl("svg");
|
|
38
36
|
e.classList.add("l-icon"), this.useLink || e.setAttribute("viewBox", this.viewBox);
|
|
39
37
|
let t = this.renderChildren();
|
|
40
|
-
if (typeof t == "string")
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
let r = t
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
38
|
+
if (typeof t == "string") {
|
|
39
|
+
if (t === "") {
|
|
40
|
+
let t = this.children, n = [];
|
|
41
|
+
for (let e = 0, r = t.length; e < r; e++) {
|
|
42
|
+
let r = t[e];
|
|
43
|
+
n.push(r.outerHTML);
|
|
44
|
+
}
|
|
45
|
+
e.innerHTML = n.join("");
|
|
46
|
+
} else e.innerHTML = t;
|
|
47
|
+
} else e.append(t);
|
|
49
48
|
return {
|
|
50
49
|
template: e,
|
|
51
50
|
style: n
|
package/lib/base.d.ts
CHANGED
|
@@ -14,10 +14,10 @@ export default class BaseComponent<T = Record<string, any>> extends HTMLElement
|
|
|
14
14
|
*/
|
|
15
15
|
static get observedAttributes(): string[] | undefined | null;
|
|
16
16
|
attributeChangedCallback(name: string, oldValue: string, newValue: string): void;
|
|
17
|
-
protected attributeChanged(
|
|
17
|
+
protected attributeChanged(_name: string, _oldValue: string, _newValue: string): void;
|
|
18
18
|
cancelPending(): void;
|
|
19
19
|
batchUpdate(): void;
|
|
20
|
-
protected updateDOM(
|
|
20
|
+
protected updateDOM(_changedProps: Set<string>): void;
|
|
21
21
|
/** @deprecated */
|
|
22
22
|
get shadow(): ShadowRoot;
|
|
23
23
|
get root(): ShadowRoot | HTMLElement;
|
package/lib/base.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getAttr as e } from "ph-utils/
|
|
1
|
+
import { getAttr as e } from "ph-utils/browser";
|
|
2
2
|
//#region src/components/base.ts
|
|
3
3
|
var t = class extends HTMLElement {
|
|
4
4
|
static baseName = "base-component";
|
|
@@ -57,17 +57,21 @@ var t = class extends HTMLElement {
|
|
|
57
57
|
return e(this, t, n);
|
|
58
58
|
}
|
|
59
59
|
appendToRoot(e) {
|
|
60
|
-
if (e)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
60
|
+
if (e) {
|
|
61
|
+
if (typeof e == "string") {
|
|
62
|
+
let t = document.createElement("div");
|
|
63
|
+
t.innerHTML = e, this.root.append(...t.childNodes), t = void 0;
|
|
64
|
+
} else e.length ? this.root.append(...e) : this.root.append(e);
|
|
65
|
+
}
|
|
64
66
|
}
|
|
65
67
|
appendToRootV2(e, t) {
|
|
66
68
|
let n = [];
|
|
67
|
-
if (t && n.push(this.styleHtml(t)), e)
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
if (t && n.push(this.styleHtml(t)), e) {
|
|
70
|
+
if (typeof e == "string") n.push(e);
|
|
71
|
+
else {
|
|
72
|
+
let t = document.createElement("div");
|
|
73
|
+
t.appendChild(e), n.push(t.innerHTML), t = void 0;
|
|
74
|
+
}
|
|
71
75
|
}
|
|
72
76
|
this.root.innerHTML = n.join("");
|
|
73
77
|
}
|
|
@@ -93,7 +97,7 @@ var t = class extends HTMLElement {
|
|
|
93
97
|
emit(e, t) {
|
|
94
98
|
return this.dispatchEvent(new CustomEvent(e, {
|
|
95
99
|
bubbles: !0,
|
|
96
|
-
composed: !
|
|
100
|
+
composed: !0,
|
|
97
101
|
...t
|
|
98
102
|
}));
|
|
99
103
|
}
|
package/lib/button/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../button-
|
|
1
|
+
import { t as e } from "../button-CDYYpQu6.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
2
|
import { kebabToCamel as t, parseAttrValue as n, unitNumberStr as r } from "./utils/index.js";
|
|
3
3
|
import { t as i } from "./animation-DStAHzod.js";
|
|
4
|
-
import { $one as a, addClass as o, formatClass as s, formatStyle as c, off as l, on as u, removeClass as d } from "ph-utils/
|
|
5
|
-
import { adjust as f } from "ph-utils
|
|
4
|
+
import { $one as a, addClass as o, formatClass as s, formatStyle as c, off as l, on as u, removeClass as d } from "ph-utils/browser";
|
|
5
|
+
import { adjust as f } from "ph-utils";
|
|
6
6
|
//#region src/components/button/index.less?inline
|
|
7
7
|
var p = ":host{--l-btn-padding:0 15px;--l-btn-text-color:#fff;--l-btn-hover-text-color:var(--l-btn-text-color);--l-btn-active-text-color:var(--l-btn-text-color);--l-btn-border-color:var(--l-primary-color,#722ed1);--l-btn-background:var(--l-btn-border-color);--l-btn-hover-border-color:var(--l-primary-color-light1,#9254de);--l-btn-hover-background:var(--l-btn-hover-border-color);--l-btn-active-border-color:var(--l-primary-color-dark1,#531dab);--l-btn-active-background:var(--l-btn-active-border-color);--l-btn-disabled-color:#c9c9c9;--l-btn-disabled-background:#fbfbfb;--l-btn-disabled-border-color:#e6e6e6;--l-btn-height:var(--l-form-control-height,32px);width:auto;height:var(--l-btn-height);text-indent:0;box-sizing:border-box;border-radius:var(--l-border-radius,3px);display:inline-flex}:host([block]){width:100%}:host(.l-btn-small){--l-btn-height:24px;--l-btn-padding:0 7px}:host(.l-btn-large){--l-border-radius:6px;--l-btn-height:40px;--l-btn-padding:0 15px;font-size:16px}.l-btn{cursor:pointer;box-sizing:border-box;vertical-align:middle;width:100%;padding:var(--l-btn-padding);border-radius:inherit;height:100%;color:var(--l-btn-text-color);background:var(--l-btn-background);border:1px solid var(--l-btn-border-color);justify-content:center;align-items:center;gap:var(--l-btn-gap,5px);line-height:1;font-size:inherit;outline:none;transition:border-color .3s,background-color .3s,color .3s;display:inline-flex;position:relative}.l-btn:hover{border-color:var(--l-btn-hover-border-color,var(--l-btn-hover-background));color:var(--l-btn-hover-text-color);background:var(--l-btn-hover-background)}.l-btn-box-shadow:hover{box-shadow:0 4px 12px var(--l-primary-color-light4)}.l-btn:active{border-color:var(--l-btn-active-border-color,var(--l-btn-active-background));color:var(--l-btn-active-text-color);background:var(--l-btn-active-background)}.l-btn-normal,.l-btn-normal-v2{--l-btn-text-color:auto;--l-btn-background:transparent;--l-btn-border-color:#d9d9d9;--l-btn-hover-text-color:var(--l-primary-color-light1,#9254de);--l-btn-active-text-color:var(--l-primary-color-dark1,#531dab);--l-btn-hover-background:transparent;--l-btn-active-background:transparent;--l-btn-hover-border-color:var(--l-btn-hover-text-color);--l-btn-active-border-color:var(--l-btn-active-text-color)}.l-btn-normal-v2{--l-btn-hover-background:var(--l-primary-color-light5);--l-btn-active-background:var(--l-primary-color-light4)}.l-btn-primary{--l-btn-background:var(--l-primary-color,#722ed1);--l-btn-hover-background:var(--l-primary-color-light1,#9254de);--l-btn-active-background:var(--l-primary-color-dark1,#531dab);--l-btn-disabled-border-color:var(--l-primary-color-light2,#b37feb);--l-btn-disabled-background:var(--l-primary-color-light2,#b37feb);--l-btn-disabled-color:#fff}.l-btn:disabled{border-color:var(--l-btn-disabled-border-color);background:var(--l-btn-disabled-background);color:var(--l-btn-disabled-color);cursor:not-allowed;opacity:1}.l-btn.l-btn-loading{cursor:default}.l-btn-text{--l-btn-background:transparent;--l-btn-border-color:transparent;--l-btn-hover-border-color:transparent;--l-btn-active-border-color:transparent;--l-btn-disabled-background:transparent;--l-btn-disabled-border-color:transparent;--l-btn-hover-background:transparent;--l-btn-active-background:transparent;--l-btn-padding:5px}.l-btn-primary.l-btn-text{--l-btn-text-color:var(--l-primary-color,#722ed1);--l-btn-hover-text-color:var(--l-primary-color-light1,#9254de);--l-btn-active-text-color:var(--l-primary-color-dark1,#531dab)}.l-btn-ghost{--l-btn-text-color:var(--l-btn-border-color);--l-btn-background:transparent;--l-btn-hover-background:transparent;--l-btn-active-background:transparent;--l-btn-hover-text-color:var(--l-btn-hover-border-color);--l-btn-active-text-color:var(--l-btn-active-border-color)}.l-btn-round{border-radius:calc(var(--l-form-control-height,32px) / 2)}.l-btn-circle{width:var(--l-form-control-height,32px);border-radius:50%;padding:0}.l-btn:not(.l-btn-text)+.l-btn{margin-left:10px}html.dark .l-btn:disabled{--l-btn-disabled-background:#ffffff14;--l-btn-disabled-color:#ffffff4d;--l-btn-disabled-border-color:#ffffff4d}", m = class extends e {
|
|
8
8
|
static baseName = "button";
|
|
@@ -73,7 +73,6 @@ var p = ":host{--l-btn-padding:0 15px;--l-btn-text-color:#fff;--l-btn-hover-text
|
|
|
73
73
|
case "box-shadow":
|
|
74
74
|
let i = n(a, !1, "box-shadow");
|
|
75
75
|
this._state.boxShadow = `box-shadow${i ? "" : "-none"}`;
|
|
76
|
-
break;
|
|
77
76
|
}
|
|
78
77
|
}
|
|
79
78
|
updateDOM(e) {
|
|
@@ -105,7 +104,7 @@ var p = ":host{--l-btn-padding:0 15px;--l-btn-text-color:#fff;--l-btn-hover-text
|
|
|
105
104
|
let e = document.createElement("button"), t = this._state.loading, n = this._state.text, r = this._state.ghost;
|
|
106
105
|
e.className = this._resetBtnClass(), (this.disabled || t) && (e.disabled = !0), e.type = this._state.htmlType;
|
|
107
106
|
let i = this.applyColor(this._state.color || "", n, r);
|
|
108
|
-
return i && (e.style.cssText = i),
|
|
107
|
+
return i && (e.style.cssText = i), e.innerHTML = t ? this.loadingBody() : "<slot></slot>", e.setAttribute("part", "default"), e;
|
|
109
108
|
}
|
|
110
109
|
loadingBody() {
|
|
111
110
|
let e = this._state.loadingText, t = ["<l-loading-icon class=\"l-rotate-anim\"></l-loading-icon>"];
|
package/lib/calendar/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../calendar-
|
|
1
|
+
import { t as e } from "../calendar-CvlUsN6w.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
2
|
import { parseAttrValue as t } from "./utils/index.js";
|
|
3
|
-
import { $one as n,
|
|
4
|
-
import { endOf as
|
|
5
|
-
import { get as d } from "ph-utils/storage";
|
|
3
|
+
import { $one as n, get as r, hasClass as i, off as a, on as o, shouldEventNext as s } from "ph-utils/browser";
|
|
4
|
+
import { endOf as c, format as l, startOf as u, timestamp as d } from "ph-utils";
|
|
6
5
|
//#region src/components/calendar/index.less?inline
|
|
7
6
|
var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calendar-table{border-collapse:collapse;table-layout:fixed;width:100%;height:100%}.calendar-table thead{height:var(--l-calendar-header-height,32px)}.calendar-table th{cursor:default;font-weight:400}.calendar-table .excluded{color:var(--l-calendar-off-text-color,#a8abb2)}.day{text-align:center;cursor:pointer;font-size:14px;transition:background-color .2s}:where(.day:hover){background-color:#0000000a}.day.disabled{color:var(--l-calendar-off-text-color,#a8abb2);cursor:not-allowed}.day.active:not(.disabled){background-color:var(--l-primary-color,#007bff);color:#fff;font-weight:700}.day.today{color:var(--l-primary-color,#007bff)}.day.range{background-color:var(--l-primary-color-light4,#cce6ff)}.day.range-start,.day.range-end{background-color:var(--l-primary-color,#007bff);color:#fff}", p = { "zh-CN": { weekdays: [
|
|
8
7
|
"一",
|
|
@@ -21,7 +20,7 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
21
20
|
_value;
|
|
22
21
|
constructor() {
|
|
23
22
|
super(), this.version = 2;
|
|
24
|
-
let e =
|
|
23
|
+
let e = r("l_app_locale", "zh-CN", { storage: "session" }), t = /* @__PURE__ */ new Date();
|
|
25
24
|
this._value = "", this._state = {
|
|
26
25
|
locale: e,
|
|
27
26
|
minDate: -Infinity,
|
|
@@ -41,13 +40,13 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
41
40
|
e != this._value && (this._value = e, this._updateValue());
|
|
42
41
|
}
|
|
43
42
|
_updateValue() {
|
|
44
|
-
this._state.type === "range" ? (this.
|
|
43
|
+
this._state.type === "range" ? (this._range = this._value ? this._value.split(",").map((e) => /^\d+$/.test(e) ? e.length === 10 ? Number(e) * 1e3 : Number(e) : d(e, "ms")) : [0, 0], this._selectDates.clear()) : (this._selectDates = new Set(this._value.split("&")), this._range = [0, 0]), this.batchUpdate();
|
|
45
44
|
}
|
|
46
45
|
afterInit() {
|
|
47
|
-
this.$container = n(".calendar-table", this.root),
|
|
46
|
+
this.$container = n(".calendar-table", this.root), o(this.root, "click", this.handleCellClick), o(this.$container, "mouseover", this.handleCellHover);
|
|
48
47
|
}
|
|
49
48
|
beforeDestroy() {
|
|
50
|
-
|
|
49
|
+
a(this.root, "click", this.handleCellClick), this.$container &&= (a(this.$container, "mouseover", this.handleCellHover), void 0);
|
|
51
50
|
}
|
|
52
51
|
static get observedAttributes() {
|
|
53
52
|
return [
|
|
@@ -61,11 +60,11 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
61
60
|
];
|
|
62
61
|
}
|
|
63
62
|
handleCellClick = (e) => {
|
|
64
|
-
let [t, n, r] =
|
|
63
|
+
let [t, n, r] = s(e, "l-day", this.root);
|
|
65
64
|
t && this._emitDayAction(r, "click", n);
|
|
66
65
|
};
|
|
67
66
|
handleCellHover = (e) => {
|
|
68
|
-
let [t, n, r] =
|
|
67
|
+
let [t, n, r] = s(e, "l-day", this.root);
|
|
69
68
|
t && this._emitDayAction(r, "hover", n);
|
|
70
69
|
};
|
|
71
70
|
_emitDayAction(e, t, n) {
|
|
@@ -74,7 +73,7 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
74
73
|
maxTimestamp: this._state.maxDate,
|
|
75
74
|
dayTimestamp: Number(n),
|
|
76
75
|
day: e.title,
|
|
77
|
-
isActiveMonth: !
|
|
76
|
+
isActiveMonth: !i(e, "excluded")
|
|
78
77
|
} });
|
|
79
78
|
}
|
|
80
79
|
attributeChanged(e, n, r) {
|
|
@@ -83,10 +82,10 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
83
82
|
p.hasOwnProperty(r) && (this._state.locale = r, this._langData = p[r]);
|
|
84
83
|
break;
|
|
85
84
|
case "min-date":
|
|
86
|
-
this._state.minDate =
|
|
85
|
+
this._state.minDate = u(r).getTime();
|
|
87
86
|
break;
|
|
88
87
|
case "max-date":
|
|
89
|
-
this._state.maxDate =
|
|
88
|
+
this._state.maxDate = c(r).getTime();
|
|
90
89
|
break;
|
|
91
90
|
case "year":
|
|
92
91
|
this._state.year = t(r, this._state.year);
|
|
@@ -97,9 +96,7 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
97
96
|
case "type":
|
|
98
97
|
this._state.type = r, this._updateValue();
|
|
99
98
|
break;
|
|
100
|
-
case "value":
|
|
101
|
-
this.setValue(r);
|
|
102
|
-
break;
|
|
99
|
+
case "value": this.setValue(r);
|
|
103
100
|
}
|
|
104
101
|
}
|
|
105
102
|
updateDOM(e) {
|
|
@@ -109,19 +106,19 @@ var f = ":host{box-sizing:border-box;width:100%;height:100%;display:block}.calen
|
|
|
109
106
|
return `<tr>${this._langData.weekdays.map((e) => `<th>${e}</th>`).join("")}</tr>`;
|
|
110
107
|
}
|
|
111
108
|
_renderBody() {
|
|
112
|
-
let e = this._state.year, t = this._state.month, n =
|
|
109
|
+
let e = this._state.year, t = this._state.month, n = l(null, "yyyy-mm-dd"), r = new Date(e, t, 1), i = r.getDay() - 1;
|
|
113
110
|
i < 0 && (i = 6);
|
|
114
|
-
let a = new Date(e, t + 1, 0), o = a.getDate(), s =
|
|
115
|
-
|
|
116
|
-
let
|
|
111
|
+
let a = new Date(e, t + 1, 0), o = a.getDate(), s = l(a, "yyyy-mm"), c = new Date(e, t, 0), u = c.getDate(), d = l(c, "yyyy-mm"), f = new Date(e, t + 1, 1), p = l(f, "yyyy-mm"), m = new Date(r);
|
|
112
|
+
m.setDate(m.getDate() - i);
|
|
113
|
+
let h = m.setHours(0, 0, 0, 0), g = "", [_, v] = this._range || [];
|
|
117
114
|
for (let e = 0; e < 42; e++) {
|
|
118
|
-
e % 7 == 0 && (
|
|
115
|
+
e % 7 == 0 && (g += "<tr>");
|
|
119
116
|
let t, r = "day", a = "";
|
|
120
|
-
e < i ? (t = `${u - i + e + 1}`, r += " excluded", a = d) : e < i + o ? (t = `${e - i + 1}`, a = s) : (t = `${e - i - o + 1}`, r += " excluded", a =
|
|
117
|
+
e < i ? (t = `${u - i + e + 1}`, r += " excluded", a = d) : e < i + o ? (t = `${e - i + 1}`, a = s) : (t = `${e - i - o + 1}`, r += " excluded", a = p), (h < this._state.minDate || h > this._state.maxDate) && (r += " disabled");
|
|
121
118
|
let c = `${a}-${t.padStart(2, "0")}`;
|
|
122
|
-
c === n && (r += " today"), this._selectDates.has(c) && (r += " active"),
|
|
119
|
+
c === n && (r += " today"), this._selectDates.has(c) && (r += " active"), _ && v && (_ === h ? r += " range-start" : v === h ? r += " range-end" : _ < h && h < v && (r += " range")), g += `<td class="${r}" title="${c}" l-day="${h}">${t}</td>`, h += 864e5, e % 7 == 6 && (g += "</tr>");
|
|
123
120
|
}
|
|
124
|
-
return
|
|
121
|
+
return g;
|
|
125
122
|
}
|
|
126
123
|
rerenderHeader() {
|
|
127
124
|
if (this.$container) {
|
package/lib/carousel/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../carousel-
|
|
1
|
+
import { t as e } from "../carousel-DvkZ1YXq.js";
|
|
2
2
|
export { e as default };
|
package/lib/carousel/item.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../item-
|
|
1
|
+
import { t as e } from "../item-CQ2Sknbz.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
2
|
import { parseAttrValue as t } from "./utils/index.js";
|
|
3
|
-
import { $ as n, $$ as r, $one as i,
|
|
4
|
-
import { debounce as u } from "ph-utils/web";
|
|
3
|
+
import { $ as n, $$ as r, $one as i, debounce as a, getAttr as o, iterate as s, off as c, on as l, shouldEventNext as u } from "ph-utils/browser";
|
|
5
4
|
//#region src/components/carousel/index.less?inline
|
|
6
5
|
var d = ":host{box-sizing:border-box;width:100%;height:180px;margin:0 auto;display:block;position:relative;overflow:hidden}.container{box-sizing:border-box;min-width:900%;height:100%;display:flex;position:relative}.nav-button{cursor:pointer;z-index:20;color:#fff;background-color:#292d3d4d;border:none;border-radius:50%;outline:none;justify-content:center;align-items:center;width:30px;height:30px;margin:0;padding:0;font-size:16px;transition:background-color .3s;display:flex;position:absolute;top:50%;transform:translateY(-50%)}.nav-button:hover{background-color:#292d3d66}.nav-button:active{background-color:#292d3d80}.nav-prev{left:20px}.nav-next{right:20px}.pagination{z-index:2;justify-content:center;align-items:center;gap:8px;width:100%;display:flex;position:absolute;bottom:10px;left:0}.bullet{cursor:pointer;background-color:#0000004d;border-radius:50%;width:8px;height:8px;transition:background-color .3s;display:inline-block}.bullet.active{background-color:var(--l-primary-color,#722ed1)}";
|
|
7
6
|
//#endregion
|
|
@@ -67,21 +66,20 @@ var p = class extends e {
|
|
|
67
66
|
case "autoplay":
|
|
68
67
|
let i = t(r, !1, "autoplay");
|
|
69
68
|
i !== this.autoplay && (this.autoplay = i, this.#t && (i ? this.#t.start() : this.#t.stop()));
|
|
70
|
-
break;
|
|
71
69
|
}
|
|
72
70
|
}
|
|
73
71
|
connectedCallback() {
|
|
74
72
|
this.loadStyleText(d), this.style.setProperty("--carousel-width", `${Math.floor(this.clientWidth)}px`);
|
|
75
|
-
let e =
|
|
73
|
+
let e = o(this, "height");
|
|
76
74
|
e && this.style.setProperty("height", `${e}px`), this.#d(), super.connectedCallback();
|
|
77
75
|
}
|
|
78
76
|
afterInit() {
|
|
79
|
-
this.setAttribute("data-page", "__stop__"),
|
|
77
|
+
this.setAttribute("data-page", "__stop__"), l(this.root, "click", this.#p), this.#c(), this.#t = f(() => {
|
|
80
78
|
this.#m("next");
|
|
81
|
-
}), this.autoplay && this.#t.start(), this.#o = i(".container", this.root),
|
|
79
|
+
}), this.autoplay && this.#t.start(), this.#o = i(".container", this.root), l(this.#o, "pointerdown", this.#b), l(this.#o, "pointerup", this.#S), l(this.#o, "pointermove", this.#x), l(this.#o, "pointercancel", this.#w), l(this.#o, "pointerleave", this.#w);
|
|
82
80
|
}
|
|
83
81
|
beforeDestroy() {
|
|
84
|
-
|
|
82
|
+
c(this, "mouseenter", this.#g), c(this, "mouseleave", this.#_), c(this.root, "click", this.#p), c(this.#o, "pointerdown", this.#b), c(this.#o, "pointerup", this.#S), c(this.#o, "pointermove", this.#x), c(this.#o, "pointercancel", this.#w), c(this.#o, "pointerleave", this.#w), this.#o = void 0, this.#l(!0), this.#t.stop(), this.#t = void 0;
|
|
85
83
|
}
|
|
86
84
|
render() {
|
|
87
85
|
let e = document.createDocumentFragment(), t = "";
|
|
@@ -104,11 +102,11 @@ var p = class extends e {
|
|
|
104
102
|
return this.allIndex >= 0 && i.replaceChildren(this.#s()), e.appendChild(i), e;
|
|
105
103
|
}
|
|
106
104
|
renderArrows(e) {
|
|
107
|
-
if (this.arrows !== "never") this.renderNavigationButton("prev", e), this.renderNavigationButton("next", e), this.arrows === "hover" && (
|
|
105
|
+
if (this.arrows !== "never") this.renderNavigationButton("prev", e), this.renderNavigationButton("next", e), this.arrows === "hover" && (l(this, "mouseenter", this.#g), l(this, "mouseleave", this.#_));
|
|
108
106
|
else {
|
|
109
|
-
|
|
107
|
+
c(this, "mouseenter", this.#g), c(this, "mouseleave", this.#_);
|
|
110
108
|
let e = n(".nav-button", this.root);
|
|
111
|
-
e.length &&
|
|
109
|
+
e.length && s(e, (e) => {
|
|
112
110
|
e.remove();
|
|
113
111
|
});
|
|
114
112
|
}
|
|
@@ -143,7 +141,7 @@ var p = class extends e {
|
|
|
143
141
|
#l(e = !1) {
|
|
144
142
|
this.observer && (this.observer.disconnect(), e && (this.observer = void 0));
|
|
145
143
|
}
|
|
146
|
-
#u =
|
|
144
|
+
#u = a(() => {
|
|
147
145
|
let e = i("#cloneFirst", this);
|
|
148
146
|
e && e.remove();
|
|
149
147
|
let t = i("#cloneLast", this);
|
|
@@ -172,7 +170,7 @@ var p = class extends e {
|
|
|
172
170
|
for (let t of e) t.type === "childList" && (this.#l(), this.#u());
|
|
173
171
|
};
|
|
174
172
|
#p = (e) => {
|
|
175
|
-
let [t, n] =
|
|
173
|
+
let [t, n] = u(e, "data-page", this.root);
|
|
176
174
|
t && this.#m(n);
|
|
177
175
|
};
|
|
178
176
|
#m(e) {
|
|
@@ -196,21 +194,27 @@ var p = class extends e {
|
|
|
196
194
|
this.loop && e === this.allIndex + 2 ? n = Math.floor(this.clientWidth * -1) : this.loop && e === 0 && (n = Math.floor(this.clientWidth * (this.allIndex + 1) * -1)), this.#o.style.transform = `translateX(${n}px)`, this.#e = n;
|
|
197
195
|
}, { once: !0 });
|
|
198
196
|
}
|
|
199
|
-
this.loop && this.allIndex > 0 && e === this.allIndex + 2 ?
|
|
197
|
+
this.currentIndex = this.loop && this.allIndex > 0 && e === this.allIndex + 2 ? 0 : this.loop && this.allIndex > 0 && e === 0 ? this.allIndex : this.loop ? e - 1 : e;
|
|
200
198
|
let t = i(".bullet.active", this.root);
|
|
201
199
|
t && t.classList.remove("active");
|
|
202
200
|
let n = i(`#bullet-${this.currentIndex}`, this.root);
|
|
203
201
|
n && n.classList.add("active");
|
|
204
202
|
}
|
|
205
203
|
#g = () => {
|
|
206
|
-
this.arrows === "hover"
|
|
207
|
-
e
|
|
208
|
-
|
|
204
|
+
if (this.arrows === "hover") {
|
|
205
|
+
let e = n(".nav-button", this.root);
|
|
206
|
+
s(e, (e) => {
|
|
207
|
+
e.style.display = "flex", this.#v(e, !0);
|
|
208
|
+
});
|
|
209
|
+
}
|
|
209
210
|
};
|
|
210
211
|
#_ = () => {
|
|
211
|
-
this.arrows === "hover"
|
|
212
|
-
|
|
213
|
-
|
|
212
|
+
if (this.arrows === "hover") {
|
|
213
|
+
let e = n(".nav-button", this.root);
|
|
214
|
+
s(e, (e) => {
|
|
215
|
+
this.#v(e, !1);
|
|
216
|
+
});
|
|
217
|
+
}
|
|
214
218
|
};
|
|
215
219
|
#v(e, t = !0) {
|
|
216
220
|
let n = e.getAttribute("data-page") === "prev" ? -10 : 10, r = [];
|
package/lib/check/checkbox.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../checkbox-
|
|
1
|
+
import { t as e } from "../checkbox-DhGHJXwI.js";
|
|
2
2
|
export { e as default };
|
package/lib/check/radio.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../radio-
|
|
1
|
+
import { t as e } from "../radio-C9NPQWGI.js";
|
|
2
2
|
export { e as default };
|
package/lib/check/radio_group.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { unitNumberStr as e } from "./utils/index.js";
|
|
2
|
-
import { n as t } from "./esm-
|
|
3
|
-
import { t as n } from "./form_inner-
|
|
4
|
-
import { $$ as r, off as i, on as a } from "ph-utils/
|
|
2
|
+
import { n as t } from "./esm-DAha108i.js";
|
|
3
|
+
import { t as n } from "./form_inner-Cnwb6f_Q.js";
|
|
4
|
+
import { $$ as r, off as i, on as a } from "ph-utils/browser";
|
|
5
5
|
//#region src/components/check/index.less?inline
|
|
6
6
|
var o = ":host{align-items:center;gap:var(--l-check-gap,0px);display:flex}", s = class extends n {
|
|
7
7
|
values;
|
|
@@ -23,11 +23,7 @@ var o = ":host{align-items:center;gap:var(--l-check-gap,0px);display:flex}", s =
|
|
|
23
23
|
];
|
|
24
24
|
}
|
|
25
25
|
attributeChange(t, n, r) {
|
|
26
|
-
|
|
27
|
-
case "gap":
|
|
28
|
-
this._state.gap = e(r);
|
|
29
|
-
break;
|
|
30
|
-
}
|
|
26
|
+
t === "gap" && (this._state.gap = e(r));
|
|
31
27
|
}
|
|
32
28
|
updateDOM(e) {
|
|
33
29
|
e.has("gap") && this._updateGap();
|
|
@@ -61,11 +57,12 @@ var o = ":host{align-items:center;gap:var(--l-check-gap,0px);display:flex}", s =
|
|
|
61
57
|
};
|
|
62
58
|
updateChecked() {
|
|
63
59
|
let e = [];
|
|
64
|
-
if (this.value)
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
60
|
+
if (this.value) {
|
|
61
|
+
if (this.multiple) {
|
|
62
|
+
let t = this.value.split("&");
|
|
63
|
+
e.push(...t.map((e) => decodeURIComponent(e)));
|
|
64
|
+
} else e = [this.value];
|
|
65
|
+
} else e = [];
|
|
69
66
|
this.values(e);
|
|
70
67
|
}
|
|
71
68
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { parseAttrValue as e, stopSignal as t } from "./utils/index.js";
|
|
2
|
-
import { t as n } from "./esm-
|
|
3
|
-
import { t as r } from "./form_inner-
|
|
4
|
-
import { $$ as i, addClass as a, off as o, on as s, removeClass as c, toggleClass as l } from "ph-utils/
|
|
2
|
+
import { t as n } from "./esm-DAha108i.js";
|
|
3
|
+
import { t as r } from "./form_inner-Cnwb6f_Q.js";
|
|
4
|
+
import { $$ as i, addClass as a, off as o, on as s, removeClass as c, toggleClass as l } from "ph-utils/browser";
|
|
5
5
|
//#region src/components/check/check.ts
|
|
6
6
|
var u = class extends r {
|
|
7
7
|
_checked;
|
|
@@ -79,9 +79,7 @@ var u = class extends r {
|
|
|
79
79
|
let i = e(r, !1, t);
|
|
80
80
|
this._state.indeterminate = i, this._updateIndeterminate();
|
|
81
81
|
break;
|
|
82
|
-
case "label":
|
|
83
|
-
this._state.label = r;
|
|
84
|
-
break;
|
|
82
|
+
case "label": this._state.label = r;
|
|
85
83
|
}
|
|
86
84
|
}
|
|
87
85
|
checkedChange() {
|
|
@@ -94,10 +92,12 @@ var u = class extends r {
|
|
|
94
92
|
this._state.indeterminate ? a(this, "is-indeterminate") : c(this, "is-indeterminate");
|
|
95
93
|
}
|
|
96
94
|
#e = () => {
|
|
97
|
-
if (!this.isDisabled())
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
95
|
+
if (!this.isDisabled()) {
|
|
96
|
+
if (this.value && this._groupCtx) this.emitChange();
|
|
97
|
+
else {
|
|
98
|
+
let e = this._inputType === "radio" || !this.getChecked();
|
|
99
|
+
this.setChecked(e), this.emitChange();
|
|
100
|
+
}
|
|
101
101
|
}
|
|
102
102
|
};
|
|
103
103
|
emitChange() {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as e, t } from "./check-
|
|
1
|
+
import { n as e, t } from "./check-doQ2ZpQj.js";
|
|
2
2
|
//#region src/components/check/checkbox.less?inline
|
|
3
3
|
var n = ":host(.is-indeterminate) .l-check__inner{background-color:var(--l-primary-color,#722ed1)}:host(.is-indeterminate) .l-check__inner:after{content:\"\";width:calc(var(--l-check-size,14px) * .4);border:none;border-bottom:1px solid #fff;height:1px;margin-top:0;display:block;transform:rotate(0)}.l-check__inner:after,:host(.is-checked) .l-check__inner:after{content:\"\";width:calc(var(--l-check-size,14px) * .6);height:calc(var(--l-check-size,14px) * .3);border-top:none;border-bottom:1px solid #0000;border-left:1px solid #0000;border-right:none;margin-top:-3px;transition:border-color .2s ease-in-out;display:block;transform:rotate(-45deg)}:host(.is-checked) .l-check__inner{background-color:var(--l-primary-color,#722ed1)}:host(.is-checked) .l-check__inner:after{border-color:#fff}:host(.is-disabled) .l-check__inner{background-color:var(--l-disabled-color,#e6e6e6);border-color:var(--l-disabled-color,#e6e6e6)}", r = class extends e {
|
|
4
4
|
static baseName = "checkbox";
|
package/lib/collapse/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../collapse-
|
|
1
|
+
import { t as e } from "../collapse-B6-Rn05A.js";
|
|
2
2
|
export { e as default };
|
package/lib/collapse/item.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../item-
|
|
1
|
+
import { t as e } from "../item-DI6mQXtB.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
2
|
import { kebabToCamel as t, parseAttrValue as n, unitNumberStr as r } from "./utils/index.js";
|
|
3
|
-
import { n as i } from "./esm-
|
|
4
|
-
import { $$ as a, off as o, on as s } from "ph-utils/
|
|
3
|
+
import { n as i } from "./esm-DAha108i.js";
|
|
4
|
+
import { $$ as a, off as o, on as s } from "ph-utils/browser";
|
|
5
5
|
//#region src/components/collapse/index.less?inline
|
|
6
6
|
var c = ":host{--l-collapse-border-color:var(--l-border-color,#dedede);--l-collapse-border-radius:0px;gap:var(--l-collapse-gap,0px);box-sizing:border-box;grid-template-columns:1fr;display:grid}:host(.l-collapse-grid){grid-template-columns:repeat(auto-fill,minmax(200px,1fr));align-items:start}", l = class extends e {
|
|
7
7
|
static baseName = "collapse";
|
|
@@ -55,14 +55,12 @@ var c = ":host{--l-collapse-border-color:var(--l-border-color,#dedede);--l-colla
|
|
|
55
55
|
case "grid":
|
|
56
56
|
this._state[e] = n(a, !1, e);
|
|
57
57
|
break;
|
|
58
|
-
case "prop":
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
}
|
|
65
|
-
break;
|
|
58
|
+
case "prop": if (a !== this._state.prop) {
|
|
59
|
+
this._state.prop = a;
|
|
60
|
+
let e = [], t = a.split("&");
|
|
61
|
+
for (let n = 0, r = t.length; n < r; n++) e.push(t[n]);
|
|
62
|
+
this.expands(e);
|
|
63
|
+
}
|
|
66
64
|
}
|
|
67
65
|
}
|
|
68
66
|
updateDOM(e) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../color_picker-
|
|
1
|
+
import { t as e } from "../color_picker-0a-IGZY9.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { initAttr as e, setAttrs as t } from "./utils/index.js";
|
|
2
|
-
import { t as n } from "./form_inner-
|
|
2
|
+
import { t as n } from "./form_inner-Cnwb6f_Q.js";
|
|
3
3
|
import { t as r } from "./input-DUBlLEXS.js";
|
|
4
|
-
import { $one as i, off as a, on as o } from "ph-utils/
|
|
4
|
+
import { $one as i, off as a, on as o } from "ph-utils/browser";
|
|
5
5
|
//#region src/components/color_picker/index.less?inline
|
|
6
6
|
var s = ":host{--l-input-width:60px}", c = class extends n {
|
|
7
7
|
static baseName = "color-picker";
|
|
@@ -34,7 +34,7 @@ var s = ":host{--l-input-width:60px}", c = class extends n {
|
|
|
34
34
|
}
|
|
35
35
|
_handleChange = (e) => {
|
|
36
36
|
let t = e.target.value;
|
|
37
|
-
super.setValue(t), this.
|
|
37
|
+
super.setValue(t), this.emit("change", { detail: t });
|
|
38
38
|
};
|
|
39
39
|
};
|
|
40
40
|
//#endregion
|
package/lib/date_picker/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { unitNumberStr as e } from "./utils/index.js";
|
|
2
|
-
import { t } from "./form_inner-
|
|
2
|
+
import { t } from "./form_inner-Cnwb6f_Q.js";
|
|
3
3
|
import { t as n } from "./input_inner-x4GfLGjj.js";
|
|
4
4
|
import { Popover as r } from "./utils/popover.js";
|
|
5
|
-
import { $$ as i, on as a } from "ph-utils/
|
|
5
|
+
import { $$ as i, on as a } from "ph-utils/browser";
|
|
6
6
|
//#region src/components/date_picker/index.less?inline
|
|
7
7
|
var o = ":host{height:var(--l-form-control-height,32px);border:1px solid var(--l-border-color,#dedede);border-radius:var(--l-border-radius,3px);width:var(--l-date-picker-width,140px);align-items:center;gap:8px;padding:0 8px;transition:border-color .3s;display:inline-flex}:host(:hover){border-color:var(--l-primary-color-light2,#66b3ff)}.icon{color:#00000059;flex-shrink:0;min-width:0}", s = class extends t {
|
|
8
8
|
static baseName = "date-picker";
|
|
@@ -29,11 +29,7 @@ var o = ":host{height:var(--l-form-control-height,32px);border:1px solid var(--l
|
|
|
29
29
|
return ["width"];
|
|
30
30
|
}
|
|
31
31
|
attributeChange(t, n, r) {
|
|
32
|
-
|
|
33
|
-
case "width":
|
|
34
|
-
this._state.width = e(r);
|
|
35
|
-
break;
|
|
36
|
-
}
|
|
32
|
+
t === "width" && (this._state.width = e(r));
|
|
37
33
|
}
|
|
38
34
|
updateDOM(e) {
|
|
39
35
|
e.has("width") && this._updateWidth();
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../date_picker_ori-
|
|
1
|
+
import { t as e } from "../date_picker_ori-BXFs1eET.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { kebabToCamel as e, parseAttrValue as t, unitNumberStr as n } from "./utils/index.js";
|
|
2
|
-
import { t as r } from "./form_inner-
|
|
3
|
-
import { $ as i, $$ as a, iterate as o, off as s, on as c } from "ph-utils/
|
|
4
|
-
import { parse as l } from "ph-utils
|
|
2
|
+
import { t as r } from "./form_inner-Cnwb6f_Q.js";
|
|
3
|
+
import { $ as i, $$ as a, iterate as o, off as s, on as c } from "ph-utils/browser";
|
|
4
|
+
import { parse as l } from "ph-utils";
|
|
5
5
|
//#region src/components/date_picker_ori/index.less?inline
|
|
6
6
|
var u = ":host{width:var(--l-date-picker-width,auto);align-items:center;display:inline-flex}.l-date-inner{height:var(--l-form-control-height,32px);border:1px solid var(--l-border-color,#dedede);cursor:text;border-radius:3px;outline:none;flex-grow:1;padding:0 5px;transition:border-color .3s}.l-date-inner:hover{border-color:var(--l-primary-color-light1,#9254de)}.l-date-inner:focus{border-color:var(--l-primary-color,#722ed1)}.l-date-range-divider{margin:0 10px}", d = class extends r {
|
|
7
7
|
static baseName = "date-picker-ori";
|
|
@@ -58,9 +58,7 @@ var u = ":host{width:var(--l-date-picker-width,auto);align-items:center;display:
|
|
|
58
58
|
case "delay":
|
|
59
59
|
this._state.delay = t(a, 300);
|
|
60
60
|
break;
|
|
61
|
-
case "width":
|
|
62
|
-
this._state.width = n(a);
|
|
63
|
-
break;
|
|
61
|
+
case "width": this._state.width = n(a);
|
|
64
62
|
}
|
|
65
63
|
}
|
|
66
64
|
updateDOM(e) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../description_panel
|
|
1
|
+
import { t as e } from "../description_panel--AKXBzLL.js";
|
|
2
2
|
export { e as default };
|