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

Don't zoom to uselessly small elements in zoom.js plugin [on demand] #1326

Open
dainiak opened this issue Aug 14, 2015 · 0 comments
Open

Don't zoom to uselessly small elements in zoom.js plugin [on demand] #1326

dainiak opened this issue Aug 14, 2015 · 0 comments

Comments

@dainiak
Copy link

dainiak commented Aug 14, 2015

Often it's reasonable to zoom not to the innermost HTML node that is clicked but to some other (ancestor) node. This turns especially useful while working with MathJax or highlihgting plugins: they create many helper HTML elements, and usually clicking on them in reveal.js presentation is useless. I propose adding a CSS class zoomable, so that when an element is clicked, if it's contained in some "zoomable" element, the closest of them in the DOM hierarchy is being zoomed instead of initial mouseclick event target. If the're no such elements on the current slide, fall back to traditional behaviour. This can be achieved by altering a small code block in zoom.js plugin.

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

No branches or pull requests

1 participant