Skip to content

Allow customising the Navigation block breakpoint - #45274

Open
getdave wants to merge 7 commits into
trunkfrom
try/customise-nav-block-breakpoint
Open

getdave wants to merge 7 commits into
trunkfrom
try/customise-nav-block-breakpoint

Conversation

@getdave

@getdave getdave commented Oct 25, 2022 •

Copy link
Copy Markdown
Contributor

What

Adds an overlayBreakpoint attribute to the Navigation block so the responsive overlay can switch between the collapsed menu button and inline navigation items at a user-configured viewport width.

This is a major refresh of the earlier PR direction. The PR had gone stale, so the implementation has been updated to fit the current Navigation block overlay architecture and the newer patterns now present in trunk.

Why

The Navigation block currently uses a fixed breakpoint for its mobile overlay behavior. That can be too limiting for themes and layouts where navigation needs to collapse earlier or later depending on available space, typography, item count, or design requirements.

How

  • Adds an overlayBreakpoint block attribute with a default of 600px.
  • Adds an Overlay breakpoint control to the Navigation block Overlay settings when Overlay Visibility is set to Mobile.
  • Supports px, em, and rem values, including decimal values.
  • Normalizes invalid or unsafe values back to the default breakpoint.
  • Preserves the existing default breakpoint behavior for Navigation blocks without a custom value.
  • Emits instance-scoped frontend CSS only when a valid custom mobile overlay breakpoint is used.
  • Mirrors the custom breakpoint behavior in the editor preview.
  • Ignores custom breakpoint styling for Overlay Visibility values that do not use a responsive breakpoint, such as Off and Always.
  • Updates Navigation block docs and adds JS/PHP coverage for validation, editor behavior, rendered CSS, and default compatibility.

FAQs

Why 600px?

  • 600px is the breakpoint Navigation already uses today through WordPress's small breakpoint, not a new design decision introduced by this PR.
  • packages/base-styles/_breakpoints.scss:12 defines $break-small: 600px.
  • packages/base-styles/_mixins.scss:118 exposes that value as break-small().
  • Keeping that value as the default preserves the current behavior for existing Navigation blocks.
  • Custom values only apply when a block has a valid non-default Mobile overlay breakpoint, and those styles are scoped to the individual Navigation block instance.

Why not automate this?

Two automation routes were explored before returning to an explicit breakpoint control:

  • CSS/intrinsic layout, including container queries.
  • JavaScript measurement, where the block detects at runtime whether the navigation still fits.

Those routes did not give us a robust enough solution for this PR:

  • Container queries were suggested in #45274 and explored further in #53475.
  • The blocker is that container queries still require an explicit threshold, for example "when this container is narrower than X, switch layout." They do not automatically know when the Navigation block's inline items no longer fit.
  • The correct X is content-dependent. It changes with the number of menu items, label length, font size, spacing, submenu indicators, and translations. A threshold that works for one Navigation instance can be wrong for another instance in the same theme.
  • Querying the Navigation block's own container is not enough because many real headers break due to surrounding layout, not only the menu itself. Site Logo, Site Title, social links, Groups, Columns, spacing, and future layout containers can all reduce the available space.
  • Querying a parent container does not solve that either. It just moves the hardcoded threshold to a different container, and the right parent can vary across header layouts.
  • #57587 explored a JavaScript auto mode because CSS/container queries could not answer the actual question: "do these navigation items still fit in this layout right now?" That route required measurement heuristics across both Navigation items and parent containers.
  • Those heuristics surfaced unresolved concerns around layout assumptions, nested containers, zooming, multiple collapsible menus, resize handling, editor-visible wrapped states, measurement performance, and future Grid layout changes.
  • This PR therefore takes the narrower route: preserve the default behavior, expose a custom value only for the Mobile overlay case, and scope generated CSS to the individual Navigation block instance.

