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

Expose getAbsoluteRect private function #1724

Closed
jacekbogdanski opened this issue Feb 28, 2018 · 2 comments
Closed

Expose getAbsoluteRect private function #1724

jacekbogdanski opened this issue Feb 28, 2018 · 2 comments
Labels
changelog:api A changelog entry should be put in the API section of the changelog. good first issue Relatively easy to fix. This is a perfect issue if you are willing to create a Pull Request. status:confirmed An issue confirmed by the development team. target:major Any docs related issue that should be merged into a major branch. type:feature A feature request.
Milestone

Comments

@jacekbogdanski
Copy link
Member

Are you reporting a feature request or a bug?

Feature request

Expected result

CKEDITOR.tools.dom.getElementRect function returns the position of the element on the screen.

Actual result

_getAbsoluteRect function is hidden inside balloonpanel plugin.

Other details

I need to use this function in other place so I think it's good idea to expose it as a public API. This function takes editor and element instances as arguments to calculate element position. It doesn't fit well in core/element nor core/editor so after some debate with @f1ames we think tools are best place to expose it.

@jacekbogdanski jacekbogdanski added type:feature A feature request. status:confirmed An issue confirmed by the development team. labels Feb 28, 2018
@mlewand
Copy link
Contributor

mlewand commented Feb 28, 2018

It actually should be a method in element type. While doing that make sure that the method gets a better description, clearly explaining it's purpose and how is it different from https://docs.ckeditor.com/ckeditor4/latest/api/CKEDITOR_dom_element.html#method-getClientRect and https://docs.ckeditor.com/ckeditor4/latest/api/CKEDITOR_dom_element.html#method-getDocumentPosition

@mlewand mlewand added good first issue Relatively easy to fix. This is a perfect issue if you are willing to create a Pull Request. target:major Any docs related issue that should be merged into a major branch. changelog:api A changelog entry should be put in the API section of the changelog. labels Feb 28, 2018
@Comandeer Comandeer added this to the 4.10.0 milestone Apr 10, 2018
@Comandeer
Copy link
Member

Closed in #1727.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:api A changelog entry should be put in the API section of the changelog. good first issue Relatively easy to fix. This is a perfect issue if you are willing to create a Pull Request. status:confirmed An issue confirmed by the development team. target:major Any docs related issue that should be merged into a major branch. type:feature A feature request.
Projects
None yet
Development

No branches or pull requests

3 participants