refactor(ui): [UI8] 彻底移除遗留Card并补充下拉框中文化
这个提交包含在:
@@ -1,13 +1,12 @@
|
||||
import { Skeleton } from "../ui/skeleton";
|
||||
import { Card } from "../ui/card";
|
||||
|
||||
export function CardSkeleton({ lines = 6 }: { lines?: number }) {
|
||||
return (
|
||||
<Card className="space-y-3 p-6">
|
||||
<div className="card-std space-y-3 p-6">
|
||||
<Skeleton className="h-5 w-48" />
|
||||
{Array.from({ length: lines }, (_, i) => (
|
||||
<Skeleton key={i} className="h-4 w-full" />
|
||||
))}
|
||||
</Card>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { Component, type ErrorInfo, type ReactNode } from "react";
|
||||
import { Card } from "../ui/card";
|
||||
|
||||
type Props = {
|
||||
children: ReactNode;
|
||||
@@ -32,7 +31,7 @@ export class ErrorBoundary extends Component<Props, State> {
|
||||
}
|
||||
|
||||
return (
|
||||
<Card className="mx-auto mt-12 max-w-lg space-y-4 p-6 text-center">
|
||||
<div className="card-std mx-auto mt-12 max-w-lg space-y-4 p-6 text-center">
|
||||
<h2 className="text-lg font-semibold text-zinc-900">页面渲染出错</h2>
|
||||
<p className="text-sm text-zinc-600">
|
||||
{this.state.error?.message ?? "发生了未知错误"}
|
||||
@@ -55,7 +54,7 @@ export class ErrorBoundary extends Component<Props, State> {
|
||||
返回首页
|
||||
</button>
|
||||
</div>
|
||||
</Card>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
在新工单中引用
屏蔽一个用户