Files
next-ai-draw-io/packages/mcp-server/shell/index.html
T
dayuan.jiang 77c6a2d807 feat(mcp-server): canvas shell bundled from the web app's canvas with esbuild
The shell (packages/mcp-server/shell) renders DrawioFrame inside the
shared providers without the chat: its config comes from
window.__MCP_CONFIG__, the four dictionaries ship in the bundle, the
theme is kept under an mcp: localStorage key, and system fonts stand in
for the web fonts. scripts/build-shell.mjs bundles it into dist/shell
with the root's esbuild and Tailwind; check-package caps shell.js at
1.5 MB and shell.css at 300 KB.
2026-10-11 20:56:07 +09:00

32 lines
1.2 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Next AI Draw.io</title>
<link rel="icon" href="data:,">
<link rel="stylesheet" href="/shell/shell.css">
<script>window.__MCP_CONFIG__ = {{CONFIG_JSON}};</script>
<script>
// Dark class before the first paint (no white flash). The same rule
// as shell/theme.ts: the choice stored under "mcp:dark-mode", else
// the server's DRAWIO_DARK, else the system
try {
const config = window.__MCP_CONFIG__ || {}
const stored = localStorage.getItem("mcp:dark-mode")
const dark =
stored === "true" ||
(stored === null &&
(config.drawioDark === "dark" ||
(config.drawioDark !== "light" &&
matchMedia("(prefers-color-scheme: dark)").matches)))
if (dark) document.documentElement.classList.add("dark")
} catch {}
</script>
</head>
<body class="antialiased">
<div id="root"></div>
<script type="module" src="/shell/shell.js"></script>
</body>
</html>