Skip to content
This repository has been archived by the owner on Feb 11, 2023. It is now read-only.

Commit

Permalink
feat: Optimized images used for background
Browse files Browse the repository at this point in the history
  • Loading branch information
re-taro committed Dec 16, 2022
1 parent b5092ca commit f19d2c9
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 4 deletions.
Binary file removed src/assets/OGP_.png
Binary file not shown.
Binary file added src/assets/back.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 1 addition & 3 deletions src/components/card/og.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
import type { FC } from "react";

export type OgCardProps = {
name: string;
backGroundPng: string;
};

export const OgCard: FC<OgCardProps> = ({ name, backGroundPng }) => (
export const OgCard = ({ name, backGroundPng }: OgCardProps) => (
<div
style={{
width: "100%",
Expand Down
2 changes: 1 addition & 1 deletion src/pages/api/og.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export default async (req: NextRequest) => {
const { searchParams } = new URL(req.url);
const name = searchParams.get("name")?.slice(0, 100) ?? "Alibum";
const backGroundPng = new URL(
"../../assets/OGP_.png",
"../../assets/back.jpg",
import.meta.url,
).toString();
const font = fetch(
Expand Down

0 comments on commit f19d2c9

Please sign in to comment.