Skip to content

Fixing duplicated wp-block classes in block-list - #24466

Merged
talldan merged 1 commit into
WordPress:masterfrom
aktasfatih:fix/dublicate-classnames
Aug 14, 2020
Merged

talldan merged 1 commit into
WordPress:masterfrom
aktasfatih:fix/dublicate-classnames

Conversation

@aktasfatih

Copy link
Copy Markdown
Member

Description

Note: This is my first PR.

Fixes issue #24367

I removed the isAlign check for block-wrapper.js of block-list in block-editor. This check is already done in block.js. Doing it again causes the wp-block class to show up twice in the block-list.

How has this been tested?

I tested it on Firefox in Ubuntu to see if anything was broken.

I added some blocks in the editor. I couldn't find anything that was misaligned or didn't show up. All the blocks in the block-list had one wp-block class. No more duplicated wp-block classes.

Then, I ran the npm run test script. I didn't get any errors.

Types of changes

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.
  • I've included developer documentation if appropriate.
  • I've updated all React Native files affected by any refactorings/renamings in this PR.

@talldan talldan added [Feature] Blocks Overall functionality of blocks [Type] Bug An existing feature does not function as intended First-time Contributor Pull request opened by a first-time contributor to Gutenberg repository labels Aug 14, 2020

@talldan talldan left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks so much for picking this up @aktasfatih, the fix looks good to me.

I tested with a variety of blocks, couldn't spot any issues, and the wp-block classname was deduplicated.

Congrats on your first contribution 🎉

@talldan
talldan merged commit 5171c2e into WordPress:master Aug 14, 2020
@github-actions

Copy link
Copy Markdown

Congratulations on your first merged pull request, @aktasfatih! We'd like to credit you for your contribution in the post announcing the next WordPress release, but we can't find a WordPress.org profile associated with your GitHub account. When you have a moment, visit the following URL and click "link your GitHub account" under "GitHub Username" to link your accounts:

https://profiles.wordpress.org/me/profile/edit/

And if you don't have a WordPress.org account, you can create one on this page:

https://login.wordpress.org/register

Kudos!

@github-actions github-actions Bot added this to the Gutenberg 8.8 milestone Aug 14, 2020
@aktasfatih
aktasfatih deleted the fix/dublicate-classnames branch August 19, 2020 18:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Feature] Blocks Overall functionality of blocks First-time Contributor Pull request opened by a first-time contributor to Gutenberg repository [Type] Bug An existing feature does not function as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants