fix: use SVG data URI for menu icon so it renders on all admin pages#773
fix: use SVG data URI for menu icon so it renders on all admin pages#773superdav42 merged 1 commit intomainfrom
Conversation
The menu icon used the CSS class dashicons-wu-wp-ultimo, defined in admin.css which is only enqueued on WP Ultimo pages. On all other admin pages the sidebar menu item had no icon. Replace with an inline SVG data URI (extracted from the dashicons-wu font glyph) which WordPress renders natively via add_menu_page(), removing the dependency on admin.css being loaded.
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 2 minutes and 26 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Files changed
Testing
Merged via PR #773 to main. aidevops.sh v3.6.224 spent 6m on this as a headless bash routine. |
🔨 Build Complete - Ready for Testing!📦 Download Build Artifact (Recommended)Download the zip build, upload to WordPress and test:
🌐 Test in WordPress Playground (Very Experimental)Click the link below to instantly test this PR in your browser - no installation needed! Login credentials: |
|
Performance Test Results Performance test results for 460d5f7 are in 🛎️! Note: the numbers in parentheses show the difference to the previous (baseline) test run. Differences below 2% or 0.5 in absolute values are not shown. URL:
|
Summary
dashicons-wu-wp-ultimoCSS class fromadmin.css, which is only enqueued on WP Ultimo pagesdashicons-wufont glyph) that WordPress renders natively viaadd_menu_page(), requiring no external CSSMENU_ICON_SVGconstant onBase_Admin_Pageso all top-level menu pages share the same icon sourceFiles changed
inc/admin-pages/class-base-admin-page.php— addedMENU_ICON_SVGconstantinc/admin-pages/class-dashboard-admin-page.php— use constant ininit()inc/admin-pages/class-multisite-setup-admin-page.php— use constant in constructorinc/admin-pages/class-setup-wizard-admin-page.php— use constant in constructorinc/admin-pages/class-settings-admin-page.php— cleared unused property (submenu)tests/Admin_Pages/Dashboard_Admin_Page_Test.php— updated assertionTesting