• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

ehtick / deck.gl / 21389488284

27 Jan 2026 05:52AM UTC coverage: 91.101% (-0.01%) from 91.114%
21389488284

push

github

web-flow
chore(mapbox): Remove internal deck mode from `MapboxLayer` (#9955)

* chore(mapbox): Remove internal deck mode from MapboxLayer

MapboxLayer is no longer a public API (only MapboxOverlay is exported),
so the internal deck mode code paths are no longer needed.

Changes:
- Remove `isExternal` flag from UserData (always true now)
- Remove internal deck creation branch in getDeckInstance
- Remove `updateLayers` function (only used for internal mode)
- Make `deck` prop required in getDeckInstance
- Simplify MapboxLayer and MapboxLayerGroup to read map.__deck directly
- Only MapboxOverlay calls getDeckInstance for initialization
- Update tests to simulate MapboxOverlay flow

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor(mapbox): Use getter for deck in MapboxLayer and MapboxLayerGroup

Replace `this.deck` field with a getter that reads from `map.__deck`
directly. This avoids potential stale references and simplifies the
lifecycle - `onAdd` no longer needs to capture the deck instance.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix(mapbox): Keep non-null assertions in render method

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor(mapbox): Make __deck non-optional in MapWithDeck type

Since MapboxLayer and MapboxLayerGroup are internal classes only used
by MapboxOverlay, and MapboxOverlay always sets up map.__deck before
adding these layers, __deck is guaranteed to exist when the map is set.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor(mapbox): Remove deck getter, access map.__deck directly

Since __deck is guaranteed on MapWithDeck, we can access it directly
through the map rather than through a getter.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* test(mapbox): Remove trivial deck instance assertions

These assertions just verified getDeckInstance set map.__deck, which
is obvious and doesn't test any MapboxLayer behavior.

Co-Authored-By: Claude Opus 4.5 <norepl... (continued)

6859 of 7536 branches covered (91.02%)

Branch coverage included in aggregate %.

59 of 0 new or added lines in 0 files covered. (NaN%)

2 existing lines in 1 file now uncovered.

56796 of 62337 relevant lines covered (91.11%)

14393.11 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

79.17
/modules/mapbox/src/deck-utils.ts


Build SHA Not Found

The commit SHA "914c3d2c29832b880ae24f1b2478c05af8250351" was not found in your repository, so the file cannot be loaded. This may be because you posted from a local development environment, or your CI created an ephemeral commit.

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc