diff --git a/ui/src/components/certimate/DeployProgress.tsx b/ui/src/components/certimate/DeployProgress.tsx
index b96dc2b9..caed3f2a 100644
--- a/ui/src/components/certimate/DeployProgress.tsx
+++ b/ui/src/components/certimate/DeployProgress.tsx
@@ -1,5 +1,8 @@
import { useTranslation } from "react-i18next";
+import { cn } from "@/lib/utils"
+
+
import { Separator } from "../ui/separator";
type DeployProgressProps = {
@@ -10,116 +13,61 @@ type DeployProgressProps = {
const DeployProgress = ({ phase, phaseSuccess }: DeployProgressProps) => {
const { t } = useTranslation();
- let rs = <> >;
+ let step = 0;
+
if (phase === "check") {
- if (phaseSuccess) {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- } else {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- }
+ step = 1
+ } else if (phase === "apply") {
+ step = 2
+ } else if (phase === "deploy") {
+ step = 3
}
- if (phase === "apply") {
- if (phaseSuccess) {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- } else {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- }
- }
-
- if (phase === "deploy") {
- if (phaseSuccess) {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- } else {
- rs = (
-
-
- {t('deploy.progress.check')}
-
-
-
- {t('deploy.progress.apply')}
-
-
-
- {t('deploy.progress.deploy')}
-
-
- );
- }
- }
-
- return rs;
+ return (
+
+
1 ? "text-green-600" : "",
+ )
+ }>
+ {t('deploy.progress.check')}
+
+
1 ? "bg-green-600" : "",
+ )
+ } />
+ 2 ? "text-green-600" : "",
+ )
+ }>
+ {t('deploy.progress.apply')}
+
+ 2 ? "bg-green-600" : "",
+ )
+ } />
+ 3 ? "text-green-600" : "",
+ )
+ }>
+ {t('deploy.progress.deploy')}
+
+
+ )
};
export default DeployProgress;