85a5ba09b8
- webapp/: deployable LAMP app for /var/www/ — ingest.php (token-gated writes), api.php (public read-only), schema.sql (live_price + signal_reports), vanilla-JS dashboard with plain-English indicator readings, .htaccess, deploy README - web_publisher.py: fire-and-forget publisher (bounded queue + daemon thread) with plain-English payload builder; public API contractually never raises; disabled unless WEBAPP_INGEST_URL/TOKEN are set - telegram_bot.py: publish hooks (tick in WS loop, report in _update_level_cache); _candle_loop per-iteration guard so a failing scan can never kill an auto-scan loop; quiet heartbeat teardown - test_all.py: Module 13 — 6 resilience tests (never-raise contract, worker survival, candle-loop survival); suite 189/189 - .gitignore: webapp/config.php (server-side secrets) Verified end-to-end on a scratch MariaDB 10.11 + PHP 8.3 built-in server incl. headless-Firefox render of the live page. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KYNEHBuwwy6sgRM9f9sPx5
154 lines
5.4 KiB
CSS
154 lines
5.4 KiB
CSS
/* ForexBot2 dashboard — numbers-only stat tiles.
|
|
Color roles follow the validated reference palette:
|
|
status good #0ca30c · warning #fab219 · critical #d03b3b (fixed, never
|
|
themed); surfaces #fcfcfb / #1a1a19; text wears text tokens only. */
|
|
|
|
:root {
|
|
color-scheme: light;
|
|
--surface-1: #fcfcfb;
|
|
--surface-2: #f4f3f0;
|
|
--border: #e3e2dd;
|
|
--text-primary: #0b0b0b;
|
|
--text-secondary: #52514e;
|
|
--text-muted: #8a8985;
|
|
--good: #0ca30c;
|
|
--warning: #b97e00; /* darkened warning for light-surface text */
|
|
--warning-bg: #fff6e0;
|
|
--critical: #d03b3b;
|
|
--chip-neutral-bg: #ececea;
|
|
--good-bg: #e8f6e8;
|
|
--critical-bg: #fbe9e9;
|
|
}
|
|
@media (prefers-color-scheme: dark) {
|
|
:root {
|
|
color-scheme: dark;
|
|
--surface-1: #1a1a19;
|
|
--surface-2: #232322;
|
|
--border: #3a3a37;
|
|
--text-primary: #ffffff;
|
|
--text-secondary: #c3c2b7;
|
|
--text-muted: #8f8e86;
|
|
--good: #2fbf2f;
|
|
--warning: #fab219;
|
|
--warning-bg: #33290e;
|
|
--critical: #e66767;
|
|
--chip-neutral-bg: #32322f;
|
|
--good-bg: #14320f;
|
|
--critical-bg: #3b1414;
|
|
}
|
|
}
|
|
|
|
* { box-sizing: border-box; }
|
|
body {
|
|
margin: 0;
|
|
background: var(--surface-1);
|
|
color: var(--text-primary);
|
|
font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
}
|
|
.wrap { max-width: 980px; margin: 0 auto; padding: 20px 16px 40px; }
|
|
|
|
/* header / hero figure */
|
|
.top {
|
|
display: flex; justify-content: space-between; align-items: flex-end;
|
|
gap: 16px; flex-wrap: wrap; margin-bottom: 18px;
|
|
}
|
|
.brand { font-size: 20px; font-weight: 700; }
|
|
.pair { color: var(--text-secondary); }
|
|
.hero { text-align: right; }
|
|
.hero-price {
|
|
font-size: 52px; font-weight: 650; line-height: 1.05;
|
|
font-variant-numeric: tabular-nums;
|
|
transition: color .4s ease;
|
|
}
|
|
.hero-price.up { color: var(--good); }
|
|
.hero-price.down { color: var(--critical); }
|
|
.hero-meta { color: var(--text-muted); font-size: 13px; }
|
|
.dot {
|
|
display: inline-block; width: 8px; height: 8px; border-radius: 50%;
|
|
background: var(--text-muted); margin-right: 6px;
|
|
}
|
|
.dot.live { background: var(--good); }
|
|
.dot.stale { background: var(--warning); }
|
|
|
|
.banner {
|
|
background: var(--warning-bg); color: var(--text-primary);
|
|
border: 1px solid var(--warning); border-radius: 8px;
|
|
padding: 10px 14px; margin-bottom: 14px;
|
|
}
|
|
.hidden { display: none; }
|
|
|
|
/* timeframe strip — stat tiles */
|
|
.tf-strip {
|
|
display: grid; grid-template-columns: repeat(4, 1fr);
|
|
gap: 10px; margin-bottom: 18px;
|
|
}
|
|
@media (max-width: 640px) { .tf-strip { grid-template-columns: repeat(2, 1fr); } }
|
|
.tf-tile {
|
|
background: var(--surface-2); border: 1px solid var(--border);
|
|
border-radius: 10px; padding: 10px 12px; cursor: pointer;
|
|
text-align: left; font: inherit; color: inherit;
|
|
}
|
|
.tf-tile[aria-selected="true"] { border-color: var(--text-secondary); box-shadow: inset 0 0 0 1px var(--text-secondary); }
|
|
.tf-tile .tf-name { font-size: 12px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: .04em; }
|
|
.tf-tile .tf-sig { font-weight: 700; margin-top: 2px; }
|
|
.tf-tile .tf-sub { font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
|
|
|
|
/* cards */
|
|
.card {
|
|
background: var(--surface-2); border: 1px solid var(--border);
|
|
border-radius: 12px; padding: 16px 18px; margin-bottom: 14px;
|
|
}
|
|
.card h2 {
|
|
margin: 0 0 10px; font-size: 13px; font-weight: 600;
|
|
color: var(--text-secondary); text-transform: uppercase; letter-spacing: .05em;
|
|
}
|
|
.summary { font-size: 17px; }
|
|
.meta-line { color: var(--text-secondary); margin-top: 8px; }
|
|
.bar-time { color: var(--text-muted); font-size: 13px; margin-top: 8px; }
|
|
|
|
/* signal + grade chips — status meaning always icon+word, never color alone */
|
|
.chip {
|
|
display: inline-block; padding: 2px 10px; border-radius: 999px;
|
|
font-size: 13px; font-weight: 700; background: var(--chip-neutral-bg);
|
|
color: var(--text-primary); white-space: nowrap;
|
|
}
|
|
.chip.sig-buy { background: var(--good-bg); color: var(--good); }
|
|
.chip.sig-sell { background: var(--critical-bg); color: var(--critical); }
|
|
.chip.grade { font-variant-numeric: tabular-nums; }
|
|
.verdict-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
|
|
|
|
/* trade setup */
|
|
.setup-grid {
|
|
display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
|
|
gap: 10px;
|
|
}
|
|
.setup-grid .stat .label { font-size: 12px; color: var(--text-secondary); }
|
|
.setup-grid .stat .value { font-size: 20px; font-weight: 650; font-variant-numeric: tabular-nums; }
|
|
|
|
/* warnings */
|
|
.warn-list { list-style: none; margin: 0; padding: 0; }
|
|
.warn-list li { padding: 4px 0; color: var(--text-secondary); }
|
|
.warn-list .w-ico { color: var(--warning); margin-right: 8px; }
|
|
|
|
/* indicators table */
|
|
table.ind {
|
|
width: 100%; border-collapse: collapse; font-size: 14px;
|
|
}
|
|
table.ind th {
|
|
text-align: left; font-size: 12px; color: var(--text-secondary);
|
|
text-transform: uppercase; letter-spacing: .04em;
|
|
border-bottom: 1px solid var(--border); padding: 6px 8px;
|
|
}
|
|
table.ind td { border-bottom: 1px solid var(--border); padding: 8px; vertical-align: top; }
|
|
table.ind tr:last-child td { border-bottom: none; }
|
|
td.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
|
|
.ind-name { font-weight: 600; white-space: nowrap; }
|
|
.ind-plain { }
|
|
.ind-desc { color: var(--text-muted); font-size: 12.5px; margin-top: 2px; }
|
|
|
|
.foot { color: var(--text-muted); font-size: 13px; margin-top: 24px; }
|
|
.muted { color: var(--text-muted); }
|
|
.empty {
|
|
color: var(--text-muted); text-align: center; padding: 40px 0;
|
|
}
|