- core/theme.js: export NEXUS with full NEXUS.theme.* properties used by all 6 panels - core/ticker.js: add subscribe() convenience export so panels can self-register - data/gitea.js: also write state.agentStatus, activeAgentCount, zoneIntensity, commits, commitHashes - data/loaders.js: also write state.sovereignty - data/bitcoin.js: also write state.blockHeight, lastBlockHeight, newBlockDetected, starPulseIntensity - data/weather.js: also write state.weather - app.js: import + init all 6 panel modules, bootstrap data polling, call globalTicker.tick() Fixes #412 Refs #409 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
53 lines
1.8 KiB
JavaScript
53 lines
1.8 KiB
JavaScript
// modules/core/theme.js — NEXUS design system: colors, fonts, line weights, glow params
|
|
// All visual constants live here. No inline hex codes allowed in any other module.
|
|
|
|
export const NEXUS = {
|
|
theme: {
|
|
// Typography
|
|
fontMono: '"Courier New", monospace',
|
|
|
|
// Panel surfaces (CSS strings — canvas / DOM)
|
|
panelBg: 'rgba(0, 6, 20, 0.90)',
|
|
panelBorderFaint: '#1a3a6a',
|
|
panelDim: '#556688',
|
|
panelText: '#ccd6f6',
|
|
panelVeryDim: '#334466',
|
|
|
|
// Primary accent
|
|
accent: 0x4488ff, // hex integer — THREE.Color / PointLight
|
|
accentStr: '#4488ff', // CSS string — canvas / DOM
|
|
|
|
// Agent status (CSS strings — canvas fillStyle / strokeStyle)
|
|
agentWorking: '#00ff88',
|
|
agentIdle: '#4488ff',
|
|
agentDormant: '#334466',
|
|
agentDormantHex: '#223366', // dim offline; safe for new THREE.Color()
|
|
agentDead: '#ff4444',
|
|
|
|
// Sovereignty arc gauge
|
|
sovereignHighHex: 0x00ff88, // hex integer — THREE.Color.setHex()
|
|
sovereignMidHex: 0x4488ff,
|
|
sovereignLowHex: 0xff4444,
|
|
sovereignHigh: '#00ff88', // CSS string — canvas fillStyle
|
|
sovereignMid: '#4488ff',
|
|
sovereignLow: '#ff4444',
|
|
|
|
// LoRA panel (CSS strings)
|
|
loraAccent: '#cc44ff',
|
|
loraActive: '#00ff88',
|
|
loraInactive: '#334466',
|
|
|
|
// Holographic Earth (hex integers — THREE materials)
|
|
earthOcean: 0x0a1f3f,
|
|
earthLand: 0x1a4030,
|
|
earthGlow: 0x4488ff,
|
|
earthAtm: 0x2266bb,
|
|
},
|
|
};
|
|
|
|
// Legacy constants retained for scene-setup compat
|
|
export const THEME = {
|
|
glass: { color: 0x112244, opacity: 0.35, roughness: 0.05, metalness: 0.1, transmission: 0.95, thickness: 0.8, ior: 1.5 },
|
|
text: { primary: '#4af0c0', secondary: '#7b5cff', white: '#ffffff', dim: '#a0b8d0' },
|
|
};
|