fix: resolve lint, typecheck, and tsconfig deprecation errors

This commit is contained in:
yiling
2026-06-07 11:10:27 +08:00
parent a7e714c7d0
commit e790df2812
9 changed files with 22 additions and 26 deletions
@@ -363,12 +363,10 @@ export const MessageCard: React.FC<MessageCardProps> = ({
return (
<div className="mt-1 space-y-1.5 pt-3">
{Object.entries(obj).map(([key, value]) => {
let valueStr = ''
if (value && typeof value === 'object') {
valueStr = JSON.stringify(value, null, 2)
} else {
valueStr = String(value)
}
const valueStr =
value && typeof value === 'object'
? JSON.stringify(value, null, 2)
: String(value)
return (
<div key={key} className="text-xs leading-relaxed break-words">
<span className="font-semibold text-violet-600 dark:text-violet-400">
+1 -1
View File
@@ -27,7 +27,7 @@ function UploadTaskItem({ task }: { task: TaskInfo }) {
const isCompleted = task.uploaded === task.total
const percent = task.total > 0 ? (task.uploaded / task.total) * 100 : 0
let formattedTime = ''
let formattedTime: string
try {
formattedTime = formatTimeAgo(task.createdAt)
} catch {