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

Forms: improve styles naming and preview #41119

Open
simison opened this issue Jan 16, 2025 · 2 comments
Open

Forms: improve styles naming and preview #41119

simison opened this issue Jan 16, 2025 · 2 comments
Labels
[Block] Contact Form Form block (also see Contact Form label) [Feature] Forms Blocks Blocks designed to streamline user input and engagement, such as contact, newsletter sign-ups, etc. [Package] Forms [Pri] Normal [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it

Comments

@simison
Copy link
Member

simison commented Jan 16, 2025

Block style names are somewhat obscure. Since the preview popup nor the editor don't differ at all between style switches, it's impossible to understand how they look until you switch between them.

Image

Editor

Screen.Recording.2025-01-16.at.14.02.35.mov

Frontend

Screen.Recording.2025-01-16.at.14.04.56.mov
@simison simison added [Block] Contact Form Form block (also see Contact Form label) [Feature] Forms Blocks Blocks designed to streamline user input and engagement, such as contact, newsletter sign-ups, etc. [Package] Forms [Pri] Normal [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it labels Jan 16, 2025
@ntsekouras
Copy link
Member

I'm not sure how easy would be to solve this. The reason this is happening is because the selected style actually modifies the rendered output in php. This means there is a mismatch in the html between editor and front-end.

In general block styles should just add css rules. Having said that, maybe the animated and outline should be a block property instead of styles? 🤔

Even if we do that (or something similar to match html) here comes the question of the editing experience and how you update the placeholder and the label. I didn't explore anything in depth but it seemed nuanced. Maybe placeholder is only updated through Inspector controls? 🤔

@simison
Copy link
Member Author

simison commented Jan 17, 2025

Yeah, seems like this needs some proper thinking. I'm also not sure yet how to solve this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Contact Form Form block (also see Contact Form label) [Feature] Forms Blocks Blocks designed to streamline user input and engagement, such as contact, newsletter sign-ups, etc. [Package] Forms [Pri] Normal [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it
Projects
None yet
Development

No branches or pull requests

2 participants