Skip to content

Conversation

vgeorge
Copy link
Member

@vgeorge vgeorge commented Oct 7, 2025

Contributes to #886

Related work

Changes introduced

  • Bump Deck.gl to v9.1.15
  • Add Playwright setup for automated UI testing
  • Introduce a Mapbox overlay–based Globe View (GlobeMap), rendered when projection="globe" is set

Description

This PR takes a first, minimal step toward supporting the Globe View by introducing the Mapbox overlay approach.

Playwright testing is added to validate key UI interactions and prevent regressions. The current setup includes a test that verifies bounding box selection on the flat map. We can expand it later to cover other existing features once the testing framework stabilizes.

How to review

  • Run npm run test:e2e, all tests should pass
  • Open any existing example and set projection="globe", the map should render data using the Globe View (bbox selection is not yet supported)

Preview

globe

Follow-ups

  • Confirm if the approach is viable for the Globe View
  • Add Playwright tests to CI

@kylebarron this is ready for a first review.

- Set up Playwright with isolated JupyterLab instance (port 8889)
- Expose DeckGL instance via React ref for programmatic access
- Create test helpers for DeckGL canvas interactions (deckClick, deckHover, deckDrag)
- Create notebook helpers for JupyterLab operations
- Implement bbox selection test that verifies selected_bounds syncs to Python
- Add test scripts: test:e2e, test:e2e:ui, jupyter:test

DeckGL canvas interactions bypass DOM events and call handlers directly
via deck.pickObject() and deck.props.onClick/onHover, enabling automated
testing of map interactions.
@vgeorge vgeorge requested a review from kylebarron October 7, 2025 15:42
@vgeorge vgeorge changed the title Feat: add Globe View and automated UI testing with Playwright feat: add Globe View and automated UI testing with Playwright Oct 7, 2025
@github-actions github-actions bot added the feat label Oct 7, 2025
Add vitest configuration to exclude tests/e2e/** directory from vitest
runs. This prevents vitest from attempting to execute Playwright test
files, which was causing CI failures.

The e2e tests should only be run via the dedicated test:e2e npm script
which uses Playwright's test runner.
Resolved conflicts in package.json and package-lock.json by removing
duplicate deck.gl dependency entries that were present in main.
@kylebarron
Copy link
Member

Thanks for this! I'll write up some more thoughts, but first, could we split the playwright tests into a separate PR? I think that part is quite valuable on its own and will be relatively easy to merge while the globe view might take a little longer to architect.

Copy link
Member

Choose a reason for hiding this comment

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

Are these types not exported from a deck.gl module?

Copy link
Member Author

Choose a reason for hiding this comment

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

They probable are, I'll check.

@vgeorge
Copy link
Member Author

vgeorge commented Oct 8, 2025

@kylebarron sounds good, I'll create a separated PR just for the playwright implementation.

@kylebarron
Copy link
Member

deck.gl now works seamlessly with the MapLibre v5 globe view for all three Basemap Intergration Modes

It's possible we may not need to use MapboxOverlay at all for globe view https://deck.gl/docs/whats-new#globe-view--maplibre

@kylebarron
Copy link
Member

See #908 for what I'm thinking of for the Python side, and then when that's serialized to the JS side, we'd switch on the basemap.mode attribute to decide whether to render MapboxOverlay or not

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants