From 88c23a6ee9f598c9cf31f1999cf6a9c712d8d6e0 Mon Sep 17 00:00:00 2001 From: pianist <26953709+Pianist038801@users.noreply.github.com> Date: Mon, 25 Oct 2021 18:43:14 -0400 Subject: [PATCH] fix: json bug on struct input (#233) * fix: json bug on struct input Signed-off-by: Pianist038801 * fix: update json form button color Signed-off-by: Pianist038801 Co-authored-by: Pianist038801 --- src/components/Launch/LaunchForm/StructInput.tsx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/components/Launch/LaunchForm/StructInput.tsx b/src/components/Launch/LaunchForm/StructInput.tsx index 7ef9c91e78..d90ef58a14 100644 --- a/src/components/Launch/LaunchForm/StructInput.tsx +++ b/src/components/Launch/LaunchForm/StructInput.tsx @@ -13,6 +13,13 @@ const muiTheme = createMuiTheme({ MuiTextField: { variant: 'outlined' } + }, + overrides: { + MuiButton: { + label: { + color: 'gray' + } + } } }); @@ -76,7 +83,7 @@ export const StructInput: React.FC = props => { } const [paramData, setParamData] = useState( - jsonFormRenderable ? JSON.parse(value as string) : {} + jsonFormRenderable && value ? JSON.parse(value as string) : {} ); const onFormChange = ({ formData }, e) => {