Skip to content

Commit

Permalink
Changed some metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianCheung1 committed Oct 19, 2023
1 parent e1aa439 commit be09b75
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 8 deletions.
Binary file modified app/favicon.ico
Binary file not shown.
11 changes: 10 additions & 1 deletion app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,16 @@ import "@mantine/core/styles.css"

export const metadata: Metadata = {
title: "PokeData",
description: "Pokemon Go Data",
description: "Pokemon Go Database",
openGraph: {
title: "PokeData",
description: "Pokemon Go Database",
images: "/images/pokemon-go-logo.png",
url: "https://pokedata-rose.vercel.app/",
siteName: "PokeData",
locale: "en_US",
type: "website",
},
}

export default function RootLayout({ children }: { children: any }) {
Expand Down
14 changes: 10 additions & 4 deletions app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@

import { Container, Flex, Title } from "@mantine/core"
import { Container, Flex, Title, Text } from "@mantine/core"
import { SearchBar } from "@/components/SearchBar"
import { NavBar } from "@/components/NavBar"
import { EventList } from "@/components/EventList"

export default function Home() {
return (
Expand All @@ -14,7 +12,15 @@ export default function Home() {
align="center"
direction="column"
>
<Title order={1}>PokeData</Title>
<Text
size="calc(5rem * var(--mantine-scale))"
fw={900}
variant="gradient"
gradient={{ from: "blue", to: "green", deg: 90 }}
>
PokeData
</Text>

<SearchBar />
</Flex>
</Container>
Expand Down
16 changes: 13 additions & 3 deletions components/TeamRocketGrunts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,16 @@ export const TeamRocketGrunts = () => {
const { data, isLoading } = useGrunts()
const router = useRouter()

// Get an array of color keys
const colorKeys = Object.keys(colors)

// Generate a random index within the range of colorKeys
const randomIndex = Math.floor(Math.random() * colorKeys.length)

// Use the random key to access a color from the dictionary
const randomColorKey = colorKeys[randomIndex]
const randomColor = colors[randomColorKey]

const renderGrunts = (grunt: {
name: string
team: any[]
Expand All @@ -29,10 +39,12 @@ export const TeamRocketGrunts = () => {
<Grid.Col key={grunt.name} span={{ base: 12, md: 6, xl: 4 }}>
<Card
bg={darken(
grunt.type ? colors[grunt.type.toLowerCase()] : "yellow",
grunt.type ? colors[grunt.type.toLowerCase()] : randomColor,
0.7
)}
radius="md"
withBorder
h={750}
>
<Text>
{grunt.name
Expand Down Expand Up @@ -63,9 +75,7 @@ export const TeamRocketGrunts = () => {
<Stack key={pokemon.name}>
<Image
src={pokemon.sprite}
// h={200}
h={100}
// w="auto"
fit="contain"
alt="Pokemon"
fallbackSrc="/images/default-pokemon.jpg"
Expand Down
Binary file added public/images/pokemon-go-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit be09b75

Please sign in to comment.