-
Notifications
You must be signed in to change notification settings - Fork 134
[0.3] Add localization/theming #132
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[0.3] Add localization/theming #132
Conversation
|
Thanks so much for opening this proposal! Overall aligned with the high-level approach. cc'ing @domdomegg @MarshallOfSound @loc for input A few qs:
|
| @@ -1,7 +1,7 @@ | |||
| # MCPB Manifest.json Spec | |||
|
|
|||
| Current version: `0.2` | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a PR open here to rename 0.3 -> vNext, but I think we want to avoid publicizing / documenting 0.3 until it's finalized (unless we think this PR captures all of the remaining requirements- i think we still have folder tokens?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joan-anthropic re: folder tokens - after thinking about it more, I think we don't need that just yet (we may in the future, but I wouldn't want to hold 0.3 for that). Are there other changes in 0.3 you would like to get in? happy to snap to whatever y'all need and rebase this on top of your 0.3->vNext PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds good! v0.3 sounds good then
| @@ -1 +1 @@ | |||
| export * from "./0.2.js"; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto re: comment above
|
LGTM from my side, happy to defer to @joan-anthropic on the details she's picked up :) |
@joan-anthropic thanks for the thoughtful questions :)
|
open to documenting default! my concern is mostly if we or the server spec wants to lay claim to our named default, we're still in a bad world and would need to figure out some path towards reconciliation - does that seem like a legitimate concern, or potentially overblown? Perhaps with a tighter namespace (e.g. mcpb-locale/, manifest-locale/) we could mitigate some of your concern? Only feel ~30% strongly about this. |
|
@joan-anthropic I've added the default value of |
|
@asklar one more request - can you fix the prettier warnings you'll see on |
|
@joan-anthropic gladly :) pushed an update with the lint changes |
[0.3] Add localization/theming
Claude Desktop does not yet support v0.3 manifests (localization/theming features). Reverting LATEST_MANIFEST_VERSION to v0.2 until Desktop support is available. Changes: - Set LATEST_MANIFEST_VERSION back to "0.2" in src/shared/constants.ts - Updated src/schemas/latest.ts to export v0.2 schema - Updated src/schemas_loose/latest.ts to export v0.2 schema - Updated test manifests and test assertions to match new default - v0.3 schema remains available for testing via explicit import This fixes the issue where npx mcpb pack rejects v0.2 manifests that Claude Desktop requires, introduced in PR anthropics#132 (commit 1640ade). Fixes compatibility with Claude Desktop versions that only support v0.2. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>

Proposal: Enhance MCPB Manifest Schema for Localization and Theming
Background
The current MCPB manifest schema lacks:
Goals
Fields to Localize
Localizable fields (if present in the manifest):
display_namedescriptionlong_descriptionauthor.name(if surfaced in UI)license(if surfaced verbatim in UI; otherwise typically a SPDX identifier and not localized)keywords(when rendered as user-visible labels; if used solely for search indexing, localization is optional)Explicitly NOT in scope (either not user-facing, structured, or out of initial phase):
iconsor future classification constructs) unless and until the base spec adopts them and they are recognized as user-visible text.Proposed Changes
1. Localization
Introduce a
localizationobject with per-locale resource discovery:Locale Format:
en-US,fr-FR,zh-Hans).Important:
resourcesrelative to the server package's install path (i.e. its__dirname).Main Manifest
{ "manifest_version": "0.3", "name": "sample-mcp-server", "display_name": "Sample MCP Server", "description": "Provides advanced features", "long_description": "Extended description for UI", "keywords": ["mcp", "bundle"], "localization": { "resources": "resources/${locale}.json", "default_locale": "en-US" }, "icons": [ { "src": "assets/icons/icon-16-light.png", "sizes": "16x16", "theme": "light" }, { "src": "assets/icons/icon-16-dark.png", "sizes": "16x16", "theme": "dark" } ] }Sample Locale File (
fr-FR.json){ "display_name": "Serveur MCP Exemple", "description": "Fournit des fonctionnalités avancées", "long_description": "Description détaillée pour les utilisateurs", "keywords": ["mcp", "bundle"] }Future Expansion
We can allow explicit placeholder syntax for overrides:
This gives developers full control over mapping without relying on conventions.
2. Icons
Follow MCP registry’s
server.jsonpattern (array of objects):Do icons need localization?
No. Icons are visual assets and typically do not require language-specific variants. Theme and size differentiation is sufficient.
Definitions:
sizes: String inwidthxheightformat (e.g.,16x16).theme: Optional, values:"light","dark", or a custom platform-dependent string (this can be used to cater to specific themes such as high contrast).Why This Design?
Trade-offs
Compatibility
localizationoriconsis missing, fallback to existingdisplay_name,description, andicon.Final Notes
Fixes #98