revert outage
This commit is contained in:
MeowcaTheoRange 2024-05-02 14:24:14 -04:00
parent 610c6adf31
commit 66d7c241d6
5 changed files with 18 additions and 60 deletions

View file

@ -2,29 +2,18 @@ import { MainLayout } from "@/layout/MainLayout/MainLayout";
import Link from "next/link";
import buttons from "@/buttons.json";
import Searchbar from "@/components/Searchbar/Searchbar";
import { Outage } from "@/components/Outage/Outage";
export default async function Home() {
const data = await fetch("https://pronouns.cc/api/v1/users/mtr").then(x=>x.json());
let domains;
try {
const domainreq = await fetch("https://blog.abtmtr.link/api/collections/paste/posts/domain")
.then(x=>x.json());
domains = JSON.parse(domainreq?.data?.body.replace(/[“”]/g, "\"")) ?? [];
} catch(err) {
domains = [];
}
const domains = JSON.parse(domainreq?.data?.body.replace(/[“”]/g, "\"")) ?? [];
const goodNames = data.names.filter((x:{status:string})=>x.status == "okay");
return (
<MainLayout currentPage="/" title="Root">
<img className="headerImage" src="/welcome.png" alt="WELCOME! Enjoy your stay at abtmtr.link!"></img>
<Searchbar />
<Outage title="abtmtr.link outage">
<p>the server was being stinky and died on me</p>
<p>feel free to support me during these trying times</p>
<p><a href="https://liberapay.com/abtmtr.link/">https://liberapay.com/abtmtr.link/</a></p>
</Outage>
<p>abtmtr.link is a domain for a suite of services, ranging from micro-blogging to web search.</p>
<p>I'm {goodNames[0].value}, otherwise known as {goodNames.slice(1).map((name:{value:string}, idx:number) => (
idx == goodNames.length - 2 ? (<>or <b>{name.value}</b></>) : (<><b>{name.value}</b>{goodNames.length <= 2 ? ", " : " "}</>)

View file

@ -1,8 +0,0 @@
import styles from "./styles.module.css";
export function Outage({title, children}:{title: string, children: React.ReactNode}) {
return <div className={styles.Outage}>
<h1>{title}</h1>
{children}
</div>
}

View file

@ -1,15 +0,0 @@
.Outage {
background-color: #c00000;
color: white;
padding: 8px;
border-radius: 8px;
}
.Outage a {
color: currentColor;
}
.Outage h1,
.Outage p {
margin: 8px 0;
}

View file

@ -38,18 +38,18 @@ export function SidebarMain({currentPage}:{currentPage:string}) {
<span className={styles.Main_List_Button_Badge}>NEW</span>
</div>
</Link>
{/* <Link
<Link
href="/search/"
className={currentPage.includes("/search/") ? styles.Main_List_CurrentLink : ""}
tabIndex={-1}
// onClick={() => currentPage === "/" ? impossiblePlay() : openPlay()}
// onMouseEnter={hoverPlay}
> */}
>
<div className={`fw ${styles.Main_List_Button}`}>
<span className="icon">search</span>
<span>Search</span>
</div>
{/* </Link> */}
</Link>
<Link
href="/projects/"
className={currentPage.includes("/projects/") ? styles.Main_List_CurrentLink : ""}
@ -62,54 +62,54 @@ export function SidebarMain({currentPage}:{currentPage:string}) {
<span>Projects</span>
</div>
</Link>
{/* <Link
<Link
href="/characters/"
className={currentPage.includes("/characters/") ? styles.Main_List_CurrentLink : ""}
tabIndex={-1}
// onClick={() => currentPage.includes("/characters/") ? impossiblePlay() : openPlay()}
// onMouseEnter={hoverPlay}
> */}
>
<div className={`fw ${styles.Main_List_Button}`}>
<span className="icon">group</span>
<span>Characters</span>
</div>
{/* </Link> */}
{/* <Link
</Link>
<Link
href="/blog/"
className={currentPage.includes("/blog/") ? styles.Main_List_CurrentLink : ""}
tabIndex={-1}
// onClick={() => currentPage.includes("/blog/") ? impossiblePlay() : openPlay()}
// onMouseEnter={hoverPlay}
> */}
>
<div className={`fw ${styles.Main_List_Button}`}>
<span className="icon">description</span>
<span>Blog</span>
</div>
{/* </Link> */}
{/* <Link
</Link>
<Link
href="/gallery/"
className={currentPage.includes("/gallery/") ? styles.Main_List_CurrentLink : ""}
tabIndex={-1}
// onClick={() => currentPage.includes("/gallery/") ? impossiblePlay() : openPlay()}
// onMouseEnter={hoverPlay}
> */}
>
<div className={`fw ${styles.Main_List_Button}`}>
<span className="icon">image</span>
<span>Gallery</span>
</div>
{/* </Link> */}
{/* <Link
</Link>
<Link
href="/stories/"
className={currentPage.includes("/stories/") ? styles.Main_List_CurrentLink : ""}
tabIndex={-1}
// onClick={() => currentPage.includes("/stories/") ? impossiblePlay() : openPlay()}
// onMouseEnter={hoverPlay}
> */}
>
<div className={`fw ${styles.Main_List_Button}`}>
<span className="icon">book</span>
<span>Stories</span>
</div>
{/* </Link> */}
</Link>
<Link
href="/links/"
className={currentPage.includes("/links/") ? styles.Main_List_CurrentLink : ""}

View file

@ -9,7 +9,6 @@ export interface Database {
content: ContentTable;
judgements: JudgementTable;
tokens: TokenTable;
slowchat: SlowchatTable;
}
export interface AppTable {
@ -67,13 +66,6 @@ export interface JudgementTable {
published: number;
}
export interface SlowchatTable {
id: string;
author_id: string;
content: string;
published: number;
}
export const db = createKysely<Database>({
});