mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2026-04-30 19:36:24 +00:00
update gpu-switch-mode-indicator.tsx
This commit is contained in:
@@ -29,10 +29,14 @@ export function GpuSwitchModeIndicator({
|
|||||||
const vmColor = isVmActive ? "#a855f7" : inactiveColor
|
const vmColor = isVmActive ? "#a855f7" : inactiveColor
|
||||||
|
|
||||||
const handleClick = (e: React.MouseEvent) => {
|
const handleClick = (e: React.MouseEvent) => {
|
||||||
e.stopPropagation()
|
// Only stop propagation and handle toggle when in editing mode
|
||||||
if (isEditing && onToggle) {
|
if (isEditing) {
|
||||||
onToggle(e)
|
e.stopPropagation()
|
||||||
|
if (onToggle) {
|
||||||
|
onToggle(e)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// When not editing, let the click propagate to the card to open the modal
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -278,9 +278,7 @@ const initMessage = {
|
|||||||
|
|
||||||
const initMessage = {
|
const initMessage = {
|
||||||
script_path: scriptPath,
|
script_path: scriptPath,
|
||||||
params: {
|
params,
|
||||||
EXECUTION_MODE: "web",
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ws.send(JSON.stringify(initMessage))
|
ws.send(JSON.stringify(initMessage))
|
||||||
|
|||||||
Reference in New Issue
Block a user