#54837 closed defect (bug) (fixed)
Mobile admin menu: Clicking on menu items hides the menu
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 5.9 | Priority: | normal |
Severity: | normal | Version: | 5.9 |
Component: | Administration | Keywords: | |
Focuses: | ui | Cc: |
Description
Using WP 5.9 RC 2
Steps to reproduce:
- Use a mobile device (tested with iPhone)
- Login to admin via browser (tested with Safari and Chrome)
- Expand the admin menu
- Click on one of the main items (Posts, Users, etc)
- Admin menu is hidden
- Open menu again
- Item clicked has been expanded showing subitems.
Change History (17)
#1
@
3 years ago
- Component changed from Menus to Administration
- Focuses ui added
- Milestone changed from Awaiting Review to 5.9
#2
@
3 years ago
- Keywords reporter-feedback added
Test Report
Env
- WordPress 5.9 Beta 3, 5.9 RC1, 5.9 RC2
- (IRL) - Android - Chrome 97.0.4692.87
- (Browserstack - Real device) - iPhone 12 v14.1 - Chrome 92.0.4515.90
- (Browserstack - Real device) - iPhone 12 v14.1 - Safari 14
- Theme: Twenty Twenty One
- Gutenberg Editor
- Plugin: None activated
Steps to test
- Login to admin via browser
- Expand the admin menu
- Click on
Posts
. - Admin menu is hidden ❌ - Admin menu is still shown.
- Open menu again ❌- Admin menu is already open.
- Item clicked has been expanded showing subitems. ✅ - Expected behaviour.
Results
- Cannot reproduce on:
- Android Chrome (5.9 Beta 3, 5.9 RC1 or 5.9 RC2).
- iPhone 12 v14.1 Chrome (5.9 Beta 3, 5.9 RC1 or 5.9 RC2).
- iPhone 12 v14.1 Safari (5.9 Beta 3, 5.9 RC1 or 5.9 RC2).
Notes
- It would be beneficial to know what version of iOS, Safari and Chrome were used when the issue was originally detected. Adding
reporter-feedback
to get more information. - It would be beneficial for a tester with a physical iPhone in front of them to test this issue.
- If the issue is reproduced on an iPhone and only appeared in 5.9, then it's likely related to 51946.
#3
@
3 years ago
- Keywords needs-testing has-testing-info added; reporter-feedback removed
Removing reporter-feedback
. The issue was originally produced on iPhone 11 and iPhone 12.
I was unable to reproduce the issue in Browserstack - Real device - iPhone 11 in Safari or Chrome.
A test report from another tester using an iPhone 11 or 12 would be much appreciated.
Adding needs-testing
, has-testing-info
and requesting manual testing to reproduce the issue from the folks in the #core-test Slack channel to get this attention ahead of RC3 tomorrow.
This ticket was mentioned in Slack in #core-test by costdev. View the logs.
3 years ago
#5
@
3 years ago
I am able to reproduce the same bug on the mobile devices using the chrome device toolbar.
#6
@
3 years ago
Thanks @thelovekesh!
If you're comfortable editing code, please do the following:
- Add the following to
wp-config.php
:define( 'SCRIPT_DEBUG', true );
- Open
wp-admin/js/common.js
. - Search for
Close sidebar
. This should bring you to the following block of code:// Close sidebar when focus moves outside of toggle and sidebar. $( '#wp-admin-bar-menu-toggle, #adminmenumain' ).on( 'focusout', function() { var focusIsInToggle, focusIsInSidebar; if ( ! $wpwrap.hasClass( 'wp-responsive-open' ) ) { return; } // A brief delay is required to allow focus to switch to another element. setTimeout( function() { focusIsInToggle = $.contains( $( '#wp-admin-bar-menu-toggle' )[0], $( ':focus' )[0] ); focusIsInSidebar = $.contains( $( '#adminmenumain' )[0], $( ':focus' )[0] ); if ( ! focusIsInToggle && ! focusIsInSidebar ) { $( '#wp-admin-bar-menu-toggle' ).trigger( 'click.wp-responsive' ); } }, 10 ); } );
- Delete this block of code and save the file.
- Perform a hard refresh (
Cmd
+R
orCtrl
+F5
depending on your device). - Let us know if you are still able to reproduce the issue.
#8
@
3 years ago
- Keywords needs-testing has-testing-info removed
#9
@
3 years ago
- Owner set to audrasjb
- Status changed from new to accepted
Reverting and moving to 6.0 may be the safer option given the last release candidate is tomorrow.
Also pinging @joedolson who worked on [51946], for information.
This ticket was mentioned in Slack in #core-media by hellofromtonya. View the logs.
3 years ago
#11
@
3 years ago
- Milestone changed from 5.9 to 6.0
Spoke with @joedolson on slack who confirmed okay to revert [51946] and move resolution to 6.0. Revert will happen on its original ticket, i.e. #53587 with a reference to this new ticket.
#14
@
3 years ago
@dhusakovic the change has been reverted. To keep the conversation and resolution in one place, I'd suggest moving the conversation to the original ticket #53587.
#16
@
3 years ago
- Milestone changed from 6.0 to 5.9
- Resolution set to fixed
- Status changed from assigned to closed
Closing this ticket to keep discussion about any future changes on #53587
Thanks for the report!
Per Slack message, this may have been introduced in 5.9 RC, moving to the milestone for investigation.
Also moving to the Administration component, as Menus is specifically for the Menus screen and nav menu functions.