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

Attach to Body, or as high in the DOM as possible #111

Closed
pavilionweb opened this issue Dec 13, 2017 · 15 comments
Closed

Attach to Body, or as high in the DOM as possible #111

pavilionweb opened this issue Dec 13, 2017 · 15 comments

Comments

@pavilionweb
Copy link

I'm submitting a...


[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  
[X] Feature request
[ ] Documentation issue or request
[ ] Support request

Current behavior

The overlay gets added inside the gallery component, but there's some other components that are rendered on top of the overlay, in particular flex based components

Expected behavior

The overlay should be the first element in the HTML if possible, so no need to fiddle with z-indexes or anything.

Minimal reproduction of the problem with instructions

What is the motivation / use case for changing the behavior?

Environment


- Node version: XX  
- npm version: XX  
- Platform:  
- Angular version: X.Y.Z
-


Browser:
- [ ] Chrome (desktop) version XX
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX

Others:

@Ks89
Copy link
Owner

Ks89 commented Dec 13, 2017

I never though about this, but It could be a good idea.
What are you trying to say is that I should attach the css class with semi-transparent background directly to the body tag of the document instead of a div?

@wenzirang
Copy link

I have this problem, too

@Ks89
Copy link
Owner

Ks89 commented Dec 28, 2017

Please could you explain me why is this a problem? Could you give me a scenario (if you want also on jsbin or plnkr.co)?

I tried to work on this, but changing the current behaviour I created lot of issues.

I need a solution that shows a background over everything (also over things with really high zindex, as navbar in bootstrap 4).

@dannybucks
Copy link

I have the same problem. It e.g. occurs when I place the gallery inside a css grid (display: grid).

@domiSchenk
Copy link

This could solve the problem with issue #95.
If its appended to body all the grid:css and modals do not block the gallery.

@Ks89
Copy link
Owner

Ks89 commented Jul 25, 2018

I'll investigate again in August, because I'm completely full until the beginning of August.
PS: if you have a resource or other stuff to do this, please share it.

@Ks89 Ks89 added this to the 7.0.0 milestone Jul 25, 2018
@domiSchenk
Copy link

Other libraries are using @angular/cdk/overlay to archive this.

@Ks89
Copy link
Owner

Ks89 commented Jul 25, 2018

Interesting, I'll investigate a bit next week. thank you.

@luisCortes
Copy link

Hello, do you have any update on this, I'm having the same problem, the preview of an image is shown inside a component and not over the whole screen viewport.

image

@luisCortes
Copy link

Another issue is that I can still use the scroll behind the overlay, here's an image of that:

image

@Ks89
Copy link
Owner

Ks89 commented Aug 15, 2018

sorry, no news at the moment

@Ks89
Copy link
Owner

Ks89 commented Aug 15, 2018

@domiSchenk can you share the name of some of those libraries to see how they are using cdk? Thank u.

@luisCortes
Copy link

Thank you @Ks89

@Ks89
Copy link
Owner

Ks89 commented Sep 1, 2018

I'll fix this issue in version 8.0.0 together with #137 this winter, because I have to rewrite a core part of the library.
I made some experiments and I think to fix this issue completely in 8.0.0.
Thank you for the patience.

@Ks89
Copy link
Owner

Ks89 commented Apr 11, 2020

Fully implemented (branch 800) and scheduled for 8.0.0-beta.1 that is coming soon.

I close this issue because already done and It will be available in a beta release in some days.

@Ks89 Ks89 closed this as completed Apr 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants