Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
120 commits
Select commit Hold shift + click to select a range
677f0f4
chore: add season three components
corlard3y Mar 24, 2026
3840d6b
chore: fix deploy preview for just this branch
corlard3y Mar 24, 2026
5a05083
update preview file
corlard3y Mar 24, 2026
370f29f
chore: update preview file
corlard3y Mar 24, 2026
f5720e1
chore: add unverified state hook
corlard3y Mar 25, 2026
8fccba9
chore: fix sybil states
corlard3y Mar 27, 2026
12d53f2
chore: fix loading state
corlard3y Mar 28, 2026
90c6009
chore: fix cache in leaderboard
corlard3y Mar 28, 2026
9df2016
fix invite code section
corlard3y Mar 28, 2026
3275af3
fix push-pass
corlard3y Mar 28, 2026
a3c1fbe
chore: add the two json files
corlard3y Mar 28, 2026
c1312a0
chore: add json items
corlard3y Mar 28, 2026
ca1bb99
add images for quests and banner
corlard3y Mar 29, 2026
d5ce1e7
add boss quests images
corlard3y Mar 29, 2026
b65d4f1
chore: add and fix moile stats card
corlard3y Mar 29, 2026
dda8d5b
add image
corlard3y Mar 29, 2026
c59b3a6
chore: fix mobile boss quests
corlard3y Mar 29, 2026
19f72e0
chore: fix boss quest img
corlard3y Mar 29, 2026
9d8d0f7
Merge branch 'main' into addSeasonThreeChanges
corlard3y Mar 29, 2026
fa5e488
merge main
corlard3y Mar 30, 2026
db4d073
chore: fix sybil with api check
corlard3y Mar 31, 2026
a89cbc7
chore: update naming
corlard3y Mar 31, 2026
b49bb65
fix sybil flow in verification logic
corlard3y Apr 1, 2026
da60885
chore: add max-height
corlard3y Apr 1, 2026
828b556
chore: resolve comments
corlard3y Apr 2, 2026
2842d26
chore: resolve more issues
corlard3y Apr 2, 2026
359eed8
chore: update activities
corlard3y Apr 3, 2026
905b659
changes
corlard3y Apr 3, 2026
59f67bd
chore: add claim completed
corlard3y Apr 3, 2026
19a649f
chore: add progress completed
corlard3y Apr 3, 2026
030f4f2
chore: fix rare pass issues
corlard3y Apr 3, 2026
b7d371f
update pass images
corlard3y Apr 3, 2026
b701d43
add loading states, error states
corlard3y Apr 3, 2026
b5209e6
debug characterimage
corlard3y Apr 3, 2026
72cb941
fix character images
corlard3y Apr 3, 2026
9eaae46
fix pass image
corlard3y Apr 3, 2026
a1dd9db
restructure positions
corlard3y Apr 3, 2026
65e6729
rename badge
corlard3y Apr 3, 2026
5b5056a
add level svgs
corlard3y Apr 4, 2026
71cd625
add svgs for levels
corlard3y Apr 4, 2026
211f10d
chore: add bossquest progress percentage
corlard3y Apr 4, 2026
66a658f
chore: add pass to rarepasssection
corlard3y Apr 4, 2026
0d6007b
rm: remove auto signer
corlard3y Apr 4, 2026
792eb69
chore: fix squads pending
corlard3y Apr 4, 2026
21001ae
chore: fix squad level
corlard3y Apr 4, 2026
16badce
chore: add socials redirect on sidebar
corlard3y Apr 4, 2026
5de70ea
chore: show free spin on condition
corlard3y Apr 4, 2026
e8c9b6d
chore: fix open pass
corlard3y Apr 4, 2026
96a65bd
fix re-roll
corlard3y Apr 4, 2026
063de8c
chore: add skeleton loader
corlard3y Apr 4, 2026
f14b28f
chore: update quest ui
corlard3y Apr 4, 2026
417bdf4
chore: fix rewards
corlard3y Apr 4, 2026
6ae907f
chore: comment quest progress
corlard3y Apr 5, 2026
2f25bf1
chore: update quest refresh colors
corlard3y Apr 5, 2026
c5c31b4
chore: rename unminted pass
corlard3y Apr 5, 2026
599cd22
chore: add quest rewards modal
corlard3y Apr 5, 2026
7ac4a98
chore: fix scrollbar and spintowin
corlard3y Apr 5, 2026
497fcf5
chore: add more skeleton effects
corlard3y Apr 5, 2026
a935690
chore: remove verification proof and add skip verification proof
corlard3y Apr 5, 2026
51b3a97
chore: add claimpc tokens flow
corlard3y Apr 5, 2026
140c4ca
add pc tokens api
corlard3y Apr 5, 2026
2248a17
chore: add level config details
corlard3y Apr 5, 2026
ebab196
add util files
corlard3y Apr 5, 2026
cc5b428
chore: fix spin to win and rare pass thingy
corlard3y Apr 5, 2026
5e9a940
update item
corlard3y Apr 5, 2026
645483c
chore: fix text
corlard3y Apr 5, 2026
6cd942c
fix pushpass
corlard3y Apr 5, 2026
da4e407
chore: update background img
corlard3y Apr 5, 2026
e511fc3
Merge branch 'main' of https://github.com/pushchain/push-portal into …
corlard3y Apr 5, 2026
34087fa
chore: enable social login for authHeaders
corlard3y Apr 5, 2026
17349bd
claim button quest && comment out verification proof skip
corlard3y Apr 5, 2026
1e51bee
add reset to spintowin, fix daily rewards and add scrollbar
corlard3y Apr 5, 2026
ea808ee
chore: fix rare pass
corlard3y Apr 5, 2026
00743e3
add reflection
corlard3y Apr 5, 2026
4d4b97b
chore: add steps
corlard3y Apr 6, 2026
a92e173
chore: add verification on load for quests
corlard3y Apr 6, 2026
d4d62f1
chore: update invite code modal
corlard3y Apr 6, 2026
60fc4c0
add imgs for invite code modal
corlard3y Apr 6, 2026
dfd0b00
chore: fix verification onload
corlard3y Apr 6, 2026
b3903f4
correct links
corlard3y Apr 6, 2026
6bee8a7
chore: add disconnect flow
corlard3y Apr 6, 2026
84f99ae
chore: add loading states for signers
corlard3y Apr 6, 2026
2c6d004
chore: fix loading state
corlard3y Apr 6, 2026
184e8d1
chore: rm console
corlard3y Apr 6, 2026
4fbe6e5
chore: fix quest rewards
corlard3y Apr 6, 2026
6cedb75
chore: add event tracking for ga
corlard3y Apr 6, 2026
4120d55
add analytics helper
corlard3y Apr 6, 2026
6d0c6ec
chore: update ui-kit
corlard3y Apr 6, 2026
d292774
chore: fix discord verification page
corlard3y Apr 6, 2026
5dad8ee
chore: add error message for sybil check
corlard3y Apr 7, 2026
507d865
add sybil check utils
corlard3y Apr 7, 2026
b2cf8a0
chore: check dormant pass - update messages
corlard3y Apr 7, 2026
b10dc8d
chore: fix onclick of rare pass
corlard3y Apr 7, 2026
9c18cfd
chore: remove tabs, add badge, rework positioning
corlard3y Apr 7, 2026
221142f
chore: fix responsive design
corlard3y Apr 7, 2026
5120bf6
chore: fix small laptop view
corlard3y Apr 7, 2026
7d2c94a
chore: update rare pass
corlard3y Apr 7, 2026
dfae2d6
chore: test fadein
corlard3y Apr 7, 2026
9dc363e
add fade in component
corlard3y Apr 7, 2026
4f697d7
add scroll to top
corlard3y Apr 7, 2026
7afaaaf
chore: update ui-kit
corlard3y Apr 8, 2026
6945e84
chore: fix percentage bar
corlard3y Apr 8, 2026
6227019
chore: add quest activities and flow
corlard3y Apr 8, 2026
0f7e617
Merge branch 'main' into addSeasonThreeChanges
corlard3y Apr 8, 2026
92b795c
chore: resolve some issues
corlard3y Apr 8, 2026
e97ec41
merge main
corlard3y Apr 8, 2026
6c5ba14
chore: import pkg
corlard3y Apr 8, 2026
87e6bfd
chore: resolve issues
corlard3y Apr 8, 2026
9ddfbca
feat: update changes for linked wallet
riyanshu-patro Apr 8, 2026
e7c00b6
resolve discussions
corlard3y Apr 9, 2026
2324a05
update web3helper
corlard3y Apr 9, 2026
0006ec3
chore: add advanced sybil changes
corlard3y Apr 9, 2026
c2d0ad3
chore: add solana fix
corlard3y Apr 9, 2026
86c7e89
chore: fix quest time, invite code and add passes
corlard3y Apr 9, 2026
97243ad
chore: add boss quest spin card
corlard3y Apr 9, 2026
2909081
chore: fix modal on tablet
corlard3y Apr 9, 2026
bd859b0
chore: fix invite codes
corlard3y Apr 9, 2026
d93a310
chore: add wallet used in sybil check
corlard3y Apr 9, 2026
4cf436f
chore: add prod baseurl
corlard3y Apr 9, 2026
4c23ba6
roll-back deploy preview url
corlard3y Apr 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .github/workflows/preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ jobs:
if: github.event.action == 'closed' && !github.event.pull_request.merged
with:
source-dir: ./build/
action: remove
action: removec
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"@babel/runtime": "^7.26.9",
"@emotion/react": "^11.14.0",
"@metamask/eth-sig-util": "^4.0.0",
"@pushchain/ui-kit": "^5.2.0-alpha.0",
"@pushchain/ui-kit": "^5.2.0-alpha.4",
"@pushprotocol/restapi": "^1.7.31",
"@pushprotocol/uiweb": "1.7.1",
"@radix-ui/react-dialog": "^1.1.6",
Expand Down
File renamed without changes
274 changes: 151 additions & 123 deletions src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// React + Web3 Essentials
import React, { useState, useEffect } from "react";
import React, { useState, useEffect, useRef } from "react";

