Skip to content

Set lower default wheel zoom sensitivity for haplotype networks#934

Merged
jonbrenas merged 3 commits intomalariagen:masterfrom
blankirigaya:fix#504
Mar 8, 2026
Merged

Set lower default wheel zoom sensitivity for haplotype networks#934
jonbrenas merged 3 commits intomalariagen:masterfrom
blankirigaya:fix#504

Conversation

@blankirigaya
Copy link
Contributor

Closes #504

Exposes wheel_sensitivity as a parameter on plot_haplotype_network(), defaulting to 0.1 (vs cytoscape.js's default of 1). This prevents accidentally zooming out when scrolling over a haplotype network, while still allowing users to tune the sensitivity to their preference.
Made possible by the wheelSensitivity prop added in dash-cytoscape v1.0.0 (plotly/dash-cytoscape#203), which is already our minimum required version.

Changes:

Add wheel_sensitivity: float = 0.1 parameter to plot_haplotype_network()

@blankirigaya
Copy link
Contributor Author

@jonbrenas Sir, the issue mentioned lower the sensitivity without a specify value so i adjusted it to a value usually used for large graphs to avoid confusion. let me know if the value need adjusting/fine tuning

Copy link
Collaborator

@jonbrenas jonbrenas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jonbrenas jonbrenas merged commit ad1c1d9 into malariagen:master Mar 8, 2026
8 checks passed
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.

Dash set lower wheel zoom sensitivity

2 participants