feat(bookmarks): add sticky note icon for text-only bookmarks without URLs

This commit is contained in:
Gigi
2025-10-15 14:20:28 +02:00
parent 838bb6aa3d
commit b2b23c66cf

View File

@@ -1,5 +1,5 @@
import React, { useState } from 'react'
import { faBookOpen, faPlay, faEye, faNewspaper, faGlobe } from '@fortawesome/free-solid-svg-icons'
import { faBookOpen, faPlay, faEye, faNewspaper, faGlobe, faStickyNote } from '@fortawesome/free-solid-svg-icons'
import { IconDefinition } from '@fortawesome/fontawesome-svg-core'
import { useEventModel } from 'applesauce-react/hooks'
import { Models } from 'applesauce-core'
@@ -71,6 +71,7 @@ export const BookmarkItem: React.FC<BookmarkItemProps> = ({ bookmark, index, onS
const getContentTypeIcon = (): IconDefinition => {
if (isArticle) return faNewspaper
if (isWebBookmark) return faGlobe
if (!hasUrls) return faStickyNote // Just a text note
if (firstUrlClassification?.type === 'youtube' || firstUrlClassification?.type === 'video') return faPlay
return faBookOpen
}