From 9833caa7ffce6a0716afd584accec0252bd8fc48 Mon Sep 17 00:00:00 2001 From: frikky Date: Thu, 14 Jul 2022 18:35:31 +0200 Subject: [PATCH] Updated the app explorer page with download potential --- frontend/src/components/DetectionFramework.jsx | 6 ++++-- frontend/src/views/Docs.jsx | 4 +++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/DetectionFramework.jsx b/frontend/src/components/DetectionFramework.jsx index 6614513b..f4144cdc 100644 --- a/frontend/src/components/DetectionFramework.jsx +++ b/frontend/src/components/DetectionFramework.jsx @@ -518,7 +518,7 @@ export const usecases = { } const Framework = (props) => { - const {globalUrl, isLoaded, showOptions, selectedOption, rolling, frameworkData, size, inputUsecase, isLoggedIn, } = props; + const { globalUrl, isLoaded, showOptions, selectedOption, rolling, frameworkData, size, inputUsecase, isLoggedIn, color } = props; const [cy, setCy] = React.useState() const [edgesStarted, setEdgesStarted] = React.useState(false) const [graphDone, setGraphDone] = React.useState(false) @@ -1371,8 +1371,10 @@ const Framework = (props) => { //} } + const bgColor = color === undefined || color === null || color.length === 0 ? theme.palette.surfaceColor : color + return ( - + {data.name} diff --git a/frontend/src/views/Docs.jsx b/frontend/src/views/Docs.jsx index 24bfe359..ef548460 100644 --- a/frontend/src/views/Docs.jsx +++ b/frontend/src/views/Docs.jsx @@ -245,6 +245,7 @@ const Docs = (defaultprops) => { if (props.match.params.key === undefined) { } else { + console.log("DOCID: ", props.match.params.key) fetchDocs(props.match.params.key) } } @@ -272,7 +273,8 @@ const Docs = (defaultprops) => { .split("_") .join(" ") .split("-") - .join(" "); + .join(" ") + .split("?")[0] //console.log(name) var found = false;