From cd632f295d896100207e1b02bfeb574175c07633 Mon Sep 17 00:00:00 2001 From: Mohamed Bassem Date: Sun, 20 Apr 2025 23:49:24 +0000 Subject: ui(web): Reduce shadows, lighten some fonts, and a smaller editor. #1261 --- apps/browser-extension/package.json | 2 +- apps/landing/package.json | 2 +- .../bookmarks/BookmarkLayoutAdaptingCard.tsx | 8 ++--- .../components/dashboard/bookmarks/EditorCard.tsx | 13 ++++--- .../web/components/dashboard/bookmarks/TagList.tsx | 4 +-- .../components/dashboard/search/SearchInput.tsx | 2 ++ apps/web/components/dashboard/sidebar/AllLists.tsx | 6 ++-- apps/web/components/ui/info-tooltip.tsx | 2 +- apps/web/components/ui/input.tsx | 42 ++++++++++++++++------ apps/web/lib/i18n/locales/en/translation.json | 1 + apps/web/package.json | 2 +- pnpm-lock.yaml | 20 +++++------ 12 files changed, 67 insertions(+), 37 deletions(-) diff --git a/apps/browser-extension/package.json b/apps/browser-extension/package.json index 2f4dd7f7..8a6a66b8 100644 --- a/apps/browser-extension/package.json +++ b/apps/browser-extension/package.json @@ -30,7 +30,7 @@ "class-variance-authority": "^0.7.0", "clsx": "^2.1.0", "cmdk": "^1.0.0", - "lucide-react": "^0.330.0", + "lucide-react": "^0.501.0", "react": "^18.3.1", "react-dom": "^18.3.1", "react-router-dom": "^6.22.0", diff --git a/apps/landing/package.json b/apps/landing/package.json index 4d231443..b097ec72 100644 --- a/apps/landing/package.json +++ b/apps/landing/package.json @@ -19,7 +19,7 @@ "@svgr/webpack": "^8.1.0", "class-variance-authority": "^0.7.0", "clsx": "^2.1.0", - "lucide-react": "^0.330.0", + "lucide-react": "^0.501.0", "react": "^18.3.1", "react-dom": "^18.3.1", "react-select": "^5.8.0", diff --git a/apps/web/components/dashboard/bookmarks/BookmarkLayoutAdaptingCard.tsx b/apps/web/components/dashboard/bookmarks/BookmarkLayoutAdaptingCard.tsx index be061148..a0437c71 100644 --- a/apps/web/components/dashboard/bookmarks/BookmarkLayoutAdaptingCard.tsx +++ b/apps/web/components/dashboard/bookmarks/BookmarkLayoutAdaptingCard.tsx @@ -46,7 +46,7 @@ function BottomRow({ }) { return (
-
+
{footer && <>{footer}•} @@ -167,7 +167,7 @@ function GridView({ return (
{ if (demoMode) { return; @@ -218,7 +218,12 @@ export default function EditorCard({ className }: { className?: string }) { /> - + {form.formState.dirtyFields.text ? demoMode ? t("editor.disabled_submissions") diff --git a/apps/web/components/dashboard/bookmarks/TagList.tsx b/apps/web/components/dashboard/bookmarks/TagList.tsx index 49a1156c..593a269b 100644 --- a/apps/web/components/dashboard/bookmarks/TagList.tsx +++ b/apps/web/components/dashboard/bookmarks/TagList.tsx @@ -29,8 +29,8 @@ export default function TagList({ diff --git a/apps/web/components/dashboard/search/SearchInput.tsx b/apps/web/components/dashboard/search/SearchInput.tsx index 5e46fc18..c58542bf 100644 --- a/apps/web/components/dashboard/search/SearchInput.tsx +++ b/apps/web/components/dashboard/search/SearchInput.tsx @@ -6,6 +6,7 @@ import { Input } from "@/components/ui/input"; import { useDoBookmarkSearch } from "@/lib/hooks/bookmark-search"; import { useTranslation } from "@/lib/i18n/client"; import { cn } from "@/lib/utils"; +import { SearchIcon } from "lucide-react"; import { EditListModal } from "../lists/EditListModal"; import QueryExplainerTooltip from "./QueryExplainerTooltip"; @@ -99,6 +100,7 @@ const SearchInput = React.forwardRef< )} -
  • +
  • Lists

    - +
  • diff --git a/apps/web/components/ui/info-tooltip.tsx b/apps/web/components/ui/info-tooltip.tsx index 0254aa80..4dd97199 100644 --- a/apps/web/components/ui/info-tooltip.tsx +++ b/apps/web/components/ui/info-tooltip.tsx @@ -23,7 +23,7 @@ export default function InfoTooltip({ {variant === "tip" ? ( ) : ( diff --git a/apps/web/components/ui/input.tsx b/apps/web/components/ui/input.tsx index 5543446c..09f9def9 100644 --- a/apps/web/components/ui/input.tsx +++ b/apps/web/components/ui/input.tsx @@ -1,20 +1,42 @@ import * as React from "react"; import { cn } from "@/lib/utils"; +import { LucideIcon } from "lucide-react"; -export type InputProps = React.InputHTMLAttributes; +export interface InputProps + extends React.InputHTMLAttributes { + startIcon?: LucideIcon; + endIcon?: LucideIcon; +} const Input = React.forwardRef( - ({ className, type, ...props }, ref) => { + ({ className, type, startIcon, endIcon, ...props }, ref) => { + const StartIcon = startIcon; + const EndIcon = endIcon; + return ( - + {StartIcon && ( +
    + +
    + )} + + {EndIcon && ( +
    + +
    )} - ref={ref} - {...props} - /> +
    ); }, ); diff --git a/apps/web/lib/i18n/locales/en/translation.json b/apps/web/lib/i18n/locales/en/translation.json index 4e622df5..1d99a96f 100644 --- a/apps/web/lib/i18n/locales/en/translation.json +++ b/apps/web/lib/i18n/locales/en/translation.json @@ -298,6 +298,7 @@ "import_as_text": "Import as Text Bookmark", "import_as_separate_bookmarks": "Import as separate Bookmarks", "placeholder": "Paste a link or an image, write a note or drag and drop an image in here…", + "placeholder_v2": "Paste a link, write a note or drop an image…", "new_item": "NEW ITEM", "disabled_submissions": "Submissions are disabled", "text_toolbar": { diff --git a/apps/web/package.json b/apps/web/package.json index 1b26b183..34e4752a 100644 --- a/apps/web/package.json +++ b/apps/web/package.json @@ -64,7 +64,7 @@ "i18next": "^23.16.5", "i18next-resources-to-backend": "^1.2.1", "lexical": "^0.20.2", - "lucide-react": "^0.330.0", + "lucide-react": "^0.501.0", "next": "14.2.25", "next-auth": "^4.24.5", "next-i18next": "^15.3.1", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 9dac1f20..6c077304 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -95,8 +95,8 @@ importers: specifier: ^1.0.0 version: 1.0.0(@types/react-dom@18.2.19)(@types/react@18.2.58)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) lucide-react: - specifier: ^0.330.0 - version: 0.330.0(react@18.3.1) + specifier: ^0.501.0 + version: 0.501.0(react@18.3.1) react: specifier: ^18.3.1 version: 18.3.1 @@ -234,8 +234,8 @@ importers: specifier: ^2.1.0 version: 2.1.0 lucide-react: - specifier: ^0.330.0 - version: 0.330.0(react@18.3.1) + specifier: ^0.501.0 + version: 0.501.0(react@18.3.1) react: specifier: ^18.3.1 version: 18.3.1 @@ -645,8 +645,8 @@ importers: specifier: ^0.20.2 version: 0.20.2 lucide-react: - specifier: ^0.330.0 - version: 0.330.0(react@18.3.1) + specifier: ^0.501.0 + version: 0.501.0(react@18.3.1) next: specifier: 14.2.25 version: 14.2.25(@babel/core@7.26.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -10445,10 +10445,10 @@ packages: react-native: '*' react-native-svg: ^12.0.0 || ^13.0.0 || ^14.0.0 || ^15.0.0 - lucide-react@0.330.0: - resolution: {integrity: sha512-CQwY+Fpbt2kxCoVhuN0RCZDCYlbYnqB870Bl/vIQf3ER/cnDDQ6moLmEkguRyruAUGd4j3Lc4mtnJosXnqHheA==} + lucide-react@0.501.0: + resolution: {integrity: sha512-E2KoyhW59fCb/yUbR3rbDer83fqn7a8NG91ZhIot2yWaPHjPyGzzsNKh40N//GezYShAuycf3TcQksRQznIsRw==} peerDependencies: - react: ^16.5.1 || ^17.0.0 || ^18.0.0 + react: ^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0 magic-string@0.25.9: resolution: {integrity: sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==} @@ -27995,7 +27995,7 @@ snapshots: react-native-svg: 15.8.0(react-native@0.76.3(@babel/core@7.26.0)(@babel/preset-env@7.26.9(@babel/core@7.26.0))(@types/react@18.3.12)(react@18.3.1))(react@18.3.1) dev: false - lucide-react@0.330.0(react@18.3.1): + lucide-react@0.501.0(react@18.3.1): dependencies: react: 18.3.1 dev: false -- cgit v1.2.3-70-g09d2