diff --git a/src/pages/Index/Index.vue b/src/pages/Index/Index.vue
index 36a7cb4..18e6c73 100644
--- a/src/pages/Index/Index.vue
+++ b/src/pages/Index/Index.vue
@@ -2,7 +2,7 @@
-

+
@@ -31,20 +31,19 @@
-
-
+
-
+
-
+
-
+
-
+
@@ -86,7 +86,7 @@
缓冲液大
-
@@ -244,7 +244,6 @@ watch(
// 发出更新事件,通知父组件新的 remainingCount 值
const handleDeactivate = (remainingCount: number) => {
emit('updateTipNum', { index: activeTab.value, tipNum: remainingCount })
- console.log('剩余小球数量:', remainingCount)
}
const syncActivatedCount = (count: number) => {
@@ -269,69 +268,65 @@ const changePlate = (index: number) => {
margin: 0;
padding: 0;
position: relative;
- width: 765px;
display: flex;
justify-content: space-between;
+ width: 100%;
.title {
- font-size: 32px;
+ font-size: 20px;
/* 统一设置标题大小 */
font-weight: bold;
}
.move-liquid-area {
- flex: 0.7;
+ width: 70%;
display: flex;
flex-direction: column;
- justify-content: space-between;
- align-items: center;
+ margin-left: 10px;
+ gap: 9px;
.load-consumables {
- padding: 0;
width: 98%;
- height: 125px;
- font-size: 50px;
+ padding: 0;
+ height: 100px;
+ font-size: 40px;
border-radius: 10px;
margin-bottom: 15px;
}
.move-liquid-title {
- width: 98%;
- height: 33px;
+ width: 100%;
display: flex;
- font-size: 32px;
+ font-size: 26px;
font-weight: 400;
align-items: center;
margin-left: 10px;
.line {
width: 4px;
- height: 30px;
+ height: 20px;
background-color: #00d800;
margin-right: 5px;
}
}
.move-liquid-controller {
- width: 508px;
display: flex;
flex-wrap: nowrap;
- justify-content: space-between;
.controller {
- flex: 1 1 30%;
- width: 153px;
- height: 153px;
+ width: 140px;
+ height: 130px;
color: #54a4e8;
border: 3px solid #54a4e8;
border-radius: 10px;
display: grid;
place-content: center;
- margin: 5px;
cursor: pointer;
+ transition: all 0.3s;
.controller-title {
- font-size: 32px;
+ font-size: 20px;
font-weight: 400;
}
@@ -353,25 +348,21 @@ const changePlate = (index: number) => {
/* 选中时文字颜色 */
}
}
-
- .move-liquid-graph {
- margin-left: 10px;
- }
}
.right-area {
- flex: 0.3;
+ width: 30%;
display: flex;
flex-direction: column;
justify-content: start;
height: 49.1875rem;
- margin: 0 10px;
+ gap: 20px;
.emergency-area,
.id-area,
.waste-area,
.buffer-area {
- width: 100%;
+ width: 90%;
margin: 11px 0;
}
@@ -379,8 +370,8 @@ const changePlate = (index: number) => {
.id-title,
.waste-title,
.buffer-title {
- font-size: 32px;
- font-weight: 400;
+ font-size: 26px;
+ font-weight: 500;
}
.controller-button,
@@ -388,12 +379,12 @@ const changePlate = (index: number) => {
.waste-button,
.buffer-controller {
width: 100%;
- height: 100px;
+ height: 80px;
}
.line {
width: 4px;
- height: 32px;
+ height: 20px;
background-color: #00d800;
margin: 0 5px;
}
@@ -412,7 +403,6 @@ const changePlate = (index: number) => {
align-items: center;
background-color: #f6f6f6;
margin: 0 5px;
- font-size: 32px;
font-weight: 400;
}
@@ -423,19 +413,19 @@ const changePlate = (index: number) => {
.controller {
width: 100%;
- height: 80px;
+ height: 60px;
display: flex;
justify-content: space-around;
background-color: #fff;
align-items: center;
.emergency-ball {
- width: 50px;
- height: 50px;
+ width: 40px;
+ height: 40px;
border-radius: 50%;
background-color: #d9d9d9;
align-items: center;
- line-height: 50px;
+ line-height: 40px;
font-weight: 700;
font-size: 30px;
color: #a1a1a1;
@@ -478,14 +468,14 @@ const changePlate = (index: number) => {
padding: 0;
background-color: #528dfe;
color: white;
- font-size: 24px;
+ font-size: 20px;
font-weight: 400;
margin-top: 5px;
border-radius: 7px;
.button-text {
width: 120px;
- font-size: 32px;
+ font-size: 26px;
}
}
}
@@ -524,15 +514,15 @@ const changePlate = (index: number) => {
margin-right: 5px;
img {
- width: 50px;
- height: 50px;
+ width: 40px;
+ height: 40px;
}
}
.button-text {
width: 65px;
height: 24px;
- font-size: 32px;
+ font-size: 26px;
font-weight: 400;
line-height: 30px;
}
diff --git a/src/pages/Index/components/Consumables/Plate.vue b/src/pages/Index/components/Consumables/Plate.vue
index 70b414b..96bbe31 100644
--- a/src/pages/Index/components/Consumables/Plate.vue
+++ b/src/pages/Index/components/Consumables/Plate.vue
@@ -42,7 +42,7 @@ defineProps({
.colored-bar {
display: flex;
justify-content: space-between;
- width: 100%;
+ width: 355px;
height: 100%;
background-color: #f0f0f0;
border-radius: 10px;
diff --git a/src/pages/Index/components/Consumables/SpttingPlates.vue b/src/pages/Index/components/Consumables/SpttingPlates.vue
index 6ed39be..45104f2 100644
--- a/src/pages/Index/components/Consumables/SpttingPlates.vue
+++ b/src/pages/Index/components/Consumables/SpttingPlates.vue
@@ -20,7 +20,7 @@
-

+
@@ -52,24 +52,7 @@ const props = defineProps({
})
// 温度状态
const currentTemperature = ref(40);
-let socket;
-// 使用 WebSocket 获取实时温度更新
-const startWebSocket = () => {
- socket = new WebSocket("ws://localhost:8080/temperature");
- socket.onmessage = (event) => {
- const { temperature } = JSON.parse(event.data);
- currentTemperature.value = temperature;
- };
-};
-onMounted(() => {
- startWebSocket();
-});
-
-onBeforeUnmount(() => {
- if (socket) {
- socket.close();
- }
-});
+
const changeNumRef = ref()
const changeNumber = (plate, index) => {
if (props.plates.length > 0) {
@@ -82,8 +65,6 @@ const changeNumber = (plate, index) => {