Files
hermes-ui/packages/client/index.html
T
toor c93e1fe1bd
Build / build (push) Canceled after 0s
NPM Lockfile Check / npm ci --ignore-scripts (push) Canceled after 0s
Playwright / e2e (push) Canceled after 0s
Phase 002: rebrand to hermes-ui and consolidate i18n to zh/en
Removes the ekko / hermes-web-ui branding from the whole tree and drops
eight locale files, so the project presents one name and one language pair.

Data compatibility is deliberate, not accidental: DB filenames, the JWT
audience, and skill manifest ownership all still recognise their pre-rename
values so existing deployments under ~/.hermes-web-ui keep working without a
re-login or a re-injection.

scripts/harness-check.mjs now scans for the legacy strings and fails the
build on any new occurrence, with an explicit allow-list (and reasons) for
the compatibility paths that must keep them.
2026-10-16 11:11:29 +08:00

125 lines
3.1 KiB
HTML

<!doctype html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.ico" />
<link rel="apple-touch-icon" href="/logo.png" />
<link rel="manifest" href="/manifest.webmanifest" />
<meta name="theme-color" content="#f7f7f4" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-title" content="hermes-ui" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>hermes-ui</title>
<style>
html,
body,
#app {
min-height: 100%;
}
body {
margin: 0;
background: #f7f7f4;
}
html.dark body {
background: #1a1a1a;
}
.boot-fallback {
min-height: 100vh;
display: grid;
place-items: center;
color: #222222;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}
html.dark .boot-fallback {
color: #f0f0f0;
}
.boot-fallback__logo-wrap {
position: relative;
display: block;
width: 72px;
height: 72px;
border-radius: 18px;
overflow: hidden;
}
.boot-fallback__logo-wrap::after {
content: "";
position: absolute;
inset: 0;
background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.85) 48%, transparent 66%);
transform: translateX(-140%);
mix-blend-mode: screen;
pointer-events: none;
-webkit-mask: url("/logo.png") center / contain no-repeat;
mask: url("/logo.png") center / contain no-repeat;
animation: boot-logo-shimmer 1.8s cubic-bezier(0.45, 0, 0.25, 1) infinite;
}
.boot-fallback__logo-wrap img {
width: 100%;
height: 100%;
object-fit: contain;
border-radius: 18px;
}
@keyframes boot-logo-shimmer {
0% {
transform: translateX(-140%);
}
52%,
100% {
transform: translateX(140%);
}
}
</style>
<!-- Prevent FOUC by applying theme classes immediately -->
<script>
(function() {
try {
const brightness = localStorage.getItem('hermes_brightness') || 'system';
const style = localStorage.getItem('hermes_style') || 'ink';
// Resolve dark mode
const prefersDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
const isDark = brightness === 'dark' || (brightness === 'system' && prefersDark);
// Resolve comic style
const isComic = style === 'comic';
// Apply classes immediately
if (isDark) {
document.documentElement.classList.add('dark');
}
if (isComic) {
document.documentElement.classList.add('comic');
}
} catch (e) {
console.warn('Failed to apply theme:', e);
}
})();
</script>
</head>
<body>
<div id="app">
<div class="boot-fallback">
<div class="boot-fallback__brand">
<span class="boot-fallback__logo-wrap">
<img src="/logo.png" alt="" />
</span>
</div>
</div>
</div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>