From ffe7b1f9e8d34793d0c102e271a73950732a1963 Mon Sep 17 00:00:00 2001 From: Tolulope Adetula <31691737+Tooluloope@users.noreply.github.com> Date: Mon, 6 Sep 2021 15:57:15 +0100 Subject: [PATCH] fix: add expected structure example to api pane based on the new validation structure (#6886) --- .../editorComponents/form/fields/KeyValueFieldArray.tsx | 2 +- app/client/src/pages/Editor/APIEditor/PostBodyData.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/client/src/components/editorComponents/form/fields/KeyValueFieldArray.tsx b/app/client/src/components/editorComponents/form/fields/KeyValueFieldArray.tsx index f70ccd5565..351b348e43 100644 --- a/app/client/src/components/editorComponents/form/fields/KeyValueFieldArray.tsx +++ b/app/client/src/components/editorComponents/form/fields/KeyValueFieldArray.tsx @@ -108,7 +108,7 @@ const DynamicDropdownFieldWrapper = styled.div` const expected = { type: FIELD_VALUES.API_ACTION.params, - example: "", + example: "string", autocompleteDataType: AutocompleteDataType.STRING, }; diff --git a/app/client/src/pages/Editor/APIEditor/PostBodyData.tsx b/app/client/src/pages/Editor/APIEditor/PostBodyData.tsx index 8d68d95251..ab460e1b0f 100644 --- a/app/client/src/pages/Editor/APIEditor/PostBodyData.tsx +++ b/app/client/src/pages/Editor/APIEditor/PostBodyData.tsx @@ -50,7 +50,7 @@ type Props = PostDataProps; const expectedPostBody: CodeEditorExpected = { type: FIELD_VALUES.API_ACTION.body, - example: "", + example: '{\n "color":"blue",\n "isVisible": true \n}', autocompleteDataType: AutocompleteDataType.OBJECT, };