Adding blocks with animated backgrounds using the latest plugin from WebArea – WP Tavern

As always, I like to highlight some things on the lighter side of the WordPress world. We’ve had enough business acquisitions over the past week – all year, really – that we need to take a break and take advantage of the more experimental developments the community has to offer.

As is the case with the latest plugin from WebArea, Background animation blocks. It is a collection of six blocks with different animated effects.

i am obsessed with all the things related to space and the night sky, so I was immediately drawn to the Stars block. It has an animated background of single dots floating in the background. It is also the most advanced animation, following the end user’s mouse cursor.

Animated block of stars.

The Stars block has a size, scale, and color setting for the background effect. Each of the other blocks has unique options, depending on what they’re doing. Some, such as Bubbles and Gradient, allow the end user to control the animation speed. Others have multiple colored entries.

In total, the plugin provides six individual blocks with unique animation effects for the background. Indeed, they behave like the Group block, serving as a simple container.

Each of the blocks supports wide and full alignment. They allow users to control the colors of the text and the background. And, any other block can be placed inside, as you would expect from basic group or container blocks.

They do not support some of the new Gutenberg plugin layout features that other container type blocks have. It’s not necessary yet as these features haven’t landed in WordPress, but it’s something to watch out for in the future. However, it is quite easy to wrap these animated blocks in another Group block for these features. However, I prefer not to put the burden of nesting on the end user if possible.

The approach taken by the plugin developer has some drawbacks. Animated backgrounds could have been pasted over existing Group or Cover blocks for WordPress, essentially behaving like a settings plugin. An alternative route would also have been to create a single “animated container” block and allow the user to choose the specific background effect. With this method, the plugin author could have used the variations API to make each of the animations searchable and appear via the block inserter.

However, the individual block route has been done before. Automattic has taken the same approach through its Starscape and Waves blocks. They are simply shipped as separate plugins instead of being bundled into a collection. I prefer this solution because it allows users to choose only the blocks they want. Assuming the animated block library grows in future versions of the plugin, this could get overkill.

The second problem is that the plugin doesn’t use the theme’s color scheme in some cases. It uses the standard text and background color options for its blocks, but any custom setting only displays a color picker. For those who wish to use a theme-defined color in these cases, they should know the hex code. Or, just look at it to get it close enough.

Despite what are trivial issues at best, the plugin was fun to tinker with. Blocks don’t have to be relegated to the wackier side of WordPress. It’s pretty easy to adjust their settings for more subtle effects that might work for sites related to business or other types of sites.

Source link

Previous "Better Call Saul" star Rhea Seehorn comes alive in Paramount + series
Next Author Linda Hagan: "Belfast and Carrickfergus are as capable of casting mysteries as Edinburgh or Oxford"

No Comment

Leave a reply

Your email address will not be published. Required fields are marked *