Skip to content

Commit

Permalink
feat(OpenGraphImage): remove all custom assets
Browse files Browse the repository at this point in the history
  • Loading branch information
mathiazom committed Sep 6, 2024
1 parent 1712678 commit 1278eb0
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 51 deletions.
7 changes: 1 addition & 6 deletions src/app/api/openGraphImage/OpenGraphImage.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { getBackground } from "./background";

interface OpenGraphImageProps {
title: string;
description?: string;
Expand All @@ -12,7 +10,7 @@ const OpenGraphImage = ({ title, description }: OpenGraphImageProps) => {
display: "flex",
flexDirection: "column",
color: "white",
background: getBackground(),
background: "#13141b",
width: "100%",
height: "100%",
padding: "0 75px",
Expand All @@ -29,7 +27,6 @@ const OpenGraphImage = ({ title, description }: OpenGraphImageProps) => {
>
<span
style={{
fontFamily: "Recoleta",
fontSize: 78,
}}
>
Expand All @@ -38,8 +35,6 @@ const OpenGraphImage = ({ title, description }: OpenGraphImageProps) => {
{description && (
<span
style={{
fontFamily: "Graphik",
fontWeight: 400,
fontSize: 36,
}}
>
Expand Down
4 changes: 0 additions & 4 deletions src/app/api/openGraphImage/background.ts

This file was deleted.

39 changes: 0 additions & 39 deletions src/app/api/openGraphImage/fontUtils.ts

This file was deleted.

2 changes: 0 additions & 2 deletions src/app/api/openGraphImage/route.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { ImageResponse } from "next/og";
import { NextRequest } from "next/server";
import OpenGraphImage from "./OpenGraphImage";
import { getFonts } from "./fontUtils";

export async function GET(request: NextRequest) {
const searchParams = request.nextUrl.searchParams;
Expand All @@ -12,7 +11,6 @@ export async function GET(request: NextRequest) {
{
width: 1200,
height: 630,
fonts: await getFonts(),
},
);
}

0 comments on commit 1278eb0

Please sign in to comment.