From 8abd271800093838501c8f68d1b442741c5e8bf9 Mon Sep 17 00:00:00 2001 From: Bill Date: Tue, 11 Jan 2022 23:03:56 -0500 Subject: [PATCH] Move wired around --- src/components/index.scss | 1 + .../wired/WiredMessageHandler.tsx | 0 .../wired/WiredView.scss | 0 src/{views => components}/wired/WiredView.tsx | 3 +- .../wired/common/GetWiredActionLayout.tsx | 50 +++++++++---------- .../wired/common/GetWiredConditionLayout.tsx | 30 +++++------ .../wired/common/GetWiredLayout.tsx | 0 .../wired/common/GetWiredTimeLocale.ts | 0 .../wired/common/GetWiredTriggerLayout.tsx | 28 +++++------ .../wired/common/WiredActionLayoutCode.ts | 0 .../wired/common/WiredConditionLayoutCode.ts | 0 .../wired/common/WiredFurniType.ts} | 5 -- .../wired/common/WiredSelectionFilter.ts | 0 .../wired/common/WiredSelectionVisualizer.ts | 0 .../wired/common/WiredStringDelimeter.ts | 1 + .../wired/common/WiredTriggerLayoutCode.ts | 0 src/components/wired/context/WiredContext.tsx | 36 +++++++++++++ .../wired/views}/WiredBaseView.tsx | 24 +++++---- .../wired/views}/WiredFurniSelectorView.tsx | 13 +++-- .../views/actions}/WiredActionBaseView.tsx | 17 ++++--- .../WiredActionBotChangeFigureView.tsx | 11 ++-- .../WiredActionBotFollowAvatarView.tsx | 8 +-- .../WiredActionBotGiveHandItemView.tsx | 8 +-- .../views/actions}/WiredActionBotMoveView.tsx | 8 +-- .../WiredActionBotTalkToAvatarView.tsx | 3 +- .../views/actions}/WiredActionBotTalkView.tsx | 9 ++-- .../actions}/WiredActionBotTeleportView.tsx | 8 +-- .../WiredActionCallAnotherStackView.tsx | 4 +- .../views/actions}/WiredActionChaseView.tsx | 4 +- .../views/actions}/WiredActionChatView.tsx | 8 +-- .../views/actions}/WiredActionFleeView.tsx | 4 +- .../actions}/WiredActionGiveRewardView.tsx | 8 +-- ...redActionGiveScoreToPredefinedTeamView.tsx | 8 +-- .../actions}/WiredActionGiveScoreView.tsx | 8 +-- .../actions}/WiredActionJoinTeamView.tsx | 8 +-- .../actions}/WiredActionKickFromRoomView.tsx | 8 +-- .../actions}/WiredActionLeaveTeamView.tsx | 4 +- .../WiredActionMoveAndRotateFurniView.tsx | 8 +-- .../actions}/WiredActionMoveFurniToView.tsx | 8 +-- .../actions}/WiredActionMoveFurniView.tsx | 8 +-- .../actions}/WiredActionMuteUserView.tsx | 8 +-- .../views/actions}/WiredActionResetView.tsx | 4 +- .../WiredActionSetFurniStateToView.tsx | 8 +-- .../actions}/WiredActionTeleportView.tsx | 4 +- .../WiredActionToggleFurniStateView.tsx | 4 +- .../WiredConditionActorHasHandItem.tsx | 8 +-- .../WiredConditionActorIsGroupMemberView.tsx | 4 +- .../WiredConditionActorIsOnFurniView.tsx | 4 +- .../WiredConditionActorIsTeamMemberView.tsx | 8 +-- .../WiredConditionActorIsWearingBadgeView.tsx | 8 +-- ...WiredConditionActorIsWearingEffectView.tsx | 8 +-- .../conditions}/WiredConditionBaseView.tsx | 11 ++-- .../WiredConditionDateRangeView.tsx | 8 +-- .../WiredConditionFurniHasAvatarOnView.tsx | 4 +- .../WiredConditionFurniHasFurniOnView.tsx | 8 +-- .../WiredConditionFurniHasNotFurniOnView.tsx | 8 +-- .../WiredConditionFurniIsOfTypeView.tsx | 4 +- ...WiredConditionFurniMatchesSnapshotView.tsx | 8 +-- .../WiredConditionTimeElapsedLessView.tsx | 10 ++-- .../WiredConditionTimeElapsedMoreView.tsx | 10 ++-- .../WiredConditionUserCountInRoomView.tsx | 8 +-- .../WiredTriggerAvatarEnterRoomView.tsx | 8 +-- .../WiredTriggerAvatarSaysSomethingView.tsx | 8 +-- .../WiredTriggerAvatarWalksOffFurniView.tsx | 4 +- .../WiredTriggerAvatarWalksOnFurni.tsx | 4 +- .../views/triggers}/WiredTriggerBaseView.tsx | 11 ++-- .../WiredTriggerBotReachedAvatarView.tsx | 8 +-- .../WiredTriggerBotReachedStuffView.tsx | 8 +-- .../triggers}/WiredTriggerCollisionView.tsx | 4 +- .../triggers}/WiredTriggerExecuteOnceView.tsx | 10 ++-- ...iredTriggerExecutePeriodicallyLongView.tsx | 8 +-- .../WiredTriggerExecutePeriodicallyView.tsx | 10 ++-- .../triggers}/WiredTriggerGameEndsView.tsx | 4 +- .../triggers}/WiredTriggerGameStartsView.tsx | 4 +- .../WiredTriggerScoreAchievedView.tsx | 8 +-- .../triggers}/WiredTriggerToggleFurniView.tsx | 4 +- src/views/Styles.scss | 1 - src/views/main/MainView.tsx | 2 +- src/views/wired/context/WiredContext.tsx | 22 -------- src/views/wired/context/WiredContext.types.ts | 21 -------- .../actions/base/WiredActionBaseView.types.ts | 5 -- .../wired/views/base/WiredBaseView.types.ts | 6 --- .../base/WiredConditionBaseView.types.ts | 5 -- .../WiredFurniSelectorView.types.ts | 3 -- .../base/WiredTriggerBaseView.types.ts | 5 -- 85 files changed, 329 insertions(+), 342 deletions(-) rename src/{views => components}/wired/WiredMessageHandler.tsx (100%) rename src/{views => components}/wired/WiredView.scss (100%) rename src/{views => components}/wired/WiredView.tsx (94%) rename src/{views => components}/wired/common/GetWiredActionLayout.tsx (61%) rename src/{views => components}/wired/common/GetWiredConditionLayout.tsx (77%) rename src/{views => components}/wired/common/GetWiredLayout.tsx (100%) rename src/{views => components}/wired/common/GetWiredTimeLocale.ts (100%) rename src/{views => components}/wired/common/GetWiredTriggerLayout.tsx (67%) rename src/{views => components}/wired/common/WiredActionLayoutCode.ts (100%) rename src/{views => components}/wired/common/WiredConditionLayoutCode.ts (100%) rename src/{views/wired/WiredView.types.ts => components/wired/common/WiredFurniType.ts} (75%) rename src/{views => components}/wired/common/WiredSelectionFilter.ts (100%) rename src/{views => components}/wired/common/WiredSelectionVisualizer.ts (100%) create mode 100644 src/components/wired/common/WiredStringDelimeter.ts rename src/{views => components}/wired/common/WiredTriggerLayoutCode.ts (100%) create mode 100644 src/components/wired/context/WiredContext.tsx rename src/{views/wired/views/base => components/wired/views}/WiredBaseView.tsx (85%) rename src/{views/wired/views/furni-selector => components/wired/views}/WiredFurniSelectorView.tsx (83%) rename src/{views/wired/views/actions/base => components/wired/views/actions}/WiredActionBaseView.tsx (78%) rename src/{views/wired/views/actions/bot-change-figure => components/wired/views/actions}/WiredActionBotChangeFigureView.tsx (83%) rename src/{views/wired/views/actions/bot-follow-avatar => components/wired/views/actions}/WiredActionBotFollowAvatarView.tsx (89%) rename src/{views/wired/views/actions/bot-give-hand-item => components/wired/views/actions}/WiredActionBotGiveHandItemView.tsx (88%) rename src/{views/wired/views/actions/bot-move => components/wired/views/actions}/WiredActionBotMoveView.tsx (79%) rename src/{views/wired/views/actions/bot-talk-to-avatar => components/wired/views/actions}/WiredActionBotTalkToAvatarView.tsx (94%) rename src/{views/wired/views/actions/bot-talk => components/wired/views/actions}/WiredActionBotTalkView.tsx (89%) rename src/{views/wired/views/actions/bot-teleport => components/wired/views/actions}/WiredActionBotTeleportView.tsx (79%) rename src/{views/wired/views/actions/call-another-stack => components/wired/views/actions}/WiredActionCallAnotherStackView.tsx (64%) rename src/{views/wired/views/actions/chase => components/wired/views/actions}/WiredActionChaseView.tsx (63%) rename src/{views/wired/views/actions/chat => components/wired/views/actions}/WiredActionChatView.tsx (78%) rename src/{views/wired/views/actions/flee => components/wired/views/actions}/WiredActionFleeView.tsx (63%) rename src/{views/wired/views/actions/give-reward => components/wired/views/actions}/WiredActionGiveRewardView.tsx (97%) rename src/{views/wired/views/actions/give-score-to-predefined-team => components/wired/views/actions}/WiredActionGiveScoreToPredefinedTeamView.tsx (92%) rename src/{views/wired/views/actions/give-score => components/wired/views/actions}/WiredActionGiveScoreView.tsx (87%) rename src/{views/wired/views/actions/join-team => components/wired/views/actions}/WiredActionJoinTeamView.tsx (86%) rename src/{views/wired/views/actions/kick-from-room => components/wired/views/actions}/WiredActionKickFromRoomView.tsx (79%) rename src/{views/wired/views/actions/leave-team => components/wired/views/actions}/WiredActionLeaveTeamView.tsx (61%) rename src/{views/wired/views/actions/move-and-rotate-furni => components/wired/views/actions}/WiredActionMoveAndRotateFurniView.tsx (92%) rename src/{views/wired/views/actions/move-furni-to => components/wired/views/actions}/WiredActionMoveFurniToView.tsx (91%) rename src/{views/wired/views/actions/move-furni => components/wired/views/actions}/WiredActionMoveFurniView.tsx (94%) rename src/{views/wired/views/actions/mute-user => components/wired/views/actions}/WiredActionMuteUserView.tsx (86%) rename src/{views/wired/views/actions/reset => components/wired/views/actions}/WiredActionResetView.tsx (60%) rename src/{views/wired/views/actions/set-furni-state-to => components/wired/views/actions}/WiredActionSetFurniStateToView.tsx (90%) rename src/{views/wired/views/actions/teleport => components/wired/views/actions}/WiredActionTeleportView.tsx (64%) rename src/{views/wired/views/actions/toggle-furni-state => components/wired/views/actions}/WiredActionToggleFurniStateView.tsx (64%) rename src/{views/wired/views/conditions/actor-has-hand-item => components/wired/views/conditions}/WiredConditionActorHasHandItem.tsx (83%) rename src/{views/wired/views/conditions/actor-is-group-member => components/wired/views/conditions}/WiredConditionActorIsGroupMemberView.tsx (62%) rename src/{views/wired/views/conditions/actor-is-on-furni => components/wired/views/conditions}/WiredConditionActorIsOnFurniView.tsx (61%) rename src/{views/wired/views/conditions/actor-is-team-member => components/wired/views/conditions}/WiredConditionActorIsTeamMemberView.tsx (86%) rename src/{views/wired/views/conditions/actor-is-wearing-badge => components/wired/views/conditions}/WiredConditionActorIsWearingBadgeView.tsx (78%) rename src/{views/wired/views/conditions/actor-is-wearing-effect => components/wired/views/conditions}/WiredConditionActorIsWearingEffectView.tsx (79%) rename src/{views/wired/views/conditions/base => components/wired/views/conditions}/WiredConditionBaseView.tsx (70%) rename src/{views/wired/views/conditions/date-range => components/wired/views/conditions}/WiredConditionDateRangeView.tsx (90%) rename src/{views/wired/views/conditions/furni-has-avatar-on => components/wired/views/conditions}/WiredConditionFurniHasAvatarOnView.tsx (61%) rename src/{views/wired/views/conditions/furni-has-furni-on => components/wired/views/conditions}/WiredConditionFurniHasFurniOnView.tsx (86%) rename src/{views/wired/views/conditions/furni-has-not-furni-on => components/wired/views/conditions}/WiredConditionFurniHasNotFurniOnView.tsx (86%) rename src/{views/wired/views/conditions/furni-is-of-type => components/wired/views/conditions}/WiredConditionFurniIsOfTypeView.tsx (62%) rename src/{views/wired/views/conditions/furni-matches-snapshot => components/wired/views/conditions}/WiredConditionFurniMatchesSnapshotView.tsx (90%) rename src/{views/wired/views/conditions/time-elapsed-less => components/wired/views/conditions}/WiredConditionTimeElapsedLessView.tsx (77%) rename src/{views/wired/views/conditions/time-elapsed-more => components/wired/views/conditions}/WiredConditionTimeElapsedMoreView.tsx (77%) rename src/{views/wired/views/conditions/user-count-in-room => components/wired/views/conditions}/WiredConditionUserCountInRoomView.tsx (87%) rename src/{views/wired/views/triggers/avatar-enter-room => components/wired/views/triggers}/WiredTriggerAvatarEnterRoomView.tsx (89%) rename src/{views/wired/views/triggers/avatar-says-something => components/wired/views/triggers}/WiredTriggerAvatarSaysSomethingView.tsx (91%) rename src/{views/wired/views/triggers/avatar-walks-off-furni => components/wired/views/triggers}/WiredTriggerAvatarWalksOffFurniView.tsx (63%) rename src/{views/wired/views/triggers/avatar-walks-on-furni => components/wired/views/triggers}/WiredTriggerAvatarWalksOnFurni.tsx (63%) rename src/{views/wired/views/triggers/base => components/wired/views/triggers}/WiredTriggerBaseView.tsx (70%) rename src/{views/wired/views/triggers/bot-reached-avatar => components/wired/views/triggers}/WiredTriggerBotReachedAvatarView.tsx (79%) rename src/{views/wired/views/triggers/bot-reached-stuff => components/wired/views/triggers}/WiredTriggerBotReachedStuffView.tsx (79%) rename src/{views/wired/views/triggers/collision => components/wired/views/triggers}/WiredTriggerCollisionView.tsx (61%) rename src/{views/wired/views/triggers/execute-once => components/wired/views/triggers}/WiredTriggerExecuteOnceView.tsx (77%) rename src/{views/wired/views/triggers/execute-periodically-long => components/wired/views/triggers}/WiredTriggerExecutePeriodicallyLongView.tsx (82%) rename src/{views/wired/views/triggers/execute-periodically => components/wired/views/triggers}/WiredTriggerExecutePeriodicallyView.tsx (77%) rename src/{views/wired/views/triggers/game-ends => components/wired/views/triggers}/WiredTriggerGameEndsView.tsx (61%) rename src/{views/wired/views/triggers/game-starts => components/wired/views/triggers}/WiredTriggerGameStartsView.tsx (61%) rename src/{views/wired/views/triggers/score-achieved => components/wired/views/triggers}/WiredTriggerScoreAchievedView.tsx (82%) rename src/{views/wired/views/triggers/toggle-furni => components/wired/views/triggers}/WiredTriggerToggleFurniView.tsx (62%) delete mode 100644 src/views/wired/context/WiredContext.tsx delete mode 100644 src/views/wired/context/WiredContext.types.ts delete mode 100644 src/views/wired/views/actions/base/WiredActionBaseView.types.ts delete mode 100644 src/views/wired/views/base/WiredBaseView.types.ts delete mode 100644 src/views/wired/views/conditions/base/WiredConditionBaseView.types.ts delete mode 100644 src/views/wired/views/furni-selector/WiredFurniSelectorView.types.ts delete mode 100644 src/views/wired/views/triggers/base/WiredTriggerBaseView.types.ts diff --git a/src/components/index.scss b/src/components/index.scss index 9736d874..56a8c8ad 100644 --- a/src/components/index.scss +++ b/src/components/index.scss @@ -5,3 +5,4 @@ @import './inventory/InventoryView'; @import './navigator/NavigatorView'; @import './toolbar/ToolbarView'; +@import './wired/WiredView'; diff --git a/src/views/wired/WiredMessageHandler.tsx b/src/components/wired/WiredMessageHandler.tsx similarity index 100% rename from src/views/wired/WiredMessageHandler.tsx rename to src/components/wired/WiredMessageHandler.tsx diff --git a/src/views/wired/WiredView.scss b/src/components/wired/WiredView.scss similarity index 100% rename from src/views/wired/WiredView.scss rename to src/components/wired/WiredView.scss diff --git a/src/views/wired/WiredView.tsx b/src/components/wired/WiredView.tsx similarity index 94% rename from src/views/wired/WiredView.tsx rename to src/components/wired/WiredView.tsx index 245d26d3..2a95a5b1 100644 --- a/src/views/wired/WiredView.tsx +++ b/src/components/wired/WiredView.tsx @@ -6,9 +6,8 @@ import { SendMessageHook } from '../../hooks/messages'; import { GetWiredLayout } from './common/GetWiredLayout'; import { WiredContextProvider } from './context/WiredContext'; import { WiredMessageHandler } from './WiredMessageHandler'; -import { WiredFurniSelectorViewProps } from './WiredView.types'; -export const WiredView: FC = props => +export const WiredView: FC<{}> = props => { const [ trigger, setTrigger ] = useState(null); const [ intParams, setIntParams ] = useState(null); diff --git a/src/views/wired/common/GetWiredActionLayout.tsx b/src/components/wired/common/GetWiredActionLayout.tsx similarity index 61% rename from src/views/wired/common/GetWiredActionLayout.tsx rename to src/components/wired/common/GetWiredActionLayout.tsx index fab75242..9a0b1c09 100644 --- a/src/views/wired/common/GetWiredActionLayout.tsx +++ b/src/components/wired/common/GetWiredActionLayout.tsx @@ -1,28 +1,28 @@ -import { WiredActionBotChangeFigureView } from '../views/actions/bot-change-figure/WiredActionBotChangeFigureView'; -import { WiredActionBotFollowAvatarView } from '../views/actions/bot-follow-avatar/WiredActionBotFollowAvatarView'; -import { WiredActionBotGiveHandItemView } from '../views/actions/bot-give-hand-item/WiredActionBotGiveHandItemView'; -import { WiredActionBotMoveView } from '../views/actions/bot-move/WiredActionBotMoveView'; -import { WiredActionBotTalkToAvatarView } from '../views/actions/bot-talk-to-avatar/WiredActionBotTalkToAvatarView'; -import { WiredActionBotTalkView } from '../views/actions/bot-talk/WiredActionBotTalkView'; -import { WiredActionBotTeleportView } from '../views/actions/bot-teleport/WiredActionBotTeleportView'; -import { WiredActionCallAnotherStackView } from '../views/actions/call-another-stack/WiredActionCallAnotherStackView'; -import { WiredActionChaseView } from '../views/actions/chase/WiredActionChaseView'; -import { WiredActionChatView } from '../views/actions/chat/WiredActionChatView'; -import { WiredActionFleeView } from '../views/actions/flee/WiredActionFleeView'; -import { WiredActionGiveRewardView } from '../views/actions/give-reward/WiredActionGiveRewardView'; -import { WiredActionGiveScoreToPredefinedTeamView } from '../views/actions/give-score-to-predefined-team/WiredActionGiveScoreToPredefinedTeamView'; -import { WiredActionGiveScoreView } from '../views/actions/give-score/WiredActionGiveScoreView'; -import { WiredActionJoinTeamView } from '../views/actions/join-team/WiredActionJoinTeamView'; -import { WiredActionKickFromRoomView } from '../views/actions/kick-from-room/WiredActionKickFromRoomView'; -import { WiredActionLeaveTeamView } from '../views/actions/leave-team/WiredActionLeaveTeamView'; -import { WiredActionMoveAndRotateFurniView } from '../views/actions/move-and-rotate-furni/WiredActionMoveAndRotateFurniView'; -import { WiredActionMoveFurniToView } from '../views/actions/move-furni-to/WiredActionMoveFurniToView'; -import { WiredActionMoveFurniView } from '../views/actions/move-furni/WiredActionMoveFurniView'; -import { WiredActionMuteUserView } from '../views/actions/mute-user/WiredActionMuteUserView'; -import { WiredActionResetView } from '../views/actions/reset/WiredActionResetView'; -import { WiredActionSetFurniStateToView } from '../views/actions/set-furni-state-to/WiredActionSetFurniStateToView'; -import { WiredActionTeleportView } from '../views/actions/teleport/WiredActionTeleportView'; -import { WiredActionToggleFurniStateView } from '../views/actions/toggle-furni-state/WiredActionToggleFurniStateView'; +import { WiredActionBotChangeFigureView } from '../views/actions/WiredActionBotChangeFigureView'; +import { WiredActionBotFollowAvatarView } from '../views/actions/WiredActionBotFollowAvatarView'; +import { WiredActionBotGiveHandItemView } from '../views/actions/WiredActionBotGiveHandItemView'; +import { WiredActionBotMoveView } from '../views/actions/WiredActionBotMoveView'; +import { WiredActionBotTalkToAvatarView } from '../views/actions/WiredActionBotTalkToAvatarView'; +import { WiredActionBotTalkView } from '../views/actions/WiredActionBotTalkView'; +import { WiredActionBotTeleportView } from '../views/actions/WiredActionBotTeleportView'; +import { WiredActionCallAnotherStackView } from '../views/actions/WiredActionCallAnotherStackView'; +import { WiredActionChaseView } from '../views/actions/WiredActionChaseView'; +import { WiredActionChatView } from '../views/actions/WiredActionChatView'; +import { WiredActionFleeView } from '../views/actions/WiredActionFleeView'; +import { WiredActionGiveRewardView } from '../views/actions/WiredActionGiveRewardView'; +import { WiredActionGiveScoreToPredefinedTeamView } from '../views/actions/WiredActionGiveScoreToPredefinedTeamView'; +import { WiredActionGiveScoreView } from '../views/actions/WiredActionGiveScoreView'; +import { WiredActionJoinTeamView } from '../views/actions/WiredActionJoinTeamView'; +import { WiredActionKickFromRoomView } from '../views/actions/WiredActionKickFromRoomView'; +import { WiredActionLeaveTeamView } from '../views/actions/WiredActionLeaveTeamView'; +import { WiredActionMoveAndRotateFurniView } from '../views/actions/WiredActionMoveAndRotateFurniView'; +import { WiredActionMoveFurniToView } from '../views/actions/WiredActionMoveFurniToView'; +import { WiredActionMoveFurniView } from '../views/actions/WiredActionMoveFurniView'; +import { WiredActionMuteUserView } from '../views/actions/WiredActionMuteUserView'; +import { WiredActionResetView } from '../views/actions/WiredActionResetView'; +import { WiredActionSetFurniStateToView } from '../views/actions/WiredActionSetFurniStateToView'; +import { WiredActionTeleportView } from '../views/actions/WiredActionTeleportView'; +import { WiredActionToggleFurniStateView } from '../views/actions/WiredActionToggleFurniStateView'; import { WiredActionLayout } from './WiredActionLayoutCode'; export function GetWiredActionLayout(code: number): JSX.Element diff --git a/src/views/wired/common/GetWiredConditionLayout.tsx b/src/components/wired/common/GetWiredConditionLayout.tsx similarity index 77% rename from src/views/wired/common/GetWiredConditionLayout.tsx rename to src/components/wired/common/GetWiredConditionLayout.tsx index e56caebe..c3f79007 100644 --- a/src/views/wired/common/GetWiredConditionLayout.tsx +++ b/src/components/wired/common/GetWiredConditionLayout.tsx @@ -1,18 +1,18 @@ -import { WiredConditionActorHasHandItemView } from '../views/conditions/actor-has-hand-item/WiredConditionActorHasHandItem'; -import { WiredConditionActorIsGroupMemberView } from '../views/conditions/actor-is-group-member/WiredConditionActorIsGroupMemberView'; -import { WiredConditionActorIsOnFurniView } from '../views/conditions/actor-is-on-furni/WiredConditionActorIsOnFurniView'; -import { WiredConditionActorIsTeamMemberView } from '../views/conditions/actor-is-team-member/WiredConditionActorIsTeamMemberView'; -import { WiredConditionActorIsWearingBadgeView } from '../views/conditions/actor-is-wearing-badge/WiredConditionActorIsWearingBadgeView'; -import { WiredConditionActorIsWearingEffectView } from '../views/conditions/actor-is-wearing-effect/WiredConditionActorIsWearingEffectView'; -import { WiredConditionDateRangeView } from '../views/conditions/date-range/WiredConditionDateRangeView'; -import { WiredConditionFurniHasAvatarOnView } from '../views/conditions/furni-has-avatar-on/WiredConditionFurniHasAvatarOnView'; -import { WiredConditionFurniHasFurniOnView } from '../views/conditions/furni-has-furni-on/WiredConditionFurniHasFurniOnView'; -import { WiredConditionFurniHasNotFurniOnView } from '../views/conditions/furni-has-not-furni-on/WiredConditionFurniHasNotFurniOnView'; -import { WiredConditionFurniIsOfTypeView } from '../views/conditions/furni-is-of-type/WiredConditionFurniIsOfTypeView'; -import { WiredConditionFurniMatchesSnapshotView } from '../views/conditions/furni-matches-snapshot/WiredConditionFurniMatchesSnapshotView'; -import { WiredConditionTimeElapsedLessView } from '../views/conditions/time-elapsed-less/WiredConditionTimeElapsedLessView'; -import { WiredConditionTimeElapsedMoreView } from '../views/conditions/time-elapsed-more/WiredConditionTimeElapsedMoreView'; -import { WiredConditionUserCountInRoomView } from '../views/conditions/user-count-in-room/WiredConditionUserCountInRoomView'; +import { WiredConditionActorHasHandItemView } from '../views/conditions/WiredConditionActorHasHandItem'; +import { WiredConditionActorIsGroupMemberView } from '../views/conditions/WiredConditionActorIsGroupMemberView'; +import { WiredConditionActorIsOnFurniView } from '../views/conditions/WiredConditionActorIsOnFurniView'; +import { WiredConditionActorIsTeamMemberView } from '../views/conditions/WiredConditionActorIsTeamMemberView'; +import { WiredConditionActorIsWearingBadgeView } from '../views/conditions/WiredConditionActorIsWearingBadgeView'; +import { WiredConditionActorIsWearingEffectView } from '../views/conditions/WiredConditionActorIsWearingEffectView'; +import { WiredConditionDateRangeView } from '../views/conditions/WiredConditionDateRangeView'; +import { WiredConditionFurniHasAvatarOnView } from '../views/conditions/WiredConditionFurniHasAvatarOnView'; +import { WiredConditionFurniHasFurniOnView } from '../views/conditions/WiredConditionFurniHasFurniOnView'; +import { WiredConditionFurniHasNotFurniOnView } from '../views/conditions/WiredConditionFurniHasNotFurniOnView'; +import { WiredConditionFurniIsOfTypeView } from '../views/conditions/WiredConditionFurniIsOfTypeView'; +import { WiredConditionFurniMatchesSnapshotView } from '../views/conditions/WiredConditionFurniMatchesSnapshotView'; +import { WiredConditionTimeElapsedLessView } from '../views/conditions/WiredConditionTimeElapsedLessView'; +import { WiredConditionTimeElapsedMoreView } from '../views/conditions/WiredConditionTimeElapsedMoreView'; +import { WiredConditionUserCountInRoomView } from '../views/conditions/WiredConditionUserCountInRoomView'; import { WiredConditionlayout } from './WiredConditionLayoutCode'; export function GetWiredConditionLayout(code: number): JSX.Element diff --git a/src/views/wired/common/GetWiredLayout.tsx b/src/components/wired/common/GetWiredLayout.tsx similarity index 100% rename from src/views/wired/common/GetWiredLayout.tsx rename to src/components/wired/common/GetWiredLayout.tsx diff --git a/src/views/wired/common/GetWiredTimeLocale.ts b/src/components/wired/common/GetWiredTimeLocale.ts similarity index 100% rename from src/views/wired/common/GetWiredTimeLocale.ts rename to src/components/wired/common/GetWiredTimeLocale.ts diff --git a/src/views/wired/common/GetWiredTriggerLayout.tsx b/src/components/wired/common/GetWiredTriggerLayout.tsx similarity index 67% rename from src/views/wired/common/GetWiredTriggerLayout.tsx rename to src/components/wired/common/GetWiredTriggerLayout.tsx index 41ddd9c7..592b30dd 100644 --- a/src/views/wired/common/GetWiredTriggerLayout.tsx +++ b/src/components/wired/common/GetWiredTriggerLayout.tsx @@ -1,17 +1,17 @@ -import { WiredTriggerAvatarEnterRoomView } from '../views/triggers/avatar-enter-room/WiredTriggerAvatarEnterRoomView'; -import { WiredTriggerAvatarSaysSomethingView } from '../views/triggers/avatar-says-something/WiredTriggerAvatarSaysSomethingView'; -import { WiredTriggerAvatarWalksOffFurniView } from '../views/triggers/avatar-walks-off-furni/WiredTriggerAvatarWalksOffFurniView'; -import { WiredTriggerAvatarWalksOnFurniView } from '../views/triggers/avatar-walks-on-furni/WiredTriggerAvatarWalksOnFurni'; -import { WiredTriggerBotReachedAvatarView } from '../views/triggers/bot-reached-avatar/WiredTriggerBotReachedAvatarView'; -import { WiredTriggerBotReachedStuffView } from '../views/triggers/bot-reached-stuff/WiredTriggerBotReachedStuffView'; -import { WiredTriggerCollisionView } from '../views/triggers/collision/WiredTriggerCollisionView'; -import { WiredTriggeExecuteOnceView } from '../views/triggers/execute-once/WiredTriggerExecuteOnceView'; -import { WiredTriggeExecutePeriodicallyLongView } from '../views/triggers/execute-periodically-long/WiredTriggerExecutePeriodicallyLongView'; -import { WiredTriggeExecutePeriodicallyView } from '../views/triggers/execute-periodically/WiredTriggerExecutePeriodicallyView'; -import { WiredTriggerGameEndsView } from '../views/triggers/game-ends/WiredTriggerGameEndsView'; -import { WiredTriggerGameStartsView } from '../views/triggers/game-starts/WiredTriggerGameStartsView'; -import { WiredTriggeScoreAchievedView } from '../views/triggers/score-achieved/WiredTriggerScoreAchievedView'; -import { WiredTriggerToggleFurniView } from '../views/triggers/toggle-furni/WiredTriggerToggleFurniView'; +import { WiredTriggerAvatarEnterRoomView } from '../views/triggers/WiredTriggerAvatarEnterRoomView'; +import { WiredTriggerAvatarSaysSomethingView } from '../views/triggers/WiredTriggerAvatarSaysSomethingView'; +import { WiredTriggerAvatarWalksOffFurniView } from '../views/triggers/WiredTriggerAvatarWalksOffFurniView'; +import { WiredTriggerAvatarWalksOnFurniView } from '../views/triggers/WiredTriggerAvatarWalksOnFurni'; +import { WiredTriggerBotReachedAvatarView } from '../views/triggers/WiredTriggerBotReachedAvatarView'; +import { WiredTriggerBotReachedStuffView } from '../views/triggers/WiredTriggerBotReachedStuffView'; +import { WiredTriggerCollisionView } from '../views/triggers/WiredTriggerCollisionView'; +import { WiredTriggeExecuteOnceView } from '../views/triggers/WiredTriggerExecuteOnceView'; +import { WiredTriggeExecutePeriodicallyLongView } from '../views/triggers/WiredTriggerExecutePeriodicallyLongView'; +import { WiredTriggeExecutePeriodicallyView } from '../views/triggers/WiredTriggerExecutePeriodicallyView'; +import { WiredTriggerGameEndsView } from '../views/triggers/WiredTriggerGameEndsView'; +import { WiredTriggerGameStartsView } from '../views/triggers/WiredTriggerGameStartsView'; +import { WiredTriggeScoreAchievedView } from '../views/triggers/WiredTriggerScoreAchievedView'; +import { WiredTriggerToggleFurniView } from '../views/triggers/WiredTriggerToggleFurniView'; import { WiredTriggerLayout } from './WiredTriggerLayoutCode'; export function GetWiredTriggerLayout(code: number): JSX.Element diff --git a/src/views/wired/common/WiredActionLayoutCode.ts b/src/components/wired/common/WiredActionLayoutCode.ts similarity index 100% rename from src/views/wired/common/WiredActionLayoutCode.ts rename to src/components/wired/common/WiredActionLayoutCode.ts diff --git a/src/views/wired/common/WiredConditionLayoutCode.ts b/src/components/wired/common/WiredConditionLayoutCode.ts similarity index 100% rename from src/views/wired/common/WiredConditionLayoutCode.ts rename to src/components/wired/common/WiredConditionLayoutCode.ts diff --git a/src/views/wired/WiredView.types.ts b/src/components/wired/common/WiredFurniType.ts similarity index 75% rename from src/views/wired/WiredView.types.ts rename to src/components/wired/common/WiredFurniType.ts index 823d8fb3..447e9701 100644 --- a/src/views/wired/WiredView.types.ts +++ b/src/components/wired/common/WiredFurniType.ts @@ -1,6 +1,3 @@ -export class WiredFurniSelectorViewProps -{} - export class WiredFurniType { public static STUFF_SELECTION_OPTION_NONE: number = 0; @@ -8,5 +5,3 @@ export class WiredFurniType public static STUFF_SELECTION_OPTION_BY_ID_OR_BY_TYPE: number = 2; public static STUFF_SELECTION_OPTION_BY_ID_BY_TYPE_OR_FROM_CONTEXT: number = 3; } - -export const WIRED_STRING_DELIMETER: string = '\t'; diff --git a/src/views/wired/common/WiredSelectionFilter.ts b/src/components/wired/common/WiredSelectionFilter.ts similarity index 100% rename from src/views/wired/common/WiredSelectionFilter.ts rename to src/components/wired/common/WiredSelectionFilter.ts diff --git a/src/views/wired/common/WiredSelectionVisualizer.ts b/src/components/wired/common/WiredSelectionVisualizer.ts similarity index 100% rename from src/views/wired/common/WiredSelectionVisualizer.ts rename to src/components/wired/common/WiredSelectionVisualizer.ts diff --git a/src/components/wired/common/WiredStringDelimeter.ts b/src/components/wired/common/WiredStringDelimeter.ts new file mode 100644 index 00000000..bc4cf2e4 --- /dev/null +++ b/src/components/wired/common/WiredStringDelimeter.ts @@ -0,0 +1 @@ +export const WIRED_STRING_DELIMETER: string = '\t'; diff --git a/src/views/wired/common/WiredTriggerLayoutCode.ts b/src/components/wired/common/WiredTriggerLayoutCode.ts similarity index 100% rename from src/views/wired/common/WiredTriggerLayoutCode.ts rename to src/components/wired/common/WiredTriggerLayoutCode.ts diff --git a/src/components/wired/context/WiredContext.tsx b/src/components/wired/context/WiredContext.tsx new file mode 100644 index 00000000..d2046048 --- /dev/null +++ b/src/components/wired/context/WiredContext.tsx @@ -0,0 +1,36 @@ +import { Triggerable } from '@nitrots/nitro-renderer'; +import { createContext, Dispatch, FC, ProviderProps, SetStateAction, useContext } from 'react'; + +export interface IWiredContext +{ + trigger: Triggerable; + setTrigger: Dispatch>; + intParams: number[], + setIntParams: Dispatch>; + stringParam: string; + setStringParam: Dispatch>; + furniIds: number[]; + setFurniIds: Dispatch>; + actionDelay: number; + setActionDelay: Dispatch>; +} + +const WiredContext = createContext({ + trigger: null, + setTrigger: null, + intParams: null, + setIntParams: null, + stringParam: null, + setStringParam: null, + furniIds: null, + setFurniIds: null, + actionDelay: null, + setActionDelay: null +}); + +export const WiredContextProvider: FC> = props => +{ + return { props.children } +} + +export const useWiredContext = () => useContext(WiredContext); diff --git a/src/views/wired/views/base/WiredBaseView.tsx b/src/components/wired/views/WiredBaseView.tsx similarity index 85% rename from src/views/wired/views/base/WiredBaseView.tsx rename to src/components/wired/views/WiredBaseView.tsx index 919677c2..f807fc25 100644 --- a/src/views/wired/views/base/WiredBaseView.tsx +++ b/src/components/wired/views/WiredBaseView.tsx @@ -1,13 +1,19 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { GetSessionDataManager, LocalizeText } from '../../../../api'; -import { WiredEvent } from '../../../../events'; -import { dispatchUiEvent } from '../../../../hooks/events'; -import { NitroCardContentView, NitroCardView } from '../../../../layout'; -import { WiredSelectionVisualizer } from '../../common/WiredSelectionVisualizer'; -import { useWiredContext } from '../../context/WiredContext'; -import { WiredFurniType } from '../../WiredView.types'; -import { WiredFurniSelectorView } from '../furni-selector/WiredFurniSelectorView'; -import { WiredBaseViewProps } from './WiredBaseView.types'; +import { GetSessionDataManager, LocalizeText } from '../../../api'; +import { WiredEvent } from '../../../events'; +import { dispatchUiEvent } from '../../../hooks/events'; +import { NitroCardContentView, NitroCardView } from '../../../layout'; +import { WiredFurniType } from '../common/WiredFurniType'; +import { WiredSelectionVisualizer } from '../common/WiredSelectionVisualizer'; +import { useWiredContext } from '../context/WiredContext'; +import { WiredFurniSelectorView } from './WiredFurniSelectorView'; + +export interface WiredBaseViewProps +{ + wiredType: string; + requiresFurni: number; + save: () => void; +} export const WiredBaseView: FC = props => { diff --git a/src/views/wired/views/furni-selector/WiredFurniSelectorView.tsx b/src/components/wired/views/WiredFurniSelectorView.tsx similarity index 83% rename from src/views/wired/views/furni-selector/WiredFurniSelectorView.tsx rename to src/components/wired/views/WiredFurniSelectorView.tsx index 07d92a72..129f1b8a 100644 --- a/src/views/wired/views/furni-selector/WiredFurniSelectorView.tsx +++ b/src/components/wired/views/WiredFurniSelectorView.tsx @@ -1,12 +1,11 @@ import { FC, useCallback, useEffect } from 'react'; -import { LocalizeText } from '../../../../api'; -import { WiredSelectObjectEvent } from '../../../../events'; -import { useUiEvent } from '../../../../hooks/events'; -import { WiredSelectionVisualizer } from '../../common/WiredSelectionVisualizer'; -import { useWiredContext } from '../../context/WiredContext'; -import { WiredFurniSelectorViewProps } from './WiredFurniSelectorView.types'; +import { LocalizeText } from '../../../api'; +import { WiredSelectObjectEvent } from '../../../events'; +import { useUiEvent } from '../../../hooks/events'; +import { WiredSelectionVisualizer } from '../common/WiredSelectionVisualizer'; +import { useWiredContext } from '../context/WiredContext'; -export const WiredFurniSelectorView: FC = props => +export const WiredFurniSelectorView: FC<{}> = props => { const { trigger = null, furniIds = [], setFurniIds = null } = useWiredContext(); diff --git a/src/views/wired/views/actions/base/WiredActionBaseView.tsx b/src/components/wired/views/actions/WiredActionBaseView.tsx similarity index 78% rename from src/views/wired/views/actions/base/WiredActionBaseView.tsx rename to src/components/wired/views/actions/WiredActionBaseView.tsx index fd440e91..76548401 100644 --- a/src/views/wired/views/actions/base/WiredActionBaseView.tsx +++ b/src/components/wired/views/actions/WiredActionBaseView.tsx @@ -1,12 +1,17 @@ import { WiredActionDefinition } from '@nitrots/nitro-renderer'; import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { GetWiredTimeLocale } from '../../../common/GetWiredTimeLocale'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredBaseView } from '../../base/WiredBaseView'; -import { WiredActionBaseViewProps } from './WiredActionBaseView.types'; +import { LocalizeText } from '../../../../api'; +import { GetWiredTimeLocale } from '../../common/GetWiredTimeLocale'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredBaseView } from '../WiredBaseView'; + +export interface WiredActionBaseViewProps +{ + requiresFurni: number; + save: () => void; +} export const WiredActionBaseView: FC = props => { diff --git a/src/views/wired/views/actions/bot-change-figure/WiredActionBotChangeFigureView.tsx b/src/components/wired/views/actions/WiredActionBotChangeFigureView.tsx similarity index 83% rename from src/views/wired/views/actions/bot-change-figure/WiredActionBotChangeFigureView.tsx rename to src/components/wired/views/actions/WiredActionBotChangeFigureView.tsx index 4f78cb5c..8f913ffc 100644 --- a/src/views/wired/views/actions/bot-change-figure/WiredActionBotChangeFigureView.tsx +++ b/src/components/wired/views/actions/WiredActionBotChangeFigureView.tsx @@ -1,9 +1,10 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { GetSessionDataManager, LocalizeText } from '../../../../../api'; -import { AvatarImageView } from '../../../../shared/avatar-image/AvatarImageView'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType, WIRED_STRING_DELIMETER } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { GetSessionDataManager, LocalizeText } from '../../../../api'; +import { AvatarImageView } from '../../../../views/shared/avatar-image/AvatarImageView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WIRED_STRING_DELIMETER } from '../../common/WiredStringDelimeter'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; const DEFAULT_FIGURE: string = 'hd-180-1.ch-210-66.lg-270-82.sh-290-81'; diff --git a/src/views/wired/views/actions/bot-follow-avatar/WiredActionBotFollowAvatarView.tsx b/src/components/wired/views/actions/WiredActionBotFollowAvatarView.tsx similarity index 89% rename from src/views/wired/views/actions/bot-follow-avatar/WiredActionBotFollowAvatarView.tsx rename to src/components/wired/views/actions/WiredActionBotFollowAvatarView.tsx index 73dec702..3351288c 100644 --- a/src/views/wired/views/actions/bot-follow-avatar/WiredActionBotFollowAvatarView.tsx +++ b/src/components/wired/views/actions/WiredActionBotFollowAvatarView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionBotFollowAvatarView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/bot-give-hand-item/WiredActionBotGiveHandItemView.tsx b/src/components/wired/views/actions/WiredActionBotGiveHandItemView.tsx similarity index 88% rename from src/views/wired/views/actions/bot-give-hand-item/WiredActionBotGiveHandItemView.tsx rename to src/components/wired/views/actions/WiredActionBotGiveHandItemView.tsx index 994e167c..1c998c9a 100644 --- a/src/views/wired/views/actions/bot-give-hand-item/WiredActionBotGiveHandItemView.tsx +++ b/src/components/wired/views/actions/WiredActionBotGiveHandItemView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; const allowedHanditemIds: number[] = [2, 5, 7, 8, 9, 10, 27]; diff --git a/src/views/wired/views/actions/bot-move/WiredActionBotMoveView.tsx b/src/components/wired/views/actions/WiredActionBotMoveView.tsx similarity index 79% rename from src/views/wired/views/actions/bot-move/WiredActionBotMoveView.tsx rename to src/components/wired/views/actions/WiredActionBotMoveView.tsx index 6e9f7f34..0ba69ae6 100644 --- a/src/views/wired/views/actions/bot-move/WiredActionBotMoveView.tsx +++ b/src/components/wired/views/actions/WiredActionBotMoveView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionBotMoveView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/bot-talk-to-avatar/WiredActionBotTalkToAvatarView.tsx b/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx similarity index 94% rename from src/views/wired/views/actions/bot-talk-to-avatar/WiredActionBotTalkToAvatarView.tsx rename to src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx index 5d16fdc7..19cf1e3f 100644 --- a/src/views/wired/views/actions/bot-talk-to-avatar/WiredActionBotTalkToAvatarView.tsx +++ b/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx @@ -1,7 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; import { LocalizeText } from '../../../../../api'; +import { WiredFurniType } from '../../../common/WiredFurniType'; +import { WIRED_STRING_DELIMETER } from '../../../common/WiredStringDelimeter'; import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType, WIRED_STRING_DELIMETER } from '../../../WiredView.types'; import { WiredActionBaseView } from '../base/WiredActionBaseView'; export const WiredActionBotTalkToAvatarView: FC<{}> = props => diff --git a/src/views/wired/views/actions/bot-talk/WiredActionBotTalkView.tsx b/src/components/wired/views/actions/WiredActionBotTalkView.tsx similarity index 89% rename from src/views/wired/views/actions/bot-talk/WiredActionBotTalkView.tsx rename to src/components/wired/views/actions/WiredActionBotTalkView.tsx index 6f90b9d6..bf92e915 100644 --- a/src/views/wired/views/actions/bot-talk/WiredActionBotTalkView.tsx +++ b/src/components/wired/views/actions/WiredActionBotTalkView.tsx @@ -1,8 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType, WIRED_STRING_DELIMETER } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WIRED_STRING_DELIMETER } from '../../common/WiredStringDelimeter'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionBotTalkView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/bot-teleport/WiredActionBotTeleportView.tsx b/src/components/wired/views/actions/WiredActionBotTeleportView.tsx similarity index 79% rename from src/views/wired/views/actions/bot-teleport/WiredActionBotTeleportView.tsx rename to src/components/wired/views/actions/WiredActionBotTeleportView.tsx index fde10dd8..e9170f68 100644 --- a/src/views/wired/views/actions/bot-teleport/WiredActionBotTeleportView.tsx +++ b/src/components/wired/views/actions/WiredActionBotTeleportView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionBotTeleportView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/call-another-stack/WiredActionCallAnotherStackView.tsx b/src/components/wired/views/actions/WiredActionCallAnotherStackView.tsx similarity index 64% rename from src/views/wired/views/actions/call-another-stack/WiredActionCallAnotherStackView.tsx rename to src/components/wired/views/actions/WiredActionCallAnotherStackView.tsx index 62342124..c3d310e2 100644 --- a/src/views/wired/views/actions/call-another-stack/WiredActionCallAnotherStackView.tsx +++ b/src/components/wired/views/actions/WiredActionCallAnotherStackView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionCallAnotherStackView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/chase/WiredActionChaseView.tsx b/src/components/wired/views/actions/WiredActionChaseView.tsx similarity index 63% rename from src/views/wired/views/actions/chase/WiredActionChaseView.tsx rename to src/components/wired/views/actions/WiredActionChaseView.tsx index 76bcfae0..5f5dbaac 100644 --- a/src/views/wired/views/actions/chase/WiredActionChaseView.tsx +++ b/src/components/wired/views/actions/WiredActionChaseView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionChaseView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/chat/WiredActionChatView.tsx b/src/components/wired/views/actions/WiredActionChatView.tsx similarity index 78% rename from src/views/wired/views/actions/chat/WiredActionChatView.tsx rename to src/components/wired/views/actions/WiredActionChatView.tsx index 07317241..098e064e 100644 --- a/src/views/wired/views/actions/chat/WiredActionChatView.tsx +++ b/src/components/wired/views/actions/WiredActionChatView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionChatView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/flee/WiredActionFleeView.tsx b/src/components/wired/views/actions/WiredActionFleeView.tsx similarity index 63% rename from src/views/wired/views/actions/flee/WiredActionFleeView.tsx rename to src/components/wired/views/actions/WiredActionFleeView.tsx index d8e37d0b..fcc76360 100644 --- a/src/views/wired/views/actions/flee/WiredActionFleeView.tsx +++ b/src/components/wired/views/actions/WiredActionFleeView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionFleeView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/give-reward/WiredActionGiveRewardView.tsx b/src/components/wired/views/actions/WiredActionGiveRewardView.tsx similarity index 97% rename from src/views/wired/views/actions/give-reward/WiredActionGiveRewardView.tsx rename to src/components/wired/views/actions/WiredActionGiveRewardView.tsx index 89bfb009..a956d4bc 100644 --- a/src/views/wired/views/actions/give-reward/WiredActionGiveRewardView.tsx +++ b/src/components/wired/views/actions/WiredActionGiveRewardView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionGiveRewardView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/give-score-to-predefined-team/WiredActionGiveScoreToPredefinedTeamView.tsx b/src/components/wired/views/actions/WiredActionGiveScoreToPredefinedTeamView.tsx similarity index 92% rename from src/views/wired/views/actions/give-score-to-predefined-team/WiredActionGiveScoreToPredefinedTeamView.tsx rename to src/components/wired/views/actions/WiredActionGiveScoreToPredefinedTeamView.tsx index 9fdaa57c..7895f4d3 100644 --- a/src/views/wired/views/actions/give-score-to-predefined-team/WiredActionGiveScoreToPredefinedTeamView.tsx +++ b/src/components/wired/views/actions/WiredActionGiveScoreToPredefinedTeamView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionGiveScoreToPredefinedTeamView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/give-score/WiredActionGiveScoreView.tsx b/src/components/wired/views/actions/WiredActionGiveScoreView.tsx similarity index 87% rename from src/views/wired/views/actions/give-score/WiredActionGiveScoreView.tsx rename to src/components/wired/views/actions/WiredActionGiveScoreView.tsx index a76a3cad..a73b1e87 100644 --- a/src/views/wired/views/actions/give-score/WiredActionGiveScoreView.tsx +++ b/src/components/wired/views/actions/WiredActionGiveScoreView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionGiveScoreView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/join-team/WiredActionJoinTeamView.tsx b/src/components/wired/views/actions/WiredActionJoinTeamView.tsx similarity index 86% rename from src/views/wired/views/actions/join-team/WiredActionJoinTeamView.tsx rename to src/components/wired/views/actions/WiredActionJoinTeamView.tsx index 7691100e..a6c75127 100644 --- a/src/views/wired/views/actions/join-team/WiredActionJoinTeamView.tsx +++ b/src/components/wired/views/actions/WiredActionJoinTeamView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionJoinTeamView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/kick-from-room/WiredActionKickFromRoomView.tsx b/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx similarity index 79% rename from src/views/wired/views/actions/kick-from-room/WiredActionKickFromRoomView.tsx rename to src/components/wired/views/actions/WiredActionKickFromRoomView.tsx index 5597da91..ce74fbbb 100644 --- a/src/views/wired/views/actions/kick-from-room/WiredActionKickFromRoomView.tsx +++ b/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionKickFromRoomView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/leave-team/WiredActionLeaveTeamView.tsx b/src/components/wired/views/actions/WiredActionLeaveTeamView.tsx similarity index 61% rename from src/views/wired/views/actions/leave-team/WiredActionLeaveTeamView.tsx rename to src/components/wired/views/actions/WiredActionLeaveTeamView.tsx index 67d13522..45e9be5f 100644 --- a/src/views/wired/views/actions/leave-team/WiredActionLeaveTeamView.tsx +++ b/src/components/wired/views/actions/WiredActionLeaveTeamView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionLeaveTeamView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/move-and-rotate-furni/WiredActionMoveAndRotateFurniView.tsx b/src/components/wired/views/actions/WiredActionMoveAndRotateFurniView.tsx similarity index 92% rename from src/views/wired/views/actions/move-and-rotate-furni/WiredActionMoveAndRotateFurniView.tsx rename to src/components/wired/views/actions/WiredActionMoveAndRotateFurniView.tsx index 51b80717..ed1d33d3 100644 --- a/src/views/wired/views/actions/move-and-rotate-furni/WiredActionMoveAndRotateFurniView.tsx +++ b/src/components/wired/views/actions/WiredActionMoveAndRotateFurniView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; const directionOptions: { value: number, icon: string }[] = [ { diff --git a/src/views/wired/views/actions/move-furni-to/WiredActionMoveFurniToView.tsx b/src/components/wired/views/actions/WiredActionMoveFurniToView.tsx similarity index 91% rename from src/views/wired/views/actions/move-furni-to/WiredActionMoveFurniToView.tsx rename to src/components/wired/views/actions/WiredActionMoveFurniToView.tsx index 1e362983..abf69e40 100644 --- a/src/views/wired/views/actions/move-furni-to/WiredActionMoveFurniToView.tsx +++ b/src/components/wired/views/actions/WiredActionMoveFurniToView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; const directionOptions: { value: number, icon: string }[] = [ { diff --git a/src/views/wired/views/actions/move-furni/WiredActionMoveFurniView.tsx b/src/components/wired/views/actions/WiredActionMoveFurniView.tsx similarity index 94% rename from src/views/wired/views/actions/move-furni/WiredActionMoveFurniView.tsx rename to src/components/wired/views/actions/WiredActionMoveFurniView.tsx index 18b36c5f..a494a58d 100644 --- a/src/views/wired/views/actions/move-furni/WiredActionMoveFurniView.tsx +++ b/src/components/wired/views/actions/WiredActionMoveFurniView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; const directionOptions: { value: number, icon: string }[] = [ { diff --git a/src/views/wired/views/actions/mute-user/WiredActionMuteUserView.tsx b/src/components/wired/views/actions/WiredActionMuteUserView.tsx similarity index 86% rename from src/views/wired/views/actions/mute-user/WiredActionMuteUserView.tsx rename to src/components/wired/views/actions/WiredActionMuteUserView.tsx index d362fe4b..d447c5f1 100644 --- a/src/views/wired/views/actions/mute-user/WiredActionMuteUserView.tsx +++ b/src/components/wired/views/actions/WiredActionMuteUserView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionMuteUserView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/reset/WiredActionResetView.tsx b/src/components/wired/views/actions/WiredActionResetView.tsx similarity index 60% rename from src/views/wired/views/actions/reset/WiredActionResetView.tsx rename to src/components/wired/views/actions/WiredActionResetView.tsx index 23d4cbf5..9645a9da 100644 --- a/src/views/wired/views/actions/reset/WiredActionResetView.tsx +++ b/src/components/wired/views/actions/WiredActionResetView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionResetView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/set-furni-state-to/WiredActionSetFurniStateToView.tsx b/src/components/wired/views/actions/WiredActionSetFurniStateToView.tsx similarity index 90% rename from src/views/wired/views/actions/set-furni-state-to/WiredActionSetFurniStateToView.tsx rename to src/components/wired/views/actions/WiredActionSetFurniStateToView.tsx index cc08521c..30df7087 100644 --- a/src/views/wired/views/actions/set-furni-state-to/WiredActionSetFurniStateToView.tsx +++ b/src/components/wired/views/actions/WiredActionSetFurniStateToView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionSetFurniStateToView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/teleport/WiredActionTeleportView.tsx b/src/components/wired/views/actions/WiredActionTeleportView.tsx similarity index 64% rename from src/views/wired/views/actions/teleport/WiredActionTeleportView.tsx rename to src/components/wired/views/actions/WiredActionTeleportView.tsx index f4390f4e..3ab7b330 100644 --- a/src/views/wired/views/actions/teleport/WiredActionTeleportView.tsx +++ b/src/components/wired/views/actions/WiredActionTeleportView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionTeleportView: FC<{}> = props => { diff --git a/src/views/wired/views/actions/toggle-furni-state/WiredActionToggleFurniStateView.tsx b/src/components/wired/views/actions/WiredActionToggleFurniStateView.tsx similarity index 64% rename from src/views/wired/views/actions/toggle-furni-state/WiredActionToggleFurniStateView.tsx rename to src/components/wired/views/actions/WiredActionToggleFurniStateView.tsx index fc7aed91..93a26197 100644 --- a/src/views/wired/views/actions/toggle-furni-state/WiredActionToggleFurniStateView.tsx +++ b/src/components/wired/views/actions/WiredActionToggleFurniStateView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredActionBaseView } from '../base/WiredActionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredActionBaseView } from './WiredActionBaseView'; export const WiredActionToggleFurniStateView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/actor-has-hand-item/WiredConditionActorHasHandItem.tsx b/src/components/wired/views/conditions/WiredConditionActorHasHandItem.tsx similarity index 83% rename from src/views/wired/views/conditions/actor-has-hand-item/WiredConditionActorHasHandItem.tsx rename to src/components/wired/views/conditions/WiredConditionActorHasHandItem.tsx index 2c680e5b..d4e5c625 100644 --- a/src/views/wired/views/conditions/actor-has-hand-item/WiredConditionActorHasHandItem.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorHasHandItem.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; const allowedHanditemIds: number[] = [ 2, 5, 7, 8, 9, 10, 27 ]; diff --git a/src/views/wired/views/conditions/actor-is-group-member/WiredConditionActorIsGroupMemberView.tsx b/src/components/wired/views/conditions/WiredConditionActorIsGroupMemberView.tsx similarity index 62% rename from src/views/wired/views/conditions/actor-is-group-member/WiredConditionActorIsGroupMemberView.tsx rename to src/components/wired/views/conditions/WiredConditionActorIsGroupMemberView.tsx index 8221f74b..8e5e59c2 100644 --- a/src/views/wired/views/conditions/actor-is-group-member/WiredConditionActorIsGroupMemberView.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorIsGroupMemberView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionActorIsGroupMemberView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/actor-is-on-furni/WiredConditionActorIsOnFurniView.tsx b/src/components/wired/views/conditions/WiredConditionActorIsOnFurniView.tsx similarity index 61% rename from src/views/wired/views/conditions/actor-is-on-furni/WiredConditionActorIsOnFurniView.tsx rename to src/components/wired/views/conditions/WiredConditionActorIsOnFurniView.tsx index fbafd294..5bdac45e 100644 --- a/src/views/wired/views/conditions/actor-is-on-furni/WiredConditionActorIsOnFurniView.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorIsOnFurniView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionActorIsOnFurniView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/actor-is-team-member/WiredConditionActorIsTeamMemberView.tsx b/src/components/wired/views/conditions/WiredConditionActorIsTeamMemberView.tsx similarity index 86% rename from src/views/wired/views/conditions/actor-is-team-member/WiredConditionActorIsTeamMemberView.tsx rename to src/components/wired/views/conditions/WiredConditionActorIsTeamMemberView.tsx index 041857a1..49a50017 100644 --- a/src/views/wired/views/conditions/actor-is-team-member/WiredConditionActorIsTeamMemberView.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorIsTeamMemberView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; const teamIds: number[] = [ 1, 2, 3, 4 ]; diff --git a/src/views/wired/views/conditions/actor-is-wearing-badge/WiredConditionActorIsWearingBadgeView.tsx b/src/components/wired/views/conditions/WiredConditionActorIsWearingBadgeView.tsx similarity index 78% rename from src/views/wired/views/conditions/actor-is-wearing-badge/WiredConditionActorIsWearingBadgeView.tsx rename to src/components/wired/views/conditions/WiredConditionActorIsWearingBadgeView.tsx index 00c18a4e..832b9630 100644 --- a/src/views/wired/views/conditions/actor-is-wearing-badge/WiredConditionActorIsWearingBadgeView.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorIsWearingBadgeView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionActorIsWearingBadgeView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/actor-is-wearing-effect/WiredConditionActorIsWearingEffectView.tsx b/src/components/wired/views/conditions/WiredConditionActorIsWearingEffectView.tsx similarity index 79% rename from src/views/wired/views/conditions/actor-is-wearing-effect/WiredConditionActorIsWearingEffectView.tsx rename to src/components/wired/views/conditions/WiredConditionActorIsWearingEffectView.tsx index 393cc759..1ccb5913 100644 --- a/src/views/wired/views/conditions/actor-is-wearing-effect/WiredConditionActorIsWearingEffectView.tsx +++ b/src/components/wired/views/conditions/WiredConditionActorIsWearingEffectView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionActorIsWearingEffectView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/base/WiredConditionBaseView.tsx b/src/components/wired/views/conditions/WiredConditionBaseView.tsx similarity index 70% rename from src/views/wired/views/conditions/base/WiredConditionBaseView.tsx rename to src/components/wired/views/conditions/WiredConditionBaseView.tsx index 4504765d..f2c6edfa 100644 --- a/src/views/wired/views/conditions/base/WiredConditionBaseView.tsx +++ b/src/components/wired/views/conditions/WiredConditionBaseView.tsx @@ -1,7 +1,12 @@ import { FC, useCallback } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredBaseView } from '../../base/WiredBaseView'; -import { WiredConditionBaseViewProps } from './WiredConditionBaseView.types'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredBaseView } from '../WiredBaseView'; + +export interface WiredConditionBaseViewProps +{ + requiresFurni: number; + save: () => void; +} export const WiredConditionBaseView: FC = props => { diff --git a/src/views/wired/views/conditions/date-range/WiredConditionDateRangeView.tsx b/src/components/wired/views/conditions/WiredConditionDateRangeView.tsx similarity index 90% rename from src/views/wired/views/conditions/date-range/WiredConditionDateRangeView.tsx rename to src/components/wired/views/conditions/WiredConditionDateRangeView.tsx index 843f8e3a..dec8ec0c 100644 --- a/src/views/wired/views/conditions/date-range/WiredConditionDateRangeView.tsx +++ b/src/components/wired/views/conditions/WiredConditionDateRangeView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionDateRangeView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/furni-has-avatar-on/WiredConditionFurniHasAvatarOnView.tsx b/src/components/wired/views/conditions/WiredConditionFurniHasAvatarOnView.tsx similarity index 61% rename from src/views/wired/views/conditions/furni-has-avatar-on/WiredConditionFurniHasAvatarOnView.tsx rename to src/components/wired/views/conditions/WiredConditionFurniHasAvatarOnView.tsx index 286273ae..4a79952a 100644 --- a/src/views/wired/views/conditions/furni-has-avatar-on/WiredConditionFurniHasAvatarOnView.tsx +++ b/src/components/wired/views/conditions/WiredConditionFurniHasAvatarOnView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionFurniHasAvatarOnView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/furni-has-furni-on/WiredConditionFurniHasFurniOnView.tsx b/src/components/wired/views/conditions/WiredConditionFurniHasFurniOnView.tsx similarity index 86% rename from src/views/wired/views/conditions/furni-has-furni-on/WiredConditionFurniHasFurniOnView.tsx rename to src/components/wired/views/conditions/WiredConditionFurniHasFurniOnView.tsx index f56f9ce4..afdb43d0 100644 --- a/src/views/wired/views/conditions/furni-has-furni-on/WiredConditionFurniHasFurniOnView.tsx +++ b/src/components/wired/views/conditions/WiredConditionFurniHasFurniOnView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionFurniHasFurniOnView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/furni-has-not-furni-on/WiredConditionFurniHasNotFurniOnView.tsx b/src/components/wired/views/conditions/WiredConditionFurniHasNotFurniOnView.tsx similarity index 86% rename from src/views/wired/views/conditions/furni-has-not-furni-on/WiredConditionFurniHasNotFurniOnView.tsx rename to src/components/wired/views/conditions/WiredConditionFurniHasNotFurniOnView.tsx index 4b5dc97a..1b1b0c7f 100644 --- a/src/views/wired/views/conditions/furni-has-not-furni-on/WiredConditionFurniHasNotFurniOnView.tsx +++ b/src/components/wired/views/conditions/WiredConditionFurniHasNotFurniOnView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionFurniHasNotFurniOnView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/furni-is-of-type/WiredConditionFurniIsOfTypeView.tsx b/src/components/wired/views/conditions/WiredConditionFurniIsOfTypeView.tsx similarity index 62% rename from src/views/wired/views/conditions/furni-is-of-type/WiredConditionFurniIsOfTypeView.tsx rename to src/components/wired/views/conditions/WiredConditionFurniIsOfTypeView.tsx index 2f2514a7..47d97cca 100644 --- a/src/views/wired/views/conditions/furni-is-of-type/WiredConditionFurniIsOfTypeView.tsx +++ b/src/components/wired/views/conditions/WiredConditionFurniIsOfTypeView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionFurniIsOfTypeView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/furni-matches-snapshot/WiredConditionFurniMatchesSnapshotView.tsx b/src/components/wired/views/conditions/WiredConditionFurniMatchesSnapshotView.tsx similarity index 90% rename from src/views/wired/views/conditions/furni-matches-snapshot/WiredConditionFurniMatchesSnapshotView.tsx rename to src/components/wired/views/conditions/WiredConditionFurniMatchesSnapshotView.tsx index 5f33aa4a..875ce507 100644 --- a/src/views/wired/views/conditions/furni-matches-snapshot/WiredConditionFurniMatchesSnapshotView.tsx +++ b/src/components/wired/views/conditions/WiredConditionFurniMatchesSnapshotView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionFurniMatchesSnapshotView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/time-elapsed-less/WiredConditionTimeElapsedLessView.tsx b/src/components/wired/views/conditions/WiredConditionTimeElapsedLessView.tsx similarity index 77% rename from src/views/wired/views/conditions/time-elapsed-less/WiredConditionTimeElapsedLessView.tsx rename to src/components/wired/views/conditions/WiredConditionTimeElapsedLessView.tsx index 0b3761ea..5f0ad4a4 100644 --- a/src/views/wired/views/conditions/time-elapsed-less/WiredConditionTimeElapsedLessView.tsx +++ b/src/components/wired/views/conditions/WiredConditionTimeElapsedLessView.tsx @@ -1,10 +1,10 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { GetWiredTimeLocale } from '../../../common/GetWiredTimeLocale'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { GetWiredTimeLocale } from '../../common/GetWiredTimeLocale'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionTimeElapsedLessView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/time-elapsed-more/WiredConditionTimeElapsedMoreView.tsx b/src/components/wired/views/conditions/WiredConditionTimeElapsedMoreView.tsx similarity index 77% rename from src/views/wired/views/conditions/time-elapsed-more/WiredConditionTimeElapsedMoreView.tsx rename to src/components/wired/views/conditions/WiredConditionTimeElapsedMoreView.tsx index c2e00f13..8c07c1e7 100644 --- a/src/views/wired/views/conditions/time-elapsed-more/WiredConditionTimeElapsedMoreView.tsx +++ b/src/components/wired/views/conditions/WiredConditionTimeElapsedMoreView.tsx @@ -1,10 +1,10 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { GetWiredTimeLocale } from '../../../common/GetWiredTimeLocale'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { GetWiredTimeLocale } from '../../common/GetWiredTimeLocale'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionTimeElapsedMoreView: FC<{}> = props => { diff --git a/src/views/wired/views/conditions/user-count-in-room/WiredConditionUserCountInRoomView.tsx b/src/components/wired/views/conditions/WiredConditionUserCountInRoomView.tsx similarity index 87% rename from src/views/wired/views/conditions/user-count-in-room/WiredConditionUserCountInRoomView.tsx rename to src/components/wired/views/conditions/WiredConditionUserCountInRoomView.tsx index ffb7f0b9..5f062029 100644 --- a/src/views/wired/views/conditions/user-count-in-room/WiredConditionUserCountInRoomView.tsx +++ b/src/components/wired/views/conditions/WiredConditionUserCountInRoomView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredConditionBaseView } from '../base/WiredConditionBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredConditionBaseView } from './WiredConditionBaseView'; export const WiredConditionUserCountInRoomView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/avatar-enter-room/WiredTriggerAvatarEnterRoomView.tsx b/src/components/wired/views/triggers/WiredTriggerAvatarEnterRoomView.tsx similarity index 89% rename from src/views/wired/views/triggers/avatar-enter-room/WiredTriggerAvatarEnterRoomView.tsx rename to src/components/wired/views/triggers/WiredTriggerAvatarEnterRoomView.tsx index ec754162..ac41ec5b 100644 --- a/src/views/wired/views/triggers/avatar-enter-room/WiredTriggerAvatarEnterRoomView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerAvatarEnterRoomView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerAvatarEnterRoomView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/avatar-says-something/WiredTriggerAvatarSaysSomethingView.tsx b/src/components/wired/views/triggers/WiredTriggerAvatarSaysSomethingView.tsx similarity index 91% rename from src/views/wired/views/triggers/avatar-says-something/WiredTriggerAvatarSaysSomethingView.tsx rename to src/components/wired/views/triggers/WiredTriggerAvatarSaysSomethingView.tsx index 6c87f122..305edb69 100644 --- a/src/views/wired/views/triggers/avatar-says-something/WiredTriggerAvatarSaysSomethingView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerAvatarSaysSomethingView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { GetSessionDataManager, LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { GetSessionDataManager, LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerAvatarSaysSomethingView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/avatar-walks-off-furni/WiredTriggerAvatarWalksOffFurniView.tsx b/src/components/wired/views/triggers/WiredTriggerAvatarWalksOffFurniView.tsx similarity index 63% rename from src/views/wired/views/triggers/avatar-walks-off-furni/WiredTriggerAvatarWalksOffFurniView.tsx rename to src/components/wired/views/triggers/WiredTriggerAvatarWalksOffFurniView.tsx index 4a9176ca..a436cee7 100644 --- a/src/views/wired/views/triggers/avatar-walks-off-furni/WiredTriggerAvatarWalksOffFurniView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerAvatarWalksOffFurniView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerAvatarWalksOffFurniView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/avatar-walks-on-furni/WiredTriggerAvatarWalksOnFurni.tsx b/src/components/wired/views/triggers/WiredTriggerAvatarWalksOnFurni.tsx similarity index 63% rename from src/views/wired/views/triggers/avatar-walks-on-furni/WiredTriggerAvatarWalksOnFurni.tsx rename to src/components/wired/views/triggers/WiredTriggerAvatarWalksOnFurni.tsx index 1584600d..4644babf 100644 --- a/src/views/wired/views/triggers/avatar-walks-on-furni/WiredTriggerAvatarWalksOnFurni.tsx +++ b/src/components/wired/views/triggers/WiredTriggerAvatarWalksOnFurni.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerAvatarWalksOnFurniView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/base/WiredTriggerBaseView.tsx b/src/components/wired/views/triggers/WiredTriggerBaseView.tsx similarity index 70% rename from src/views/wired/views/triggers/base/WiredTriggerBaseView.tsx rename to src/components/wired/views/triggers/WiredTriggerBaseView.tsx index 330b3405..47b5f669 100644 --- a/src/views/wired/views/triggers/base/WiredTriggerBaseView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerBaseView.tsx @@ -1,7 +1,12 @@ import { FC, useCallback } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredBaseView } from '../../base/WiredBaseView'; -import { WiredTriggerBaseViewProps } from './WiredTriggerBaseView.types'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredBaseView } from '../WiredBaseView'; + +export interface WiredTriggerBaseViewProps +{ + requiresFurni: number; + save: () => void; +} export const WiredTriggerBaseView: FC = props => { diff --git a/src/views/wired/views/triggers/bot-reached-avatar/WiredTriggerBotReachedAvatarView.tsx b/src/components/wired/views/triggers/WiredTriggerBotReachedAvatarView.tsx similarity index 79% rename from src/views/wired/views/triggers/bot-reached-avatar/WiredTriggerBotReachedAvatarView.tsx rename to src/components/wired/views/triggers/WiredTriggerBotReachedAvatarView.tsx index 0b2f3ea5..743069da 100644 --- a/src/views/wired/views/triggers/bot-reached-avatar/WiredTriggerBotReachedAvatarView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerBotReachedAvatarView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerBotReachedAvatarView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/bot-reached-stuff/WiredTriggerBotReachedStuffView.tsx b/src/components/wired/views/triggers/WiredTriggerBotReachedStuffView.tsx similarity index 79% rename from src/views/wired/views/triggers/bot-reached-stuff/WiredTriggerBotReachedStuffView.tsx rename to src/components/wired/views/triggers/WiredTriggerBotReachedStuffView.tsx index 7dab1532..7d3e992a 100644 --- a/src/views/wired/views/triggers/bot-reached-stuff/WiredTriggerBotReachedStuffView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerBotReachedStuffView.tsx @@ -1,8 +1,8 @@ import { FC, useCallback, useEffect, useState } from 'react'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerBotReachedStuffView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/collision/WiredTriggerCollisionView.tsx b/src/components/wired/views/triggers/WiredTriggerCollisionView.tsx similarity index 61% rename from src/views/wired/views/triggers/collision/WiredTriggerCollisionView.tsx rename to src/components/wired/views/triggers/WiredTriggerCollisionView.tsx index 2e76dbfe..2f7cb067 100644 --- a/src/views/wired/views/triggers/collision/WiredTriggerCollisionView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerCollisionView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerCollisionView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/execute-once/WiredTriggerExecuteOnceView.tsx b/src/components/wired/views/triggers/WiredTriggerExecuteOnceView.tsx similarity index 77% rename from src/views/wired/views/triggers/execute-once/WiredTriggerExecuteOnceView.tsx rename to src/components/wired/views/triggers/WiredTriggerExecuteOnceView.tsx index c9d84fac..ffda94dc 100644 --- a/src/views/wired/views/triggers/execute-once/WiredTriggerExecuteOnceView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerExecuteOnceView.tsx @@ -1,10 +1,10 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { GetWiredTimeLocale } from '../../../common/GetWiredTimeLocale'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { GetWiredTimeLocale } from '../../common/GetWiredTimeLocale'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggeExecuteOnceView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/execute-periodically-long/WiredTriggerExecutePeriodicallyLongView.tsx b/src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyLongView.tsx similarity index 82% rename from src/views/wired/views/triggers/execute-periodically-long/WiredTriggerExecutePeriodicallyLongView.tsx rename to src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyLongView.tsx index e2a0e565..1d00ec2c 100644 --- a/src/views/wired/views/triggers/execute-periodically-long/WiredTriggerExecutePeriodicallyLongView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyLongView.tsx @@ -1,10 +1,10 @@ import { FriendlyTime } from '@nitrots/nitro-renderer'; import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggeExecutePeriodicallyLongView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/execute-periodically/WiredTriggerExecutePeriodicallyView.tsx b/src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyView.tsx similarity index 77% rename from src/views/wired/views/triggers/execute-periodically/WiredTriggerExecutePeriodicallyView.tsx rename to src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyView.tsx index 423e43e4..494f5ef7 100644 --- a/src/views/wired/views/triggers/execute-periodically/WiredTriggerExecutePeriodicallyView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerExecutePeriodicallyView.tsx @@ -1,10 +1,10 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { GetWiredTimeLocale } from '../../../common/GetWiredTimeLocale'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { GetWiredTimeLocale } from '../../common/GetWiredTimeLocale'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggeExecutePeriodicallyView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/game-ends/WiredTriggerGameEndsView.tsx b/src/components/wired/views/triggers/WiredTriggerGameEndsView.tsx similarity index 61% rename from src/views/wired/views/triggers/game-ends/WiredTriggerGameEndsView.tsx rename to src/components/wired/views/triggers/WiredTriggerGameEndsView.tsx index 9f219b97..1e9c5bdf 100644 --- a/src/views/wired/views/triggers/game-ends/WiredTriggerGameEndsView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerGameEndsView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerGameEndsView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/game-starts/WiredTriggerGameStartsView.tsx b/src/components/wired/views/triggers/WiredTriggerGameStartsView.tsx similarity index 61% rename from src/views/wired/views/triggers/game-starts/WiredTriggerGameStartsView.tsx rename to src/components/wired/views/triggers/WiredTriggerGameStartsView.tsx index cee76c33..57650fa8 100644 --- a/src/views/wired/views/triggers/game-starts/WiredTriggerGameStartsView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerGameStartsView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerGameStartsView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/score-achieved/WiredTriggerScoreAchievedView.tsx b/src/components/wired/views/triggers/WiredTriggerScoreAchievedView.tsx similarity index 82% rename from src/views/wired/views/triggers/score-achieved/WiredTriggerScoreAchievedView.tsx rename to src/components/wired/views/triggers/WiredTriggerScoreAchievedView.tsx index 6dff18b3..7c32dba2 100644 --- a/src/views/wired/views/triggers/score-achieved/WiredTriggerScoreAchievedView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerScoreAchievedView.tsx @@ -1,9 +1,9 @@ import { FC, useCallback, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText } from '../../../../../api'; -import { useWiredContext } from '../../../context/WiredContext'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { LocalizeText } from '../../../../api'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { useWiredContext } from '../../context/WiredContext'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggeScoreAchievedView: FC<{}> = props => { diff --git a/src/views/wired/views/triggers/toggle-furni/WiredTriggerToggleFurniView.tsx b/src/components/wired/views/triggers/WiredTriggerToggleFurniView.tsx similarity index 62% rename from src/views/wired/views/triggers/toggle-furni/WiredTriggerToggleFurniView.tsx rename to src/components/wired/views/triggers/WiredTriggerToggleFurniView.tsx index 28ae43c8..9344d141 100644 --- a/src/views/wired/views/triggers/toggle-furni/WiredTriggerToggleFurniView.tsx +++ b/src/components/wired/views/triggers/WiredTriggerToggleFurniView.tsx @@ -1,6 +1,6 @@ import { FC } from 'react'; -import { WiredFurniType } from '../../../WiredView.types'; -import { WiredTriggerBaseView } from '../base/WiredTriggerBaseView'; +import { WiredFurniType } from '../../common/WiredFurniType'; +import { WiredTriggerBaseView } from './WiredTriggerBaseView'; export const WiredTriggerToggleFurniView: FC<{}> = props => { diff --git a/src/views/Styles.scss b/src/views/Styles.scss index db447719..29280d21 100644 --- a/src/views/Styles.scss +++ b/src/views/Styles.scss @@ -9,7 +9,6 @@ @import "./right-side/RightSideView"; @import "./room/RoomView"; @import "./room-host/RoomHostView"; -@import "./wired/WiredView"; @import "./mod-tools/ModToolsView"; @import "./user-settings/UserSettingsView"; @import "./user-profile/UserProfileVew"; diff --git a/src/views/main/MainView.tsx b/src/views/main/MainView.tsx index ec281f7e..7c1d36cb 100644 --- a/src/views/main/MainView.tsx +++ b/src/views/main/MainView.tsx @@ -8,6 +8,7 @@ import { CatalogView } from '../../components/catalog/CatalogView'; import { InventoryView } from '../../components/inventory/InventoryView'; import { NavigatorView } from '../../components/navigator/NavigatorView'; import { ToolbarView } from '../../components/toolbar/ToolbarView'; +import { WiredView } from '../../components/wired/WiredView'; import { useRoomSessionManagerEvent } from '../../hooks/events/nitro/session/room-session-manager-event'; import { TransitionAnimation, TransitionAnimationTypes } from '../../layout'; import { CampaignView } from '../campaign/CampaignView'; @@ -24,7 +25,6 @@ import { RightSideView } from '../right-side/RightSideView'; import { RoomHostView } from '../room-host/RoomHostView'; import { UserProfileView } from '../user-profile/UserProfileView'; import { UserSettingsView } from '../user-settings/UserSettingsView'; -import { WiredView } from '../wired/WiredView'; import { MainViewProps } from './MainView.types'; export const MainView: FC = props => diff --git a/src/views/wired/context/WiredContext.tsx b/src/views/wired/context/WiredContext.tsx deleted file mode 100644 index 26c42a7a..00000000 --- a/src/views/wired/context/WiredContext.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { createContext, FC, useContext } from 'react'; -import { IWiredContext, WiredContextProps } from './WiredContext.types'; - -const WiredContext = createContext({ - trigger: null, - setTrigger: null, - intParams: null, - setIntParams: null, - stringParam: null, - setStringParam: null, - furniIds: null, - setFurniIds: null, - actionDelay: null, - setActionDelay: null -}); - -export const WiredContextProvider: FC = props => -{ - return { props.children } -} - -export const useWiredContext = () => useContext(WiredContext); diff --git a/src/views/wired/context/WiredContext.types.ts b/src/views/wired/context/WiredContext.types.ts deleted file mode 100644 index 36d0f888..00000000 --- a/src/views/wired/context/WiredContext.types.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { Triggerable } from '@nitrots/nitro-renderer'; -import { Dispatch, ProviderProps, SetStateAction } from 'react'; - -export interface IWiredContext -{ - trigger: Triggerable; - setTrigger: Dispatch>; - intParams: number[], - setIntParams: Dispatch>; - stringParam: string; - setStringParam: Dispatch>; - furniIds: number[]; - setFurniIds: Dispatch>; - actionDelay: number; - setActionDelay: Dispatch>; -} - -export interface WiredContextProps extends ProviderProps -{ - -} diff --git a/src/views/wired/views/actions/base/WiredActionBaseView.types.ts b/src/views/wired/views/actions/base/WiredActionBaseView.types.ts deleted file mode 100644 index ef514b76..00000000 --- a/src/views/wired/views/actions/base/WiredActionBaseView.types.ts +++ /dev/null @@ -1,5 +0,0 @@ -export interface WiredActionBaseViewProps -{ - requiresFurni: number; - save: () => void; -} diff --git a/src/views/wired/views/base/WiredBaseView.types.ts b/src/views/wired/views/base/WiredBaseView.types.ts deleted file mode 100644 index b38c08da..00000000 --- a/src/views/wired/views/base/WiredBaseView.types.ts +++ /dev/null @@ -1,6 +0,0 @@ -export interface WiredBaseViewProps -{ - wiredType: string; - requiresFurni: number; - save: () => void; -} diff --git a/src/views/wired/views/conditions/base/WiredConditionBaseView.types.ts b/src/views/wired/views/conditions/base/WiredConditionBaseView.types.ts deleted file mode 100644 index 61d99f91..00000000 --- a/src/views/wired/views/conditions/base/WiredConditionBaseView.types.ts +++ /dev/null @@ -1,5 +0,0 @@ -export interface WiredConditionBaseViewProps -{ - requiresFurni: number; - save: () => void; -} diff --git a/src/views/wired/views/furni-selector/WiredFurniSelectorView.types.ts b/src/views/wired/views/furni-selector/WiredFurniSelectorView.types.ts deleted file mode 100644 index 4bca7969..00000000 --- a/src/views/wired/views/furni-selector/WiredFurniSelectorView.types.ts +++ /dev/null @@ -1,3 +0,0 @@ -export class WiredFurniSelectorViewProps -{ -} diff --git a/src/views/wired/views/triggers/base/WiredTriggerBaseView.types.ts b/src/views/wired/views/triggers/base/WiredTriggerBaseView.types.ts deleted file mode 100644 index 9e766aa8..00000000 --- a/src/views/wired/views/triggers/base/WiredTriggerBaseView.types.ts +++ /dev/null @@ -1,5 +0,0 @@ -export interface WiredTriggerBaseViewProps -{ - requiresFurni: number; - save: () => void; -}