home(feed): drop LEGACY category label, vertical separator, and Imported source badge

The article-row metadata strip rendered three things side-by-side:
  {category} | <SourceBadge source>

For imported WP posts whose `category` column was the placeholder string
"legacy", this produced a meaningless "LEGACY | IMPORTED" row on the
homepage. Now:

- Hide the category text entirely when value is "legacy" (any case);
  it falls back to nothing while the AI-derived category propagates
  in a separate data pass.
- Drop the vertical pipe separator.
- Remove the yellow "IMPORTED" SourceBadge — the article's category
  is the user-relevant signal, not its data-source provenance.

The SourceBadge function is now unused and removed. The source-filter
control in the advanced filters panel is unchanged.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ryan Salazar
2026-05-18 20:01:46 +00:00
parent 83579523d1
commit fe0edf5c02

View File

@@ -52,23 +52,6 @@ function parseArticleDate(dateStr: string): Date | null {
return isNaN(d.getTime()) ? null : d;
}
function SourceBadge({ source }: { source: "live" | "imported" }) {
if (source === "imported") {
return (
<span className="inline-flex items-center gap-1 px-1.5 py-0.5 rounded-sm text-[9px] font-bold uppercase tracking-wide bg-amber-500/15 text-amber-400 border border-amber-500/30">
<span className="w-1 h-1 rounded-full bg-amber-400 inline-block" />
Imported
</span>
);
}
return (
<span className="inline-flex items-center gap-1 px-1.5 py-0.5 rounded-sm text-[9px] font-bold uppercase tracking-wide bg-emerald-500/15 text-emerald-400 border border-emerald-500/30">
<span className="w-1 h-1 rounded-full bg-emerald-400 inline-block" />
Live
</span>
);
}
export default function ArticleFeed() {
const [page, setPage] = useState(1);
const [searchQuery, setSearchQuery] = useState("");
@@ -609,11 +592,11 @@ export default function ArticleFeed() {
</Link>
<div className="flex-1 min-w-0">
<div className="flex items-center gap-1.5 md:gap-2 mb-1 md:mb-1.5 flex-wrap">
<span className="font-body text-[10px] font-bold text-[#3b82f6] uppercase tracking-wide">
{article?.category}
</span>
<span className="text-[#444] text-xs hidden sm:inline">|</span>
<SourceBadge source={article.source} />
{article?.category && article.category.toLowerCase() !== "legacy" && (
<span className="font-body text-[10px] font-bold text-[#3b82f6] uppercase tracking-wide">
{article.category}
</span>
)}
</div>
<h3 className="font-heading text-[#e0e0e0] font-bold text-[0.875rem] md:text-[1rem] leading-snug mb-1 md:mb-1.5 group-hover:text-[#3b82f6] transition-colors duration-200 line-clamp-2">
<Link