Skip to content

Commit d2750e1

Browse files
committed
improve accessibility, load times
1 parent 39391e4 commit d2750e1

5 files changed

Lines changed: 20 additions & 9 deletions

File tree

src/assets/index.css

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,22 @@
11
@import 'tailwindcss';
22
@import "tw-animate-css";
33

4+
@font-face {
5+
font-family: 'Geist';
6+
src: url('./fonts/Geist-Variable.woff2') format('woff2');
7+
font-weight: 100 900;
8+
font-style: normal;
9+
font-display: swap;
10+
}
11+
12+
@font-face {
13+
font-family: 'Geist Mono';
14+
src: url('./fonts/GeistMono-Variable.woff2') format('woff2');
15+
font-weight: 100 900;
16+
font-style: normal;
17+
font-display: swap;
18+
}
19+
420
@theme {
521
--color-background: #0a0f1a;
622
--color-foreground: #e2e8f0;

src/components/Footer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default function Footer() {
1818
{author.url ? (
1919
<a
2020
href={author.url}
21-
className="text-foreground underline-offset-4 hover:underline"
21+
className="text-foreground underline underline-offset-4 hover:text-accent"
2222
data-umami-event={`Footer - ${author.name}`}
2323
target="_blank"
2424
rel="noopener noreferrer"

src/components/Navbar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default function Navbar() {
99
<header className="sticky top-0 z-50 border-b border-border bg-background/80 backdrop-blur-sm">
1010
<nav className="mx-auto flex h-16 max-w-3xl items-center justify-between px-6 md:px-8">
1111
<Link to="/" className="flex items-center gap-2">
12-
<img src={logo} alt="py-clash-bot" width={32} height={32} />
12+
<img src={logo} alt="" width={32} height={32} />
1313
<span className="font-semibold text-foreground">py-clash-bot</span>
1414
</Link>
1515
<div className="flex items-center gap-6">

src/components/cms/MarkdownLink.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const MarkdownLink = ({ href, children }: MarkdownLinkProps) => {
2121
const isExternal = resolvedHref.startsWith('http') || resolvedHref.startsWith('//')
2222

2323
const className =
24-
'text-accent font-medium underline-offset-4 transition-colors hover:text-accent/80 hover:underline'
24+
'text-accent font-medium underline underline-offset-4 transition-colors hover:text-accent/80'
2525

2626
if (isExternal) {
2727
return (

src/routes/__root.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,6 @@ export const Route = createRootRoute({
2727
links: [
2828
{ rel: 'canonical', href: 'https://www.pyclashbot.app/' },
2929
{ rel: 'icon', href: '/favicon.ico' },
30-
{ rel: 'preconnect', href: 'https://fonts.googleapis.com' },
31-
{ rel: 'preconnect', href: 'https://fonts.gstatic.com', crossOrigin: 'anonymous' },
32-
{
33-
rel: 'stylesheet',
34-
href: 'https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono:wght@400;500&display=swap',
35-
},
3630
{ rel: 'stylesheet', href: appCss },
3731
],
3832
scripts: [
@@ -60,6 +54,7 @@ function RootDocument({ children }: Readonly<{ children: ReactNode }>) {
6054
return (
6155
<html lang="en">
6256
<head>
57+
<title>{title}</title>
6358
<HeadContent />
6459
</head>
6560
<body className="font-sans antialiased">

0 commit comments

Comments
 (0)