hyperhive/hive-c0re/swagger-ui-theme/index.html
iris 062a84378d hive-c0re: swagger theme follows stylix via colors.css, not a hardcoded copy
Loads the dashboard's own themed /static/colors.css directly (same
origin, see vhosts.nix dashboardProxyLocation) instead of redeclaring
the Catppuccin Mocha hex values locally. The theme now re-themes live
with the rest of the dashboard instead of drifting out of sync.

Addresses review feedback on PR.
2026-08-02 21:24:57 +02:00

34 lines
1.7 KiB
HTML

<!-- HTML for static distribution bundle build -->
<!-- Overrides the vendored Swagger UI's own `dist/index.html` (byte-for-
byte identical otherwise — copied from utoipa-swagger-ui-vendored
0.1.2's swagger-ui-5.17.14/dist/index.html) via the crate's
`SWAGGER_UI_OVERWRITE_FOLDER` build-time hook, adding two lines: the
dashboard's own themed `colors.css` (same absolute `/static/`
origin the dashboard dist serves it from — see
nix/host-modules/hive-gateway/vhosts.nix's dashboardProxyLocation,
`/` and `/api/` share one vhost so this resolves whatever the
operator's stylix theme currently renders, not a frozen copy) and
hyperhive-theme.css, which consumes those `--baseNN` vars. Loaded
after swagger-ui.css so hyperhive-theme.css's rules win the cascade
without needing `!important`. See
docs/web-ui/dashboard.md::Dashboard endpoints. -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Swagger UI</title>
<link rel="stylesheet" type="text/css" href="./swagger-ui.css" />
<link rel="stylesheet" type="text/css" href="index.css" />
<link rel="stylesheet" type="text/css" href="/static/colors.css" />
<link rel="stylesheet" type="text/css" href="hyperhive-theme.css" />
<link rel="icon" type="image/png" href="./favicon-32x32.png" sizes="32x32" />
<link rel="icon" type="image/png" href="./favicon-16x16.png" sizes="16x16" />
</head>
<body>
<div id="swagger-ui"></div>
<script src="./swagger-ui-bundle.js" charset="UTF-8"> </script>
<script src="./swagger-ui-standalone-preset.js" charset="UTF-8"> </script>
<script src="./swagger-initializer.js" charset="UTF-8"> </script>
</body>
</html>