refactor: 优化 Dashboard 布局及 ToolCard 描述文本截断处理
This commit is contained in:
@@ -74,7 +74,7 @@ export default function ToolCard({
|
||||
{title}
|
||||
</h4>
|
||||
{description && (
|
||||
<p className="text-[11px] font-medium text-muted-foreground/90 mt-0.5 leading-normal break-words">
|
||||
<p className="text-[11px] font-medium text-muted-foreground/90 mt-0.5 leading-normal w-full truncate">
|
||||
{description}
|
||||
</p>
|
||||
)}
|
||||
|
||||
@@ -13,13 +13,9 @@ export default function DashboardPage() {
|
||||
const visibleSet = useMemo(() => new Set<string>(visiblePages), [visiblePages]);
|
||||
|
||||
return (
|
||||
/* 💡 核心修复点:
|
||||
- 彻底移除限制死高度的 auto-rows-fr,换用弹性自适应的 auto-rows-auto。
|
||||
- 将 gap-2 / p-2 扩展为标准的 gap-3.5 / p-3.5,彻底消灭挤压颤噪。
|
||||
*/
|
||||
<div
|
||||
className={cn(
|
||||
'grid grid-cols-1 sm:grid-cols-[repeat(auto-fill,minmax(290px,1fr))] auto-rows-auto gap-3.5 p-3.5 w-full h-full',
|
||||
'grid grid-cols-1 sm:grid-cols-[repeat(auto-fill,minmax(290px,1fr))] auto-rows-auto gap-3.5 p-3.5 w-full h-auto',
|
||||
'animate-in fade-in duration-300 select-none',
|
||||
)}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user