Skip to content
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

Draft Pull Request - Web Map Core Issue #48: Expose an Option of the Map: Zoom in/out button #76

Closed
wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Feb 6, 2022

Description of Issue and Fix
This pull request was created to assist in the following issue on the web map core section. Issue #48 Expose an Option of the Map: Zoom in/out button. #48.
It offers a possible solution on what can be done to improve the situation. The zoom in/out button for the treetracker web map is situated at the bottom right corner, the zoom feature needs to be exposed as an option of the map. The reason for this issue is that for the zoom feature, the element will fade out when being used by users.

Code
This code can be configured to the web map repository so that it may allow the zoom feature to be exposed. There are two different calls used which are the expose and mask feature. The expose method takes all elements (returned by selector) and any jQuery selectors and are placed on top of the mask. The mask is loaded right after the expose/mask call. Furthermore, an existing element can be used as a mask. This code snippet was taken from the following website: https://jquerytools.github.io/documentation/toolbox/expose.html.

// place a white mask over page
$(document).mask();

// places the custom colored mask over page
$(document).mask("#789");

// place non-closable mask (on zoom element)
$(document).mask{ closeOnEsc: false, closeOnClick: false });

// places the mask but let selected zoom element show through (be exposed)
$("div.to_be_exposed").expose();

// closes the mask
$.mask.close();

@ghost ghost marked this pull request as ready for review February 6, 2022 15:10
@dadiorchen
Copy link
Collaborator

@GowS31 is your solution relying on jQuery? But we don't use jQuery in this project.

This pull request was closed.
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.

1 participant