From 3025501523ab1e0c836d2bd04b4f10bf4ac71f1f Mon Sep 17 00:00:00 2001 From: Credence Date: Fri, 13 Dec 2024 18:36:50 +0100 Subject: [PATCH 1/5] landing: select lords by default for bridge in --- landing/src/components/modules/bridge-in.tsx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/landing/src/components/modules/bridge-in.tsx b/landing/src/components/modules/bridge-in.tsx index d536786c6..8844fe5cc 100644 --- a/landing/src/components/modules/bridge-in.tsx +++ b/landing/src/components/modules/bridge-in.tsx @@ -38,8 +38,10 @@ export const BridgeIn = () => { const { computeTravelTime } = useTravel(); const { getRealmNameById } = useRealm(); const [isLoading, setIsLoading] = useState(false); - const [selectedResourceIds, setSelectedResourceIds] = useState([]); - const [selectedResourceAmounts, setSelectedResourceAmounts] = useState<{ [key: string]: number }>({}); + const [selectedResourceIds, setSelectedResourceIds] = useState([ResourcesIds.Lords]); + const [selectedResourceAmounts, setSelectedResourceAmounts] = useState<{ [key: string]: number }>({ + [ResourcesIds.Lords]: 0, + }); const [resourceAddresses, setResourceAddresses] = useState<{ [key: string]: string }>({}); const unselectedResources = useMemo( () => resources.filter((res) => !selectedResourceIds.includes(res.id)), @@ -151,8 +153,10 @@ export const BridgeIn = () => { const resp = await bridgeIntoRealm(validResources, ADMIN_BANK_ENTITY_ID, BigInt(realmEntityId!)); if (resp) { - setSelectedResourceIds([]); - setSelectedResourceAmounts({}); + setSelectedResourceIds([ResourcesIds.Lords]); + setSelectedResourceAmounts({ + [ResourcesIds.Lords]: 0, + }); } } catch (error) { console.error("Bridge into realm error:", error); From a7849cdd87368b5ac776e70e3ce47ee3ced36b9d Mon Sep 17 00:00:00 2001 From: Credence Date: Fri, 13 Dec 2024 18:39:47 +0100 Subject: [PATCH 2/5] landing: add connect wallet msgs --- landing/src/components/modules/bridge-in.tsx | 6 +++++- landing/src/components/modules/bridge-out-step-1.tsx | 2 +- landing/src/components/modules/bridge-out-step-2.tsx | 4 ++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/landing/src/components/modules/bridge-in.tsx b/landing/src/components/modules/bridge-in.tsx index 8844fe5cc..1985126dd 100644 --- a/landing/src/components/modules/bridge-in.tsx +++ b/landing/src/components/modules/bridge-in.tsx @@ -190,7 +190,11 @@ export const BridgeIn = () => { setRealmEntityId(value)}> - + {address ? :
-- Connect your wallet --
}
{playerRealmsIdAndName.map((realm) => { diff --git a/landing/src/components/modules/bridge-out-step-2.tsx b/landing/src/components/modules/bridge-out-step-2.tsx index bd4fe55e6..e8503138f 100644 --- a/landing/src/components/modules/bridge-out-step-2.tsx +++ b/landing/src/components/modules/bridge-out-step-2.tsx @@ -142,7 +142,7 @@ export const BridgeOutStep2 = () => {
Withdraw To
-
{displayAddress(address || "")}
+
{address ? displayAddress(address || "") : " -- Connect your wallet --"}
@@ -308,7 +308,7 @@ export const BridgeOutStep2 = () => { className="w-full" > {isLoading && } - {isLoading ? "Sending to Wallet..." : "Send to Wallet (Final Step)"} + {isLoading ? "Sending to Wallet..." : "Send to Wallet"} From 50753b58825a7ae386654a41aaf6ea11706b0806 Mon Sep 17 00:00:00 2001 From: Credence Date: Fri, 13 Dec 2024 18:40:32 +0100 Subject: [PATCH 3/5] landing: update bridge section description --- landing/src/components/modules/bridge-in.tsx | 49 ++++++++++++++--- .../components/modules/bridge-out-step-1.tsx | 53 ++++++++++++++++++- .../components/modules/bridge-out-step-2.tsx | 36 ++++++++++++- 3 files changed, 128 insertions(+), 10 deletions(-) diff --git a/landing/src/components/modules/bridge-in.tsx b/landing/src/components/modules/bridge-in.tsx index 1985126dd..fefbc173e 100644 --- a/landing/src/components/modules/bridge-in.tsx +++ b/landing/src/components/modules/bridge-in.tsx @@ -172,12 +172,49 @@ export const BridgeIn = () => { <>
- Bridge resources and lords from your Starknet wallet into the Eternum game. You will have to complete the - claim on your Realm in the{" "} - - game - - . +
+

+ Bridge Resources Into Your Realm +

+ +
+
+
+ + 1 + +
+
+

Bridge Assets into the Game

+

+ Bridge your ERC20 assets, resources and lords from your Starknet wallet into the Eternum game. +

+
+
+ +
+
+ + 2 + +
+
+

Complete Claim

+

+ Complete the claim on your Realm in the{" "} + + game + {" "} + by checking the Resource Arrivals (Donkeys) tab in the game. +

+
+
+
+

diff --git a/landing/src/components/modules/bridge-out-step-1.tsx b/landing/src/components/modules/bridge-out-step-1.tsx index f6bfd6dfe..53e637f68 100644 --- a/landing/src/components/modules/bridge-out-step-1.tsx +++ b/landing/src/components/modules/bridge-out-step-1.tsx @@ -153,8 +153,57 @@ export const BridgeOutStep1 = () => { <>
- Bridge resources from your Realms balance in game to tradeable ERC20 assets in your Starknet wallet. This will - require a second step to send the resources to your wallet once the donkeys have arrived at the bank. +
+

+ Bridge Resources to Wallet +

+ +
+
+
+ + 1 + +
+
+

Bridge Resources

+

+ Bridge resources from your Realms balance in-game to tradeable ERC20 assets in your Starknet wallet. + The first step is to send it to the bank. +

+
+
+ +
+
+ + 2 + +
+
+

Complete Transfer

+

+ Once the donkeys arrive at the bank, complete the second step ( the next section ) to receive + resources in your wallet. +

+
+
+ +
+
+ + ℹ️ + +
+
+

Important Note

+

+ This bridge will only be available for withdrawals for up to 48 hours after the Season ends. +

+
+
+
+

diff --git a/landing/src/components/modules/bridge-out-step-2.tsx b/landing/src/components/modules/bridge-out-step-2.tsx index e8503138f..50c118374 100644 --- a/landing/src/components/modules/bridge-out-step-2.tsx +++ b/landing/src/components/modules/bridge-out-step-2.tsx @@ -136,8 +136,40 @@ export const BridgeOutStep2 = () => { <>
- Finalise the withdrawal of resources from your Realm in Eternum to your Starknet wallet. The bridge will close - and you will be unable to withdraw 48 hours after the Season is won. +
+

+ Finalize Bridge Withdrawal +

+ +
+
+
+ + + + + +
+
+

Complete Withdrawal

+

+ Finalize the withdrawal of resources from your Realm in Eternum to your Starknet wallet. Select a + donkey to withdraw resources from. +

+
+
+
+

From 3f5157103830feb074c35e1aa8611ce1941ad157 Mon Sep 17 00:00:00 2001 From: Credence Date: Fri, 13 Dec 2024 19:02:52 +0100 Subject: [PATCH 4/5] landing: update collection not found pages --- .../src/components/modules/realms-grid.tsx | 37 ++++++++++++++++++- .../components/modules/season-passes-grid.tsx | 36 +++++++++++++++++- 2 files changed, 69 insertions(+), 4 deletions(-) diff --git a/landing/src/components/modules/realms-grid.tsx b/landing/src/components/modules/realms-grid.tsx index b32c94287..a967ae2d2 100644 --- a/landing/src/components/modules/realms-grid.tsx +++ b/landing/src/components/modules/realms-grid.tsx @@ -1,6 +1,6 @@ import { Button } from "@/components/ui/button"; import { GetRealmsQuery } from "@/hooks/gql/graphql"; -import { Grid2X2, Grid3X3 } from "lucide-react"; +import { Castle, Grid2X2, Grid3X3 } from "lucide-react"; import { useState } from "react"; import { AnimatedGrid } from "./animated-grid"; import { RealmCard } from "./realm-card"; @@ -30,8 +30,41 @@ export const RealmsGrid = ({ }: SeasonPassRowProps) => { const [isCompactGrid, setIsCompactGrid] = useState(false); - if (!realms?.length) return
No Realms found
; + if (!realms?.length) { + return ( +
+ {/* Decorative elements */} +
+
+
+
+ + +
+

+ No Realms Yet +

+ +

+ Your collection of realms will appear here once you acquire them. + + Get your first realm to start your journey into Realms World! +

+ + + + +
+
+ ); + } const gridItems: RealmGridItem[] = realms.map((realm) => ({ colSpan: isCompactGrid ? { sm: 3, md: 2, lg: 2 } : { sm: 5, md: 3, lg: 3 }, data: realm!, diff --git a/landing/src/components/modules/season-passes-grid.tsx b/landing/src/components/modules/season-passes-grid.tsx index c577a9772..c9007b7e0 100644 --- a/landing/src/components/modules/season-passes-grid.tsx +++ b/landing/src/components/modules/season-passes-grid.tsx @@ -1,6 +1,6 @@ import { Button } from "@/components/ui/button"; import { GetRealmsQuery } from "@/hooks/gql/graphql"; -import { Grid2X2, Grid3X3 } from "lucide-react"; +import { Crown, Grid2X2, Grid3X3 } from "lucide-react"; import { useState } from "react"; import { AnimatedGrid } from "./animated-grid"; import { SeasonPassCard } from "./season-pass-card"; @@ -23,7 +23,39 @@ interface SeasonPassRowProps { export const SeasonPassesGrid = ({ toggleNftSelection, isNftSelected, seasonPasses }: SeasonPassRowProps) => { const [isCompactGrid, setIsCompactGrid] = useState(false); - if (!seasonPasses?.length) return
No Season Pass Found
; + if (!seasonPasses?.length) { + return ( +
+ {/* Decorative elements */} +
+
+
+
+ + +
+

+ No Season Passes Yet +

+ +

+ Your collection of season passes will appear here once you acquire them. + Get your first pass to join the game and start your journey into Eternum! +

+ + + + +
+
+ ); + } const gridItems: RealmGridItem[] = seasonPasses.map((pass) => ({ colSpan: isCompactGrid ? { sm: 3, md: 2, lg: 2 } : { sm: 5, md: 3, lg: 3 }, From 067697deefb214f2306eafff72376beeb0582d4c Mon Sep 17 00:00:00 2001 From: Credence Date: Fri, 13 Dec 2024 19:25:57 +0100 Subject: [PATCH 5/5] landing: update collection not found pages --- .../src/components/modules/realms-grid.tsx | 4 +- .../components/modules/season-passes-grid.tsx | 44 ++++++++++++------- 2 files changed, 30 insertions(+), 18 deletions(-) diff --git a/landing/src/components/modules/realms-grid.tsx b/landing/src/components/modules/realms-grid.tsx index a967ae2d2..bc09c7f84 100644 --- a/landing/src/components/modules/realms-grid.tsx +++ b/landing/src/components/modules/realms-grid.tsx @@ -49,7 +49,7 @@ export const RealmsGrid = ({

Your collection of realms will appear here once you acquire them. - Get your first realm to start your journey into Realms World! + Get your realm to start your journey into Realms World!

@@ -58,7 +58,7 @@ export const RealmsGrid = ({ className="mt-6 group hover:border-primary/50 transition-all duration-300" > - Buy Your First Realm + Get Your Realm
diff --git a/landing/src/components/modules/season-passes-grid.tsx b/landing/src/components/modules/season-passes-grid.tsx index c9007b7e0..92f3726e9 100644 --- a/landing/src/components/modules/season-passes-grid.tsx +++ b/landing/src/components/modules/season-passes-grid.tsx @@ -25,31 +25,43 @@ export const SeasonPassesGrid = ({ toggleNftSelection, isNftSelected, seasonPass if (!seasonPasses?.length) { return ( -
- {/* Decorative elements */} +
-
-
+
+
- -
-

+ + +
+

No Season Passes Yet

-

- Your collection of season passes will appear here once you acquire them. - Get your first pass to join the game and start your journey into Eternum! -

+
+

+ Your collection of season passes will appear here until you burn them to mint a realm in the game. +

+

+ Once you burn a pass, it will be removed from this view. +

+ +

+ Get your pass to join the game and start your journey into Eternum! +

+
- +