@vechain/vechain-kit 1.5.4 → 1.5.6
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/index.cjs +340 -260
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +49 -40
- package/dist/index.d.ts +49 -40
- package/dist/index.js +343 -263
- package/dist/index.js.map +1 -1
- package/dist/metafile-cjs.json +1 -1
- package/dist/metafile-esm.json +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -22,10 +22,10 @@ import { z } from 'zod';
|
|
|
22
22
|
import { useAccount, createConfig, http, WagmiProvider, useConnect, useSignTypedData, useSignMessage, useDisconnect } from 'wagmi';
|
|
23
23
|
import { toPrivyWalletConnector } from '@privy-io/cross-app-connect/rainbow-kit';
|
|
24
24
|
import { isMobile } from 'react-device-detect';
|
|
25
|
-
import { createMultiStyleConfigHelpers, defineStyle, defineStyleConfig, extendTheme, createStandaloneToast, IconButton, VStack, Text, InputGroup, InputLeftElement, Icon, Input, InputRightElement, HStack, Link, Box, useMediaQuery, Modal, ModalOverlay, ModalContent, Button, Image, Skeleton, Spinner, useDisclosure, GridItem, ModalHeader, ModalCloseButton, ModalBody, ModalFooter,
|
|
25
|
+
import { createMultiStyleConfigHelpers, defineStyle, defineStyleConfig, extendTheme, createStandaloneToast, IconButton, VStack, Text, InputGroup, InputLeftElement, Icon, Input, InputRightElement, HStack, Link, Box, useMediaQuery, Modal, ModalOverlay, ModalContent, Button, Image, Skeleton, Spinner, useDisclosure, GridItem, ModalHeader, ModalCloseButton, ModalBody, ModalFooter, Tag, useColorMode, Heading, useColorModeValue, Tabs, TabList, Tab, TabPanels, TabPanel, Grid, Card, CardBody, Alert, AlertIcon, Divider, FormControl, Center, Container, Select, FormLabel, Textarea, Circle, AlertTitle, AlertDescription, Popover, PopoverTrigger, PopoverContent, PopoverBody, CardFooter, PinInput, PinInputField, Stack, Accordion, AccordionItem, AccordionButton, AccordionPanel, List, ListItem, ChakraProvider, ColorModeScript, Flex } from '@chakra-ui/react';
|
|
26
26
|
import { motion } from 'framer-motion';
|
|
27
|
-
import { IoChevronBack, IoCheckmarkOutline, IoCopyOutline, IoWalletOutline, IoCloseCircle, IoShieldOutline, IoOpenOutline,
|
|
28
|
-
import { FaRegAddressCard, FaExternalLinkAlt, FaGlobe, FaEnvelope, FaTelegramPlane, FaChevronDown, FaEdit, FaGoogle, FaTwitter, FaPhone, FaSpotify, FaApple, FaInstagram, FaTiktok, FaGithub, FaLinkedin, FaTelegram, FaDiscord as FaDiscord$1, FaWallet, FaPlus } from 'react-icons/fa';
|
|
27
|
+
import { IoChevronBack, IoCheckmarkOutline, IoCopyOutline, IoWalletOutline, IoCloseCircle, IoShieldOutline, IoOpenOutline, IoTrashBin, IoChevronUp, IoChevronDown, IoCloseOutline } from 'react-icons/io5';
|
|
28
|
+
import { FaRegAddressCard, FaExternalLinkAlt, FaGlobe, FaEnvelope, FaArrowRight, FaTelegramPlane, FaChevronDown, FaEdit, FaGoogle, FaTwitter, FaPhone, FaSpotify, FaApple, FaInstagram, FaTiktok, FaGithub, FaLinkedin, FaTelegram, FaDiscord as FaDiscord$1, FaWallet, FaPlus } from 'react-icons/fa';
|
|
29
29
|
import { HiOutlineWallet, HiOutlineShieldCheck } from 'react-icons/hi2';
|
|
30
30
|
import { BsQuestionCircle, BsBookmarkFill, BsBookmark } from 'react-icons/bs';
|
|
31
31
|
import { LuMail, LuArrowDownToLine } from 'react-icons/lu';
|
|
@@ -4978,7 +4978,7 @@ var AddressDisplay = ({
|
|
|
4978
4978
|
// package.json
|
|
4979
4979
|
var package_default = {
|
|
4980
4980
|
name: "@vechain/vechain-kit",
|
|
4981
|
-
version: "1.5.
|
|
4981
|
+
version: "1.5.6",
|
|
4982
4982
|
private: false,
|
|
4983
4983
|
homepage: "https://github.com/vechain/vechain-kit",
|
|
4984
4984
|
repository: "github:vechain/vechain-kit",
|
|
@@ -5453,7 +5453,8 @@ var TransactionButtonAndStatus = ({
|
|
|
5453
5453
|
txReceipt,
|
|
5454
5454
|
isSubmitForm = false,
|
|
5455
5455
|
buttonText,
|
|
5456
|
-
isDisabled = false
|
|
5456
|
+
isDisabled = false,
|
|
5457
|
+
style
|
|
5457
5458
|
}) => {
|
|
5458
5459
|
const { t } = useTranslation();
|
|
5459
5460
|
const { darkMode: isDark } = useVeChainKitConfig();
|
|
@@ -5462,6 +5463,10 @@ var TransactionButtonAndStatus = ({
|
|
|
5462
5463
|
if (!transactionError) return null;
|
|
5463
5464
|
return transactionError.reason || t("Something went wrong. Please try again.");
|
|
5464
5465
|
}, [transactionError, t]);
|
|
5466
|
+
const buttonBg = useMemo(() => {
|
|
5467
|
+
if (style?.accentColor) return `${style.accentColor} !important`;
|
|
5468
|
+
return void 0;
|
|
5469
|
+
}, [style?.accentColor]);
|
|
5465
5470
|
return /* @__PURE__ */ jsxs(VStack, { width: "full", spacing: 4, children: [
|
|
5466
5471
|
errorMessage && /* @__PURE__ */ jsx(Text, { color: "#da5a5a", textAlign: "center", width: "full", children: errorMessage }),
|
|
5467
5472
|
/* @__PURE__ */ jsx(
|
|
@@ -5469,6 +5474,7 @@ var TransactionButtonAndStatus = ({
|
|
|
5469
5474
|
{
|
|
5470
5475
|
px: 4,
|
|
5471
5476
|
variant: "vechainKitPrimary",
|
|
5477
|
+
bg: buttonBg,
|
|
5472
5478
|
onClick: onConfirm,
|
|
5473
5479
|
type: isSubmitForm ? "submit" : "button",
|
|
5474
5480
|
isLoading: isSubmitting,
|
|
@@ -5882,7 +5888,7 @@ var DappKitButton = ({ isDark, gridColumn = 2 }) => {
|
|
|
5882
5888
|
isDark,
|
|
5883
5889
|
onClick: openDappKitModal,
|
|
5884
5890
|
icon: IoWalletOutline,
|
|
5885
|
-
text: gridColumn >= 2 ? t("Connect
|
|
5891
|
+
text: gridColumn >= 2 ? t("Connect wallet") : void 0,
|
|
5886
5892
|
rightIcon: /* @__PURE__ */ jsx(Icon, { as: IoIosArrowForward })
|
|
5887
5893
|
}
|
|
5888
5894
|
) });
|
|
@@ -6072,110 +6078,9 @@ var MainContent = ({ setCurrentContent, onClose }) => {
|
|
|
6072
6078
|
/* @__PURE__ */ jsx(ModalFooter, { pt: 0, pb: "5px", children: /* @__PURE__ */ jsx(VersionFooter, {}) })
|
|
6073
6079
|
] });
|
|
6074
6080
|
};
|
|
6075
|
-
var useFeatureAnnouncement = () => {
|
|
6076
|
-
const [isVisible, setIsVisible] = useState(true);
|
|
6077
|
-
const CACHE_KEY = "vechain_kit_feature_announcement_closed";
|
|
6078
|
-
useEffect(() => {
|
|
6079
|
-
const isClosed = localStorage.getItem(CACHE_KEY);
|
|
6080
|
-
if (isClosed) {
|
|
6081
|
-
setIsVisible(false);
|
|
6082
|
-
}
|
|
6083
|
-
}, []);
|
|
6084
|
-
const closeAnnouncement = () => {
|
|
6085
|
-
localStorage.setItem(CACHE_KEY, "true");
|
|
6086
|
-
setIsVisible(false);
|
|
6087
|
-
};
|
|
6088
|
-
return {
|
|
6089
|
-
isVisible,
|
|
6090
|
-
closeAnnouncement
|
|
6091
|
-
};
|
|
6092
|
-
};
|
|
6093
|
-
var FeatureAnnouncementCard = ({
|
|
6094
|
-
setCurrentContent
|
|
6095
|
-
}) => {
|
|
6096
|
-
const { t } = useTranslation();
|
|
6097
|
-
const { isVisible, closeAnnouncement } = useFeatureAnnouncement();
|
|
6098
|
-
const titleColor = useColorModeValue("gray.800", "whiteAlpha.900");
|
|
6099
|
-
const handleOnClick = () => {
|
|
6100
|
-
setCurrentContent({
|
|
6101
|
-
type: "choose-name",
|
|
6102
|
-
props: {
|
|
6103
|
-
setCurrentContent,
|
|
6104
|
-
onBack: () => setCurrentContent("main"),
|
|
6105
|
-
initialContentSource: "main"
|
|
6106
|
-
}
|
|
6107
|
-
});
|
|
6108
|
-
closeAnnouncement();
|
|
6109
|
-
};
|
|
6110
|
-
if (!isVisible) return null;
|
|
6111
|
-
return /* @__PURE__ */ jsx(
|
|
6112
|
-
Card,
|
|
6113
|
-
{
|
|
6114
|
-
w: "full",
|
|
6115
|
-
variant: "featureAnnouncement",
|
|
6116
|
-
overflow: "hidden",
|
|
6117
|
-
mb: 4,
|
|
6118
|
-
onClick: handleOnClick,
|
|
6119
|
-
cursor: "pointer",
|
|
6120
|
-
_hover: { opacity: 0.8 },
|
|
6121
|
-
children: /* @__PURE__ */ jsx(CardBody, { p: 4, children: /* @__PURE__ */ jsxs(HStack, { justify: "space-between", align: "flex-start", spacing: 3, children: [
|
|
6122
|
-
/* @__PURE__ */ jsxs(VStack, { align: "flex-start", spacing: 1, children: [
|
|
6123
|
-
/* @__PURE__ */ jsxs(HStack, { spacing: 2, children: [
|
|
6124
|
-
/* @__PURE__ */ jsx(
|
|
6125
|
-
Text,
|
|
6126
|
-
{
|
|
6127
|
-
fontSize: "sm",
|
|
6128
|
-
fontWeight: "400",
|
|
6129
|
-
color: titleColor,
|
|
6130
|
-
children: t("Claim your vet domain!")
|
|
6131
|
-
}
|
|
6132
|
-
),
|
|
6133
|
-
/* @__PURE__ */ jsx(Tag, { size: "sm", colorScheme: "red", children: t("New") })
|
|
6134
|
-
] }),
|
|
6135
|
-
/* @__PURE__ */ jsx(Text, { fontSize: "xs", opacity: 0.5, children: t(
|
|
6136
|
-
"Say goodbye to 0x addresses, claim your .veworld.vet subdomain now for free!"
|
|
6137
|
-
) })
|
|
6138
|
-
] }),
|
|
6139
|
-
/* @__PURE__ */ jsx(
|
|
6140
|
-
IconButton,
|
|
6141
|
-
{
|
|
6142
|
-
size: "sm",
|
|
6143
|
-
variant: "ghost",
|
|
6144
|
-
colorScheme: "gray",
|
|
6145
|
-
icon: /* @__PURE__ */ jsx(IoCloseCircle, {}),
|
|
6146
|
-
onClick: (e) => {
|
|
6147
|
-
e.stopPropagation();
|
|
6148
|
-
closeAnnouncement();
|
|
6149
|
-
},
|
|
6150
|
-
"aria-label": t("Close announcement")
|
|
6151
|
-
}
|
|
6152
|
-
)
|
|
6153
|
-
] }) })
|
|
6154
|
-
}
|
|
6155
|
-
);
|
|
6156
|
-
};
|
|
6157
|
-
var ExchangeWarningAlert = () => {
|
|
6158
|
-
const { t } = useTranslation();
|
|
6159
|
-
return /* @__PURE__ */ jsx(Alert, { status: "warning", fontSize: "xs", borderRadius: "xl", p: 2, children: /* @__PURE__ */ jsx(VStack, { spacing: 1, align: "stretch", w: "full", children: /* @__PURE__ */ jsxs(HStack, { spacing: 2, align: "flex-start", children: [
|
|
6160
|
-
/* @__PURE__ */ jsx(AlertIcon, { boxSize: 4, mt: "10px" }),
|
|
6161
|
-
/* @__PURE__ */ jsx(Text, { w: "full", children: t(
|
|
6162
|
-
"Sending to OceanX or other exchanges may result in loss of funds."
|
|
6163
|
-
) })
|
|
6164
|
-
] }) }) });
|
|
6165
|
-
};
|
|
6166
|
-
var DomainRequiredAlert = () => {
|
|
6167
|
-
const { t } = useTranslation();
|
|
6168
|
-
return /* @__PURE__ */ jsx(Alert, { status: "warning", fontSize: "xs", borderRadius: "xl", p: 2, children: /* @__PURE__ */ jsx(VStack, { spacing: 1, align: "stretch", w: "full", children: /* @__PURE__ */ jsxs(HStack, { spacing: 2, align: "flex-start", children: [
|
|
6169
|
-
/* @__PURE__ */ jsx(AlertIcon, { boxSize: 4, mt: "10px" }),
|
|
6170
|
-
/* @__PURE__ */ jsx(Text, { w: "full", children: t(
|
|
6171
|
-
"A .vet domain is required to customize your profile. Choose an account name to get started."
|
|
6172
|
-
) })
|
|
6173
|
-
] }) }) });
|
|
6174
|
-
};
|
|
6175
6081
|
var AccountMainContent = ({ setCurrentContent, wallet }) => {
|
|
6176
6082
|
const { t } = useTranslation();
|
|
6177
6083
|
const { network } = useVeChainKitConfig();
|
|
6178
|
-
const { account } = useWallet();
|
|
6179
6084
|
return /* @__PURE__ */ jsxs(ScrollToTopWrapper, { children: [
|
|
6180
6085
|
/* @__PURE__ */ jsxs(StickyHeaderContainer, { children: [
|
|
6181
6086
|
/* @__PURE__ */ jsx(
|
|
@@ -6189,7 +6094,29 @@ var AccountMainContent = ({ setCurrentContent, wallet }) => {
|
|
|
6189
6094
|
})
|
|
6190
6095
|
}
|
|
6191
6096
|
),
|
|
6192
|
-
/* @__PURE__ */ jsx(ModalHeader, { children:
|
|
6097
|
+
/* @__PURE__ */ jsx(ModalHeader, { children: /* @__PURE__ */ jsxs(
|
|
6098
|
+
HStack,
|
|
6099
|
+
{
|
|
6100
|
+
w: "full",
|
|
6101
|
+
justifyContent: "center",
|
|
6102
|
+
p: 0,
|
|
6103
|
+
spacing: 2,
|
|
6104
|
+
children: [
|
|
6105
|
+
/* @__PURE__ */ jsx(Text, { fontSize: "md", fontWeight: "bold", children: t("Wallet") }),
|
|
6106
|
+
network?.type !== "main" && /* @__PURE__ */ jsx(
|
|
6107
|
+
Tag,
|
|
6108
|
+
{
|
|
6109
|
+
size: "xs",
|
|
6110
|
+
colorScheme: "orange",
|
|
6111
|
+
fontSize: "2xs",
|
|
6112
|
+
p: 1,
|
|
6113
|
+
textTransform: "uppercase",
|
|
6114
|
+
children: `${network?.type}`
|
|
6115
|
+
}
|
|
6116
|
+
)
|
|
6117
|
+
]
|
|
6118
|
+
}
|
|
6119
|
+
) }),
|
|
6193
6120
|
/* @__PURE__ */ jsx(ModalCloseButton, {})
|
|
6194
6121
|
] }),
|
|
6195
6122
|
/* @__PURE__ */ jsx(ModalBody, { w: "full", children: /* @__PURE__ */ jsxs(
|
|
@@ -6200,12 +6127,6 @@ var AccountMainContent = ({ setCurrentContent, wallet }) => {
|
|
|
6200
6127
|
justifyContent: "flex-start",
|
|
6201
6128
|
spacing: 6,
|
|
6202
6129
|
children: [
|
|
6203
|
-
!account?.domain && /* @__PURE__ */ jsx(
|
|
6204
|
-
FeatureAnnouncementCard,
|
|
6205
|
-
{
|
|
6206
|
-
setCurrentContent
|
|
6207
|
-
}
|
|
6208
|
-
),
|
|
6209
6130
|
/* @__PURE__ */ jsx(
|
|
6210
6131
|
AccountSelector,
|
|
6211
6132
|
{
|
|
@@ -6216,26 +6137,6 @@ var AccountMainContent = ({ setCurrentContent, wallet }) => {
|
|
|
6216
6137
|
wallet
|
|
6217
6138
|
}
|
|
6218
6139
|
),
|
|
6219
|
-
network?.type !== "main" && /* @__PURE__ */ jsx(
|
|
6220
|
-
HStack,
|
|
6221
|
-
{
|
|
6222
|
-
w: "full",
|
|
6223
|
-
justifyContent: "flex-start",
|
|
6224
|
-
mt: "-10px",
|
|
6225
|
-
mb: "-10px",
|
|
6226
|
-
children: /* @__PURE__ */ jsx(
|
|
6227
|
-
Tag,
|
|
6228
|
-
{
|
|
6229
|
-
size: "xl",
|
|
6230
|
-
colorScheme: "orange",
|
|
6231
|
-
fontSize: "xs",
|
|
6232
|
-
p: 2,
|
|
6233
|
-
textTransform: "capitalize",
|
|
6234
|
-
children: `${network?.type} network`
|
|
6235
|
-
}
|
|
6236
|
-
)
|
|
6237
|
-
}
|
|
6238
|
-
),
|
|
6239
6140
|
/* @__PURE__ */ jsx(
|
|
6240
6141
|
BalanceSection,
|
|
6241
6142
|
{
|
|
@@ -6439,7 +6340,7 @@ var AccountSelector = ({
|
|
|
6439
6340
|
props: { width: 7, height: 7 }
|
|
6440
6341
|
}
|
|
6441
6342
|
),
|
|
6442
|
-
/* @__PURE__ */ jsx(Text, { fontSize: size, fontWeight: "500", children: humanDomain(wallet?.domain ?? "",
|
|
6343
|
+
/* @__PURE__ */ jsx(Text, { fontSize: size, fontWeight: "500", children: humanDomain(wallet?.domain ?? "", 18, 0) || humanAddress(wallet?.address ?? "", 6, 4) })
|
|
6443
6344
|
] }),
|
|
6444
6345
|
/* @__PURE__ */ jsx(
|
|
6445
6346
|
Icon,
|
|
@@ -6863,6 +6764,109 @@ var QuickActionsSection = ({ mt, setCurrentContent }) => {
|
|
|
6863
6764
|
)) })
|
|
6864
6765
|
] });
|
|
6865
6766
|
};
|
|
6767
|
+
var useFeatureAnnouncement = () => {
|
|
6768
|
+
const [isVisible, setIsVisible] = useState(true);
|
|
6769
|
+
const CACHE_KEY = "vechain_kit_feature_announcement_closed";
|
|
6770
|
+
useEffect(() => {
|
|
6771
|
+
const isClosed = localStorage.getItem(CACHE_KEY);
|
|
6772
|
+
if (isClosed) {
|
|
6773
|
+
setIsVisible(false);
|
|
6774
|
+
}
|
|
6775
|
+
}, []);
|
|
6776
|
+
const closeAnnouncement = () => {
|
|
6777
|
+
localStorage.setItem(CACHE_KEY, "true");
|
|
6778
|
+
setIsVisible(false);
|
|
6779
|
+
};
|
|
6780
|
+
return {
|
|
6781
|
+
isVisible,
|
|
6782
|
+
closeAnnouncement
|
|
6783
|
+
};
|
|
6784
|
+
};
|
|
6785
|
+
var FeatureAnnouncementCard = ({
|
|
6786
|
+
setCurrentContent
|
|
6787
|
+
}) => {
|
|
6788
|
+
const { t } = useTranslation();
|
|
6789
|
+
const { isVisible, closeAnnouncement } = useFeatureAnnouncement();
|
|
6790
|
+
const titleColor = useColorModeValue("blackAlpha.800", "whiteAlpha.800");
|
|
6791
|
+
const descriptionColor = useColorModeValue(
|
|
6792
|
+
"blackAlpha.700",
|
|
6793
|
+
"whiteAlpha.700"
|
|
6794
|
+
);
|
|
6795
|
+
const handleOnClick = () => {
|
|
6796
|
+
setCurrentContent({
|
|
6797
|
+
type: "choose-name",
|
|
6798
|
+
props: {
|
|
6799
|
+
setCurrentContent,
|
|
6800
|
+
onBack: () => setCurrentContent("main"),
|
|
6801
|
+
initialContentSource: "main"
|
|
6802
|
+
}
|
|
6803
|
+
});
|
|
6804
|
+
closeAnnouncement();
|
|
6805
|
+
};
|
|
6806
|
+
if (!isVisible) return null;
|
|
6807
|
+
return /* @__PURE__ */ jsx(
|
|
6808
|
+
Card,
|
|
6809
|
+
{
|
|
6810
|
+
w: "full",
|
|
6811
|
+
variant: "featureAnnouncement",
|
|
6812
|
+
overflow: "hidden",
|
|
6813
|
+
onClick: handleOnClick,
|
|
6814
|
+
cursor: "pointer",
|
|
6815
|
+
_hover: { opacity: 0.8 },
|
|
6816
|
+
children: /* @__PURE__ */ jsx(CardBody, { p: 4, children: /* @__PURE__ */ jsxs(HStack, { justify: "space-between", align: "flex-start", spacing: 3, children: [
|
|
6817
|
+
/* @__PURE__ */ jsxs(VStack, { align: "flex-start", spacing: 1, children: [
|
|
6818
|
+
/* @__PURE__ */ jsxs(HStack, { spacing: 2, children: [
|
|
6819
|
+
/* @__PURE__ */ jsx(
|
|
6820
|
+
Text,
|
|
6821
|
+
{
|
|
6822
|
+
fontSize: "sm",
|
|
6823
|
+
fontWeight: "400",
|
|
6824
|
+
color: titleColor,
|
|
6825
|
+
children: t("Claim your vet domain!")
|
|
6826
|
+
}
|
|
6827
|
+
),
|
|
6828
|
+
/* @__PURE__ */ jsx(Tag, { size: "sm", colorScheme: "red", children: t("New") })
|
|
6829
|
+
] }),
|
|
6830
|
+
/* @__PURE__ */ jsx(Text, { fontSize: "xs", color: descriptionColor, children: t(
|
|
6831
|
+
"Say goodbye to 0x addresses, claim your .veworld.vet subdomain now for free!"
|
|
6832
|
+
) })
|
|
6833
|
+
] }),
|
|
6834
|
+
/* @__PURE__ */ jsx(
|
|
6835
|
+
IconButton,
|
|
6836
|
+
{
|
|
6837
|
+
size: "sm",
|
|
6838
|
+
variant: "ghost",
|
|
6839
|
+
colorScheme: "gray",
|
|
6840
|
+
icon: /* @__PURE__ */ jsx(IoCloseCircle, {}),
|
|
6841
|
+
onClick: (e) => {
|
|
6842
|
+
e.stopPropagation();
|
|
6843
|
+
closeAnnouncement();
|
|
6844
|
+
},
|
|
6845
|
+
"aria-label": t("Close announcement")
|
|
6846
|
+
}
|
|
6847
|
+
)
|
|
6848
|
+
] }) })
|
|
6849
|
+
}
|
|
6850
|
+
);
|
|
6851
|
+
};
|
|
6852
|
+
var ExchangeWarningAlert = () => {
|
|
6853
|
+
const { t } = useTranslation();
|
|
6854
|
+
return /* @__PURE__ */ jsx(Alert, { status: "warning", fontSize: "xs", borderRadius: "xl", p: 2, children: /* @__PURE__ */ jsx(VStack, { spacing: 1, align: "stretch", w: "full", children: /* @__PURE__ */ jsxs(HStack, { spacing: 2, align: "flex-start", children: [
|
|
6855
|
+
/* @__PURE__ */ jsx(AlertIcon, { boxSize: 4, mt: "10px" }),
|
|
6856
|
+
/* @__PURE__ */ jsx(Text, { w: "full", children: t(
|
|
6857
|
+
"Sending to OceanX or other exchanges may result in loss of funds."
|
|
6858
|
+
) })
|
|
6859
|
+
] }) }) });
|
|
6860
|
+
};
|
|
6861
|
+
var DomainRequiredAlert = () => {
|
|
6862
|
+
const { t } = useTranslation();
|
|
6863
|
+
return /* @__PURE__ */ jsx(Alert, { status: "warning", fontSize: "xs", borderRadius: "xl", p: 2, children: /* @__PURE__ */ jsx(VStack, { spacing: 1, align: "stretch", w: "full", children: /* @__PURE__ */ jsxs(HStack, { spacing: 2, align: "flex-start", children: [
|
|
6864
|
+
/* @__PURE__ */ jsx(AlertIcon, { boxSize: 4, mt: "10px" }),
|
|
6865
|
+
/* @__PURE__ */ jsx(Text, { w: "full", children: t(
|
|
6866
|
+
"A .vet domain is required to customize your profile. Choose an account name to get started."
|
|
6867
|
+
) })
|
|
6868
|
+
] }) }) });
|
|
6869
|
+
};
|
|
6866
6870
|
var AccessAndSecurityContent = ({ setCurrentContent }) => {
|
|
6867
6871
|
const { t } = useTranslation();
|
|
6868
6872
|
const { exportWallet } = usePrivy();
|
|
@@ -9169,6 +9173,7 @@ var en_default = {
|
|
|
9169
9173
|
"Confirm transaction": "Confirm transaction",
|
|
9170
9174
|
"Connect Wallet": "Connect Wallet",
|
|
9171
9175
|
"Connect an external wallet for easier access": "Connect an external wallet for easier access",
|
|
9176
|
+
"Connect wallet": "Connect wallet",
|
|
9172
9177
|
"Connect your Apple account for easier access": "Connect your Apple account for easier access",
|
|
9173
9178
|
"Connect your Discord account for easier access": "Connect your Discord account for easier access",
|
|
9174
9179
|
"Connect your Farcaster account for easier access": "Connect your Farcaster account for easier access",
|
|
@@ -9649,6 +9654,7 @@ var de_default = {
|
|
|
9649
9654
|
"Confirm transaction": "Transaktion best\xE4tigen",
|
|
9650
9655
|
"Connect Wallet": "Wallet verbinden",
|
|
9651
9656
|
"Connect an external wallet for easier access": "Verbinden Sie eine externe Wallet f\xFCr einfacheren Zugang",
|
|
9657
|
+
"Connect wallet": "Wallet verbinden",
|
|
9652
9658
|
"Connect your Apple account for easier access": "Verbinden Sie Ihr Apple-Konto f\xFCr einfacheren Zugriff",
|
|
9653
9659
|
"Connect your Discord account for easier access": "Verbinden Sie Ihr Discord-Konto f\xFCr einen einfacheren Zugriff",
|
|
9654
9660
|
"Connect your Farcaster account for easier access": "Verbinden Sie Ihr Farcaster-Konto f\xFCr einfacheren Zugriff",
|
|
@@ -10129,6 +10135,7 @@ var it_default = {
|
|
|
10129
10135
|
"Confirm transaction": "Conferma transazione",
|
|
10130
10136
|
"Connect Wallet": "Collega Portafoglio",
|
|
10131
10137
|
"Connect an external wallet for easier access": "Collega un portafoglio esterno per un accesso pi\xF9 semplice",
|
|
10138
|
+
"Connect wallet": "Connetti portafoglio",
|
|
10132
10139
|
"Connect your Apple account for easier access": "Collega il tuo account Apple per un accesso pi\xF9 facile",
|
|
10133
10140
|
"Connect your Discord account for easier access": "Collega il tuo account Discord per accedere pi\xF9 facilmente",
|
|
10134
10141
|
"Connect your Farcaster account for easier access": "Collega il tuo account Farcaster per un accesso pi\xF9 facile",
|
|
@@ -10609,6 +10616,7 @@ var fr_default = {
|
|
|
10609
10616
|
"Confirm transaction": "Confirmer la transaction",
|
|
10610
10617
|
"Connect Wallet": "Connecter le portefeuille",
|
|
10611
10618
|
"Connect an external wallet for easier access": "Connectez un portefeuille externe pour un acc\xE8s plus facile",
|
|
10619
|
+
"Connect wallet": "Connecter le portefeuille",
|
|
10612
10620
|
"Connect your Apple account for easier access": "Connectez votre compte Apple pour un acc\xE8s plus facile",
|
|
10613
10621
|
"Connect your Discord account for easier access": "Connectez votre compte Discord pour un acc\xE8s plus facile",
|
|
10614
10622
|
"Connect your Farcaster account for easier access": "Connectez votre compte Farcaster pour un acc\xE8s plus facile",
|
|
@@ -11089,6 +11097,7 @@ var es_default = {
|
|
|
11089
11097
|
"Confirm transaction": "Confirmar transacci\xF3n",
|
|
11090
11098
|
"Connect Wallet": "Conectar Monedero",
|
|
11091
11099
|
"Connect an external wallet for easier access": "Conectar una billetera externa para un acceso m\xE1s f\xE1cil",
|
|
11100
|
+
"Connect wallet": "Conectar billetera",
|
|
11092
11101
|
"Connect your Apple account for easier access": "Conecta tu cuenta de Apple para un acceso m\xE1s f\xE1cil",
|
|
11093
11102
|
"Connect your Discord account for easier access": "Conecta tu cuenta de Discord para un acceso m\xE1s f\xE1cil",
|
|
11094
11103
|
"Connect your Farcaster account for easier access": "Conecta tu cuenta de Farcaster para un acceso m\xE1s f\xE1cil",
|
|
@@ -11569,6 +11578,7 @@ var zh_default = {
|
|
|
11569
11578
|
"Confirm transaction": "\u786E\u8BA4\u4EA4\u6613",
|
|
11570
11579
|
"Connect Wallet": "\u8FDE\u63A5\u94B1\u5305",
|
|
11571
11580
|
"Connect an external wallet for easier access": "\u8FDE\u63A5\u5916\u90E8\u94B1\u5305\u4EE5\u4FBF\u66F4\u8F7B\u677E\u8BBF\u95EE",
|
|
11581
|
+
"Connect wallet": "\u8FDE\u63A5\u94B1\u5305",
|
|
11572
11582
|
"Connect your Apple account for easier access": "\u8FDE\u63A5\u60A8\u7684 Apple \u8D26\u6237\u4EE5\u4FBF\u66F4\u8F7B\u677E\u5730\u8BBF\u95EE",
|
|
11573
11583
|
"Connect your Discord account for easier access": "\u8FDE\u63A5\u60A8\u7684 Discord \u5E10\u53F7\u4EE5\u66F4\u8F7B\u677E\u5730\u8BBF\u95EE",
|
|
11574
11584
|
"Connect your Farcaster account for easier access": "\u8FDE\u63A5\u60A8\u7684 Farcaster \u8D26\u6237\u4EE5\u4FBF\u66F4\u8F7B\u677E\u5730\u8BBF\u95EE",
|
|
@@ -12049,6 +12059,7 @@ var ja_default = {
|
|
|
12049
12059
|
"Confirm transaction": "\u53D6\u5F15\u3092\u78BA\u8A8D",
|
|
12050
12060
|
"Connect Wallet": "\u30A6\u30A9\u30EC\u30C3\u30C8\u3092\u63A5\u7D9A",
|
|
12051
12061
|
"Connect an external wallet for easier access": "\u5916\u90E8\u30A6\u30A9\u30EC\u30C3\u30C8\u3092\u63A5\u7D9A\u3057\u3066\u7C21\u5358\u306B\u30A2\u30AF\u30BB\u30B9",
|
|
12062
|
+
"Connect wallet": "\u30A6\u30A9\u30EC\u30C3\u30C8\u3092\u63A5\u7D9A",
|
|
12052
12063
|
"Connect your Apple account for easier access": "Apple\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u63A5\u7D9A\u3057\u3066\u7C21\u5358\u306B\u30A2\u30AF\u30BB\u30B9",
|
|
12053
12064
|
"Connect your Discord account for easier access": "\u7C21\u5358\u306A\u30A2\u30AF\u30BB\u30B9\u306E\u305F\u3081\u306B\u3042\u306A\u305F\u306EDiscord\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u63A5\u7D9A\u3057\u3066\u304F\u3060\u3055\u3044",
|
|
12054
12065
|
"Connect your Farcaster account for easier access": "Farcaster\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u63A5\u7D9A\u3057\u3066\u7C21\u5358\u306B\u30A2\u30AF\u30BB\u30B9",
|
|
@@ -13179,26 +13190,34 @@ var ProfileContent = ({
|
|
|
13179
13190
|
/* @__PURE__ */ jsx(ModalBackButton, { onClick: () => setCurrentContent("main") }),
|
|
13180
13191
|
/* @__PURE__ */ jsx(ModalCloseButton, {})
|
|
13181
13192
|
] }),
|
|
13182
|
-
/* @__PURE__ */ jsx(ModalBody, { w: "full", children: /* @__PURE__ */
|
|
13183
|
-
|
|
13184
|
-
|
|
13185
|
-
|
|
13186
|
-
|
|
13187
|
-
showHeader: false,
|
|
13188
|
-
onLogout: () => {
|
|
13189
|
-
setCurrentContent?.({
|
|
13190
|
-
type: "disconnect-confirm",
|
|
13191
|
-
props: {
|
|
13192
|
-
onDisconnect: () => {
|
|
13193
|
-
disconnect();
|
|
13194
|
-
onLogoutSuccess?.();
|
|
13195
|
-
},
|
|
13196
|
-
onBack: () => setCurrentContent?.("profile")
|
|
13197
|
-
}
|
|
13198
|
-
});
|
|
13193
|
+
/* @__PURE__ */ jsx(ModalBody, { w: "full", children: /* @__PURE__ */ jsxs(VStack, { w: "full", spacing: 2, children: [
|
|
13194
|
+
!account?.domain && /* @__PURE__ */ jsx(
|
|
13195
|
+
FeatureAnnouncementCard,
|
|
13196
|
+
{
|
|
13197
|
+
setCurrentContent
|
|
13199
13198
|
}
|
|
13200
|
-
|
|
13201
|
-
|
|
13199
|
+
),
|
|
13200
|
+
/* @__PURE__ */ jsx(
|
|
13201
|
+
ProfileCard,
|
|
13202
|
+
{
|
|
13203
|
+
onEditClick: () => setCurrentContent("account-customization"),
|
|
13204
|
+
address: account?.address ?? "",
|
|
13205
|
+
showHeader: false,
|
|
13206
|
+
onLogout: () => {
|
|
13207
|
+
setCurrentContent?.({
|
|
13208
|
+
type: "disconnect-confirm",
|
|
13209
|
+
props: {
|
|
13210
|
+
onDisconnect: () => {
|
|
13211
|
+
disconnect();
|
|
13212
|
+
onLogoutSuccess?.();
|
|
13213
|
+
},
|
|
13214
|
+
onBack: () => setCurrentContent?.("profile")
|
|
13215
|
+
}
|
|
13216
|
+
});
|
|
13217
|
+
}
|
|
13218
|
+
}
|
|
13219
|
+
)
|
|
13220
|
+
] }) }),
|
|
13202
13221
|
/* @__PURE__ */ jsx(ModalFooter, { pt: 0 })
|
|
13203
13222
|
] });
|
|
13204
13223
|
};
|
|
@@ -13268,12 +13287,71 @@ var UpgradeSmartAccountContent = ({
|
|
|
13268
13287
|
),
|
|
13269
13288
|
/* @__PURE__ */ jsx(ModalCloseButton, {})
|
|
13270
13289
|
] }),
|
|
13271
|
-
/* @__PURE__ */ jsx(ModalBody, { children: /* @__PURE__ */ jsxs(VStack, { spacing:
|
|
13290
|
+
/* @__PURE__ */ jsx(ModalBody, { children: /* @__PURE__ */ jsxs(VStack, { spacing: 10, align: "stretch", children: [
|
|
13272
13291
|
/* @__PURE__ */ jsx(Text, { fontSize: "sm", textAlign: "center", children: upgradeRequired ? t(
|
|
13273
13292
|
"Your smart account needs to be upgraded to the latest version (v3)."
|
|
13274
13293
|
) : t(
|
|
13275
13294
|
"Your smart account is already upgraded to this version."
|
|
13276
13295
|
) }),
|
|
13296
|
+
/* @__PURE__ */ jsxs(
|
|
13297
|
+
HStack,
|
|
13298
|
+
{
|
|
13299
|
+
align: "center",
|
|
13300
|
+
justifyContent: "space-evenly",
|
|
13301
|
+
rounded: "md",
|
|
13302
|
+
children: [
|
|
13303
|
+
/* @__PURE__ */ jsxs(Box, { position: "relative", display: "inline-block", children: [
|
|
13304
|
+
/* @__PURE__ */ jsx(Circle, { size: "60px", bg: "gray.200", children: /* @__PURE__ */ jsx(
|
|
13305
|
+
Image,
|
|
13306
|
+
{
|
|
13307
|
+
borderRadius: "full",
|
|
13308
|
+
src: smartAccount?.image,
|
|
13309
|
+
alt: t("Profile Picture"),
|
|
13310
|
+
w: "100%",
|
|
13311
|
+
h: "100%",
|
|
13312
|
+
objectFit: "cover"
|
|
13313
|
+
}
|
|
13314
|
+
) }),
|
|
13315
|
+
/* @__PURE__ */ jsx(
|
|
13316
|
+
Heading,
|
|
13317
|
+
{
|
|
13318
|
+
position: "absolute",
|
|
13319
|
+
top: "-5",
|
|
13320
|
+
right: "-5",
|
|
13321
|
+
color: "#D23F63",
|
|
13322
|
+
fontSize: "28px",
|
|
13323
|
+
children: `v1`
|
|
13324
|
+
}
|
|
13325
|
+
)
|
|
13326
|
+
] }),
|
|
13327
|
+
/* @__PURE__ */ jsx(Icon, { as: FaArrowRight, color: "#3DBA67" }),
|
|
13328
|
+
/* @__PURE__ */ jsxs(Box, { position: "relative", display: "inline-block", children: [
|
|
13329
|
+
/* @__PURE__ */ jsx(Circle, { size: "60px", bg: "gray.200", children: /* @__PURE__ */ jsx(
|
|
13330
|
+
Image,
|
|
13331
|
+
{
|
|
13332
|
+
borderRadius: "full",
|
|
13333
|
+
src: smartAccount?.image,
|
|
13334
|
+
alt: t("Profile Picture"),
|
|
13335
|
+
w: "100%",
|
|
13336
|
+
h: "100%",
|
|
13337
|
+
objectFit: "cover"
|
|
13338
|
+
}
|
|
13339
|
+
) }),
|
|
13340
|
+
/* @__PURE__ */ jsx(
|
|
13341
|
+
Heading,
|
|
13342
|
+
{
|
|
13343
|
+
position: "absolute",
|
|
13344
|
+
top: "-5",
|
|
13345
|
+
right: "-5",
|
|
13346
|
+
color: "#3DBA67",
|
|
13347
|
+
fontSize: "28px",
|
|
13348
|
+
children: `v3`
|
|
13349
|
+
}
|
|
13350
|
+
)
|
|
13351
|
+
] })
|
|
13352
|
+
]
|
|
13353
|
+
}
|
|
13354
|
+
),
|
|
13277
13355
|
/* @__PURE__ */ jsxs(Alert, { status: "info", borderRadius: "md", children: [
|
|
13278
13356
|
/* @__PURE__ */ jsx(AlertIcon, {}),
|
|
13279
13357
|
/* @__PURE__ */ jsxs(Box, { children: [
|
|
@@ -13299,23 +13377,6 @@ var UpgradeSmartAccountContent = ({
|
|
|
13299
13377
|
] })
|
|
13300
13378
|
] }) })
|
|
13301
13379
|
] })
|
|
13302
|
-
] }),
|
|
13303
|
-
/* @__PURE__ */ jsxs(Alert, { status: "warning", borderRadius: "md", children: [
|
|
13304
|
-
/* @__PURE__ */ jsx(AlertIcon, { as: IoWarningOutline }),
|
|
13305
|
-
/* @__PURE__ */ jsxs(Box, { children: [
|
|
13306
|
-
/* @__PURE__ */ jsx(AlertTitle, { fontSize: "sm", children: t("Important") }),
|
|
13307
|
-
/* @__PURE__ */ jsx(
|
|
13308
|
-
AlertDescription,
|
|
13309
|
-
{
|
|
13310
|
-
fontSize: "xs",
|
|
13311
|
-
lineHeight: "17px",
|
|
13312
|
-
display: "block",
|
|
13313
|
-
children: t(
|
|
13314
|
-
"This upgrade is necessary to continue interacting with VeChain blockchain. Please complete it now."
|
|
13315
|
-
)
|
|
13316
|
-
}
|
|
13317
|
-
)
|
|
13318
|
-
] })
|
|
13319
13380
|
] })
|
|
13320
13381
|
] }) }),
|
|
13321
13382
|
/* @__PURE__ */ jsx(ModalFooter, { justifyContent: "center", children: /* @__PURE__ */ jsxs(VStack, { spacing: 3, w: "full", children: [
|
|
@@ -14532,7 +14593,7 @@ var DEFAULT_APPS = [
|
|
|
14532
14593
|
name: "VeChain Kit",
|
|
14533
14594
|
description: "A all-in-one library for building VeChain applications.",
|
|
14534
14595
|
external_url: "https://vechainkit.vechain.org/",
|
|
14535
|
-
logo: "https://
|
|
14596
|
+
logo: "https://vechain.org/wp-content/uploads/2025/02/VeChain_Icon_Quartz_300ppi.png",
|
|
14536
14597
|
banner: "",
|
|
14537
14598
|
screenshots: [],
|
|
14538
14599
|
social_urls: [],
|
|
@@ -14835,7 +14896,7 @@ var TransactionModalContent = ({
|
|
|
14835
14896
|
};
|
|
14836
14897
|
case "error":
|
|
14837
14898
|
return {
|
|
14838
|
-
title:
|
|
14899
|
+
title: t("Something went wrong"),
|
|
14839
14900
|
icon: uiConfig?.errorIcon ?? /* @__PURE__ */ jsx(
|
|
14840
14901
|
Icon,
|
|
14841
14902
|
{
|
|
@@ -14848,7 +14909,7 @@ var TransactionModalContent = ({
|
|
|
14848
14909
|
};
|
|
14849
14910
|
case "success":
|
|
14850
14911
|
return {
|
|
14851
|
-
title:
|
|
14912
|
+
title: t("Transaction successful!"),
|
|
14852
14913
|
icon: uiConfig?.successIcon ?? /* @__PURE__ */ jsx(
|
|
14853
14914
|
Icon,
|
|
14854
14915
|
{
|
|
@@ -15016,7 +15077,7 @@ var SuccessfulOperationContent = ({
|
|
|
15016
15077
|
showSocialButtons = false
|
|
15017
15078
|
}) => {
|
|
15018
15079
|
const { t } = useTranslation();
|
|
15019
|
-
const { network } = useVeChainKitConfig();
|
|
15080
|
+
const { network, darkMode } = useVeChainKitConfig();
|
|
15020
15081
|
const explorerUrl = getConfig(network.type).explorerUrl;
|
|
15021
15082
|
const socialDescription = `${explorerUrl}/${txId}`;
|
|
15022
15083
|
return /* @__PURE__ */ jsxs(Box, { children: [
|
|
@@ -15030,7 +15091,7 @@ var SuccessfulOperationContent = ({
|
|
|
15030
15091
|
{
|
|
15031
15092
|
as: IoIosCheckmarkCircleOutline,
|
|
15032
15093
|
fontSize: "100px",
|
|
15033
|
-
color: "#
|
|
15094
|
+
color: darkMode ? "#00ff45de" : "#10ba3e"
|
|
15034
15095
|
}
|
|
15035
15096
|
),
|
|
15036
15097
|
description && /* @__PURE__ */ jsx(Text, { fontSize: "sm", textAlign: "center", children: description }),
|
|
@@ -16158,7 +16219,7 @@ var SuccessfulOperationContent2 = ({
|
|
|
16158
16219
|
showSocialButtons = false
|
|
16159
16220
|
}) => {
|
|
16160
16221
|
const { t } = useTranslation();
|
|
16161
|
-
const { network } = useVeChainKitConfig();
|
|
16222
|
+
const { network, darkMode } = useVeChainKitConfig();
|
|
16162
16223
|
const explorerUrl = getConfig(network.type).explorerUrl;
|
|
16163
16224
|
const socialDescription = `${explorerUrl}/${txId}`;
|
|
16164
16225
|
return /* @__PURE__ */ jsxs(Box, { children: [
|
|
@@ -16183,7 +16244,7 @@ var SuccessfulOperationContent2 = ({
|
|
|
16183
16244
|
{
|
|
16184
16245
|
as: IoIosCheckmarkCircleOutline,
|
|
16185
16246
|
fontSize: "100px",
|
|
16186
|
-
color: "#00ff45de"
|
|
16247
|
+
color: darkMode ? "#00ff45de" : "#10ba3e"
|
|
16187
16248
|
}
|
|
16188
16249
|
)
|
|
16189
16250
|
}
|
|
@@ -16237,7 +16298,8 @@ var SuccessfulOperationContent2 = ({
|
|
|
16237
16298
|
};
|
|
16238
16299
|
var UpgradeSmartAccountContent2 = ({
|
|
16239
16300
|
setCurrentContent,
|
|
16240
|
-
handleClose
|
|
16301
|
+
handleClose,
|
|
16302
|
+
style
|
|
16241
16303
|
}) => {
|
|
16242
16304
|
const { t } = useTranslation();
|
|
16243
16305
|
const { smartAccount, connectedWallet } = useWallet();
|
|
@@ -16288,10 +16350,69 @@ var UpgradeSmartAccountContent2 = ({
|
|
|
16288
16350
|
/* @__PURE__ */ jsx(ModalHeader, { children: t("Account upgrade required") }),
|
|
16289
16351
|
/* @__PURE__ */ jsx(ModalCloseButton, {})
|
|
16290
16352
|
] }),
|
|
16291
|
-
/* @__PURE__ */ jsx(ModalBody, { children: /* @__PURE__ */ jsxs(VStack, { spacing:
|
|
16353
|
+
/* @__PURE__ */ jsx(ModalBody, { children: /* @__PURE__ */ jsxs(VStack, { spacing: 10, align: "stretch", justifyContent: "center", children: [
|
|
16292
16354
|
/* @__PURE__ */ jsx(Text, { fontSize: "sm", textAlign: "center", children: t(
|
|
16293
16355
|
"To continue interacting with VeChain blockchain and complete your operation, your smart account needs to be upgraded to the latest version (v3)."
|
|
16294
16356
|
) }),
|
|
16357
|
+
/* @__PURE__ */ jsxs(
|
|
16358
|
+
HStack,
|
|
16359
|
+
{
|
|
16360
|
+
align: "center",
|
|
16361
|
+
justifyContent: "space-evenly",
|
|
16362
|
+
rounded: "md",
|
|
16363
|
+
children: [
|
|
16364
|
+
/* @__PURE__ */ jsxs(Box, { position: "relative", display: "inline-block", children: [
|
|
16365
|
+
/* @__PURE__ */ jsx(Circle, { size: "60px", bg: "gray.200", children: /* @__PURE__ */ jsx(
|
|
16366
|
+
Image,
|
|
16367
|
+
{
|
|
16368
|
+
src: smartAccount?.image,
|
|
16369
|
+
alt: t("Profile Picture"),
|
|
16370
|
+
w: "100%",
|
|
16371
|
+
h: "100%",
|
|
16372
|
+
borderRadius: "full",
|
|
16373
|
+
objectFit: "cover"
|
|
16374
|
+
}
|
|
16375
|
+
) }),
|
|
16376
|
+
/* @__PURE__ */ jsx(
|
|
16377
|
+
Heading,
|
|
16378
|
+
{
|
|
16379
|
+
position: "absolute",
|
|
16380
|
+
top: "-5",
|
|
16381
|
+
right: "-5",
|
|
16382
|
+
color: "#D23F63",
|
|
16383
|
+
fontSize: "28px",
|
|
16384
|
+
children: `v1`
|
|
16385
|
+
}
|
|
16386
|
+
)
|
|
16387
|
+
] }),
|
|
16388
|
+
/* @__PURE__ */ jsx(Icon, { as: FaArrowRight, color: "#3DBA67" }),
|
|
16389
|
+
/* @__PURE__ */ jsxs(Box, { position: "relative", display: "inline-block", children: [
|
|
16390
|
+
/* @__PURE__ */ jsx(Circle, { size: "60px", bg: "gray.200", children: /* @__PURE__ */ jsx(
|
|
16391
|
+
Image,
|
|
16392
|
+
{
|
|
16393
|
+
src: smartAccount?.image,
|
|
16394
|
+
alt: t("Profile Picture"),
|
|
16395
|
+
w: "100%",
|
|
16396
|
+
h: "100%",
|
|
16397
|
+
borderRadius: "full",
|
|
16398
|
+
objectFit: "cover"
|
|
16399
|
+
}
|
|
16400
|
+
) }),
|
|
16401
|
+
/* @__PURE__ */ jsx(
|
|
16402
|
+
Heading,
|
|
16403
|
+
{
|
|
16404
|
+
position: "absolute",
|
|
16405
|
+
top: "-5",
|
|
16406
|
+
right: "-5",
|
|
16407
|
+
color: "#3DBA67",
|
|
16408
|
+
fontSize: "28px",
|
|
16409
|
+
children: `v3`
|
|
16410
|
+
}
|
|
16411
|
+
)
|
|
16412
|
+
] })
|
|
16413
|
+
]
|
|
16414
|
+
}
|
|
16415
|
+
),
|
|
16295
16416
|
/* @__PURE__ */ jsxs(Alert, { status: "info", borderRadius: "md", children: [
|
|
16296
16417
|
/* @__PURE__ */ jsx(AlertIcon, {}),
|
|
16297
16418
|
/* @__PURE__ */ jsxs(Box, { children: [
|
|
@@ -16317,28 +16438,12 @@ var UpgradeSmartAccountContent2 = ({
|
|
|
16317
16438
|
] })
|
|
16318
16439
|
] }) })
|
|
16319
16440
|
] })
|
|
16320
|
-
] }),
|
|
16321
|
-
/* @__PURE__ */ jsxs(Alert, { status: "warning", borderRadius: "md", children: [
|
|
16322
|
-
/* @__PURE__ */ jsx(AlertIcon, { as: IoWarningOutline }),
|
|
16323
|
-
/* @__PURE__ */ jsxs(Box, { children: [
|
|
16324
|
-
/* @__PURE__ */ jsx(AlertTitle, { fontSize: "sm", children: t("Important") }),
|
|
16325
|
-
/* @__PURE__ */ jsx(
|
|
16326
|
-
AlertDescription,
|
|
16327
|
-
{
|
|
16328
|
-
fontSize: "xs",
|
|
16329
|
-
lineHeight: "17px",
|
|
16330
|
-
display: "block",
|
|
16331
|
-
children: t(
|
|
16332
|
-
"This upgrade is necessary to continue interacting with VeChain blockchain. Please complete it now."
|
|
16333
|
-
)
|
|
16334
|
-
}
|
|
16335
|
-
)
|
|
16336
|
-
] })
|
|
16337
16441
|
] })
|
|
16338
16442
|
] }) }),
|
|
16339
16443
|
/* @__PURE__ */ jsx(ModalFooter, { justifyContent: "center", children: /* @__PURE__ */ jsx(VStack, { spacing: 3, w: "full", children: /* @__PURE__ */ jsx(
|
|
16340
16444
|
TransactionButtonAndStatus,
|
|
16341
16445
|
{
|
|
16446
|
+
style,
|
|
16342
16447
|
buttonText: upgradeRequired ? t("Upgrade account") : t("Account already upgraded"),
|
|
16343
16448
|
onConfirm: handleUpgrade,
|
|
16344
16449
|
isTxWaitingConfirmation: isWaitingForWalletConfirmation,
|
|
@@ -16351,7 +16456,7 @@ var UpgradeSmartAccountContent2 = ({
|
|
|
16351
16456
|
) }) })
|
|
16352
16457
|
] });
|
|
16353
16458
|
};
|
|
16354
|
-
var UpgradeSmartAccountModal = ({ isOpen, onClose }) => {
|
|
16459
|
+
var UpgradeSmartAccountModal = ({ isOpen, onClose, style }) => {
|
|
16355
16460
|
const [currentContent, setCurrentContent] = useState(
|
|
16356
16461
|
"upgrade-smart-account"
|
|
16357
16462
|
);
|
|
@@ -16371,7 +16476,8 @@ var UpgradeSmartAccountModal = ({ isOpen, onClose }) => {
|
|
|
16371
16476
|
UpgradeSmartAccountContent2,
|
|
16372
16477
|
{
|
|
16373
16478
|
setCurrentContent,
|
|
16374
|
-
handleClose: onClose
|
|
16479
|
+
handleClose: onClose,
|
|
16480
|
+
style
|
|
16375
16481
|
}
|
|
16376
16482
|
);
|
|
16377
16483
|
}
|
|
@@ -16383,6 +16489,7 @@ var UpgradeSmartAccountModal = ({ isOpen, onClose }) => {
|
|
|
16383
16489
|
onClose,
|
|
16384
16490
|
allowExternalFocus: true,
|
|
16385
16491
|
blockScrollOnMount: true,
|
|
16492
|
+
size: style?.modalSize,
|
|
16386
16493
|
children: renderContent()
|
|
16387
16494
|
}
|
|
16388
16495
|
);
|
|
@@ -16411,10 +16518,13 @@ var ModalProvider = ({ children }) => {
|
|
|
16411
16518
|
[]
|
|
16412
16519
|
);
|
|
16413
16520
|
const [isAccountModalOpen, setIsAccountModalOpen] = useState(false);
|
|
16414
|
-
const openAccountModal = useCallback(
|
|
16415
|
-
|
|
16416
|
-
|
|
16417
|
-
|
|
16521
|
+
const openAccountModal = useCallback(
|
|
16522
|
+
(content) => {
|
|
16523
|
+
setAccountModalContent(content ?? "main");
|
|
16524
|
+
setIsAccountModalOpen(true);
|
|
16525
|
+
},
|
|
16526
|
+
[]
|
|
16527
|
+
);
|
|
16418
16528
|
const closeAccountModal = useCallback(
|
|
16419
16529
|
() => setIsAccountModalOpen(false),
|
|
16420
16530
|
[]
|
|
@@ -16438,8 +16548,12 @@ var ModalProvider = ({ children }) => {
|
|
|
16438
16548
|
[]
|
|
16439
16549
|
);
|
|
16440
16550
|
const [isUpgradeSmartAccountModalOpen, setIsUpgradeSmartAccountModalOpen] = useState(false);
|
|
16551
|
+
const [upgradeSmartAccountModalStyle, setUpgradeSmartAccountModalStyle] = useState(void 0);
|
|
16441
16552
|
const openUpgradeSmartAccountModal = useCallback(
|
|
16442
|
-
() =>
|
|
16553
|
+
(style) => {
|
|
16554
|
+
setUpgradeSmartAccountModalStyle(style);
|
|
16555
|
+
setIsUpgradeSmartAccountModalOpen(true);
|
|
16556
|
+
},
|
|
16443
16557
|
[]
|
|
16444
16558
|
);
|
|
16445
16559
|
const closeUpgradeSmartAccountModal = useCallback(
|
|
@@ -16490,7 +16604,8 @@ var ModalProvider = ({ children }) => {
|
|
|
16490
16604
|
UpgradeSmartAccountModal,
|
|
16491
16605
|
{
|
|
16492
16606
|
isOpen: isUpgradeSmartAccountModalOpen,
|
|
16493
|
-
onClose: closeUpgradeSmartAccountModal
|
|
16607
|
+
onClose: closeUpgradeSmartAccountModal,
|
|
16608
|
+
style: upgradeSmartAccountModalStyle
|
|
16494
16609
|
}
|
|
16495
16610
|
)
|
|
16496
16611
|
]
|
|
@@ -16512,7 +16627,7 @@ var useAccountModal = () => {
|
|
|
16512
16627
|
closeAccountModal: close,
|
|
16513
16628
|
isAccountModalOpen: isOpen
|
|
16514
16629
|
} = useModal();
|
|
16515
|
-
return { open, close, isOpen };
|
|
16630
|
+
return { open: () => open(), close, isOpen };
|
|
16516
16631
|
};
|
|
16517
16632
|
var AccountModalProvider = ({ children }) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16518
16633
|
var useTransactionModal = () => {
|
|
@@ -16574,7 +16689,7 @@ var useChooseNameModal = () => {
|
|
|
16574
16689
|
setAccountModalContent
|
|
16575
16690
|
} = useModal();
|
|
16576
16691
|
const open = () => {
|
|
16577
|
-
|
|
16692
|
+
openAccountModal({
|
|
16578
16693
|
type: "choose-name",
|
|
16579
16694
|
props: {
|
|
16580
16695
|
setCurrentContent: setAccountModalContent,
|
|
@@ -16582,7 +16697,6 @@ var useChooseNameModal = () => {
|
|
|
16582
16697
|
initialContentSource: "main"
|
|
16583
16698
|
}
|
|
16584
16699
|
});
|
|
16585
|
-
openAccountModal();
|
|
16586
16700
|
};
|
|
16587
16701
|
const close = () => {
|
|
16588
16702
|
closeAccountModal();
|
|
@@ -16604,13 +16718,12 @@ var useSendTokenModal = () => {
|
|
|
16604
16718
|
setAccountModalContent
|
|
16605
16719
|
} = useModal();
|
|
16606
16720
|
const open = () => {
|
|
16607
|
-
|
|
16721
|
+
openAccountModal({
|
|
16608
16722
|
type: "send-token",
|
|
16609
16723
|
props: {
|
|
16610
16724
|
setCurrentContent: setAccountModalContent
|
|
16611
16725
|
}
|
|
16612
16726
|
});
|
|
16613
|
-
openAccountModal();
|
|
16614
16727
|
};
|
|
16615
16728
|
const close = () => {
|
|
16616
16729
|
closeAccountModal();
|
|
@@ -16625,15 +16738,9 @@ var SendTokenModalProvider = ({
|
|
|
16625
16738
|
children
|
|
16626
16739
|
}) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16627
16740
|
var useAccessAndSecurityModal = () => {
|
|
16628
|
-
const {
|
|
16629
|
-
openAccountModal,
|
|
16630
|
-
closeAccountModal,
|
|
16631
|
-
isAccountModalOpen,
|
|
16632
|
-
setAccountModalContent
|
|
16633
|
-
} = useModal();
|
|
16741
|
+
const { openAccountModal, closeAccountModal, isAccountModalOpen } = useModal();
|
|
16634
16742
|
const open = () => {
|
|
16635
|
-
|
|
16636
|
-
openAccountModal();
|
|
16743
|
+
openAccountModal("access-and-security");
|
|
16637
16744
|
};
|
|
16638
16745
|
const close = () => {
|
|
16639
16746
|
closeAccountModal();
|
|
@@ -16648,15 +16755,9 @@ var AccessAndSecurityModalProvider = ({
|
|
|
16648
16755
|
children
|
|
16649
16756
|
}) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16650
16757
|
var useExploreEcosystemModal = () => {
|
|
16651
|
-
const {
|
|
16652
|
-
openAccountModal,
|
|
16653
|
-
closeAccountModal,
|
|
16654
|
-
isAccountModalOpen,
|
|
16655
|
-
setAccountModalContent
|
|
16656
|
-
} = useModal();
|
|
16758
|
+
const { openAccountModal, closeAccountModal, isAccountModalOpen } = useModal();
|
|
16657
16759
|
const open = () => {
|
|
16658
|
-
|
|
16659
|
-
openAccountModal();
|
|
16760
|
+
openAccountModal("ecosystem");
|
|
16660
16761
|
};
|
|
16661
16762
|
const close = () => {
|
|
16662
16763
|
closeAccountModal();
|
|
@@ -16671,15 +16772,9 @@ var ExploreEcosystemModalProvider = ({
|
|
|
16671
16772
|
children
|
|
16672
16773
|
}) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16673
16774
|
var useNotificationsModal = () => {
|
|
16674
|
-
const {
|
|
16675
|
-
openAccountModal,
|
|
16676
|
-
closeAccountModal,
|
|
16677
|
-
isAccountModalOpen,
|
|
16678
|
-
setAccountModalContent
|
|
16679
|
-
} = useModal();
|
|
16775
|
+
const { openAccountModal, closeAccountModal, isAccountModalOpen } = useModal();
|
|
16680
16776
|
const open = () => {
|
|
16681
|
-
|
|
16682
|
-
openAccountModal();
|
|
16777
|
+
openAccountModal("notifications");
|
|
16683
16778
|
};
|
|
16684
16779
|
const close = () => {
|
|
16685
16780
|
closeAccountModal();
|
|
@@ -16701,11 +16796,10 @@ var useFAQModal = () => {
|
|
|
16701
16796
|
setAccountModalContent
|
|
16702
16797
|
} = useModal();
|
|
16703
16798
|
const open = () => {
|
|
16704
|
-
|
|
16799
|
+
openAccountModal({
|
|
16705
16800
|
type: "faq",
|
|
16706
16801
|
props: { onGoBack: () => setAccountModalContent("main") }
|
|
16707
16802
|
});
|
|
16708
|
-
openAccountModal();
|
|
16709
16803
|
};
|
|
16710
16804
|
const close = () => {
|
|
16711
16805
|
closeAccountModal();
|
|
@@ -16718,15 +16812,9 @@ var useFAQModal = () => {
|
|
|
16718
16812
|
};
|
|
16719
16813
|
var FAQModalProvider = ({ children }) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16720
16814
|
var useAccountCustomizationModal = () => {
|
|
16721
|
-
const {
|
|
16722
|
-
openAccountModal,
|
|
16723
|
-
closeAccountModal,
|
|
16724
|
-
isAccountModalOpen,
|
|
16725
|
-
setAccountModalContent
|
|
16726
|
-
} = useModal();
|
|
16815
|
+
const { openAccountModal, closeAccountModal, isAccountModalOpen } = useModal();
|
|
16727
16816
|
const open = () => {
|
|
16728
|
-
|
|
16729
|
-
openAccountModal();
|
|
16817
|
+
openAccountModal("account-customization");
|
|
16730
16818
|
};
|
|
16731
16819
|
const close = () => {
|
|
16732
16820
|
closeAccountModal();
|
|
@@ -16741,15 +16829,9 @@ var AccountCustomizationModalProvider = ({
|
|
|
16741
16829
|
children
|
|
16742
16830
|
}) => /* @__PURE__ */ jsx(Fragment, { children });
|
|
16743
16831
|
var useReceiveModal = () => {
|
|
16744
|
-
const {
|
|
16745
|
-
openAccountModal,
|
|
16746
|
-
closeAccountModal,
|
|
16747
|
-
isAccountModalOpen,
|
|
16748
|
-
setAccountModalContent
|
|
16749
|
-
} = useModal();
|
|
16832
|
+
const { openAccountModal, closeAccountModal, isAccountModalOpen } = useModal();
|
|
16750
16833
|
const open = () => {
|
|
16751
|
-
|
|
16752
|
-
openAccountModal();
|
|
16834
|
+
openAccountModal("receive-token");
|
|
16753
16835
|
};
|
|
16754
16836
|
const close = () => {
|
|
16755
16837
|
closeAccountModal();
|
|
@@ -16830,13 +16912,13 @@ var useLoginModalContent = () => {
|
|
|
16830
16912
|
...baseConfig
|
|
16831
16913
|
};
|
|
16832
16914
|
};
|
|
16833
|
-
var useUpgradeSmartAccountModal = () => {
|
|
16915
|
+
var useUpgradeSmartAccountModal = (style) => {
|
|
16834
16916
|
const {
|
|
16835
16917
|
openUpgradeSmartAccountModal: open,
|
|
16836
16918
|
closeUpgradeSmartAccountModal: close,
|
|
16837
16919
|
isUpgradeSmartAccountModalOpen: isOpen
|
|
16838
16920
|
} = useModal();
|
|
16839
|
-
return { open, close, isOpen };
|
|
16921
|
+
return { open: () => open(style), close, isOpen };
|
|
16840
16922
|
};
|
|
16841
16923
|
var UpgradeSmartAccountModalProvider = ({
|
|
16842
16924
|
children
|
|
@@ -17298,8 +17380,8 @@ var PrivyWalletProvider = ({
|
|
|
17298
17380
|
value: valueArray,
|
|
17299
17381
|
data: dataArray,
|
|
17300
17382
|
validAfter: 0,
|
|
17301
|
-
validBefore: Math.floor(Date.now() / 1e3) +
|
|
17302
|
-
// e.g.
|
|
17383
|
+
validBefore: Math.floor(Date.now() / 1e3) + 300,
|
|
17384
|
+
// e.g. 5 minutes from now
|
|
17303
17385
|
nonce: ethers.hexlify(ethers.randomBytes(32))
|
|
17304
17386
|
}
|
|
17305
17387
|
};
|
|
@@ -17740,13 +17822,12 @@ var VeChainKitProvider = (props) => {
|
|
|
17740
17822
|
},
|
|
17741
17823
|
appearance: {
|
|
17742
17824
|
theme: darkMode ? "dark" : "light",
|
|
17743
|
-
accentColor: darkMode ? "#3182CE" : "#2B6CB0",
|
|
17825
|
+
accentColor: privy?.appearance.accentColor ?? (darkMode ? "#3182CE" : "#2B6CB0"),
|
|
17744
17826
|
loginMessage: privy?.appearance.loginMessage,
|
|
17745
17827
|
logo: privy?.appearance.logo
|
|
17746
17828
|
},
|
|
17747
17829
|
embeddedWallets: {
|
|
17748
|
-
createOnLogin: privy?.embeddedWallets?.createOnLogin ?? "all-users"
|
|
17749
|
-
showWalletUIs: true
|
|
17830
|
+
createOnLogin: privy?.embeddedWallets?.createOnLogin ?? "all-users"
|
|
17750
17831
|
},
|
|
17751
17832
|
passkeys: {
|
|
17752
17833
|
shouldUnlinkOnUnenrollMfa: false
|
|
@@ -17871,10 +17952,9 @@ var variants2 = {
|
|
|
17871
17952
|
}),
|
|
17872
17953
|
featureAnnouncement: (props) => definePartsStyle2({
|
|
17873
17954
|
body: {
|
|
17874
|
-
backgroundColor: props.colorMode === "dark" ? "
|
|
17955
|
+
backgroundColor: props.colorMode === "dark" ? "#ffffff0a" : "blackAlpha.50",
|
|
17875
17956
|
borderRadius: "12px",
|
|
17876
|
-
|
|
17877
|
-
color: props.colorMode === "dark" ? "whiteAlpha.900" : "gray.800"
|
|
17957
|
+
color: props.colorMode === "dark" ? "#ffffff12" : "blackAlpha.200"
|
|
17878
17958
|
},
|
|
17879
17959
|
container: {
|
|
17880
17960
|
borderRadius: "12px",
|