shared library hinzugefügt
This commit is contained in:
@@ -1,22 +0,0 @@
|
||||
import { BADGES } from "@repo/db";
|
||||
import React from "react";
|
||||
|
||||
const badgeImageMapping = {
|
||||
[BADGES.P1]: "p-1.png",
|
||||
[BADGES.P2]: "p-2.png",
|
||||
[BADGES.P3]: "p-3.png",
|
||||
[BADGES.D1]: "d-1.png",
|
||||
[BADGES.D2]: "d-2.png",
|
||||
[BADGES.D3]: "d-3.png",
|
||||
[BADGES.DAY1]: "day-1-member.png",
|
||||
[BADGES.V1Veteran]: "day-1-member.png",
|
||||
};
|
||||
|
||||
export const Badge = ({ badge }: { badge: BADGES }) => (
|
||||
<img
|
||||
src={`${process.env.NEXT_PUBLIC_HUB_URL}/badges/${badgeImageMapping[badge]}`}
|
||||
alt="Badge"
|
||||
width="80"
|
||||
style={{ display: "block", margin: "0 auto" }}
|
||||
/>
|
||||
);
|
||||
@@ -1,7 +1,7 @@
|
||||
import * as React from "react";
|
||||
import { Event, User } from "@repo/db";
|
||||
import { Html, Button, render } from "@react-email/components";
|
||||
import { Badge } from "./Badge";
|
||||
import { Badge } from "@repo/shared-components";
|
||||
import { EmailFooter } from "./EmailFooter";
|
||||
|
||||
const styles = `
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@react-email/components": "^0.0.41",
|
||||
"@repo/shared-components": "workspace:*",
|
||||
"@repo/db": "workspace:*",
|
||||
"@repo/typescript-config": "workspace:*",
|
||||
"@types/cors": "^2.8.18",
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
{
|
||||
"extends": "@repo/typescript-config/base.json",
|
||||
"extends": "@repo/typescript-config/nextjs.json",
|
||||
"compilerOptions": {
|
||||
"outDir": "dist",
|
||||
"allowImportingTsExtensions": false,
|
||||
"baseUrl": ".",
|
||||
"jsx": "react-jsx"
|
||||
/* "moduleDirectories": ["node_modules", "."] */
|
||||
"jsx": "react-jsx",
|
||||
"types": ["node", "react"]
|
||||
},
|
||||
"include": ["**/*.ts", "./index.ts"],
|
||||
|
||||
"include": ["."],
|
||||
"exclude": ["node_modules", "dist"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user