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

Add selection.isCollapsed method #800

Closed
Comandeer opened this issue Aug 18, 2017 · 0 comments
Closed

Add selection.isCollapsed method #800

Comandeer opened this issue Aug 18, 2017 · 0 comments
Assignees
Labels
status:confirmed An issue confirmed by the development team. type:task Any other issue (refactoring, typo fix, etc).
Milestone

Comments

@Comandeer
Copy link
Member

Are you reporting a feature request or a bug?

Task

At the moment if there is need to check if current selection is collapsed, the first range must be fetched just to check its collapsed property:

editor.getSelection().getRanges()[ 0 ].collapsed

It'd be nice if we provide selection.isCollapsed method, which will wrap this logic.

@Comandeer Comandeer added status:confirmed An issue confirmed by the development team. type:task Any other issue (refactoring, typo fix, etc). labels Aug 18, 2017
@Comandeer Comandeer self-assigned this Aug 22, 2017
@mlewand mlewand added this to the 4.7.3 milestone Aug 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:confirmed An issue confirmed by the development team. type:task Any other issue (refactoring, typo fix, etc).
Projects
None yet
Development

No branches or pull requests

2 participants