This commit is contained in:
parent
f8b7c1df46
commit
c55c092e8f
|
|
@ -766,15 +766,23 @@ export function DetailPageHeader({ data }: { data: any }) {
|
|||
</div>
|
||||
|
||||
{showProgressBar && (progress !== "0%" || statusText) && (
|
||||
<div className="w-full mt-4 bg-gray-200 h-6">
|
||||
<div
|
||||
className={`${progressBarColor} h-full text-white text-center text-sm flex items-center justify-center transition-all duration-300 px-2 overflow-hidden whitespace-nowrap text-ellipsis`}
|
||||
style={{ width: progress || "0%" }}
|
||||
>
|
||||
{loading ? "操作中..." : statusText}
|
||||
<div className="relative w-full bg-gray-200 h-6 rounded">
|
||||
{/* 独立文字层 */}
|
||||
<div className="absolute right-2 top-1/2 -translate-y-1/2 text-sm font-medium text-black whitespace-nowrap">
|
||||
{loading ? "Processing..." : statusText}
|
||||
</div>
|
||||
|
||||
{/* 蓝色进度条 */}
|
||||
<div
|
||||
className={`transition-all duration-300 h-full rounded ${progressBarColor}`}
|
||||
style={{ width: progress }}
|
||||
/>
|
||||
</div>
|
||||
)}
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in New Issue