Polish wired editor UI and variable handling

This commit is contained in:
Lorenzune
2026-04-08 16:18:16 +02:00
parent 0ebd37d91b
commit 5e9e3e1e4c
22 changed files with 926 additions and 1029 deletions
+3
View File
@@ -4,6 +4,7 @@ import { useBetween } from 'use-between';
import { GetRoomSession, IsOwnerOfFloorFurniture, LocalizeText, SendMessageComposer, WiredFurniType, WiredSelectionVisualizer } from '../../api';
import { useMessageEvent } from '../events';
import { useNotification } from '../notification';
import { useWiredTools } from '../wired-tools/useWiredTools';
const useWiredState = () =>
{
@@ -19,6 +20,7 @@ const useWiredState = () =>
const [ allowedInteractionTypes, setAllowedInteractionTypes ] = useState<string[] | null>(null);
const [ allowedInteractionErrorKey, setAllowedInteractionErrorKey ] = useState<string | null>(null);
const { showConfirm = null, simpleAlert = null } = useNotification();
const { requestUserVariables = null, roomSettings = null } = useWiredTools();
const saveWired = () =>
{
@@ -273,6 +275,7 @@ const useWiredState = () =>
const parser = event.getParser();
WiredSelectionVisualizer.clearAllSelectionShaders();
if(roomSettings?.canInspect && requestUserVariables) requestUserVariables();
setTrigger(null);
});