Skip to content

Add scroll direction to extension settings #85

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

Conversation

ColinEge
Copy link
Contributor

This PR adds the new Scroll Direction variable to the extension settings as requested by issue 83 this was a simple and quick implementation so any changes are welcomed. My main goal was to quickly improve the UX for myself and others that find "up-out" scrolling unusual and prefer not to hold Ctrl.

Changes Made:

Add property to extension settings: Added dbmlERDPreviewer.scrollDirection with values 'up-out' and 'up-in' to extension settings, leaving up-out as default to preserve UX for current users.
Create ScrollDirectionProvider: A new provider to give context to components. This could later be refactored to something like NavigationProvider to provide other navigation related extension settings.
DiagramWrapper.tsx consumes the new context: Scroll direction is added as a const prop which flips the direction of scroll in handleZooming().
Types adjustments: To support these changes, the ScrollDirection type was created and ConfigKeys type was updated.

Impact:

No Regression: The changes do not affect current functionality.
Improved UX: Improves navigation for users not used to "up-out" scrolling.

Testing:

The changes have been tested to ensure no change in default behaviour and successful scroll switching. Further testing is welcome.

Conclusion:

This PR should make UX better for at least myself and issue 83. I appreciate your consideration and look forward to your feedback.

Thank you muchly,

ColinEge

Scroll direction is set in extension settings and added to visualizer via new provider
Copy link
Owner

@BOCOVO BOCOVO left a comment

Choose a reason for hiding this comment

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

Thank you for the contribution.

@BOCOVO BOCOVO merged commit d5d966b into BOCOVO:main Jun 8, 2025
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.

2 participants