How does this relate to the WordPress 7.1 responsive styling system?

  • The new responsive styling system and this PR solve different problems.
  • The WordPress 7.1 responsive styling system lets block styles vary across named viewport states such as @mobile and @tablet. Those states are driven by settings.viewport.mobile and settings.viewport.tablet.
  • overlayBreakpoint is not a responsive style state. It is a Navigation-block behavior setting that controls when one Navigation block switches between inline items and the overlay menu button.
  • Changing settings.viewport does not automatically change a Navigation block's overlayBreakpoint, and changing overlayBreakpoint does not redefine the site's @mobile or @tablet style breakpoints.
  • The two systems can still work together. Responsive style controls can adjust how the Navigation block looks at mobile/tablet viewports, while overlayBreakpoint controls when the overlay behavior starts.
  • In practice, a theme or user can choose matching values if they want the Navigation overlay transition to align with a site viewport breakpoint, but this PR does not force that coupling.
  • Keeping the values separate avoids making a content-dependent Navigation behavior part of the global responsive styling API, while still preserving compatibility with the new responsive styling system.

Testing Instructions

  1. Add a Navigation block.
  2. Open the block settings sidebar and expand the Overlay panel.
  3. Set Overlay Visibility to Mobile.
  4. Change the Overlay breakpoint value, for example 720px, 37.5em, or 48rem.
  5. Resize the editor and frontend viewport and confirm the Navigation block switches between the menu button and inline navigation items at the configured breakpoint.
  6. Confirm a Navigation block using the default 600px breakpoint still behaves as before.
  7. Confirm the Overlay breakpoint control is hidden when Overlay Visibility is Off or Always.
  8. Run npm run test:unit packages/block-library/src/navigation/edit/test.
  9. With the test environment running, run vendor/bin/phpunit phpunit/blocks/render-block-navigation-test.php.

@getdave getdave added the [Block] Navigation Affects the Navigation Block label Oct 25, 2022
@getdave getdave self-assigned this Oct 25, 2022
`(max-width: ${ mobileBreakpoint })`
);

console.log( { mobileBreakpoint, isMobileBreakPoint } );

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Need to remove

@getdave

getdave commented Oct 25, 2022

Copy link
Copy Markdown
Contributor Author

@mikachan From a Theming perspective would you see this feature as being valuable? Every time I create a theme I"m frustrated by not being able to properly control the Navigation block breakpoint. I assume you've run into this also?

@github-actions

github-actions Bot commented Oct 25, 2022 •

Copy link
Copy Markdown

Size Change: +1.26 kB (+0.02%)

Total Size: 7.73 MB

📦 View Changed
Filename Size Change
build/scripts/block-library/index.min.js 352 kB +722 B (+0.21%)
build/styles/block-library/navigation/style-rtl.css 3.76 kB +66 B (+1.79%)
build/styles/block-library/navigation/style-rtl.min.css 2.57 kB +54 B (+2.14%)
build/styles/block-library/navigation/style.css 3.76 kB +66 B (+1.79%)
build/styles/block-library/navigation/style.min.css 2.57 kB +55 B (+2.19%)
build/styles/block-library/style-rtl.css 22.4 kB +79 B (+0.35%)
build/styles/block-library/style-rtl.min.css 18.9 kB +66 B (+0.35%)
build/styles/block-library/style.css 22.5 kB +85 B (+0.38%)
build/styles/block-library/style.min.css 18.8 kB +66 B (+0.35%)

compressed-size-action

@mikachan

Copy link
Copy Markdown
Member

From a Theming perspective would you see this feature as being valuable? Every time I create a theme I"m frustrated by not being able to properly control the Navigation block breakpoint. I assume you've run into this also?

Yes, I think this would be extremely valuable. I love the idea of being able to control the Navigation block breakpoint from the UI. Your video looks promising!

Going forward, I wonder if this custom breakpoint should be at a higher level so it can impact more blocks. I really love using intrinsic design but there are some cases (like the Navigation block) where the best solution is probably to use a breakpoint, so it would be great to enable this for more blocks. Perhaps the custom breakpoints could eventually replace the break-small / break-medium mixins.

