Skip to content

Added check to see if the element has fixed position and use fixed po… #146

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sras
Copy link

@sras sras commented Dec 5, 2015

When the editable element is inside a element which is fixed, the menu appears either at the top or at a point above where it should ideally appear. This apparently is due to the fact that the cursor position calculation code returns a position relative to the top of the window (the target being fixed positioned), but when that position is applied to the absolutely positioned menu item, it ends up being positioned by that amount from the top of the page (as opposed to the window top), which results in the error.

It was fixed by seeing if the target element is fixed or inside a fixed parent, and if so, giving fixed position to the menu drop down.

@philippzentner
Copy link

+1

@seanconnollydev
Copy link

I added a similar fix via PR #177 (I didn't see this before submitting). I've seen a few PRs attempting to solved the fixed element problem. @jeff-collins: thoughts on getting this into master soon?

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

Successfully merging this pull request may close these issues.

3 participants