Archived topic
Adding off-canvas toggle in a site header created with Elements
3 replies · Started by Luca on October 19, 2022
Hi,
I have set up a menu for the off-canvas panel, enabled it in Customizer and I have added an empty primary menu to activate the toggle.
All works ok, except that now I need to create some custom site header layouts for specific pages and I need to add the off-canvas toggle.
I created a Block Element and assigned it to Site header and then I added the core navigation block (selecting the empty primary menu) but it will not show the toggle in this case.
Is there any way I could show the toggle manually in such cases? A shortcode maybe?
Thanks
Hi there,
the off-canvas can be triggered by any <a> link thats within a slideout-toggle classed element.
See here for example:
https://generatepress.com/forums/topic/trigger-slideout-menu-with-secondary-button/#post-775778
Thanks!
You're welcome