Repalced CSS Themes with styled-components on index, about and games

This commit is contained in:
Neshura 2022-12-15 23:20:26 +01:00
parent dd1ab4bad9
commit d60c6ca3b5
No known key found for this signature in database
GPG key ID: ACDF5B6EBECF6B0A
7 changed files with 166 additions and 197 deletions

View file

@ -1,20 +1,21 @@
import Head from 'next/head'
import styles from '/styles/Home.module.css'
import { PageDescription, PageTitle } from '../components/styles/content'
export default function About() {
return (
<>
<Head>
<title>Neshura Servers</title>
<title>Neshweb - About</title>
<meta charSet='utf-8' />
<link rel="icon" href="/favicon.ico" />
</Head>
<h1 className={styles.title}>
<PageTitle>
About
</h1>
<p className={styles.description}>
</PageTitle>
<PageDescription>
This website is primarily for managing my game servers in one spot
</p>
</PageDescription>
</>
)
}

View file

@ -1,53 +1,50 @@
import Head from 'next/head'
import Link from 'next/link'
import styles from '/styles/Home.module.css'
import fsPromises from 'fs/promises'
import path from 'path'
import type { CustomLink, EntryList } from '../interfaces/LinkTypes'
import { PageContentBox, PageCard, PageDescription, PageTitle, PageCardContentGame } from '../components/styles/content'
import Link from 'next/link'
function Servers(props: EntryList) {
const serverList = props.games
return (
<>
<Head>
<title>Neshura Servers</title>
<title>Neshweb - Games</title>
<meta charSet='utf-8' />
<link rel="icon" href="/favicon.ico" />
</Head>
<h1 className={styles.title}>
<PageTitle>
Server List
</h1>
</PageTitle>
<p className={styles.description}>
<PageDescription>
Lists all available Services, probably up-to-date
</p>
<div className={styles.grid}>
</PageDescription>
<PageContentBox>
{Object.values(serverList).map((item: CustomLink) => {
if (item.href != null) {
return (
<Link className={styles.contentcard} key={item.name} href={item.href}>
<div className={styles.contenttitle}><h2>{item.name}</h2></div>
<div><p>{item.desc}</p></div>
<div><p>{item.ip}</p></div>
<div className={item.status == "Online" ? styles.contentonline : styles.contentoffline}><p>{item.status}</p></div>
</Link>
<PageCard key={item.name}>
<Link href={item.href}>
<PageCardContentGame content={item} />
</Link>
</PageCard>
)
}
else {
return (
<a key={item.name} className={styles.contentcardstatic}>
<div className={styles.contenttitle}><h2>{item.name}</h2></div>
<div><p>{item.desc}</p></div>
<div><p>{item.ip}</p></div>
<div className={item.status == "Online" ? styles.contentonline : styles.contentoffline}><p>{item.status}</p></div>
</a>
<PageCard key={item.name}>
<PageCardContentGame content={item} />
</PageCard>
)
}
}
)}
</div>
</PageContentBox>
</>
)
}

View file

@ -1,39 +1,44 @@
import Head from 'next/head'
import Link from 'next/link'
import styles from '/styles/Home.module.css'
import Link from 'next/link';
import { PageTitle, PageDescription, PageContentBox, PageCard } from '../components/styles/content';
export default function Home() {
return (
<>
<Head>
<title>Neshweb - Home</title>
<title>Neshweb - Home</title>
<meta charSet='utf-8' />
<link rel="icon" href="/favicon.ico" />
</Head>
<h1 className={styles.title}>
<PageTitle>
Welcome to my Servers Webpage
</h1>
</PageTitle>
<p className={styles.description}>
<PageDescription>
Feel free to look around
</p>
<div className={styles.grid}>
<Link className={styles.card} key="about" href="/about">
<h2>About &rarr;</h2>
<p>Useless Info, don&apos;t bother</p>
</Link>
</PageDescription>
<PageContentBox>
<PageCard key="about">
<Link href="/about">
<h2>About &rarr;</h2>
<p>Useless Info, don&apos;t bother</p>
</Link>
</PageCard>
<Link className={styles.card} key="servers" href="/games">
<h2>Games &rarr;</h2>
<p>List of all available Servers</p>
</Link>
<PageCard key="servers">
<Link href="/games">
<h2>Games &rarr;</h2>
<p>List of all available Servers</p>
</Link>
</PageCard>
<Link className={styles.card} key="services" href="/services">
<h2>Services &rarr;</h2>
<p>List of available Services</p>
</Link>
</div>
<PageCard key="services">
<Link href="/services">
<h2>Services &rarr;</h2>
<p>List of available Services</p>
</Link>
</PageCard>
</PageContentBox>
</>
)
}