// External Packages
import {
Expand All @@ -13,11 +13,11 @@ import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
import { ReactQueryDevtools } from "@tanstack/react-query-devtools";
import { createGlobalStyle, css } from "styled-components";
import {
PushUI,
PushUniversalWalletProvider,
ProviderConfigProps,
usePushWalletContext,
} from '@pushchain/ui-kit';
PushUI,
PushUniversalWalletProvider,
ProviderConfigProps,
usePushWalletContext,
} from "@pushchain/ui-kit";

import { getPreviewBasePath } from "../basePath";
import { FLAGS } from "./config/flags";
Expand Down Expand Up @@ -47,7 +47,8 @@ import { RewardStatusContextProvider } from "./context/rewardStatusContext";
import S3CountdownPage from "./pages/S3CountdownPage";
import CultPage from "./pages/CultPage";
import { ActivityContextProvider } from "./context/activityContext";

import { trackEvent } from "./helpers/analytics";
import { LinkedWalletProvider } from "./context/linkedWalletContext";

const GlobalStyle = createGlobalStyle`
body {
Expand Down Expand Up @@ -122,21 +123,40 @@ const queryClient = new QueryClient({});

const AppContent = () => {
const location = useLocation();
const { connectionStatus, universalAccount } = usePushWalletContext('wallet1');
const { connectionStatus, universalAccount } =
usePushWalletContext("wallet1");
const [isSidebarOpen, setIsSidebarOpen] = useState(false);
const [isInviteCodeModalOpen, setIsInviteCodeModalOpen] = useState(false);
const scrollContainerRef = useRef<HTMLDivElement | null>(null);

const caip10WalletAddress = walletToFullCAIP10(
universalAccount?.address as string,
universalAccount?.chain,
);

const { data: seasonThreeDetails, isLoading } = useGetSeasonThreeUserByWallet({
walletAddress: caip10WalletAddress,
});
const { data: seasonThreeDetails, isLoading } = useGetSeasonThreeUserByWallet(
{
walletAddress: caip10WalletAddress,
},
);

const prevConnectionStatus = React.useRef(connectionStatus);

useEffect(() => {
if (
prevConnectionStatus.current !== "connected" &&
connectionStatus === "connected"
) {
trackEvent("wallet_connected", {
event_category: "auth",
event_label: "login_success",
});
}
prevConnectionStatus.current = connectionStatus;
}, [connectionStatus]);

useEffect(() => {
if (connectionStatus !== 'connected') return;
if (connectionStatus !== "connected") return;

if (isLoading) return;

Expand All @@ -147,36 +167,40 @@ const AppContent = () => {
}
}, [connectionStatus, seasonThreeDetails, isLoading]);

useEffect(() => {
const el = scrollContainerRef.current;
if (!el) return;
el.scrollTo({ top: 0, left: 0, behavior: "smooth" });
}, [location.pathname]);

const toggleSidebar = () => {
setIsSidebarOpen(!isSidebarOpen);
};

const hideSideBar = location.pathname === "/discord/verification" || location.pathname === "/admin/controls";
const hideSideBar =
location.pathname === "/discord/verification" ||
location.pathname === "/admin/controls";
const isAdminPage = location.pathname === "/admin/controls";

return (
<Box
display="flex"
flexDirection="column"
height="100vh"
css={css``}
>
{!isAdminPage &&
(<Box
css={css`
position: fixed;
left: 0;
top: 0;
bottom: 0;
right: 0;
width: 100%;
height: 100%;
background: url(${SeasonBg}) no-repeat center center fixed;
background-size: cover;
pointer-events: none;
z-index: 0;
`}
/>)}
<Box display="flex" flexDirection="column" height="100vh" css={css``}>
{!isAdminPage && (
<Box
css={css`
position: fixed;
left: 0;
top: 0;
bottom: 0;
right: 0;
width: 100%;
height: 100%;
background: url(${SeasonBg}) no-repeat center center fixed;
background-size: cover;
pointer-events: none;
z-index: -1;
`}
/>
)}

<Header toggleSidebar={toggleSidebar} />
<Box
Expand All @@ -194,7 +218,9 @@ const AppContent = () => {
)}
<Box
width="100%"
maxWidth={hideSideBar ? "100%" : "1200px"}
// maxWidth={hideSideBar ? "100%" : "100%"}
customScrollbar
ref={scrollContainerRef}
padding={{
initial: "spacing-none spacing-md",
tb: "spacing-none spacing-xs",
Expand All @@ -205,33 +231,68 @@ const AppContent = () => {
margin: ${hideSideBar ? "0" : "0 auto"};
`}
>
<Routes>
{/*<Route path="/" element={FLAGS.SEASON_THREE ? <Navigate to="/rewards" replace /> : <S3CountdownPage />} />*/}
{FLAGS.SEASON_THREE && <>
<Route path="/" element={<Navigate to="/rewards" replace />} />
<Route path="/admin/controls" element={<AdminPage />} />
<Route path="/rewards" element={<RewardsPage />} />
<Route path="/rewards/pushpass" element={<PushPassPage />} />
<Route path="/rewards/squads" element={<SquadsPage />} />
<Route path="/rewards/pre-launch" element={<PreLaunchPage />} />
<Route path="/rewards/pushpass/:id" element={<PushPassItemPage />} />
<Route path="/rewards/leaderboard" element={<LeaderBoardPage />} />
<Route path="/rewards/leaderboard-s2" element={<LeaderBoardPage />} />
<Route path="/rewards/leaderboard-s1" element={<LeaderBoardPage />} />
</>}
{FLAGS.CULT && <>
<Box
css={css`
max-width: 1200px;
margin: 0 auto;
min-height: 100%;
display: flex;
flex-direction: column;
`}
>
<Routes>
{/*<Route path="/" element={FLAGS.SEASON_THREE ? <Navigate to="/rewards" replace /> : <S3CountdownPage />} />*/}
<Route path="/admin/controls" element={<AdminPage />} />
<Route path="/" element={<S3CountdownPage />} />
<Route path="/cult" element={<CultPage />} />
{/*TODO: comment out for now */}
{/*<Route path="/cult/leaderboard" element={<CultLeaderboardPage />} />*/}
</>}
<Route
path="/discord/verification"
element={<DiscordVerificationPage />}
/>
<Route path="*" element={<NotFound />} />
</Routes>
<Route
path="/discord/verification"
element={<DiscordVerificationPage />}
/>

