@vechain/vechain-kit 1.2.0 → 1.2.1

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.
@@ -8,7 +8,7 @@ type SmartAccount = Wallet & {
8
8
  isActive: boolean;
9
9
  };
10
10
  type ConnectionSource = {
11
- type: 'privy' | 'wallet' | 'privy-cross-app' | 'privy-vechain';
11
+ type: 'privy' | 'wallet' | 'privy-cross-app';
12
12
  displayName: string;
13
13
  };
14
14
  /**
@@ -8,7 +8,7 @@ type SmartAccount = Wallet & {
8
8
  isActive: boolean;
9
9
  };
10
10
  type ConnectionSource = {
11
- type: 'privy' | 'wallet' | 'privy-cross-app' | 'privy-vechain';
11
+ type: 'privy' | 'wallet' | 'privy-cross-app';
12
12
  displayName: string;
13
13
  };
14
14
  /**
package/dist/index.cjs CHANGED
@@ -4568,7 +4568,7 @@ var AddressDisplay = ({ wallet, label, size = "lg" }) => {
4568
4568
  // package.json
4569
4569
  var package_default = {
4570
4570
  name: "@vechain/vechain-kit",
4571
- version: "1.1.1",
4571
+ version: "1.2.1",
4572
4572
  private: false,
4573
4573
  homepage: "https://github.com/vechain/vechain-kit",
4574
4574
  repository: "github:vechain/vechain-kit",
@@ -5931,7 +5931,7 @@ var AccountSelector = ({
5931
5931
  rounded: "full"
5932
5932
  }
5933
5933
  ),
5934
- /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: size, fontWeight: "500", children: chunkVUMG5BY2_cjs.humanDomain(wallet?.domain ?? "", 10, 4) || chunkVUMG5BY2_cjs.humanAddress(wallet?.address ?? "", 6, 4) }),
5934
+ /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: size, fontWeight: "500", children: chunkVUMG5BY2_cjs.humanDomain(wallet?.domain ?? "", 11, 4) || chunkVUMG5BY2_cjs.humanAddress(wallet?.address ?? "", 6, 4) }),
5935
5935
  /* @__PURE__ */ jsxRuntime.jsx(
5936
5936
  react.Icon,
5937
5937
  {
@@ -6234,12 +6234,17 @@ var EmbeddedWalletContent = ({ setCurrentContent }) => {
6234
6234
  ),
6235
6235
  /* @__PURE__ */ jsxRuntime.jsx(AddressDisplay, { wallet: connectedWallet })
6236
6236
  ] }),
6237
- connection.isConnectedWithCrossApp && /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", opacity: 0.5, children: t(
6238
- "This is your main wallet and identity. Please be sure to keep it safe and backed up. Go to {{element}} website to manage your login methods and security settings.",
6239
- {
6240
- element: connectionCache?.ecosystemApp?.name
6241
- }
6242
- ) }),
6237
+ connection.isConnectedWithCrossApp && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
6238
+ /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", opacity: 0.5, children: t(
6239
+ "This is your main wallet and identity. Please be sure to keep it safe and backed up. Go to {{element}} website to manage your login methods and security settings.",
6240
+ {
6241
+ element: connectionCache?.ecosystemApp?.name
6242
+ }
6243
+ ) }),
6244
+ /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", opacity: 0.5, mt: 5, children: t(
6245
+ "A smart account is being used as a gateway for blockchain interactions."
6246
+ ) })
6247
+ ] }),
6243
6248
  connection.isConnectedWithSocialLogin && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
6244
6249
  /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", opacity: 0.5, children: t(
6245
6250
  "You are using an Embedded Wallet secured by your social login method, ensuring a seamless VeChain experience."
@@ -7474,7 +7479,7 @@ var ConfirmationModalContent = ({
7474
7479
  }, 9e3);
7475
7480
  return () => clearTimeout(timer);
7476
7481
  }, [progress?.currentStep]);