@getdave

getdave commented Oct 26, 2022

Copy link
Copy Markdown
Contributor Author

Yes I agree. I suggest we roll out to the Nav block and then if appetite grows we can consider if/how we extend this outwards to become a system wide tool. I can see other blocks (e.g. Columns) needing something similar to determine when to "stack on mobile" for example.

@mtias

mtias commented Oct 26, 2022

Copy link
Copy Markdown
Member

I don't think we should be having user set this value. Can we leverage container queries to do it automatically based on space?

@getdave

getdave commented Oct 26, 2022

Copy link
Copy Markdown
Contributor Author

Yeh I did consider taking a look at that. I appreciate we want to go for intrinsic design principles.

I may not have fully groked container queries but as I understand it you can query the width of the parent container and then adjust accordingly. However in Navigaiton blocks we care about switching out an entire layout to "mobile" mode based on the number of items in the Navigation itself.

As an example:

  • Navigation has x3 items in it. Fits nicely into container on most screen sizes.
  • We have a container query that says "when container div of Nav block gets less than 600px then switch to mobile layout".
  • This works really well for our 3 item Nav.
  • Then user adds x3 more items.
  • Suddenly the hard coded container query no longer works.

If there's a way of solving that (without resorting to JavaScript "measuring" the width of the Nav items) which I have missed then I'd be happy to look into it.

@getdave

getdave commented Oct 26, 2022

Copy link
Copy Markdown
Contributor Author

I've had a think about this and left some alternative suggestions under Alternatives in the description of this PR.

@chyvak1831

Copy link
Copy Markdown

Great solution, it's really required!
I don't understand why people don't vote for that.

@goodpenguins

Copy link
Copy Markdown

Hey :) everyone. Must have. We are already in the future and screens of any size can be an electronic canvas. This is just obvious and should be a standard principle in Gutenberg.

@getdave

getdave commented Apr 17, 2023

Copy link
Copy Markdown
Contributor Author

If you would like to see the PR land then please leave a 👍 emoji on this comment.

@masteradhoc

Copy link
Copy Markdown
Contributor

Just came across this and would love to get a solution for this!

@sinanisler

sinanisler commented Oct 25, 2023 •

Copy link
Copy Markdown

replicated to this issue
#55619

@MaggieCabrera

Copy link
Copy Markdown
Contributor

We proposed an alternative to this here: #57587 any feedback is welcome

@paaljoachim

Copy link
Copy Markdown
Contributor

Hello everyone

It would be great with some kind of update or link to an open issue/PR that took over for this PR. Thank you.

@getdave

getdave commented Dec 9, 2024

Copy link
Copy Markdown
Contributor Author

We started to explore various ideas in this Discussion

#53475

@MaggieCabrera look at container queries and also dynamically adjusting the layout based on various heuristics but they all fell short.

@getdave
getdave force-pushed the try/customise-nav-block-breakpoint branch from bee7f93 to ccfeb92 Compare July 20, 2026 12:34
@github-actions github-actions Bot added the [Package] Block library /packages/block-library label Jul 20, 2026
@getdave
getdave requested a review from Copilot July 20, 2026 13:07
@getdave getdave added the [Type] Enhancement A suggestion for improvement. label Jul 20, 2026
@getdave getdave changed the title [Experiment] Enable customising the Nav block breakpoint Allow customising the Navigation block breakpoint Jul 20, 2026

Copilot AI 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.

Pull request overview

Adds a configurable overlayBreakpoint attribute to the Navigation block so the “mobile overlay vs inline items” switch can happen at a user-selected viewport width, while keeping the existing 600px default behavior unchanged unless explicitly customized.

Changes:

  • Introduces overlayBreakpoint (default 600px) across block schema, editor UI, and server rendering, with validation/normalization for px|em|rem.
  • Adds editor UI controls (UnitControl + reset) and editor-preview behavior for custom breakpoints.
  • Emits instance-scoped frontend CSS (via style engine) only for valid, non-default custom breakpoints; updates docs and adds JS/PHP test coverage.

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/eslint/suppressions.json Removes a now-unneeded lint suppression for the overlay panel implementation.
phpunit/blocks/render-block-navigation-test.php Adds PHPUnit coverage for default/custom/invalid overlay breakpoint behavior and scoped CSS emission.
packages/block-library/src/navigation/style.scss Keeps static break-small() rules for non-custom blocks; custom blocks opt out and rely on scoped rules.
packages/block-library/src/navigation/README.md Documents the new overlayBreakpoint attribute.
packages/block-library/src/navigation/index.php Adds breakpoint constants + validation; adds custom-breakpoint classing and instance-scoped CSS rules.
packages/block-library/src/navigation/edit/utils.js Adds editor-side breakpoint normalization and “has custom” helpers.
packages/block-library/src/navigation/edit/test/utils.js Adds unit tests for breakpoint normalization + custom detection.
packages/block-library/src/navigation/edit/test/responsive-wrapper.js Adds tests for editor preview behavior tied to custom breakpoint matching.
packages/block-library/src/navigation/edit/test/overlay-panel.js Adds tests for overlay breakpoint control UI behavior (units, reset, invalid fallback, visibility).
packages/block-library/src/navigation/edit/responsive-wrapper.js Adds useMediaQuery-based editor preview state for custom breakpoints.
packages/block-library/src/navigation/edit/overlay-visibility-control.js Updates the overlay visibility help text.
packages/block-library/src/navigation/edit/overlay-panel.js Adds the overlay breakpoint UnitControl + reset button and wiring to attributes.
packages/block-library/src/navigation/edit/index.js Wires the new attribute into editor rendering + passes derived props to children.
packages/block-library/src/navigation/constants.js Adds default breakpoint + unit definitions for the UnitControl.
packages/block-library/src/navigation/block.json Adds the new attribute schema/default.
docs/reference-guides/core-blocks/README.md Updates the Navigation block attribute list to include overlayBreakpoint.

Comment on lines +72 to +76
const handleOverlayBreakpointChange = ( nextValue ) => {
setAttributes( {
overlayBreakpoint: normalizeOverlayBreakpoint( nextValue ),
} );
};
@getdave
getdave marked this pull request as ready for review July 20, 2026 13:55
@getdave
getdave requested a review from ajitbohra as a code owner July 20, 2026 13:55
@getdave
getdave force-pushed the try/customise-nav-block-breakpoint branch from 4e43603 to 4171bfe Compare July 20, 2026 13:58
@getdave getdave mentioned this pull request Jul 20, 2026
27 of 52 tasks
@getdave
getdave requested review from ramonjd and talldan July 21, 2026 08:42
@getdave

getdave commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

@talldan This is not targeting 7.1 so not urgent, but with your experience of Navigation and the recent work on responsive controls I'd love to get your expertise here 🙇

@talldan

talldan commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Mirrors the custom breakpoint behavior in the editor preview.

What is this part referring to?

The new responsive styling system and this PR solve different problems.

Just my opinion, but I think it would be better if there were something that works more in tune with responsive editing/styles. At least to begin with. Otherwise users might be confused that there's a special third breakpoint that only the nav block has, and one that's hard to view precisely. Also that there are systems that work differently.

After #79104 custom theme.json breakpoint values are supported for mobile/tablet, in the future that might be more extensible with completely custom breakpoints, so it might be good to keep overlay visibility more aligned with the future of themes.

