feat: support GeoJSON FeatureCollection tiles - #91
Conversation
1dfb051 to
987d758
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 987d758313
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| done(error, canvas); | ||
| } | ||
|
|
||
| data = Kothic.normalizeData(data); |
There was a problem hiding this comment.
Preserve normalized payload for subclass consumers
Rebinding data to Kothic.normalizeData(data) creates a new object for GeoJSON FeatureCollection inputs, but L.TileLayer.Kothic.Clickable._onKothicDataResponse (in dist/kothic-leaflet-clickable.js) still reads the original argument after calling the parent method. In that path, features remain type: "Feature" with nested geometry, so the clickable layer stores no point features and featureclick stops working for GeoJSON tiles. This regression occurs specifically when using the clickable layer with wrapped GeoJSON features.
Useful? React with 👍 / 👎.
Signed-off-by: Darafei Praliaskouski <me@komzpa.net>
987d758 to
3bf7a62
Compare
Summary
FeatureCollectiontile payloads by normalizing wrappedFeature.geometryobjects into Kothic's existing feature shapeFixes #67.
Validation
npm test