Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tentative Feature #81

Merged
merged 31 commits into from
Sep 24, 2018
Merged

Tentative Feature #81

merged 31 commits into from
Sep 24, 2018

Conversation

supersonicclay
Copy link
Collaborator

@supersonicclay supersonicclay commented Sep 20, 2018

Instead of calling onEdit for tentative features, store then internally in nebula.gl.

So, for example:

  • When in drawLineString, only call onEdit when two points are clicked (i.e. don't add a Point feature)
  • When in any of the draw polygon modes (e.g. drawPolygon, drawRectangleUsing3Points), only call onEdit when the polygon is complete (i.e. don't add a Point or LineString feature)

This means nebula will no longer "upgrade" geometry types.

In action

tentative-features

More Testable

Much of the pointer move and click functionality was factored out of EditableGeoJsonLayer into EditableFeatureCollection. So, it should be much more testable going forward.

Other fixes

Fixes #69

TODO

[X] POC with drawLineString
[X] Refactor other draw modes
[X] delete updatedMode
[X] delete updatedSelectedFeatureIndexes
[X] Rename "draw" to "tentative" for rendering props
[X] Documentation
[X] Add example of test for onPointerMove
[X] Add example of test for onClick
[ ] Refactor add intermediate position?
[ ] Refactor move position?
[ ] Refactor rotate?

@supersonicclay supersonicclay self-assigned this Sep 20, 2018
@supersonicclay supersonicclay force-pushed the clay/tentative-feature branch 4 times, most recently from 24d92bf to ec0e6d7 Compare September 21, 2018 03:11
@supersonicclay supersonicclay changed the title WIP: Tentative Feature Tentative Feature Sep 22, 2018
@supersonicclay supersonicclay added this to the Nebula 1.0.0 milestone Sep 22, 2018
@supersonicclay supersonicclay merged commit d3092f1 into master Sep 24, 2018
@supersonicclay supersonicclay deleted the clay/tentative-feature branch September 24, 2018 20:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

dblclick event is also firing 2 additional pointer up/down events
2 participants