surveyjs / survey-library

Free JavaScript form builder library with integration for React, Angular, Vue, jQuery, and Knockout.
https://surveyjs.io/form-library
MIT License
4.2k stars 813 forks source link

How to style checkboxes and other questions individually? #4335

Open brundles opened 2 years ago

brundles commented 2 years ago

Are you requesting a feature, reporting a bug or asking a question?

Asking a question

What is the current behavior?

I can use Checkboxes, Radiobuttons, etc. to give the user the different options, but would like to style the questions better.

What is the expected behavior?

I was hoping to style Checkboxes with images somehow. This could perhaps be via CSS or otherwise, but I'm not sure where to do it.

An example of the end-result I am looking for is described in the below image:

image

And for single-selection type questions it would be nice to be able to make something like this:

image

How would you reproduce the current behavior (if this is a bug)?

Just create a checkbox-type question (or single-selection like radiobutton) and then I'd like to somehow style it as above.

andrewtelnov commented 2 years ago

@brundles You can use image picker for the first type questions. Regarding the second question, we have buttongroup question type that we use in our Creator V2. We do not have it in our library yet. Do you use react?

Thank you, Andrew

brundles commented 2 years ago

Hi there, excellent - thank you. Can I custom style the selected image in the image picker? (I'm fluent in CSS and JS of course).

I can use React - but also any other technology if it helps with this. When do you expect to launch the buttongroup - and do you have more information about it?