Skip to content
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

Fix styling regression to autocompleters #14791

Closed
wants to merge 1 commit into from

Conversation

talldan
Copy link
Contributor

@talldan talldan commented Apr 3, 2019

Description

The styles of the autocompleters (slash inserter autocompleter and @ user autocompleter) regressed recently, and it looks like it was caused by the block-editor refactor. Some classnames were updated to block-editor in SCSS, but not in JS. I've updated them to use the block-editor prefix. However, as these components are still in the editor package, maybe I should have gone with the editor prefix instead?

How has this been tested?

  • Type / in a new paragraph. Observe that block icons in the autocompletion menu have correct padding.
  • Type @ in a new paragraph. Observe that icons and text in the autocompletion menu have correct padding/spacing.

Screenshots

Slash inserter before regression
Screen Shot 2019-04-03 at 5 53 00 pm

Slash inserter after regression
Screen Shot 2019-04-03 at 6 24 58 pm

Slash inserter after fix
Screen Shot 2019-04-03 at 6 25 49 pm

Types of changes

Bug fix (non-breaking change which fixes an issue)

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.

@talldan talldan added [Type] Bug An existing feature does not function as intended General Interface Parts of the UI which don't fall neatly under other labels. labels Apr 3, 2019
@talldan talldan added this to the 5.5 (Gutenberg) milestone Apr 3, 2019
@talldan talldan self-assigned this Apr 3, 2019
@@ -54,7 +54,7 @@ export function createBlockCompleter( {
} = {} ) {
return {
name: 'blocks',
className: 'editor-autocompleters__block',
className: 'block-editor-autocompleters__block',
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Should I have gone with block-editor, editor (changing the stylesheet instead), or both?

Copy link
Contributor

Choose a reason for hiding this comment

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

It seems like we should go with editor as we're declaring these in the editor module. Not sure why these classNames were changed.

@aduth
Copy link
Member

aduth commented Apr 3, 2019

This appears to be a duplicate of #14772

@aduth
Copy link
Member

aduth commented Apr 3, 2019

Let's go with #14772 . I've pushed commits for the revised proposal, which is as you mention in #14791 (comment) with "changing the stylesheet instead" (credited as co-authored commit).

@aduth aduth closed this Apr 3, 2019
@aduth aduth deleted the fix/autocompleter-styles branch April 3, 2019 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
General Interface Parts of the UI which don't fall neatly under other labels. [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants