From 083ea5bd19172381bb53e95aaf98eaabef839c54 Mon Sep 17 00:00:00 2001 From: MohamedBassem Date: Tue, 6 Feb 2024 12:26:29 +0000 Subject: Move the web app into a subdir --- lib/types/api/links.ts | 26 -------------------------- lib/types/next-auth.d.ts | 12 ------------ 2 files changed, 38 deletions(-) delete mode 100644 lib/types/api/links.ts delete mode 100644 lib/types/next-auth.d.ts (limited to 'lib/types') diff --git a/lib/types/api/links.ts b/lib/types/api/links.ts deleted file mode 100644 index 81cde053..00000000 --- a/lib/types/api/links.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { z } from "zod"; - -export const ZBookmarkedLink = z.object({ - id: z.string(), - url: z.string().url(), - createdAt: z.coerce.date(), - - details: z.object({ - title: z.string(), - description: z.string(), - imageUrl: z.string().url(), - }).nullish(), - -}); -export type ZBookmarkedLink = z.infer; - - -// POST /v1/links -export const ZNewBookmarkedLinkRequest = ZBookmarkedLink.pick({ url: true }); - - -// GET /v1/links -export const ZGetLinksResponse = z.object({ - links: z.array(ZBookmarkedLink), -}); -export type ZGetLinksResponse = z.infer; diff --git a/lib/types/next-auth.d.ts b/lib/types/next-auth.d.ts deleted file mode 100644 index bdd3bd03..00000000 --- a/lib/types/next-auth.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import NextAuth, { DefaultSession } from "next-auth" - -declare module "next-auth" { - /** - * Returned by `useSession`, `getSession` and received as a prop on the `SessionProvider` React Context - */ - interface Session { - user: { - id: string; - } & DefaultSession["user"]; - } -} -- cgit v1.2.3-70-g09d2