feat: 支持评分字段的导入
This commit is contained in:
@@ -6,9 +6,9 @@ import { Pencil, Trash2 } from 'lucide-react'
|
||||
import Image from 'next/image'
|
||||
|
||||
// 列宽定义,header 和 row 必须保持一致。用 grid-template-columns 统一控制。
|
||||
// 序号 | 图片 | 答案 | 谐音梗 | 提示 | 创建时间 | 操作
|
||||
// 序号 | 图片 | 答案 | 谐音梗 | 提示 | 创建时间 | 评分 | 操作
|
||||
export const GRID_TEMPLATE =
|
||||
'minmax(60px,60px) minmax(120px,120px) minmax(80px,1fr) minmax(100px,1fr) minmax(160px,2fr) minmax(100px,100px) minmax(100px,100px)'
|
||||
'minmax(60px,60px) minmax(120px,120px) minmax(80px,1fr) minmax(100px,1fr) minmax(160px,2fr) minmax(100px,100px) minmax(110px,110px) minmax(100px,100px)'
|
||||
|
||||
interface LevelRowProps {
|
||||
level: Level
|
||||
@@ -91,6 +91,13 @@ export function LevelRow({ level, index, onEdit, onDelete }: LevelRowProps) {
|
||||
})}
|
||||
</span>
|
||||
|
||||
{/* 评分 */}
|
||||
<span className="text-xs text-muted-foreground whitespace-nowrap">
|
||||
{level.difficultyScore != null || level.funScore != null
|
||||
? `难度 ${level.difficultyScore ?? '-'} · 有趣 ${level.funScore ?? '-'}`
|
||||
: '—'}
|
||||
</span>
|
||||
|
||||
{/* 操作 */}
|
||||
<div className="flex items-center gap-2">
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user