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

feature/add-field-support: Add support for all cf7 fields #8

Open
imranhsayed opened this issue Oct 26, 2019 · 6 comments
Open

feature/add-field-support: Add support for all cf7 fields #8

imranhsayed opened this issue Oct 26, 2019 · 6 comments

Comments

@imranhsayed
Copy link
Owner

Add support for all cf7 fields

@imranhsayed imranhsayed changed the title Add support for all cf7 fields feature/add-field-support: Add support for all cf7 fields Oct 26, 2019
@imranhsayed
Copy link
Owner Author

imranhsayed commented Oct 31, 2019

Add support for:

  1. Checkbox
  2. Multiselect
  3. Textarea
  4. Quiz etc

@minnifer
Copy link

I'd like to help work on the Checkbox form, if possible? I need it for a project I'm working on and would like to help, but I'm not sure how!

@luisherranz
Copy link
Collaborator

@imranhsayed could you please help @minnifer to contribute to the package with support for the checkbox?

@imranhsayed
Copy link
Owner Author

Hi @luisherranz ,
I am preoccupied with a lot of work lately. Just had a look at your message.
We will certainly help @minnifer to add support for checkboxes as soon as I get free.
Thank you 😊

@dejangeorgiev
Copy link

dejangeorgiev commented Sep 24, 2020

hi @imranhsayed

Add support for:

  1. Checkbox
  2. Multiselect
  3. Textarea
  4. Quiz etc

vote for files upload here. :)

@davidrhoderick
Copy link

@dejangeorgiev , @minnifer , and @imranhsayed , I have started a PR at #37. It doesn't provide full functionality for checkboxes but it will allow singular option checkboxes (without default checking) to work. This works for my usage at the moment but it needs to be fleshed out:

My guess is that in the cf7Checkboxes processor, we want to actually test for the wrapper class and then iterate over the options inside that and add them to an array for that input's name when they are checked. This would be similar to how the Select component is built out using .map() on the inputProps.options. If an array is too hairy to use directly in the submission, perhaps it's easier to use .join() and .split() either in submission or in the onChange() handler within the Checkbox component, which is possible because the values are very predictable. I just foresee an issue if someone wants to use "," (or whatever we use to combine the array items e.g., "|") in a singular option and we are .join()ing or .split()ing on that separator...

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

No branches or pull requests

5 participants