[ad_1]
How to add a hamburger menu even if the view/display is desktop view. I tried to change the break points, but it doesn’t take effect.
I’m using helium theme and gantry 5
[ad_2]Copyright © 2020 - 2022, Project DMC - WordPress Tutorials for Beginners- All Rights Reserved. Privacy Policy
Identify the Menu Element: Find the HTML element or class that represents your menu.
Create Media Query: Write a media query in CSS to target desktop screens. Typically, hamburger menus are hidden on desktop screens, so you’ll want to show it when the screen size reaches a certain width.
Override Display: Within the media query, override the display property of the menu element to make it visible. You’ll likely set it to block or inline-block to ensure it’s visible.
Style and Positioning: Adjust the styling and positioning of the hamburger menu as needed to ensure it looks good and is accessible on desktop screens.
Test and Iterate: Test your changes across various desktop screen sizes and browsers to ensure the hamburger menu behaves as expected.
Here’s an example of how you might write the CSS:
/* Show hamburger menu on desktop screens */
u/media screen and (min-width: 768px) {
/* Assuming .hamburger-menu is the class of your menu element */
.hamburger-menu {
display: block !important;
}
}
Remember to replace .hamburger-menu with the actual class or ID of your menu element.
If changing breakpoints directly in the theme settings doesn’t work, it’s likely because the theme or framework you’re using has specific implementation details that override those settings. In such cases, custom CSS and possibly JavaScript are the way to go.
If you’re not comfortable with CSS and JavaScript, you might consider reaching out to the support channels provided by the theme or framework developers for more specific guidance tailored to your setup. They may have custom hooks or settings you can use to achieve the desired functionality.
clear cache, try to use the browser console ….
Is this the theme [https://themeforest.net/item/helium-modern-portfolio-blog-theme/9458672](https://themeforest.net/item/helium-modern-portfolio-blog-theme/9458672) ?