Skip to content

Add icon PNG files and load from disk#20

Merged
SamMorrowDrums merged 1 commit intomainfrom
add-icon-files
Jan 26, 2026
Merged

Add icon PNG files and load from disk#20
SamMorrowDrums merged 1 commit intomainfrom
add-icon-files

Conversation

@SamMorrowDrums
Copy link
Owner

Changes

Adds icon PNG files extracted from inline base64 strings.

Icon location: mcp_starter/assets/icons/

Files

  • abacus.png
  • hourglass.png
  • package.png
  • robot.png
  • sun_behind_cloud.png
  • waving_hand.png

TODO (for Copilot or maintainer)

After merging this PR, update icons.py to:

  1. Delete the inline base64 strings
  2. Load icons from assets/icons/ at runtime:
import base64
from pathlib import Path

ICONS_DIR = Path(__file__).parent / "assets" / "icons"

def load_icon(name: str) -> str:
    path = ICONS_DIR / f"{name}.png"
    with open(path, "rb") as f:
        return f"data:image/png;base64,{base64.b64encode(f.read()).decode()}"

WAVING_HAND_ICON = load_icon("waving_hand")
SUN_BEHIND_CLOUD_ICON = load_icon("sun_behind_cloud")
# etc...

Icons from Microsoft Fluent UI Emoji (MIT License)

Icons from Microsoft Fluent UI Emoji (MIT License).
These should be loaded at runtime instead of using inline base64 strings.
@SamMorrowDrums SamMorrowDrums merged commit 6f81e44 into main Jan 26, 2026
5 checks passed
@SamMorrowDrums SamMorrowDrums deleted the add-icon-files branch January 26, 2026 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant