Skip to content

Commit

Permalink
Ultracite fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
haydenbleasel committed Jul 21, 2024
1 parent e4a2b67 commit e932d42
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 21 deletions.
9 changes: 7 additions & 2 deletions app/(pages)/(home)/cards/steam.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,17 @@ const SteamCard = async (): Promise<ReactElement> => {
className="flex flex-col justify-between gap-4 p-4 sm:flex-row"
>
<div className="flex flex-col justify-between gap-4 text-sm">
<Link href={`https://store.steampowered.com/app/${game.id}`} className="line-clamp-4">
<Link
href={`https://store.steampowered.com/app/${game.id}`}
className="line-clamp-4"
>
{game.name}
</Link>
<div>
<p className="truncate">🕦 {Math.round(game.playtime / 60)} hours</p>
<p className="truncate">🏆 {game.completeAchievements} achievements</p>
<p className="truncate">
🏆 {game.completeAchievements} achievements
</p>
</div>
</div>
<Image
Expand Down
3 changes: 2 additions & 1 deletion app/(pages)/(home)/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ const Home = async (): Promise<ReactElement> => {
priority
/>
<h1 className="text-3xl leading-tight tracking-tight sm:text-4xl">
Hello, I’m Hayden Bleasel. I’m an Australian Design Engineer currently based in {location}.
Hello, I’m Hayden Bleasel. I’m an Australian Design Engineer currently
based in {location}.
</h1>
<Newsletter />
<div className="prose-img:m-0 prose-p:m-0 grid gap-3 md:grid-cols-3">
Expand Down
26 changes: 11 additions & 15 deletions app/(pages)/blog/[slug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@ export const runtime = 'nodejs';

export const generateMetadata = ({ params }: PageProperties): Metadata => {
const currentPath = params.slug;
const page = allBlogs.find(
({ slug }) => slug === currentPath
);
const page = allBlogs.find(({ slug }) => slug === currentPath);

if (!page) {
return {};
Expand All @@ -32,15 +30,15 @@ export const generateMetadata = ({ params }: PageProperties): Metadata => {
description: page.description,
openGraph: page.image
? {
images: [
{
url: new URL(page.image, siteUrl).href,
width: 1920,
height: 1080,
alt: page.title,
},
],
}
images: [
{
url: new URL(page.image, siteUrl).href,
width: 1920,
height: 1080,
alt: page.title,
},
],
}
: undefined,
};
};
Expand All @@ -52,9 +50,7 @@ export const generateStaticParams = (): PageProperties['params'][] =>

const Page: FC<PageProperties> = ({ params }) => {
const currentPath = params.slug;
const page = allBlogs.find(
({ slug }) => slug === currentPath
);
const page = allBlogs.find(({ slug }) => slug === currentPath);

if (!page) {
notFound();
Expand Down
2 changes: 1 addition & 1 deletion app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ body {
.shiki[title]:before {
content: attr(title);
@apply inline-block text-neutral-500 dark:text-neutral-400 text-right mb-6 text-sm;
}
}
2 changes: 1 addition & 1 deletion components/mdx.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { useMDXComponent } from "@content-collections/mdx/react";
import { useMDXComponent } from '@content-collections/mdx/react';
import Image from 'next/image';
import type { FC, HTMLProps, ReactNode } from 'react';
import { Video } from './video';
Expand Down
2 changes: 1 addition & 1 deletion next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { withContentCollections } from "@content-collections/next";
import { withContentCollections } from '@content-collections/next';
import withBundleAnalyzer from '@next/bundle-analyzer';
import { createSecureHeaders } from 'next-secure-headers';

Expand Down

0 comments on commit e932d42

Please sign in to comment.