Skip to content

Commit

Permalink
fix: always import types from "react"
Browse files Browse the repository at this point in the history
  • Loading branch information
BrickheadJohnny committed Jan 2, 2025
1 parent 27cbb2f commit ba05480
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { SignInDialog } from "@/components/SignInDialog";
import { Toaster } from "@/components/ui/Toaster";
import { dystopian } from "@/lib/fonts";
import { cn } from "lib/cssUtils";
import { Suspense } from "react";
import { type ReactNode, Suspense } from "react";

export const metadata: Metadata = {
title: "Guildhall",
Expand All @@ -23,7 +23,7 @@ export const metadata: Metadata = {
const RootLayout = ({
children,
}: Readonly<{
children: React.ReactNode;
children: ReactNode;
}>) => {
return (
<html lang="en" suppressHydrationWarning>
Expand Down
5 changes: 3 additions & 2 deletions src/components/AuthBoundary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@

import { userOptions } from "@/lib/options";
import { useQuery } from "@tanstack/react-query";
import type { ReactNode } from "react";

export const AuthBoundary = ({
fallback,
children,
}: Readonly<{
fallback: React.ReactNode;
children: React.ReactNode;
fallback: ReactNode;
children: ReactNode;
}>) => {
const { data: user } = useQuery(userOptions());

Expand Down
6 changes: 2 additions & 4 deletions src/components/ui/Skeleton.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
import { cn } from "@/lib/cssUtils";
import type { HTMLAttributes } from "react";

function Skeleton({
className,
...props
}: React.HTMLAttributes<HTMLDivElement>) {
function Skeleton({ className, ...props }: HTMLAttributes<HTMLDivElement>) {
return (
<div
className={cn("animate-pulse rounded-md bg-skeleton", className)}
Expand Down
3 changes: 2 additions & 1 deletion src/components/ui/Toaster.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"use client";

import { useTheme } from "next-themes";
import type { ComponentProps } from "react";
import { Toaster as Sonner } from "sonner";

type ToasterProps = React.ComponentProps<typeof Sonner>;
type ToasterProps = ComponentProps<typeof Sonner>;

const Toaster = ({ ...props }: ToasterProps) => {
const { theme = "system" } = useTheme();
Expand Down

0 comments on commit ba05480

Please # to comment.