magento2: "Uncaught TypeError: Cannot read property 'clientWidth' of undefined" error message appears on New Media Gallery page

Preconditions (*)

  1. Install Magento with Adobe Stock Integration
  2. Configured integration in Stores -> Configuration -> Advanced-> System -> Adobe Stock Integration fieldset

Steps to reproduce (*)

  1. Log in Admin Panel and go to Stores - Configuration - Advanced - System- Media Gallery
  2. Set Enable Old Media Gallery to No.
  3. Save Config and clear Magento cache
  4. Log out from Admin
  5. Generate small profile for your instance php bin/magento setup:performance:generate-fixtures setup/performance-toolkit/profiles/ce/small.xml
  6. Perform Media Gallery synchronization php bin/magento media-gallery-sync
  7. Clear Magento cache php bin/magento cache:clean
  8. Log in Admin Pannel
  9. Go to Content - Media Gallery

Expected result (*)

Media Gallery is opened no error messages in dev console

Actual result (*)

Uncaught TypeError: Cannot read property ‘clientWidth’ of undefined

Note

The bug is unstable, usually appeared on my system after Sign Out/Sign In Magento Admin

The error “comes from” ‘masanory.js’ client_width

About this issue

  • Original URL
  • State: open
  • Created 4 years ago
  • Comments: 15 (6 by maintainers)

Most upvoted comments

I believe we still need to fix it