From 9dffdd6e0ad72c6fc79d2f808f8ab664381331d4 Mon Sep 17 00:00:00 2001 From: JF-Cozy Date: Wed, 18 Dec 2024 10:01:32 +0100 Subject: [PATCH] feat: Add two more intent route. You now need to use `path` option in Intent to select route --- src/targets/intents/index.jsx | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/targets/intents/index.jsx b/src/targets/intents/index.jsx index 6699b0a6..11c1f06a 100644 --- a/src/targets/intents/index.jsx +++ b/src/targets/intents/index.jsx @@ -24,17 +24,19 @@ import setupApp from 'src/targets/browser/setupApp' import { EditLoader } from 'src/components/Views/Edit' import { AppProviders } from 'src/components/AppProviders' import ErrorBoundary from 'src/components/Views/ErrorBoundary' +import ContactEdit from 'src/components/Views/ContactEdit' +import InformationEdit from 'src/components/Views/InformationEdit' -export const IntentWrapper = () => { +export const IntentWrapper = ({ Component }) => { const { service } = useIntent() - return + return } const IntentLoader = () => { const { data } = useIntent() - return + return } const makeRoutes = ({ client, intentId, ...rest }) => [ @@ -57,7 +59,17 @@ const makeRoutes = ({ client, intentId, ...rest }) => [ }, { path: ':qualificationLabel/:fileId', - element: , + element: , + errorElement: + }, + { + path: ':qualificationLabel/:fileId/edit/information', + element: , + errorElement: + }, + { + path: ':qualificationLabel/:fileId/edit/contact', + element: , errorElement: } ]