@arcblock/ux 3.0.6 → 3.0.7
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 +9 -9
- package/lib/ActivityIndicator/index.js +6 -7
- package/lib/Address/compact-text.d.ts +1 -1
- package/lib/Address/compact-text.js +6 -7
- package/lib/Address/did-address.js +4 -4
- package/lib/Address/index.js +6 -6
- package/lib/Address/responsive-did-address.js +17 -17
- package/lib/Alert/index.d.ts +1 -1
- package/lib/Alert/index.js +8 -8
- package/lib/AnimationWaiter/index.js +10 -10
- package/lib/Async/index.js +4 -4
- package/lib/Avatar/etherscan-blockies.js +15 -15
- package/lib/Avatar/index.d.ts +1 -1
- package/lib/Avatar/index.js +6 -6
- package/lib/Badge/index.js +5 -5
- package/lib/Blocklet/blocklet.js +10 -10
- package/lib/Blocklet/index.js +6 -5
- package/lib/Blocklet/utils.js +1 -1
- package/lib/BlockletContext/index.d.ts +1 -1
- package/lib/BlockletContext/index.js +1 -1
- package/lib/BlockletNFT/index.js +19 -19
- package/lib/BlockletV2/blocklet.d.ts +1 -1
- package/lib/BlockletV2/blocklet.js +36 -37
- 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/BlockletV2/index.js +8 -7
- package/lib/BlockletV2/utils.js +1 -1
- package/lib/Button/index.js +1 -1
- package/lib/Button/wrap.js +3 -3
- package/lib/ButtonGroup/index.js +1 -1
- package/lib/Center/index.js +4 -4
- package/lib/ClickToCopy/copy-button.js +3 -3
- package/lib/ClickToCopy/index.js +5 -5
- package/lib/CloseButton/index.js +2 -2
- package/lib/CodeBlock/index.js +3 -3
- package/lib/Colors/index.js +3 -3
- package/lib/Config/config-provider.js +15 -16
- package/lib/Config/index.js +3 -5
- package/lib/Config/theme-mode-toggle.js +1 -1
- package/lib/ContactForm/index.js +26 -25
- package/lib/CookieConsent/index.js +1 -1
- package/lib/CountDown/index.js +2 -2
- package/lib/DID/index.js +79 -78
- package/lib/DIDConnect/app-icon.js +10 -10
- package/lib/DIDConnect/app-info-item.js +5 -5
- package/lib/DIDConnect/auth-apps/auth-apps-info.js +1 -1
- package/lib/DIDConnect/auth-apps/index.js +56 -56
- package/lib/DIDConnect/did-connect-container.js +35 -36
- package/lib/DIDConnect/did-connect-footer.js +7 -7
- package/lib/DIDConnect/index.js +10 -10
- package/lib/DIDConnect/landing-page.js +45 -46
- package/lib/DIDConnect/powered-by.js +2 -2
- package/lib/DIDConnect/request-storage-access-api-dialog.js +44 -45
- package/lib/DIDConnect/with-container.js +25 -26
- package/lib/DIDConnect/with-ux-theme.js +6 -7
- package/lib/Datatable/CustomToolbar.d.ts +3 -1
- package/lib/Datatable/CustomToolbar.js +13 -13
- package/lib/Datatable/TableSearch.js +2 -2
- package/lib/Datatable/index.js +6 -6
- package/lib/Dialog/confirm.d.ts +1 -1
- package/lib/Dialog/confirm.js +20 -20
- package/lib/Dialog/dialog.js +7 -7
- package/lib/Dialog/index.js +3 -3
- package/lib/Dialog/use-confirm.js +1 -1
- package/lib/DriftBot/index.js +1 -1
- package/lib/Earth/index.js +10 -10
- package/lib/Empty/index.js +1 -1
- package/lib/ErrorBoundary/fallback.js +15 -15
- package/lib/ErrorBoundary/index.js +1 -6
- package/lib/Footer/index.d.ts +1 -1
- package/lib/Footer/index.js +7 -7
- package/lib/Header/addon-button.d.ts +1 -1
- package/lib/Header/addon-button.js +11 -6
- package/lib/Header/auto-hidden.js +1 -1
- package/lib/Header/header.js +4 -4
- package/lib/Header/index.js +3 -3
- package/lib/Header/responsive-header.d.ts +1 -1
- package/lib/Header/responsive-header.js +33 -34
- package/lib/Icon/image.js +2 -2
- package/lib/Icon/index.js +12 -12
- package/lib/Img/index.js +1 -1
- package/lib/InfoRow/index.d.ts +1 -1
- package/lib/InfoRow/index.js +1 -2
- 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 +30 -32
- package/lib/Layout/dashboard/sidebar.js +3 -3
- package/lib/Layout/dashboard-legacy/header.js +12 -12
- package/lib/Layout/dashboard-legacy/index.js +20 -20
- package/lib/Layout/dashboard-legacy/sidebar.d.ts +1 -1
- package/lib/Layout/dashboard-legacy/sidebar.js +20 -13
- package/lib/Layout/index.js +7 -7
- package/lib/LoadingMask/index.d.ts +1 -1
- package/lib/LoadingMask/index.js +4 -4
- package/lib/Locale/context.js +27 -27
- package/lib/Locale/selector.d.ts +1 -1
- package/lib/Locale/selector.js +4 -4
- package/lib/Logo/index.js +19 -19
- package/lib/Metric/index.js +2 -2
- package/lib/NFTDisplay/aspect-ratio-container.d.ts +1 -1
- package/lib/NFTDisplay/aspect-ratio-container.js +1 -1
- package/lib/NFTDisplay/broken.js +2 -2
- package/lib/NFTDisplay/index.js +38 -35
- package/lib/NFTDisplay/loading.js +1 -1
- package/lib/NFTDisplay/render-svg.js +4 -4
- package/lib/NFTDisplay/svg-embedder/img.js +3 -3
- package/lib/NFTDisplay/svg-embedder/inline-svg.js +1 -1
- package/lib/NavMenu/index.js +2 -2
- package/lib/NavMenu/nav-menu.js +46 -44
- package/lib/NavMenu/products.js +33 -33
- package/lib/NavMenu/style.js +1 -1
- package/lib/NavMenu/sub-item-group.js +1 -1
- package/lib/PageScroller/index.js +53 -53
- package/lib/PageScroller/story/FullPage.js +27 -27
- package/lib/PageScroller/story/PageContain.js +8 -8
- package/lib/Passport/index.js +3 -2
- package/lib/Passport/passport.js +2 -2
- package/lib/PhoneInput/country-select.js +24 -24
- package/lib/PhoneInput/index.js +13 -13
- package/lib/PoweredByArcBlock/index.js +10 -6
- package/lib/PricingTable/PricingPlan.js +1 -1
- package/lib/PricingTable/index.js +3 -3
- package/lib/QRCode/index.js +5 -5
- package/lib/RelativeTime/index.js +17 -17
- package/lib/Result/common.js +4 -6
- package/lib/Result/index.js +2 -2
- package/lib/Result/result.js +5 -5
- package/lib/Screenshot/BaseScreenshot/index.js +3 -3
- package/lib/Screenshot/index.d.ts +1 -1
- package/lib/Screenshot/index.js +10 -10
- package/lib/SessionBlocklet/index.js +8 -8
- package/lib/SessionManager/index.js +3 -2
- package/lib/SessionUser/components/did-space.d.ts +1 -1
- package/lib/SessionUser/components/did-space.js +14 -14
- package/lib/SessionUser/components/logged-in.js +33 -33
- package/lib/SessionUser/components/quick-login-item.js +29 -29
- package/lib/SessionUser/components/session-user-item.js +27 -27
- package/lib/SessionUser/components/session-user-switch.js +4 -4
- package/lib/SessionUser/components/un-login.js +7 -7
- package/lib/SessionUser/components/user-info.js +16 -16
- package/lib/SessionUser/index.js +2 -2
- package/lib/SharedBridge/index.js +23 -23
- package/lib/Spinner/index.js +2 -2
- package/lib/SplitButton/index.d.ts +1 -1
- package/lib/SplitButton/index.js +2 -2
- package/lib/Success/index.js +1 -1
- package/lib/Switch/index.js +1 -1
- package/lib/Tabs/index.js +16 -9
- package/lib/Tag/index.d.ts +1 -1
- package/lib/Tag/index.js +7 -7
- package/lib/TextCollapse/index.js +3 -3
- package/lib/Theme/index.js +11 -22
- package/lib/Theme/theme-provider.js +60 -55
- package/lib/Theme/theme.js +5 -4
- package/lib/Toast/index.js +11 -11
- package/lib/Typography/index.js +13 -13
- package/lib/UserCard/Cards/avatar-only.js +2 -2
- package/lib/UserCard/Cards/basic-info.d.ts +1 -1
- package/lib/UserCard/Cards/basic-info.js +4 -4
- package/lib/UserCard/Cards/index.d.ts +1 -1
- package/lib/UserCard/Cards/index.js +4 -4
- package/lib/UserCard/Cards/name-only.js +1 -1
- package/lib/UserCard/Container/card.js +8 -8
- package/lib/UserCard/Container/dialog.js +2 -2
- package/lib/UserCard/Content/basic.js +3 -3
- package/lib/UserCard/Content/clock.js +3 -3
- package/lib/UserCard/Content/minimal.d.ts +1 -1
- package/lib/UserCard/Content/minimal.js +8 -8
- package/lib/UserCard/Content/tooltip-avatar.js +18 -18
- package/lib/UserCard/components.js +23 -23
- package/lib/UserCard/index.js +12 -12
- package/lib/Util/index.js +2 -2
- package/lib/VerificationCode/index.js +2 -2
- package/lib/Video/index.js +2 -2
- package/lib/Wallet/Action.js +4 -4
- package/lib/Wallet/Download.js +6 -6
- package/lib/Wallet/Open.js +1 -1
- package/lib/WalletOSIcon/index.d.ts +2 -2
- package/lib/WalletOSIcon/index.js +8 -3
- package/lib/WebWalletSWKeeper/index.d.ts +3 -1
- package/lib/WebWalletSWKeeper/index.js +6 -3
- package/lib/WechatPrompt/index.js +1 -1
- package/lib/hooks/use-blocklet-logo.js +13 -15
- package/lib/hooks/use-clock.js +1 -1
- package/lib/index.js +74 -79
- package/lib/withTheme/index.d.ts +3 -2
- package/lib/withTheme/index.js +13 -14
- package/lib/withTracker/error_boundary.js +1 -1
- 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 +5 -2
- 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/AnimationWaiter/dark-animation.json.js +0 -27
- package/lib/AnimationWaiter/default-animation.json.js +0 -29
- 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/Earth/countries.json.js +0 -13
- 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/Logo/images/logo-dark-text.svg.js +0 -5
- package/lib/Logo/images/logo-dark-top.svg.js +0 -5
- package/lib/Logo/images/logo-light-text.svg.js +0 -5
- package/lib/Logo/images/logo-light-top.svg.js +0 -5
- package/lib/Metric/Metric.stories.d.ts +0 -14
- package/lib/NFTDisplay/NFTBroken.svg.js +0 -108
- package/lib/NFTDisplay/NFTDisplay.stories.d.ts +0 -15
- package/lib/NavMenu/NavMenu.stories.d.ts +0 -17
- package/lib/NavMenu/images/OCAP.svg.js +0 -5
- package/lib/NavMenu/images/abt-network.svg.js +0 -7
- package/lib/NavMenu/images/ai-kit.svg.js +0 -7
- package/lib/NavMenu/images/aigne.svg.js +0 -7
- package/lib/NavMenu/images/aistro.svg.js +0 -5
- package/lib/NavMenu/images/arcsphere.svg.js +0 -10
- package/lib/NavMenu/images/blocklet-framework.svg.js +0 -7
- package/lib/NavMenu/images/blocklet-launcher.svg.js +0 -5
- package/lib/NavMenu/images/blocklet-server.svg.js +0 -7
- package/lib/NavMenu/images/blocklet-store.svg.js +0 -5
- package/lib/NavMenu/images/creator-studio.svg.js +0 -7
- package/lib/NavMenu/images/did-connect.svg.js +0 -5
- package/lib/NavMenu/images/did-name-service.svg.js +0 -5
- package/lib/NavMenu/images/did-wallet.svg.js +0 -7
- package/lib/NavMenu/images/did.svg.js +0 -5
- package/lib/NavMenu/images/nft-studio.svg.js +0 -5
- package/lib/NavMenu/images/vc.svg.js +0 -5
- package/lib/NavMenu/images/web3-kit.svg.js +0 -7
- 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/SessionUser/images/did-spaces.svg.js +0 -5
- 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
- package/lib/Wallet/images/android_download.svg.js +0 -5
- package/lib/Wallet/images/app-store.svg.js +0 -5
- package/lib/Wallet/images/google-play.svg.js +0 -5
- package/lib/ux.css +0 -1
@@ -1,24 +1,24 @@
|
|
1
|
-
import { jsxs as
|
2
|
-
import { useTheme as u, Box as
|
1
|
+
import { jsxs as t, jsx as l } from "react/jsx-runtime";
|
2
|
+
import { useTheme as u, Box as a, Tooltip as x, Typography as h, IconButton as v } from "@mui/material";
|
3
3
|
import { Icon as m } from "@iconify/react";
|
4
|
-
import
|
5
|
-
import
|
6
|
-
import S from "../../Avatar
|
7
|
-
import { DID as g } from "../../DID
|
8
|
-
import { getSourceProvider as z } from "../libs/utils
|
9
|
-
function
|
10
|
-
ref: p,
|
4
|
+
import w from "@iconify-icons/material-symbols/lens";
|
5
|
+
import y from "../../WalletOSIcon";
|
6
|
+
import S from "../../Avatar";
|
7
|
+
import { DID as g } from "../../DID";
|
8
|
+
import { getSourceProvider as z } from "../libs/utils";
|
9
|
+
function W({
|
10
|
+
ref: p = void 0,
|
11
11
|
sessionItem: r,
|
12
12
|
statusContent: c = null,
|
13
|
-
active:
|
14
|
-
...
|
13
|
+
active: f = !1,
|
14
|
+
...e
|
15
15
|
}) {
|
16
|
-
var
|
17
|
-
const { palette:
|
18
|
-
return /* @__PURE__ */
|
19
|
-
|
16
|
+
var o, d;
|
17
|
+
const { palette: i } = u(), n = z(r == null ? void 0 : r.user) === "wallet";
|
18
|
+
return /* @__PURE__ */ t(
|
19
|
+
a,
|
20
20
|
{
|
21
|
-
...
|
21
|
+
...e,
|
22
22
|
ref: p,
|
23
23
|
sx: {
|
24
24
|
display: "flex",
|
@@ -27,11 +27,11 @@ function R({
|
|
27
27
|
py: 0.75,
|
28
28
|
px: 1,
|
29
29
|
width: "100%",
|
30
|
-
...
|
30
|
+
...e == null ? void 0 : e.sx
|
31
31
|
},
|
32
32
|
children: [
|
33
|
-
/* @__PURE__ */
|
34
|
-
|
33
|
+
/* @__PURE__ */ t(
|
34
|
+
a,
|
35
35
|
{
|
36
36
|
sx: {
|
37
37
|
display: "flex",
|
@@ -43,17 +43,17 @@ function R({
|
|
43
43
|
}
|
44
44
|
},
|
45
45
|
children: [
|
46
|
-
/* @__PURE__ */ l(
|
46
|
+
/* @__PURE__ */ l(a, { sx: { mr: 0.5, fontSize: 0 }, children: /* @__PURE__ */ l(S, { did: r.userDid, size: 36 }) }),
|
47
47
|
/* @__PURE__ */ l(
|
48
|
-
|
48
|
+
y,
|
49
49
|
{
|
50
|
-
color:
|
50
|
+
color: i.text.secondary,
|
51
51
|
loading: r.__isDefault,
|
52
|
-
provider: (
|
53
|
-
walletOS: (
|
52
|
+
provider: (o = r == null ? void 0 : r.extra) == null ? void 0 : o.provider,
|
53
|
+
walletOS: (d = r == null ? void 0 : r.extra) == null ? void 0 : d.walletOS
|
54
54
|
}
|
55
55
|
),
|
56
|
-
|
56
|
+
n ? /* @__PURE__ */ l(g, { did: r.userDid, copyable: !1, size: 14, responsive: !1, compact: !0, sx: { lineHeight: 1 } }) : r.user.email && /* @__PURE__ */ l(
|
57
57
|
x,
|
58
58
|
{
|
59
59
|
title: r.user.email,
|
@@ -77,11 +77,11 @@ function R({
|
|
77
77
|
]
|
78
78
|
}
|
79
79
|
),
|
80
|
-
c ||
|
80
|
+
c || f && /* @__PURE__ */ l(v, { size: "small", disableRipple: !0, children: /* @__PURE__ */ l(m, { icon: w, fontSize: 6, color: i.success.main }) })
|
81
81
|
]
|
82
82
|
}
|
83
83
|
);
|
84
84
|
}
|
85
85
|
export {
|
86
|
-
|
86
|
+
W as default
|
87
87
|
};
|
@@ -7,10 +7,10 @@ import V from "@iconify-icons/material-symbols/add-circle-outline-rounded";
|
|
7
7
|
import q from "@iconify-icons/material-symbols/expand-more-rounded";
|
8
8
|
import B from "@iconify-icons/material-symbols/swap-horiz-rounded";
|
9
9
|
import G from "lodash/pick";
|
10
|
-
import h from "./session-user-item
|
11
|
-
import { getVisitorId as J } from "../../Util
|
12
|
-
import { translate as K } from "../../Locale/util
|
13
|
-
import { translations as Q } from "../libs/translation
|
10
|
+
import h from "./session-user-item";
|
11
|
+
import { getVisitorId as J } from "../../Util";
|
12
|
+
import { translate as K } from "../../Locale/util";
|
13
|
+
import { translations as Q } from "../libs/translation";
|
14
14
|
function sr({
|
15
15
|
session: o,
|
16
16
|
onSwitch: g,
|
@@ -8,13 +8,13 @@ import Q from "lodash/noop";
|
|
8
8
|
import H from "@arcblock/icons/lib/DidBrandLogo";
|
9
9
|
import { useBrowser as K } from "@arcblock/react-hooks";
|
10
10
|
import { joinURL as V } from "ufo";
|
11
|
-
import X from "../../CloseButton
|
12
|
-
import { translate as q } from "../../Locale/util
|
13
|
-
import { translations as G } from "../libs/translation
|
14
|
-
import J from "../../Typography
|
15
|
-
import Y from "./quick-login-item
|
16
|
-
import { getFederatedEnabled as Z, getMaster as oo } from "../../Util/federated
|
17
|
-
import { BLOCKLET_SERVICE_PATH_PREFIX as eo } from "../../Util/constant
|
11
|
+
import X from "../../CloseButton";
|
12
|
+
import { translate as q } from "../../Locale/util";
|
13
|
+
import { translations as G } from "../libs/translation";
|
14
|
+
import J from "../../Typography";
|
15
|
+
import Y from "./quick-login-item";
|
16
|
+
import { getFederatedEnabled as Z, getMaster as oo } from "../../Util/federated";
|
17
|
+
import { BLOCKLET_SERVICE_PATH_PREFIX as eo } from "../../Util/constant";
|
18
18
|
function wo({ session: l, onLogin: f = Q, size: g = 24, dark: h = !1, locale: d = "en" }) {
|
19
19
|
const { palette: u } = P(), x = a((o, n = {}) => q(G, o, d, "en", n)), L = new URLSearchParams(window.location.search), b = K(), c = j(null), e = O({
|
20
20
|
open: !1,
|
@@ -1,17 +1,17 @@
|
|
1
1
|
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
2
2
|
import { Box as a, Typography as k, Chip as A, alpha as R } from "@mui/material";
|
3
|
-
import { Icon as
|
3
|
+
import { Icon as b } from "@iconify/react";
|
4
4
|
import U from "@iconify-icons/material-symbols/swap-horiz-rounded";
|
5
|
-
import
|
6
|
-
import { useMemoizedFn as
|
5
|
+
import j from "@iconify-icons/material-symbols/arrow-right-alt-rounded";
|
6
|
+
import { useMemoizedFn as D, useCreation as y } from "ahooks";
|
7
7
|
import w from "lodash/noop";
|
8
|
-
import
|
9
|
-
import { getUserAvatar as
|
10
|
-
import H from "./session-user-switch
|
11
|
-
import { getWallet as
|
12
|
-
import { translations as
|
13
|
-
import { translate as
|
14
|
-
function
|
8
|
+
import M from "../../Avatar";
|
9
|
+
import { getUserAvatar as W } from "../../Util";
|
10
|
+
import H from "./session-user-switch";
|
11
|
+
import { getWallet as F } from "../libs/utils";
|
12
|
+
import { translations as N } from "../libs/translation";
|
13
|
+
import { translate as T } from "../../Locale/util";
|
14
|
+
function Z({
|
15
15
|
session: r,
|
16
16
|
onSwitchPassport: p,
|
17
17
|
onSwitchAccount: v,
|
@@ -21,12 +21,12 @@ function Y({
|
|
21
21
|
isBlocklet: o = !0
|
22
22
|
}) {
|
23
23
|
var m, f, u, h, g;
|
24
|
-
const d =
|
24
|
+
const d = D((t, n = {}) => T(N, t, c, "en", n)), I = W((f = (m = r.user) == null ? void 0 : m.avatar) == null ? void 0 : f.replace(/\s/g, encodeURIComponent(" ")), 64), l = y(() => {
|
25
25
|
var t, n;
|
26
26
|
return (n = (t = r.user) == null ? void 0 : t.passports) == null ? void 0 : n.find(
|
27
27
|
(x) => x.name === r.user.role || x.role === r.user.role
|
28
28
|
);
|
29
|
-
}, [(u = r == null ? void 0 : r.user) == null ? void 0 : u.passports, (h = r == null ? void 0 : r.user) == null ? void 0 : h.role]), z =
|
29
|
+
}, [(u = r == null ? void 0 : r.user) == null ? void 0 : u.passports, (h = r == null ? void 0 : r.user) == null ? void 0 : h.role]), z = y(() => F(r == null ? void 0 : r.user), [r == null ? void 0 : r.user]);
|
30
30
|
return /* @__PURE__ */ i(
|
31
31
|
a,
|
32
32
|
{
|
@@ -88,7 +88,7 @@ function Y({
|
|
88
88
|
}
|
89
89
|
},
|
90
90
|
children: /* @__PURE__ */ e(
|
91
|
-
|
91
|
+
M,
|
92
92
|
{
|
93
93
|
variant: "circle",
|
94
94
|
did: r.user.did,
|
@@ -125,7 +125,7 @@ function Y({
|
|
125
125
|
boxShadow: "none"
|
126
126
|
}
|
127
127
|
},
|
128
|
-
deleteIcon: /* @__PURE__ */ e(
|
128
|
+
deleteIcon: /* @__PURE__ */ e(b, { icon: U, color: "inherit" }),
|
129
129
|
onDelete: p,
|
130
130
|
onClick: p,
|
131
131
|
"data-cy": "sessionManager-switch-passport-trigger"
|
@@ -155,7 +155,7 @@ function Y({
|
|
155
155
|
"data-cy": "sessionManager-bind-trigger",
|
156
156
|
children: [
|
157
157
|
d("connectDIDWallet"),
|
158
|
-
/* @__PURE__ */ e(
|
158
|
+
/* @__PURE__ */ e(b, { icon: j, color: "inherit", fontSize: 16 })
|
159
159
|
]
|
160
160
|
}
|
161
161
|
)
|
@@ -164,5 +164,5 @@ function Y({
|
|
164
164
|
);
|
165
165
|
}
|
166
166
|
export {
|
167
|
-
|
167
|
+
Z as default
|
168
168
|
};
|
package/lib/SessionUser/index.js
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
2
2
|
import f from "lodash/noop";
|
3
3
|
import { useCreation as p } from "ahooks";
|
4
|
-
import u from "./components/logged-in
|
5
|
-
import l from "./components/un-login
|
4
|
+
import u from "./components/logged-in";
|
5
|
+
import l from "./components/un-login";
|
6
6
|
function b({
|
7
7
|
session: r,
|
8
8
|
onBindWallet: e = f,
|
@@ -1,20 +1,20 @@
|
|
1
1
|
import { jsx as g } from "react/jsx-runtime";
|
2
2
|
import { Box as I } from "@mui/material";
|
3
|
-
import { memo as v, useRef as w, useId as S, useEffect as
|
4
|
-
import { withQuery as
|
5
|
-
import { useReactive as
|
3
|
+
import { memo as v, useRef as w, useId as S, useEffect as x, useImperativeHandle as A } from "react";
|
4
|
+
import { withQuery as L } from "ufo";
|
5
|
+
import { useReactive as b, useMemoizedFn as y } from "ahooks";
|
6
6
|
import E from "lodash/noop";
|
7
|
-
import { mergeSx as R } from "../Util/style
|
8
|
-
import { callIframe as i, getCallbackAction as c } from "../Util/iframe
|
9
|
-
function
|
10
|
-
ref: d,
|
7
|
+
import { mergeSx as R } from "../Util/style";
|
8
|
+
import { callIframe as i, getCallbackAction as c } from "../Util/iframe";
|
9
|
+
function q({
|
10
|
+
ref: d = void 0,
|
11
11
|
src: o,
|
12
12
|
onClick: s,
|
13
13
|
onLoad: u = E,
|
14
|
-
sx: m,
|
14
|
+
sx: m = {},
|
15
15
|
...f
|
16
16
|
}) {
|
17
|
-
const
|
17
|
+
const t = w(null), n = `shared-bridge_${S()}`, r = b({
|
18
18
|
hasInited: void 0,
|
19
19
|
open: !1,
|
20
20
|
hasStorageAccess: !1,
|
@@ -34,42 +34,42 @@ function B({
|
|
34
34
|
}
|
35
35
|
}
|
36
36
|
});
|
37
|
-
|
37
|
+
x(() => {
|
38
38
|
async function e(h) {
|
39
39
|
const { data: a } = h;
|
40
40
|
if (a.action === c(n, "requestStorageAccess")) {
|
41
|
-
if (
|
41
|
+
if (r.open = !1, !a.value) {
|
42
42
|
s(a);
|
43
43
|
return;
|
44
44
|
}
|
45
|
-
const { value: p } = await i(
|
45
|
+
const { value: p } = await i(t.current, "getVisitorId");
|
46
46
|
s({ ...a, visitorId: p });
|
47
|
-
} else a.action === c(n, "preRequestStorageAccess") && (
|
47
|
+
} else a.action === c(n, "preRequestStorageAccess") && (r.open = !0);
|
48
48
|
}
|
49
49
|
return window.addEventListener("message", e), () => {
|
50
50
|
window.removeEventListener("message", e);
|
51
51
|
};
|
52
|
-
}, [s, n,
|
52
|
+
}, [s, n, t == null ? void 0 : t.current]);
|
53
53
|
const l = y(() => {
|
54
|
-
i(
|
55
|
-
|
54
|
+
i(t.current, "hasStorageAccess").then(({ value: e }) => {
|
55
|
+
r.hasStorageAccess = e, r.hasInited = !0;
|
56
56
|
}), setTimeout(() => {
|
57
|
-
|
57
|
+
r.hasInited === void 0 && (r.hasInited = !1);
|
58
58
|
}, 1e3), u();
|
59
59
|
});
|
60
|
-
return
|
60
|
+
return A(d, () => ({
|
61
61
|
callIframe(e) {
|
62
|
-
return i(
|
62
|
+
return i(t.current, e);
|
63
63
|
}
|
64
64
|
})), /* @__PURE__ */ g(
|
65
65
|
I,
|
66
66
|
{
|
67
67
|
...f,
|
68
68
|
component: "iframe",
|
69
|
-
ref:
|
69
|
+
ref: t,
|
70
70
|
onLoad: l,
|
71
71
|
"data-id": n,
|
72
|
-
src:
|
72
|
+
src: L(o, { id: n }),
|
73
73
|
sx: R(
|
74
74
|
{
|
75
75
|
border: 0,
|
@@ -86,7 +86,7 @@ function B({
|
|
86
86
|
}
|
87
87
|
);
|
88
88
|
}
|
89
|
-
const
|
89
|
+
const V = v(q);
|
90
90
|
export {
|
91
|
-
|
91
|
+
V as default
|
92
92
|
};
|
package/lib/Spinner/index.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
2
2
|
import { CircularProgress as t } from "@mui/material";
|
3
|
-
import { withDeprecated as a } from "../Util/deprecate
|
4
|
-
function n(r) {
|
3
|
+
import { withDeprecated as a } from "../Util/deprecate";
|
4
|
+
function n({ ...r }) {
|
5
5
|
const e = { ...r };
|
6
6
|
return e.size && Array.isArray(r.size) && ([e.size] = r.size), /* @__PURE__ */ i(t, { ...e });
|
7
7
|
}
|
@@ -6,7 +6,7 @@ export interface SplitButtonProps extends Omit<ButtonGroupProps, 'children'> {
|
|
6
6
|
onClick?: () => void;
|
7
7
|
menuButtonProps?: ButtonProps;
|
8
8
|
}
|
9
|
-
declare function SplitButton(props: SplitButtonProps): import("react/jsx-runtime").JSX.Element;
|
9
|
+
declare function SplitButton({ ...props }: SplitButtonProps): import("react/jsx-runtime").JSX.Element;
|
10
10
|
declare namespace SplitButton {
|
11
11
|
var Item: import("@mui/material").ExtendButtonBase<import("@mui/material").MenuItemTypeMap<{}, "li">>;
|
12
12
|
}
|
package/lib/SplitButton/index.js
CHANGED
@@ -3,8 +3,8 @@ import { useState as P, useRef as b, createElement as A, isValidElement as E } f
|
|
3
3
|
import { ExpandMore as L } from "@mui/icons-material";
|
4
4
|
import { ButtonGroup as S, Popper as w, MenuItem as p, Button as c, Paper as z, ClickAwayListener as j, MenuList as G } from "@mui/material";
|
5
5
|
import R from "lodash/noop";
|
6
|
-
import { styled as d } from "../Theme
|
7
|
-
function v(o) {
|
6
|
+
import { styled as d } from "../Theme";
|
7
|
+
function v({ ...o }) {
|
8
8
|
const {
|
9
9
|
size: m = "medium",
|
10
10
|
color: r = "primary",
|
package/lib/Success/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { jsxs as l, jsx as i } from "react/jsx-runtime";
|
2
2
|
import { useTheme as p, Box as e } from "@mui/material";
|
3
|
-
function x({ size: s = 64, backgroundColor: r, borderWidth: t = 4 }) {
|
3
|
+
function x({ size: s = 64, backgroundColor: r = void 0, borderWidth: t = 4 }) {
|
4
4
|
const { palette: c } = p(), o = s - t * 2, a = r || c.background.default;
|
5
5
|
return /* @__PURE__ */ l(
|
6
6
|
e,
|
package/lib/Switch/index.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
2
2
|
import a from "prop-types";
|
3
3
|
import { Switch as c, FormControlLabel as e } from "@mui/material";
|
4
|
-
import { styled as l } from "../Theme
|
4
|
+
import { styled as l } from "../Theme";
|
5
5
|
const r = l((i) => /* @__PURE__ */ t(c, { focusVisibleClassName: ".Mui-focusVisible", disableRipple: !0, ...i }))(
|
6
6
|
({ theme: i }) => ({
|
7
7
|
width: 42,
|
package/lib/Tabs/index.js
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
2
2
|
import { Tabs as u, Tab as c } from "@mui/material";
|
3
|
-
import { styled as p } from "../Theme
|
4
|
-
const
|
5
|
-
tabs: `${
|
6
|
-
tab: `${
|
3
|
+
import { styled as p } from "../Theme";
|
4
|
+
const d = "index", s = {
|
5
|
+
tabs: `${d}-tabs`,
|
6
|
+
tab: `${d}-tab`
|
7
7
|
}, m = p(u)(({ theme: e }) => ({
|
8
8
|
[`& .${s.tabs}`]: {},
|
9
9
|
[`& .${s.tab}`]: {
|
@@ -13,7 +13,7 @@ const b = "index", s = {
|
|
13
13
|
}
|
14
14
|
}
|
15
15
|
}));
|
16
|
-
function
|
16
|
+
function v({ tabs: e, current: t, onChange: r, iconPosition: n = void 0, ...o }) {
|
17
17
|
return /* @__PURE__ */ l(
|
18
18
|
u,
|
19
19
|
{
|
@@ -77,7 +77,7 @@ function f({ tabs: e, current: t, onChange: r, iconPosition: n, ...o }) {
|
|
77
77
|
}
|
78
78
|
);
|
79
79
|
}
|
80
|
-
function
|
80
|
+
function f({ tabs: e, current: t, onChange: r, iconPosition: n = void 0, ...o }) {
|
81
81
|
return /* @__PURE__ */ l(
|
82
82
|
u,
|
83
83
|
{
|
@@ -146,14 +146,21 @@ function v({ tabs: e, current: t, onChange: r, iconPosition: n, ...o }) {
|
|
146
146
|
}
|
147
147
|
);
|
148
148
|
}
|
149
|
-
function T({
|
150
|
-
|
149
|
+
function T({
|
150
|
+
tabs: e,
|
151
|
+
current: t,
|
152
|
+
onChange: r,
|
153
|
+
variant: n = void 0,
|
154
|
+
iconPosition: o = void 0,
|
155
|
+
...a
|
156
|
+
}) {
|
157
|
+
return n === "card" ? /* @__PURE__ */ l(v, { ...a, tabs: e, current: t, onChange: r, iconPosition: o }) : n === "line" ? /* @__PURE__ */ l(f, { ...a, tabs: e, current: t, onChange: r, iconPosition: o }) : /* @__PURE__ */ l(
|
151
158
|
m,
|
152
159
|
{
|
153
160
|
scrollButtons: "auto",
|
154
161
|
variant: "scrollable",
|
155
162
|
value: t,
|
156
|
-
onChange: (i,
|
163
|
+
onChange: (i, b) => r(b),
|
157
164
|
indicatorColor: "primary",
|
158
165
|
...a,
|
159
166
|
className: [s.tabs, a.className || ""].join(" "),
|
package/lib/Tag/index.d.ts
CHANGED
@@ -25,7 +25,7 @@ export type TagProps = TypographyProps & TagOwnProps;
|
|
25
25
|
* @param {TagProps} props
|
26
26
|
* @return {import('react').ReactNode}
|
27
27
|
*/
|
28
|
-
declare function Tag(rawProps:
|
28
|
+
declare function Tag({ ...rawProps }: TagProps): import('react').ReactNode;
|
29
29
|
declare namespace Tag {
|
30
30
|
namespace propTypes {
|
31
31
|
let children: PropTypes.Validator<any>;
|
package/lib/Tag/index.js
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
import { jsx as h } from "react/jsx-runtime";
|
2
2
|
import r from "prop-types";
|
3
|
-
import { Typography as u
|
3
|
+
import { Typography as u } from "@mui/material";
|
4
4
|
import n from "lodash/isUndefined";
|
5
|
-
import { mergeProps as
|
6
|
-
import e from "../Colors
|
7
|
-
import { styled as w } from "../Theme
|
5
|
+
import { mergeProps as b } from "../Util";
|
6
|
+
import e from "../Colors";
|
7
|
+
import { styled as x, useTheme as w } from "../Theme";
|
8
8
|
const i = {
|
9
9
|
error: {
|
10
10
|
color: e.common.white,
|
@@ -27,10 +27,10 @@ const i = {
|
|
27
27
|
backgroundColor: "#222"
|
28
28
|
}
|
29
29
|
};
|
30
|
-
function a(m) {
|
30
|
+
function a({ ...m }) {
|
31
31
|
const o = Object.assign({}, m);
|
32
32
|
n(o.type) && (o.type = "primary"), n(o.content) && (o.content = ""), n(o.style) && (o.style = {}), n(o.className) && (o.className = "");
|
33
|
-
const p =
|
33
|
+
const p = b(o, a, ["style"]), { type: t, content: l, children: y, style: f, className: g, ...d } = p, { palette: s } = w(), c = Object.assign({}, i[t] || i.primary, f);
|
34
34
|
return s[t] && Object.assign(c, {
|
35
35
|
color: s[t].contrastText || e.common.white,
|
36
36
|
backgroundColor: s[t].main
|
@@ -43,7 +43,7 @@ a.propTypes = {
|
|
43
43
|
className: r.string,
|
44
44
|
style: r.oneOfType([r.object, r.string])
|
45
45
|
};
|
46
|
-
const j =
|
46
|
+
const j = x(u)`
|
47
47
|
&& {
|
48
48
|
display: inline-flex;
|
49
49
|
justify-content: center;
|
@@ -1,14 +1,14 @@
|
|
1
1
|
import { jsxs as f, jsx as r } from "react/jsx-runtime";
|
2
2
|
import { Typography as x } from "@mui/material";
|
3
|
-
import { styled as y } from "../Theme
|
4
|
-
import { withDeprecated as u } from "../Util/deprecate
|
3
|
+
import { styled as y } from "../Theme";
|
4
|
+
import { withDeprecated as u } from "../Util/deprecate";
|
5
5
|
function g({
|
6
6
|
children: t,
|
7
7
|
maxWidth: s,
|
8
8
|
startChars: n = 5,
|
9
9
|
endChars: e = 5,
|
10
10
|
scaleFactor: o = 0.45,
|
11
|
-
style: a,
|
11
|
+
style: a = void 0,
|
12
12
|
fontType: l = "normal",
|
13
13
|
...p
|
14
14
|
}) {
|
package/lib/Theme/index.js
CHANGED
@@ -1,25 +1,14 @@
|
|
1
|
-
import { styled as
|
2
|
-
import { useTheme as
|
3
|
-
|
4
|
-
|
5
|
-
import {
|
6
|
-
const
|
7
|
-
...
|
8
|
-
shouldForwardProp: (t) =>
|
1
|
+
import { styled as o } from "@mui/material";
|
2
|
+
import { useTheme as f } from "@mui/material";
|
3
|
+
export * from "./theme";
|
4
|
+
export * from "./theme-provider";
|
5
|
+
import { default as P } from "./theme-provider";
|
6
|
+
const d = (e) => e.startsWith("$"), a = (e, r) => o(e, {
|
7
|
+
...r,
|
8
|
+
shouldForwardProp: (t) => r != null && r.shouldForwardProp ? r.shouldForwardProp(t) && !d(t) : !d(t)
|
9
9
|
});
|
10
10
|
export {
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
f as create,
|
15
|
-
T as createDefaultThemeOptions,
|
16
|
-
x as createTheme,
|
17
|
-
S as deepmerge,
|
18
|
-
F as isTheme,
|
19
|
-
i as isUxTheme,
|
20
|
-
n as lazyCreateDefaultTheme,
|
21
|
-
P as loadFonts,
|
22
|
-
l as styled,
|
23
|
-
p as useColorScheme,
|
24
|
-
h as useTheme
|
11
|
+
P as ThemeProvider,
|
12
|
+
a as styled,
|
13
|
+
f as useTheme
|
25
14
|
};
|