New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin: Deprecate gutenberg_add_admin_body_class #13572

Merged
merged 2 commits into from Jan 31, 2019

Conversation

Projects
3 participants
@aduth
Copy link
Member

aduth commented Jan 29, 2019

This pull request seeks to deprecate gutenberg_add_admin_body_class in favor of the equivalent core behavior which assigns block editor classes. As of #13449, Gutenberg declares itself as the block editor screen. You can confirm from the master branch that these classes are in-fact added twice to the page.

The notable omission here is the gutenberg-editor-page class. An alternative implementation here is to keep the filter, but apply only the Gutenberg-specific class, if it could serve of any value. Most any plugin should extend block editor styles using the block-editor-page class name instead, however. See also #10783.

Testing instructions:

Verify when viewing the editor while Gutenberg is active, that the block-editor-page, is-fullscreen-mode, wp-embed-responsive, and is-dark-theme (as applicable) are applied.

@aduth aduth added this to In Progress in Remove PHP via automation Jan 29, 2019

@jorgefilipecosta
Copy link
Member

jorgefilipecosta left a comment

LGTM 👍
I did the following checks:

  • the only class that is removed from body when compared with the previous version is "gutenberg-editor-page".
  • "gutenberg-editor-page" class is not used in any of our styles.
  • gutenberg_add_admin_body_class function is not called anywhere.

@aduth aduth merged commit 62f6163 into master Jan 31, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

Remove PHP automation moved this from In Progress to Done Jan 31, 2019

@aduth aduth deleted the deprecate/gutenberg_add_admin_body_class branch Jan 31, 2019

daniloercoli added a commit that referenced this pull request Feb 1, 2019

Merge branch 'master' of https://github.com/WordPress/gutenberg into …
…rnmobile/372-use-RichText-on-Title-block

* 'master' of https://github.com/WordPress/gutenberg:
  Try alternate list item jump fix. (#12941)
  Mobile bottom sheet component (#13612)
  Remove unintentional right-margin on last odd-item. (#12199)
  Introduce left and right float alignment options to latest posts block (#8814)
  Fix Google Docs table paste (#13543)
  Increase bottom padding on gallery image caption (#13623)
  Fix the editor save keyboard shortcut not working in code editor view (#13159)
  Plugin: Deprecate gutenberg_add_admin_body_class (#13572)
  Rnmobile/upload media failed state (#13615)
  Make clickOnMoreMenuItem not dependent on aria labels (#13166)
  Add: className prop support to server side render. (#13568)
  Fix: Categories Block: hierarchical Dropdown (#13567)
  Docs: Add clarification about git workflow (#13534)
  Plugin: Remove `user_can_richedit` filtering (#13608)
  eslint-plugin: Add rule `no-unused-vars-before-return` (#12828)
  Image settings button (#13597)
  Fixed wording for the color picker saturation (#13479)

# Conflicts:
#	packages/block-library/src/image/edit.native.js

@youknowriad youknowriad added this to the 5.0 (Gutenberg) milestone Feb 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment