Add status notification to the pre-publish and document sidebar panels#6027
Add status notification to the pre-publish and document sidebar panels#6027westonruter merged 25 commits intodevelopfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #6027 +/- ##
=============================================
+ Coverage 75.27% 75.39% +0.12%
+ Complexity 5709 5706 -3
=============================================
Files 218 225 +7
Lines 17283 17323 +40
=============================================
+ Hits 13009 13061 +52
+ Misses 4274 4262 -12
Flags with carried forward coverage won't be shown. Click here to find out more.
|
|
Plugin builds for 5a7860a are ready 🛎️!
|
|
This time the failing E2E test is most likely an actual issue caused by missing (moved) "Enable AMP" toggle. I'll see if I can fix this test tomorrow. |
Since Gutenberg plugins do not render markup directly, covering them with unit tests is not practical. Instead - if really needed - they should be covered by E2E tests. By ignoring the plugins we ensure that the code coverage report is not negatively impacted.
| '<rootDir>/assets/src/block-editor/plugins', | ||
| '<rootDir>/assets/src/block-validation/plugins', |
There was a problem hiding this comment.
Since Gutenberg plugins do not render markup directly, covering them with unit tests is not practical. Instead, whenever needed, they should be covered by E2E tests.
By ignoring the plugins we ensure that the code coverage report is not negatively impacted.
|
This is looking great! @amedina Any needed changes jump out at you? Before
After
|
|
@delawski would you verify the behavior when AMP developer tools are turned off in the user's profile? I'll check in the morning as well. |
So that's something that I haven't covered here at all. What's more, since the The new I think we have three ways to go:
I guess that the last option would require some planning and UX support from @jwold. Because of this, I think it would be a good candidate for a separate issue. In the meantime, I'm happy to update this PR so that the AMP toggle is rendered even if the dev tools are disabled. What are your thoughts, @westonruter? |
Yes, I think the toggle needs to be rendered still even for users with DevTools turned off. It could either go back to it's original location in the status panel, or it could be in the new AMP panel but without any status message or button to view validation. The original location may be preferred since the UI would be more discreet. You're right that eventually we'll want to have validation messages even for when DevTools is turned off, but for now we should wait until we've made sure it's good for non-technical users. |
|
This looks great indeed! The specific text on some of the messages could be calibrated a bit, but at the moment they convey the right semantics. And the UX for presenting them to users is great. |
@westonruter With 9cbd629 the AMP toggle is rendered again for users with DevTools disabled: |
|
Fixing tests… |

















Summary
Fixes #5997
This PR introduces AMP document status notifications to the pre-publish panel and to the general document sidebar.
It also contains some updates to the existing notifications area introduced in #5929.
Note that the base for this PR is #6022 that reorgs and cleans up the
block-validationdirectory.Checklist