2025.11.27.17.50

This commit is contained in:
RUI
2025-11-27 17:50:44 +08:00
commit 5dbb30b32c
111 changed files with 18320 additions and 0 deletions

View File

@@ -0,0 +1,57 @@
import React from 'react';
import { Button } from '@/components/ui/button';
import { Badge } from '@/components/ui/badge';
import Link from 'next/link';
interface SidebarProps {
tags: any[];
}
export default function Sidebar({ tags }: SidebarProps) {
return (
<div className="space-y-8">
{/* Hot Tags */}
<div>
<h3 className="font-bold text-gray-900 mb-4 flex items-center gap-2">
<span className="w-1 h-4 bg-primary rounded-full"></span>
</h3>
<div className="flex flex-wrap gap-2">
{tags.map((tag) => (
<Link key={tag._id} href={`/?tag=${tag._id}`}>
<Badge variant="secondary" className="hover:bg-gray-200 cursor-pointer font-normal px-3 py-1">
{tag.}
</Badge>
</Link>
))}
</div>
</div>
{/* Recommended (Static for now) */}
<div>
<h3 className="font-bold text-gray-900 mb-4 flex items-center gap-2">
<span className="w-1 h-4 bg-primary rounded-full"></span>
</h3>
<div className="space-y-4">
{[1, 2, 3].map((i) => (
<div key={i} className="group cursor-pointer">
<div className="flex items-start gap-3">
<span className={`text-2xl font-bold transition-colors ${i === 1 ? 'text-gray-900' :
i === 2 ? 'text-gray-500' :
'text-gray-300'
}`}>0{i}</span>
<div>
<h4 className="text-sm font-medium text-gray-900 group-hover:text-primary transition-colors line-clamp-2">
2025 Micro-Frontends Islands Architecture
</h4>
<p className="text-xs text-gray-400 mt-1">12 min read</p>
</div>
</div>
</div>
))}
</div>
</div>
</div>
);
}