antvis/G2

Can't import gesture,因此无法实现pinch zoom #6397

mxye posted onGitHub

问题描述

根据g2的documentation: https://g2-v4.antv.vision/en/docs/api/advanced/gesture/ 使用手势应该先 import Gestrue from '@antv/g2/lib/chart/controller/gesture'; 但是此地并无Gestrue这个项目。修正gesture的typo后,仍然没有此项目。打开node_modules去寻找,仍无此项目。在github的g2 repo中检索,仍无此项目。

所以,如果想要实现pinch zoom,该怎么办?

重现链接

https://github.com/search?q=repo%3Aantvis%2FG2%20gesture&type=code

重现步骤

点击重现链接,即可发现codebase中并无gesture一词,也就无从import

预期行为

预期documentation会符合package实际的功能

平台

macOS Chrome

屏幕截图或视频(可选)

No response

补充说明(可选)

No response


不建议使用这个功能,而是在外置使用手势库,结合 G2 暴露出来的鼠标事件去模拟。

posted by hustcc 8 months ago

Fund this Issue

$0.00
Funded

Pull requests