feat: remove type icon from medium-sized bookmark cards

- Remove contentTypeIcon from CardViewProps interface
- Remove type icon display from bookmark footer
- Replace contentTypeIcon with faLink in thumbnail placeholder
- Simplify card interface by removing content type indicator
- Clean up unused icon-related code
This commit is contained in:
Gigi
2025-10-25 01:45:29 +02:00
parent e12aaa2b6c
commit e12d67cc5f

View File

@@ -1,7 +1,7 @@
import React, { useState } from 'react' import React, { useState } from 'react'
import { Link } from 'react-router-dom' import { Link } from 'react-router-dom'
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome' import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
import { IconDefinition } from '@fortawesome/fontawesome-svg-core' import { faLink } from '@fortawesome/free-solid-svg-icons'
import { IndividualBookmark } from '../../types/bookmarks' import { IndividualBookmark } from '../../types/bookmarks'
import { formatDate, renderParsedContent } from '../../utils/bookmarkUtils' import { formatDate, renderParsedContent } from '../../utils/bookmarkUtils'
import RichContent from '../RichContent' import RichContent from '../RichContent'
@@ -22,7 +22,6 @@ interface CardViewProps {
articleImage?: string articleImage?: string
articleSummary?: string articleSummary?: string
articleTitle?: string articleTitle?: string
contentTypeIcon: IconDefinition
readingProgress?: number readingProgress?: number
} }
@@ -38,7 +37,6 @@ export const CardView: React.FC<CardViewProps> = ({
articleImage, articleImage,
articleSummary, articleSummary,
articleTitle, articleTitle,
contentTypeIcon,
readingProgress readingProgress
}) => { }) => {
const firstUrl = hasUrls ? extractedUrls[0] : null const firstUrl = hasUrls ? extractedUrls[0] : null
@@ -124,7 +122,7 @@ export const CardView: React.FC<CardViewProps> = ({
> >
{!cachedImage && firstUrl && ( {!cachedImage && firstUrl && (
<div className="thumbnail-placeholder"> <div className="thumbnail-placeholder">
<FontAwesomeIcon icon={contentTypeIcon} /> <FontAwesomeIcon icon={faLink} />
</div> </div>
)} )}
</div> </div>
@@ -191,9 +189,6 @@ export const CardView: React.FC<CardViewProps> = ({
) : ( ) : (
<span className="bookmark-date">{formatDate(bookmark.created_at ?? bookmark.listUpdatedAt)}</span> <span className="bookmark-date">{formatDate(bookmark.created_at ?? bookmark.listUpdatedAt)}</span>
)} )}
<span className="bookmark-type">
<FontAwesomeIcon icon={contentTypeIcon} className="content-type-icon" />
</span>
</div> </div>
</div> </div>
</div> </div>