7477
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
7482
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
7478
7483
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
7479
7484
  /* @__PURE__ */ jsxRuntime.jsx(
7480
7485
  react.ModalHeader,
@@ -7566,7 +7571,7 @@ var ErrorModalContent = ({
7566
7571
  const { network } = useVeChainKitConfig();
7567
7572
  const { darkMode: isDark } = useVeChainKitConfig();
7568
7573
  const explorerUrl = chunkVUMG5BY2_cjs.getConfig(network.type).explorerUrl;
7569
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
7574
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
7570
7575
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
7571
7576
  /* @__PURE__ */ jsxRuntime.jsx(
7572
7577
  react.ModalHeader,
@@ -7661,7 +7666,7 @@ var LoadingModalContent = ({
7661
7666
  }, 12e3);
7662
7667
  return () => clearTimeout(timer);
7663
7668
  }, []);
7664
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
7669
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
7665
7670
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
7666
7671
  /* @__PURE__ */ jsxRuntime.jsx(
7667
7672
  react.ModalHeader,
@@ -7782,7 +7787,7 @@ var SuccessModalContent = ({
7782
7787
  const { network } = useVeChainKitConfig();
7783
7788
  const explorerUrl = chunkVUMG5BY2_cjs.getConfig(network.type).explorerUrl;
7784
7789
  const socialDescription = socialDescriptionEncoded ?? `${explorerUrl}/${txId}`;
7785
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
7790
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
7786
7791
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
7787
7792
  /* @__PURE__ */ jsxRuntime.jsx(
7788
7793
  react.ModalHeader,
@@ -9934,7 +9939,15 @@ var FAQContent = ({ onGoBack }) => {
9934
9939
  var NetworkInfo = () => {
9935
9940
  const { t } = reactI18next.useTranslation();
9936
9941
  const { darkMode: isDark, network } = useVeChainKitConfig();
9942
+ const { connection } = useWallet();
9937
9943
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
9944
+ /* @__PURE__ */ jsxRuntime.jsxs(react.HStack, { w: "full", justifyContent: "space-between", children: [
9945
+ /* @__PURE__ */ jsxRuntime.jsxs(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: [
9946
+ t("Connection Type"),
9947
+ ":"
9948
+ ] }),
9949
+ /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: connection.source.type })
9950
+ ] }),
9938
9951
  /* @__PURE__ */ jsxRuntime.jsxs(react.HStack, { w: "full", justifyContent: "space-between", children: [
9939
9952
  /* @__PURE__ */ jsxRuntime.jsxs(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: [
9940
9953
  t("Network"),
@@ -9948,6 +9961,13 @@ var NetworkInfo = () => {
9948
9961
  ":"
9949
9962
  ] }),
9950
9963
  /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: network.nodeUrl || chunkVUMG5BY2_cjs.getConfig(network.type).nodeUrl })
9964
+ ] }),
9965
+ /* @__PURE__ */ jsxRuntime.jsxs(react.HStack, { w: "full", justifyContent: "space-between", children: [
9966
+ /* @__PURE__ */ jsxRuntime.jsxs(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: [
9967
+ t("Active Smart Account"),
9968
+ ":"
9969
+ ] }),
9970
+ /* @__PURE__ */ jsxRuntime.jsx(react.Text, { fontSize: "sm", color: isDark ? "#dfdfdd" : "#4d4d4d", children: connection.isConnectedWithPrivy ? "Yes" : "No" })
9951
9971
  ] })
9952
9972
  ] });
9953
9973
  };
@@ -10838,7 +10858,7 @@ var NotificationsContent = ({ setCurrentContent }) => {
10838
10858
  ),
10839
10859
  /* @__PURE__ */ jsxRuntime.jsx(react.ModalCloseButton, {})
10840
10860
  ] }),
10841
- /* @__PURE__ */ jsxRuntime.jsxs(react.Container, { maxW: "container.lg", h: "350px", overflowY: "auto", children: [
10861
+ /* @__PURE__ */ jsxRuntime.jsxs(react.Container, { maxW: "container.lg", h: "350px", children: [
10842
10862
  /* @__PURE__ */ jsxRuntime.jsx(react.ModalBody, { w: "full", children: /* @__PURE__ */ jsxRuntime.jsxs(react.VStack, { spacing: 4, align: "stretch", w: "full", children: [
10843
10863
  /* @__PURE__ */ jsxRuntime.jsxs(react.HStack, { justify: "space-between", children: [
10844
10864
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -11164,7 +11184,7 @@ var AppOverviewContent = ({
11164
11184
  }) => {
11165
11185
  const { t } = reactI18next.useTranslation();
11166
11186
  const { darkMode: isDark } = useVeChainKitConfig();
11167
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
11187
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
11168
11188
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
11169
11189
  /* @__PURE__ */ jsxRuntime.jsx(
11170
11190
  react.ModalHeader,
@@ -11345,7 +11365,12 @@ var AccountModal = ({ isOpen, onClose }) => {
11345
11365
  case "choose-name":
11346
11366
  return /* @__PURE__ */ jsxRuntime.jsx(ChooseNameContent, { setCurrentContent });
11347
11367
  case "faq":
11348
- return /* @__PURE__ */ jsxRuntime.jsx(FAQContent, { onGoBack: () => setCurrentContent("main") });
11368
+ return /* @__PURE__ */ jsxRuntime.jsx(
11369
+ FAQContent,
11370
+ {
11371
+ onGoBack: () => setCurrentContent("settings")
11372
+ }
11373
+ );
11349
11374
  case "connection-details":
11350
11375
  return /* @__PURE__ */ jsxRuntime.jsx(
11351
11376
  ConnectionDetailsContent,
@@ -11970,7 +11995,7 @@ var EcosystemContent = ({ onClose, appsInfo, isLoading }) => {
11970
11995
  }
11971
11996
  }
11972
11997
  };
11973
- return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
11998
+ return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
11974
11999
  /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
11975
12000
  /* @__PURE__ */ jsxRuntime.jsxs(StickyHeaderContainer, { children: [
11976
12001
  /* @__PURE__ */ jsxRuntime.jsxs(