Merge cloud venue biomes into dashboard weather and Emberwake biome chip.
Some checks failed
CI Docker Mining Proof / Linux agent hashrate proof (push) Has been cancelled
Some checks failed
CI Docker Mining Proof / Linux agent hashrate proof (push) Has been cancelled
This commit is contained in:
@@ -25,6 +25,8 @@ import SupplyChainExportWizard from '../components/Emberwake/SupplyChainExportWi
|
||||
import SSMSpreadPanel from '../components/Emberwake/SSMSpreadPanel';
|
||||
import SubnetAutopsyCard from '../components/Atlas/SubnetAutopsyCard';
|
||||
import { parseSeerSubnetAutopsy } from '../help/subnetAutopsy';
|
||||
import { activeBiomeLabel, type CloudVenueSnapshot } from '../help/cloudVenueBiomeWeather';
|
||||
import type { ScoutConstellationSnapshot } from '../help/scoutBiomeWeather';
|
||||
import { HelpTip } from '../components/HelpTip';
|
||||
import './EmberwakePage.css';
|
||||
import '../components/Presence/Presence.css';
|
||||
@@ -74,6 +76,18 @@ export default function EmberwakePage() {
|
||||
|
||||
const pinned = useMemo(() => builds.filter((b) => b.pinned), [builds]);
|
||||
|
||||
const biomeLabel = useMemo(() => {
|
||||
let scout: ScoutConstellationSnapshot | null = null;
|
||||
let cloud: CloudVenueSnapshot | null = null;
|
||||
if (latestMessage?.type === 'scout_constellations') {
|
||||
scout = latestMessage.payload as ScoutConstellationSnapshot;
|
||||
}
|
||||
if (latestMessage?.type === 'cloud_venue_biomes') {
|
||||
cloud = latestMessage.payload as CloudVenueSnapshot;
|
||||
}
|
||||
return activeBiomeLabel(scout, cloud);
|
||||
}, [latestMessage]);
|
||||
|
||||
// Keep refs so `load` can read current pin values without listing them as deps.
|
||||
// Listing pinA/pinB as deps caused a cascade: load() → setPinA/setPinB →
|
||||
// re-render → new load reference → useEffect fires load() again (×N).
|
||||
@@ -242,6 +256,11 @@ export default function EmberwakePage() {
|
||||
<p className="page-subtitle">
|
||||
Tag install links, export lure kits, and track which campaigns convert — all from one desk.
|
||||
</p>
|
||||
{biomeLabel && (
|
||||
<p className="emberwake-biome-chip font-tech" data-testid="emberwake-biome-chip">
|
||||
Weather biome · {biomeLabel}
|
||||
</p>
|
||||
)}
|
||||
<p className="emberwake-hero-links form-hint">
|
||||
<a href={SPREAD_TECHNIQUES_DOC} target="_blank" rel="noreferrer">
|
||||
Spread techniques playbook
|
||||
|
||||
Reference in New Issue
Block a user