Skip to content

Commit

Permalink
substitutes InferModel calls
Browse files Browse the repository at this point in the history
  • Loading branch information
xwilson03 committed Aug 17, 2024
1 parent 02756a1 commit d65bad3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 11 deletions.
5 changes: 2 additions & 3 deletions apps/web/src/app/dash/pass/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import QRCode from "react-qr-code";
import { currentUser } from "@clerk/nextjs";
import { InferModel } from "db/drizzle";
import { userCommonData } from "db/schema";
import Image from "next/image";
import c from "config";
import { format } from "date-fns";
Expand All @@ -13,9 +11,10 @@ import {
DrawerTrigger,
} from "@/components/shadcn/ui/drawer";
import { getHacker } from "db/functions";
import { Hacker } from "db/types";

interface EventPassProps {
user: InferModel<typeof userCommonData>;
user: Hacker;
clerk: NonNullable<Awaited<ReturnType<typeof currentUser>>>;
qrPayload: string;
guild: string;
Expand Down
9 changes: 4 additions & 5 deletions apps/web/src/components/schedule/Day.tsx
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
import { events } from "db/schema";
import { InferModel } from "db/drizzle";
import { format, compareAsc } from "date-fns";
import { compareAsc } from "date-fns";
import { Badge } from "@/components/shadcn/ui/badge";
import c from "config";
import Link from "next/link";
import { formatInTimeZone } from "date-fns-tz";
import { Event } from "db/types";

interface DayProps {
title: string;
subtitle: string;
events: InferModel<typeof events>[];
events: Event[];
}

interface EventItemProps {
event: InferModel<typeof events>;
event: Event;
}

export default function Day({ title, subtitle, events }: DayProps) {
Expand Down
5 changes: 2 additions & 3 deletions apps/web/src/components/schedule/EventFull.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import { events } from "db/schema";
import { InferModel } from "db/drizzle";
import c from "config";
import { Badge } from "@/components/shadcn/ui/badge";
import Balancer from "react-wrap-balancer";
import { formatInTimeZone } from "date-fns-tz";
import { Event } from "db/types";

export default function EventFull({
event,
}: {
event: InferModel<typeof events>;
event: Event;
}) {
return (
<div className="relative w-screen">
Expand Down

0 comments on commit d65bad3

Please sign in to comment.