Skip to content

fix: Fix PointLayer polygon filtering for GeoJSON column mode#3410

Merged
igorDykhta merged 3 commits into
masterfrom
igr/fix-point-layer-polygon-filter-geojson
May 4, 2026
Merged

fix: Fix PointLayer polygon filtering for GeoJSON column mode#3410
igorDykhta merged 3 commits into
masterfrom
igr/fix-point-layer-polygon-filter-geojson

Conversation

@igorDykhta
Copy link
Copy Markdown
Collaborator

@igorDykhta igorDykhta commented May 3, 2026

Signed-off-by: Ihor Dykhta <ihordykhta@Ihors-MacBook-Pro.local>
Copilot AI review requested due to automatic review settings May 3, 2026 00:31
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes polygon/rectangle filtering behavior for PointLayer when using GeoJSON column mode by ensuring polygon filtering operates on parsed numeric coordinates (including MultiPoint-like cases) rather than raw GeoJSON/WKT values.

Changes:

  • Update polygon filter functor to use layer.dataToFeature coordinates for point/icon layers when available.
  • Fix PointLayer GeoJSON column mode to index dataToFeature by the underlying row index (filteredIndex[i]) instead of the loop counter.
  • Add node tests covering polygon filtering for point layers in GeoJSON column mode, including MultiPoint behavior.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
test/node/utils/filter-utils-test.js Adds coverage for polygon filtering with dataToFeature (GeoJSON column mode) and MultiPoint semantics.
src/utils/src/filter-utils.ts Adjusts polygon filtering logic for point/icon layers to use dataToFeature coordinates.
src/layers/src/point-layer/point-layer.ts Corrects dataToFeature indexing in GeoJSON column mode when iterating filtered rows.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/utils/src/filter-utils.ts
Comment thread src/utils/src/filter-utils.ts Outdated
Comment thread src/utils/src/filter-utils.ts Outdated
Signed-off-by: Ihor Dykhta <ihordykhta@Ihors-MacBook-Pro.local>
@igorDykhta igorDykhta added the 3.3 Kepler.gl 3.3 release label May 3, 2026
@igorDykhta igorDykhta requested a review from lixun910 May 3, 2026 00:39
Signed-off-by: Ihor Dykhta <ihordykhta@Ihors-MacBook-Pro.local>
@igorDykhta igorDykhta self-assigned this May 3, 2026
@igorDykhta igorDykhta merged commit 735bfc0 into master May 4, 2026
8 checks passed
@igorDykhta igorDykhta deleted the igr/fix-point-layer-polygon-filter-geojson branch May 4, 2026 10:59
@leverglowh
Copy link
Copy Markdown
Contributor

This should fix #3278
Other stale pr (still open): #3321

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

Labels

3.3 Kepler.gl 3.3 release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants