Files
XZBT-NGN/public/index.html
T
2026-09-14 13:01:45 -07:00

30 lines
2.6 KiB
HTML

<!doctype html>
<html lang="en">
<head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>XZBT-NGN Exhibit Engine</title><link rel="stylesheet" href="/public/style.css"></head>
<body>
<header><h1>XZBT-NGN Exhibit Engine</h1><p>Contract 5.2 · One exhibit at a time</p></header>
<main>
<section><h2>Connection</h2>
<form id="connection"><label for="exhibit-url">Exhibit URL (same origin)</label><div class="connection-row"><input id="exhibit-url" placeholder="/public/exhibits/example/index.html" required><button>Load exhibit</button><button id="reconnect" type="button" disabled>Reconnect</button><button id="disconnect" type="button" disabled>Disconnect</button></div></form>
<p>Enter a trusted exhibit's local served path or a URL on this origin. Load exhibit also switches exhibits. Reconnect starts a new session, or reloads the last exhibit after disconnect.</p>
<p id="status" role="status">Disconnected</p><p id="identity"></p><p id="loaded-url"></p>
<p id="latest-error" role="alert" hidden></p>
<div id="frame-container"></div>
</section>
<section><h2>Exhibit controls <span id="target-count"></span></h2>
<details><summary>Capabilities</summary><ul id="capabilities"></ul><p>Unavailable requirements disable affected controls. Available/loading capabilities may use an exhibit fallback; the exhibit decides whether to accept a request.</p></details>
<p>Reported values are authoritative. New values are drafts; select Set or Invoke to submit. Rediscovery resets drafts.</p>
<div id="catalog">Connect an exhibit to discover its controls.</div>
</section>
<section><h2>State and metadata</h2><button id="refresh" disabled>Refresh state</button>
<details><summary>Session and exhibit metadata</summary><pre id="metadata">No negotiated session.</pre></details>
<details><summary>Current persistent state</summary><p>Last reported exhibit values. This host view may be uncertain while resynchronizing.</p><pre id="state">{}</pre></details>
</section>
<section><h2>Protocol diagnostics</h2>
<details><summary>Incoming events</summary><p>Latest 200 session events, including source, sequence, revision, and correlation when supplied.</p><pre id="events" aria-label="Incoming events">[]</pre></details>
<details><summary>Protocol and errors</summary><p>Latest 200 entries across connections in this page. Timestamps identify earlier failures.</p><button id="clear-errors">Clear log</button><pre id="errors" role="log">[]</pre></details>
</section>
</main>
<script type="module" src="/src/ui.js"></script>
</body></html>