From f2422e96013fca78fdc54f50fd29d28b529e4741 Mon Sep 17 00:00:00 2001 From: Gigi Date: Sun, 5 Oct 2025 21:54:02 +0100 Subject: [PATCH] feat(highlights): color sidebar highlight items by level (mine/friends/nostrverse) --- src/components/HighlightItem.tsx | 8 ++++++-- src/index.css | 16 ++++++++++++++++ 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/src/components/HighlightItem.tsx b/src/components/HighlightItem.tsx index 8feaeee2..206c1b82 100644 --- a/src/components/HighlightItem.tsx +++ b/src/components/HighlightItem.tsx @@ -4,8 +4,12 @@ import { faQuoteLeft, faLink, faExternalLinkAlt } from '@fortawesome/free-solid- import { Highlight } from '../types/highlights' import { formatDistanceToNow } from 'date-fns' +interface HighlightWithLevel extends Highlight { + level?: 'mine' | 'friends' | 'nostrverse' +} + interface HighlightItemProps { - highlight: Highlight + highlight: HighlightWithLevel onSelectUrl?: (url: string) => void isSelected?: boolean onHighlightClick?: (highlightId: string) => void @@ -45,7 +49,7 @@ export const HighlightItem: React.FC = ({ highlight, onSelec return (