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

Backwards compatibility with traditional admin notices #10491

Closed
mboynes opened this issue Oct 10, 2018 · 2 comments
Closed

Backwards compatibility with traditional admin notices #10491

mboynes opened this issue Oct 10, 2018 · 2 comments
Labels
[Status] Duplicate Used to indicate that a current issue matches an existing one and can be closed

Comments

@mboynes
Copy link
Contributor

mboynes commented Oct 10, 2018

Following #4811, if a plugin or theme is trying to show a message on the post edit screen, it will be hidden. Plugins may be trying to add important messages, ones that only appear on the new/edit post screen. Gutenberg should attempt to render these messages, perhaps by automatically upgrading them to notice components, rather than hiding them.

To Reproduce
Steps to reproduce the behavior:

  1. Render an admin notice, e.g.
    add_action(
    	'admin_notices',
    	function() {
    		echo '<div class="updated success"><p>Sample Message</p></div>';
    	}
    );
  2. Navigate to the new/edit posts screen with Gutenberg active

Expected behavior

I should see the above "Sample Message", ideally with some indicator of success.

Additional context

Related: #3395, amongst others.

@danielbachhuber
Copy link
Member

#6388 is the canonical issue for this. Closing in favor of that.

@danielbachhuber danielbachhuber added the [Status] Duplicate Used to indicate that a current issue matches an existing one and can be closed label Oct 10, 2018
@collimarco
Copy link

This still doesn't work... admin notices are not shown in Gutenberg.

Moreover the linked issue has been closed as completed, but the bug is still present.

Please fix this, so that admin_notices works as expected...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Status] Duplicate Used to indicate that a current issue matches an existing one and can be closed
Projects
None yet
Development

No branches or pull requests

3 participants