Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#45244 closed defect (bug) (fixed)

Twenty Fifteen: Issues in theme’s Gutenberg support & styles

Reported by: laurelfulford's profile laurelfulford Owned by: laurelfulford's profile laurelfulford
Milestone: 5.0 Priority: normal
Severity: normal Version: 5.0
Component: Bundled Theme Keywords: has-patch, needs-testing, has-screenshots, dev-reviewed, fixed-5.0
Focuses: Cc:

Description

I’ve re-reviewed the Gutenberg support that added in #45043, primarily to find anything that might have been missed, but also make sure none of the other changes happening during 5.0 development so far created a need for theme updates, too.

I opted to combine my findings per theme into one ticket, since many of the issues showed up in more than one of the default themes — it seemed like it would make it easier to review and commit these fixes, given the timeline.

In Twenty Fifteen, I found these issues:

  1. Centred widget lists (Categories, Archives…) need to be text centred, like the editor.
  2. Spacing is missing next to blocks when floated left and right (eg. Cover block, or button block).
  3. The cover blocks need to have their styles updated to add the newer non -image- variations of the cover block classes (.wp-block-cover and .wp-block-cover-text)
  4. The Media & Text block does not have spacing underneath it.
  5. Editor width selectors can be simplified to just use wp-block in Gutenberg 4.2 RC 1.
  6. The margin styles being pulled in from the theme’s original editor styles are causing the content in Gutenberg to list to the left. This is new in Gutenberg’s 4.2 RC 1 as well.

Attachments (12)

twenty-fifteen-centred-categories-before.png (92.2 KB) - added by laurelfulford 6 years ago.
1. Centred category widget, not being centred
twenty-fifteen-aligned-blocks2-before.png (185.7 KB) - added by laurelfulford 6 years ago.
2. Floated cover blocks, without spacing around them
twenty-fifteen-media-text-before.png (212.3 KB) - added by laurelfulford 6 years ago.
4. Media & Text block without spacing underneath
twenty-fifteen-editor-width-before.png (130.7 KB) - added by laurelfulford 6 years ago.
6. Editor - content sitting to the left
45244.patch (3.0 KB) - added by laurelfulford 6 years ago.
twenty-fifteen-centred-categories-after.png (88.7 KB) - added by laurelfulford 6 years ago.
1. Centred category widget, fixed
twenty-fifteen-aligned-blocks2-after.png (163.5 KB) - added by laurelfulford 6 years ago.
2. Floated cover blocks, with spacing
twenty-fifteen-media-text-after.png (219.9 KB) - added by laurelfulford 6 years ago.
4. Media & Text block with spacing
twenty-fifteen-editor-width-after.png (123.4 KB) - added by laurelfulford 6 years ago.
6. Editor alignment, after fix
45244.1.patch (3.6 KB) - added by laurelfulford 6 years ago.
twenty-fifteen-remove-bottom-margin-last-child-media-text.png (208.2 KB) - added by laurelfulford 6 years ago.
Twenty Fifteen - remove margin under last child in Media & Text block
twenty-fifteen-centred-widget-bullet.png (47.0 KB) - added by laurelfulford 6 years ago.
Twenty Fifteen - centre bullets in centred list widgets

Download all attachments as: .zip

Change History (21)

@laurelfulford
6 years ago

  1. Centred category widget, not being centred

@laurelfulford
6 years ago

  1. Floated cover blocks, without spacing around them

@laurelfulford
6 years ago

  1. Media & Text block without spacing underneath

@laurelfulford
6 years ago

  1. Editor - content sitting to the left

@laurelfulford
6 years ago

@laurelfulford
6 years ago

  1. Centred category widget, fixed

@laurelfulford
6 years ago

  1. Floated cover blocks, with spacing

@laurelfulford
6 years ago

  1. Media & Text block with spacing

@laurelfulford
6 years ago

  1. Editor alignment, after fix

#1 @laurelfulford
6 years ago

45244.patch includes all the fixes for the above issues, but I only included screenshots where it seemed helpful!

#2 @davidakennedy
6 years ago

Hey @laurelfulford – like Twenty Fourteen, this patch looks good, save for a similar issue with the media and text block. See: https://core.trac.wordpress.org/ticket/45243#comment:2 Otherwise, good to go.

#3 @pento
6 years ago

  • Keywords dev-reviewed added

Same thing with the uncentered dot points as in Twenty Eleven, but otherwise, 👍🏻.

#4 @laurelfulford
6 years ago

Thanks @davidakennedy and @pento!

45244.1.patch makes a couple small changes:

  1. The bottom margin of the last child in the Media & Text block now has a bottom margin of zero.
  2. The centred widget styles now centres the bullets, along with the text, on the front-end and in the editor.

@laurelfulford
6 years ago

Twenty Fifteen - remove margin under last child in Media & Text block

@laurelfulford
6 years ago

Twenty Fifteen - centre bullets in centred list widgets

#5 @pento
6 years ago

💖

#6 @davidakennedy
6 years ago

The latest patch looks good to me, @laurelfulford.

#7 @laurelfulford
6 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 43874:

Twenty Fifteen: Fix issues with theme's Gutenberg support.

A handful of issues were missed in Twenty Fifteen's Gutenberg support, added in #45043. This commit includes the following fixes:

  • Center text and bullets in list-based widget blocks, when block itself is centered.
  • Add a margin to blocks that are aligned to the left or to the right, to create space.
  • Include non "image" variations of the Cover block classes .wp-block-cover and .wp-block-cover-text in the styles.
  • Add spacing underneath the Media & Text block, but make sure the final paragraph in the block doesn't add too much space.
  • Simplify selectors used to set editor width to just .wp-block.
  • Prevent margin from theme's editor-style.css from interfering with editor alignment.

Props pento, davidakennedy.
Fixes #45244.

#8 @SergeyBiryukov
6 years ago

  • Keywords fixed-5.0 added
  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening for trunk.

#9 @desrosj
6 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 44152:

Bundled Themes: Expand initial block editor support.

A handful of items were missed when adding initial support for the new block editor to bundled themes in [43793]-[43800]. This adds support for those missed items.

Props pento, davidakennedy, laurelfulford.

Merges [43869], [43870], [43871], [43872], [43873], [43874], [43875], [43876] to trunk.

Fixes #45238, #45239, #45240, #45242, #45243, #45244, #45245, #45246.

Note: See TracTickets for help on using tickets.