Skip to content

Commit

Permalink
Interactivity refactor (#112)
Browse files Browse the repository at this point in the history
* refactor: started on new event managers (WIP)

* feat: new MouseEventTracker

* refactor: code structure

* _

* _

* _

* refactor: cleaner useWindow functionality

* feat: improved structure of EventManager even more

* _

* refactor: folder structure

* _

* refactor: hitUtils (moved _isInSection and shit out of class)

* refactor: put getLocalCoordinates and clamp in separate files

* fix: import paths

* refactor: simplified click handler

* refactor: added Mousedown and Mouseup handlers

* refactor: MouseoverHandler

* refactor: MouseoutHandler

* feat: hooked up MarkInteractionManager with mark InteractionHandlers

* refactor: SectionInteractionHandler

* refactor: started on WheelHandler (wip)

* refactor: wheel interaction handler

* fix: missing section argument for coordinatesAreInSection

* feat: DRY-ing up of mark interaction handlers

* refactor: WheelHandler to extend SectionInteractionHandler

* feat: Section ClickHandler

* feat: Mousedown and Mouseup handlers Section

* feat: Mouseover and Mouseout for Section

* refactor: event structure for section, mark and layer events

* refactor: changed MarkInteractionManager to MarkInteractionInterface etc

* refactor: laid base structure for TouchInteractionManager

* _

* refactor: created classes EventManager and InteractionManager

* refactor: all interaction stuff should be hooked up correctly now

* refactor: Graphic, Section and Mark

* refactor: Layer

* refactor: removed all examples that will not work yet

* fix: imports

* fix: some bugs/typos

* refactor: interactivity folder (makes more sense now)

* _

* fix: imports

* fix: SpatialIndex bugs

* refactor: updated all marks and layers with new interactivity props

* fix: some bugs and mouseover and out work better now

* feat: FunctionAPI example finally working as it should

* refactor: zoom example working again

* feat: Section mousemove event

* _

* feat: blockReindexing flag

* refactor: pan handler (nicer syntax kinda)

* feat: added blockReindexing prop to Section and Graphic that is inherited by children

* feat: panning while blocking reindexing working (albeit with a slightly awkward syntax)

* _

* refactor: started on createDragHandler (WIP)

* fix: bug in interaction logic, and also got other mark dragging working again

* fix: FuncLines example

* refactor: more consistent syntax for handlers

* feat: InteractionHandlers can now listen for multiple events

* feat: MousedragHandler

* feat: onMousedrag working for PointLayer

* feat: added onMousedrag to all Marks and Layers

* fix: blockReindexing reactivity bug

* refactor: removed createDragHandler helper again

* refactor: createPanHandler and createZoomHandler

* fix: all integration tests passing again

* refactor: geometryUtils (took improved versions of utils from transshape)

* _

* feat: indexPoint for select

* feat: indexPolygon for select

* feat: indexRectangle for select

* feat: indexLine for select

* refactor: SpatialIndex (uses getter functions now)

* feat: mark/layer loading part of SelectInterface

* feat: SelectInterface should probably work!

* refactor: renamed to SelectManager

* fix: broken imports

* feat: added select methods to Section

* feat: added onSelect and onDeselect to PointLayer

* feat: select working!

* feat: added onSelect and onDeselect to all marks and layers

* feat: select working for all marks!

* feat: brushing!

* fix: prevent default on mousedown (otherwise dragging and stuff will select things on page)

* feat: created new sandbox for selection polygon

* feat: polygon selection logic in SelectManager

* feat: updated Section API

* feat: Polygon select working!

* feat: polygon brush!

* refactor: removed old interaction logic

* refactor: removed old stuff for presentation

* _

* _

* fix: another 0 is falsy bug in RectangleLayer

* _

* feat: added zoom example

* feat: added cool 'trade-off' graphic

* feat: improved tradeoff example

* _

* fix: transition bug when changing scale and data at the same time

* feat: live demonstration improvements

* _

* _

* feat: select/brush example

* feat: cleaned up dashboard code

* feat: layer transition example

* feat: started on polar example

* feat: cool polar coordinate demo

* refactor: put demonstration examples in separate folder

* refactor: restored original sandbox root file

* refactor: put back original sandbox examples

* refactor: put back hexagon data

* fix: test snapshots

* chore: remove snapshots.js

* refactor: removed nextTick and used svelte's native tick

* fix: correct examples

* chore: deleted snapshots.js (again?)

* fix: bug in pointInPolygon

* fix: pointInPolygon excludes boundary now

* fix: switched mouseover and mouseout order
  • Loading branch information
luucvanderzee authored Oct 14, 2019
1 parent 9b0fa69 commit 4e9a204
Show file tree
Hide file tree
Showing 122 changed files with 16,061 additions and 1,656 deletions.
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@
"@babel/core": "^7.5.5",
"@babel/preset-env": "^7.5.5",
"@cypress/snapshot": "^2.1.3",
"@snlab/florence-datacontainer": "^0.1.3",
"@snlab/florence-datacontainer": "^0.1.4",
"babel-jest": "^24.9.0",
"cypress": "^3.4.1",
"d3-format": "^1.4.1",
"d3-scale-chromatic": "^1.5.0",
"eslint": "^6.2.2",
"eslint-config-standard": "^14.0.1",
Expand All @@ -31,6 +32,7 @@
"npm-run-all": "^4.1.5",
"rollup": "^1.19.4",
"rollup-plugin-commonjs": "^10.1.0",
"rollup-plugin-dsv": "^1.2.0",
"rollup-plugin-json": "^4.0.0",
"rollup-plugin-livereload": "^1.0.0",
"rollup-plugin-node-globals": "^1.4.0",
Expand Down
281 changes: 0 additions & 281 deletions src/classes/EventManager/index.js

This file was deleted.

78 changes: 0 additions & 78 deletions src/classes/InteractionManager/InteractionHandlers/ClickHandler.js

This file was deleted.

Loading

0 comments on commit 4e9a204

Please sign in to comment.