{FLAGS.SEASON_THREE && (
<>
<Route
path="/"
element={<Navigate to="/rewards" replace />}
/>
<Route path="/rewards" element={<RewardsPage />} />
<Route path="/rewards/pushpass" element={<PushPassPage />} />
<Route path="/rewards/squads" element={<SquadsPage />} />
<Route
path="/rewards/pre-launch"
element={<PreLaunchPage />}
/>
<Route
path="/rewards/pushpass/:id"
element={<PushPassItemPage />}
/>
<Route
path="/rewards/leaderboard"
element={<LeaderBoardPage />}
/>
<Route
path="/rewards/leaderboard-s2"
element={<LeaderBoardPage />}
/>
<Route
path="/rewards/leaderboard-s1"
element={<LeaderBoardPage />}
/>
</>
)}
{FLAGS.CULT && (
<>
<Route path="/" element={<S3CountdownPage />} />
<Route path="/cult" element={<CultPage />} />
{/*TODO: comment out for now */}
<Route
path="/cult/leaderboard"
element={<CultLeaderboardPage />}
/>
</>
)}
<Route path="*" element={<NotFound />} />
</Routes>
</Box>
</Box>
</Box>

Expand All @@ -244,46 +305,21 @@ const AppContent = () => {
};

function App() {

const walletConfig: ProviderConfigProps = {
uid: 'wallet1',
uid: "wallet1",
network: PushUI.CONSTANTS.PUSH_NETWORK.TESTNET,
// NOTE: comment socials till S3 launch
login: {
email: false,
google: false,
phone: false,
email: true,
google: true,
phone: true,
wallet: {
enabled: true,
},
socials: {
discord: false,
github: false,
x: false,
bluesky: false,
},
appPreview: true,
},
modal: {
loginLayout: PushUI.CONSTANTS.LOGIN.LAYOUT.SPLIT,
connectedLayout: PushUI.CONSTANTS.CONNECTED.LAYOUT.HOVER,
appPreview: true,
connectedInteraction: PushUI.CONSTANTS.CONNECTED.INTERACTION.BLUR,
},
chainConfig: {
rpcUrls: {
},
},
};

const linkedWalletConfig: ProviderConfigProps = {
uid: 'wallet2',
network: PushUI.CONSTANTS.PUSH_NETWORK.TESTNET,
login: {
email: false,
google: false,
wallet: {
enabled: true,
discord: true,
github: true,
x: true,
bluesky: true,
},
appPreview: true,
},
Expand All @@ -294,8 +330,7 @@ function App() {
connectedInteraction: PushUI.CONSTANTS.CONNECTED.INTERACTION.BLUR,
},
chainConfig: {
rpcUrls: {
},
rpcUrls: {},
},
};

Expand All @@ -304,35 +339,28 @@ function App() {
{/* Global style */}
<GlobalStyle />
<Router basename={basename}>
<PushUniversalWalletProvider
config={walletConfig}
themeMode={PushUI.CONSTANTS.THEME.DARK}
themeOverrides={{
'--pw-core-font-family': "'DM Sans', sans-serif",
'--pwauth-btn-connected-bg-color': '#D548EC'
}}
>
{/*<PushUniversalWalletProvider
config={linkedWalletConfig}
<PushUniversalWalletProvider
config={walletConfig}
themeMode={PushUI.CONSTANTS.THEME.DARK}
themeOverrides={{
'--pw-core-font-family': "'DM Sans', sans-serif",
'--pwauth-btn-connected-bg-color': '#D548EC'
"--pw-core-font-family": "'DM Sans', sans-serif",
"--pwauth-btn-connected-bg-color": "#D548EC",
}}
>*/}
<QueryClientProvider client={queryClient}>
<RewardsContextProvider>
<AuthHeadersProvider>
<RewardStatusContextProvider>
<ActivityContextProvider>
<AppContent />
<ReactQueryDevtools initialIsOpen={false} />
</ActivityContextProvider>
</RewardStatusContextProvider>
</AuthHeadersProvider>
</RewardsContextProvider>
</QueryClientProvider>
{/*</PushUniversalWalletProvider>*/}
>
<LinkedWalletProvider>
<QueryClientProvider client={queryClient}>
<RewardsContextProvider>
<AuthHeadersProvider>
<RewardStatusContextProvider>
<ActivityContextProvider>
<AppContent />
<ReactQueryDevtools initialIsOpen={false} />
</ActivityContextProvider>
</RewardStatusContextProvider>
</AuthHeadersProvider>
</RewardsContextProvider>
</QueryClientProvider>
</LinkedWalletProvider>
</PushUniversalWalletProvider>
</Router>
</ThemeProviderWrapper>
Expand Down
Loading
Loading