Skip to content

[Feature] Allow separate configuration of mouse wheel and gesture events (zoom, move) #20220

Description

@mephinet

What problem does this feature solve?

Use case:

An echarts map is shown as part of a long news article. In such a scenario we want to:

  • disable zoomOnMouseWheel, so that a user using the mouse wheel can scroll through the page quickly
  • disable moveOnMouseMove, so that a user using gestures can scroll through the page quickly
  • enable zoom on pinch, so that users using gestures can zoom into the map

Currently, this is not possible to achive, because controlType does not allow to separete mouse wheel and pinch events.

The 3rd argument of RoamController.enable would allow specifying the desired behavior.
However, when called by MapDraw._updateController, there is no way to specify this 3rd argument, so the defaults are always used. It is furthermore not possible to change (e.g. monkey-patch) these default options.

What does the proposed API look like?

Extend MapDraw._updateController, GraphView.prototype._updateController, TreeView.prototype._updateController and TreemapView.prototype._resetController to pass e.g. "roamOptions" from the model to the 3rd argument of RoamController.enable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enThis issue is in Englishnew-featurependingWe are not sure about whether this is a bug/new feature.staleInactive for a long time. Will be closed in 7 days.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions