From 154efe17421ca96d433fcc1f820ad460e1675bdc Mon Sep 17 00:00:00 2001 From: Mohamed Bassem Date: Sat, 26 Jul 2025 12:58:01 +0000 Subject: feat: Configurable number of grid columns. Fixes #1713 --- apps/web/components/dashboard/ChangeLayout.tsx | 64 -------------------------- 1 file changed, 64 deletions(-) delete mode 100644 apps/web/components/dashboard/ChangeLayout.tsx (limited to 'apps/web/components/dashboard/ChangeLayout.tsx') diff --git a/apps/web/components/dashboard/ChangeLayout.tsx b/apps/web/components/dashboard/ChangeLayout.tsx deleted file mode 100644 index c7f44a73..00000000 --- a/apps/web/components/dashboard/ChangeLayout.tsx +++ /dev/null @@ -1,64 +0,0 @@ -"use client"; - -import React from "react"; -import { ButtonWithTooltip } from "@/components/ui/button"; -import { - DropdownMenu, - DropdownMenuContent, - DropdownMenuItem, - DropdownMenuTrigger, -} from "@/components/ui/dropdown-menu"; -import { useTranslation } from "@/lib/i18n/client"; -import { useBookmarkLayout } from "@/lib/userLocalSettings/bookmarksLayout"; -import { updateBookmarksLayout } from "@/lib/userLocalSettings/userLocalSettings"; -import { - Check, - LayoutDashboard, - LayoutGrid, - LayoutList, - List, - LucideIcon, -} from "lucide-react"; - -type LayoutType = "masonry" | "grid" | "list" | "compact"; - -const iconMap: Record = { - masonry: LayoutDashboard, - grid: LayoutGrid, - list: LayoutList, - compact: List, -}; - -export default function ChangeLayout() { - const { t } = useTranslation(); - const layout = useBookmarkLayout(); - - return ( - - - - {React.createElement(iconMap[layout], { size: 18 })} - - - - {(Object.keys(iconMap) as LayoutType[]).map((key) => ( - await updateBookmarksLayout(key as LayoutType)} - > -
- {React.createElement(iconMap[key as LayoutType], { size: 18 })} - {t(`layouts.${key}`)} -
- {layout == key && } -
- ))} -
-
- ); -} -- cgit v1.2.3-70-g09d2