Maybe a place to start for now is by supporting 'Tablet' as a value for the overlay (it could support the same breakpoints that theme.json provides). After that it might be possible to surface the controls as a toggle when 'Responsive styles' is active, similar to what's being explored for block visibility in #79995. Maybe it's possible to follow the same pattern as that PR (if we can decide on something), since the two features have similar values (off, set to breakpoint(s), or always on).

  • The WordPress 7.1 responsive styling system lets block styles vary across named viewport states such as @mobile and @tablet. Those states are driven by settings.viewport.mobile and settings.viewport.tablet.
  • overlayBreakpoint is not a responsive style state. It is a Navigation-block behavior setting that controls when one Navigation block switches between inline items and the overlay menu button.

To me, it doesn't matter if the values are stored differently behind the scenes, it's more a matter of surfacing the most useful controls when 'Responsive styles' is active.

@getdave

getdave commented Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

@talldan Thanks for the feedback. I'll review this carefully now.

I also realised that as the breakpoint is heavily content dependent, it might be necessary to save different values for different languages in multi-lingual setups. Given the menu item data comes from wp_navigation and it is this which most ML Plugins will "modify" and not the block, this is something we need to consider very carefully.

getdave and others added 7 commits November 17, 2026 09:42
Drop the "Internal dependencies" banner comment in navigation edit
utils.js to match the rest of the package, and remove a stale
suppressions.json entry for overlay-panel.jsx that no longer applies.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@getdave
getdave force-pushed the try/customise-nav-block-breakpoint branch from 4171bfe to 1fbdda7 Compare November 17, 2026 09:51
@github-actions
github-actions Bot requested review from aduth and ciampo November 17, 2026 09:52
@github-actions

github-actions Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

🤖 PR meta 🤖

🎉 Props

Unlinked Accounts

The following contributors have not linked their GitHub and WordPress.org accounts: @sinanisler.

Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Unlinked contributors: sinanisler.

Co-authored-by: getdave <get_dave@git.wordpress.org>
Co-authored-by: mikachan <mikachan@git.wordpress.org>
Co-authored-by: mtias <matveb@git.wordpress.org>
Co-authored-by: chyvak1831 <chyvak1831@git.wordpress.org>
Co-authored-by: goodpenguins <cotobago@git.wordpress.org>
Co-authored-by: masteradhoc <masteradhoc@git.wordpress.org>
Co-authored-by: MaggieCabrera <onemaggie@git.wordpress.org>
Co-authored-by: paaljoachim <paaljoachim@git.wordpress.org>
Co-authored-by: talldan <talldanwp@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.


Props Bot commands

You can trigger Props Bot actions by commenting on this PR:

  • @propsbot add <username> to give props to a GitHub user. Requires write access.
  • @propsbot remove <username> to leave a user out of the props. Requires write access.
  • @propsbot refresh to refresh this list. Adding the props-bot label works too.

Updated as activity occurs, without notifying anyone named here. Add the props-bot label to refresh.

📦 Bundle size

Size Change: +1.29 kB (+0.01%)

Total Size: 8.66 MB

📦 View Changed
Filename Size Change
build/scripts/block-library/index.min.js 427 kB +740 B (+0.17%)
build/styles/block-library/navigation/style-rtl.css 3.85 kB +64 B (+1.69%)
build/styles/block-library/navigation/style-rtl.min.css 2.65 kB +54 B (+2.08%)
build/styles/block-library/navigation/style.css 3.84 kB +63 B (+1.67%)
build/styles/block-library/navigation/style.min.css 2.64 kB +56 B (+2.17%)
build/styles/block-library/style-rtl.css 22.9 kB +85 B (+0.37%)
build/styles/block-library/style-rtl.min.css 19.5 kB +72 B (+0.37%)
build/styles/block-library/style.css 23.1 kB +84 B (+0.37%)
build/styles/block-library/style.min.css 19.5 kB +71 B (+0.37%)

1fbdda7 Run

⚡ Performance

Show the results

Client side metrics exclude the server response time.

front-end-block-theme

