-
-
Notifications
You must be signed in to change notification settings - Fork 657
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
SeparatorWidget drag-to-resize not working in mobile/responsive view in Chrome nor Firefox [Bug] #490
Comments
For anyone who is facing a similar issue with touch events and wondering how to resolve it, I've made some progress and was able to edit the dist/klinecharts.js file as needed for touch events. Just a few moments ago, I was able to get the yAxis scaling working by copying the WidgetNameConstants.YAXIS case blocks from ChartEvent.prototype.mouseDownEvent and ChartEvent.prototype.pressedMouseMoveEvent Be sure to replace the "event" variable names in your blocks though. For example, And ChartEvent.prototype.touchMoveEvent uses: Also, make sure to add any variables, that exist in the mouse event's blocks, to your touch event's block. For example, var _b exists didn't exist in ChartEvent.prototype.touchStartEvent, but did exist in ChartEvent.prototype.mouseDownEvent. So just make sure to add it in or make a new one for your touch event block Here's what I did for the touch events for yAxis scaling. Please don't mind the mess/console logs... legit just got it working and haven't cleaned up:
|
Hey! How were you able to edit the js file inside the dist folder? |
Version
Latest version of v9
Steps to Reproduce
Everything is set up as shown in the examples and everything works fine (drag to resize panes, etc) in browser, but after I open dev tools to view mobile/responsive views in Chrome and Firefox the SeparatorWidget comes up as null and I'm unable to resize any of the panes.
As of now, while troubleshooting I noticed that the block in the dist build file that starts with "ChartEvent.prototype._findWidgetByEvent = function (event) {", at the condition of "if (pane !== null) {", console log returns true for a brief moment, but when I continue to hold the mouse down it quickly flips back to null. Not sure what the relevancy of that is, but this is something that is important for my project and I'm in the process of trying to hack this thing apart to get it working.
Any help resolving this issue would be greatly appreciated. Thank you
Current Behavior
Unable to resize panes in mobile/responsive view in Chrome and Firefox
Expected Behavior
Heights of panes adjusting upon dragging the separator widget, in both normal desktop browser view and in mobile browser view.
Environment
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: