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

Independent Pivot #8

Closed
dhemmlerf opened this issue Jan 19, 2019 · 1 comment
Closed

Independent Pivot #8

dhemmlerf opened this issue Jan 19, 2019 · 1 comment
Labels
as designed Working intentionally, as designed with no immediate plans for change

Comments

@dhemmlerf
Copy link

dhemmlerf commented Jan 19, 2019

Hello.

The rotation pivot from the custom tool is not element independent, I mean if you change its position in one element, this is reflected in the other elements under de dom container. That behavior is present here:

http://senocular.github.io/TransformTool/examples/TransformDOMPictures.html

Is this a default feature or just a bug? Thanks.

@senocular
Copy link
Owner

I would say it's neither. For the position to change for individual elements, there would be some sort of persistence needed to maintain the state of the pivot for each element. The tool does not make any attempt to try and modify the element (potentially your elements) in some way that might be unexpected so it just keeps one pivot location stored and uses that for all elements.

With ES6, a weak map would be suitable for storing element locations without directly affecting the element itself in any noticeable way and could be used to implement this kind of persistence. This code was written before those features were available, though.

@senocular senocular added the as designed Working intentionally, as designed with no immediate plans for change label Jan 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
as designed Working intentionally, as designed with no immediate plans for change
Projects
None yet
Development

No branches or pull requests

2 participants