Skip to content

retain the selected component (if any) when previewing a form configu… #2687

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

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

teboho
Copy link
Contributor

@teboho teboho commented Feb 11, 2025

…ration and coming back to the designer mode

@teboho
Copy link
Contributor Author

teboho commented Feb 11, 2025

Deals with this issue #2481

@teboho teboho requested a review from IvanIlyichev February 11, 2025 15:18
Copy link
Contributor

@IvanIlyichev IvanIlyichev left a comment

Choose a reason for hiding this comment

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

Hi @teboho. Please move this logic to the reducer and remove useEffect from the designerMainArea.

… configuration and coming back to the designer mode"

This reverts commit 8b68c4e.
@teboho teboho marked this pull request as draft February 21, 2025 17:22
@teboho teboho marked this pull request as ready for review March 18, 2025 13:01
@teboho
Copy link
Contributor Author

teboho commented Mar 18, 2025

preview.-.Made.with.Clipchamp.mp4

@teboho teboho requested a review from IvanIlyichev March 18, 2025 13:18
Copy link
Contributor

@IvanIlyichev IvanIlyichev left a comment

Choose a reason for hiding this comment

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

Hi @teboho. Please retest it, after switch to the preview mode and back I got an empty properties panel, see below.
Also the isPreview flag is used by the Preview button only, the designer doesn't take it into account and uses form mode during render. Designer should use the isPreview flag otherwise this flag can be removed. Previous implementation (with useEffect) worked because of multiple unneeded re-renders
image

@teboho teboho marked this pull request as draft March 19, 2025 08:15
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

Successfully merging this pull request may close these issues.

2 participants