Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for https://github.com/kevinchappell/formBuilder/issues/699 #1487

Merged
merged 6 commits into from
Dec 8, 2023

Conversation

Shinbar
Copy link
Contributor

@Shinbar Shinbar commented Nov 23, 2023

After recently using this great project, I found that TextArea content are not being preserved, as they are being converted into a single value input of input[type=text]. This removes formatting from the TextArea such as line feeds etc.

I have amended the code so that TextArea are provided a proper TextArea control, and that the innerHTML data is preserved.

I believe this solved the following issue.

Fixes: #699

…ingle input[type=text] value. Formatting of TextAreas is now preserved.
@Shinbar Shinbar changed the title For TextArea controls changed value input into a textarea and not a single input[type=text] value. #699 Pull request to fix https://github.com/kevinchappell/formBuilder/issues/699 Nov 23, 2023
@lucasnetau
Copy link
Collaborator

Thank you @Shinbar for your PR. I'll will review

Copy link
Collaborator

@lucasnetau lucasnetau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Shinbar thanks for the PR. I've added some comments and suggested changes.

src/js/form-builder.js Outdated Show resolved Hide resolved
src/js/form-builder.js Outdated Show resolved Hide resolved
src/js/form-builder.js Outdated Show resolved Hide resolved
@lucasnetau
Copy link
Collaborator

Also, if possible can you please adjust your commit message to include the prefix 'fix: ' so it becomes

fix: For TextArea control have made the value input a textarea and not a single input[type=text] value. Formatting of TextAreas is now preserved.

Shinbar and others added 3 commits November 24, 2023 10:27
Co-authored-by: James Lucas <james@lucas.net.au>
Co-authored-by: James Lucas <james@lucas.net.au>
Co-authored-by: James Lucas <james@lucas.net.au>
@Shinbar Shinbar changed the title Pull request to fix https://github.com/kevinchappell/formBuilder/issues/699 Fix for https://github.com/kevinchappell/formBuilder/issues/699 Nov 24, 2023
Shinbar and others added 2 commits November 24, 2023 14:53
…t a single input[type=text] value. Formatting of TextAreas is now preserved.

Update src/js/form-builder.js

Co-authored-by: James Lucas <james@lucas.net.au>
…t a single input[type=text] value. Formatting of TextAreas is now preserved.
@lucasnetau
Copy link
Collaborator

LGTM

@kevinchappell any issues with this change for textareas?

Copy link
Owner

@kevinchappell kevinchappell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changes look good. thank you @Shinbar

@kevinchappell kevinchappell merged commit ad01ca9 into kevinchappell:master Dec 8, 2023
1 check passed
Copy link

github-actions bot commented Dec 8, 2023

🎉 This PR is included in version 3.17.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants