fix: replace old WP Ultimo logo with dashicons-networking SVG for menu icon#857
fix: replace old WP Ultimo logo with dashicons-networking SVG for menu icon#857superdav42 merged 1 commit intomainfrom
Conversation
…u icon The SVG data URI introduced in e83bf27 extracted the wrong glyph — it used the old WP Ultimo swirl logo from the custom dashicons-wu font instead of the WordPress dashicons-networking icon (\f325) that the CSS class originally referenced. Replace with the correct 3-node networking icon path from wp-includes/fonts/dashicons.svg.
📝 WalkthroughWalkthroughThe admin menu icon SVG has been updated by changing the base64-encoded data URI stored in the Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 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 |
🔨 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: |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@inc/admin-pages/class-base-admin-page.php`:
- Line 34: The MENU_ICON_SVG constant in class-base-admin-page.php contains an
incorrect SVG path (absolute commands) that doesn't match WordPress core
dashicons-networking; replace the current base64 SVG string in the const
MENU_ICON_SVG with the correct dashicons-networking SVG (use the official path
from WordPress core, encoded as data:image/svg+xml;base64,...), ensuring the
path uses the correct relative coordinates and matches the core markup exactly
so the icon renders properly in the admin menu.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 3663adbe-5e09-40a3-8695-157063abae12
📒 Files selected for processing (1)
inc/admin-pages/class-base-adm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DE0NS44MzUtMTM1LjY3NyAyNTAuNzYzIDAgMTY1LjQxOSAxMzQuMDk1IDI5OS41MDUgMjk5LjUxNSAyOTkuNTA1eiIvPjwvc3ZnPg=='; | ||
| const MENU_ICON_SVG = 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAyMCI+PHBhdGggZmlsbD0iYmxhY2siIGQ9Ik0xOCAxM2gxYy41NSAwIDEgLjQ1IDEgMS4wMXYyLjk4YzAgLjU2LS40NSAxLjAxLTEgMS4wMWgtNGMtLjU1IDAtMS0uNDUtMS0xLjAxdi0yLjk4YzAtLjU2LjQ1LTEuMDEgMS0xLjAxaDF2LTJoLTV2MmgxYy41NSAwIDEgLjQ1IDEgMS4wMXYyLjk4YzAgLjU2LS40NSAxLjAxLTEgMS4wMUg4Yy0uNTUgMC0xLS40NS0xLTEuMDF2LTIuOThjMC0uNTYuNDUtMS4wMSAxLTEuMDFoMXYtMkg0djJoMWMuNTUgMCAxIC40NSAxIDEuMDF2Mi45OEM2IDE3LjU1IDUuNTUgMTggNSAxOEgxYy0uNTUgMC0xLS40NS0xLTEuMDF2LTIuOThDMCAxMy40NS40NSAxMyAxIDEzaDF2LTJjMC0xLjEuOS0yIDItMmg1VjdIOGMtLjU1IDAtMS0uNDUtMS0xLjAxVjMuMDFDNyAyLjQ1IDcuNDUgMiA4IDJoNGMuNTUgMCAxIC40NSAxIDEuMDF2Mi45OEMxMyA2LjU1IDEyLjU1IDcgMTIgN2gtMXYyaDVjMS4xIDAgMiAuOSAyIDJ2MnoiLz48L3N2Zz4='; |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Decode the base64 SVG and verify it matches dashicons-networking from WordPress core
# Decode the new base64 SVG constant
echo "Decoding the new SVG from MENU_ICON_SVG constant:"
echo "PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAyMCI+PHBhdGggZmlsbD0iYmxhY2siIGQ9Ik0xOCAxM2gxYy41NSAwIDEgLjQ1IDEgMS4wMXYyLjk4YzAgLjU2LS40NSAxLjAxLTEgMS4wMWgtNGMtLjU1IDAtMS0uNDUtMS0xLjAxdi0yLjk4YzAtLjU2LjQ1LTEuMDEgMS0xLjAxaDF2LTJoLTV2MmgxYy41NSAwIDEgLjQ1IDEgMS4wMXYyLjk4YzAgLjU2LS40NSAxLjAxLTEgMS4wMUg4Yy0uNTUgMC0xLS40NS0xLTEuMDF2LTIuOThjMC0uNTYuNDUtMS4wMSAxLTEuMDFoMXYtMkg0djJoMWMuNTUgMCAxIC40NSAxIDEuMDF2Mi45OEM2IDE3LjU1IDUuNTUgMTggNSAxOEgxYy0uNTUgMC0xLS40NS0xLTEuMDF2LTIuOThDMCAxMy40NS40NSAxMyAxIDEzaDF2LTJjMC0xLjEuOS0yIDItMmg1VjdIOGMtLjU1IDAtMS0uNDUtMS0xLjAxVjMuMDFDNyAyLjQ1IDcuNDUgMiA4IDJoNGMuNTUgMCAxIC40NSAxIDEuMDF2Mi45OEMxMyA2LjU1IDEyLjU1IDcgMTIgN2gtMXYyaDVjMS4xIDAgMiAuOSAyIDJ2MnoiLz48L3N2Zz4=" | base64 -d
echo ""
echo ""
# Try to find the WordPress core dashicons.svg file
echo "Searching for WordPress core dashicons.svg file:"
fd -t f "dashicons.svg" /usr /var 2>/dev/null | head -5 || echo "dashicons.svg not found in common WordPress locations"
echo ""
# If WordPress is installed locally, extract the dashicons-networking path
if command -v wp &> /dev/null; then
echo "WordPress CLI detected. Checking WordPress version:"
wp --version 2>/dev/null || echo "WP-CLI not available in this environment"
fiRepository: Ultimate-Multisite/ultimate-multisite
Length of output: 727
🌐 Web query:
WordPress dashicons-networking icon SVG path glyph f325
💡 Result:
The dashicons-networking icon (CSS class: dashicons-networking) is the official WordPress Dashicons icon for networking/social sharing, located in the Social category per official documentation. It corresponds to the Unicode glyph U+f325 in the Dashicons font. The raw SVG path data (glyph) is available in the official WordPress Dashicons GitHub repository at sources/svg/networking.svg. Download/view the raw SVG from https://github.com/WordPress/dashicons/blob/master/sources/svg/networking.svg?raw=true for the complete definition. Iconify also hosts it as dashicons:networking with SVG export available.
Citations:
- 1: https://developer.wordpress.org/resource/dashicons/
- 2: https://github.com/WordPress/dashicons/
- 3: https://icon-sets.iconify.design/dashicons/networking/
- 4: https://github.com/WordPress/dashicons/tree/master/sources/svg
- 5: https://github.com/WordPress/dashicons/blob/master/icon-font/dashicons.html
- 6: https://github.com/WordPress/dashicons/blob/master/react/index.jsx
🏁 Script executed:
#!/bin/bash
# Fetch the official WordPress dashicons-networking SVG and compare
echo "Fetching official WordPress dashicons-networking SVG..."
official_svg=$(curl -s "https://raw.githubusercontent.com/WordPress/dashicons/master/sources/svg/networking.svg")
if [ -z "$official_svg" ]; then
echo "Failed to fetch official SVG. Trying alternative source..."
# Try the icon-sets/iconify API
official_svg=$(curl -s "https://api.iconify.design/dashicons:networking.svg")
fi
echo "Official SVG from WordPress Dashicons repository:"
echo "$official_svg"
echo ""
echo ""
# Extract just the path d attribute from official
echo "Path from official SVG:"
echo "$official_svg" | grep -oP 'd="[^"]*"' || echo "Could not extract path"
# The decoded SVG path from the PR
pr_path='d="M18 13h1c.55 0 1 .45 1 1.01v2.98c0 .56-.45 1.01-1 1.01h-4c-.55 0-1-.45-1-1.01v-2.98c0-.56.45-1.01 1-1.01h1v-2h-5v2h1c.55 0 1 .45 1 1.01v2.98c0 .56-.45 1.01-1 1.01H8c-.55 0-1-.45-1-1.01v-2.98c0-.56.45-1.01 1-1.01h1v-2H4v2h1c.55 0 1 .45 1 1.01v2.98C6 17.55 5.55 18 5 18H1c-.55 0-1-.45-1-1.01v-2.98C0 13.45.45 13 1 13h1v-2c0-1.1.9-2 2-2h5V7H8c-.55 0-1-.45-1-1.01V3.01C7 2.45 7.45 2 8 2h4c.55 0 1 .45 1 1.01v2.98C13 6.55 12.55 7 12 7h-1v2h5c1.1 0 2 .9 2 2v2z"'
echo ""
echo "Path from PR SVG:"
echo "$pr_path"Repository: Ultimate-Multisite/ultimate-multisite
Length of output: 2093
🏁 Script executed:
#!/bin/bash
# Normalize and compare the two SVG paths
python3 << 'PYTHON_EOF'
import re
official = "M18 13h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2h-5v2h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2h-5v2h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2c0-1.1 0.9-2 2-2h5v-2h-1c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h4c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-1v2h5c1.1 0 2 0.9 2 2v2z"
pr_path = "M18 13h1c.55 0 1 .45 1 1.01v2.98c0 .56-.45 1.01-1 1.01h-4c-.55 0-1-.45-1-1.01v-2.98c0-.56.45-1.01 1-1.01h1v-2h-5v2h1c.55 0 1 .45 1 1.01v2.98c0 .56-.45 1.01-1 1.01H8c-.55 0-1-.45-1-1.01v-2.98c0-.56.45-1.01 1-1.01h1v-2H4v2h1c.55 0 1 .45 1 1.01v2.98C6 17.55 5.55 18 5 18H1c-.55 0-1-.45-1-1.01v-2.98C0 13.45.45 13 1 13h1v-2c0-1.1.9-2 2-2h5V7H8c-.55 0-1-.45-1-1.01V3.01C7 2.45 7.45 2 8 2h4c.55 0 1 .45 1 1.01v2.98C13 6.55 12.55 7 12 7h-1v2h5c1.1 0 2 .9 2 2v2z"
print("=== PATH COMPARISON ===\n")
print(f"Official length: {len(official)}")
print(f"PR path length: {len(pr_path)}")
print()
# Check for absolute coordinate commands in PR
pr_uppercase = [m.group() for m in re.finditer(r'[A-Z]', pr_path)]
official_uppercase = [m.group() for m in re.finditer(r'[A-Z]', official)]
print("Uppercase commands (absolute coordinates) in Official:", official_uppercase)
print("Uppercase commands (absolute coordinates) in PR:", pr_uppercase)
print()
# Find sections with uppercase in PR
pr_sections = re.findall(r'[A-Z][^A-Z]*', pr_path)
print("Sections with absolute commands in PR:")
for i, section in enumerate(pr_sections):
if section[0].isupper():
print(f" {i}: {section[:50]}...")
print()
# Check for presence of specific markers
if "V7" in pr_path:
print("⚠️ PR contains 'V7' (vertical absolute movement) - NOT in official")
if "V3.01" in pr_path:
print("⚠️ PR contains 'V3.01' (vertical absolute movement) - NOT in official")
if "H8" in pr_path or "H4" in pr_path or "H1" in pr_path:
print("⚠️ PR contains absolute horizontal movements (H8, H4, H1, etc.) - NOT in official")
if "C6" in pr_path or "C13" in pr_path:
print("⚠️ PR contains absolute curve commands (C6, C13, etc.) - NOT in official")
print()
print("CONCLUSION: The SVG paths are DIFFERENT and will NOT render the same icon!")
PYTHON_EOFRepository: Ultimate-Multisite/ultimate-multisite
Length of output: 1164
The SVG path does not match the official WordPress dashicons-networking icon and will not render correctly.
The path in the PR contains absolute coordinate commands (H8, H4, H1, V7, V3.01, C6, C13, etc.) that are not in the official WordPress core dashicons-networking SVG. The official icon uses only relative coordinates. This mismatch will cause the icon to render incorrectly.
Use the correct path from WordPress core dashicons:
Correct SVG constant
const MENU_ICON_SVG = 'data:image/svg+xml;base64,' . base64_encode('<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20"><path d="M18 13h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2h-5v2h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2h-5v2h1c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-4c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h1v-2c0-1.1 0.9-2 2-2h5v-2h-1c-0.55 0-1-0.45-1-1.010v-2.98c0-0.56 0.45-1.010 1-1.010h4c0.55 0 1 0.45 1 1.010v2.98c0 0.56-0.45 1.010-1 1.010h-1v2h5c1.1 0 2 0.9 2 2v2z"></path></svg>');🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@inc/admin-pages/class-base-admin-page.php` at line 34, The MENU_ICON_SVG
constant in class-base-admin-page.php contains an incorrect SVG path (absolute
commands) that doesn't match WordPress core dashicons-networking; replace the
current base64 SVG string in the const MENU_ICON_SVG with the correct
dashicons-networking SVG (use the official path from WordPress core, encoded as
data:image/svg+xml;base64,...), ensuring the path uses the correct relative
coordinates and matches the core markup exactly so the icon renders properly in
the admin menu.
|
Performance Test Results Performance test results for 2f2ac2e 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
Changed file
Merged via PR #857 to main. aidevops.sh v3.8.28 spent 8m on this as a headless bash routine. |
Summary
dashicons-networking(3-node hierarchy) icondashicons-wufont instead of the WordPress coredashicons-networkingglyph (\f325) that the CSS class originally referencedChanged file
inc/admin-pages/class-base-admin-page.php—MENU_ICON_SVGconstant updated with the correct base64-encoded SVG path sourced fromwp-includes/fonts/dashicons.svgSummary by CodeRabbit