Archived topic
Pixel mobile menu
11 replies · Started by Ketil on October 13, 2020
Hi. If you look at site https://visitnorthsenja.com/ (emulate portrait from mobile or view on mobile), and then click "Meny", you will see that the menu also shows the google analytics overview, and embedded code from the page "booking" (html from airbnb). What could be causing this?
Hi there,
How are you adding those content?
It's not intentional, I don't know why it appears in menu. But realized now that they are off canvas panel-added widgets. Why do they appear in mobile menu?
Just removing the widgets should fix the issues no?
I don't see this issue in the default Pixel template:
https://gpsites.co/pixel/
Well, I put them there for a reason, but that reason was not to have them appear in the menu.
I'm a bit confused.
If you added them in the off canvas widget area:
https://docs.generatepress.com/article/off-canvas-panel-overview/#off-canvas-panel-widget-area
And set the off-canvas panel to mobile only:
https://docs.generatepress.com/article/off-canvas-panel-overview/
Then they will show in the mobile menu?
I'm using widget shortcode to put widgets in page-content. I thought "off canvas panel" was for this purpose, make widgets that don't show in the canvas. I didn't realize it had to do with navigation menus. Is there a way i can use "off canvas panel" to just store "off canvas widgets" in without it showing up in the mobile navigation?
Sorry still not quite sure if I'm following.
So you want to add widgets but you don't want them to show?
Where do you actually want those widgets to show?
Each widget generates a shortcode, allowing me to add the shortcode where I want the widget to appear. I have a plugin for extra widget options, with many useful settings that allows me to solve some issues by putting widgets in page content. Specifially on this site, the issue is the html "embed"-code from airbnb. The client wants it embedded, and it comes in a table. I needed to create a mobile-friendly setup for this specific page because of the embedded html from airbnb. The widget plugin has a "device"-setting, so I made one setup that works on small screens, and one that works on big ones, and put both widget-shortcodes in the page content. If page is opened on a big screen, the "big screen"-widget is loaded, if the page is opened on a small screen, the "small screen"-wigdet is loaded. Apart from that, I don't want the widget to appear in navigation or in any of the widget areas. I need to create widgets for the sole purpose of the settings in them. I'm sure there is a better way to solve this, but this was my intention anyways. What is "off canvas panel" actully for?
The off canvas panel is simply an option that allows you to display the menu in a different style as explained here:
https://docs.generatepress.com/article/off-canvas-panel-overview/#style
It also has a widget area that allows which allows you to add things like social icons as seen the screenshot.
Can I "force" a mobile menu without showing the off canvas panel? It's just so handy to have a place to create widgets without any other purpose of getting the shortcode. I'll move the widgets to "inactive" for now, it will solve it.
Can I "force" a mobile menu without showing the off canvas panel?
You would just need to turn off the off canvas panel in the customizer and the normal menu should show.
Why don't you just use the Widget Shortcode area that comes with the plugin?
https://ps.w.org/widget-shortcode/assets/screenshot-1.png?rev=2023925