@arcblock/ux 3.0.6 → 3.0.8
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/ActionButton/index.d.ts +1 -1
- package/lib/ActionButton/index.js +1 -1
- package/lib/Address/compact-text.d.ts +1 -1
- package/lib/Address/compact-text.js +5 -5
- package/lib/Address/did-address.js +1 -1
- package/lib/Address/index.js +5 -5
- package/lib/Address/responsive-did-address.js +14 -14
- package/lib/Alert/index.d.ts +1 -1
- package/lib/Alert/index.js +1 -1
- package/lib/Avatar/index.d.ts +1 -1
- package/lib/Avatar/index.js +1 -1
- package/lib/Badge/index.js +1 -1
- package/lib/BlockletContext/index.d.ts +1 -1
- package/lib/BlockletNFT/index.js +1 -1
- package/lib/BlockletV2/blocklet.d.ts +1 -1
- package/lib/BlockletV2/blocklet.js +1 -1
- package/lib/BlockletV2/components/icon-text.d.ts +1 -1
- package/lib/BlockletV2/components/icon-text.js +13 -13
- package/lib/BlockletV2/components/tooltip-icon.js +22 -20
- package/lib/Button/wrap.js +1 -1
- package/lib/Center/index.js +3 -3
- package/lib/ClickToCopy/copy-button.js +3 -3
- package/lib/CloseButton/index.js +1 -1
- package/lib/ContactForm/index.js +22 -21
- package/lib/DID/index.js +45 -44
- package/lib/DIDConnect/app-info-item.js +1 -1
- package/lib/DIDConnect/auth-apps/index.js +48 -48
- package/lib/DIDConnect/did-connect-container.js +22 -22
- package/lib/DIDConnect/did-connect-footer.js +1 -1
- package/lib/DIDConnect/landing-page.js +27 -27
- package/lib/DIDConnect/request-storage-access-api-dialog.js +39 -40
- package/lib/Datatable/CustomToolbar.d.ts +3 -1
- package/lib/Datatable/CustomToolbar.js +1 -1
- package/lib/Datatable/index.js +2 -2
- package/lib/Dialog/confirm.d.ts +1 -1
- package/lib/Dialog/confirm.js +12 -12
- package/lib/Earth/index.js +1 -1
- package/lib/Footer/index.d.ts +1 -1
- package/lib/Footer/index.js +5 -5
- package/lib/Header/addon-button.d.ts +1 -1
- package/lib/Header/addon-button.js +11 -6
- package/lib/Header/header.js +1 -1
- package/lib/Header/responsive-header.d.ts +1 -1
- package/lib/Header/responsive-header.js +33 -34
- package/lib/Icon/index.js +12 -12
- package/lib/InfoRow/index.d.ts +1 -1
- package/lib/InfoRow/index.js +0 -1
- package/lib/Layout/dashboard/external-link.d.ts +1 -1
- package/lib/Layout/dashboard/external-link.js +1 -1
- package/lib/Layout/dashboard/full-page.js +8 -8
- package/lib/Layout/dashboard/index.js +1 -1
- package/lib/Layout/dashboard/sidebar.js +1 -1
- package/lib/Layout/dashboard-legacy/header.js +10 -10
- package/lib/Layout/dashboard-legacy/index.js +16 -16
- package/lib/Layout/dashboard-legacy/sidebar.d.ts +1 -1
- package/lib/Layout/dashboard-legacy/sidebar.js +19 -12
- package/lib/Layout/index.js +2 -2
- package/lib/LoadingMask/index.d.ts +1 -1
- package/lib/LoadingMask/index.js +4 -4
- package/lib/Locale/context.js +24 -24
- package/lib/Locale/selector.d.ts +1 -1
- package/lib/Locale/selector.js +1 -1
- package/lib/Logo/index.js +3 -3
- package/lib/NFTDisplay/aspect-ratio-container.d.ts +1 -1
- package/lib/NFTDisplay/index.js +5 -2
- package/lib/NFTDisplay/render-svg.js +3 -3
- package/lib/NavMenu/nav-menu.js +29 -26
- package/lib/NavMenu/products.js +1 -1
- package/lib/PageScroller/index.js +43 -43
- package/lib/PhoneInput/country-select.js +23 -23
- package/lib/PhoneInput/index.js +11 -11
- package/lib/PoweredByArcBlock/index.js +10 -6
- package/lib/QRCode/index.js +5 -5
- package/lib/RelativeTime/index.js +16 -16
- package/lib/Result/result.js +5 -5
- package/lib/Screenshot/index.d.ts +1 -1
- package/lib/Screenshot/index.js +1 -1
- package/lib/SessionUser/components/did-space.d.ts +1 -1
- package/lib/SessionUser/components/session-user-item.js +10 -10
- package/lib/SharedBridge/index.js +6 -6
- package/lib/Spinner/index.js +1 -1
- package/lib/SplitButton/index.d.ts +1 -1
- package/lib/SplitButton/index.js +1 -1
- package/lib/Success/index.js +1 -1
- package/lib/Tabs/index.js +15 -8
- package/lib/Tag/index.d.ts +1 -1
- package/lib/Tag/index.js +1 -1
- package/lib/TextCollapse/index.js +1 -1
- package/lib/Theme/theme-provider.js +58 -53
- package/lib/Theme/theme.js +1 -0
- package/lib/Typography/index.js +13 -13
- package/lib/UserCard/Cards/basic-info.d.ts +1 -1
- package/lib/UserCard/Cards/basic-info.js +1 -1
- package/lib/UserCard/Cards/index.d.ts +1 -1
- package/lib/UserCard/Cards/index.js +1 -1
- package/lib/UserCard/Container/card.js +6 -6
- package/lib/UserCard/Container/dialog.js +1 -1
- package/lib/UserCard/Content/basic.js +2 -2
- package/lib/UserCard/Content/minimal.d.ts +1 -1
- package/lib/UserCard/Content/minimal.js +1 -1
- package/lib/UserCard/Content/tooltip-avatar.js +17 -17
- package/lib/VerificationCode/index.js +1 -1
- package/lib/WalletOSIcon/index.d.ts +2 -2
- package/lib/WalletOSIcon/index.js +7 -2
- package/lib/WebWalletSWKeeper/index.d.ts +3 -1
- package/lib/WebWalletSWKeeper/index.js +4 -1
- package/lib/withTheme/index.d.ts +3 -2
- package/lib/withTheme/index.js +16 -16
- package/package.json +7 -7
- package/src/ActionButton/index.jsx +1 -1
- package/src/Address/compact-text.jsx +1 -1
- package/src/Address/did-address.tsx +1 -1
- package/src/Address/index.tsx +1 -1
- package/src/Address/responsive-did-address.tsx +3 -3
- package/src/Alert/index.jsx +1 -1
- package/src/Avatar/index.jsx +1 -1
- package/src/Badge/index.jsx +1 -1
- package/src/BlockletContext/index.tsx +1 -1
- package/src/BlockletNFT/index.jsx +1 -1
- package/src/BlockletV2/blocklet.tsx +1 -1
- package/src/BlockletV2/components/icon-text.tsx +4 -4
- package/src/BlockletV2/components/tooltip-icon.tsx +5 -3
- package/src/Button/wrap.jsx +1 -1
- package/src/Center/index.tsx +1 -1
- package/src/ClickToCopy/copy-button.tsx +1 -1
- package/src/CloseButton/index.tsx +1 -1
- package/src/ContactForm/index.tsx +9 -2
- package/src/DID/index.tsx +5 -4
- package/src/DIDConnect/app-info-item.tsx +1 -1
- package/src/DIDConnect/auth-apps/index.tsx +8 -8
- package/src/DIDConnect/did-connect-container.tsx +2 -2
- package/src/DIDConnect/did-connect-footer.tsx +1 -1
- package/src/DIDConnect/landing-page.tsx +6 -6
- package/src/DIDConnect/request-storage-access-api-dialog.tsx +1 -2
- package/src/Datatable/CustomToolbar.jsx +1 -1
- package/src/Datatable/index.jsx +2 -2
- package/src/Dialog/confirm.jsx +1 -1
- package/src/Earth/index.tsx +1 -1
- package/src/Footer/index.tsx +5 -2
- package/src/Header/addon-button.tsx +7 -2
- package/src/Header/header.tsx +1 -1
- package/src/Header/responsive-header.tsx +1 -2
- package/src/Icon/index.tsx +1 -1
- package/src/InfoRow/index.tsx +1 -2
- package/src/Layout/dashboard/external-link.tsx +1 -1
- package/src/Layout/dashboard/full-page.tsx +1 -1
- package/src/Layout/dashboard/index.tsx +1 -1
- package/src/Layout/dashboard/sidebar.tsx +5 -2
- package/src/Layout/dashboard-legacy/header.tsx +5 -5
- package/src/Layout/dashboard-legacy/index.tsx +3 -3
- package/src/Layout/dashboard-legacy/sidebar.tsx +10 -2
- package/src/Layout/index.tsx +2 -2
- package/src/LoadingMask/index.tsx +5 -5
- package/src/Locale/context.tsx +3 -3
- package/src/Locale/selector.tsx +1 -1
- package/src/Logo/index.tsx +1 -1
- package/src/NFTDisplay/aspect-ratio-container.tsx +1 -1
- package/src/NFTDisplay/index.tsx +2 -1
- package/src/NFTDisplay/render-svg.tsx +1 -1
- package/src/NavMenu/nav-menu.tsx +8 -5
- package/src/NavMenu/products.tsx +3 -1
- package/src/PageScroller/index.tsx +4 -4
- package/src/PhoneInput/country-select.tsx +3 -3
- package/src/PhoneInput/index.tsx +1 -1
- package/src/PoweredByArcBlock/index.tsx +5 -1
- package/src/QRCode/index.tsx +1 -1
- package/src/RelativeTime/index.tsx +3 -3
- package/src/Result/result.tsx +1 -1
- package/src/Screenshot/index.tsx +2 -2
- package/src/SessionUser/components/did-space.tsx +1 -1
- package/src/SessionUser/components/session-user-item.tsx +1 -1
- package/src/SharedBridge/index.tsx +2 -2
- package/src/Spinner/index.tsx +1 -1
- package/src/SplitButton/index.tsx +1 -1
- package/src/Success/index.tsx +1 -1
- package/src/Tabs/index.tsx +10 -3
- package/src/Tag/index.jsx +1 -1
- package/src/TextCollapse/index.tsx +1 -1
- package/src/Theme/theme-provider.tsx +11 -6
- package/src/Theme/theme.ts +5 -0
- package/src/Typography/index.tsx +1 -1
- package/src/UserCard/Cards/basic-info.tsx +1 -1
- package/src/UserCard/Cards/index.tsx +1 -1
- package/src/UserCard/Container/card.tsx +2 -2
- package/src/UserCard/Container/dialog.tsx +1 -1
- package/src/UserCard/Content/basic.tsx +2 -2
- package/src/UserCard/Content/minimal.tsx +1 -1
- package/src/UserCard/Content/tooltip-avatar.tsx +4 -4
- package/src/VerificationCode/index.tsx +1 -1
- package/src/WalletOSIcon/index.tsx +7 -2
- package/src/WebWalletSWKeeper/index.tsx +6 -1
- package/src/withTheme/index.tsx +7 -3
- package/vite.config.mjs +4 -1
- package/lib/ActionButton/ActionButton.stories.d.ts +0 -18
- package/lib/ActivityIndicator/ActivityIndicator.stories.d.ts +0 -8
- package/lib/Address/Address.stories.d.ts +0 -16
- package/lib/Alert/Alert.stories.d.ts +0 -28
- package/lib/AnimationWaiter/AnimationWaiter.stories.d.ts +0 -21
- package/lib/Avatar/Avatar.stories.d.ts +0 -11
- package/lib/Badge/Badge.stories.d.ts +0 -13
- package/lib/Blocklet/Blocklet.stories.d.ts +0 -17
- package/lib/BlockletNFT/BlockletNFT.stories.d.ts +0 -17
- package/lib/BlockletV2/Blocklet.stories.d.ts +0 -18
- package/lib/Button/Button.stories.d.ts +0 -19
- package/lib/Center/Center.stories.d.ts +0 -18
- package/lib/ClickToCopy/ClickToCopy.stories.d.ts +0 -16
- package/lib/CodeBlock/CodeBlock.stories.d.ts +0 -20
- package/lib/Colors/Colors.stories.d.ts +0 -34
- package/lib/Config/Config.stories.d.ts +0 -14
- package/lib/ContactForm/ContactForm.stories.d.ts +0 -23
- package/lib/CookieConsent/CookieConsent.stories.d.ts +0 -18
- package/lib/CountDown/CountDown.stories.d.ts +0 -14
- package/lib/DID/DID.stories.d.ts +0 -15
- package/lib/Datatable/Datatable.stories.d.ts +0 -32
- package/lib/Dialog/Dialog.stories.d.ts +0 -20
- package/lib/DidLogo/Logo.stories.d.ts +0 -8
- package/lib/Earth/Earth.stories.d.ts +0 -18
- package/lib/Empty/Empty.stories.d.ts +0 -17
- package/lib/ErrorBoundary/ErrorBoundary.stories.d.ts +0 -12
- package/lib/Footer/Footer.stories.d.ts +0 -12
- package/lib/Header/Header.stories.d.ts +0 -21
- package/lib/Icon/Icon.stories.d.ts +0 -23
- package/lib/Img/Img.stories.d.ts +0 -13
- package/lib/InfoRow/InfoRow.stories.d.ts +0 -14
- package/lib/Layout/Layout.stories.d.ts +0 -23
- package/lib/Locale/LocaleSelector.stories.d.ts +0 -22
- package/lib/Logo/Logo.stories.d.ts +0 -22
- package/lib/Metric/Metric.stories.d.ts +0 -14
- package/lib/NFTDisplay/NFTDisplay.stories.d.ts +0 -15
- package/lib/NavMenu/NavMenu.stories.d.ts +0 -17
- package/lib/PageScroller/story/PageScroller.stories.d.ts +0 -13
- package/lib/PhoneInput/PhoneInput.stories.d.ts +0 -12
- package/lib/PricingTable/PricingTable.stories.d.ts +0 -8
- package/lib/QRCode/QRCode.stories.d.ts +0 -13
- package/lib/RelativeTime/RelativeTime.stories.d.ts +0 -20
- package/lib/Result/Result.stories.d.ts +0 -21
- package/lib/Screenshot/Screenshot.stories.d.ts +0 -13
- package/lib/SessionManager/SessionManager.stories.d.ts +0 -9
- package/lib/Sparkline/Sparkline.stories.d.ts +0 -12
- package/lib/Spinner/Spinner.stories.d.ts +0 -18
- package/lib/SplitButton/SplitButton.stories.d.ts +0 -15
- package/lib/Switch/Switch.stories.d.ts +0 -13
- package/lib/Tabs/Tabs.stories.d.ts +0 -14
- package/lib/Tag/Tag.stories.d.ts +0 -13
- package/lib/TextCollapse/TextCollapse.stories.d.ts +0 -28
- package/lib/Theme/Theme.stories.d.ts +0 -10
- package/lib/Toast/Toast.stories.d.ts +0 -15
- package/lib/UserCard/UserCard.stories.d.ts +0 -18
- package/lib/Util/WebWalletOpener.stories.d.ts +0 -5
- package/lib/Video/Video.stories.d.ts +0 -6
- package/lib/Wallet/Action.stories.d.ts +0 -8
- package/lib/Wallet/Download.stories.d.ts +0 -9
- package/lib/Wallet/OpenInWallet.stories.d.ts +0 -5
@@ -4,7 +4,7 @@ import i from "lodash/isUndefined";
|
|
4
4
|
import x from "../Button/index.js";
|
5
5
|
import { mergeProps as y } from "../Util/index.js";
|
6
6
|
import { withDeprecated as v } from "../Util/deprecate.js";
|
7
|
-
function s(d) {
|
7
|
+
function s({ ...d }) {
|
8
8
|
const t = Object.assign({}, d);
|
9
9
|
i(t.gradient) && (t.gradient = ""), i(t.icon) && (t.icon = ""), i(t.text) && (t.text = ""), i(t.color) && (t.color = ""), i(t.border) && (t.border = ""), i(t.width) && (t.width = ""), i(t.theme) && (t.theme = "inherit"), i(t.variant) && (t.variant = "outlined"), i(t.size) && (t.size = "large");
|
10
10
|
const o = y(t, s), { href: f, icon: a, size: m, color: z, theme: g, variant: p, gradient: c, children: l, text: h, ...u } = o, e = {};
|
@@ -12,7 +12,7 @@ declare namespace CompactText {
|
|
12
12
|
namespace propTypes {
|
13
13
|
let startChars: PropTypes.Requireable<number>;
|
14
14
|
let endChars: PropTypes.Requireable<number>;
|
15
|
-
let children: PropTypes.
|
15
|
+
let children: PropTypes.Validator<NonNullable<PropTypes.ReactNodeLike>>;
|
16
16
|
let showCopyButtonInTooltip: PropTypes.Requireable<boolean>;
|
17
17
|
}
|
18
18
|
}
|
@@ -4,8 +4,8 @@ import n from "prop-types";
|
|
4
4
|
import { Tooltip as u, tooltipClasses as c, Box as s } from "@mui/material";
|
5
5
|
import { styled as y } from "../Theme/index.js";
|
6
6
|
import "../ClickToCopy/index.js";
|
7
|
-
import
|
8
|
-
const
|
7
|
+
import d from "../ClickToCopy/copy-button.js";
|
8
|
+
const C = y(({ className: p, ...r }) => /* @__PURE__ */ e(u, { ...r, classes: { popper: p } }))({
|
9
9
|
[`& .${c.tooltip}`]: {
|
10
10
|
maxWidth: 360,
|
11
11
|
wordBreak: "break-all"
|
@@ -15,7 +15,7 @@ function l({ children: p, ...r }) {
|
|
15
15
|
return f.map(p, (t) => typeof t == "string" ? /* @__PURE__ */ e(a, { ...r, children: t }) : t.props && t.props.children ? /* @__PURE__ */ e(t.type, { ...t.props, children: /* @__PURE__ */ e(l, { ...r, children: t.props.children }) }) : t);
|
16
16
|
}
|
17
17
|
function a({ startChars: p = 6, endChars: r = 6, children: o, showCopyButtonInTooltip: t = !1 }) {
|
18
|
-
return typeof o != "string" ? /* @__PURE__ */ e(l, { startChars: p, endChars: r, showCopyButtonInTooltip: t, children: o }) : /* @__PURE__ */ e(
|
18
|
+
return typeof o != "string" ? /* @__PURE__ */ e(l, { startChars: p, endChars: r, showCopyButtonInTooltip: t, children: o }) : /* @__PURE__ */ e(C, { title: /* @__PURE__ */ i(
|
19
19
|
s,
|
20
20
|
{
|
21
21
|
onClick: (m) => m.stopPropagation(),
|
@@ -26,7 +26,7 @@ function a({ startChars: p = 6, endChars: r = 6, children: o, showCopyButtonInTo
|
|
26
26
|
},
|
27
27
|
children: [
|
28
28
|
/* @__PURE__ */ e(s, { children: o }),
|
29
|
-
t && /* @__PURE__ */ e(
|
29
|
+
t && /* @__PURE__ */ e(d, { content: o, showTooltip: !1, style: { fontSize: 16, marginLeft: 4 } })
|
30
30
|
]
|
31
31
|
}
|
32
32
|
), placement: "top", children: /* @__PURE__ */ i("span", { children: [
|
@@ -38,7 +38,7 @@ function a({ startChars: p = 6, endChars: r = 6, children: o, showCopyButtonInTo
|
|
38
38
|
a.propTypes = {
|
39
39
|
startChars: n.number,
|
40
40
|
endChars: n.number,
|
41
|
-
children: n.node,
|
41
|
+
children: n.node.isRequired,
|
42
42
|
// 在 tooltip 中完整地址后显示复制按钮
|
43
43
|
showCopyButtonInTooltip: n.bool
|
44
44
|
};
|
package/lib/Address/index.js
CHANGED
@@ -1,12 +1,12 @@
|
|
1
|
-
import { jsx as
|
2
|
-
import
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
2
|
+
import e from "./did-address.js";
|
3
3
|
import s from "./responsive-did-address.js";
|
4
4
|
function f({
|
5
|
-
ref: r,
|
6
|
-
responsive:
|
5
|
+
ref: r = void 0,
|
6
|
+
responsive: o = !0,
|
7
7
|
...d
|
8
8
|
}) {
|
9
|
-
return
|
9
|
+
return o ? /* @__PURE__ */ i(s, { ...d, ref: r }) : /* @__PURE__ */ i(e, { ...d, ref: r });
|
10
10
|
}
|
11
11
|
export {
|
12
12
|
f as default
|
@@ -6,16 +6,16 @@ import { styled as F } from "../Theme/index.js";
|
|
6
6
|
import P from "./did-address.js";
|
7
7
|
import { getFontSize as B } from "../Util/index.js";
|
8
8
|
function Q({
|
9
|
-
ref: t,
|
10
|
-
style: A,
|
11
|
-
className: D,
|
9
|
+
ref: t = void 0,
|
10
|
+
style: A = {},
|
11
|
+
className: D = void 0,
|
12
12
|
component: l = "span",
|
13
13
|
size: d = 0,
|
14
14
|
...p
|
15
15
|
}) {
|
16
16
|
const [h, S] = r(!1), z = L(h), [f, m] = r(null), [u, w] = r(null), [a, C] = r(!0), { run: x } = $(() => C(!1), {
|
17
17
|
wait: 50
|
18
|
-
}), o = b(null),
|
18
|
+
}), o = b(null), i = b(null);
|
19
19
|
return j(
|
20
20
|
t,
|
21
21
|
() => new Proxy(
|
@@ -23,21 +23,21 @@ function Q({
|
|
23
23
|
{
|
24
24
|
get(c, s) {
|
25
25
|
var e;
|
26
|
-
return (e =
|
26
|
+
return (e = i.current) == null ? void 0 : e[s];
|
27
27
|
}
|
28
28
|
}
|
29
29
|
)
|
30
30
|
), R(() => {
|
31
|
-
var
|
32
|
-
const c = ((
|
31
|
+
var v, W;
|
32
|
+
const c = ((v = i.current) == null ? void 0 : v.offsetWidth) || 0;
|
33
33
|
let s = null, e = null;
|
34
|
-
return m(c), w((
|
35
|
-
var
|
36
|
-
!z.current && ((
|
34
|
+
return m(c), w((W = o.current) == null ? void 0 : W.offsetWidth), s = new ResizeObserver(() => {
|
35
|
+
var n, g;
|
36
|
+
!z.current && ((n = i.current) == null ? void 0 : n.offsetWidth) !== c && (m((g = i.current) == null ? void 0 : g.offsetWidth), x());
|
37
37
|
}), e = new ResizeObserver(() => {
|
38
|
-
var
|
39
|
-
w((
|
40
|
-
}), s.observe(
|
38
|
+
var n;
|
39
|
+
w((n = o.current) == null ? void 0 : n.offsetWidth);
|
40
|
+
}), s.observe(i.current.getEl()), e.observe(o.current), x(), () => {
|
41
41
|
s == null || s.disconnect(), e == null || e.disconnect();
|
42
42
|
};
|
43
43
|
}, []), R(() => {
|
@@ -66,7 +66,7 @@ function Q({
|
|
66
66
|
component: l,
|
67
67
|
inline: !0,
|
68
68
|
compact: h,
|
69
|
-
ref:
|
69
|
+
ref: i
|
70
70
|
}
|
71
71
|
),
|
72
72
|
a && /* @__PURE__ */ y("div", { style: { width: "100%", height: `${(d || 16) * 1.5}px` } })
|
package/lib/Alert/index.d.ts
CHANGED
package/lib/Alert/index.js
CHANGED
@@ -37,7 +37,7 @@ const i = {
|
|
37
37
|
variant: "solid"
|
38
38
|
}
|
39
39
|
};
|
40
|
-
function a(l) {
|
40
|
+
function a({ ...l }) {
|
41
41
|
const r = Object.assign({}, l);
|
42
42
|
n(r.type) && (r.type = "tip"), n(r.className) && (r.className = ""), n(r.style) && (r.style = {}), n(r.variant) && (r.variant = "border");
|
43
43
|
const m = O(r, a, ["style"]), { type: s, children: p, style: d, className: f, variant: e, showIcon: g = !1, ...b } = m, { icon: y, color: u, backgroundColor: x, borderColor: v, variant: C } = i[s] || i.success, h = Object.assign(
|
package/lib/Avatar/index.d.ts
CHANGED
@@ -41,7 +41,7 @@ export { Avatar as AvatarProps };
|
|
41
41
|
* @param {AvatarProps} props
|
42
42
|
* @returns {JSX.Element}
|
43
43
|
*/
|
44
|
-
declare function Avatar(rawProps:
|
44
|
+
declare function Avatar({ ...rawProps }: AvatarProps): JSX.Element;
|
45
45
|
declare namespace Avatar {
|
46
46
|
export namespace propTypes_1 {
|
47
47
|
let did: PropTypes.Requireable<string>;
|
package/lib/Avatar/index.js
CHANGED
@@ -10,7 +10,7 @@ import { mergeProps as E, isEthereumDid as R } from "../Util/index.js";
|
|
10
10
|
import M from "./did-motif.js";
|
11
11
|
import T from "./etherscan-blockies.js";
|
12
12
|
import { DID_PREFIX as f } from "../Util/constant.js";
|
13
|
-
function d(s) {
|
13
|
+
function d({ ...s }) {
|
14
14
|
const r = Object.assign({}, s);
|
15
15
|
n(r.did) && (r.did = ""), n(r.size) && (r.size = 36), n(r.variant) && (r.variant = "default"), n(r.animation) && (r.animation = !1), n(r.shape) && (r.shape = ""), n(r.blockiesPadding) && (r.blockiesPadding = !0), n(r.responsive) && (r.responsive = !1);
|
16
16
|
const [c, h] = k(!1), g = E(r, d, []), { did: i = "", size: e, src: p, variant: b, animation: v, shape: x, blockiesPadding: y, responsive: w, ...o } = g, l = P(() => R(i) ? T.createIcon({
|
package/lib/Badge/index.js
CHANGED
@@ -28,7 +28,7 @@ const s = {
|
|
28
28
|
backgroundColor: o.grey[900]
|
29
29
|
}
|
30
30
|
};
|
31
|
-
function i(t) {
|
31
|
+
function i({ ...t }) {
|
32
32
|
const e = Object.assign({}, t);
|
33
33
|
n(e.type) && (e.type = "primary"), n(e.content) && (e.content = ""), n(e.className) && (e.className = ""), n(e.style) && (e.style = {});
|
34
34
|
const a = b(e, i, ["style"]), { type: m, content: p, children: l, style: y, className: d, forwardedRef: f, ...g } = a, h = Object.assign(s[m] || s.primary, y);
|
@@ -8,7 +8,7 @@ declare const Consumer: import('react').Consumer<{
|
|
8
8
|
masterBlocklet: Blocklet | null;
|
9
9
|
}>;
|
10
10
|
declare function BlockletProvider({ children, baseUrl, loading, }: {
|
11
|
-
children
|
11
|
+
children: React.ReactNode;
|
12
12
|
/**
|
13
13
|
* baseUrl 为 blocklet origin + blocklet prefix
|
14
14
|
*/
|
package/lib/BlockletNFT/index.js
CHANGED
@@ -36,4 +36,4 @@ export interface IBlockletStore extends CardProps {
|
|
36
36
|
color?: string;
|
37
37
|
}[];
|
38
38
|
}
|
39
|
-
export default function BlockletStore(props: IBlockletStore): import("react/jsx-runtime").JSX.Element;
|
39
|
+
export default function BlockletStore({ ...props }: IBlockletStore): import("react/jsx-runtime").JSX.Element;
|
@@ -11,7 +11,7 @@ import "../Theme/theme-provider.js";
|
|
11
11
|
import d from "./components/icon-text.js";
|
12
12
|
import T from "./components/tooltip-icon.js";
|
13
13
|
import { strippedString as M, formatDownloadCount as J } from "./utils.js";
|
14
|
-
function co(A) {
|
14
|
+
function co({ ...A }) {
|
15
15
|
const {
|
16
16
|
title: e,
|
17
17
|
description: n = "",
|
@@ -6,4 +6,4 @@ export default function IconText({ icon, children, maxWidth, title, sx, }: {
|
|
6
6
|
maxWidth?: number;
|
7
7
|
title?: React.ReactNode;
|
8
8
|
sx?: StackProps['sx'];
|
9
|
-
}): false | "" | 0 | 0n | import("react/jsx-runtime").JSX.Element | null
|
9
|
+
}): false | "" | 0 | 0n | import("react/jsx-runtime").JSX.Element | null;
|
@@ -1,15 +1,15 @@
|
|
1
|
-
import { jsxs as
|
2
|
-
import { Stack as
|
3
|
-
import
|
4
|
-
function
|
5
|
-
icon: e,
|
6
|
-
children: o,
|
1
|
+
import { jsxs as l, jsx as t } from "react/jsx-runtime";
|
2
|
+
import { Stack as n, Typography as p } from "@mui/material";
|
3
|
+
import f from "./tooltip-icon.js";
|
4
|
+
function u({
|
5
|
+
icon: e = null,
|
6
|
+
children: o = null,
|
7
7
|
maxWidth: i = 100,
|
8
|
-
title: a,
|
9
|
-
sx: r
|
8
|
+
title: a = void 0,
|
9
|
+
sx: r = {}
|
10
10
|
}) {
|
11
|
-
return (o === 0 || o) && /* @__PURE__ */
|
12
|
-
|
11
|
+
return (o === 0 || o) && /* @__PURE__ */ l(
|
12
|
+
n,
|
13
13
|
{
|
14
14
|
direction: "row",
|
15
15
|
sx: [
|
@@ -22,8 +22,8 @@ function d({
|
|
22
22
|
],
|
23
23
|
children: [
|
24
24
|
e,
|
25
|
-
/* @__PURE__ */ t(
|
26
|
-
|
25
|
+
/* @__PURE__ */ t(f, { title: a || (typeof o == "string" ? o : ""), children: /* @__PURE__ */ t(
|
26
|
+
p,
|
27
27
|
{
|
28
28
|
variant: "body2",
|
29
29
|
sx: {
|
@@ -41,5 +41,5 @@ function d({
|
|
41
41
|
);
|
42
42
|
}
|
43
43
|
export {
|
44
|
-
|
44
|
+
u as default
|
45
45
|
};
|
@@ -1,30 +1,31 @@
|
|
1
|
-
import { jsx as
|
2
|
-
import { Tooltip as
|
3
|
-
|
4
|
-
|
5
|
-
|
1
|
+
import { jsx as x } from "react/jsx-runtime";
|
2
|
+
import { Tooltip as n, tooltipClasses as f } from "@mui/material";
|
3
|
+
import { mergeSx as u } from "../../Util/style.js";
|
4
|
+
function I({
|
5
|
+
title: t,
|
6
|
+
sx: c,
|
6
7
|
children: p,
|
7
8
|
slotProps: e,
|
8
|
-
fontSize:
|
9
|
-
fontWeight:
|
9
|
+
fontSize: a = 12,
|
10
|
+
fontWeight: m = 500,
|
10
11
|
color: r = "text.contrast",
|
11
|
-
...
|
12
|
+
...i
|
12
13
|
}) {
|
13
|
-
var
|
14
|
-
return
|
15
|
-
|
14
|
+
var o;
|
15
|
+
return t ? /* @__PURE__ */ x(
|
16
|
+
n,
|
16
17
|
{
|
17
|
-
title:
|
18
|
+
title: t,
|
18
19
|
placement: "top",
|
19
|
-
...
|
20
|
+
...i,
|
20
21
|
slotProps: {
|
21
22
|
popper: {
|
22
23
|
...e == null ? void 0 : e.popper,
|
23
|
-
sx:
|
24
|
+
sx: u(
|
24
25
|
{
|
25
|
-
[`& .${
|
26
|
-
fontSize:
|
27
|
-
fontWeight:
|
26
|
+
[`& .${f.tooltip}`]: {
|
27
|
+
fontSize: a,
|
28
|
+
fontWeight: m,
|
28
29
|
boxShadow: 2,
|
29
30
|
marginBottom: "6px !important",
|
30
31
|
borderRadius: "8px",
|
@@ -34,8 +35,9 @@ function g({
|
|
34
35
|
alignItems: "center"
|
35
36
|
}
|
36
37
|
},
|
37
|
-
|
38
|
-
|
38
|
+
// @ts-expect-error
|
39
|
+
(o = e == null ? void 0 : e.popper) == null ? void 0 : o.sx
|
40
|
+
)
|
39
41
|
}
|
40
42
|
},
|
41
43
|
children: p
|
@@ -43,5 +45,5 @@ function g({
|
|
43
45
|
) : p;
|
44
46
|
}
|
45
47
|
export {
|
46
|
-
|
48
|
+
I as default
|
47
49
|
};
|
package/lib/Button/wrap.js
CHANGED
@@ -15,7 +15,7 @@ const y = {
|
|
15
15
|
}
|
16
16
|
};
|
17
17
|
function q(g) {
|
18
|
-
function d(c) {
|
18
|
+
function d({ ...c }) {
|
19
19
|
const e = Object.assign({}, c);
|
20
20
|
i(e.rounded) && (e.rounded = !1), i(e.size) && (e.size = "medium"), i(e.forwardedRef) && (e.forwardedRef = null), i(e.style) && (e.style = {});
|
21
21
|
const s = k(e, d, ["style"]), { children: b, rounded: w, loading: f, disabled: h, style: R, forwardedRef: C, color: n, ...t } = s, z = h || f;
|
package/lib/Center/index.js
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
2
2
|
import { styled as r } from "../Theme/index.js";
|
3
3
|
function o({
|
4
|
-
children: e,
|
4
|
+
children: e = null,
|
5
5
|
relative: i = "screen"
|
6
6
|
}) {
|
7
7
|
let t = {};
|
8
8
|
return i === "parent" && (t = {
|
9
9
|
width: "100%",
|
10
10
|
height: "100%"
|
11
|
-
}), /* @__PURE__ */ n(
|
11
|
+
}), /* @__PURE__ */ n(l, { style: t, children: e });
|
12
12
|
}
|
13
|
-
const
|
13
|
+
const l = r("div")`
|
14
14
|
flex: 1;
|
15
15
|
width: 100vw;
|
16
16
|
height: 100vh;
|
@@ -2,15 +2,15 @@ import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { Tooltip as u } from "@mui/material";
|
3
3
|
import { green as y } from "@mui/material/colors";
|
4
4
|
import { Check as a, ContentCopy as C } from "@mui/icons-material";
|
5
|
-
import
|
5
|
+
import d from "./hook.js";
|
6
6
|
function S({
|
7
7
|
content: c = "",
|
8
8
|
locale: m = "en",
|
9
|
-
render: e,
|
9
|
+
render: e = void 0,
|
10
10
|
showTooltip: l = !0,
|
11
11
|
...r
|
12
12
|
}) {
|
13
|
-
const { containerRef: s, copied: t, copy: f, texts: n } =
|
13
|
+
const { containerRef: s, copied: t, copy: f, texts: n } = d({ content: c, locale: m }), i = {
|
14
14
|
fontSize: "1em"
|
15
15
|
}, p = /* @__PURE__ */ o("span", { title: t ? "" : n.copy, ...r, style: { height: "1em", ...r.style }, children: t ? /* @__PURE__ */ o(u, { title: n.copied, placement: "bottom", arrow: !0, open: t && l, children: /* @__PURE__ */ o(a, { sx: { ...i, color: y[500] } }) }) : /* @__PURE__ */ o(C, { onClick: f, sx: { ...i, cursor: "pointer" } }) });
|
16
16
|
return e ? e({ copyButton: p, containerRef: s }) : p;
|
package/lib/CloseButton/index.js
CHANGED
package/lib/ContactForm/index.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { jsxs as d, jsx as
|
1
|
+
import { jsxs as d, jsx as o } from "react/jsx-runtime";
|
2
2
|
import f from "react";
|
3
3
|
import g from "axios";
|
4
4
|
import { Typography as m, CircularProgress as b } from "@mui/material";
|
@@ -6,15 +6,15 @@ import { mergeProps as y } from "../Util/index.js";
|
|
6
6
|
import { warn as x } from "../Util/deprecate.js";
|
7
7
|
import v from "../Button/index.js";
|
8
8
|
import { styled as w } from "../Theme/index.js";
|
9
|
-
function S({ formId: t, portalId: e }, s,
|
10
|
-
const
|
11
|
-
return g.post(
|
9
|
+
function S({ formId: t, portalId: e }, s, r) {
|
10
|
+
const a = `https://api.hsforms.com/submissions/v3/integration/submit/${e}/${t}`;
|
11
|
+
return g.post(a, {
|
12
12
|
submittedAt: Date.now(),
|
13
13
|
fields: Object.keys(s).map((i) => ({
|
14
14
|
name: i.replace(/\s+/, "").toLowerCase(),
|
15
15
|
value: s[i]
|
16
16
|
})),
|
17
|
-
context:
|
17
|
+
context: r,
|
18
18
|
skipValidation: !1
|
19
19
|
}).then((i) => i.data.inlineMessage).catch((i) => i.data ? i.data.message : "Form Submit Failed");
|
20
20
|
}
|
@@ -23,9 +23,9 @@ const l = class l extends f.Component {
|
|
23
23
|
super(e), this.onSubmit = async (s) => {
|
24
24
|
s.preventDefault(), this.setState({ loading: !0 });
|
25
25
|
try {
|
26
|
-
const
|
26
|
+
const r = await S(
|
27
27
|
{ formId: this.props.formId, portalId: this.props.portalId },
|
28
|
-
this.fields.reduce((
|
28
|
+
this.fields.reduce((a, i) => (a[i] = this.state[i], a), {}),
|
29
29
|
{
|
30
30
|
pageUri: window.location.href,
|
31
31
|
pageName: document.title
|
@@ -33,18 +33,18 @@ const l = class l extends f.Component {
|
|
33
33
|
);
|
34
34
|
this.setState({
|
35
35
|
loading: !1,
|
36
|
-
successMessage:
|
36
|
+
successMessage: r || this.props.successMessage
|
37
37
|
});
|
38
|
-
} catch (
|
38
|
+
} catch (r) {
|
39
39
|
this.setState({
|
40
40
|
loading: !1,
|
41
|
-
errorMessage:
|
41
|
+
errorMessage: r ? r.message : "Form submit failed"
|
42
42
|
});
|
43
43
|
}
|
44
|
-
}, this.getInputHandler = (s,
|
44
|
+
}, this.getInputHandler = (s, r = {}) => (a) => {
|
45
45
|
this.setState(
|
46
|
-
Object.assign(
|
47
|
-
[s]:
|
46
|
+
Object.assign(r, {
|
47
|
+
[s]: a.target.value
|
48
48
|
})
|
49
49
|
);
|
50
50
|
}, typeof e.fields == "string" ? this.fields = e.fields.split(",").map((s) => s.trim()) : this.fields = e.fields, this.state = {
|
@@ -60,7 +60,7 @@ const l = class l extends f.Component {
|
|
60
60
|
return typeof e.title > "u" && (e.title = "Signup for our news letter"), e.button || (e.button = "Subscribe"), e;
|
61
61
|
}
|
62
62
|
render() {
|
63
|
-
const { className: e, style: s, title:
|
63
|
+
const { className: e, style: s, title: r, button: a, layout: i } = this.deriveProps(), { loading: c, errorMessage: u, successMessage: p } = this.state;
|
64
64
|
return /* @__PURE__ */ d(
|
65
65
|
I,
|
66
66
|
{
|
@@ -71,9 +71,9 @@ const l = class l extends f.Component {
|
|
71
71
|
fieldCount: this.fields.length,
|
72
72
|
name: "subscribe",
|
73
73
|
children: [
|
74
|
-
!!
|
74
|
+
!!r && /* @__PURE__ */ o(m, { component: "p", className: "title", children: r }),
|
75
75
|
/* @__PURE__ */ d("div", { className: "form-controls", children: [
|
76
|
-
this.fields.map((n) => /* @__PURE__ */
|
76
|
+
this.fields.map((n) => /* @__PURE__ */ o(
|
77
77
|
"input",
|
78
78
|
{
|
79
79
|
required: !0,
|
@@ -85,7 +85,7 @@ const l = class l extends f.Component {
|
|
85
85
|
},
|
86
86
|
n
|
87
87
|
)),
|
88
|
-
/* @__PURE__ */
|
88
|
+
/* @__PURE__ */ o(
|
89
89
|
v,
|
90
90
|
{
|
91
91
|
variant: "outlined",
|
@@ -94,11 +94,11 @@ const l = class l extends f.Component {
|
|
94
94
|
size: "large",
|
95
95
|
disabled: c,
|
96
96
|
className: "subscribe-btn-empty",
|
97
|
-
children: c ? /* @__PURE__ */
|
97
|
+
children: c ? /* @__PURE__ */ o(b, { size: 28 }) : a
|
98
98
|
}
|
99
99
|
)
|
100
100
|
] }),
|
101
|
-
!!u && /* @__PURE__ */
|
101
|
+
!!u && /* @__PURE__ */ o(
|
102
102
|
m,
|
103
103
|
{
|
104
104
|
component: "p",
|
@@ -108,7 +108,7 @@ const l = class l extends f.Component {
|
|
108
108
|
dangerouslySetInnerHTML: { __html: u }
|
109
109
|
}
|
110
110
|
),
|
111
|
-
!!p && /* @__PURE__ */
|
111
|
+
!!p && /* @__PURE__ */ o(
|
112
112
|
m,
|
113
113
|
{
|
114
114
|
component: "p",
|
@@ -163,7 +163,8 @@ const M = (t) => t.layout === "vertical" ? "100%" : `${Math.max(95 / (t.fieldCou
|
|
163
163
|
width: ${(t) => M(t)};
|
164
164
|
height: 50px;
|
165
165
|
border: none;
|
166
|
-
border-bottom: 1px solid
|
166
|
+
border-bottom: 1px solid
|
167
|
+
${(t) => t.theme.typography.color.main};
|
167
168
|
font-size: 16px;
|
168
169
|
letter-spacing: 1.8px;
|
169
170
|
outline: none;
|