Skip to content

Commit

Permalink
formatted project with prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
mjanderson1227 committed Dec 2, 2024
1 parent 6358346 commit 67f3394
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
5 changes: 1 addition & 4 deletions apps/web/src/app/admin/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,7 @@ export default async function AdminLayout({ children }: AdminLayoutProps) {
<ClientToast />
<div className="fixed z-20 grid h-16 w-full grid-cols-2 bg-nav px-5">
<div className="flex items-center gap-x-4">
<Link
href={"/"}
className="mr-5 flex items-center gap-x-2"
>
<Link href={"/"} className="mr-5 flex items-center gap-x-2">
<Image
src={c.icon.svg}
alt={c.hackathonName + " Logo"}
Expand Down
14 changes: 8 additions & 6 deletions apps/web/src/app/admin/toggles/registration/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,16 @@ export default async function Page() {
pipe.get("config:registration:secretRegistrationEnabled");
// const result = await pipe.exec();

const [defaultRegistrationEnabled, defaultSecretRegistrationEnabled, defaultRSVPsEnabled, defaultRSVPLimit]: (
| string
| null
)[] = await kv.mget(
const [
defaultRegistrationEnabled,
defaultSecretRegistrationEnabled,
defaultRSVPsEnabled,
defaultRSVPLimit,
]: (string | null)[] = await kv.mget(
"config:registration:registrationEnabled",
"config:registration:secretRegistrationEnabled",
"config:registration:allowRSVPs",
"config:registration:maxRSVPs"
"config:registration:maxRSVPs",
);

return (
Expand All @@ -41,7 +43,7 @@ export default async function Page() {
)}
defaultRSVPLimit={parseRedisNumber(
defaultRSVPLimit,
c.rsvpDefaultLimit
c.rsvpDefaultLimit,
)}
/>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ export function UpdateItemWithConfirmation({
const [value, setValue] = useState(defaultValue.toString());

return (
<div className="flex items-center gap-2 max-h-8">
<div className="flex max-h-8 items-center gap-2">
<Input
className="sm:w-40 w-24 text-center text-md font-bold"
className="text-md w-24 text-center font-bold sm:w-40"
value={value}
disabled={!enabled}
onChange={({ target: { value: updated } }) => {
Expand All @@ -39,7 +39,8 @@ export function UpdateItemWithConfirmation({
/* Avoid allowing the user to update the default value to itself.
* Also disallow the user from sending a zero length input. */
setValueUpdated(
updated !== defaultValue.toString() && updated.length !== 0
updated !== defaultValue.toString() &&
updated.length !== 0,
);
}}
/>
Expand Down
8 changes: 4 additions & 4 deletions apps/web/src/lib/utils/client/shared.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { redirect } from "next/navigation";
export function getClientTimeZone(vercelIPTimeZone: string | null) {
return vercelIPTimeZone ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
}
export async function clientLogOut(){
"use server";
redirect("/");
};
export async function clientLogOut() {
"use server";
redirect("/");
}

0 comments on commit 67f3394

Please sign in to comment.