From e4db9bf2725f1714f273332f0a444ec940aae1a8 Mon Sep 17 00:00:00 2001 From: Mohamed Bassem Date: Sun, 23 Nov 2025 11:21:22 +0000 Subject: fix: Hide shared lists where user is a viewer in Manage Lists dialog (#2164) Users with viewer role cannot add/remove bookmarks from lists, so these lists should not appear in the Manage Lists dialog across all platforms (web, mobile, and extension). Changes: - Web: Updated BookmarkListSelector to filter out viewer lists - Mobile: Updated manage_lists.tsx to filter out viewer lists - Extension: Updated ListsSelector to filter out viewer lists Co-authored-by: Claude --- .../src/components/ListsSelector.tsx | 50 +++++++++++----------- 1 file changed, 26 insertions(+), 24 deletions(-) (limited to 'apps/browser-extension') diff --git a/apps/browser-extension/src/components/ListsSelector.tsx b/apps/browser-extension/src/components/ListsSelector.tsx index 379338b6..86c151d1 100644 --- a/apps/browser-extension/src/components/ListsSelector.tsx +++ b/apps/browser-extension/src/components/ListsSelector.tsx @@ -74,31 +74,33 @@ export function ListsSelector({ bookmarkId }: { bookmarkId: string }) { You don't have any lists. - {allLists?.allPaths.map((path) => { - const lastItem = path[path.length - 1]; + {allLists?.allPaths + .filter((path) => path[path.length - 1].userRole !== "viewer") + .map((path) => { + const lastItem = path[path.length - 1]; - return ( - - - {path - .map((item) => `${item.icon} ${item.name}`) - .join(" / ")} - - ); - })} + return ( + + + {path + .map((item) => `${item.icon} ${item.name}`) + .join(" / ")} + + ); + })} -- cgit v1.2.3-70-g09d2