Metric 0b63e79 trunk % Change
timeToFirstByte 44.5 ms +12.7% -3.48% 49.75 ms +8.64% -8.64% -10.55%
largestContentfulPaint 76 ms +2.63% -10.53% 78 ms +7.69% -2.56% -2.56%
lcpMinusTtfb 26.6 ms +16.17% -10.15% 26.9 ms +18.96% -7.99% -1.12%
wpBeforeTemplate 24.01 ms +11.79% -8.04% 25.28 ms +20.29% -6.92% -5.02%
wpTemplate 17.55 ms +5.47% -5.24% 19.24 ms +9.62% -4% -8.78%
wpTotal 41.11 ms +11.51% -4.31% 46.19 ms +9.11% -9.14% -11%
wpMemoryUsage 7.75 MB +0% -0% 7.71 MB +0% -0% 0.46%
wpDbQueries 16 +0% -0% 16 +0% -0% 0%

front-end-classic-theme

Metric 0b63e79 trunk % Change
timeToFirstByte 36.8 ms +10.05% -3.4% 39.45 ms +10.14% -4.56% -6.72%
largestContentfulPaint 66 ms +6.06% -3.03% 70 ms +8.57% -2.86% -5.71%
lcpMinusTtfb 29.25 ms +7.35% -4.96% 30.15 ms +5.97% -5.14% -2.99%
wpBeforeTemplate 19.92 ms +17.52% -2.81% 21.09 ms +11.1% -4.36% -5.55%
wpTemplate 13.7 ms +3.87% -4.53% 15.18 ms +3.29% -6.32% -9.75%
wpTotal 34.14 ms +9.87% -3.28% 36.42 ms +6.53% -5.41% -6.26%
wpMemoryUsage 6.44 MB +0% -0% 6.40 MB +0% -0% 0.57%
wpDbQueries 13 +0% -0% 13 +0% -0% 0%

media-processing

Metric 0b63e79 trunk % Change
mediaProcessingJpeg 323.55 ms +1.95% -0.2% 335.71 ms +0.52% -2.12% -3.62%
mediaProcessingAvif 4862.94 ms +0.01% -0.23% 4911.9 ms +0.16% -0.04% -1%
mediaProcessingJpegToAvif 3391.73 ms +0.34% -0.19% 3436.94 ms +0.18% -0.1% -1.32%

media-upload

Metric 0b63e79 trunk % Change
jpegUploadProcessing 1475.15 ms +1.42% -1.24% 1473.46 ms +0.56% -1.09% 0.11%
pngUploadProcessing 251.43 ms +8.54% -4.9% 260.33 ms +3.25% -2.34% -3.42%
largeJpegUploadProcessing 1446.32 ms +1.2% -0.83% 1457.3 ms +0.46% -1.09% -0.75%
multipleImageUploadProcessing 1542.85 ms +0.88% -1.04% 1547.33 ms +1.56% -0.82% -0.29%

post-editor

