Skip to content

Commit

Permalink
Ultracite safe fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
haydenbleasel committed Jul 19, 2024
1 parent f00bdc7 commit cd6d4db
Show file tree
Hide file tree
Showing 27 changed files with 83 additions and 98 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
"quickfix.biome": "explicit",
"source.organizeImports.biome": "explicit"
}
}
}
2 changes: 1 addition & 1 deletion actions/subscribe.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
'use server';

import { z } from 'zod';
import { resend } from '@/lib/resend';
import { parseError } from '@/lib/utils';
import { z } from 'zod';

const audienceId = process.env.RESEND_AUDIENCE_ID;

Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/(home)/cards/announcement.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { get } from '@vercel/edge-config';
import { Card } from '@/components/card';
import { Link } from '@/components/link';
import { cn } from '@/lib/utils';
import { Card } from '@/components/card';
import { get } from '@vercel/edge-config';
import type { ReactElement } from 'react';

export const AnnouncementCard = async (): Promise<ReactElement> => {
Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/(home)/cards/github.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
'use client';

import GitHubCalendar from 'react-github-calendar';
import { useState } from 'react';
import { Card } from '@/components/card';
import { useState } from 'react';
import type { FC } from 'react';
import GitHubCalendar from 'react-github-calendar';

type Activity = {
date: string;
Expand Down
6 changes: 3 additions & 3 deletions app/(pages)/(home)/cards/spotify.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { SpotifyProperties } from '@/app/api/cron/spotify/route';
import { Card } from '@/components/card';
import { Link } from '@/components/link';
import { get } from '@vercel/edge-config';
import Image from 'next/image';
import { Link } from '@/components/link';
import { Card } from '@/components/card';
import type { ReactElement } from 'react';
import type { SpotifyProperties } from '@/app/api/cron/spotify/route';

const SpotifyCard = async (): Promise<ReactElement> => {
const song = await get<SpotifyProperties>('spotify');
Expand Down
8 changes: 4 additions & 4 deletions app/(pages)/(home)/cards/steam.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import Image from 'next/image';
import { get } from '@vercel/edge-config';
import { Link } from '@/components/link';
import { Card } from '@/components/card';
import type { GameProperties } from '@/app/api/cron/steam/route';
import { Card } from '@/components/card';
import { Link } from '@/components/link';
import { get } from '@vercel/edge-config';
import Image from 'next/image';
import type { ReactElement } from 'react';

const SteamCard = async (): Promise<ReactElement> => {
Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/(home)/components/avatar.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Image from 'next/image';
import { cn } from '@/lib/utils';
import Profile from './avatar.jpg';
import Image from 'next/image';
import type { FC } from 'react';
import Profile from './avatar.jpg';

export const Avatar: FC = () => (
<Image
Expand Down
10 changes: 5 additions & 5 deletions app/(pages)/(home)/components/github.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import Image from 'next/image';
import { get } from '@vercel/edge-config';
import { cn } from '@/lib/utils';
import { Link } from '@/components/link';
import GitHubLogo from './github.svg';
import type { ReactElement } from 'react';
import { cn } from '@/lib/utils';
import { get } from '@vercel/edge-config';
import Image from 'next/image';
import type { StaticImageData } from 'next/image';
import type { ReactElement } from 'react';
import GitHubLogo from './github.svg';

export const GitHub = async (): Promise<ReactElement> => {
const github = await get<{ followers: number }>('github');
Expand Down
2 changes: 1 addition & 1 deletion app/(pages)/(home)/components/location.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { get } from '@vercel/edge-config';
import { cn } from '@/lib/utils';
import { get } from '@vercel/edge-config';
import type { ReactElement } from 'react';

export const Location = async (): Promise<ReactElement> => {
Expand Down
2 changes: 1 addition & 1 deletion app/(pages)/(home)/components/newsletter.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
'use client';

import { useFormState, useFormStatus } from 'react-dom';
import { subscribe } from '@/actions/subscribe';
import { cn } from '@/lib/utils';
import type { FC } from 'react';
import { useFormState, useFormStatus } from 'react-dom';

const SubmitButton: FC = () => {
const { pending } = useFormStatus();
Expand Down
12 changes: 6 additions & 6 deletions app/(pages)/(home)/page.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { Newsletter } from './components/newsletter';
import GitHubCard from './cards/github';
import type { Metadata } from 'next';
import type { FC } from 'react';
import { AnnouncementCard } from './cards/announcement';
import GitHubCard from './cards/github';
import SpotifyCard from './cards/spotify';
import SteamCard from './cards/steam';
import { Avatar } from './components/avatar';
import { GitHub } from './components/github';
import { Location } from './components/location';
import { Newsletter } from './components/newsletter';
import { Wave } from './components/wave';
import { GitHub } from './components/github';
import { Avatar } from './components/avatar';
import type { FC } from 'react';
import type { Metadata } from 'next';

export const metadata: Metadata = {
title: 'Hayden Bleasel',
Expand Down
14 changes: 7 additions & 7 deletions app/(pages)/blog/[slug]/page.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { notFound } from 'next/navigation';
import Image from 'next/image';
import { ArrowLeftToLineIcon } from 'lucide-react';
import { allBlogs } from '@contentlayer/generated';
import { Mdx } from '@/components/mdx';
import { Link } from '@/components/link';
import { Header } from '@/components/header';
import { Link } from '@/components/link';
import { Mdx } from '@/components/mdx';
import { siteUrl } from '@/lib/consts';
import type { FC } from 'react';
import { allBlogs } from '@contentlayer/generated';
import { ArrowLeftToLineIcon } from 'lucide-react';
import type { Metadata } from 'next';
import Image from 'next/image';
import { notFound } from 'next/navigation';
import type { FC } from 'react';

type PageProperties = {
readonly params: {
Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/contact/components/contact-form.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
'use client';

import { useFormState, useFormStatus } from 'react-dom';
import { Card } from '@/components/card';
import { Input, Select, Textarea } from '@/components/form';
import { cn } from '@/lib/utils';
import { contact } from '../actions/contact';
import type { FC } from 'react';
import { useFormState, useFormStatus } from 'react-dom';
import { contact } from '../actions/contact';

const SubmitButton: FC = () => {
const { pending } = useFormStatus();
Expand Down
2 changes: 1 addition & 1 deletion app/(pages)/contact/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Header } from '@/components/header';
import { ContactForm } from './components/contact-form';
import type { Metadata } from 'next';
import type { FC } from 'react';
import { ContactForm } from './components/contact-form';

const title = 'Contact';
const description =
Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/features/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Header } from '@/components/header';
import { Link } from '@/components/link';
import speaking from '@/data/speaking.json';
import features from '@/data/features.json';
import { Header } from '@/components/header';
import speaking from '@/data/speaking.json';
import type { Metadata } from 'next';
import type { FC } from 'react';

Expand Down
6 changes: 3 additions & 3 deletions app/(pages)/stack/page.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import Image from 'next/image';
import { Link } from '@/components/link';
import stack from '@/data/stack.json';
import { Card } from '@/components/card';
import { Header } from '@/components/header';
import { Link } from '@/components/link';
import stack from '@/data/stack.json';
import { cn } from '@/lib/utils';
import type { Metadata } from 'next';
import Image from 'next/image';
import type { FC } from 'react';

const title = 'Stack';
Expand Down
4 changes: 2 additions & 2 deletions app/(pages)/work/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Header } from '@/components/header';
import { Link } from '@/components/link';
import work from '@/data/work.json';
import clients from '@/data/clients.json';
import { Header } from '@/components/header';
import work from '@/data/work.json';
import type { Metadata } from 'next';
import type { FC } from 'react';

Expand Down
2 changes: 1 addition & 1 deletion app/about/inline-image.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Image from 'next/image';
import { Link } from '@/components/link';
import Image from 'next/image';
import type { StaticImageData } from 'next/image';
import type { FC } from 'react';

Expand Down
18 changes: 9 additions & 9 deletions app/about/page.tsx
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
import Image from 'next/image';

import PageLayout from '@/app/(pages)/layout';
import { Header } from '@/components/header';
import { Link } from '@/components/link';
import { cn } from '@/lib/utils';
import { Header } from '@/components/header';
import PageLayout from '@/app/(pages)/layout';
import type { COBEOptions } from 'cobe';
import type { Metadata } from 'next';
import type { StaticImageData } from 'next/image';
import type { FC } from 'react';
import { Travel } from '../components/travel';
import Avatar from './avatar.jpg';
import Profile from './profile.jpg';
import Refraction from './refraction.jpg';
import Corellium from './corellium.svg';
import Eververse from './eververse.svg';
import Jellypepper from './jellypepper.svg';
import { InlineImage } from './inline-image';
import type { COBEOptions } from 'cobe';
import type { StaticImageData } from 'next/image';
import type { Metadata } from 'next';
import type { FC } from 'react';
import Jellypepper from './jellypepper.svg';
import Profile from './profile.jpg';
import Refraction from './refraction.jpg';

export const metadata: Metadata = {
title: 'About',
Expand Down
4 changes: 2 additions & 2 deletions app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ code > [data-line]::before {
counter-increment: line;
}

code[data-line-numbers-max-digits='2'] > [data-line]::before {
code[data-line-numbers-max-digits="2"] > [data-line]::before {
@apply w-6;
}

code[data-line-numbers-max-digits='3'] > [data-line]::before {
code[data-line-numbers-max-digits="3"] > [data-line]::before {
@apply w-8;
}

Expand Down
8 changes: 4 additions & 4 deletions app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { GeistSans } from 'geist/font/sans';
import { GeistMono } from 'geist/font/mono';
import { Toaster } from 'sonner';
import { Analytics } from '@vercel/analytics/react';
import { Navbar } from '@/components/navbar';
import { siteUrl } from '@/lib/consts';
import { cn } from '@/lib/utils';
import { Analytics } from '@vercel/analytics/react';
import { GeistMono } from 'geist/font/mono';
import { GeistSans } from 'geist/font/sans';
import type { Metadata } from 'next';
import type { FC, ReactNode } from 'react';
import { Toaster } from 'sonner';
import './globals.css';

type RootLayoutProperties = {
Expand Down
6 changes: 3 additions & 3 deletions components/form.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { useId, useState } from 'react';
import { cn } from '@/lib/utils';
import * as RadixLabel from '@radix-ui/react-label';
import type { LabelProps } from '@radix-ui/react-label';
import * as RadixSelect from '@radix-ui/react-select';
import { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react';
import { cn } from '@/lib/utils';
import type { LabelProps } from '@radix-ui/react-label';
import { useId, useState } from 'react';
import type { ChangeEventHandler, ComponentProps, FC } from 'react';

type CustomProperties = {
Expand Down
6 changes: 3 additions & 3 deletions components/navbar.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use client';

import { usePathname } from 'next/navigation';
import { cn } from '@/lib/utils';
import {
BriefcaseBusinessIcon,
CircleUserIcon,
Expand All @@ -10,9 +10,9 @@ import {
NewspaperIcon,
NotebookPenIcon,
} from 'lucide-react';
import { cn } from '@/lib/utils';
import { Link } from './link';
import { usePathname } from 'next/navigation';
import type { FC } from 'react';
import { Link } from './link';

const pages = [
{ name: 'Home', path: '/', icon: HomeIcon },
Expand Down
2 changes: 1 addition & 1 deletion components/video.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use client';

import dynamic from 'next/dynamic';
import { cn } from '@/lib/utils';
import dynamic from 'next/dynamic';
import type { FC } from 'react';
import type { ReactPlayerProps } from 'react-player';

Expand Down
18 changes: 9 additions & 9 deletions contentlayer.config.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
import { defineDocumentType, makeSource } from 'contentlayer2/source-files';
import remarkGfm from 'remark-gfm';
import rehypePrettyCode from 'rehype-pretty-code';
import rehypeSlug from 'rehype-slug';
import rehypeAutolinkHeadings from 'rehype-autolink-headings';
import { rehypeAccessibleEmojis } from 'rehype-accessible-emojis';
import type { ComputedFields } from 'contentlayer2/source-files';
import { extractTocHeadings } from 'pliny/mdx-plugins/remark-toc-headings.js';
import readingTime from 'reading-time';
import { rehypeAccessibleEmojis } from 'rehype-accessible-emojis';
import rehypeAutolinkHeadings from 'rehype-autolink-headings';
import type { Options as RehypeAutoLinkHeadingsOptions } from 'rehype-autolink-headings';
import rehypePresetMinify from 'rehype-preset-minify';
import { extractTocHeadings } from 'pliny/mdx-plugins/remark-toc-headings.js';
import rehypePrettyCode from 'rehype-pretty-code';
import type { Options as PrettyCodeOptions } from 'rehype-pretty-code';
import rehypeSlug from 'rehype-slug';
import remarkGfm from 'remark-gfm';
import { sqip } from 'sqip';
import moonlightTheme from './public/moonlight-ii.json' with { type: 'json' };
import type { Options as PrettyCodeOptions } from 'rehype-pretty-code';
import type { Options as RehypeAutoLinkHeadingsOptions } from 'rehype-autolink-headings';
import type { ComputedFields } from 'contentlayer2/source-files';

export const computeFields = <T extends string>({
openGraphEndpoint = '/api/og',
Expand Down
2 changes: 1 addition & 1 deletion lib/utils.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { clsx } from 'clsx';
import { twMerge } from 'tailwind-merge';
import type { ClassValue } from 'clsx';
import { twMerge } from 'tailwind-merge';

export const cn = (...inputs: ClassValue[]): string => twMerge(clsx(inputs));

Expand Down
25 changes: 5 additions & 20 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
{
"compilerOptions": {
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
Expand All @@ -22,24 +18,13 @@
}
],
"paths": {
"@contentlayer/generated": [
"./.contentlayer/generated"
],
"@/*": [
"./*"
]
"@contentlayer/generated": ["./.contentlayer/generated"],
"@/*": ["./*"]
},
"strictNullChecks": true,
"baseUrl": ".",
"target": "ES2017"
},
"include": [
"next-env.d.ts",
"**/*.ts",
"**/*.tsx",
".next/types/**/*.ts"
],
"exclude": [
"node_modules"
]
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"exclude": ["node_modules"]
}

0 comments on commit cd6d4db

Please sign in to comment.