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

Option to disable pan/zoom functionality #55

Open
CW12 opened this issue Sep 10, 2016 · 1 comment
Open

Option to disable pan/zoom functionality #55

CW12 opened this issue Sep 10, 2016 · 1 comment

Comments

@CW12
Copy link

CW12 commented Sep 10, 2016

Is there an easy way to disable the pan/zoom functionality? (i.e. I want an "edit mode" button that toggles editMode between true and false, and only want the pan/zoom functionality enabled when editMode is true.

(awesome directive btw!)

@mvindahl
Copy link
Owner

Hi CW12, apologies for delayed reply. I don't think it's possible at the moment as configuration is only taken into account during initialization. However, one might argue that it would be very much in the spirit of AngularJS if the configuration were a shared object which could be modified by client code at any time and watched by the directive to make changes reflect. It wouldn't make sense for all properties but it would definitely make sense for an enablement type property.

I don't think I will find the time to implement it but I'll happily approve a PR if you decide to give it a shot. Don't feel obliged to create a general solution; as long as it solves your specific problem and doesn't wreak havoc on existing functionality it'll be a definite improvement.

If you don't have the time either, don't feel any pressure. Either way, thanks for the nice words.

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

2 participants