From 2ef0c8e9c38ffefd9c7112e84a0bffc43890b603 Mon Sep 17 00:00:00 2001 From: Chris Hunt Date: Tue, 10 Jan 2023 12:00:16 +0000 Subject: [PATCH] Fix missing image recursion Fix add app link not being highlighted --- site/components/header.js | 2 +- site/pages/addapp/[[...app]].js | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/site/components/header.js b/site/components/header.js index 9fa4a42..c0b19e5 100644 --- a/site/components/header.js +++ b/site/components/header.js @@ -47,7 +47,7 @@ export default function Header({ searchText, changeSearch }) {
diff --git a/site/pages/addapp/[[...app]].js b/site/pages/addapp/[[...app]].js index dbdccf9..9a807f3 100644 --- a/site/pages/addapp/[[...app]].js +++ b/site/pages/addapp/[[...app]].js @@ -31,7 +31,7 @@ export async function getStaticProps({ params }) { } } -export default function AddApp({ app = null }) { +export default function AddApp({ app }) { function friendlyUrl(url) { // make the url lowercase @@ -98,12 +98,14 @@ export default function AddApp({ app = null }) { // const { app } = router.query useEffect(() => { + console.log(app) if(app === null) { description.current.value = '' name.current.value = '' friendly_name.current.value = '' setCategories(null) setArchitecture(null) + setIcon(null) setApplication(defaultState) } else if (app && app[0]) { @@ -211,6 +213,7 @@ export default function AddApp({ app = null }) { file: event.target.files[0] }) setExt(event.target.value.substr(event.target.value.lastIndexOf('.') + 1)) + setInlineImage(null) // return } @@ -257,6 +260,7 @@ export default function AddApp({ app = null }) { Architecture