mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 08:11:33 +11:00
extract content block kind
This commit is contained in:
parent
3587c599ac
commit
9c00be8d6a
|
@ -12,14 +12,7 @@ import { useMemo, useRef, useState } from "react";
|
|||
import { GbaKey } from "../components/mgba/bindings";
|
||||
import { useClientValue } from "../hooks/useClientValue.hook";
|
||||
import { MgbaHandle } from "../components/mgba/mgba";
|
||||
import { ExternalLink } from "@/components/externalLink";
|
||||
|
||||
const HelpLinks = styled.div`
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 16px;
|
||||
justify-content: space-around;
|
||||
`;
|
||||
import { ExternalLink, ExternalLinkBlock } from "@/components/externalLink";
|
||||
|
||||
const GameDisplay = styled.div`
|
||||
height: min(calc(100vw / 1.5), min(90vh, 480px));
|
||||
|
@ -133,7 +126,7 @@ export default function Home() {
|
|||
<MgbaWithControllerSides />
|
||||
</ContentBlock>
|
||||
<ContentBlock color="#256256">
|
||||
<HelpLinks>
|
||||
<ExternalLinkBlock>
|
||||
<ExternalLink href="https://github.com/agbrs/agb">
|
||||
GitHub
|
||||
</ExternalLink>
|
||||
|
@ -142,7 +135,7 @@ export default function Home() {
|
|||
Docs
|
||||
</ExternalLink>
|
||||
<ExternalLink href="./showcase">Showcase</ExternalLink>
|
||||
</HelpLinks>
|
||||
</ExternalLinkBlock>
|
||||
</ContentBlock>
|
||||
</>
|
||||
);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { slugify } from "@/sluggify";
|
||||
import { Games, ShowcaseGame } from "../games";
|
||||
import { ContentBlock } from "@/components/contentBlock";
|
||||
import { ExternalLink } from "@/components/externalLink";
|
||||
import { ExternalLink, ExternalLinkBlock } from "@/components/externalLink";
|
||||
import Link from "next/link";
|
||||
import {
|
||||
BackToShowcaseWrapper,
|
||||
|
@ -70,9 +70,11 @@ function Display({ game }: { game: ShowcaseGame }) {
|
|||
</DescriptionAndScreenshots>
|
||||
</ContentBlock>
|
||||
<ContentBlock color="#256256">
|
||||
<ExternalLinkBlock>
|
||||
{game.itch && (
|
||||
<ExternalLink href={game.itch.href}>View on itch.io</ExternalLink>
|
||||
)}
|
||||
</ExternalLinkBlock>
|
||||
</ContentBlock>
|
||||
</>
|
||||
);
|
||||
|
|
|
@ -14,3 +14,10 @@ export const ExternalLink = styled(Link)`
|
|||
border: solid black 2px;
|
||||
}
|
||||
`;
|
||||
|
||||
export const ExternalLinkBlock = styled.div`
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 16px;
|
||||
justify-content: space-around;
|
||||
`;
|
||||
|
|
Loading…
Reference in a new issue