Skip to content

feat(site-template): build mcp-server sites, drop innerHTML, add main landmark and meta#83

Merged
TMHSDigital merged 1 commit into
mainfrom
feat/template-mcp-server-support
Jun 17, 2026
Merged

feat(site-template): build mcp-server sites, drop innerHTML, add main landmark and meta#83
TMHSDigital merged 1 commit into
mainfrom
feat/template-mcp-server-support

Conversation

@TMHSDigital

Copy link
Copy Markdown
Owner

Summary

Template parity and MCP-server support from site-audit.md: T1, C1, A1 (template-side), S1 (template-side). No VERSION bump ([skip version]).

Findings addressed

  • T1 build_site.py exited 1 when .cursor-plugin/plugin.json was absent, so MCP-server repos could not use the shared template. plugin.json is now optional: when absent it falls back to site.json + package.json for display name (humanized, acronyms like MCP upper-cased), description, repository, version, and license. site.json is the one required input.
  • C1 Theme-toggle and install copy-button icons are now built with DOMParser + importNode instead of innerHTML, matching the catalog's hardening. Rendered output has zero innerHTML.
  • A1 (template) Content wrapped in <main id="main"> with a visually-hidden skip link.
  • S1 (template) og:image defaults to the directory logo when site.ogImage is unset; added Twitter card tags and optional canonical/og:url from site.canonical. Theme toggle also gained a state-reflecting aria-label.

Verification (proves T1)

Built build_site.py against C:\Dev\screencast-mcp with no synthesized plugin.json:

  • Builds and renders: title and h1 "Screencast MCP", single MCP stat = 25, 25-tool table, footer v0.8.12.
  • Rendered output: 0 innerHTML, <main id="main"> + skip link present, og:image defaulted, Twitter tags present.
  • Post-JS DOM: #themeIcon populated via DOMParser; toggle aria-label = "Theme: auto (click to change)".
  • Source repo left untouched (clean git status).
  • Full suite: 239 passed, 1 skipped (born-green test renders the template for both repo types).

🤖 Generated with Claude Code

… landmark and meta [skip version]

The shared template could not build an MCP-server repo: build_site.py exited 1
when .cursor-plugin/plugin.json was absent, which MCP servers do not ship, so
they hand-rolled their pages instead (T1). It also used innerHTML for the theme
and copy icons (C1), had no main landmark or skip link (A1), and emitted no
og:image when site.ogImage was unset (S1).

- build_site.py: plugin.json is now optional. When absent it falls back to
  site.json + package.json for display name (humanized from the package name,
  acronyms like MCP upper-cased), description, repository, version, and license.
  site.json is the one required input.
- template.html.j2: theme-toggle and install copy-button icons are built with
  DOMParser + importNode instead of innerHTML, matching the catalog's hardening.
  Wrapped content in <main id="main"> with a visually-hidden skip link, and the
  theme toggle now sets an aria-label reflecting the current state.
- template head: og:image defaults to the directory logo when site.ogImage is
  unset, plus Twitter card tags and an optional canonical/og:url from
  site.canonical.
- SETUP-PROMPT.md: documents the plugin.json fallback and updates troubleshooting.

Verified by building site-template/build_site.py against C:\Dev\screencast-mcp
with no synthesized plugin.json: it builds and renders (title and h1 "Screencast
MCP", 25-tool table, footer v0.8.12), the rendered output has zero innerHTML and
a populated themeIcon, and the source repo is untouched.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Signed-off-by: TMHSDigital <TMHospitalityStrategies@gmail.com>
@github-actions

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@TMHSDigital TMHSDigital merged commit d1f5989 into main Jun 17, 2026
14 checks passed
@TMHSDigital TMHSDigital deleted the feat/template-mcp-server-support branch June 17, 2026 21:25
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