fix: show URL as fallback title when news item has no title
Likes and other untitled feed items showed a blank link. Falls back to item.link in all three views (list, card, expanded) when title is empty or null. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -145,7 +145,7 @@ withSidebar: true
|
|||||||
class="hover:text-accent-600 dark:hover:text-accent-400"
|
class="hover:text-accent-600 dark:hover:text-accent-400"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener"
|
rel="noopener"
|
||||||
x-text="item.title"
|
x-text="item.title || item.link"
|
||||||
></a>
|
></a>
|
||||||
</h2>
|
</h2>
|
||||||
<p x-show="item.description" class="text-sm text-surface-600 dark:text-surface-400 line-clamp-2 mb-2" x-text="item.description"></p>
|
<p x-show="item.description" class="text-sm text-surface-600 dark:text-surface-400 line-clamp-2 mb-2" x-text="item.description"></p>
|
||||||
@@ -211,7 +211,7 @@ withSidebar: true
|
|||||||
class="hover:text-accent-600 dark:hover:text-accent-400"
|
class="hover:text-accent-600 dark:hover:text-accent-400"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener"
|
rel="noopener"
|
||||||
x-text="item.title"
|
x-text="item.title || item.link"
|
||||||
></a>
|
></a>
|
||||||
</h2>
|
</h2>
|
||||||
<p x-show="item.description" class="text-sm text-surface-600 dark:text-surface-400 line-clamp-3 mb-3" x-text="item.description"></p>
|
<p x-show="item.description" class="text-sm text-surface-600 dark:text-surface-400 line-clamp-3 mb-3" x-text="item.description"></p>
|
||||||
@@ -278,7 +278,7 @@ withSidebar: true
|
|||||||
class="hover:text-accent-600 dark:hover:text-accent-400"
|
class="hover:text-accent-600 dark:hover:text-accent-400"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener"
|
rel="noopener"
|
||||||
x-text="item.title"
|
x-text="item.title || item.link"
|
||||||
></a>
|
></a>
|
||||||
</h2>
|
</h2>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user