SPB Git forge
1commits 1branches 0releases
189.0 KBsize
maindefault branch
6 h agolast push
Python 54.7% TypeScript 42.5% SQL 1.9%
2.3 KB · 36 lines tsx
Raw Blame History
1import { Lock } from "lucide-react";2import { Badge, Card, Empty, PageHeader } from "@/components/ui";34const CHECKLIST = [5  ["Owner confirmation in the UI (second confirmation)", "Live mode can never be enabled by a background process or an agent."],6  ["Trade-key permission verified by preflight", "Separate least-privilege key with order permission only; withdrawal permission is never used."],7  ["Risk budget selected", "Per-order, per-symbol, daily-loss and drawdown limits acknowledged for the live book."],8  ["Small-size canary completed", "A documented minimum-size order cycle before any strategy is allowed to route live."],9  ["Feature flag KTRADE_LIVE_TRADING_ENABLED=true", "Server-side gate; off by default and in every deployment so far."],10];1112export default function ExecutionPage() {13  return (14    <>15      <PageHeader title="Execution Console" subtitle="Order lifecycle, routing status, Kraken error codes, latency and reconciliation. Paper routing arrives in Phase 4; the live adapter in Phase 5." />16      <div className="mb-4 flex gap-2" role="tablist" aria-label="Execution environment">17        <button role="tab" aria-selected="true" className="rounded-md border border-accent bg-accent-soft px-3 py-1.5 text-xs">Paper</button>18        <button role="tab" aria-selected="false" aria-disabled="true" disabled className="inline-flex items-center gap-1.5 rounded-md border border-line-strong px-3 py-1.5 text-xs text-fg-dim"><Lock className="h-3 w-3" /> Live <Badge tone="muted">locked</Badge></button>19      </div>20      <div className="grid gap-4 md:grid-cols-2">21        <Card title="Order lifecycle"><Empty title="No orders">No paper or live orders have been created. Order ids are idempotent client ids (cl_ord_id) so retries can never duplicate an order.</Empty></Card>22        <Card title="Live activation checklist" subtitle="All items are required, in order. None is satisfied.">23          <ol className="space-y-2">24            {CHECKLIST.map(([t, d]) => (25              <li key={t} className="flex items-start gap-2 text-xs">26                <input type="checkbox" disabled aria-label={t} className="mt-0.5" />27                <span><span className="font-medium text-fg">{t}</span><br /><span className="text-fg-dim">{d}</span></span>28              </li>29            ))}30          </ol>31        </Card>32      </div>33    </>34  );35}36