Archived topic
Disable Editor roles acces to Elements
3 replies · Started by trebere on December 10, 2021
Hello,
I've noticed when a user's role is Editor, editing a post, the Active Elements info panel appears in the sidebar but it hasn't access to Elements through the admin Menu>Appearance>Elements. I'd like completely disable access to this role or hide the panel info to this role.
I've tried using wp.data.dispatch('core/edit-post').removeEditorPanel('meta-box-gpp-elements-info-panel'); but I couldn't guess the exact panel id.
Could you point me how to do it?
Thank you!
Hi there,
This should help: https://generatepress.com/forums/topic/remove-active-elements-panel-in-the-block-editor/#post-1948839
Let us know :)
Hi,
Yes, I could make it work at least with the domReady option by now.
wp.domReady( function() {
var unregisterPlugin = wp.plugins.unregisterPlugin;
unregisterPlugin( 'generatepress-elements-info-panel' );
} );
Thank you!
You're welcome :)