From f659d73ac2061d6541f0e502177d19712eefd36e Mon Sep 17 00:00:00 2001 From: Dan Date: Sun, 18 Feb 2024 11:36:24 +0300 Subject: [PATCH] chore: run prettier --- app/@modal/(.)account/sign-in/page.tsx | 6 +-- .../event-groups/[alias]/export/page.tsx | 8 ++-- .../(.)schedule/event-groups/[alias]/page.tsx | 14 +++---- app/dashboard/page.tsx | 13 ++++--- app/dashboard/template.tsx | 2 +- app/layout.tsx | 2 +- app/music-room/page.tsx | 4 +- app/not-found.tsx | 2 +- app/schedule/[category]/page.tsx | 2 +- app/schedule/event-groups/[alias]/page.tsx | 10 +++-- app/schedule/page.tsx | 2 +- app/scholarship/page.tsx | 2 +- app/~offline/page.tsx | 2 +- components/icons/Arrow.tsx | 5 ++- .../schedule/ClarificationContainer.tsx | 2 +- .../schedule/group-card/FavoriteButton.tsx | 2 +- components/schedule/group-card/GroupCard.tsx | 11 ++---- components/schedule/group-card/HideButton.tsx | 38 +++++++++---------- tailwind.config.js | 8 ++-- 19 files changed, 68 insertions(+), 67 deletions(-) diff --git a/app/@modal/(.)account/sign-in/page.tsx b/app/@modal/(.)account/sign-in/page.tsx index e2121e0..fe5b408 100644 --- a/app/@modal/(.)account/sign-in/page.tsx +++ b/app/@modal/(.)account/sign-in/page.tsx @@ -39,7 +39,7 @@ export default function Page() { {isMounted && ( @@ -51,12 +51,12 @@ export default function Page() { >
-
+
{searchParams.get("header") || "Sign in to get access"}
+ +
{group && ( @@ -110,7 +110,7 @@ export default function Page({ params: { alias } }: Props) {
- { /* TODO: Determine what to do with calendar margin */ } + {/* TODO: Determine what to do with calendar margin */}
-
+
@@ -53,8 +52,8 @@ export default function Page() {

-
-
+
+

Schedule

{favorites.filter((v) => v.predefined === true).length === 0 ? (

Nothing here.

@@ -88,7 +87,7 @@ export default function Page() {
)}
-
+

Favorites

{favorites.filter((v) => v.predefined === false).length === 0 ? (

@@ -114,7 +113,9 @@ export default function Page() {

Your calendar

-
{/* TODO: -mx-8 makes calendars margin not equal on PC. is it good or not? */} +
+ {" "} + {/* TODO: -mx-8 makes calendars margin not equal on PC. is it good or not? */} {!user ? ( <>Loading... ) : ( diff --git a/app/dashboard/template.tsx b/app/dashboard/template.tsx index 8f2a219..4bd40dd 100644 --- a/app/dashboard/template.tsx +++ b/app/dashboard/template.tsx @@ -2,7 +2,7 @@ import { NavbarTemplate } from "@/components/layout/Navbar"; export default function Template({ children }: React.PropsWithChildren) { return ( -
+
-
{children}
+
{children}
{modal} diff --git a/app/music-room/page.tsx b/app/music-room/page.tsx index 74c3f70..967062f 100644 --- a/app/music-room/page.tsx +++ b/app/music-room/page.tsx @@ -6,7 +6,7 @@ import React from "react"; export default function Page() { return ( -
+

Booking calendar

- { /* TODO: Determine what to do with the margin of calendar */ } + {/* TODO: Determine what to do with the margin of calendar */}
+

404 / not found

diff --git a/app/schedule/[category]/page.tsx b/app/schedule/[category]/page.tsx index 0f1eb12..cf77435 100755 --- a/app/schedule/[category]/page.tsx +++ b/app/schedule/[category]/page.tsx @@ -38,7 +38,7 @@ export default async function Page({ params: { category } }: Props) { const categoryInfo = getCategoryInfoBySlug(category); return ( -
+
{group && ( -
+
-
+

{group.name}

{group.description || @@ -55,7 +55,9 @@ export default function Page({ params: { alias } }: Props) {

Calendar

-
{/* TODO: Calendar margin is not good? */} +
+ {" "} + {/* TODO: Calendar margin is not good? */} +
+
+

You are offline

However, some pages may work.

diff --git a/components/icons/Arrow.tsx b/components/icons/Arrow.tsx index 1f746d6..8d46933 100644 --- a/components/icons/Arrow.tsx +++ b/components/icons/Arrow.tsx @@ -9,7 +9,10 @@ function Arrow({ ...props }: IconProps) { viewBox="0 0 102 38" xmlns="http://www.w3.org/2000/svg" {...props} - className={clsx("rotate-90 fill-border @2xl/clarify:rotate-0", props.className)} + className={clsx( + "rotate-90 fill-border @2xl/clarify:rotate-0", + props.className, + )} > diff --git a/components/schedule/ClarificationContainer.tsx b/components/schedule/ClarificationContainer.tsx index 9362025..d6910e4 100644 --- a/components/schedule/ClarificationContainer.tsx +++ b/components/schedule/ClarificationContainer.tsx @@ -3,7 +3,7 @@ import Arrow from "@/components/icons/Arrow"; export default function ClarificationContainer() { return ( -
+
diff --git a/components/schedule/group-card/FavoriteButton.tsx b/components/schedule/group-card/FavoriteButton.tsx index 3375883..cba7659 100644 --- a/components/schedule/group-card/FavoriteButton.tsx +++ b/components/schedule/group-card/FavoriteButton.tsx @@ -28,7 +28,7 @@ export default function FavoriteButton({ groupId }: { groupId: number }) { switchFavorite && switchFavorite(); } }} - className="w-52 h-52 p-2 -mr-2 rounded-2xl text-4xl text-icon-main/50 hover:bg-secondary-hover hover:text-icon-hover/75" + className="-mr-2 h-52 w-52 rounded-2xl p-2 text-4xl text-icon-main/50 hover:bg-secondary-hover hover:text-icon-hover/75" > {isPredefined ? ( diff --git a/components/schedule/group-card/GroupCard.tsx b/components/schedule/group-card/GroupCard.tsx index 98e5003..e943974 100644 --- a/components/schedule/group-card/GroupCard.tsx +++ b/components/schedule/group-card/GroupCard.tsx @@ -1,9 +1,6 @@ import FavoriteButton from "@/components/schedule/group-card/FavoriteButton"; import HideButton from "@/components/schedule/group-card/HideButton"; -import { - getAllTagsByType, - getFirstTagByType, -} from "@/lib/event-group"; +import { getAllTagsByType, getFirstTagByType } from "@/lib/event-group"; import { ViewEventGroup } from "@/lib/events"; import { viewConfig } from "@/lib/events-view-config"; import { useRouter } from "next/navigation"; @@ -56,10 +53,8 @@ export function GroupCard({ group, canHide = false }: GroupCardProps) { )}
- {canHide && ( - - )} - + {canHide && } +
); diff --git a/components/schedule/group-card/HideButton.tsx b/components/schedule/group-card/HideButton.tsx index 7516aa4..3b5880c 100644 --- a/components/schedule/group-card/HideButton.tsx +++ b/components/schedule/group-card/HideButton.tsx @@ -1,23 +1,23 @@ import Tooltip from "@/components/common/Tooltip"; -import {useEventGroup} from "@/lib/event-group"; +import { useEventGroup } from "@/lib/event-group"; export default function HideButton({ groupId }: { groupId: number }) { - const { isHidden, switchHideFavorite } = useEventGroup(groupId); - return - + const { isHidden, switchHideFavorite } = useEventGroup(groupId); + return ( + + -} \ No newline at end of file + ); +} diff --git a/tailwind.config.js b/tailwind.config.js index 0810e2d..06a2801 100755 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -10,11 +10,11 @@ module.exports = { theme: { extend: { width: { - 52: '3.25rem', + 52: "3.25rem", 256: "64rem", }, height: { - 52: '3.25rem', + 52: "3.25rem", }, colors: { base: "rgba(var(--color-base) / )", @@ -60,7 +60,7 @@ module.exports = { "lg-h": { raw: "(min-height: 1024px)" }, "xl-h": { raw: "(min-height: 1280px)" }, "2xl-h": { raw: "(min-height: 1536px)" }, - "4xl": { raw: "(min-width: 2048px)"}, + "4xl": { raw: "(min-width: 2048px)" }, }, spacing: { "18p": "4.5rem", @@ -71,6 +71,6 @@ module.exports = { plugins: [ // Iconify plugin addDynamicIconSelectors(), - require('@tailwindcss/container-queries'), + require("@tailwindcss/container-queries"), ], };