feat(wired-ui): add freeze and furni movement action views

- add UI support for FREEZE, UNFREEZE, FURNI_TO_USER, USER_TO_FURNI and FURNI_TO_FURNI

- add secondary furni source 101 and dual furni-source labels for furni-to-furni targeting

- extend source selectors for custom source sets and titles

- add green primary and blue secondary wired highlights

- clear wired highlights globally on close, reopen and save to avoid stuck selections
This commit is contained in:
Lorenzune
2026-03-17 03:28:00 +01:00
parent bffaccf6a3
commit f4ddf406ad
9 changed files with 426 additions and 27 deletions
@@ -0,0 +1,26 @@
import { FC, useEffect, useState } from 'react';
import { WiredFurniType } from '../../../../api';
import { useWired } from '../../../../hooks';
import { WiredActionBaseView } from './WiredActionBaseView';
import { WiredSourcesSelector } from '../WiredSourcesSelector';
export const WiredActionUnfreezeView: FC<{}> = () =>
{
const [ userSource, setUserSource ] = useState(0);
const { trigger = null, setIntParams = null } = useWired();
const save = () => setIntParams([ userSource ]);
useEffect(() =>
{
setUserSource((trigger?.intData?.length > 0) ? trigger.intData[0] : 0);
}, [ trigger ]);
return (
<WiredActionBaseView
hasSpecialInput={ true }
requiresFurni={ WiredFurniType.STUFF_SELECTION_OPTION_NONE }
save={ save }
footer={ <WiredSourcesSelector showUsers={ true } userSource={ userSource } onChangeUsers={ setUserSource } /> } />
);
};