pwkip / contact-form-7-conditional-fields

Wordpress Plugin: Contact Form 7 Conditional Fields
http://bdwm.be/wpcf7cf
22 stars 18 forks source link

Set display property of group. (display: inline / block / flex / ..) #83

Closed pwkip closed 2 years ago

pwkip commented 3 years ago

Right now it's possible to create a group as a block element (DIV) with [group my-group] or as an inline element (SPAN) with [group my-group inline]

There are other display types like flex, contents, table, grid, ...

Maybe add a property like this:

[group my-group display:flex]

Side note: [group my-group inline] should automatically resolve to [group my-group display:inline] for backwards compatibility.

pwkip commented 2 years ago

Think I had a brain fart while creating this issue. Obviously you can simply add the CSS property display:flex to the group here. The point is that there are 2 types of HTML elements: block level elements and inline elements. You can style them however you want, but it's a fact that you cannot nest a block level element inside an inline element.

More information here: https://conditional-fields-cf7.bdwm.be/inline/

Technical information here: https://developer.mozilla.org/en-US/docs/Web/HTML/Block-level_elements and https://developer.mozilla.org/en-US/docs/Web/HTML/Inline_elements