WordPress / gutenberg

The Block Editor project for WordPress and beyond. Plugin is available from the official repository.
https://wordpress.org/gutenberg/
Other
10.42k stars 4.16k forks source link

Add {float:right} to group block #47114

Open burnuser opened 1 year ago

burnuser commented 1 year ago

As suggested in core https://core.trac.wordpress.org/ticket/57439 and advised to report it here:

Since group block has now a width control and justification, it can float like an image block!

The effect can be achieved with an individual defined CSS class (maybe in WP 6.2 site editor styles or a plugin like Simple CSS), for example:

.sidebox {float:right}

=> Added as additional CSS class "sidebox" to the group block in question.

But with such a really little CSS part and a simple check-box in the user interface in block inspector - according to a manual set group-width smaller than content-width - it would be a quick and easy way to deliver a completely new feature like well known side-boxes (Author-info, fact sheet, ... ) in magazines!

burnuser commented 1 year ago

Meanwhile I discovered, that not even a custom CSS class is necessary, because the already in WordPress for image aligning used standard CSS class alignright would do the job. The only missing part is an option in the user interface to allow group blocks floating!