-
- {step.icon}
+
+ {/* 连接线 */}
+
+
+ {steps.map((step, index) => {
+ const isCompleted = index < currentStep
+ const isActive = index === currentStep
+
+ return (
+
+
+ {step.icon}
+
+
+ {step.title}
+
-
- {step.title}
-
-
- ))}
+ )
+ })}
)
}
diff --git a/nkebao/src/pages/workspace/traffic-distribution/NewDistribution.tsx b/nkebao/src/pages/workspace/traffic-distribution/NewDistribution.tsx
index 6c7c594db..23be78bb2 100644
--- a/nkebao/src/pages/workspace/traffic-distribution/NewDistribution.tsx
+++ b/nkebao/src/pages/workspace/traffic-distribution/NewDistribution.tsx
@@ -8,6 +8,8 @@ import {
Settings,
Search,
} from 'lucide-react';
+import { Steps, StepItem } from 'tdesign-mobile-react'; // 添加这一行
+import 'tdesign-mobile-react/es/style/index.css'; // 添加这一行
import { Button } from '@/components/ui/button';
import { Input } from '@/components/ui/input';
import { Label } from '@/components/ui/label';
@@ -88,21 +90,20 @@ interface TrafficPool {
// 步骤指示器组件
function StepIndicator({ currentStep, steps }: StepIndicatorProps) {
return (
-
- {steps.map((step, index) => (
-
-
- {step.icon}
-
-
- {step.title}
-
-
- ))}
+
+
+ {steps.map((step, index) => (
+
+ ))}
+
);
}
@@ -336,7 +337,7 @@ function TargetSettingsStep({ onNext, onBack, initialData = {} }: TargetSettings
key={device.id}
className={`cursor-pointer border ${selectedDevices.includes(device.id) ? "border-blue-500" : "border-gray-200"}`}
>
-
+
toggleDevice(device.id)}>
-
- toggleCustomerService(cs.id)}>
+
+ toggleCustomerService(cs.id)}>