From c7b5dbe4055d820426a1d4bb80e6394f62474aec Mon Sep 17 00:00:00 2001 From: Guillaume Falvet Date: Sat, 25 May 2024 12:50:57 +0200 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat=20:=20setup=20a=20router=20to?= =?UTF-8?q?=20better=20manage=20multiple=20plugin?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- property-inspector/src/router.tsx | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 property-inspector/src/router.tsx diff --git a/property-inspector/src/router.tsx b/property-inspector/src/router.tsx new file mode 100644 index 0000000..1d1bd82 --- /dev/null +++ b/property-inspector/src/router.tsx @@ -0,0 +1,27 @@ +import { lazy } from 'react'; +const IncrementAction = lazy(() => import('./actions/IncrementAction')); +const LightSwitchAction = lazy(() => import('./actions/LightSwitchAction')); + +// - Types +import { ParsedProps } from './types/streamDeck'; + +// - Shared +import { INCREMENT_COUNTER_UUID, LIGHT_SWITCH_UUID } from 'shared'; + + +export default function RouterAction(props: ParsedProps) { + + switch (props.inActionInfo.action) { + case INCREMENT_COUNTER_UUID: + return + case LIGHT_SWITCH_UUID: + return + default: + return ( +
+ Unknown Action +
+ ); + } +} +