From 75cc0425bab62c3436a4538514b642b463368b41 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 17 Dec 2025 06:18:24 +0000 Subject: [PATCH 1/2] Replace Geist font with system font stack - Remove Geist font import and configuration from layout.tsx - Add system font family configuration in tailwind.config.js --- app/layout.tsx | 8 +------- tailwind.config.js | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/app/layout.tsx b/app/layout.tsx index 1092242..332eea6 100644 --- a/app/layout.tsx +++ b/app/layout.tsx @@ -1,16 +1,10 @@ import { ClerkProvider } from "@clerk/nextjs"; import { Analytics } from "@vercel/analytics/next"; -import { Geist } from "next/font/google"; import { ThemeProvider } from "@/components/core/theme-provider"; import { Toaster } from "@/components/ui/sonner"; import { SITE_METADATA } from "@/data/marketing"; -import { cn } from "@/lib/utils"; import "./globals.css"; -const mainFont = Geist({ - subsets: ["latin"], -}); - export const metadata = { metadataBase: new URL( process.env.NEXT_PUBLIC_APP_URL || "https://managee.xyz", @@ -85,7 +79,7 @@ export default function RootLayout({ return ( diff --git a/tailwind.config.js b/tailwind.config.js index 3211955..d36a511 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -15,6 +15,23 @@ module.exports = { "2xl": "1400px", }, }, + fontFamily: { + sans: [ + "system-ui", + "-apple-system", + "BlinkMacSystemFont", + "Segoe UI", + "Roboto", + "Helvetica Neue", + "Arial", + "Noto Sans", + "sans-serif", + "Apple Color Emoji", + "Segoe UI Emoji", + "Segoe UI Symbol", + "Noto Color Emoji", + ], + }, extend: { colors: { gray: "neutral", From 0c5912873f69eed9aa1b8aa722f21b7c85e2592e Mon Sep 17 00:00:00 2001 From: Arjun Komath Date: Thu, 18 Dec 2025 12:50:30 +1100 Subject: [PATCH 2/2] Use url state for task panel and showing deleted --- .../tasklists/[tasklistId]/page.tsx | 7 +++++++ components/core/panel.tsx | 6 ++++++ .../project/tasklist/task/task-item.tsx | 20 ++++++++++++++----- components/project/tasklist/tasklist.tsx | 7 +++++-- lib/utils/mentionNotifications.ts | 5 +++-- trpc/routers/tasks.ts | 2 ++ 6 files changed, 38 insertions(+), 9 deletions(-) diff --git a/app/(dashboard)/[tenant]/projects/[projectId]/tasklists/[tasklistId]/page.tsx b/app/(dashboard)/[tenant]/projects/[projectId]/tasklists/[tasklistId]/page.tsx index 59f74d2..3d6185f 100644 --- a/app/(dashboard)/[tenant]/projects/[projectId]/tasklists/[tasklistId]/page.tsx +++ b/app/(dashboard)/[tenant]/projects/[projectId]/tasklists/[tasklistId]/page.tsx @@ -15,9 +15,14 @@ import { toStartOfDay } from "@/lib/utils/date"; import { useTRPC } from "@/trpc/client"; import { useQueries } from "@tanstack/react-query"; import { useParams } from "next/navigation"; +import { parseAsBoolean, useQueryState } from "nuqs"; export default function TaskLists() { const { projectId, tasklistId } = useParams(); + const [showDeleted, setShowDeleted] = useQueryState( + "showDeleted", + parseAsBoolean.withDefault(false), + ); const trpc = useTRPC(); const [{ data: list }, { data: timezone }, { data: project }] = useQueries({ @@ -127,6 +132,8 @@ export default function TaskLists() { id={list.id} hideHeader canEdit={project.canEdit} + showDeleted={showDeleted} + onShowDeletedChange={setShowDeleted} /> diff --git a/components/core/panel.tsx b/components/core/panel.tsx index c792c39..7cc2ab3 100644 --- a/components/core/panel.tsx +++ b/components/core/panel.tsx @@ -1,6 +1,7 @@ "use client"; import * as Dialog from "@radix-ui/react-dialog"; +import { VisuallyHidden } from "@radix-ui/react-visually-hidden"; import { memo } from "react"; import { useIsMobile } from "@/hooks/use-mobile"; import { cn } from "@/lib/utils"; @@ -10,11 +11,13 @@ export const Panel = memo(function Panel({ setOpen, children, className, + title = "Panel", }: { open: boolean; setOpen?: (open: boolean) => void; children: React.ReactNode; className?: string; + title?: string; }) { const isMobile = useIsMobile(); @@ -31,6 +34,9 @@ export const Panel = memo(function Panel({ className, )} > + + {title} + {children} diff --git a/components/project/tasklist/task/task-item.tsx b/components/project/tasklist/task/task-item.tsx index 09230dd..bc3faab 100644 --- a/components/project/tasklist/task/task-item.tsx +++ b/components/project/tasklist/task/task-item.tsx @@ -6,7 +6,8 @@ import { Close, Title } from "@radix-ui/react-dialog"; import { useQueries } from "@tanstack/react-query"; import { AlignJustifyIcon, CalendarClock, FileIcon, X } from "lucide-react"; import { useParams } from "next/navigation"; -import { useMemo, useState } from "react"; +import { parseAsInteger, useQueryState } from "nuqs"; +import { useMemo } from "react"; import { toast } from "sonner"; import { Panel } from "@/components/core/panel"; import { ConfirmButton } from "@/components/form/button"; @@ -44,7 +45,11 @@ export const TaskItem = ({ canEdit?: boolean; }) => { const { projectId } = useParams(); - const [detailsOpen, setDetailsOpen] = useState(false); + const [selectedTaskId, setSelectedTaskId] = useQueryState( + "task", + parseAsInteger, + ); + const detailsOpen = selectedTaskId === task.id; const { attributes, listeners, setNodeRef, transform, transition } = useSortable({ id: task.id }); @@ -113,7 +118,7 @@ export const TaskItem = ({ creating ? "text-muted-foreground" : "", )} onClick={() => { - if (!creating) setDetailsOpen(true); + if (!creating) setSelectedTaskId(task.id); }} >
- + { + if (!open) setSelectedTaskId(null); + }} + > <div className="flex items-center px-4 h-14 border-b"> <div className="flex items-center flex-1"> @@ -372,7 +382,7 @@ export const TaskItem = ({ "Error while copying, please try again.", }, ); - setDetailsOpen(false); + setSelectedTaskId(null); }} > <button diff --git a/components/project/tasklist/tasklist.tsx b/components/project/tasklist/tasklist.tsx index bf31f22..2025883 100644 --- a/components/project/tasklist/tasklist.tsx +++ b/components/project/tasklist/tasklist.tsx @@ -31,11 +31,15 @@ export const TaskListItem = ({ hideHeader = false, compact = false, canEdit = true, + showDeleted, + onShowDeletedChange, }: { id: number; hideHeader?: boolean; compact?: boolean; canEdit?: boolean; + showDeleted?: boolean; + onShowDeletedChange?: (showDeleted: boolean) => void; }) => { const trpc = useTRPC(); const { data: taskList, isLoading } = useQuery( @@ -63,7 +67,6 @@ export const TaskListItem = ({ [taskList?.tasks], ); - const [showDeleted, setShowDeleted] = useState(false); const deletedItems = useMemo( () => taskList?.tasks.filter((task) => task.status === TaskStatus.DELETED) ?? @@ -204,7 +207,7 @@ export const TaskListItem = ({ <Button variant="ghost" size="sm" - onClick={() => setShowDeleted((x) => !x)} + onClick={() => onShowDeletedChange?.(!showDeleted)} > {showDeleted ? "Hide" : "Show"} </Button> diff --git a/lib/utils/mentionNotifications.ts b/lib/utils/mentionNotifications.ts index a4143e0..4373940 100644 --- a/lib/utils/mentionNotifications.ts +++ b/lib/utils/mentionNotifications.ts @@ -8,7 +8,8 @@ interface MentionContext { type: "project" | "task" | "tasklist" | "event" | "comment" | "post"; entityName: string; entityId: number; - projectId?: number; // For linking back to project + projectId?: number; + taskListId?: number; orgSlug: string; fromUserId: string; } @@ -47,7 +48,7 @@ export async function sendMentionNotifications( case "task": message = `${fromUserName} mentioned you in task "${context.entityName}"`; - target = `/${context.orgSlug}/projects/${context.projectId}`; + target = `/${context.orgSlug}/projects/${context.projectId}/tasklists/${context.taskListId}?task=${context.entityId}`; break; case "tasklist": diff --git a/trpc/routers/tasks.ts b/trpc/routers/tasks.ts index 6a2b976..d5ddb1c 100644 --- a/trpc/routers/tasks.ts +++ b/trpc/routers/tasks.ts @@ -331,6 +331,7 @@ export const tasksRouter = createTRPCRouter({ entityName: input.name || "Untitled Task", entityId: createdTask[0].id, projectId: taskListDetails.projectId, + taskListId: input.taskListId, orgSlug: ctx.orgSlug, fromUserId: ctx.userId, }); @@ -447,6 +448,7 @@ export const tasksRouter = createTRPCRouter({ entityName: oldTask.name, entityId: input.id, projectId: oldTask.taskList.projectId, + taskListId: oldTask.taskListId, orgSlug: ctx.orgSlug, fromUserId: ctx.userId, });