fix(playback-controller): 移除旧的暗黑主题样式,新增播放控制器的暗黑主题样式
This commit is contained in:
parent
51ffcd95e2
commit
1caed38024
@ -325,21 +325,6 @@ const handleTimelineClick = (event: MouseEvent) => {
|
|||||||
color: #555;
|
color: #555;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
body[data-theme='dark'] {
|
|
||||||
.tick {
|
|
||||||
background-color: #777;
|
|
||||||
&.tick-major {
|
|
||||||
background-color: #ddd;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.tick-label {
|
|
||||||
color: #aaa;
|
|
||||||
}
|
|
||||||
.timeline-container::after {
|
|
||||||
background-color: #434343;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@ -358,5 +343,18 @@ body[data-theme='dark'] {
|
|||||||
color: #0dbb8a !important; /* "Today" button text color */
|
color: #0dbb8a !important; /* "Today" button text color */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
html[theme='dark'] {
|
||||||
|
.playback-controller {
|
||||||
|
background-color: #36393a;
|
||||||
|
border-color: #2a2c2c;
|
||||||
|
.timeline-container {
|
||||||
|
&::after {
|
||||||
|
background-color: #2a2c2c;
|
||||||
|
}
|
||||||
|
.tick-label {
|
||||||
|
color: #aaa;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
import { message } from 'ant-design-vue';
|
import { message } from 'ant-design-vue';
|
||||||
import { type Ref, ref, type ShallowRef, shallowRef } from 'vue';
|
import { type Ref, ref, type ShallowRef, shallowRef } from 'vue';
|
||||||
|
|
||||||
@ -98,7 +97,7 @@ export function usePlaybackWebSocket(editorService: ShallowRef<EditorService | u
|
|||||||
locateCenter();
|
locateCenter();
|
||||||
}, 100);
|
}, 100);
|
||||||
} else if (msg.type === 'AMR') {
|
} else if (msg.type === 'AMR') {
|
||||||
(msg.data as RobotRealtimeInfo[]).forEach(robot => {
|
(msg.data as RobotRealtimeInfo[]).forEach((robot) => {
|
||||||
latestRobotData.set(robot.id, robot);
|
latestRobotData.set(robot.id, robot);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -134,7 +133,7 @@ export function usePlaybackWebSocket(editorService: ShallowRef<EditorService | u
|
|||||||
if (client.value && client.value.readyState === WebSocket.OPEN) {
|
if (client.value && client.value.readyState === WebSocket.OPEN) {
|
||||||
client.value.send(command);
|
client.value.send(command);
|
||||||
} else {
|
} else {
|
||||||
message.warn('回放连接未建立或已断开,无法发送指令');
|
// message.warn('回放连接未建立或已断开,无法发送指令');
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -180,7 +179,7 @@ export function usePlaybackWebSocket(editorService: ShallowRef<EditorService | u
|
|||||||
robot: {
|
robot: {
|
||||||
...rest,
|
...rest,
|
||||||
// 增加更严格的校验:确保 state 的值存在于 RobotState 枚举中
|
// 增加更严格的校验:确保 state 的值存在于 RobotState 枚举中
|
||||||
state: RobotState[state] ? state : currentState ?? RobotState.未知,
|
state: RobotState[state] ? state : (currentState ?? RobotState.未知),
|
||||||
}, // 将业务数据挂载到图元的 robot 属性上
|
}, // 将业务数据挂载到图元的 robot 属性上
|
||||||
},
|
},
|
||||||
{ render: false },
|
{ render: false },
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user