Metric 0b63e79 trunk % Change
serverResponse 244.38 ms +5.11% -6.69% 257.26 ms +2.25% -7.21% -5.01%
firstPaint 271.82 ms +7.05% -6.5% 290.6 ms +3.75% -7.1% -6.46%
domContentLoaded 502.85 ms +10.12% -2.44% 525.5 ms +2.21% -2.66% -4.31%
loaded 504.04 ms +10.05% -2.54% 526.49 ms +2.19% -2.7% -4.26%
firstContentfulPaint 288.15 ms +14.9% -3.75% 297.8 ms +6.85% -0.98% -3.24%
firstBlock 1336.1 ms +0.81% -1.5% 1392.35 ms +0.75% -2.92% -4.04%
type 12.77 ms +6.66% -7.99% 13.09 ms +13.37% -7.33% -2.44%
typeWithoutInspector 12.98 ms +6.93% -6.47% 13.05 ms +5.98% -8.2% -0.54%
typeWithTopToolbar 15.31 ms +3.33% -8.62% 18.15 ms +2.81% -10.58% -15.65%
typeContainer 6.04 ms +9.44% -12.91% 6.4 ms +18.12% -1.41% -5.63%
focus 73.58 ms +1.77% -2.16% 81.19 ms +5.48% -2.01% -9.37%
firstFocus 156.51 ms +0% -0% 187.76 ms +0% -0% -16.64%
selectAll 242.56 ms +2.7% -2.33% 266.3 ms +1.81% -4.56% -8.91%
undo 19.23 ms +2.03% -2.03% 21.91 ms +9.36% -2.37% -12.23%
listViewOpen 45.55 ms +25.29% -9.81% 53 ms +31.6% -6.11% -14.06%
inserterOpen 26.09 ms +15.33% -5.56% 32.28 ms +3.44% -5.36% -19.18%
inserterHover 7.77 ms +11.2% -5.41% 9.47 ms +9.82% -5.91% -17.95%
inserterSearch 6.79 ms +2.5% -10.75% 6.98 ms +7.16% -2.01% -2.72%
loadPatterns 415.69 ms +1.18% -3.47% 475.24 ms +5.78% -3.41% -12.53%
wpTotal 237.86 ms +5.14% -6.95% 250.14 ms +1.81% -7.23% -4.91%
wpMemoryUsage 14.81 MB +0% -0% 14.77 MB +0% -0% 0.25%
wpDbQueries 55 +0% -0% 55 +0% -0% 0%

site-editor

Metric 0b63e79 trunk % Change
serverResponse 454.55 ms +4.37% -4.96% 476.85 ms +0.92% -8.24% -4.68%
firstPaint 449.89 ms +4.52% -10.78% 439.84 ms +4.29% -7.9% 2.28%
domContentLoaded 827.2 ms +4.69% -0.88% 827.52 ms +1.81% -1.93% -0.04%
loaded 828.13 ms +4.72% -0.84% 828.59 ms +1.8% -1.95% -0.06%
firstContentfulPaint 471.58 ms +6.82% -3.45% 463.64 ms +2.22% -1.66% 1.71%
firstBlock 2582.68 ms +1.21% -0.87% 2541.94 ms +1.04% -1.15% 1.6%
type 18.36 ms +10.73% -6.81% 17.95 ms +1.73% -10.81% 2.28%
navigate 115.27 ms +3.56% -7.4% 111.21 ms +3.69% -3.43% 3.65%
loadPatterns 1410.79 ms +5.39% -17.93% 1379.7 ms +4.51% -5.68% 2.25%
loadPages 947.76 ms +4.72% -1.3% 944.77 ms +2.97% -0.43% 0.32%
wpTotal 444.97 ms +4.47% -5.07% 467.26 ms +0.96% -8.42% -4.77%
wpMemoryUsage 12.82 MB +0% -0% 12.79 MB +0% -0% 0.26%
wpDbQueries 45 +0% -0% 45 +0% -0% 0%

1fbdda7 Run

🏁 Flaky tests

Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.

Undo restores the post selection when another synced entity is loaded in /test/e2e/specs/editor/collaboration/collaboration-undo-redo.spec.ts, passed after 1 failed attempt.
Error: expect(received).toMatchObject(expected)

- Expected  - 2
+ Received  + 2

  Object {
    "attributeKey": "content",
    "blockIndex": 0,
    "content": "abcdef",
-   "endOffset": 3,
-   "offset": 3,
+   "endOffset": 0,
+   "offset": 0,
  }

Call Log:
- Timeout 5000ms exceeded while waiting on the predicate
    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/collaboration/collaboration-undo-redo.spec.ts:363:5
does not select blocks in the canvas preview when editing from the sidebar (Site Editor v2) in /test/e2e/specs/site-editor/navigation-sidebar-list-view.spec.js, passed after 1 failed attempt.
Error: expect(locator).toBeFocused() failed

Locator: getByRole('combobox', { name: 'Search or type URL' })
Expected: focused
Timeout: 5000ms
Error: element(s) not found

