Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to Next.js 13 #24

Merged
merged 7 commits into from
Feb 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions components/all-posts-link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ interface Props {
export default function AllPostsLink({ text }: Props) {
return (
<div className="mb-10">
<Link href="/posts">
<a className="underline dark:text-white text-black">{text}</a>
<Link className="underline dark:text-white text-black" href="/posts">
{text}
</Link>
</div>
);
Expand Down
9 changes: 5 additions & 4 deletions components/nav-link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ interface Props {

export default function NavLink({ route, text }: Props) {
return (
<Link href={route}>
<a className="hover:ring-2 ring-stone-400 dark:bg-stone-800 dark:hover:bg-stone-900 text-blue-500 hover:text-blue-700 dark:text-blue-300 dark:hover:text-blue-100 px-3 py-2 mt-1 rounded-md text-sm font-medium">
{text}
</a>
<Link
className="hover:ring-2 ring-stone-400 dark:bg-stone-800 dark:hover:bg-stone-900 text-blue-500 hover:text-blue-700 dark:text-blue-300 dark:hover:text-blue-100 px-3 py-2 mt-1 rounded-md text-sm font-medium"
href={route}
>
{text}
</Link>
);
}
9 changes: 5 additions & 4 deletions components/nav-logo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ import Link from "next/link";
export default function NavLogo() {
return (
<div className="shrink-0 md:flex md:items-center">
<Link href="/">
<a className="dark:text-blue-300 dark:hover:text-blue-100 hover:text-blue-700 text-blue-500 cursor-pointer text-2xl font-mono font-bold flex items-center flex-none px-2">
&lt;Aaron Bos&#47;&gt;
</a>
<Link
className={`dark:text-blue-300 dark:hover:text-blue-100 hover:text-blue-700 text-blue-500 cursor-pointer text-2xl font-mono font-semibold flex items-center flex-none px-2`}
href="/"
>
&lt;Aaron Bos&#47;&gt;
</Link>
</div>
);
Expand Down
9 changes: 5 additions & 4 deletions components/nav-mobile-link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ interface Props {

export default function NavMobileLink({ route, text }: Props) {
return (
<Link href={route}>
<a className="dark:hover:bg-stone-900 hover:bg-blue-100 text-blue-500 dark:text-blue-300 hover:text-blue-700 dark:hover:text-blue-100 block px-3 py-2 rounded-md text-base font-medium">
{text}
</a>
<Link
className="dark:hover:bg-stone-900 hover:bg-blue-100 text-blue-500 dark:text-blue-300 hover:text-blue-700 dark:hover:text-blue-100 block px-3 py-2 rounded-md text-base font-medium"
href={route}
>
{text}
</Link>
);
}
9 changes: 5 additions & 4 deletions components/post-preview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ export default function PostPreview({
return (
<>
<div className="py-6 px-3">
<Link href={`/posts/${slug}`}>
<a className="dark:text-blue-400 text-blue-600 cursor-pointer hover:underline font-semibold text-lg">
{title}
</a>
<Link
className="dark:text-blue-400 text-blue-600 cursor-pointer hover:underline font-semibold text-lg"
href={`/posts/${slug}`}
>
{title}
</Link>
<div className="my-2 italic dark:text-gray-300 text-gray-600">
{description}
Expand Down
12 changes: 9 additions & 3 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@ module.exports = {
reactStrictMode: true, // https://nextjs.org/docs/api-reference/next.config.js/react-strict-mode
swcMinify: true,
images: {
loader: "cloudinary",
path: "https://res.cloudinary.com/aaron-bos/image/upload"
}
remotePatterns: [
{
protocol: "https",
hostname: "res.cloudinary.com",
port: "",
pathname: "/aaron-bos/image/upload/**",
},
],
},
};