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

chore(all): use biome #1833

Merged
merged 12 commits into from
Jan 16, 2025
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.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 1 addition & 3 deletions .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [
["react-email-starter", "create-email"]
],
"fixed": [["react-email-starter", "create-email"]],
"linked": [],
"access": "public",
"baseBranch": "main",
Expand Down
42 changes: 6 additions & 36 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,37 +5,7 @@ on:
- main
pull_request:
jobs:
format:
runs-on: buildjet-4vcpu-ubuntu-2204
container:
image: node:18
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Enable Corepack
id: pnpm-setup
run: |
corepack enable
corepack prepare pnpm@latest --activate
pnpm config set script-shell "/usr/bin/bash"
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"
- name: pnpm Cache
uses: buildjet/cache@v4
with:
path: ${{ steps.pnpm-setup.outputs.pnpm_cache_dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install packages
run: pnpm install --frozen-lockfile

- name: Run Format Check
run: pnpm format:check

test:
lint:
gabrielmfern marked this conversation as resolved.
Show resolved Hide resolved
runs-on: buildjet-4vcpu-ubuntu-2204
container:
image: node:18
Expand Down Expand Up @@ -65,10 +35,10 @@ jobs:
- name: Run Build
run: pnpm build

- name: Run Tests
run: pnpm test
- name: Run Lint
run: pnpm lint

lint:
test:
runs-on: buildjet-4vcpu-ubuntu-2204
container:
image: node:18
Expand Down Expand Up @@ -98,8 +68,8 @@ jobs:
- name: Run Build
run: pnpm build

- name: Run Lint
run: pnpm lint
- name: Run Tests
run: pnpm test

build:
runs-on: buildjet-4vcpu-ubuntu-2204
Expand Down
1 change: 0 additions & 1 deletion .prettierignore

This file was deleted.

1 change: 0 additions & 1 deletion .prettierrc

This file was deleted.

88 changes: 44 additions & 44 deletions apps/demo/emails/magic-links/aws-verify-email.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,19 @@ import {
Preview,
Section,
Text,
} from "@react-email/components";
import * as React from "react";
} from '@react-email/components';
import * as React from 'react';

interface AWSVerifyEmailProps {
verificationCode?: string;
}

const baseUrl = process.env.VERCEL_URL
? `https://${process.env.VERCEL_URL}`
: "";
: '';

export default function AWSVerifyEmail({
verificationCode = "596853",
verificationCode = '596853',
}: AWSVerifyEmailProps) {
return (
<Html>
Expand Down Expand Up @@ -68,11 +68,11 @@ export default function AWSVerifyEmail({
This message was produced and distributed by Amazon Web Services,
Inc., 410 Terry Ave. North, Seattle, WA 98109. © 2022, Amazon Web
Services, Inc.. All rights reserved. AWS is a registered trademark
of{" "}
of{' '}
<Link href="https://amazon.com" target="_blank" style={link}>
Amazon.com
</Link>
, Inc. View our{" "}
, Inc. View our{' '}
<Link href="https://amazon.com" target="_blank" style={link}>
privacy policy
</Link>
Expand All @@ -85,88 +85,88 @@ export default function AWSVerifyEmail({
}

const main = {
backgroundColor: "#fff",
color: "#212121",
backgroundColor: '#fff',
color: '#212121',
};

const container = {
padding: "20px",
margin: "0 auto",
backgroundColor: "#eee",
padding: '20px',
margin: '0 auto',
backgroundColor: '#eee',
};

const h1 = {
color: "#333",
color: '#333',
fontFamily:
"-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif",
fontSize: "20px",
fontWeight: "bold",
marginBottom: "15px",
fontSize: '20px',
fontWeight: 'bold',
marginBottom: '15px',
};

const link = {
color: "#2754C5",
color: '#2754C5',
fontFamily:
"-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif",
fontSize: "14px",
textDecoration: "underline",
fontSize: '14px',
textDecoration: 'underline',
};

const text = {
color: "#333",
color: '#333',
fontFamily:
"-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif",
fontSize: "14px",
margin: "24px 0",
fontSize: '14px',
margin: '24px 0',
};

const imageSection = {
backgroundColor: "#252f3d",
display: "flex",
padding: "20px 0",
alignItems: "center",
justifyContent: "center",
backgroundColor: '#252f3d',
display: 'flex',
padding: '20px 0',
alignItems: 'center',
justifyContent: 'center',
};

const coverSection = { backgroundColor: "#fff" };
const coverSection = { backgroundColor: '#fff' };

const upperSection = { padding: "25px 35px" };
const upperSection = { padding: '25px 35px' };

const lowerSection = { padding: "25px 35px" };
const lowerSection = { padding: '25px 35px' };

const footerText = {
...text,
fontSize: "12px",
padding: "0 20px",
fontSize: '12px',
padding: '0 20px',
};

const verifyText = {
...text,
margin: 0,
fontWeight: "bold",
textAlign: "center" as const,
fontWeight: 'bold',
textAlign: 'center' as const,
};

const codeText = {
...text,
fontWeight: "bold",
fontSize: "36px",
margin: "10px 0",
textAlign: "center" as const,
fontWeight: 'bold',
fontSize: '36px',
margin: '10px 0',
textAlign: 'center' as const,
};

const validityText = {
...text,
margin: "0px",
textAlign: "center" as const,
margin: '0px',
textAlign: 'center' as const,
};

const verificationSection = {
display: "flex",
alignItems: "center",
justifyContent: "center",
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
};

const mainText = { ...text, marginBottom: "14px" };
const mainText = { ...text, marginBottom: '14px' };

const cautionText = { ...text, margin: "0px" };
const cautionText = { ...text, margin: '0px' };
Loading
Loading