Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added bag platform section #263

Merged
merged 1 commit into from
Jan 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions app/components/new-landing/sections/Games.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import TOE_BACKGROUND from "~/../public/img/new-landing/game-backgrounds/The_ToE

import { twMerge } from "tailwind-merge";
import { ChevronRightIcon } from "../misc/Icons";
import { set } from "nprogress";

const games = [
{
Expand Down Expand Up @@ -92,11 +93,25 @@ const Games = () => {
/>

{/* Carousel container */}
<div className="relative z-10 mb-20 flex cursor-pointer gap-12">
<div className="relative z-10 mb-20 flex h-[600px] cursor-pointer gap-12 transition-all">
{games.map((game) => (
<div
className="h-[600px] w-[416px] min-w-[416px] overflow-hidden rounded-2xl border border-night-100/40"
className={twMerge(
"absolute h-[600px] w-[416px] min-w-[416px] overflow-hidden rounded-2xl border border-night-100/40",
activeGame === games.indexOf(game) && "scale-110"
)}
style={{
left: `${
(games.indexOf(game) - activeGame) * 416 +
games.indexOf(game) * 32
}px`,
}}
key={game.name}
onClick={() => {
if (!(activeGame === games.indexOf(game))) {
setActiveGame(games.indexOf(game));
}
}}
>
<img
src={game.cover}
Expand Down
3 changes: 2 additions & 1 deletion app/routes/_index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import Games from "~/components/new-landing/sections/Games";
import Ctas from "~/components/new-landing/sections/Ctas";
import Bridgeworld from "~/components/new-landing/sections/Bridgeworld";
import Chain from "~/components/new-landing/sections/Chain";
import Platform from "~/components/new-landing/sections/Platform";

export const headers: HeadersFunction = commonHeaders;

Expand All @@ -30,7 +31,7 @@ export default function Home() {
<Intro />
<Partners />
<Games />
{/* <Platform /> */}
<Platform />
<Chain />
<Bridgeworld />
<Ctas />
Expand Down