astra
astra copied to clipboard
Slider Jumps and Flashes white when Closing
Describe the bug:
When using the slider canvas menu in mobile/tablet and having it set to pop from the left or right, upon closing the menu blinks white and appears slightly larger just before closing.
To reproduce:
- Enable a side menu on mobile or tablet (canvas menu)
- Set the width to something less than 60% and publish
- Make sure the menu is a dark color and not white
- Now close the menu and you will see a flash with white and it will be slightly larger for a split second.
Expected behavior:
Menu should move to the side and not flash.
Reason for the Bug:
Within public_html/wp-content/themes/astra/inc/builder/type/header/off-canvas/dynamic-css/dynamic.css.php there is a function called astra_off_canvas_static_css() and the default css is causing the menu to jump when active class is removed.
Isolating the problem:
- [x] This bug happens with no other plugins activated
- [x ] I can reproduce this bug consistently using the steps above
WordPress version:
WordPress version: 6.0.2
Astra Theme version: Version 3.9.1 Pro
I didn't see any, but some logic to determine if you're on mobile/tablet/desktop could help here. Could just detect the device and then set that base class with the correct max-width to match what is actually selected by the user.