Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Blocks: Add the missing alignments classNames to the Cover Image Block's markup #4060
Tiny PR adding the missing alignment classNames to the cover image block. It also declares a "deprecated" version to avoid invalidating old cover image blocks.
add_theme_support( 'gutenberg', array( 'wide-images' => true, ) );
Seems an extreme change to fix a minor bug
mmmm, It's not. I guess I assumed it was "center" because I had a "centered" cover image when testing.
So this makes things easier IMO. We can just drop the "deprecated" declaration as is. This could produce "invalid" blocks but the chance for it to happen is small.
Yes, I also share the same view. That it is a lot of code to add and process to fix a very small bug for a relatively simple block. We should watch closely how deprecation feature is used for blocks and take an action if this becomes too complicated to manage. On the other hand, maybe we should always copy and paste the version that gets updated but put everything in their own file to make sure it doesn't pollute the existing solution.
The fix itself looks good :)