Call log:
  - Expect "toBeFocused" getByRole('combobox', { name: 'Search or type URL' }) with timeout 5000ms
  - waiting for getByRole('combobox', { name: 'Search or type URL' })

    at LinkControl.useLinkControlSearch (/home/runner/work/gutenberg/gutenberg/test/e2e/specs/site-editor/navigation-sidebar-list-view.spec.js:416:47)
    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/site-editor/navigation-sidebar-list-view.spec.js:179:21
should apply a named font size using the font size buttons in /test/e2e/specs/editor/various/font-size-picker.spec.js, passed after 1 failed attempt.
Error: expect(received).toBe(expected) // Object.is equality

- Expected  - 2
+ Received  + 2

- <!-- wp:paragraph {"fontSize":"large"} -->
+ <!-- wp:paragraph {"fontSize":"medium"} -->
- <p class="has-large-font-size">Paragraph to be made "large"</p>
+ <p class="has-medium-font-size">Paragraph to be made "large"</p>
  <!-- /wp:paragraph -->

Call Log:
- Timeout 5000ms exceeded while waiting on the predicate
    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/various/font-size-picker.spec.js:153:6
should reset a named font size using input field in /test/e2e/specs/editor/various/font-size-picker.spec.js, passed after 1 failed attempt.
Error: expect(received).toBe(expected) // Object.is equality

- Expected  - 2
+ Received  + 2

- <!-- wp:paragraph {"fontSize":"small"} -->
+ <!-- wp:paragraph {"fontSize":"tiny"} -->
- <p class="has-small-font-size">Paragraph with font size reset using input field</p>
+ <p class="has-tiny-font-size">Paragraph with font size reset using input field</p>
  <!-- /wp:paragraph -->

Call Log:
- Timeout 5000ms exceeded while waiting on the predicate
    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/various/font-size-picker.spec.js:216:6
should reset a named font size using the tools panel menu in /test/e2e/specs/editor/various/font-size-picker.spec.js, passed after 1 failed attempt.
Error: expect(received).toBe(expected) // Object.is equality

- Expected  - 2
+ Received  + 2

- <!-- wp:paragraph {"fontSize":"medium"} -->
+ <!-- wp:paragraph {"fontSize":"small"} -->
- <p class="has-medium-font-size">Paragraph with font size reset using tools panel menu</p>
+ <p class="has-small-font-size">Paragraph with font size reset using tools panel menu</p>
  <!-- /wp:paragraph -->

Call Log:
- Timeout 5000ms exceeded while waiting on the predicate
    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/various/font-size-picker.spec.js:178:6
should select synced pattern in /test/e2e/specs/editor/various/writing-flow.spec.js, passed after 1 failed attempt.
Error: expect(locator).toBeFocused() failed

Locator:  locator('[name="editor-canvas"]').contentFrame().locator('[data-type="core/block"]')
Expected: focused
Received: inactive
Timeout:  5000ms

Call log:
  - Expect "toBeFocused" locator('[name="editor-canvas"]').contentFrame().locator('[data-type="core/block"]') with timeout 5000ms
  - waiting for locator('[name="editor-canvas"]').contentFrame().locator('[data-type="core/block"]')
    14 × locator resolved to <div tabindex="0" role="document" draggable="true" data-title="Pattern" data-type="core/block" data-is-drop-zone="true" aria-label="Block: Pattern" id="block-8ebbeafd-32b5-49b5-b564-862976a43391" data-block="8ebbeafd-32b5-49b5-b564-862976a43391" class="block-editor-block-list__block wp-block is-selected is-reusable block-library-block__reusable-block-container wp-block-block block-editor-block-list__layout">…</div>
       - unexpected value "inactive"

    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/various/writing-flow.spec.js:1464:5

1fbdda7 Run

This branch has not been deployed

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

Labels

[Block] Navigation Affects the Navigation Block [Package] Block library /packages/block-library [Type] Enhancement A suggestion for improvement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.