Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Added an "mvp" version of preview mode for checkboxes. I also added a button in the form builder to switch to preview mode for this component. We can change that later when we have implemented preview for all components and it becomes the default state, but in the meantime I think this is a good solution while we are transitioning to the new design. It allows users to test out the new view while the old one is still available.
This pull request does not include editing texts directly in the preview. I think we need to discuss with the designers exactly how this functionality should appear. It may be confusing for the users to see the same text editor appear twice (both in the middle section and in the right section).
Related Issue(s)
Verification
It works, but there are some issues in the design system's
CheckboxGroup
component. Labels should not listen to click events in presentation mode (since there are buttons inside the labels), and there is also some weird behaviour when selecting a checkbox.Documentation