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 workaround to properly display overflowing child elements of panes #3

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

Conversation

rbtbar
Copy link

@rbtbar rbtbar commented Oct 6, 2014

The workaround preserves the initial 'auto' z-index of 'panes', so that
it is possible to keep many overflowing child elements of 'panes'
visible in front of all other 'panes' while the mouse is neither over
the 'pane' or its children;

Actually, this solution replaces handing of z-indexes via:
allowOverflow( elem_or_pane )
resetOverflow( elem_or_pane )
showOverflowOnHover
... in most of the standard use cases.

The workaround preserves the initial 'auto' z-index of 'panes', so that
it is possible to keep the overflowing child elements of the 'pane'
visible in front of all other 'panes' while the mouse is neither over
the 'pane' or its children;
@rbtbar
Copy link
Author

rbtbar commented Oct 10, 2014

The corresponding Gist file:

https://gist.github.com/rbtbar/bfe6ddbab441bee840a2

Copy link

@melloware melloware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you clean up this commit? It looks like you touched a lot of lines but made no actual changes to those lines. Did you run it through some code formatter or something?

@GedMarc
Copy link
Collaborator

GedMarc commented Nov 23, 2017

Looks like this is already in the jquery3 branch, do you need this specifically for jquery2?
(https://github.com/GedMarc/layout/blob/master/dist/layout-default.css)

@allpro
Copy link
Owner

allpro commented Nov 23, 2017

The new commit looks fine. The extra line edits are all just trailing whitespace trimming, plus trimming one odd but of gibberish! (abcdef)

@allpro
Copy link
Owner

allpro commented Nov 23, 2017

However the CSS commit from 2014 would BREAK many layouts. Layout dynamically adjusts element zIndexes when panes overlap ('slide'). Hard-coding a zIndex would prevent this.

The reason allowOverflow() and similar methods exist are so users can temporarily override the dynamic zIndexes in special scenarios. This cannot be a default though.

It is OK for a 'user' to hard-coded a zIndex on a pane that requires it, assuming no other pane will ever overlay it. A common example is a header that contains drop-down menus. Again, this cannot be a default.

Copy link
Owner

@allpro allpro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The commit with changes to layout-default.css should be reverted as it would break layout. This is explained in a comment I added.

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.

None yet

4 participants