From bdf57e932af2bd899ee1ce3083156193e75a742a Mon Sep 17 00:00:00 2001 From: Mateusz Borowczyk Date: Tue, 14 May 2024 15:57:30 +0200 Subject: [PATCH] Fix TextArea --- changelogs/unreleased/5748-textarea-fix.yml | 6 +++ src/Test/Data/Field.ts | 12 +++++ .../Components/TextFormInput.tsx | 4 +- .../ServiceInstanceForm.test.tsx | 49 +++++++++++++++++++ 4 files changed, 69 insertions(+), 2 deletions(-) create mode 100644 changelogs/unreleased/5748-textarea-fix.yml diff --git a/changelogs/unreleased/5748-textarea-fix.yml b/changelogs/unreleased/5748-textarea-fix.yml new file mode 100644 index 000000000..d5a0ceede --- /dev/null +++ b/changelogs/unreleased/5748-textarea-fix.yml @@ -0,0 +1,6 @@ +description: "Fix issue with updating textarea fields" +issue-nr: 5748 +change-type: patch +destination-branches: [master, iso7] +sections: + bugfix: "{{description}}" diff --git a/src/Test/Data/Field.ts b/src/Test/Data/Field.ts index 16ebb5752..fdfce7995 100644 --- a/src/Test/Data/Field.ts +++ b/src/Test/Data/Field.ts @@ -6,8 +6,20 @@ import { TextField, BooleanField, EnumField, + Textarea, } from "@/Core"; +export const textArea: Textarea = { + kind: "Textarea", + name: "textarea_field", + description: "description", + isOptional: true, + isDisabled: false, + defaultValue: "", + inputType: TextInputTypes.text, + type: "string", +}; + export const text: TextField = { kind: "Text", name: "text_field", diff --git a/src/UI/Components/ServiceInstanceForm/Components/TextFormInput.tsx b/src/UI/Components/ServiceInstanceForm/Components/TextFormInput.tsx index 0b4581c7d..ab2a10cf5 100644 --- a/src/UI/Components/ServiceInstanceForm/Components/TextFormInput.tsx +++ b/src/UI/Components/ServiceInstanceForm/Components/TextFormInput.tsx @@ -103,8 +103,8 @@ export const TextFormInput: React.FC = ({ > {isTextarea ? (