Skip to content

feat: add sensor fusion deck#3713

Open
SteveDigital-Dev wants to merge 1 commit into
koala73:mainfrom
SteveDigital-Dev:feat/sensor-fusion-deck
Open

feat: add sensor fusion deck#3713
SteveDigital-Dev wants to merge 1 commit into
koala73:mainfrom
SteveDigital-Dev:feat/sensor-fusion-deck

Conversation

@SteveDigital-Dev
Copy link
Copy Markdown

Summary

  • Add a Sensor Fusion Deck panel for WorldView-style public geospatial stream inventory
  • Summarize live/available layers and tracked object counts from existing map/cache state
  • Document Bilawal WorldView / internet-3D takeaways with privacy/provenance guardrails

Test plan

  • npx tsx --test tests/sensor-fusion.test.mts
  • npm run typecheck -- --pretty false
  • npx biome check src/services/sensor-fusion.ts src/components/SensorFusionPanel.ts tests/sensor-fusion.test.mts src/app/panel-layout.ts src/components/index.ts

Note: Biome reports the existing panel-layout createPanels cognitive-complexity warning, but exits 0.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 16, 2026

@SteveDigital-Dev is attempting to deploy a commit to the World Monitor Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions Bot added the trust:caution Brin: contributor trust score caution label May 16, 2026
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 16, 2026

Greptile Summary

This PR adds a Sensor Fusion Deck panel that reads from existing intelligenceCache and mapLayers state to give operators a live inventory of which geospatial streams are fused and which remain roadmap-only — a lightweight summary layer with no new data fetches required.

  • src/services/sensor-fusion.ts / SensorFusionPanel.ts: New service + panel wired cleanly into the layout manager; snapshot logic is correct and covered by unit tests.
  • src/styles/panels.css: The new CSS block is inserted inside the still-open .latest-brief-empty {} rule (the original closing } was shifted to line 3120 after the insertion). All sensor fusion selectors are effectively invisible until this is fixed.
  • src/config/panels.ts / variant configs: Panel added to FULL_PANELS but not to any variant DEFAULT_PANELS, so it may not surface by default in any deployed variant.

Confidence Score: 3/5

The panel renders completely unstyled due to the CSS insertion bug, blocking a clean ship.

The CSS edit inserts ~115 lines of new rules before the closing } of .latest-brief-empty, so none of the sensor fusion selectors take effect. The service logic, component lifecycle, and tests are all correct; only the stylesheet needs a one-line fix.

src/styles/panels.css needs .latest-brief-empty closed before the sensor fusion comment. src/config/variants/full.ts may need sensor-fusion added to DEFAULT_PANELS.

Important Files Changed

Filename Overview
src/services/sensor-fusion.ts New service that reads from existing cache/map state to produce a SensorFusionSnapshot; logic is correct and well-tested.
src/components/SensorFusionPanel.ts New Panel subclass with a 30-second refresh timer; properly clears the interval on destroy and guards re-renders when disconnected.
src/styles/panels.css Sensor fusion CSS block inserted before the closing } of .latest-brief-empty, nesting ~115 lines of new rules inside the wrong parent block and rendering them all ineffective.
src/app/panel-layout.ts Wires SensorFusionPanel into the layout manager, passing a lambda for live cache/mapLayers access; follows existing panel creation pattern.
src/config/panels.ts Adds sensor-fusion to FULL_PANELS but no corresponding entry was added to any variant DEFAULT_PANELS, so the panel may be invisible by default.
tests/sensor-fusion.test.mts Unit tests for buildSensorFusionSnapshot cover the happy-path count aggregation and the enabled-but-empty 'ready' status; assertions are correct.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    PL[PanelLayoutManager] -->|creates| SFP[SensorFusionPanel]
    SFP -->|constructor: getSnapshotInput lambda| CTX[AppContext]
    CTX --> IC[intelligenceCache]
    CTX --> ML[mapLayers]
    SFP -->|render / 30s refresh| BFS[buildSensorFusionSnapshot]
    IC --> BFS
    ML --> BFS
    BFS --> SNAP[SensorFusionSnapshot]
    SNAP --> UI[Panel DOM]
Loading

Reviews (1): Last reviewed commit: "feat: add sensor fusion deck" | Re-trigger Greptile

Comment thread src/styles/panels.css
text-align: center;
color: var(--text-muted, #888);
font-size: 12px;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Sensor fusion styles injected inside .latest-brief-empty {} block

The new CSS block starts at line 3006 but the } that originally closed .latest-brief-empty (which opened at line 3001) was pushed down to line 3120 after the insertion. In browsers without CSS Nesting support every sensor fusion selector is treated as an invalid declaration and silently dropped; in browsers that do support nesting the styles only match within .latest-brief-empty, which never wraps a .sensor-fusion-panel. The fix is to add a closing } for .latest-brief-empty before the sensor fusion comment block.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

trust:caution Brin: contributor trust score caution

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant