Skip to content

Commit

Permalink
refactor: restructure files
Browse files Browse the repository at this point in the history
  • Loading branch information
dominik-stumpf committed Nov 20, 2024
1 parent 89e7ce1 commit 86eac95
Show file tree
Hide file tree
Showing 27 changed files with 29 additions and 29 deletions.
2 changes: 1 addition & 1 deletion src/app/actions/auth.ts → src/actions/auth.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"use server";

import { GUILD_AUTH_COOKIE_NAME } from "app/config/constants";
import { GUILD_AUTH_COOKIE_NAME } from "@/config/constants";
import { cookies } from "next/headers";
import { redirect } from "next/navigation";
import { z } from "zod";
Expand Down
4 changes: 2 additions & 2 deletions src/app/explorer/components/GuildCard.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Badge } from "@/components/ui/Badge";
import { Card } from "@/components/ui/Card";
import { ImageSquare, Users } from "@phosphor-icons/react/dist/ssr";
import { Badge } from "app/components/ui/Badge";
import { Card } from "app/components/ui/Card";
import Link from "next/link";

export const GuildCard = () => {
Expand Down
10 changes: 5 additions & 5 deletions src/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import type { Metadata } from "next";
import "./globals.css";
import { Providers } from "components/Providers";
import { dystopian, inter } from "fonts";
import "@/styles/globals.css";
import { Header } from "@/components/Header";
import { Providers } from "@/components/Providers";
import { SignInDialog } from "@/components/SignInDialog";
import { dystopian, inter } from "@/lib/fonts";
import { cn } from "lib/cssUtils";
import { Header } from "./components/Header";
import { SignInDialog } from "./components/SignInDialog";

export const metadata: Metadata = {
title: "Guildhall",
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Providers.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { wagmiConfig } from "@/config/wagmi";
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
import { wagmiConfig } from "app/config/wagmi";
import { ThemeProvider } from "next-themes";
import type { FunctionComponent, PropsWithChildren } from "react";
import { WagmiProvider } from "wagmi";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { signInDialogOpenAtom } from "@/config/atoms";
import { SignIn } from "@phosphor-icons/react/dist/ssr";
import { signInDialogOpenAtom } from "app/config/atoms";
import { useSetAtom } from "jotai";
import { Button } from "./ui/Button";
import { Card } from "./ui/Card";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
"use client";

import { signIn } from "@/actions/auth";
import { signInDialogOpenAtom } from "@/config/atoms";
import { SignIn, User, Wallet } from "@phosphor-icons/react/dist/ssr";
import { useMutation } from "@tanstack/react-query";
import { signIn } from "app/actions/auth";
import { signInDialogOpenAtom } from "app/config/atoms";
import { useAtom, useSetAtom } from "jotai";
import { shortenHex } from "lib/shortenHex";
import { createSiweMessage } from "viem/siwe";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { signOut } from "@/actions/auth";
import { SignOut } from "@phosphor-icons/react/dist/ssr";
import { signOut } from "app/actions/auth";
import { usePathname } from "next/navigation";
import { Button } from "./ui/Button";

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions src/fonts.ts → src/lib/fonts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,21 @@ const inter = Inter({
const dystopian = localFont({
src: [
{
path: "../public/fonts/Dystopian-Light.woff2",
path: "../../public/fonts/Dystopian-Light.woff2",
weight: "300",
style: "normal",
},
{
path: "../public/fonts/Dystopian-Regular.woff2",
path: "../../public/fonts/Dystopian-Regular.woff2",
style: "normal",
},
{
path: "../public/fonts/Dystopian-Bold.woff2",
path: "../../public/fonts/Dystopian-Bold.woff2",
weight: "600",
style: "normal",
},
{
path: "../public/fonts/Dystopian-Black.woff2",
path: "../../public/fonts/Dystopian-Black.woff2",
weight: "700",
style: "normal",
},
Expand Down
2 changes: 1 addition & 1 deletion src/stories/Badge.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Badge, type BadgeProps } from "@/components/ui/Badge";
import type { Meta, StoryObj } from "@storybook/react";
import { Badge, type BadgeProps } from "app/components/ui/Badge";

const meta: Meta<typeof Badge> = {
title: "Design system/Badge",
Expand Down
2 changes: 1 addition & 1 deletion src/stories/Button.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Button, type ButtonProps } from "@/components/ui/Button";
import { CircleDashed } from "@phosphor-icons/react/dist/ssr";
import type { Meta, StoryObj } from "@storybook/react";
import { Button, type ButtonProps } from "app/components/ui/Button";

type ButtonExampleProps = Omit<ButtonProps, "leftIcon" | "rightIcon"> & {
leftIcon?: boolean;
Expand Down
4 changes: 2 additions & 2 deletions src/stories/Dialog.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import type { Meta, StoryObj } from "@storybook/react";
import {
Dialog,
DialogBody,
Expand All @@ -9,7 +8,8 @@ import {
DialogHeader,
DialogTitle,
DialogTrigger,
} from "app/components/ui/Dialog";
} from "@/components/ui/Dialog";
import type { Meta, StoryObj } from "@storybook/react";

import type { ComponentProps } from "react";

Expand Down
6 changes: 3 additions & 3 deletions src/stories/Drawer.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import type { Meta, StoryObj } from "@storybook/react";
import { Button } from "app/components/ui/Button";
import { Button } from "@/components/ui/Button";
import {
Drawer,
DrawerClose,
Expand All @@ -8,7 +7,8 @@ import {
DrawerHeader,
DrawerTitle,
DrawerTrigger,
} from "app/components/ui/Drawer";
} from "@/components/ui/Drawer";
import type { Meta, StoryObj } from "@storybook/react";

const DrawerExample = () => (
<Drawer>
Expand Down
8 changes: 4 additions & 4 deletions src/stories/ResponsiveDialog.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import type { Meta, StoryObj } from "@storybook/react";
import { Button } from "app/components/ui/Button";
import type { DialogContentProps } from "app/components/ui/Dialog";
import { Button } from "@/components/ui/Button";
import type { DialogContentProps } from "@/components/ui/Dialog";
import {
ResponsiveDialog,
ResponsiveDialogBody,
Expand All @@ -10,7 +9,8 @@ import {
ResponsiveDialogHeader,
ResponsiveDialogTitle,
ResponsiveDialogTrigger,
} from "app/components/ui/ResponsiveDialog";
} from "@/components/ui/ResponsiveDialog";
import type { Meta, StoryObj } from "@storybook/react";

import type { ComponentProps } from "react";

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
],
"strictNullChecks": true,
"paths": {
"@/*": ["./src/*"]
"@/*": ["./*"]
}
},
"include": [
Expand Down

0 comments on commit 86eac95

Please sign in to comment.