best-unit 2.0.9 → 2.0.10
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/best-unit.js
CHANGED
|
@@ -2065,22 +2065,22 @@ z.getAdapter = zn.getAdapter;
|
|
|
2065
2065
|
z.HttpStatusCode = ot;
|
|
2066
2066
|
z.default = z;
|
|
2067
2067
|
const {
|
|
2068
|
-
Axios:
|
|
2069
|
-
AxiosError:
|
|
2070
|
-
CanceledError:
|
|
2071
|
-
isCancel:
|
|
2072
|
-
CancelToken:
|
|
2073
|
-
VERSION:
|
|
2074
|
-
all:
|
|
2075
|
-
Cancel:
|
|
2076
|
-
isAxiosError:
|
|
2077
|
-
spread:
|
|
2078
|
-
toFormData:
|
|
2079
|
-
AxiosHeaders:
|
|
2080
|
-
HttpStatusCode:
|
|
2081
|
-
formToJSON:
|
|
2082
|
-
getAdapter:
|
|
2083
|
-
mergeConfig:
|
|
2068
|
+
Axios: ra,
|
|
2069
|
+
AxiosError: oa,
|
|
2070
|
+
CanceledError: ia,
|
|
2071
|
+
isCancel: aa,
|
|
2072
|
+
CancelToken: sa,
|
|
2073
|
+
VERSION: la,
|
|
2074
|
+
all: ca,
|
|
2075
|
+
Cancel: da,
|
|
2076
|
+
isAxiosError: ua,
|
|
2077
|
+
spread: fa,
|
|
2078
|
+
toFormData: pa,
|
|
2079
|
+
AxiosHeaders: ha,
|
|
2080
|
+
HttpStatusCode: ma,
|
|
2081
|
+
formToJSON: ga,
|
|
2082
|
+
getAdapter: ba,
|
|
2083
|
+
mergeConfig: ya
|
|
2084
2084
|
} = z;
|
|
2085
2085
|
function Uo(e = {}) {
|
|
2086
2086
|
const t = JSON.parse(
|
|
@@ -2261,10 +2261,10 @@ const Wo = async () => X().get("/all-dicts", {}).then((e) => (sessionStorage.set
|
|
|
2261
2261
|
consistent: n.data.consistent
|
|
2262
2262
|
}));
|
|
2263
2263
|
};
|
|
2264
|
-
async function
|
|
2264
|
+
async function xa() {
|
|
2265
2265
|
return await Un();
|
|
2266
2266
|
}
|
|
2267
|
-
function
|
|
2267
|
+
function _a(e) {
|
|
2268
2268
|
const {
|
|
2269
2269
|
merchant_id: t,
|
|
2270
2270
|
biz_type: n,
|
|
@@ -2443,13 +2443,13 @@ class Yo {
|
|
|
2443
2443
|
}
|
|
2444
2444
|
}
|
|
2445
2445
|
const Ie = new Yo();
|
|
2446
|
-
function
|
|
2446
|
+
function Sa() {
|
|
2447
2447
|
console.log("npm package test!!!");
|
|
2448
2448
|
}
|
|
2449
|
-
function
|
|
2449
|
+
function La() {
|
|
2450
2450
|
console.log("Current time:", (/* @__PURE__ */ new Date()).toISOString());
|
|
2451
2451
|
}
|
|
2452
|
-
const
|
|
2452
|
+
const wa = {
|
|
2453
2453
|
"/api": {
|
|
2454
2454
|
target: "https://fund.bestfulfill.tech/api/sdk",
|
|
2455
2455
|
changeOrigin: !0,
|
|
@@ -5660,7 +5660,8 @@ function zi() {
|
|
|
5660
5660
|
}
|
|
5661
5661
|
return o;
|
|
5662
5662
|
}
|
|
5663
|
-
|
|
5663
|
+
const Oi = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20t='1760084950168'%20class='icon'%20viewBox='0%200%201024%201024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20p-id='6759'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='200'%20height='200'%3e%3cpath%20d='M932.579556%20137.272889h-192V64.142222a9.159111%209.159111%200%200%200-9.130667-9.159111h-64a9.159111%209.159111%200%200%200-9.159111%209.159111v73.130667H365.738667V64.142222a9.159111%209.159111%200%200%200-9.159111-9.159111h-64a9.159111%209.159111%200%200%200-9.130667%209.159111v73.130667h-192c-20.224%200-36.579556%2016.355556-36.579556%2036.579555v758.869334c0%2020.195556%2016.355556%2036.551111%2036.579556%2036.551111h841.130667c20.252444%200%2036.579556-16.327111%2036.579555-36.551111V173.852444c0-20.224-16.355556-36.579556-36.579555-36.579555zM886.897778%20887.011556H137.159111V452.693333H886.897778v434.261334z%20m-749.710222-512V219.534222h146.289777v54.869334c0%205.034667%204.124444%209.130667%209.130667%209.130666h64a9.159111%209.159111%200%200%200%209.159111-9.130666V219.562667h292.551111v54.869333c0%205.034667%204.124444%209.130667%209.159111%209.130667h64a9.159111%209.159111%200%200%200%209.130667-9.130667V219.562667h146.289778v155.448889H137.159111z'%20p-id='6760'%3e%3c/path%3e%3c/svg%3e";
|
|
5664
|
+
function Pi() {
|
|
5664
5665
|
const e = E("theme"), t = E("themeConfig"), n = {
|
|
5665
5666
|
container: {
|
|
5666
5667
|
position: "relative",
|
|
@@ -5689,7 +5690,12 @@ function Oi() {
|
|
|
5689
5690
|
calendarIcon: {
|
|
5690
5691
|
fontSize: "16px",
|
|
5691
5692
|
color: "rgba(0, 0, 0, 0.45)",
|
|
5692
|
-
marginLeft: "8px"
|
|
5693
|
+
marginLeft: "8px",
|
|
5694
|
+
// 作为<img>使用时控制尺寸,避免SVG原始尺寸过大撑开容器
|
|
5695
|
+
width: 16,
|
|
5696
|
+
height: 16,
|
|
5697
|
+
objectFit: "contain",
|
|
5698
|
+
display: "inline-block"
|
|
5693
5699
|
},
|
|
5694
5700
|
disabled: {
|
|
5695
5701
|
backgroundColor: "#f5f5f5",
|
|
@@ -5975,10 +5981,10 @@ function Oi() {
|
|
|
5975
5981
|
}, o = r[e] || r.white, a = t?.[e]?.color;
|
|
5976
5982
|
return a && (o.dayToday.color = a, o.daySelected.backgroundColor = a, o.yearSelected.backgroundColor = a, e === "dark" && (o.daySelected.color = "#111", o.yearSelected.color = "#111")), o;
|
|
5977
5983
|
}
|
|
5978
|
-
function
|
|
5979
|
-
return
|
|
5984
|
+
function Ni() {
|
|
5985
|
+
return Pi();
|
|
5980
5986
|
}
|
|
5981
|
-
function
|
|
5987
|
+
function Ui({
|
|
5982
5988
|
value: e = "",
|
|
5983
5989
|
placeholder: t = _("请选择日期"),
|
|
5984
5990
|
disabled: n = !1,
|
|
@@ -5989,7 +5995,7 @@ function Ni({
|
|
|
5989
5995
|
className: s = "",
|
|
5990
5996
|
style: p = {}
|
|
5991
5997
|
}) {
|
|
5992
|
-
const c =
|
|
5998
|
+
const c = Ni(), [f, u] = B(!1), [y, m] = B(e), [h, x] = B(/* @__PURE__ */ new Date()), [b, S] = B(!1), L = se(null), T = (k) => {
|
|
5993
5999
|
if (!k) return "";
|
|
5994
6000
|
const v = new Date(k);
|
|
5995
6001
|
return `${v.getFullYear()}-${String(v.getMonth() + 1).padStart(
|
|
@@ -6101,7 +6107,7 @@ function Ni({
|
|
|
6101
6107
|
onBlur: i,
|
|
6102
6108
|
children: [
|
|
6103
6109
|
/* @__PURE__ */ d("span", { style: c.inputText, children: y ? T(y) : t }),
|
|
6104
|
-
/* @__PURE__ */ d("
|
|
6110
|
+
/* @__PURE__ */ d("img", { src: Oi, alt: "calendar", style: c.calendarIcon })
|
|
6105
6111
|
]
|
|
6106
6112
|
}
|
|
6107
6113
|
),
|
|
@@ -6191,7 +6197,7 @@ function Ni({
|
|
|
6191
6197
|
}
|
|
6192
6198
|
);
|
|
6193
6199
|
}
|
|
6194
|
-
function
|
|
6200
|
+
function $i({
|
|
6195
6201
|
onBack: e,
|
|
6196
6202
|
onCancel: t,
|
|
6197
6203
|
currency: n = "USD",
|
|
@@ -6265,7 +6271,7 @@ function Ui({
|
|
|
6265
6271
|
_("转账时间")
|
|
6266
6272
|
] }),
|
|
6267
6273
|
/* @__PURE__ */ d(
|
|
6268
|
-
|
|
6274
|
+
Ui,
|
|
6269
6275
|
{
|
|
6270
6276
|
value: f.transferTime,
|
|
6271
6277
|
placeholder: _("请选择转账时间"),
|
|
@@ -6359,7 +6365,7 @@ function Ui({
|
|
|
6359
6365
|
] })
|
|
6360
6366
|
] });
|
|
6361
6367
|
}
|
|
6362
|
-
function
|
|
6368
|
+
function Wi() {
|
|
6363
6369
|
const e = E("size"), t = {
|
|
6364
6370
|
container: {
|
|
6365
6371
|
background: "#fff",
|
|
@@ -6527,7 +6533,10 @@ function $i() {
|
|
|
6527
6533
|
color: "#666",
|
|
6528
6534
|
lineHeight: 1.6,
|
|
6529
6535
|
textAlign: "left",
|
|
6530
|
-
fontSize: e === l.SMALL ? 12 : 13
|
|
6536
|
+
fontSize: e === l.SMALL ? 12 : 13,
|
|
6537
|
+
// 为避免宿主系统重置 ul/li 样式导致小圆点不显示,这里显式指定
|
|
6538
|
+
listStyleType: "disc",
|
|
6539
|
+
listStylePosition: "outside"
|
|
6531
6540
|
},
|
|
6532
6541
|
link: {
|
|
6533
6542
|
color: "#1890ff",
|
|
@@ -6616,8 +6625,8 @@ function $i() {
|
|
|
6616
6625
|
}
|
|
6617
6626
|
};
|
|
6618
6627
|
}
|
|
6619
|
-
function
|
|
6620
|
-
const e = E("theme"), t = E("themeConfig"), n = e === N.WHITE, r =
|
|
6628
|
+
function Hi() {
|
|
6629
|
+
const e = E("theme"), t = E("themeConfig"), n = e === N.WHITE, r = Wi(), o = n ? r.white : r.dark;
|
|
6621
6630
|
if (t) {
|
|
6622
6631
|
const a = n ? t.white : t.dark;
|
|
6623
6632
|
if (a?.color)
|
|
@@ -6631,8 +6640,8 @@ function Wi() {
|
|
|
6631
6640
|
}
|
|
6632
6641
|
return o;
|
|
6633
6642
|
}
|
|
6634
|
-
function
|
|
6635
|
-
const n =
|
|
6643
|
+
function ji({ onConfirm: e, channelCode: t }) {
|
|
6644
|
+
const n = Hi(), [r, o] = B([]);
|
|
6636
6645
|
return J(() => {
|
|
6637
6646
|
if (!t) return;
|
|
6638
6647
|
let a = !0;
|
|
@@ -6697,7 +6706,7 @@ function Hi({ onConfirm: e, channelCode: t }) {
|
|
|
6697
6706
|
] })
|
|
6698
6707
|
] });
|
|
6699
6708
|
}
|
|
6700
|
-
function
|
|
6709
|
+
function qi({
|
|
6701
6710
|
visible: e,
|
|
6702
6711
|
onClose: t,
|
|
6703
6712
|
onSubmit: n
|
|
@@ -6803,7 +6812,7 @@ function ji({
|
|
|
6803
6812
|
onAmountError: f
|
|
6804
6813
|
}
|
|
6805
6814
|
) : i.showOfflineUpload ? /* @__PURE__ */ d(
|
|
6806
|
-
|
|
6815
|
+
$i,
|
|
6807
6816
|
{
|
|
6808
6817
|
onBack: h,
|
|
6809
6818
|
onCancel: t,
|
|
@@ -6813,7 +6822,7 @@ function ji({
|
|
|
6813
6822
|
onAmountError: f
|
|
6814
6823
|
}
|
|
6815
6824
|
) : /* @__PURE__ */ d(
|
|
6816
|
-
|
|
6825
|
+
ji,
|
|
6817
6826
|
{
|
|
6818
6827
|
onConfirm: m,
|
|
6819
6828
|
channelCode: i.channel
|
|
@@ -6825,7 +6834,7 @@ function ji({
|
|
|
6825
6834
|
}
|
|
6826
6835
|
);
|
|
6827
6836
|
}
|
|
6828
|
-
function
|
|
6837
|
+
function Ji() {
|
|
6829
6838
|
const [e, t] = B(!1), n = async (r) => {
|
|
6830
6839
|
const o = await Wn({
|
|
6831
6840
|
amount: r.amount,
|
|
@@ -6837,7 +6846,7 @@ function qi() {
|
|
|
6837
6846
|
return /* @__PURE__ */ d("div", { children: [
|
|
6838
6847
|
/* @__PURE__ */ d(ht, { onClick: () => t(!0), children: _("充值/转账") }),
|
|
6839
6848
|
/* @__PURE__ */ d(
|
|
6840
|
-
|
|
6849
|
+
qi,
|
|
6841
6850
|
{
|
|
6842
6851
|
visible: e,
|
|
6843
6852
|
onClose: () => t(!1),
|
|
@@ -6846,7 +6855,7 @@ function qi() {
|
|
|
6846
6855
|
)
|
|
6847
6856
|
] });
|
|
6848
6857
|
}
|
|
6849
|
-
qe(
|
|
6858
|
+
qe(Ji, "best-payment", ["theme"], { shadow: !1 });
|
|
6850
6859
|
const Kt = {
|
|
6851
6860
|
white: {
|
|
6852
6861
|
popover: {
|
|
@@ -6877,10 +6886,10 @@ const Kt = {
|
|
|
6877
6886
|
}
|
|
6878
6887
|
}
|
|
6879
6888
|
};
|
|
6880
|
-
function
|
|
6889
|
+
function Vi() {
|
|
6881
6890
|
return E("theme") === N.WHITE ? Kt.white : Kt.dark;
|
|
6882
6891
|
}
|
|
6883
|
-
const
|
|
6892
|
+
const Yi = ({
|
|
6884
6893
|
popover: e,
|
|
6885
6894
|
children: t,
|
|
6886
6895
|
popoverWidth: n,
|
|
@@ -6889,7 +6898,7 @@ const Vi = ({
|
|
|
6889
6898
|
offsetX: a,
|
|
6890
6899
|
popoverPosition: i = "top"
|
|
6891
6900
|
}) => {
|
|
6892
|
-
const s = E("size"), p = n ?? (s === l.SMALL ? 200 : 300), c = r ?? (s === l.SMALL ? 150 : 200), f = o ?? (s === l.SMALL ? 8 : 16), u = a ?? (s === l.SMALL ? 8 : 16), [y, m] = B(!1), [h, x] = B(i), b = se(null), S = se(null), L =
|
|
6901
|
+
const s = E("size"), p = n ?? (s === l.SMALL ? 200 : 300), c = r ?? (s === l.SMALL ? 150 : 200), f = o ?? (s === l.SMALL ? 8 : 16), u = a ?? (s === l.SMALL ? 8 : 16), [y, m] = B(!1), [h, x] = B(i), b = se(null), S = se(null), L = Vi(), T = () => {
|
|
6893
6902
|
if (S.current && (clearTimeout(S.current), S.current = null), i === "top" || i === "bottom")
|
|
6894
6903
|
if (b.current) {
|
|
6895
6904
|
const P = b.current.getBoundingClientRect();
|
|
@@ -7001,7 +7010,7 @@ const Vi = ({
|
|
|
7001
7010
|
}
|
|
7002
7011
|
);
|
|
7003
7012
|
};
|
|
7004
|
-
function
|
|
7013
|
+
function Gi() {
|
|
7005
7014
|
const e = E("size");
|
|
7006
7015
|
return {
|
|
7007
7016
|
white: {
|
|
@@ -7102,8 +7111,8 @@ function Yi() {
|
|
|
7102
7111
|
}
|
|
7103
7112
|
};
|
|
7104
7113
|
}
|
|
7105
|
-
function
|
|
7106
|
-
const t = E("theme") === N.WHITE, n =
|
|
7114
|
+
function Ki() {
|
|
7115
|
+
const t = E("theme") === N.WHITE, n = Gi();
|
|
7107
7116
|
return t ? n.white : n.dark;
|
|
7108
7117
|
}
|
|
7109
7118
|
function Xt(e) {
|
|
@@ -7112,7 +7121,7 @@ function Xt(e) {
|
|
|
7112
7121
|
maximumFractionDigits: 2
|
|
7113
7122
|
});
|
|
7114
7123
|
}
|
|
7115
|
-
function
|
|
7124
|
+
function Xi(e) {
|
|
7116
7125
|
const [t, n] = B({
|
|
7117
7126
|
currBalance: 0,
|
|
7118
7127
|
currency: "USD",
|
|
@@ -7180,7 +7189,7 @@ function Ki(e) {
|
|
|
7180
7189
|
);
|
|
7181
7190
|
};
|
|
7182
7191
|
}, []);
|
|
7183
|
-
const o =
|
|
7192
|
+
const o = Ki(), a = [
|
|
7184
7193
|
{
|
|
7185
7194
|
label: _("真实金额"),
|
|
7186
7195
|
value: t.details[0]?.value || 0,
|
|
@@ -7215,7 +7224,7 @@ function Ki(e) {
|
|
|
7215
7224
|
}
|
|
7216
7225
|
];
|
|
7217
7226
|
return /* @__PURE__ */ d(
|
|
7218
|
-
|
|
7227
|
+
Yi,
|
|
7219
7228
|
{
|
|
7220
7229
|
popover: /* @__PURE__ */ d(ne, { children: [
|
|
7221
7230
|
/* @__PURE__ */ d("div", { style: o.popoverTitle, children: _("余额详情") }),
|
|
@@ -7235,7 +7244,7 @@ function Ki(e) {
|
|
|
7235
7244
|
}
|
|
7236
7245
|
);
|
|
7237
7246
|
}
|
|
7238
|
-
qe(
|
|
7247
|
+
qe(Xi, "best-statistical-balance");
|
|
7239
7248
|
const we = {
|
|
7240
7249
|
white: {
|
|
7241
7250
|
background: "#1890ff",
|
|
@@ -7256,7 +7265,7 @@ const we = {
|
|
|
7256
7265
|
transition: "all 0.2s ease"
|
|
7257
7266
|
}
|
|
7258
7267
|
};
|
|
7259
|
-
function
|
|
7268
|
+
function Zi(e) {
|
|
7260
7269
|
return E("theme") === N.WHITE ? {
|
|
7261
7270
|
...we.white,
|
|
7262
7271
|
background: e || we.white.background
|
|
@@ -7265,7 +7274,7 @@ function Xi(e) {
|
|
|
7265
7274
|
background: e || we.dark.background
|
|
7266
7275
|
};
|
|
7267
7276
|
}
|
|
7268
|
-
function
|
|
7277
|
+
function Qi(e) {
|
|
7269
7278
|
switch (e) {
|
|
7270
7279
|
case "small":
|
|
7271
7280
|
return {
|
|
@@ -7284,12 +7293,12 @@ function Zi(e) {
|
|
|
7284
7293
|
};
|
|
7285
7294
|
}
|
|
7286
7295
|
}
|
|
7287
|
-
function
|
|
7296
|
+
function ea({
|
|
7288
7297
|
color: e,
|
|
7289
7298
|
size: t = "medium",
|
|
7290
7299
|
children: n
|
|
7291
7300
|
}) {
|
|
7292
|
-
const [r, o] = B(!1), a =
|
|
7301
|
+
const [r, o] = B(!1), a = Zi(e), i = Qi(t), s = {
|
|
7293
7302
|
...a,
|
|
7294
7303
|
...i,
|
|
7295
7304
|
display: "flex",
|
|
@@ -7352,19 +7361,19 @@ function Qi({
|
|
|
7352
7361
|
] }) })
|
|
7353
7362
|
] });
|
|
7354
7363
|
}
|
|
7355
|
-
qe(
|
|
7356
|
-
const
|
|
7364
|
+
qe(ea, "best-refresh-button", [], { shadow: !0 });
|
|
7365
|
+
const Aa = [
|
|
7357
7366
|
"best-recharge",
|
|
7358
7367
|
"best-payment",
|
|
7359
7368
|
"best-statistical-balance",
|
|
7360
7369
|
"best-refresh-button"
|
|
7361
7370
|
];
|
|
7362
7371
|
export {
|
|
7363
|
-
|
|
7364
|
-
|
|
7365
|
-
|
|
7366
|
-
|
|
7367
|
-
|
|
7372
|
+
Aa as components,
|
|
7373
|
+
xa as getBalanceData,
|
|
7374
|
+
_a as initFundUnit,
|
|
7375
|
+
Sa as npmTest,
|
|
7376
|
+
La as printCurrentTime,
|
|
7368
7377
|
Jo as refreshBalance,
|
|
7369
|
-
|
|
7378
|
+
wa as viteProxy
|
|
7370
7379
|
};
|
package/package.json
CHANGED
|
@@ -169,6 +169,9 @@ function createOfflineDetailThemes() {
|
|
|
169
169
|
lineHeight: 1.6,
|
|
170
170
|
textAlign: "left",
|
|
171
171
|
fontSize: size === Size.SMALL ? 12 : 13,
|
|
172
|
+
// 为避免宿主系统重置 ul/li 样式导致小圆点不显示,这里显式指定
|
|
173
|
+
listStyleType: "disc",
|
|
174
|
+
listStylePosition: "outside",
|
|
172
175
|
},
|
|
173
176
|
link: {
|
|
174
177
|
color: "#1890ff",
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { useState, useRef, useEffect } from "preact/hooks";
|
|
2
2
|
import { t } from "@/local";
|
|
3
|
+
import DateIcon from "@/image/date.svg";
|
|
3
4
|
import { getDatePickerTheme } from "./theme";
|
|
4
5
|
|
|
5
6
|
export interface DatePickerProps {
|
|
@@ -231,7 +232,7 @@ export function DatePicker({
|
|
|
231
232
|
<span style={theme.inputText}>
|
|
232
233
|
{selectedDate ? formatDate(selectedDate) : placeholder}
|
|
233
234
|
</span>
|
|
234
|
-
<
|
|
235
|
+
<img src={DateIcon} alt="calendar" style={theme.calendarIcon} />
|
|
235
236
|
</div>
|
|
236
237
|
|
|
237
238
|
{/* 日历面板 */}
|
|
@@ -34,6 +34,11 @@ function createDatePickerThemes() {
|
|
|
34
34
|
fontSize: "16px",
|
|
35
35
|
color: "rgba(0, 0, 0, 0.45)",
|
|
36
36
|
marginLeft: "8px",
|
|
37
|
+
// 作为<img>使用时控制尺寸,避免SVG原始尺寸过大撑开容器
|
|
38
|
+
width: 16,
|
|
39
|
+
height: 16,
|
|
40
|
+
objectFit: "contain" as const,
|
|
41
|
+
display: "inline-block",
|
|
37
42
|
},
|
|
38
43
|
disabled: {
|
|
39
44
|
backgroundColor: "#f5f5f5",
|