Open source Loom alternative. Beautiful, shareable screen recordings.
Rust appcapcossloommacnextjsnextjs15open-sourceossreactrecordrustscreen-capturescreen-recorderscreenshotsolidjstauritauri-apptypescriptvite
Feature: notifications (#833)
Ameer Al Ashhabf8e9406d2ba7
diff --git a/apps/desktop/package.json b/apps/desktop/package.jsonindex c34d7c035..625c6cab0 100644--- a/apps/desktop/package.json+++ b/apps/desktop/package.json@@ -66,7 +66,7 @@"uuid": "^9.0.1","vinxi": "^0.5.6","webcodecs": "^0.1.0",- "zod": "^3.24.2"+ "zod": "^3.25.76"},"devDependencies": {"@fontsource/geist-sans": "^5.0.3",diff --git a/apps/discord-bot/package.json b/apps/discord-bot/package.jsonindex dbb8c6950..96ddf0e7b 100644--- a/apps/discord-bot/package.json+++ b/apps/discord-bot/package.json@@ -22,6 +22,7 @@"jose": "^5.10.0","octokit": "^4.1.2","tweetnacl": "^1.0.3",- "valibot": "1.0.0-rc.1"+ "valibot": "1.0.0-rc.1",+ "zod": "^3"}}diff --git a/apps/storybook/package.json b/apps/storybook/package.jsonindex aa7cbaae0..9c9b11297 100644--- a/apps/storybook/package.json+++ b/apps/storybook/package.json@@ -9,7 +9,8 @@"dependencies": {"@cap/ui-solid": "workspace:*","postcss-pseudo-companion-classes": "^0.1.1",- "solid-js": "^1.9.3"+ "solid-js": "^1.9.3",+ "zod": "^3"},"devDependencies": {"@chromatic-com/storybook": "^1.6.1",diff --git a/apps/tasks/package.json b/apps/tasks/package.jsonindex c0327622f..675ee7c2e 100644--- a/apps/tasks/package.json+++ b/apps/tasks/package.json@@ -27,7 +27,8 @@"helmet": "^7.1.0","morgan": "^1.10.0","ts-node": "^10.9.2",- "typescript": "^5.8.3"+ "typescript": "^5.8.3",+ "zod": "^3"},"devDependencies": {"@typescript-eslint/eslint-plugin": "^7.6.0",diff --git a/apps/web/actions/notifications/mark-all-as-read.ts b/apps/web/actions/notifications/mark-all-as-read.tsnew file mode 100644index 000000000..318d44e30--- /dev/null+++ b/apps/web/actions/notifications/mark-all-as-read.ts@@ -0,0 +1,26 @@+"use server";++import { getCurrentUser } from "@cap/database/auth/session";+import { notifications } from "@cap/database/schema";+import { db } from "@cap/database";+import { eq } from "drizzle-orm";+import { revalidatePath } from "next/cache";++export const markAllAsRead = async () => {+ const currentUser = await getCurrentUser();+ if (!currentUser) {+ throw new Error("User not found");+ }++ try {+ await db()+ .update(notifications)+ .set({ readAt: new Date() })+ .where(eq(notifications.recipientId, currentUser.id));+ } catch (error) {+ console.log(error);+ throw new Error("Error marking notifications as read");+ }++ revalidatePath("/dashboard");+};diff --git a/apps/web/actions/notifications/update-preferences.ts b/apps/web/actions/notifications/update-preferences.tsnew file mode 100644index 000000000..cdd2fb652--- /dev/null+++ b/apps/web/actions/notifications/update-preferences.ts@@ -0,0 +1,38 @@+"use server";++import { getCurrentUser } from "@cap/database/auth/session";+import { db } from "@cap/database";+import { users } from "@cap/database/schema";+import { eq } from "drizzle-orm";+import { revalidatePath } from "next/cache";++export const updatePreferences = async ({+ notifications,+}: {+ notifications: {+ pauseComments: boolean;+ pauseReplies: boolean;+ pauseViews: boolean;+ pauseReactions: boolean;+ };+}) => {+ const currentUser = await getCurrentUser();+ if (!currentUser) {+ throw new Error("User not found");+ }++ try {+ await db()+ .update(users)+ .set({+ preferences: {+ notifications,+ },+ })+ .where(eq(users.id, currentUser.id));+ revalidatePath("/dashboard");+ } catch (error) {+ console.log(error);+ throw new Error("Error updating preferences");+ }+};diff --git a/apps/web/actions/videos/delete-comment.ts b/apps/web/actions/videos/delete-comment.tsindex 5e9e623c4..c62bac4d0 100644--- a/apps/web/actions/videos/delete-comment.ts+++ b/apps/web/actions/videos/delete-comment.ts@@ -1,16 +1,18 @@"use server";import { db } from "@cap/database";-import { comments } from "@cap/database/schema";+import { comments, notifications } from "@cap/database/schema";import { getCurrentUser } from "@cap/database/auth/session";import { revalidatePath } from "next/cache";-import { eq, and } from "drizzle-orm";+import { eq, and, sql } from "drizzle-orm";export async function deleteComment({commentId,+ parentId,videoId,}: {commentId: string;+ parentId?: string;videoId: string;}) {const user = await getCurrentUser();@@ -23,25 +25,60 @@ export async function deleteComment({throw new Error("Comment ID and video ID are required");}- // First, verify the comment exists and belongs to the current user- const existingComment = await db()- .select()- .from(comments)- .where(and(eq(comments.id, commentId), eq(comments.authorId, user.id)))- .limit(1);-- if (existingComment.length === 0) {- throw new Error(- "Comment not found or you don't have permission to delete it"- );- }+ try {+ await db().transaction(async (tx) => {+ // First, verify the comment exists and belongs to the current user+ const [existingComment] = await tx+ .select({ id: comments.id })+ .from(comments)+ .where(and(eq(comments.id, commentId), eq(comments.authorId, user.id)))+ .limit(1);++ if (!existingComment) {+ throw new Error(+ "Comment not found or you don't have permission to delete it"+ );+ }- // Delete the comment- await db()- .delete(comments)- .where(and(eq(comments.id, commentId), eq(comments.authorId, user.id)));+ await tx+ .delete(comments)+ .where(and(eq(comments.id, commentId), eq(comments.authorId, user.id)));- revalidatePath(`/s/${videoId}`);+ // Delete related notifications+ if (parentId) {+ await tx+ .delete(notifications)+ .where(+ and(+ eq(notifications.type, "reply"),+ sql`JSON_EXTRACT(${notifications.data}, '$.comment.id') = ${commentId}`+ )+ );+ } else {+ await tx+ .delete(notifications)+ .where(+ and(+ eq(notifications.type, "comment"),+ sql`JSON_EXTRACT(${notifications.data}, '$.comment.id') = ${commentId}`+ )+ );- return { success: true, commentId };+ await tx+ .delete(notifications)+ .where(+ and(+ eq(notifications.type, "reply"),+ sql`JSON_EXTRACT(${notifications.data}, '$.comment.parentCommentId') = ${commentId}`+ )+ );+ }+ });++ revalidatePath(`/s/${videoId}`);+ return { success: true };+ } catch (error) {+ console.error("Error deleting comment:", error);+ throw error;+ }}diff --git a/apps/web/actions/videos/new-comment.ts b/apps/web/actions/videos/new-comment.tsindex be874e824..0abb976b3 100644--- a/apps/web/actions/videos/new-comment.ts+++ b/apps/web/actions/videos/new-comment.ts@@ -5,6 +5,7 @@ import { comments } from "@cap/database/schema";import { getCurrentUser } from "@cap/database/auth/session";import { revalidatePath } from "next/cache";import { nanoId } from "@cap/database/helpers";+import { createNotification } from "@/lib/Notification";export async function newComment(data: {content: string;@@ -22,6 +23,11 @@ export async function newComment(data: {const videoId = data.videoId;const type = data.type;const parentCommentId = data.parentCommentId;+ const conditionalType = parentCommentId+ ? "reply"+ : type === "emoji"+ ? "reaction"+ : "comment";if (!content || !videoId) {throw new Error("Content and videoId are required");@@ -42,6 +48,17 @@ export async function newComment(data: {await db().insert(comments).values(newComment);+ try {+ await createNotification({+ type: conditionalType,+ videoId,+ authorId: user.id,+ comment: { id, content },+ });+ } catch (error) {+ console.error("Failed to create notification:", error);+ }+// Add author name to the returned dataconst commentWithAuthor = {...newComment,diff --git a/apps/web/app/(org)/dashboard/Contexts.tsx b/apps/web/app/(org)/dashboard/Contexts.tsxindex 07de3e6fe..e4f2b841a 100644--- a/apps/web/app/(org)/dashboard/Contexts.tsx+++ b/apps/web/app/(org)/dashboard/Contexts.tsx@@ -6,7 +6,7 @@ import { createContext, useContext, useEffect, useState } from "react";import { UpgradeModal } from "@/components/UpgradeModal";import { usePathname } from "next/navigation";import { buildEnv } from "@cap/env";-import { Organization, Spaces } from "./dashboard-data";+import { Organization, Spaces, UserPreferences } from "./dashboard-data";type SharedContext = {organizationData: Organization[] | null;@@ -18,6 +18,8 @@ type SharedContext = {user: typeof users.$inferSelect;isSubscribed: boolean;toggleSidebarCollapsed: () => void;+ anyNewNotifications: boolean;+ userPreferences: UserPreferences;sidebarCollapsed: boolean;upgradeModalOpen: boolean;setUpgradeModalOpen: (open: boolean) => void;@@ -32,7 +34,7 @@ const ThemeContext = createContext<{setThemeHandler: (newTheme: ITheme) => void;}>({theme: "light",- setThemeHandler: () => {},+ setThemeHandler: () => { },});export const useTheme = () => useContext(ThemeContext);@@ -46,6 +48,8 @@ export function DashboardContexts({spacesData,user,isSubscribed,+ userPreferences,+ anyNewNotifications,initialTheme,initialSidebarCollapsed,}: {@@ -55,6 +59,8 @@ export function DashboardContexts({spacesData: SharedContext["spacesData"];user: SharedContext["user"];isSubscribed: SharedContext["isSubscribed"];+ userPreferences: SharedContext["userPreferences"];+ anyNewNotifications: boolean;initialTheme: ITheme;initialSidebarCollapsed: boolean;}) {@@ -133,6 +139,8 @@ export function DashboardContexts({organizationData,activeOrganization,spacesData,+ anyNewNotifications,+ userPreferences,userSpaces,sharedSpaces,activeSpace,diff --git a/apps/web/app/(org)/dashboard/_components/DashboardInner.tsx b/apps/web/app/(org)/dashboard/_components/DashboardInner.tsxindex 7ef626c3d..ba4a7b546 100644--- a/apps/web/app/(org)/dashboard/_components/DashboardInner.tsx+++ b/apps/web/app/(org)/dashboard/_components/DashboardInner.tsx@@ -1,5 +1,6 @@"use client";+import Notifications from "@/app/(org)/dashboard/_components/Notifications";import { UpgradeModal } from "@/components/UpgradeModal";import { buildEnv } from "@cap/env";import {@@ -11,15 +12,24 @@ import {PopoverContent,PopoverTrigger,} from "@cap/ui";-import { faMoon, faSun } from "@fortawesome/free-solid-svg-icons";+import { faBell, faMoon, faSun } from "@fortawesome/free-solid-svg-icons";import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import { useClickAway } from "@uidotdev/usehooks";import clsx from "clsx";+import { AnimatePresence } from "framer-motion";import { MoreVertical } from "lucide-react";import { signOut } from "next-auth/react";import Image from "next/image";import Link from "next/link";import { usePathname } from "next/navigation";-import React, { cloneElement, memo, useMemo, useRef, useState } from "react";+import React, {+ cloneElement,+ memo,+ MutableRefObject,+ useMemo,+ useRef,+ useState,+} from "react";import { useDashboardContext, useTheme } from "../Contexts";import { MembersDialog } from "../spaces/[spaceId]/components/MembersDialog";import {@@ -43,7 +53,8 @@ export default function DashboardInner({children: React.ReactNode;}) {const pathname = usePathname();- const { activeOrganization, activeSpace } = useDashboardContext();+ const { activeOrganization, activeSpace, anyNewNotifications } =+ useDashboardContext();const [membersDialogOpen, setMembersDialogOpen] = useState(false);const titles: Record<string, string> = {@@ -57,6 +68,15 @@ export default function DashboardInner({const title = activeSpace ? activeSpace.name : titles[pathname] || "";const { theme, setThemeHandler } = useTheme();+ const [toggleNotifications, setToggleNotifications] = useState(false);+ const bellRef = useRef<HTMLDivElement>(null);+ const notificationsRef: MutableRefObject<HTMLDivElement> = useClickAway(+ (e) => {+ if (bellRef.current && !bellRef.current.contains(e.target as Node)) {+ setToggleNotifications(false);+ }+ }+ );const isSharedCapsPage = pathname === "/dashboard/shared-caps";return (<div className="flex flex-col min-h-screen">@@ -92,6 +112,43 @@ export default function DashboardInner({</div><div className="flex gap-4 items-center">{buildEnv.NEXT_PUBLIC_IS_CAP && <ReferButton />}+ <div+ data-state={toggleNotifications ? "open" : "closed"}+ ref={bellRef}+ onClick={() => {+ setToggleNotifications(!toggleNotifications);+ }}+ onKeyDown={(e) => {+ if (e.key === "Enter" || e.key === " ") {+ e.preventDefault();+ setToggleNotifications(!toggleNotifications);+ }+ }}+ tabIndex={0}+ role="button"+ aria-label={`Notifications${+ anyNewNotifications ? " (new notifications available)" : ""+ }`}+ aria-expanded={toggleNotifications}+ className="hidden relative justify-center data-[state=open]:hover:bg-gray-5 items-center bg-gray-3+ rounded-full transition-colors cursor-pointer lg:flex+ hover:bg-gray-5 data-[state=open]:bg-gray-5+ focus:outline-none+ size-9"+ >+ {anyNewNotifications && (+ <div className="absolute right-0 top-1 z-10">+ <div className="relative">+ <div className="absolute inset-0 w-2 h-2 bg-red-400 rounded-full opacity-75 animate-ping" />+ <div className="relative w-2 h-2 bg-red-400 rounded-full" />+ </div>+ </div>+ )}+ <FontAwesomeIcon className="text-gray-12 size-3.5" icon={faBell} />+ <AnimatePresence>+ {toggleNotifications && <Notifications ref={notificationsRef} />}+ </AnimatePresence>+ </div><divonClick={() => {if (document.startViewTransition) {@@ -306,8 +363,8 @@ const ReferButton = () => {{/* Red notification dot with pulse animation */}<div className="absolute right-0 top-1 z-10"><div className="relative">- <div className="absolute inset-0 w-2 h-2 bg-red-500 rounded-full opacity-75 animate-ping" />- <div className="relative w-2 h-2 bg-red-500 rounded-full" />+ <div className="absolute inset-0 w-2 h-2 bg-red-400 rounded-full opacity-75 animate-ping" />+ <div className="relative w-2 h-2 bg-red-400 rounded-full" /></div></div>diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/Filter.ts b/apps/web/app/(org)/dashboard/_components/Notifications/Filter.tsnew file mode 100644index 000000000..1377cf0cf--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/Filter.ts@@ -0,0 +1,27 @@+import { NotificationType } from "@/lib/Notification";++export type FilterType = "all" | NotificationType;++export const Filters: Array<FilterType> = [+ "all",+ "comment",+ "reply",+ "view",+ "reaction",+];++export const FilterLabels: Record<FilterType, string> = {+ all: "All",+ comment: "Comments",+ reply: "Replies",+ view: "Views",+ reaction: "Reactions",+};++export const matchNotificationFilter = (+ filter: FilterType,+ type: NotificationType+): boolean => {+ if (filter === "all") return true;+ return type === filter;+};diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/FilterTabs.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/FilterTabs.tsxnew file mode 100644index 000000000..d40557887--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/FilterTabs.tsx@@ -0,0 +1,96 @@+import clsx from "clsx";+import { motion } from "framer-motion";+import { useRef, useEffect, useMemo } from "react";+import { NotificationType } from "@/lib/Notification";+import { FilterLabels, Filters, FilterType } from "./Filter";++type FilterTabsProps = {+ activeFilter: FilterType;+ setActiveFilter: (filter: FilterType) => void;+ loading: boolean;+ count?: Record<NotificationType, number>;+};++export const FilterTabs = ({+ activeFilter,+ setActiveFilter,+ loading,+ count,+}: FilterTabsProps) => {+ const scrollContainerRef = useRef<HTMLDivElement>(null);+ const totalCount = useMemo(() => {+ return Object.values(count ?? {}).reduce((acc, val) => acc + val, 0);+ }, [count]);++ useEffect(() => {+ const container = scrollContainerRef.current;+ if (!container) return;++ const handleWheel = (e: WheelEvent) => {+ // Only hijack vertical scroll if not already scrolling horizontally+ if (Math.abs(e.deltaX) > Math.abs(e.deltaY)) return;+ if (!e.ctrlKey) {+ e.preventDefault();+ }+ container.scrollLeft += e.deltaY;+ };++ container.addEventListener("wheel", handleWheel, { passive: false });++ return () => {+ container.removeEventListener("wheel", handleWheel);+ };+ }, []);++ return (+ <div+ ref={scrollContainerRef}+ className="flex isolate overflow-x-auto relative gap-4 items-center px-6 border-r border-b border-l hide-scroll border-gray-3"+ >+ {Filters.map((filter) => (+ <div key={filter} className="relative min-w-fit">+ <div+ onClick={() => setActiveFilter(filter)}+ className="flex relative gap-2 items-center py-4 cursor-pointer group"+ >+ <p+ className={clsx(+ "text-[13px] transition-colors",+ activeFilter === filter+ ? "text-gray-12"+ : "text-gray-10 group-hover:text-gray-11"+ )}+ >+ {FilterLabels[filter]}+ </p>+ <div className="flex justify-center items-center rounded-md size-4 bg-gray-4">+ {loading ? (+ <span className="size-1.5 rounded-full bg-gray-10" />+ ) : (+ <p+ className={clsx(+ "text-[10px] transition-colors",+ activeFilter === filter+ ? "text-gray-12"+ : "text-gray-10 group-hover:text-gray-11"+ )}+ >+ {filter === "all" ? totalCount : count?.[filter] ?? 0}+ </p>+ )}+ </div>+ </div>++ {/* Indicator */}+ {activeFilter === filter && (+ <motion.div+ layoutId="indicator"+ className="absolute right-0 bottom-0 w-full h-px rounded-full bg-gray-12"+ transition={{ ease: "easeOut", duration: 0.2 }}+ />+ )}+ </div>+ ))}+ </div>+ );+};diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/NotificationFooter.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationFooter.tsxnew file mode 100644index 000000000..830a619ed--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationFooter.tsx@@ -0,0 +1,20 @@+import { faArrowDown, faArrowUp } from "@fortawesome/free-solid-svg-icons";+import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import { SettingsDropdown } from "./SettingsDropdown";++export const NotificationFooter = () => {+ return (+ <div className="flex justify-between items-center px-6 py-3 rounded-b-xl border bg-gray-4 border-gray-5">+ <div className="flex gap-2 items-center">+ <p className="text-[13px] text-gray-10">Navigate</p>+ <div className="flex gap-1 justify-center items-center rounded-md size-4 bg-gray-10">+ <FontAwesomeIcon icon={faArrowDown} className="text-gray-2 size-2.5" />+ </div>+ <div className="flex gap-1 justify-center items-center rounded-md size-4 bg-gray-10">+ <FontAwesomeIcon icon={faArrowUp} className="text-gray-2 size-2.5" />+ </div>+ </div>+ <SettingsDropdown />+ </div>+ );+};diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/NotificationHeader.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationHeader.tsxnew file mode 100644index 000000000..ca26cb597--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationHeader.tsx@@ -0,0 +1,45 @@+import { faCheckDouble } from "@fortawesome/free-solid-svg-icons";+import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import { toast } from "sonner";+import clsx from "clsx";+import { markAllAsRead } from "@/actions/notifications/mark-all-as-read";+import { useQueryClient } from "@tanstack/react-query";+import { useState } from "react";++export const NotificationHeader = () => {++ const [loading, setLoading] = useState(false);+ const queryClient = useQueryClient();++ const markAllAsReadHandler = async () => {+ try {+ setLoading(true);+ await markAllAsRead();+ toast.success("Notifications marked as read");+ queryClient.invalidateQueries({+ queryKey: ["notifications"],+ });+ } catch (error) {+ console.error("Error marking notifications as read:", error);+ toast.error("Failed to mark notifications as read");+ } finally {+ setLoading(false);+ }+ }++ return (+ <div className="flex justify-between items-center px-6 py-3 rounded-t-xl border bg-gray-3 border-gray-4">+ <p className="text-md text-gray-12">Notifications</p>+ <div+ onClick={markAllAsReadHandler}+ className={clsx("flex gap-1 items-center transition-opacity duration-200 cursor-pointer hover:opacity-70", loading ? "opacity-50 cursor-not-allowed" : "")}+ >+ <FontAwesomeIcon+ icon={faCheckDouble}+ className="text-blue-9 size-2.5"+ />+ <p className="text-[13px] text-blue-9">Mark all as read</p>+ </div>+ </div>+ );+};diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/NotificationItem.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationItem.tsxnew file mode 100644index 000000000..585a463ca--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/NotificationItem.tsx@@ -0,0 +1,105 @@+import { faComment, faEye, faReply } from "@fortawesome/free-solid-svg-icons";+import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import clsx from "clsx";+import Link from "next/link";+import moment from "moment";+import { NotificationType } from "@/lib/Notification";+import { Notification as APINotification } from "@cap/web-api-contract";++type NotificationItemProps = {+ notification: APINotification;+ className?: string;+};++const descriptionMap: Record<NotificationType, string> = {+ comment: `commented on your video`,+ reply: `replied to your comment`,+ view: `viewed your video`,+ reaction: `reacted to your video`,+ // mention: `mentioned you in a comment`,+};++export const NotificationItem = ({+ notification,+ className,+}: NotificationItemProps) => {+ const link = getLink(notification);++ return (+ <Link+ href={link}+ className={clsx(+ "flex gap-3 p-4 transition-colors cursor-pointer border-gray-3 hover:bg-gray-2",+ className+ )}+ >+ {/* Avatar */}+ <div className="relative flex-shrink-0">+ {notification.author.avatar ? (+ <img+ src={notification.author.avatar}+ alt={notification.author.name}+ className="object-cover rounded-full size-10"+ />+ ) : (+ <div className="flex justify-center items-center text-xl font-medium text-white bg-purple-500 rounded-full size-10">+ {notification.author.name.charAt(0)}+ </div>+ )}+ {notification.readAt === null && (+ <div className="absolute top-0 right-0 size-2.5 rounded-full bg-red-500 border-2 border-gray-1"></div>+ )}+ </div>++ {/* Content */}+ <div className="flex flex-col flex-1 justify-center">+ <div className="flex gap-1 items-center">+ <span className="font-medium text-gray-12 text-[13px]">+ {notification.author.name}+ </span>+ <span className="text-gray-10 text-[13px]">+ {descriptionMap[notification.type]}+ </span>+ </div>++ {notification.type === "comment" ||+ (notification.type === "reply" && (+ <p className="mb-2 text-[13px] italic leading-4 text-gray-11 line-clamp-2">+ {notification.comment.content}+ </p>+ ))}+ <p className="text-xs text-gray-10">+ {moment(notification.createdAt).fromNow()}+ </p>+ </div>++ {/* Icon */}+ <div className="flex flex-shrink-0 items-center mt-1">+ {notification.type === "comment" && (+ <FontAwesomeIcon icon={faComment} className="text-gray-10 size-4" />+ )}+ {notification.type === "reply" && (+ <FontAwesomeIcon icon={faReply} className="text-gray-10 size-4" />+ )}+ {notification.type === "view" && (+ <FontAwesomeIcon icon={faEye} className="text-gray-10 size-4" />+ )}+ {notification.type === "reaction" && (+ <span className="text-xl">{notification.comment.content}</span>+ )}+ </div>+ </Link>+ );+};++function getLink(notification: APINotification) {+ switch (notification.type) {+ case "comment":+ case "reply":+ case "reaction":+ // case "mention":+ return `/s/${notification.videoId}/?comment=${notification.comment.id}`;+ default:+ return `/s/${notification.videoId}`;+ }+}diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsxnew file mode 100644index 000000000..a9fe9524f--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsx@@ -0,0 +1,151 @@+import {+ faArrowUp,+ faBellSlash,+ faCheck,+ faCog,+ faComment,+ faEye,+ faReply,+ faThumbsUp,+ IconDefinition,+} from "@fortawesome/free-solid-svg-icons";+import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import { Menu, Transition } from "@headlessui/react";+import clsx from "clsx";+import { Fragment, useState } from "react";+import { updatePreferences } from "@/actions/notifications/update-preferences";+import { toast } from "sonner";+import { useDashboardContext } from "../../Contexts";++type NotificationOption = {+ icon: IconDefinition;+ label: string;+ value: "pauseComments" | "pauseViews" | "pauseReactions" | "pauseReplies";+};++const notificationOptions: NotificationOption[] = [+ { icon: faComment, label: "Comments", value: "pauseComments" },+ { icon: faReply, label: "Replies", value: "pauseReplies" },+ { icon: faEye, label: "Views", value: "pauseViews" },+ { icon: faThumbsUp, label: "Reactions", value: "pauseReactions" },+];++export const SettingsDropdown = () => {+ const [showPauseSubmenu, setShowPauseSubmenu] = useState(false);+ const { userPreferences } = useDashboardContext();++ const updateNotificationPreferences = async (option: NotificationOption) => {+ try {+ const currentPrefs = userPreferences?.notifications ?? {+ pauseComments: false,+ pauseReplies: false,+ pauseViews: false,+ pauseReactions: false,+ };++ await updatePreferences({+ notifications: {+ ...currentPrefs,+ [option.value]: !(currentPrefs[option.value] ?? false),+ },+ });++ toast.success(+ `Notifications from ${option.label} have been ${+ !(currentPrefs[option.value] ?? false) ? "paused" : "unpaused"+ }`+ );+ } catch (error) {+ console.error("Failed to update preferences:", error);+ toast.error("Failed to update notification preferences");+ }+ };++ return (+ <Menu as="div" className="relative">+ <Menu.Button className="flex gap-1 items-center transition-opacity duration-200 cursor-pointer hover:opacity-70">+ <FontAwesomeIcon icon={faCog} className="text-gray-10 size-3" />+ <p className="text-[13px] text-gray-10">Settings</p>+ </Menu.Button>++ <Transition+ as={Fragment}+ enter="transition ease-out duration-200"+ enterFrom="opacity-0 scale-95"+ enterTo="opacity-100 scale-100"+ leave="transition ease-in duration-150"+ leaveFrom="opacity-100 scale-100"+ leaveTo="opacity-0 scale-95"+ >+ <Menu.Items className="absolute right-0 top-4 mb-2 min-w-[200px] bg-gray-2 rounded-lg shadow-lg border border-gray-3 p-1.5 z-50 focus:outline-none">+ <div className="relative">+ <Menu.Item>+ {({ active }) => (+ <div+ className={clsx(+ "flex flex-1 items-center group justify-between px-2 py-1 min-w-fit text-[13px] text-gray-11 rounded-lg cursor-pointer outline-none",+ active || showPauseSubmenu ? "bg-gray-3" : ""+ )}+ onMouseEnter={() => setShowPauseSubmenu(true)}+ onMouseLeave={() => setShowPauseSubmenu(false)}+ >+ <div className="flex gap-2 items-center">+ <FontAwesomeIcon+ icon={faBellSlash}+ className="text-gray-10 text-[13px] size-3.5 transition-colors group-hover:text-gray-12"+ />+ <p className="text-[13px] transition-colors group-hover:text-gray-12">+ Pause notifications+ </p>+ </div>+ <FontAwesomeIcon+ icon={faArrowUp}+ className="text-gray-10 size-2.5 rotate-90 transition-colors group-hover:text-gray-12"+ />+ </div>+ )}+ </Menu.Item>++ {/* Submenu */}+ {showPauseSubmenu && (+ <div+ className="absolute top-0 left-full z-50 p-2 -ml-1 rounded-lg border shadow-lg min-w-[150px] bg-gray-2 border-gray-3"+ onMouseEnter={() => setShowPauseSubmenu(true)}+ onMouseLeave={() => setShowPauseSubmenu(false)}+ >+ {notificationOptions.map((option, index) => (+ <div+ key={index}+ className="flex w-full items-center justify-between gap-2 px-2 py-1 text-[13px] text-gray-11 rounded-lg group hover:bg-gray-3 cursor-pointer outline-none"+ onClick={async () =>+ await updateNotificationPreferences(option)+ }+ >+ <div className="flex gap-1.5 items-center">+ <FontAwesomeIcon+ icon={option.icon}+ className="text-gray-10 size-3.5 transition-colors group-hover:text-gray-12"+ />+ <p className="text-[13px] transition-colors group-hover:text-gray-12">+ {option.label}+ </p>+ </div>++ {userPreferences?.notifications[option.value] && (+ <FontAwesomeIcon+ icon={faCheck}+ className="text-gray-10 size-2.5 transition-colors group-hover:text-gray-12"+ />+ )}+ </div>+ ))}+ </div>+ )}+ </div>+ </Menu.Items>+ </Transition>+ </Menu>+ );+};++export default SettingsDropdown;diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/Skeleton.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/Skeleton.tsxnew file mode 100644index 000000000..394150b5b--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/Skeleton.tsx@@ -0,0 +1,70 @@+import { SkeletonPage } from "@cap/ui";+import clsx from "clsx";++export const NotificationItemSkeleton = ({+ className,+}: {+ className?: string;+}) => {+ return (+ <SkeletonPage+ customSkeleton={(Skeleton) => (+ <div className={clsx("flex gap-3 p-4", className)}>+ {/* Avatar Skeleton */}+ <div className="flex-shrink-0">+ <Skeleton+ baseColor="var(--gray-4)"+ highlightColor="var(--gray-5)"+ className="!size-10 !rounded-full"+ />+ </div>++ {/* Content Skeleton */}+ <div className="flex-1 space-y-2">+ <div className="flex gap-2 items-center">+ <Skeleton+ baseColor="var(--gray-4)"+ highlightColor="var(--gray-5)"+ className="!h-4 !w-24"+ />+ <Skeleton+ baseColor="var(--gray-4)"+ highlightColor="var(--gray-5)"+ className="!h-3 !w-32"+ />+ </div>+ <Skeleton+ baseColor="var(--gray-4)"+ highlightColor="var(--gray-5)"+ className="!h-3 !w-48"+ />+ </div>++ {/* Icon Skeleton */}+ <div className="flex-shrink-0 self-start">+ <Skeleton+ baseColor="var(--gray-4)"+ highlightColor="var(--gray-5)"+ className="!size-4 !rounded"+ />+ </div>+ </div>+ )}+ />+ );+};++export const NotificationsSkeleton = ({ count = 5 }: { count?: number }) => {+ return (+ <div>+ {Array.from({ length: count }).map((_, i) => (+ <NotificationItemSkeleton+ key={i}+ className={clsx(i !== count - 1 && "border-b")}+ />+ ))}+ </div>+ );+};++export default NotificationsSkeleton;diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/index.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/index.tsxnew file mode 100644index 000000000..faaca4509--- /dev/null+++ b/apps/web/app/(org)/dashboard/_components/Notifications/index.tsx@@ -0,0 +1,139 @@+"use client";++import clsx from "clsx";+import { motion, MotionProps } from "framer-motion";+import { forwardRef, useEffect, useRef, useMemo, useState } from "react";+import { FilterTabs } from "./FilterTabs";+import { NotificationFooter } from "./NotificationFooter";+import { NotificationHeader } from "./NotificationHeader";+import { NotificationItem } from "./NotificationItem";+import { useQuery } from "@tanstack/react-query";+import { toast } from "sonner";+import { NotificationsSkeleton } from "./Skeleton";+import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";+import { faBellSlash } from "@fortawesome/free-solid-svg-icons";+import { useDashboardContext } from "@/app/(org)/dashboard/Contexts";+import { useApiClient } from "@/utils/web-api";+import { FilterLabels, FilterType, matchNotificationFilter } from "./Filter";++type NotificationsProps = MotionProps & React.HTMLAttributes<HTMLDivElement>;++const Notifications = forwardRef<HTMLDivElement, NotificationsProps>(+ (props, ref) => {+ const { className } = props;+ const { activeOrganization } = useDashboardContext();+ const [activeFilter, setActiveFilter] = useState<FilterType>("all");+ const scrollRef = useRef<HTMLDivElement>(null);+ const api = useApiClient();++ const notifications = useQuery({+ queryKey: ["notifications", activeOrganization?.organization.id],+ queryFn: async () => {+ const resp = await api.notifications.get();+ if (resp.status !== 200) {+ toast.error("Failed to fetch notifications");+ return { notifications: [], count: {} };+ }++ return resp.body;+ },+ refetchOnWindowFocus: false,+ });++ const filteredNotifications = useMemo(+ () =>+ notifications.data?.notifications.filter((notification) =>+ matchNotificationFilter(activeFilter, notification.type)+ ),+ [notifications.data, activeFilter]+ );++ const isNotificationTabEmpty = useMemo(() => {+ return filteredNotifications?.length === 0;+ }, [filteredNotifications]);++ useEffect(() => {+ if (!scrollRef.current) return;+ const handleKeyDown = (e: KeyboardEvent) => {+ const target = e.target as HTMLElement;+ // Ignore typing/navigation inside inputs/editable fields+ if (target.closest("input, textarea, [contenteditable='true']")) return;+ // Only handle when event originates within the panel's scroll area+ if (!scrollRef.current?.contains(target)) return;+ if (e.key === "ArrowUp") {+ e.preventDefault();+ scrollRef.current?.scrollBy({ top: -100, behavior: "smooth" });+ } else if (e.key === "ArrowDown") {+ e.preventDefault();+ scrollRef.current?.scrollBy({ top: 100, behavior: "smooth" });+ }+ };+ document.addEventListener("keydown", handleKeyDown);+ return () => {+ document.removeEventListener("keydown", handleKeyDown);+ };+ }, []);++ return (+ <motion.div+ ref={ref}+ initial={{ opacity: 0, y: 4, scale: 0.98 }}+ animate={{ opacity: 1, y: 0, scale: 1 }}+ exit={{ opacity: 0, y: 4, scale: 0.98 }}+ transition={{ ease: "easeOut", duration: 0.2 }}+ onClick={(e) => e.stopPropagation()}+ className={clsx(+ "flex absolute right-0 top-12 flex-col rounded-xl cursor-default w-[400px] h-[450px] bg-gray-1 origin-top-right",+ className+ )}+ {...props}+ >+ <NotificationHeader />+ <FilterTabs+ loading={notifications.isPending}+ count={notifications.data?.count}+ activeFilter={activeFilter}+ setActiveFilter={setActiveFilter}+ />+ <div+ ref={scrollRef}+ className="isolate flex-1 h-full custom-scroll border-x border-gray-3 divide-y divide-gray-3 flex flex-col"+ >+ {notifications.isPending ? (+ <NotificationsSkeleton />+ ) : isNotificationTabEmpty ? (+ <div className="flex flex-col gap-3 justify-center items-center h-full">+ <FontAwesomeIcon+ icon={faBellSlash}+ className="text-gray-10 size-10"+ />+ <p className="text-gray-10 text-[13px]">+ No notifications{" "}+ {activeFilter !== "all" && (+ <>+ for{" "}+ <span className="font-medium text-gray-11">+ {FilterLabels[activeFilter]}+ </span>+ </>+ )}+ </p>+ </div>+ ) : (+ filteredNotifications?.map((notification) => (+ <NotificationItem+ key={notification.id}+ notification={notification}+ />+ ))+ )}+ <div className="flex-1 border-t border-gray-3" />+ </div>++ <NotificationFooter />+ </motion.div>+ );+ }+);++export default Notifications;diff --git a/apps/web/app/(org)/dashboard/dashboard-data.ts b/apps/web/app/(org)/dashboard/dashboard-data.tsindex 1bc1c59ae..4d9bbeb22 100644--- a/apps/web/app/(org)/dashboard/dashboard-data.ts+++ b/apps/web/app/(org)/dashboard/dashboard-data.ts@@ -8,8 +8,9 @@ import {spaces,sharedVideos,spaceMembers,+ notifications,} from "@cap/database/schema";-import { and, count, eq, inArray, or, sql } from "drizzle-orm";+import { and, count, eq, inArray, isNull, or, sql } from "drizzle-orm";export type Organization = {organization: typeof organizations.$inferSelect;@@ -32,6 +33,8 @@ export type Spaces = Omit<videoCount: number;};+export type UserPreferences = (typeof users.$inferSelect)["preferences"];+export async function getDashboardData(user: typeof userSelectProps) {try {const organizationsWithMembers = await db()@@ -73,6 +76,7 @@ export async function getDashboardData(user: typeof userSelectProps) {.where(inArray(organizationInvites.organizationId, organizationIds));}+ let anyNewNotifications = false;let spacesData: Spaces[] = [];// Find active organization ID@@ -87,6 +91,20 @@ export async function getDashboardData(user: typeof userSelectProps) {// Only fetch spaces for the active organizationif (activeOrganizationId) {+ const [notification] = await db()+ .select({ id: notifications.id })+ .from(notifications)+ .where(+ and(+ eq(notifications.recipientId, user.id),+ eq(notifications.orgId, activeOrganizationId),+ isNull(notifications.readAt)+ )+ )+ .limit(1);++ anyNewNotifications = !!notification;+spacesData = await db().select({id: spaces.id,@@ -165,6 +183,14 @@ export async function getDashboardData(user: typeof userSelectProps) {}}+ const [userPreferences] = await db()+ .select({+ preferences: users.preferences,+ })+ .from(users)+ .where(eq(users.id, user.id))+ .limit(1);+const organizationSelect: Organization[] = await Promise.all(organizationsWithMembers.reduce((acc: (typeof organizations.$inferSelect)[], row) => {@@ -236,12 +262,16 @@ export async function getDashboardData(user: typeof userSelectProps) {return {organizationSelect,spacesData,+ anyNewNotifications,+ userPreferences,};} catch (error) {console.error("Failed to fetch dashboard data", error);return {organizationSelect: [],spacesData: [],+ anyNewNotifications: false,+ userPreferences: null,};}}diff --git a/apps/web/app/(org)/dashboard/layout.tsx b/apps/web/app/(org)/dashboard/layout.tsxindex 64c97a0da..65b8c48ce 100644--- a/apps/web/app/(org)/dashboard/layout.tsx+++ b/apps/web/app/(org)/dashboard/layout.tsx@@ -2,14 +2,14 @@ import { getCurrentUser } from "@cap/database/auth/session";import { cookies } from "next/headers";import { redirect } from "next/navigation";-import { getDashboardData, Organization, Spaces } from "./dashboard-data";+import { getDashboardData, Organization, Spaces, UserPreferences } from "./dashboard-data";import DashboardInner from "./_components/DashboardInner";import { DashboardContexts } from "./Contexts";import DesktopNav from "./_components/Navbar/Desktop";import MobileNav from "./_components/Navbar/Mobile";+import { UploadingProvider } from "./caps/UploadingContext";export const dynamic = "force-dynamic";-import { UploadingProvider } from "./caps/UploadingContext";export default async function DashboardLayout({children,@@ -28,14 +28,20 @@ export default async function DashboardLayout({let organizationSelect: Organization[] = [];let spacesData: Spaces[] = [];+ let anyNewNotifications = false;+ let userPreferences: UserPreferences;try {const dashboardData = await getDashboardData(user);organizationSelect = dashboardData.organizationSelect;+ userPreferences = dashboardData.userPreferences?.preferences || null;spacesData = dashboardData.spacesData;+ anyNewNotifications = dashboardData.anyNewNotifications;} catch (error) {console.error("Failed to load dashboard data", error);organizationSelect = [];spacesData = [];+ anyNewNotifications = false;+ userPreferences = null;}let activeOrganization = organizationSelect.find(@@ -64,6 +70,8 @@ export default async function DashboardLayout({isSubscribed={isSubscribed}initialTheme={theme as "light" | "dark"}initialSidebarCollapsed={sidebar === "true"}+ anyNewNotifications={anyNewNotifications}+ userPreferences={userPreferences}><div className="grid grid-cols-[auto,1fr] overflow-y-auto bg-gray-1 grid-rows-[auto,1fr] h-dvh min-h-dvh"><aside className="z-10 col-span-1 row-span-2">diff --git a/apps/web/app/api/notifications/preferences/route.ts b/apps/web/app/api/notifications/preferences/route.tsnew file mode 100644index 000000000..37de60224--- /dev/null+++ b/apps/web/app/api/notifications/preferences/route.ts@@ -0,0 +1,50 @@+import { getCurrentUser } from "@cap/database/auth/session";+import { db } from "@cap/database";+import { users } from "@cap/database/schema";+import { eq } from "drizzle-orm";+import { NextResponse } from "next/server";+import { z } from "zod";++const PreferencesSchema = z.object({+ notifications: z.object({+ pauseComments: z.boolean(),+ pauseReplies: z.boolean(),+ pauseViews: z.boolean(),+ pauseReactions: z.boolean(),+ }),+});++export async function GET() {+ const currentUser = await getCurrentUser();+ if (!currentUser) {+ return NextResponse.json(+ { error: "Unauthorized" },+ {+ status: 401,+ }+ );+ }+ try {+ const [userPreferences] = await db()+ .select({+ preferences: users.preferences,+ })+ .from(users)+ .where(eq(users.id, currentUser.id))+ .limit(1);++ const parsedData = PreferencesSchema.parse(userPreferences?.preferences);++ return NextResponse.json(parsedData.notifications, {+ status: 200,+ });+ } catch (error) {+ console.error("Error fetching user preferences:", error);+ return NextResponse.json(+ { error: "Failed to fetch user preferences" },+ {+ status: 500,+ }+ );+ }+}diff --git a/apps/web/app/api/notifications/route.ts b/apps/web/app/api/notifications/route.tsnew file mode 100644index 000000000..fd8541578--- /dev/null+++ b/apps/web/app/api/notifications/route.ts@@ -0,0 +1,129 @@+import { getCurrentUser } from "@cap/database/auth/session";+import { notifications, users } from "@cap/database/schema";+import { db } from "@cap/database";+import { and, ColumnBaseConfig, desc, eq, isNull, sql } from "drizzle-orm";+import { z } from "zod";+import { NextResponse } from "next/server";+import { Notification as APINotification } from "@cap/web-api-contract";+import { AvcProfileInfo } from "node_modules/@remotion/media-parser/dist/containers/avc/parse-avc";+import { NotificationType } from "@/lib/Notification";+import { MySqlColumn } from "drizzle-orm/mysql-core";+import { jsonExtractString } from "@/utils/sql";++const notificationDataSchema = z.object({+ authorId: z.string(),+ content: z.string().optional(),+ videoId: z.string(),+});++type NotificationsKeys = (typeof notifications.$inferSelect)["type"];+type NotificationsKeysWithReplies =+ | Exclude<`${NotificationsKeys}s`, "replys">+ | "replies";++export async function GET() {+ const currentUser = await getCurrentUser();+ if (!currentUser) {+ return new Response(JSON.stringify({ error: "Unauthorized" }), {+ status: 401,+ });+ }++ try {+ const notificationsWithAuthors = await db()+ .select({+ notification: {+ id: notifications.id,+ type: notifications.type,+ data: notifications.data,+ readAt: notifications.readAt,+ createdAt: notifications.createdAt,+ },+ author: {+ id: users.id,+ name: users.name,+ avatar: users.image,+ },+ })+ .from(notifications)+ .leftJoin(+ users,+ and(eq(jsonExtractString(notifications.data, "authorId"), users.id))+ )+ .where(+ and(+ eq(notifications.recipientId, currentUser.id),+ eq(notifications.orgId, currentUser.activeOrganizationId)+ )+ )+ .orderBy(+ desc(isNull(notifications.readAt)),+ desc(notifications.createdAt)+ );++ const countResults = await db()+ .select({+ type: notifications.type,+ count: sql`COUNT(*)`.as("count"),+ })+ .from(notifications)+ .where(+ and(+ eq(notifications.recipientId, currentUser.id),+ eq(notifications.orgId, currentUser.activeOrganizationId)+ )+ )+ .groupBy(notifications.type);++ const formattedCountResults: Record<NotificationType, number> = {+ view: 0,+ comment: 0,+ reply: 0,+ reaction: 0,+ // recordings: 0,+ // mentions: 0,+ };++ countResults.forEach(({ type, count }) => {+ formattedCountResults[type] = Number(count);+ });++ const formattedNotifications = notificationsWithAuthors+ .map(({ notification, author }) => {+ try {+ // all notifications currently require an author+ if (!author) return;++ return APINotification.parse({+ id: notification.id,+ type: notification.type,+ readAt: notification.readAt,+ videoId: notification.data.videoId,+ createdAt: notification.createdAt,+ data: notification.data,+ comment: notification.data.comment,+ author: {+ id: author.id,+ name: author.name ?? "Unknown",+ avatar: author.avatar,+ },+ });+ } catch (error) {+ console.error("Invalid notification data:", error);+ return null;+ }+ })+ .filter(Boolean);++ return NextResponse.json({+ notifications: formattedNotifications,+ count: formattedCountResults,+ });+ } catch (error) {+ console.error("Error fetching notifications:", error);+ return NextResponse.json({+ status: 500,+ error: "Failed to fetch notifications",+ });+ }+}diff --git a/apps/web/app/globals.css b/apps/web/app/globals.cssindex 88f28d334..4db92a329 100644--- a/apps/web/app/globals.css+++ b/apps/web/app/globals.css@@ -549,9 +549,13 @@ slot:not(.dashboard-layout slot) {@apply bg-gray-50;}+.hide-scroll::-webkit-scrollbar {+ display: none;+}+/* Custom scrollbar */.custom-scroll {- overflow-y: scroll;+ overflow-y: auto;}.custom-scroll::-webkit-scrollbar {diff --git a/apps/web/app/s/[videoId]/_components/Toolbar.tsx b/apps/web/app/s/[videoId]/_components/Toolbar.tsxindex f056cc182..3865e82e2 100644--- a/apps/web/app/s/[videoId]/_components/Toolbar.tsx+++ b/apps/web/app/s/[videoId]/_components/Toolbar.tsx@@ -7,7 +7,7 @@ import { AnimatePresence, motion } from "motion/react";import { CommentType } from "../Share";import { newComment } from "@/actions/videos/new-comment";-const MotionButton = motion(Button);+const MotionButton = motion.create(Button);// million-ignoreinterface ToolbarProps {diff --git a/apps/web/app/s/[videoId]/_components/tabs/Activity/Comment.tsx b/apps/web/app/s/[videoId]/_components/tabs/Activity/Comment.tsxindex 989436859..67212ec2d 100644--- a/apps/web/app/s/[videoId]/_components/tabs/Activity/Comment.tsx+++ b/apps/web/app/s/[videoId]/_components/tabs/Activity/Comment.tsx@@ -1,6 +1,5 @@import { userSelectProps } from "@cap/database/auth/session";import { Avatar, Button } from "@cap/ui";-import { motion } from "framer-motion";import React from "react";import { Tooltip } from "@/components/Tooltip";@@ -10,6 +9,8 @@ import { faReply, faTrash } from "@fortawesome/free-solid-svg-icons";import { CommentType } from "../../../Share";import CommentInput from "./CommentInput";import { formatTimeAgo, formatTimestamp } from "./utils";+import { useSearchParams } from "next/navigation";+import { motion } from "framer-motion";const Comment: React.FC<{comment: CommentType;@@ -18,7 +19,7 @@ const Comment: React.FC<{replyingToId: string | null;handleReply: (content: string) => void;onCancelReply: () => void;- onDelete: (commentId: string) => void;+ onDelete: (commentId: string, parentId?: string) => void;user: typeof userSelectProps | null;level?: number;onSeek?: (time: number) => void;@@ -36,6 +37,7 @@ const Comment: React.FC<{}) => {const isReplying = replyingToId === comment.id;const isOwnComment = user?.id === comment.authorId;+ const commentParams = useSearchParams().get("comment");const nestedReplies =level === 0? replies.filter((reply) => {@@ -49,7 +51,7 @@ const Comment: React.FC<{const handleDelete = () => {if (window.confirm("Are you sure you want to delete this comment?")) {- onDelete(comment.id);+ onDelete(comment.id, comment.parentCommentId);}};@@ -57,13 +59,24 @@ const Comment: React.FC<{const commentDate = new Date(comment.createdAt);return (- <motion.div+ <div+ id={`comment-${comment.id}`}key={`comment-${comment.id}`}className={clsx(`space-y-3`, level > 0 ? "ml-8 border-l-2 border-gray-100 pl-4" : "", comment.sending ? "opacity-20" : "opacity-100")}><div className="flex items-start space-x-2.5"><Avatar className="size-6" letterClass="text-sm" name={comment.authorName} />- <div className="flex-1 p-3 rounded-xl border bg-gray-2 border-gray-3">+ <motion.div+ viewport={{+ once: true,+ }}+ whileInView={{+ scale: commentParams === comment.id ? [1, 1.08, 1] : 1,+ borderColor: commentParams === comment.id ? ["#EEEEEE", "#1696e0"] : "#EEEEEE",+ backgroundColor: commentParams === comment.id ? ["#F9F9F9", "#EDF6FF"] : " #F9F9F9",+ }}+ transition={{ duration: 0.75, ease: "easeInOut", delay: 0.15 }}+ className={"flex-1 p-3 rounded-xl border border-gray-3 bg-gray-2"}><div className="flex items-center space-x-2"><p className="text-base font-medium text-gray-12">{comment.authorName || "Anonymous"}@@ -109,7 +122,7 @@ const Comment: React.FC<{</Tooltip>)}</div>- </div>+ </motion.div></div>{isReplying && canReply && (@@ -144,7 +157,7 @@ const Comment: React.FC<{))}</div>)}- </motion.div>+ </div>);};diff --git a/apps/web/app/s/[videoId]/_components/tabs/Activity/Comments.tsx b/apps/web/app/s/[videoId]/_components/tabs/Activity/Comments.tsxindex 65764b335..2dafb1a9a 100644--- a/apps/web/app/s/[videoId]/_components/tabs/Activity/Comments.tsx+++ b/apps/web/app/s/[videoId]/_components/tabs/Activity/Comments.tsx@@ -2,7 +2,6 @@ import { newComment } from "@/actions/videos/new-comment";import { deleteComment } from "@/actions/videos/delete-comment";import { userSelectProps } from "@cap/database/auth/session";import { Button } from "@cap/ui";-import { AnimatePresence } from "framer-motion";import React, {ComponentProps,PropsWithChildren, useEffect, useRef,@@ -13,6 +12,7 @@ import Comment from "./Comment";import { CommentType } from "../../../Share";import CommentInput from "./CommentInput";import EmptyState from "./EmptyState";+import { useSearchParams } from "next/navigation";export const Comments = Object.assign(forwardRef<{ scrollToBottom: () => void }, {@@ -28,6 +28,7 @@ export const Comments = Object.assign((props, ref) => {const { optimisticComments, setOptimisticComments, setComments, handleCommentSuccess } = props;+ const commentParams = useSearchParams().get("comment");const { user } = props;const [replyingTo, setReplyingTo] = useState<string | null>(null);@@ -35,6 +36,7 @@ export const Comments = Object.assign(const commentsContainerRef = useRef<HTMLDivElement>(null);useEffect(() => {+ if (commentParams) return;if (commentsContainerRef.current) {commentsContainerRef.current.scrollTop =commentsContainerRef.current.scrollHeight;@@ -140,10 +142,11 @@ export const Comments = Object.assign(setReplyingTo(null);};- const handleDeleteComment = async (commentId: string) => {+ const handleDeleteComment = async (commentId: string, parentId?: string) => {try {await deleteComment({commentId,+ parentId,videoId: props.videoId,});setComments((prev) => prev.filter((c) => c.id !== commentId));@@ -163,38 +166,27 @@ export const Comments = Object.assign(<EmptyState />) : (<div className="p-4 space-y-6">- <AnimatePresence>- {rootComments- .sort(- (a, b) =>- new Date(a.createdAt).getTime() -- new Date(b.createdAt).getTime()- )- .map((comment) => (- <Comment- key={comment.id}- comment={comment}- replies={optimisticComments.sort(- (a, b) =>- new Date(a.createdAt).getTime() -- new Date(b.createdAt).getTime()- )}- onReply={(id) => {- if (!user) {- props.setShowAuthOverlay(true);- } else {- setReplyingTo(id);- }- }}- replyingToId={replyingTo}- handleReply={handleReply}- onCancelReply={handleCancelReply}- onDelete={handleDeleteComment}- user={user}- onSeek={props.onSeek}- />- ))}- </AnimatePresence>+ {rootComments+ .map((comment) => (+ <Comment+ key={comment.id}+ comment={comment}+ replies={optimisticComments}+ onReply={(id) => {+ if (!user) {+ props.setShowAuthOverlay(true);+ } else {+ setReplyingTo(id);+ }+ }}+ replyingToId={replyingTo}+ handleReply={handleReply}+ onCancelReply={handleCancelReply}+ onDelete={handleDeleteComment}+ user={user}+ onSeek={props.onSeek}+ />+ ))}</div>)}</Comments.Shell>diff --git a/apps/web/app/s/[videoId]/page.tsx b/apps/web/app/s/[videoId]/page.tsxindex 66251186c..69bc51147 100644--- a/apps/web/app/s/[videoId]/page.tsx+++ b/apps/web/app/s/[videoId]/page.tsx@@ -1,5 +1,5 @@import { db } from "@cap/database";-import { eq, InferSelectModel } from "drizzle-orm";+import { eq, InferSelectModel, sql, desc } from "drizzle-orm";import { Logo } from "@cap/ui";import {@@ -28,6 +28,7 @@ import { Share } from "./Share";import { PasswordOverlay } from "./_components/PasswordOverlay";import { ShareHeader } from "./_components/ShareHeader";import { userHasAccessToVideo } from "@/utils/auth";+import { createNotification } from "@/lib/Notification";import { getDashboardData } from "@/app/(org)/dashboard/dashboard-data";export const dynamic = "auto";@@ -69,7 +70,7 @@ async function getSharedSpacesForVideo(videoId: string) {}> = [];// Add space-level sharing- spaceSharing.forEach(space => {+ spaceSharing.forEach((space) => {sharedSpaces.push({id: space.id,name: space.name,@@ -79,7 +80,7 @@ async function getSharedSpacesForVideo(videoId: string) {});// Add organization-level sharing- orgSharing.forEach(org => {+ orgSharing.forEach((org) => {sharedSpaces.push({id: org.id,name: org.name,@@ -93,6 +94,7 @@ async function getSharedSpacesForVideo(videoId: string) {type Props = {params: { [key: string]: string | string[] | undefined };+ searchParams: { [key: string]: string | string[] | undefined };};type CommentWithAuthor = typeof comments.$inferSelect & {@@ -112,6 +114,7 @@ type VideoWithOrganization = typeof videos.$inferSelect & {export async function generateMetadata({ params }: Props): Promise<Metadata> {const videoId = params.videoId as string;+console.log("[generateMetadata] Fetching video metadata for videoId:",videoId@@ -270,10 +273,10 @@ export async function generateMetadata({ params }: Props): Promise<Metadata> {export default async function ShareVideoPage(props: Props) {const params = props.params;+ const searchParams = props.searchParams;const videoId = params.videoId as string;- console.log("[ShareVideoPage] Starting page load for videoId:", videoId);- const userPromise = getCurrentUser();+ const user = await getCurrentUser();const [video] = await db().select({@@ -305,19 +308,28 @@ export default async function ShareVideoPage(props: Props) {.leftJoin(sharedVideos, eq(videos.id, sharedVideos.videoId)).where(eq(videos.id, videoId));+ if (user && video && user.id !== video.ownerId) {+ try {+ await createNotification({ type: "view", videoId, authorId: user.id });+ } catch (error) {+ console.error("Failed to create view notification:", error);+ }+ }+if (!video) {console.log("[ShareVideoPage] No video found for videoId:", videoId);return <p>No video found</p>;}- const userAccess = await userHasAccessToVideo(userPromise, video);+ const userAccess = await userHasAccessToVideo(user, video);if (userAccess === "private") {return (<div className="flex flex-col justify-center items-center p-4 min-h-screen text-center"><h1 className="mb-4 text-2xl font-bold">This video is private</h1><p className="text-gray-400">- If you own this video, please <Link href="/login">sign in</Link> to manage sharing.+ If you own this video, please <Link href="/login">sign in</Link> to+ manage sharing.</p></div>);@@ -330,7 +342,11 @@ export default async function ShareVideoPage(props: Props) {videoId={video.id}/>{userAccess === "has-access" && (- <AuthorizedContent video={video} user={userPromise} />+ <AuthorizedContent+ video={video}+ user={user}+ searchParams={searchParams}+ />)}</div>);@@ -339,15 +355,18 @@ export default async function ShareVideoPage(props: Props) {async function AuthorizedContent({video,user: _user,+ searchParams,}: {- video: InferSelectModel<typeof videos> & {+ video: Omit<InferSelectModel<typeof videos>, "folderId"> & {sharedOrganization: { organizationId: string } | null;};user: MaybePromise<InferSelectModel<typeof users> | null>;+ searchParams: { [key: string]: string | string[] | undefined };}) {const user = await _user;const videoId = video.id;const userId = user?.id;+ const commentId = searchParams.comment as string | undefined;// Fetch spaces data for the sharing dialoglet spacesData = null;@@ -567,33 +586,41 @@ async function AuthorizedContent({const membersListPromise = video.sharedOrganization?.organizationId? db()- .select({ userId: organizationMembers.userId })- .from(organizationMembers)- .where(- eq(- organizationMembers.organizationId,- video.sharedOrganization.organizationId+ .select({ userId: organizationMembers.userId })+ .from(organizationMembers)+ .where(+ eq(+ organizationMembers.organizationId,+ video.sharedOrganization.organizationId+ ))- ): Promise.resolve([]);- const commentsPromise = db()- .select({- id: comments.id,- content: comments.content,- timestamp: comments.timestamp,- type: comments.type,- authorId: comments.authorId,- videoId: comments.videoId,- createdAt: comments.createdAt,- updatedAt: comments.updatedAt,- parentCommentId: comments.parentCommentId,- authorName: users.name,- })- .from(comments)- .leftJoin(users, eq(comments.authorId, users.id))- .where(eq(comments.videoId, videoId))- .execute();+ const commentsPromise = (async () => {+ const allComments = await db()+ .select({+ id: comments.id,+ content: comments.content,+ timestamp: comments.timestamp,+ type: comments.type,+ authorId: comments.authorId,+ videoId: comments.videoId,+ createdAt: comments.createdAt,+ updatedAt: comments.updatedAt,+ parentCommentId: comments.parentCommentId,+ authorName: users.name,+ })+ .from(comments)+ .leftJoin(users, eq(comments.authorId, users.id))+ .where(eq(comments.videoId, videoId))+ .orderBy(+ commentId+ ? sql`CASE WHEN ${comments.id} = ${commentId} THEN 0 ELSE 1 END, ${comments.createdAt} DESC`+ : desc(comments.createdAt)+ );++ return allComments;+ })();const viewsPromise = getVideoAnalytics(videoId).then((v) => v.count);@@ -616,9 +643,9 @@ async function AuthorizedContent({sharedOrganizations: sharedOrganizations,password: null,hasPassword: video.password !== null,+ folderId: null,};-return (<><div className="container flex-1 px-4 py-4 mx-auto">diff --git a/apps/web/components/VideoThumbnail.tsx b/apps/web/components/VideoThumbnail.tsxindex c6186490b..0d2847ead 100644--- a/apps/web/components/VideoThumbnail.tsx+++ b/apps/web/components/VideoThumbnail.tsx@@ -42,9 +42,8 @@ export const VideoThumbnail: React.FC<VideoThumbnailProps> = memo(if (response.ok) {const data = await response.json();// Add cache busting to the thumbnail URL as well- return `${data.screen}${- data.screen.includes("?") ? "&" : "?"- }t=${cacheBuster}`;+ return `${data.screen}${data.screen.includes("?") ? "&" : "?"+ }t=${cacheBuster}`;} else {throw new Error("Failed to fetch pre-signed URLs");}diff --git a/apps/web/global.d.ts b/apps/web/global.d.tsindex 2cd438de1..69ed3dd66 100644--- a/apps/web/global.d.ts+++ b/apps/web/global.d.ts@@ -1 +1,5 @@declare type MaybePromise<T> = T | Promise<T>;++declare type DistributiveOmit<T, K extends keyof any> = T extends any+ ? Omit<T, K>+ : never;diff --git a/apps/web/lib/Notification.ts b/apps/web/lib/Notification.tsnew file mode 100644index 000000000..b0b933f40--- /dev/null+++ b/apps/web/lib/Notification.ts@@ -0,0 +1,141 @@+// Ideally all the Notification-related types would be in @cap/web-domain+// but @cap/web-api-contract is the closest we have right now++import { notifications, videos, users } from "@cap/database/schema";+import { db } from "@cap/database";+import { and, eq, sql } from "drizzle-orm";+import { nanoId } from "@cap/database/helpers";+import { UserPreferences } from "@/app/(org)/dashboard/dashboard-data";+import { revalidatePath } from "next/cache";+import { Notification, NotificationBase } from "@cap/web-api-contract";++export type NotificationType = Notification["type"];++// Notification daata without id, readTime, etc+type NotificationSpecificData = DistributiveOmit<+ Notification,+ keyof NotificationBase+>;++// Replaces author object with authorId since we query for that info.+// If we add more notifications this would probably be better done manually+// Type is weird since we need to operate on each member of the NotificationSpecificData union+type CreateNotificationInput<D = NotificationSpecificData> =+ D extends NotificationSpecificData+ ? D["author"] extends never+ ? D+ : Omit<D, "author"> & { authorId: string }+ : never;++export async function createNotification(+ notification: CreateNotificationInput+) {+ try {+ // First, get the video and owner data+ const [videoResult] = await db()+ .select({+ videoId: videos.id,+ ownerId: users.id,+ activeOrganizationId: users.activeOrganizationId,+ preferences: users.preferences,+ })+ .from(videos)+ .innerJoin(users, eq(users.id, videos.ownerId))+ .where(eq(videos.id, notification.videoId))+ .limit(1);++ if (!videoResult) {+ throw new Error("Video or owner not found");+ }++ // Skip notification if the video owner is the current user+ if (videoResult.ownerId === notification.authorId) {+ return;+ }++ // Check user preferences+ const preferences = videoResult.preferences as UserPreferences;+ if (preferences?.notifications) {+ const notificationPrefs = preferences.notifications;++ const shouldSkipNotification =+ (notification.type === "comment" && notificationPrefs.pauseComments) ||+ (notification.type === "view" && notificationPrefs.pauseViews) ||+ (notification.type === "reply" && notificationPrefs.pauseReplies) ||+ (notification.type === "reaction" && notificationPrefs.pauseReactions);++ if (shouldSkipNotification) {+ return;+ }+ }++ // Check for existing notification to prevent duplicates+ let hasExistingNotification = false;+ if (notification.type === "view") {+ const [existingNotification] = await db()+ .select({ id: notifications.id })+ .from(notifications)+ .where(+ and(+ eq(notifications.type, "view"),+ eq(notifications.recipientId, videoResult.ownerId),+ sql`JSON_EXTRACT(${notifications.data}, '$.videoId') = ${notification.videoId}`,+ sql`JSON_EXTRACT(${notifications.data}, '$.authorId') = ${notification.authorId}`+ )+ )+ .limit(1);++ hasExistingNotification = !!existingNotification;+ } else if (+ notification.type === "comment" ||+ notification.type === "reaction" ||+ notification.type === "reply"+ ) {+ // Check for existing comment notification+ const [existingNotification] = await db()+ .select({ id: notifications.id })+ .from(notifications)+ .where(+ and(+ eq(notifications.type, notification.type),+ eq(notifications.recipientId, videoResult.ownerId),+ sql`JSON_EXTRACT(${notifications.data}, '$.comment.id') = ${notification.comment.id}`+ )+ )+ .limit(1);++ hasExistingNotification = !!existingNotification;+ }++ if (hasExistingNotification) {+ return;+ }++ const notificationId = nanoId();+ const now = new Date();++ if (!videoResult.activeOrganizationId) {+ console.warn(+ `User ${videoResult.ownerId} has no active organization, skipping notification`+ );+ return;+ }++ const { type, ...data } = notification;++ await db().insert(notifications).values({+ id: notificationId,+ orgId: videoResult.activeOrganizationId,+ recipientId: videoResult.ownerId,+ type,+ data,+ });++ revalidatePath("/dashboard");++ return { success: true, notificationId };+ } catch (error) {+ console.error("Error creating notification:", error);+ throw error;+ }+}diff --git a/apps/web/package.json b/apps/web/package.jsonindex 8f4321c09..39d7926a9 100644--- a/apps/web/package.json+++ b/apps/web/package.json@@ -103,7 +103,7 @@"tailwind-merge": "^2.6.0","tailwindcss-animate": "^1.0.7","uuid": "^9.0.1",- "zod": "^3.24.4"+ "zod": "^3.25.76"},"devDependencies": {"@smithy/types": "^4.3.1",diff --git a/apps/web/utils/auth.ts b/apps/web/utils/auth.tsindex 61b565b57..25bef1b7b 100644--- a/apps/web/utils/auth.ts+++ b/apps/web/utils/auth.ts@@ -13,7 +13,7 @@ async function verifyPasswordCookie(videoPassword: string) {export async function userHasAccessToVideo(user: MaybePromise<{ id: string } | undefined | null>,- video: InferSelectModel<typeof videos>+ video: Omit<InferSelectModel<typeof videos>, "folderId">): Promise<"has-access" | "private" | "needs-password" | "not-org-email"> {if (video.public && video.password === null) return "has-access";diff --git a/apps/web/utils/organization.ts b/apps/web/utils/organization.tsindex 8ef75b7de..2e0ebaf22 100644--- a/apps/web/utils/organization.ts+++ b/apps/web/utils/organization.ts@@ -9,14 +9,17 @@ export function calculateSeats(organization: {const inviteQuota = organization?.inviteQuota ?? 1;const memberCount = organization?.members?.length ?? 0;const pendingInvitesCount = organization?.invites?.length ?? 0;- const totalUsedSeats = memberCount + pendingInvitesCount;- const remainingSeats = Math.max(0, inviteQuota - totalUsedSeats);-+ const totalUsedSeats = memberCount + pendingInvitesCount;+ const remainingSeats =+ process.env.NODE_ENv === "development"+ ? Number.MAX_SAFE_INTEGER+ : Math.max(0, inviteQuota - totalUsedSeats);+return {inviteQuota,memberCount,pendingInvitesCount,totalUsedSeats,- remainingSeats+ remainingSeats,};-}\ No newline at end of file+}diff --git a/apps/web/utils/sql.ts b/apps/web/utils/sql.tsnew file mode 100644index 000000000..c16ae2bf1--- /dev/null+++ b/apps/web/utils/sql.ts@@ -0,0 +1,13 @@+import { ColumnBaseConfig, sql } from "drizzle-orm";+import { MySqlColumn } from "drizzle-orm/mysql-core";++export function jsonExtractString<+ C extends ColumnBaseConfig<"json", "MySqlJson"> & { data: T },+ T extends Record<string, any>,+ F extends keyof T+>(column: MySqlColumn<C>, field: F) {+ const jsonParam = `$.${field as string}`;+ return sql<+ string | undefined+ >`JSON_UNQUOTE(JSON_EXTRACT(${column}, ${jsonParam}))`;+}diff --git a/apps/web/utils/web-api.ts b/apps/web/utils/web-api.tsindex d3650b1c9..aca399bc7 100644--- a/apps/web/utils/web-api.ts+++ b/apps/web/utils/web-api.ts@@ -8,7 +8,9 @@ export function useApiClient() {const { webUrl } = usePublicEnv();const [client] = useState(() =>initClient(contract, {- baseUrl: typeof window !== "undefined" ? `${webUrl}/api` : "/api",+ baseUrl: typeof window === "undefined"+ ? `${webUrl.replace(/\/+$/, "")}/api`+ : "/api",}));diff --git a/infra/package.json b/infra/package.jsonindex 0d775a85f..e54262df9 100644--- a/infra/package.json+++ b/infra/package.json@@ -8,6 +8,7 @@},"dependencies": {"@pulumi/github": "^6.7.0",- "@pulumiverse/vercel": "^1.14.3"+ "@pulumiverse/vercel": "^1.14.3",+ "zod": "^3"}}diff --git a/packages/config/package.json b/packages/config/package.jsonindex bf2320983..aed0de6d7 100644--- a/packages/config/package.json+++ b/packages/config/package.json@@ -25,6 +25,7 @@"dependencies": {"@vitejs/plugin-react": "^4.0.3","vite": "^6.3.5",- "vite-tsconfig-paths": "^4.2.0"+ "vite-tsconfig-paths": "^4.2.0",+ "zod": "^3"}}diff --git a/packages/database/migrations/meta/0007_snapshot.json b/packages/database/migrations/meta/0007_snapshot.jsonnew file mode 100644index 000000000..e5bcd7047--- /dev/null+++ b/packages/database/migrations/meta/0007_snapshot.json@@ -0,0 +1,1866 @@+{+ "version": "5",+ "dialect": "mysql",+ "id": "ccef8ed8-2472-41a3-bf54-900db6ce8b08",+ "prevId": "140a5aa9-5b37-4435-baeb-5fd016ef5c6e",+ "tables": {+ "accounts": {+ "name": "accounts",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "provider": {+ "name": "provider",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "providerAccountId": {+ "name": "providerAccountId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "access_token": {+ "name": "access_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "expires_in": {+ "name": "expires_in",+ "type": "int",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "id_token": {+ "name": "id_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "refresh_token": {+ "name": "refresh_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "refresh_token_expires_in": {+ "name": "refresh_token_expires_in",+ "type": "int",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "scope": {+ "name": "scope",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "token_type": {+ "name": "token_type",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "tempColumn": {+ "name": "tempColumn",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "provider_account_id_idx": {+ "name": "provider_account_id_idx",+ "columns": [+ "providerAccountId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "accounts_id": {+ "name": "accounts_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "accounts_id_unique": {+ "name": "accounts_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "auth_api_keys": {+ "name": "auth_api_keys",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(36)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "auth_api_keys_id": {+ "name": "auth_api_keys_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "auth_api_keys_id_unique": {+ "name": "auth_api_keys_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "comments": {+ "name": "comments",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(6)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "content": {+ "name": "content",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "timestamp": {+ "name": "timestamp",+ "type": "float",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "authorId": {+ "name": "authorId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "parentCommentId": {+ "name": "parentCommentId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "author_id_idx": {+ "name": "author_id_idx",+ "columns": [+ "authorId"+ ],+ "isUnique": false+ },+ "parent_comment_id_idx": {+ "name": "parent_comment_id_idx",+ "columns": [+ "parentCommentId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "comments_id": {+ "name": "comments_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "comments_id_unique": {+ "name": "comments_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "folders": {+ "name": "folders",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "color": {+ "name": "color",+ "type": "varchar(16)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'normal'"+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdById": {+ "name": "createdById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "parentId": {+ "name": "parentId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "created_by_id_idx": {+ "name": "created_by_id_idx",+ "columns": [+ "createdById"+ ],+ "isUnique": false+ },+ "parent_id_idx": {+ "name": "parent_id_idx",+ "columns": [+ "parentId"+ ],+ "isUnique": false+ },+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "folders_id": {+ "name": "folders_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "folders_id_unique": {+ "name": "folders_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "notifications": {+ "name": "notifications",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "orgId": {+ "name": "orgId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "recipientId": {+ "name": "recipientId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(10)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "data": {+ "name": "data",+ "type": "json",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "readAt": {+ "name": "readAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "notifications_id": {+ "name": "notifications_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "notifications_id_unique": {+ "name": "notifications_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organization_invites": {+ "name": "organization_invites",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "invitedEmail": {+ "name": "invitedEmail",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "invitedByUserId": {+ "name": "invitedByUserId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "status": {+ "name": "status",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'pending'"+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "expiresAt": {+ "name": "expiresAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "invited_email_idx": {+ "name": "invited_email_idx",+ "columns": [+ "invitedEmail"+ ],+ "isUnique": false+ },+ "invited_by_user_id_idx": {+ "name": "invited_by_user_id_idx",+ "columns": [+ "invitedByUserId"+ ],+ "isUnique": false+ },+ "status_idx": {+ "name": "status_idx",+ "columns": [+ "status"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organization_invites_id": {+ "name": "organization_invites_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organization_invites_id_unique": {+ "name": "organization_invites_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organization_members": {+ "name": "organization_members",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "user_id_organization_id_idx": {+ "name": "user_id_organization_id_idx",+ "columns": [+ "userId",+ "organizationId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organization_members_id": {+ "name": "organization_members_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organization_members_id_unique": {+ "name": "organization_members_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organizations": {+ "name": "organizations",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "metadata": {+ "name": "metadata",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "allowedEmailDomain": {+ "name": "allowedEmailDomain",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "customDomain": {+ "name": "customDomain",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "domainVerified": {+ "name": "domainVerified",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "iconUrl": {+ "name": "iconUrl",+ "type": "varchar(1024)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "workosOrganizationId": {+ "name": "workosOrganizationId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "workosConnectionId": {+ "name": "workosConnectionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "owner_id_idx": {+ "name": "owner_id_idx",+ "columns": [+ "ownerId"+ ],+ "isUnique": false+ },+ "custom_domain_idx": {+ "name": "custom_domain_idx",+ "columns": [+ "customDomain"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organizations_id": {+ "name": "organizations_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organizations_id_unique": {+ "name": "organizations_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "s3_buckets": {+ "name": "s3_buckets",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "region": {+ "name": "region",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "endpoint": {+ "name": "endpoint",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "bucketName": {+ "name": "bucketName",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "accessKeyId": {+ "name": "accessKeyId",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "secretAccessKey": {+ "name": "secretAccessKey",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "provider": {+ "name": "provider",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "('aws')"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "s3_buckets_id": {+ "name": "s3_buckets_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "s3_buckets_id_unique": {+ "name": "s3_buckets_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "sessions": {+ "name": "sessions",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sessionToken": {+ "name": "sessionToken",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "expires": {+ "name": "expires",+ "type": "datetime",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "session_token_idx": {+ "name": "session_token_idx",+ "columns": [+ "sessionToken"+ ],+ "isUnique": true+ },+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "sessions_id": {+ "name": "sessions_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "sessions_id_unique": {+ "name": "sessions_id_unique",+ "columns": [+ "id"+ ]+ },+ "sessions_sessionToken_unique": {+ "name": "sessions_sessionToken_unique",+ "columns": [+ "sessionToken"+ ]+ }+ },+ "checkConstraint": {}+ },+ "shared_videos": {+ "name": "shared_videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sharedByUserId": {+ "name": "sharedByUserId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sharedAt": {+ "name": "sharedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "shared_by_user_id_idx": {+ "name": "shared_by_user_id_idx",+ "columns": [+ "sharedByUserId"+ ],+ "isUnique": false+ },+ "video_id_organization_id_idx": {+ "name": "video_id_organization_id_idx",+ "columns": [+ "videoId",+ "organizationId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "shared_videos_id": {+ "name": "shared_videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "shared_videos_id_unique": {+ "name": "shared_videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "space_members": {+ "name": "space_members",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'member'"+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ },+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "space_id_user_id_idx": {+ "name": "space_id_user_id_idx",+ "columns": [+ "spaceId",+ "userId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "space_members_id": {+ "name": "space_members_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "space_members_id_unique": {+ "name": "space_members_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "space_videos": {+ "name": "space_videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "folderId": {+ "name": "folderId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "addedById": {+ "name": "addedById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "addedAt": {+ "name": "addedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ },+ "folder_id_idx": {+ "name": "folder_id_idx",+ "columns": [+ "folderId"+ ],+ "isUnique": false+ },+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "added_by_id_idx": {+ "name": "added_by_id_idx",+ "columns": [+ "addedById"+ ],+ "isUnique": false+ },+ "space_id_video_id_idx": {+ "name": "space_id_video_id_idx",+ "columns": [+ "spaceId",+ "videoId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "space_videos_id": {+ "name": "space_videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "space_videos_id_unique": {+ "name": "space_videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "spaces": {+ "name": "spaces",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "primary": {+ "name": "primary",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdById": {+ "name": "createdById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "iconUrl": {+ "name": "iconUrl",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "description": {+ "name": "description",+ "type": "varchar(1000)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "privacy": {+ "name": "privacy",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'Private'"+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "created_by_id_idx": {+ "name": "created_by_id_idx",+ "columns": [+ "createdById"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "spaces_id": {+ "name": "spaces_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "spaces_id_unique": {+ "name": "spaces_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "users": {+ "name": "users",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "lastName": {+ "name": "lastName",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "email": {+ "name": "email",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "emailVerified": {+ "name": "emailVerified",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "image": {+ "name": "image",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeCustomerId": {+ "name": "stripeCustomerId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionId": {+ "name": "stripeSubscriptionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "thirdPartyStripeSubscriptionId": {+ "name": "thirdPartyStripeSubscriptionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionStatus": {+ "name": "stripeSubscriptionStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionPriceId": {+ "name": "stripeSubscriptionPriceId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "preferences": {+ "name": "preferences",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false,+ "default": "('null')"+ },+ "activeOrganizationId": {+ "name": "activeOrganizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "onboarding_completed_at": {+ "name": "onboarding_completed_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "customBucket": {+ "name": "customBucket",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "inviteQuota": {+ "name": "inviteQuota",+ "type": "int",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": 1+ }+ },+ "indexes": {+ "email_idx": {+ "name": "email_idx",+ "columns": [+ "email"+ ],+ "isUnique": true+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "users_id": {+ "name": "users_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "users_id_unique": {+ "name": "users_id_unique",+ "columns": [+ "id"+ ]+ },+ "users_email_unique": {+ "name": "users_email_unique",+ "columns": [+ "email"+ ]+ }+ },+ "checkConstraint": {}+ },+ "verification_tokens": {+ "name": "verification_tokens",+ "columns": {+ "identifier": {+ "name": "identifier",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "token": {+ "name": "token",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "expires": {+ "name": "expires",+ "type": "datetime",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "verification_tokens_identifier": {+ "name": "verification_tokens_identifier",+ "columns": [+ "identifier"+ ]+ }+ },+ "uniqueConstraints": {+ "verification_tokens_token_unique": {+ "name": "verification_tokens_token_unique",+ "columns": [+ "token"+ ]+ }+ },+ "checkConstraint": {}+ },+ "videos": {+ "name": "videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'My Video'"+ },+ "awsRegion": {+ "name": "awsRegion",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "awsBucket": {+ "name": "awsBucket",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "bucket": {+ "name": "bucket",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "metadata": {+ "name": "metadata",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "public": {+ "name": "public",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": true+ },+ "password": {+ "name": "password",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "videoStartTime": {+ "name": "videoStartTime",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "audioStartTime": {+ "name": "audioStartTime",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "xStreamInfo": {+ "name": "xStreamInfo",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "jobId": {+ "name": "jobId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "jobStatus": {+ "name": "jobStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "isScreenshot": {+ "name": "isScreenshot",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "skipProcessing": {+ "name": "skipProcessing",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "transcriptionStatus": {+ "name": "transcriptionStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "source": {+ "name": "source",+ "type": "json",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "('{\"type\":\"MediaConvert\"}')"+ },+ "folderId": {+ "name": "folderId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "id_idx": {+ "name": "id_idx",+ "columns": [+ "id"+ ],+ "isUnique": false+ },+ "owner_id_idx": {+ "name": "owner_id_idx",+ "columns": [+ "ownerId"+ ],+ "isUnique": false+ },+ "is_public_idx": {+ "name": "is_public_idx",+ "columns": [+ "public"+ ],+ "isUnique": false+ },+ "folder_id_idx": {+ "name": "folder_id_idx",+ "columns": [+ "folderId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "videos_id": {+ "name": "videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "videos_id_unique": {+ "name": "videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ }+ },+ "views": {},+ "_meta": {+ "schemas": {},+ "tables": {},+ "columns": {}+ },+ "internal": {+ "tables": {},+ "indexes": {}+ }+}\ No newline at end of filediff --git a/packages/database/migrations/meta/0008_snapshot.json b/packages/database/migrations/meta/0008_snapshot.jsonnew file mode 100644index 000000000..c2035fcaf--- /dev/null+++ b/packages/database/migrations/meta/0008_snapshot.json@@ -0,0 +1,1918 @@+{+ "version": "5",+ "dialect": "mysql",+ "id": "6dee9a50-52c1-4900-a05d-b3fa7f6fcb27",+ "prevId": "ccef8ed8-2472-41a3-bf54-900db6ce8b08",+ "tables": {+ "accounts": {+ "name": "accounts",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "provider": {+ "name": "provider",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "providerAccountId": {+ "name": "providerAccountId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "access_token": {+ "name": "access_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "expires_in": {+ "name": "expires_in",+ "type": "int",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "id_token": {+ "name": "id_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "refresh_token": {+ "name": "refresh_token",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "refresh_token_expires_in": {+ "name": "refresh_token_expires_in",+ "type": "int",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "scope": {+ "name": "scope",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "token_type": {+ "name": "token_type",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "tempColumn": {+ "name": "tempColumn",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "provider_account_id_idx": {+ "name": "provider_account_id_idx",+ "columns": [+ "providerAccountId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "accounts_id": {+ "name": "accounts_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "accounts_id_unique": {+ "name": "accounts_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "auth_api_keys": {+ "name": "auth_api_keys",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(36)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "auth_api_keys_id": {+ "name": "auth_api_keys_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "auth_api_keys_id_unique": {+ "name": "auth_api_keys_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "comments": {+ "name": "comments",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(6)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "content": {+ "name": "content",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "timestamp": {+ "name": "timestamp",+ "type": "float",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "authorId": {+ "name": "authorId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "parentCommentId": {+ "name": "parentCommentId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "author_id_idx": {+ "name": "author_id_idx",+ "columns": [+ "authorId"+ ],+ "isUnique": false+ },+ "parent_comment_id_idx": {+ "name": "parent_comment_id_idx",+ "columns": [+ "parentCommentId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "comments_id": {+ "name": "comments_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "comments_id_unique": {+ "name": "comments_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "folders": {+ "name": "folders",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "color": {+ "name": "color",+ "type": "varchar(16)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'normal'"+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdById": {+ "name": "createdById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "parentId": {+ "name": "parentId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "created_by_id_idx": {+ "name": "created_by_id_idx",+ "columns": [+ "createdById"+ ],+ "isUnique": false+ },+ "parent_id_idx": {+ "name": "parent_id_idx",+ "columns": [+ "parentId"+ ],+ "isUnique": false+ },+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "folders_id": {+ "name": "folders_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "folders_id_unique": {+ "name": "folders_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "notifications": {+ "name": "notifications",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "orgId": {+ "name": "orgId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "recipientId": {+ "name": "recipientId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "type": {+ "name": "type",+ "type": "varchar(10)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "data": {+ "name": "data",+ "type": "json",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "readAt": {+ "name": "readAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {+ "recipient_id_idx": {+ "name": "recipient_id_idx",+ "columns": [+ "recipientId"+ ],+ "isUnique": false+ },+ "org_id_idx": {+ "name": "org_id_idx",+ "columns": [+ "orgId"+ ],+ "isUnique": false+ },+ "type_idx": {+ "name": "type_idx",+ "columns": [+ "type"+ ],+ "isUnique": false+ },+ "read_at_idx": {+ "name": "read_at_idx",+ "columns": [+ "readAt"+ ],+ "isUnique": false+ },+ "created_at_idx": {+ "name": "created_at_idx",+ "columns": [+ "createdAt"+ ],+ "isUnique": false+ },+ "recipient_read_idx": {+ "name": "recipient_read_idx",+ "columns": [+ "recipientId",+ "readAt"+ ],+ "isUnique": false+ },+ "recipient_created_idx": {+ "name": "recipient_created_idx",+ "columns": [+ "recipientId",+ "createdAt"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "notifications_id": {+ "name": "notifications_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "notifications_id_unique": {+ "name": "notifications_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organization_invites": {+ "name": "organization_invites",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "invitedEmail": {+ "name": "invitedEmail",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "invitedByUserId": {+ "name": "invitedByUserId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "status": {+ "name": "status",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'pending'"+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "expiresAt": {+ "name": "expiresAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "invited_email_idx": {+ "name": "invited_email_idx",+ "columns": [+ "invitedEmail"+ ],+ "isUnique": false+ },+ "invited_by_user_id_idx": {+ "name": "invited_by_user_id_idx",+ "columns": [+ "invitedByUserId"+ ],+ "isUnique": false+ },+ "status_idx": {+ "name": "status_idx",+ "columns": [+ "status"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organization_invites_id": {+ "name": "organization_invites_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organization_invites_id_unique": {+ "name": "organization_invites_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organization_members": {+ "name": "organization_members",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "user_id_organization_id_idx": {+ "name": "user_id_organization_id_idx",+ "columns": [+ "userId",+ "organizationId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organization_members_id": {+ "name": "organization_members_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organization_members_id_unique": {+ "name": "organization_members_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "organizations": {+ "name": "organizations",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "metadata": {+ "name": "metadata",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "allowedEmailDomain": {+ "name": "allowedEmailDomain",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "customDomain": {+ "name": "customDomain",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "domainVerified": {+ "name": "domainVerified",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "iconUrl": {+ "name": "iconUrl",+ "type": "varchar(1024)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "workosOrganizationId": {+ "name": "workosOrganizationId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "workosConnectionId": {+ "name": "workosConnectionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "owner_id_idx": {+ "name": "owner_id_idx",+ "columns": [+ "ownerId"+ ],+ "isUnique": false+ },+ "custom_domain_idx": {+ "name": "custom_domain_idx",+ "columns": [+ "customDomain"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "organizations_id": {+ "name": "organizations_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "organizations_id_unique": {+ "name": "organizations_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "s3_buckets": {+ "name": "s3_buckets",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "region": {+ "name": "region",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "endpoint": {+ "name": "endpoint",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "bucketName": {+ "name": "bucketName",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "accessKeyId": {+ "name": "accessKeyId",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "secretAccessKey": {+ "name": "secretAccessKey",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "provider": {+ "name": "provider",+ "type": "text",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "('aws')"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "s3_buckets_id": {+ "name": "s3_buckets_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "s3_buckets_id_unique": {+ "name": "s3_buckets_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "sessions": {+ "name": "sessions",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sessionToken": {+ "name": "sessionToken",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "expires": {+ "name": "expires",+ "type": "datetime",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "session_token_idx": {+ "name": "session_token_idx",+ "columns": [+ "sessionToken"+ ],+ "isUnique": true+ },+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "sessions_id": {+ "name": "sessions_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "sessions_id_unique": {+ "name": "sessions_id_unique",+ "columns": [+ "id"+ ]+ },+ "sessions_sessionToken_unique": {+ "name": "sessions_sessionToken_unique",+ "columns": [+ "sessionToken"+ ]+ }+ },+ "checkConstraint": {}+ },+ "shared_videos": {+ "name": "shared_videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sharedByUserId": {+ "name": "sharedByUserId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "sharedAt": {+ "name": "sharedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "shared_by_user_id_idx": {+ "name": "shared_by_user_id_idx",+ "columns": [+ "sharedByUserId"+ ],+ "isUnique": false+ },+ "video_id_organization_id_idx": {+ "name": "video_id_organization_id_idx",+ "columns": [+ "videoId",+ "organizationId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "shared_videos_id": {+ "name": "shared_videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "shared_videos_id_unique": {+ "name": "shared_videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "space_members": {+ "name": "space_members",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "userId": {+ "name": "userId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "role": {+ "name": "role",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'member'"+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ },+ "user_id_idx": {+ "name": "user_id_idx",+ "columns": [+ "userId"+ ],+ "isUnique": false+ },+ "space_id_user_id_idx": {+ "name": "space_id_user_id_idx",+ "columns": [+ "spaceId",+ "userId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "space_members_id": {+ "name": "space_members_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "space_members_id_unique": {+ "name": "space_members_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "space_videos": {+ "name": "space_videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "spaceId": {+ "name": "spaceId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "folderId": {+ "name": "folderId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "videoId": {+ "name": "videoId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "addedById": {+ "name": "addedById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "addedAt": {+ "name": "addedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ }+ },+ "indexes": {+ "space_id_idx": {+ "name": "space_id_idx",+ "columns": [+ "spaceId"+ ],+ "isUnique": false+ },+ "folder_id_idx": {+ "name": "folder_id_idx",+ "columns": [+ "folderId"+ ],+ "isUnique": false+ },+ "video_id_idx": {+ "name": "video_id_idx",+ "columns": [+ "videoId"+ ],+ "isUnique": false+ },+ "added_by_id_idx": {+ "name": "added_by_id_idx",+ "columns": [+ "addedById"+ ],+ "isUnique": false+ },+ "space_id_video_id_idx": {+ "name": "space_id_video_id_idx",+ "columns": [+ "spaceId",+ "videoId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "space_videos_id": {+ "name": "space_videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "space_videos_id_unique": {+ "name": "space_videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "spaces": {+ "name": "spaces",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "primary": {+ "name": "primary",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "organizationId": {+ "name": "organizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "createdById": {+ "name": "createdById",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "iconUrl": {+ "name": "iconUrl",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "description": {+ "name": "description",+ "type": "varchar(1000)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "privacy": {+ "name": "privacy",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'Private'"+ }+ },+ "indexes": {+ "organization_id_idx": {+ "name": "organization_id_idx",+ "columns": [+ "organizationId"+ ],+ "isUnique": false+ },+ "created_by_id_idx": {+ "name": "created_by_id_idx",+ "columns": [+ "createdById"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "spaces_id": {+ "name": "spaces_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "spaces_id_unique": {+ "name": "spaces_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ },+ "users": {+ "name": "users",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "lastName": {+ "name": "lastName",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "email": {+ "name": "email",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "emailVerified": {+ "name": "emailVerified",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "image": {+ "name": "image",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeCustomerId": {+ "name": "stripeCustomerId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionId": {+ "name": "stripeSubscriptionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "thirdPartyStripeSubscriptionId": {+ "name": "thirdPartyStripeSubscriptionId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionStatus": {+ "name": "stripeSubscriptionStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "stripeSubscriptionPriceId": {+ "name": "stripeSubscriptionPriceId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "preferences": {+ "name": "preferences",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false,+ "default": "('null')"+ },+ "activeOrganizationId": {+ "name": "activeOrganizationId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "onboarding_completed_at": {+ "name": "onboarding_completed_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "customBucket": {+ "name": "customBucket",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "inviteQuota": {+ "name": "inviteQuota",+ "type": "int",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": 1+ }+ },+ "indexes": {+ "email_idx": {+ "name": "email_idx",+ "columns": [+ "email"+ ],+ "isUnique": true+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "users_id": {+ "name": "users_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "users_id_unique": {+ "name": "users_id_unique",+ "columns": [+ "id"+ ]+ },+ "users_email_unique": {+ "name": "users_email_unique",+ "columns": [+ "email"+ ]+ }+ },+ "checkConstraint": {}+ },+ "verification_tokens": {+ "name": "verification_tokens",+ "columns": {+ "identifier": {+ "name": "identifier",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "token": {+ "name": "token",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "expires": {+ "name": "expires",+ "type": "datetime",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "created_at": {+ "name": "created_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updated_at": {+ "name": "updated_at",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ }+ },+ "indexes": {},+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "verification_tokens_identifier": {+ "name": "verification_tokens_identifier",+ "columns": [+ "identifier"+ ]+ }+ },+ "uniqueConstraints": {+ "verification_tokens_token_unique": {+ "name": "verification_tokens_token_unique",+ "columns": [+ "token"+ ]+ }+ },+ "checkConstraint": {}+ },+ "videos": {+ "name": "videos",+ "columns": {+ "id": {+ "name": "id",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "ownerId": {+ "name": "ownerId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false+ },+ "name": {+ "name": "name",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "'My Video'"+ },+ "awsRegion": {+ "name": "awsRegion",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "awsBucket": {+ "name": "awsBucket",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "bucket": {+ "name": "bucket",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "metadata": {+ "name": "metadata",+ "type": "json",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "public": {+ "name": "public",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": true+ },+ "password": {+ "name": "password",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "videoStartTime": {+ "name": "videoStartTime",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "audioStartTime": {+ "name": "audioStartTime",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "xStreamInfo": {+ "name": "xStreamInfo",+ "type": "text",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "jobId": {+ "name": "jobId",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "jobStatus": {+ "name": "jobStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "isScreenshot": {+ "name": "isScreenshot",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "skipProcessing": {+ "name": "skipProcessing",+ "type": "boolean",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": false+ },+ "transcriptionStatus": {+ "name": "transcriptionStatus",+ "type": "varchar(255)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ },+ "createdAt": {+ "name": "createdAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "(now())"+ },+ "updatedAt": {+ "name": "updatedAt",+ "type": "timestamp",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "onUpdate": true,+ "default": "(now())"+ },+ "source": {+ "name": "source",+ "type": "json",+ "primaryKey": false,+ "notNull": true,+ "autoincrement": false,+ "default": "('{\"type\":\"MediaConvert\"}')"+ },+ "folderId": {+ "name": "folderId",+ "type": "varchar(15)",+ "primaryKey": false,+ "notNull": false,+ "autoincrement": false+ }+ },+ "indexes": {+ "id_idx": {+ "name": "id_idx",+ "columns": [+ "id"+ ],+ "isUnique": false+ },+ "owner_id_idx": {+ "name": "owner_id_idx",+ "columns": [+ "ownerId"+ ],+ "isUnique": false+ },+ "is_public_idx": {+ "name": "is_public_idx",+ "columns": [+ "public"+ ],+ "isUnique": false+ },+ "folder_id_idx": {+ "name": "folder_id_idx",+ "columns": [+ "folderId"+ ],+ "isUnique": false+ }+ },+ "foreignKeys": {},+ "compositePrimaryKeys": {+ "videos_id": {+ "name": "videos_id",+ "columns": [+ "id"+ ]+ }+ },+ "uniqueConstraints": {+ "videos_id_unique": {+ "name": "videos_id_unique",+ "columns": [+ "id"+ ]+ }+ },+ "checkConstraint": {}+ }+ },+ "views": {},+ "_meta": {+ "schemas": {},+ "tables": {},+ "columns": {}+ },+ "internal": {+ "tables": {},+ "indexes": {}+ }+}\ No newline at end of filediff --git a/packages/database/migrations/meta/_journal.json b/packages/database/migrations/meta/_journal.jsonindex 818cb035b..a58dc667a 100644--- a/packages/database/migrations/meta/_journal.json+++ b/packages/database/migrations/meta/_journal.json@@ -50,6 +50,20 @@"when": 1751982995648,"tag": "0006_woozy_jamie_braddock","breakpoints": true+ },+ {+ "idx": 7,+ "version": "5",+ "when": 1754318170128,+ "tag": "0007_first_lilith",+ "breakpoints": true+ },+ {+ "idx": 8,+ "version": "5",+ "when": 1754326114877,+ "tag": "0008_illegal_rogue",+ "breakpoints": true}]}\ No newline at end of filediff --git a/packages/database/package.json b/packages/database/package.jsonindex 2342b3fe5..c0497f226 100644--- a/packages/database/package.json+++ b/packages/database/package.json@@ -27,7 +27,8 @@"next": "14.2.9","next-auth": "^4.24.5","react-email": "^4.0.16",- "resend": "4.6.0"+ "resend": "4.6.0",+ "zod": "^3"},"devDependencies": {"@cap/ui": "workspace:*",diff --git a/packages/database/schema.ts b/packages/database/schema.tsindex 2db1a7fef..9eecead15 100644--- a/packages/database/schema.ts+++ b/packages/database/schema.ts@@ -63,6 +63,16 @@ export const users = mysqlTable(stripeSubscriptionPriceId: varchar("stripeSubscriptionPriceId", {length: 255,}),+ preferences: json("preferences")+ .$type<{+ notifications: {+ pauseComments: boolean;+ pauseReplies: boolean;+ pauseViews: boolean;+ pauseReactions: boolean;+ };+ } | null>()+ .default(null),activeOrganizationId: nanoId("activeOrganizationId"),created_at: timestamp("created_at").notNull().defaultNow(),updated_at: timestamp("updated_at").notNull().defaultNow().onUpdateNow(),@@ -300,6 +310,45 @@ export const comments = mysqlTable(}));+export const notifications = mysqlTable(+ "notifications",+ {+ id: nanoId("id").notNull().primaryKey().unique(),+ orgId: nanoId("orgId").notNull(),+ recipientId: nanoId("recipientId").notNull(),+ type: varchar("type", { length: 10 })+ .notNull()+ .$type<"view" | "comment" | "reply" | "reaction" /*| "mention"*/>(),+ data: json("data")+ .$type<{+ videoId?: string;+ authorId?: string;+ comment?: {+ id: string;+ content: string;+ };+ }>()+ .notNull(),+ readAt: timestamp("readAt"),+ createdAt: timestamp("createdAt").notNull().defaultNow(),+ },+ (table) => ({+ recipientIdIndex: index("recipient_id_idx").on(table.recipientId),+ orgIdIndex: index("org_id_idx").on(table.orgId),+ typeIndex: index("type_idx").on(table.type),+ readAtIndex: index("read_at_idx").on(table.readAt),+ createdAtIndex: index("created_at_idx").on(table.createdAt),+ recipientReadIndex: index("recipient_read_idx").on(+ table.recipientId,+ table.readAt+ ),+ recipientCreatedIndex: index("recipient_created_idx").on(+ table.recipientId,+ table.createdAt+ ),+ })+);+export const s3Buckets = mysqlTable("s3_buckets", {id: nanoId("id").notNull().primaryKey().unique(),ownerId: nanoId("ownerId").notNull(),@@ -312,6 +361,17 @@ export const s3Buckets = mysqlTable("s3_buckets", {provider: text("provider").notNull().default("aws"),});+export const notificationsRelations = relations(notifications, ({ one }) => ({+ org: one(organizations, {+ fields: [notifications.orgId],+ references: [organizations.id],+ }),+ recipient: one(users, {+ fields: [notifications.recipientId],+ references: [users.id],+ }),+}));+export const authApiKeys = mysqlTable("auth_api_keys", {id: varchar("id", { length: 36 }).notNull().primaryKey().unique(),userId: nanoId("userId").notNull(),diff --git a/packages/env/package.json b/packages/env/package.jsonindex d10976715..92d6e358a 100644--- a/packages/env/package.json+++ b/packages/env/package.json@@ -5,7 +5,7 @@"types": "./index.ts","dependencies": {"@t3-oss/env-nextjs": "^0.12.0",- "zod": "^3.24.2"+ "zod": "^3.25.76"},"devDependencies": {"@types/node": "^22.12.0"diff --git a/packages/local-docker/package.json b/packages/local-docker/package.jsonindex b898192ce..7b08894b1 100644--- a/packages/local-docker/package.json+++ b/packages/local-docker/package.json@@ -9,8 +9,6 @@"docker:stop": "docker compose stop","docker:clean": "docker compose down -v"},- "devDependencies": {},- "dependencies": {},"engines": {"node": "20"}diff --git a/packages/ui-solid/package.json b/packages/ui-solid/package.jsonindex 1162d10b9..fc7a664fe 100644--- a/packages/ui-solid/package.json+++ b/packages/ui-solid/package.json@@ -14,7 +14,8 @@"@kobalte/core": "^0.13.7","cva": "npm:class-variance-authority@^0.7.0","solid-js": "^1.9.3",- "tailwindcss": "^3.4.10"+ "tailwindcss": "^3.4.10",+ "zod": "^3"},"devDependencies": {"@fontsource/geist-sans": "^5.0.3",diff --git a/packages/ui/package.json b/packages/ui/package.jsonindex b1e88870e..cce9a24c9 100644--- a/packages/ui/package.json+++ b/packages/ui/package.json@@ -52,7 +52,8 @@"cmdk": "^0.2.0","lucide-react": "^0.294.0","react-hook-form": "^7.49.2",- "react-loading-skeleton": "^3.3.1"+ "react-loading-skeleton": "^3.3.1",+ "zod": "^3"},"engines": {"node": "20"diff --git a/packages/ui/style/tailwind.config.js b/packages/ui/style/tailwind.config.jsindex b2d2fdb85..f84767fd9 100644--- a/packages/ui/style/tailwind.config.js+++ b/packages/ui/style/tailwind.config.js@@ -1,4 +1,4 @@-module.exports = function (app, options) {+module.exports = function (__app, _options) {// Function to generate color scales for Radix colorsfunction getColorScale(name, alpha = false) {let scale = {};@@ -73,6 +73,7 @@ module.exports = function (app, options) {},colors: {gray: getColorScale("gray"),+ "gray-a": getColorScale("gray-a", true),blue: getColorScale("blue"),red: getColorScale("red"),border: "hsl(var(--border))",diff --git a/packages/utils/package.json b/packages/utils/package.jsonindex d9d0835f3..0dbc1c99a 100644--- a/packages/utils/package.json+++ b/packages/utils/package.json@@ -22,7 +22,8 @@"@cap/env": "workspace:*","clsx": "^2.0.0","stripe": "^14.24.0",- "tailwind-merge": "^2.1.0"+ "tailwind-merge": "^2.1.0",+ "zod": "^3"},"engines": {"node": "20"diff --git a/packages/web-api-contract-effect/package.json b/packages/web-api-contract-effect/package.jsonindex caa71d8cb..a78434b3b 100644--- a/packages/web-api-contract-effect/package.json+++ b/packages/web-api-contract-effect/package.json@@ -6,6 +6,7 @@"type": "module","dependencies": {"@effect/platform": "^0.87.1",- "effect": "^3.16.10"+ "effect": "^3.16.10",+ "zod": "^3"}}diff --git a/packages/web-api-contract/package.json b/packages/web-api-contract/package.jsonindex 425c62d86..3ae35b1ae 100644--- a/packages/web-api-contract/package.json+++ b/packages/web-api-contract/package.json@@ -6,6 +6,6 @@"type": "module","dependencies": {"@ts-rest/core": "^3.52.1",- "zod": "^3.24.2"+ "zod": "^3.25.76"}}diff --git a/packages/web-api-contract/src/desktop.ts b/packages/web-api-contract/src/desktop.tsindex 050ad2932..2bbea087d 100644--- a/packages/web-api-contract/src/desktop.ts+++ b/packages/web-api-contract/src/desktop.ts@@ -1,5 +1,6 @@import { z } from "zod";import { c } from "./util";+import { AppRoute } from "@ts-rest/core";const CHANGELOG = z.object({metadata: z.object({@@ -38,6 +39,11 @@ const publicContract = c.router({},});+const a = publicContract.getChangelogPosts;+type A = typeof a;++type B = A extends AppRoute ? number : string;+const protectedContract = c.router({submitFeedback: {diff --git a/packages/web-api-contract/src/index.ts b/packages/web-api-contract/src/index.tsindex ac95b2056..d9c4d9134 100644--- a/packages/web-api-contract/src/index.ts+++ b/packages/web-api-contract/src/index.ts@@ -2,6 +2,62 @@ import { z } from "zod";import desktop from "./desktop";import { c } from "./util";+export const NotificationAuthor = z.object({+ id: z.string(),+ name: z.string(),+ avatar: z.string().nullable(),+});++export const NotificationBase = z.object({+ id: z.string(),+ readAt: z.coerce.date().nullable(),+ createdAt: z.coerce.date(),+});+export type NotificationBase = z.infer<typeof NotificationBase>;++const CommentData = z.object({+ id: z.string(),+ content: z.string(),+});++export const Notification = z+ .union([+ z.object({+ type: z.literal("view"),+ videoId: z.string(),+ author: NotificationAuthor,+ }),+ z.object({+ type: z.literal("comment"),+ videoId: z.string(),+ author: NotificationAuthor,+ comment: CommentData,+ }),+ z.object({+ type: z.literal("reaction"),+ videoId: z.string(),+ author: NotificationAuthor,+ comment: CommentData,+ }),+ z.object({+ type: z.literal("reply"),+ videoId: z.string(),+ author: NotificationAuthor,+ comment: CommentData,+ }),+ // z.object({+ // type: z.literal("mention"),+ // videoId: z.string(),+ // author: NotificationAuthor,+ // comment: z.object({+ // id: z.string(),+ // content: z.string(),+ // }),+ // }),+ ])+ .and(NotificationBase);+export type Notification = z.infer<typeof Notification>;+export const contract = c.router({desktop,video: c.router({@@ -32,6 +88,18 @@ export const contract = c.router({},},}),+ notifications: c.router({+ get: {+ method: "GET",+ path: "/notifications",+ responses: {+ 200: z.object({+ notifications: z.array(Notification),+ count: z.record(z.string(), z.number()),+ }),+ },+ },+ }),});export const orgCustomDomainContract = c.router({diff --git a/packages/web-api-contract/tsconfig.json b/packages/web-api-contract/tsconfig.jsonnew file mode 100644index 000000000..acdd0c7da--- /dev/null+++ b/packages/web-api-contract/tsconfig.json@@ -0,0 +1,9 @@+{+ "extends": "../config/base.tsconfig.json",+ "exclude": ["node_modules"],+ "include": ["**/*.ts", "**/*.tsx"],+ "compilerOptions": {+ "baseUrl": ".",+ "moduleResolution": "bundler"+ }+}diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex 7f0ab0e99..e087e3ddd 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -103,7 +103,7 @@ importers:version: 0.14.10([email protected])'@solidjs/start':specifier: ^1.1.3- version: 1.1.3(@testing-library/[email protected])(@types/[email protected])([email protected])([email protected])([email protected])([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))([email protected])+ version: 1.1.3(@testing-library/[email protected])(@types/[email protected])([email protected])([email protected])([email protected])([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))([email protected])'@tanstack/solid-query':specifier: ^5.51.21version: 5.75.4([email protected])@@ -148,7 +148,7 @@ importers:version: 2.0.0'@ts-rest/core':specifier: ^3.52.1- version: 3.52.1(@types/[email protected])([email protected])+ version: 3.52.1(@types/[email protected])([email protected])'@types/react-tooltip':specifier: ^4.2.4@@ -190,13 +190,13 @@ importers:version: 9.0.1vinxi:specifier: ^0.5.6- version: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])+ version: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])webcodecs:specifier: ^0.1.0version: 0.1.0zod:- specifier: ^3.24.2- version: 3.24.4+ specifier: ^3.25.76+ version: 3.25.76devDependencies:'@fontsource/geist-sans':specifier: ^5.0.3@@ -224,10 +224,10 @@ importers:version: 5.8.3vite:specifier: ^6.3.5vite-tsconfig-paths:specifier: ^5.0.1- version: 5.1.4([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 5.1.4([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))vitest:specifier: ~2.1.9@@ -255,6 +255,9 @@ importers:valibot:specifier: 1.0.0-rc.1version: 1.0.0-rc.1([email protected])+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@cloudflare/vitest-pool-workers':specifier: ^0.6.4@@ -283,6 +286,9 @@ importers:solid-js:specifier: ^1.9.3version: 1.9.6+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@chromatic-com/storybook':specifier: ^1.6.1@@ -313,16 +319,16 @@ importers:version: 1.0.0-beta.7(@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))storybook-solidjs-vite:specifier: ^1.0.0-beta.2- version: 1.0.0-beta.7(@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))([email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 1.0.0-beta.7(@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))([email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))typescript:specifier: ^5.8.3version: 5.8.3vite:specifier: ^6.3.5vite-plugin-solid:specifier: ^2.10.2- version: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))apps/tasks:dependencies:@@ -371,6 +377,9 @@ importers:typescript:specifier: ^5.8.3version: 5.8.3+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@typescript-eslint/eslint-plugin':specifier: ^7.6.0@@ -458,7 +467,7 @@ importers:'@hono/zod-validator':specifier: ^0.4.3- version: 0.4.3([email protected])([email protected])+ version: 0.4.3([email protected])([email protected])'@hookform/resolvers':specifier: ^3.3.2version: 3.10.0([email protected]([email protected]))@@ -515,7 +524,7 @@ importers:version: 3.5.0'@t3-oss/env-nextjs':specifier: ^0.12.0'@tanstack/react-query':specifier: ^5.75.4version: 5.75.4([email protected])@@ -527,7 +536,7 @@ importers:version: 0.5.5'@ts-rest/core':specifier: ^3.52.1- version: 3.52.1(@types/[email protected])([email protected])+ version: 3.52.1(@types/[email protected])([email protected])'@uidotdev/usehooks':specifier: ^2.4.1@@ -563,7 +572,7 @@ importers:version: 0.43.1(@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected])dub:specifier: ^0.64.0- version: 0.64.0(@modelcontextprotocol/[email protected])([email protected])+ version: 0.64.0(@modelcontextprotocol/[email protected])([email protected])file-saver:specifier: ^2.0.5version: 2.0.5@@ -679,8 +688,8 @@ importers:specifier: ^9.0.1version: 9.0.1zod:- specifier: ^3.24.4- version: 3.25.20+ specifier: ^3.25.76+ version: 3.25.76devDependencies:'@smithy/types':specifier: ^4.3.1@@ -739,6 +748,9 @@ importers:'@pulumiverse/vercel':specifier: ^1.14.3+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:sst:specifier: 3.10.13@@ -748,13 +760,16 @@ importers:dependencies:'@vitejs/plugin-react':specifier: ^4.0.3- version: 4.4.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 4.4.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))vite:specifier: ^6.3.5vite-tsconfig-paths:specifier: ^4.2.0- version: 4.3.2([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 4.3.2([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@types/node':specifier: ^20.4.5@@ -837,6 +852,9 @@ importers:resend:specifier: 4.6.0+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@cap/ui':specifier: workspace:*@@ -882,10 +900,10 @@ importers:dependencies:'@t3-oss/env-nextjs':specifier: ^0.12.0zod:- specifier: ^3.24.2- version: 3.24.4+ specifier: ^3.25.76+ version: 3.25.76devDependencies:'@types/node':specifier: ^22.12.0@@ -948,6 +966,9 @@ importers:react-loading-skeleton:specifier: ^3.3.1version: 3.5.0([email protected])+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@tauri-apps/cli':specifier: ^1.5.11@@ -963,7 +984,7 @@ importers:version: 19.1.7(@types/[email protected])'@vitejs/plugin-react':specifier: ^4.0.3- version: 4.4.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 4.4.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))autoprefixer:specifier: ^10.4.16version: 10.4.21([email protected])@@ -1005,10 +1026,10 @@ importers:version: 5.8.3vite:specifier: ^6.3.5vite-tsconfig-paths:specifier: ^4.2.1- version: 4.3.2([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 4.3.2([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))packages/ui-solid:dependencies:@@ -1024,6 +1045,9 @@ importers:tailwindcss:specifier: ^3.4.10+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:'@fontsource/geist-sans':specifier: ^5.0.3@@ -1057,7 +1081,7 @@ importers:version: 0.18.6([email protected])unplugin-fonts:specifier: ^1.1.1- version: 1.3.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ version: 1.3.1([email protected](@types/[email protected])([email protected])([email protected])([email protected]))unplugin-icons:specifier: ^0.19.2version: 0.19.3@@ -1079,6 +1103,9 @@ importers:tailwind-merge:specifier: ^2.1.0version: 2.6.0+ zod:+ specifier: ^3+ version: 3.25.76devDependencies:react:specifier: ^19.1.0@@ -1100,10 +1127,10 @@ importers:dependencies:'@ts-rest/core':specifier: ^3.52.1- version: 3.52.1(@types/[email protected])([email protected])+ version: 3.52.1(@types/[email protected])([email protected])zod:- specifier: ^3.24.2- version: 3.24.4+ specifier: ^3.25.76+ version: 3.25.76packages/web-api-contract-effect:dependencies:@@ -1113,6 +1140,9 @@ importers:effect:specifier: ^3.16.10version: 3.16.16+ zod:+ specifier: ^3+ version: 3.25.76packages:@@ -5493,10 +5523,10 @@ packages:react-dom:optional: true- '@storybook/[email protected]':- resolution: {integrity: sha512-Cx1XVZdIiGPWnTIRTEwge13S9GTT5E5LilApaCJuSngAJ6slIxLZuSaqzVPd1xQmytIClBzCXIL+tKzEEZPsqQ==}+ '@storybook/[email protected]':+ resolution: {integrity: sha512-1olE/xZI98CXu1WMS4zi725+jyrU3DCYYBgxpZVG7cNJtXQmkNwSzUhw4EDSBcNZE7ugO4/Ff4ud3VtlB4Bntw==}peerDependencies:- storybook: ^9.2.0-alpha.1+ storybook: ^9.2.0-alpha.2vite: ^5.0.0 || ^6.0.0 || ^7.0.0'@storybook/[email protected]':@@ -5512,10 +5542,10 @@ packages:peerDependencies:storybook: ^8.6.12- '@storybook/[email protected]':- resolution: {integrity: sha512-LUF5DGlss72LzZYFbXq7smHyETyLII5y84bS67xd4lfqyXHpMtj6KddyHsSPA9FQvVR8tYK/jmpzj1Z4PNeWJg==}+ '@storybook/[email protected]':+ resolution: {integrity: sha512-RoxwOkwprpxP8dtGy2riADxURcy5uxSO3+W4nf/ewVIQPKEKC97N9Nc8YuPMxLtMZ06zRY91/QBF7eq0TvXWSQ==}peerDependencies:- storybook: ^9.2.0-alpha.1+ storybook: ^9.2.0-alpha.2'@storybook/[email protected]':resolution: {integrity: sha512-bOmTNJE4FM6+3/1hPQVgha8cLxX2Nyi/4Z+tYq0pCDEyQqGRTD2KXre9XsSCnziRaGxiW80OrKkmqWY8Otuu4A==}@@ -12503,8 +12533,8 @@ packages:resolution: {integrity: sha512-0/FvIG4g3kNkYgbNwBBW5pZBkfpeYQnH+2AA3xmjkCAit/DSDPKmgwC3fKof4oYUq6gupClVOJlFl+939VRBMg==}- resolution: {integrity: sha512-EGs8PguQqAAUIcQfK4E9xdXxB6s2GK4sJfT/vcc9V1ELIvC4LH/zXu2t/5fajtv6oiRCxdv7BgtVK3vWgROxag==}+ resolution: {integrity: sha512-kIjN2qmWiHnhgr5DAkAafF9fwb0T5OhMVSWrm8XEdTFnX6+wfXwYOFjeF86UZ54vduqiR7BfqScFmXSzSaH8oA==}resolution: {integrity: sha512-CLDfGgUp7XPswWnezWwsCRxNmgQjhYq3VXHM0/XIRxhVrKw0M1if9agzryh1QS3nxjCROvV+xWxoJO1YctzzWg==}@@ -13432,6 +13462,11 @@ packages:engines: {node: '>= 14.6'}hasBin: true+ resolution: {integrity: sha512-lcYcMxX2PO9XMGvAJkJ3OsNMw+/7FKes7/hgerGUYWIoWu5j/+YQqcZr5JnPZWzOsEBgMbSbiSTn/dv/69Mkpw==}+ engines: {node: '>= 14.6'}+ hasBin: true+resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==}engines: {node: '>=12'}@@ -13492,12 +13527,6 @@ packages:resolution: {integrity: sha512-lY7CDW43ECgW9u1TcT3IoXHflywfVqDYze4waEz812jR/bZ8FHDsl7pFQoSZTz5N+2NqRXs8GBwnAwo3ZNxqhQ==}- resolution: {integrity: sha512-OdqJE9UDRPwWsrHjLN2F8bPxvwJBK22EHLWtanu0LSYr5YqzsaaW3RMgmjwr8Rypg5k+meEJdSPXJZXE/yqOMg==}-- resolution: {integrity: sha512-z03fqpTMDF1G02VLKUMt6vyACE7rNWkh3gpXVHgPTw28NPtDFRGvcpTtPwn2kMKtQ0idtYJUTxchytmnqYswcw==}-resolution: {integrity: sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==}@@ -14430,7 +14459,7 @@ snapshots:semver: 7.7.1wrangler: 3.109.1(@cloudflare/[email protected])- zod: 3.24.4+ zod: 3.25.76transitivePeerDependencies:- '@cloudflare/workers-types'- bufferutil@@ -14523,9 +14552,9 @@ snapshots:gray-matter: 4.0.3imagescript: 1.3.1micromatch: 4.0.8- ts-pattern: 5.7.1+ ts-pattern: 5.8.0unified: 11.0.5- yaml: 2.8.0+ yaml: 2.8.1zod: 3.25.76transitivePeerDependencies:- '@effect-ts/otel-node'@@ -15298,10 +15327,10 @@ snapshots:hono: 4.7.8valibot: 1.0.0-rc.1([email protected])dependencies:hono: 4.7.8- zod: 3.25.20+ zod: 3.25.76dependencies:@@ -16057,7 +16086,7 @@ snapshots:unixify: 1.0.0urlpattern-polyfill: 8.0.2yargs: 17.7.2- zod: 3.25.20+ zod: 3.25.76transitivePeerDependencies:- encoding- rollup@@ -18574,11 +18603,11 @@ snapshots:dependencies:solid-js: 1.9.6- '@solidjs/[email protected](@testing-library/[email protected])(@types/[email protected])([email protected])([email protected])([email protected])([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))([email protected])':+ '@solidjs/[email protected](@testing-library/[email protected])(@types/[email protected])([email protected])([email protected])([email protected])([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))([email protected])':dependencies:- '@tanstack/server-functions-plugin': 1.119.2(@types/[email protected])([email protected])([email protected])([email protected])- '@vinxi/plugin-directives': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))- '@vinxi/server-components': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))+ '@tanstack/server-functions-plugin': 1.119.2(@types/[email protected])([email protected])([email protected])([email protected])+ '@vinxi/plugin-directives': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))+ '@vinxi/server-components': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))defu: 6.1.4error-stack-parser: 2.1.4html-to-image: 1.11.13@@ -18589,8 +18618,8 @@ snapshots:source-map-js: 1.2.1terracotta: 1.0.6([email protected])tinyglobby: 0.2.13- vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])- vite-plugin-solid: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])+ vite-plugin-solid: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))transitivePeerDependencies:- '@testing-library/jest-dom'- '@types/node'@@ -18717,12 +18746,12 @@ snapshots:react: 19.1.0react-dom: 19.1.0([email protected])- '@storybook/[email protected]([email protected]([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))':+ '@storybook/[email protected]([email protected]([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))':dependencies:- '@storybook/csf-plugin': 9.2.0-alpha.1([email protected]([email protected]))+ '@storybook/csf-plugin': 9.2.0-alpha.2([email protected]([email protected]))storybook: 8.6.12([email protected])ts-dedent: 2.2.0dependencies:@@ -18750,7 +18779,7 @@ snapshots:storybook: 8.6.12([email protected])unplugin: 1.16.1dependencies:storybook: 8.6.12([email protected])unplugin: 1.16.1@@ -18832,33 +18861,19 @@ snapshots:dependencies:defer-to-connect: 2.0.1- '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':- optionalDependencies:- typescript: 5.8.3- valibot: 1.0.0-rc.1([email protected])- zod: 3.24.4-- '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':- optionalDependencies:- typescript: 5.8.3- valibot: 1.0.0-rc.1([email protected])- zod: 3.25.20-- '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':- dependencies:- '@t3-oss/env-core': 0.12.0([email protected])([email protected]([email protected]))([email protected])+ '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':optionalDependencies:typescript: 5.8.3valibot: 1.0.0-rc.1([email protected])- zod: 3.24.4+ zod: 3.25.76- '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':+ '@t3-oss/[email protected]([email protected])([email protected]([email protected]))([email protected])':dependencies:- '@t3-oss/env-core': 0.12.0([email protected])([email protected]([email protected]))([email protected])+ '@t3-oss/env-core': 0.12.0([email protected])([email protected]([email protected]))([email protected])optionalDependencies:typescript: 5.8.3valibot: 1.0.0-rc.1([email protected])- zod: 3.25.20+ zod: 3.25.76'@tailwindcss/[email protected]([email protected]([email protected](@types/[email protected])([email protected])))':dependencies:@@ -18876,7 +18891,7 @@ snapshots:postcss-selector-parser: 6.0.10- '@tanstack/[email protected](@types/[email protected])([email protected])([email protected])([email protected])':+ '@tanstack/[email protected](@types/[email protected])([email protected])([email protected])([email protected])':dependencies:'@babel/code-frame': 7.26.2'@babel/core': 7.27.1@@ -18889,7 +18904,7 @@ snapshots:babel-dead-code-elimination: 1.0.10dedent: 1.6.0tiny-invariant: 1.3.3transitivePeerDependencies:- '@types/node'- babel-plugin-macros@@ -18932,7 +18947,7 @@ snapshots:ansis: 3.17.0diff: 7.0.0- '@tanstack/[email protected](@types/[email protected])([email protected])([email protected])([email protected])':+ '@tanstack/[email protected](@types/[email protected])([email protected])([email protected])([email protected])':dependencies:'@babel/code-frame': 7.26.2'@babel/core': 7.27.1@@ -18941,7 +18956,7 @@ snapshots:'@babel/template': 7.27.2'@babel/traverse': 7.27.1'@babel/types': 7.27.1- '@tanstack/directive-functions-plugin': 1.119.2(@types/[email protected])([email protected])([email protected])([email protected])+ '@tanstack/directive-functions-plugin': 1.119.2(@types/[email protected])([email protected])([email protected])([email protected])babel-dead-code-elimination: 1.0.10dedent: 1.6.0tiny-invariant: 1.3.3@@ -19155,15 +19170,15 @@ snapshots:'@total-typescript/[email protected]': {}optionalDependencies:'@types/node': 20.17.43- zod: 3.25.20+ zod: 3.25.76optionalDependencies:'@types/node': 22.15.17- zod: 3.24.4+ zod: 3.25.76'@tsconfig/[email protected]': {}@@ -19791,7 +19806,7 @@ snapshots:untun: 0.1.3uqr: 0.1.2- '@vinxi/[email protected]([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))':+ '@vinxi/[email protected]([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))':dependencies:'@babel/parser': 7.27.2acorn: 8.14.1@@ -19802,18 +19817,18 @@ snapshots:magicast: 0.2.11recast: 0.23.11tslib: 2.8.1- vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])+ vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])- '@vinxi/[email protected]([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))':+ '@vinxi/[email protected]([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))':dependencies:- '@vinxi/plugin-directives': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))+ '@vinxi/plugin-directives': 0.5.1([email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))acorn: 8.14.1acorn-loose: 8.5.0acorn-typescript: 1.4.13([email protected])astring: 1.9.0magicast: 0.2.11recast: 0.23.11- vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])+ vinxi: 0.5.6(@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])'@virtual-grid/[email protected]': {}@@ -19831,14 +19846,14 @@ snapshots:'@virtual-grid/[email protected]': {}- '@vitejs/[email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected]))':+ '@vitejs/[email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected]))':dependencies:'@babel/core': 7.27.1'@babel/plugin-transform-react-jsx-self': 7.27.1(@babel/[email protected])'@babel/plugin-transform-react-jsx-source': 7.27.1(@babel/[email protected])'@types/babel__core': 7.20.5react-refresh: 0.17.0transitivePeerDependencies:- supports-color@@ -21287,12 +21302,6 @@ snapshots:'@planetscale/database': 1.19.0mysql2: 3.14.1- dependencies:- zod: 3.25.20- optionalDependencies:- '@modelcontextprotocol/sdk': 1.6.1-dependencies:zod: 3.25.76@@ -21752,8 +21761,8 @@ snapshots:eslint: 9.30.1([email protected])eslint-import-resolver-node: 0.3.9- eslint-import-resolver-typescript: 3.10.1([email protected])([email protected]([email protected]))- eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]))+ eslint-import-resolver-typescript: 3.10.1([email protected]([email protected]([email protected])))([email protected]([email protected]))+ eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])))([email protected]([email protected]))eslint-plugin-jsx-a11y: 6.10.2([email protected]([email protected]))eslint-plugin-react: 7.37.5([email protected]([email protected]))eslint-plugin-react-hooks: 4.6.2([email protected]([email protected]))@@ -21781,33 +21790,33 @@ snapshots:transitivePeerDependencies:- supports-color+ [email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])):dependencies:'@nolyfill/is-core-module': 1.0.39debug: 4.4.0([email protected])- eslint: 8.57.1+ eslint: 9.30.1([email protected])get-tsconfig: 4.10.0is-bun-module: 2.0.0stable-hash: 0.0.5tinyglobby: 0.2.13unrs-resolver: 1.7.2optionalDependencies:- eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])+ eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])))([email protected]([email protected]))transitivePeerDependencies:- supports-colordependencies:'@nolyfill/is-core-module': 1.0.39debug: 4.4.0([email protected])- eslint: 9.30.1([email protected])+ eslint: 8.57.1get-tsconfig: 4.10.0is-bun-module: 2.0.0stable-hash: 0.0.5tinyglobby: 0.2.13unrs-resolver: 1.7.2optionalDependencies:- eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]))+ eslint-plugin-import: 2.31.0(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])transitivePeerDependencies:- supports-color@@ -21822,14 +21831,14 @@ snapshots:transitivePeerDependencies:- supports-color- [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected])([email protected]([email protected])):+ [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])))([email protected]([email protected])):dependencies:debug: 3.2.7optionalDependencies:eslint: 9.30.1([email protected])eslint-import-resolver-node: 0.3.9- eslint-import-resolver-typescript: 3.10.1([email protected])([email protected]([email protected]))+ eslint-import-resolver-typescript: 3.10.1([email protected]([email protected]([email protected])))([email protected]([email protected]))transitivePeerDependencies:- supports-color@@ -21873,7 +21882,7 @@ snapshots:- eslint-import-resolver-webpack- supports-color- [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected])):+ [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])))([email protected]([email protected])):dependencies:'@rtsao/scc': 1.1.0array-includes: 3.1.8@@ -21884,7 +21893,7 @@ snapshots:doctrine: 2.1.0eslint: 9.30.1([email protected])eslint-import-resolver-node: 0.3.9- eslint-module-utils: 2.12.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected])([email protected]([email protected]))+ eslint-module-utils: 2.12.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]([email protected]([email protected])))([email protected]([email protected])))([email protected]([email protected]))hasown: 2.0.2is-core-module: 2.16.1is-glob: 4.0.3@@ -26952,16 +26961,16 @@ snapshots:- [email protected](@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))([email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])))([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected](@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))([email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])))([email protected](@types/[email protected])([email protected])([email protected])([email protected])):dependencies:- '@storybook/builder-vite': 9.2.0-alpha.1([email protected]([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ '@storybook/builder-vite': 9.2.0-alpha.2([email protected]([email protected]))([email protected](@types/[email protected])([email protected])([email protected])([email protected]))'@storybook/types': 9.0.0-alpha.1([email protected]([email protected]))magic-string: 0.30.17solid-js: 1.9.6storybook: 8.6.12([email protected])storybook-solidjs: 1.0.0-beta.7(@storybook/[email protected]([email protected]([email protected])))([email protected])([email protected]([email protected]))- vite-plugin-solid: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ vite-plugin-solid: 2.11.6(@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected]))transitivePeerDependencies:- '@storybook/test'@@ -27491,7 +27500,7 @@ snapshots:- [email protected]: {}+ [email protected]: {}optionalDependencies:@@ -27813,11 +27822,11 @@ snapshots:transitivePeerDependencies:- rollup- [email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected])):dependencies:fast-glob: 3.3.3unplugin: 2.0.0-beta.1dependencies:@@ -28027,7 +28036,7 @@ snapshots:'@types/unist': 3.0.3vfile-message: 4.0.2- [email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]):+ [email protected](@planetscale/[email protected])(@types/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected]):dependencies:'@babel/core': 7.27.1'@babel/plugin-syntax-jsx': 7.27.1(@babel/[email protected])@@ -28061,8 +28070,8 @@ snapshots:unctx: 2.4.1unenv: 1.10.0unstorage: 1.16.0(@planetscale/[email protected])([email protected]([email protected](@cloudflare/[email protected])(@opentelemetry/[email protected])(@planetscale/[email protected])([email protected]))([email protected]))([email protected])- zod: 3.25.20+ zod: 3.25.76transitivePeerDependencies:- '@azure/app-configuration'- '@azure/cosmos'@@ -28123,7 +28132,7 @@ snapshots:- supports-color- terser- [email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected](@testing-library/[email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):dependencies:'@babel/core': 7.27.1'@types/babel__core': 7.20.5@@ -28131,31 +28140,31 @@ snapshots:merge-anything: 5.1.7solid-js: 1.9.6solid-refresh: 0.6.3([email protected])- vitefu: 1.0.6([email protected](@types/[email protected])([email protected])([email protected])([email protected]))+ vitefu: 1.0.6([email protected](@types/[email protected])([email protected])([email protected])([email protected]))optionalDependencies:'@testing-library/jest-dom': 6.5.0transitivePeerDependencies:- supports-color- [email protected]([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected]([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):dependencies:debug: 4.4.0([email protected])globrex: 0.1.2tsconfck: 3.1.5([email protected])optionalDependencies:transitivePeerDependencies:- supports-color- typescript- [email protected]([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected]([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])):dependencies:debug: 4.4.0([email protected])globrex: 0.1.2tsconfck: 3.1.5([email protected])optionalDependencies:transitivePeerDependencies:- supports-color- typescript@@ -28170,7 +28179,7 @@ snapshots:fsevents: 2.3.3terser: 5.39.0- [email protected](@types/[email protected])([email protected])([email protected])([email protected]):+ [email protected](@types/[email protected])([email protected])([email protected])([email protected]):dependencies:esbuild: 0.24.2postcss: 8.5.3@@ -28180,9 +28189,9 @@ snapshots:fsevents: 2.3.3jiti: 2.4.2terser: 5.39.0- yaml: 2.8.0+ yaml: 2.8.1- [email protected](@types/[email protected])([email protected])([email protected])([email protected]):+ [email protected](@types/[email protected])([email protected])([email protected])([email protected]):dependencies:esbuild: 0.25.4fdir: 6.4.4([email protected])@@ -28195,9 +28204,9 @@ snapshots:fsevents: 2.3.3jiti: 2.4.2terser: 5.39.0- yaml: 2.8.0+ yaml: 2.8.1- [email protected](@types/[email protected])([email protected])([email protected])([email protected]):+ [email protected](@types/[email protected])([email protected])([email protected])([email protected]):dependencies:esbuild: 0.25.4fdir: 6.4.4([email protected])@@ -28210,11 +28219,11 @@ snapshots:fsevents: 2.3.3jiti: 2.4.2terser: 5.39.0- yaml: 2.8.0+ yaml: 2.8.1- [email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected])):+ [email protected]([email protected](@types/[email protected])([email protected])([email protected])([email protected])):optionalDependencies:dependencies:@@ -28507,6 +28516,8 @@ snapshots:+ [email protected]: {}+@@ -28580,10 +28591,6 @@ snapshots:- [email protected]: {}-- [email protected]: {}-