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

.ng2-pdf-viewer-container not in parent container #811

Closed
Gabriel2409 opened this issue Jul 30, 2021 · 5 comments
Closed

.ng2-pdf-viewer-container not in parent container #811

Gabriel2409 opened this issue Jul 30, 2021 · 5 comments
Milestone

Comments

@Gabriel2409
Copy link

Bug Report or Feature Request (mark with an x)
- [X] Regression (a behavior that used to work and stopped working in a new release)
- [ ] Bug report -> please search issues before submitting
- [ ] Feature request
- [ ] Documentation issue or request

File : pdf-viewer.component.scss

In the latest version, the .ng2-pdf-viewer-container is set with position:absolute and width:100%
This leads to multiple styling problems, especially in pages where the pdf viewer is supposed to be contained in a container.

In previous versions, the position was set to relative and there was no problems.

@nischi
Copy link

nischi commented Aug 4, 2021

Workaround could be to set the container to position:relative. Took me also i while to figure out.

@almothafar
Copy link

I think it is a duplicate of #805 (workaround provided)
Here is the change to blame: 8d4f8ad#diff-c0a5f3426a537629a18cbeb63abc55b7ce727f267c2e85acf84c88ddd96e4cb1R3

@axell9641
Copy link

Workaround could be to set the container to position:relative. Took me also i while to figure out.

I can't thank you enough. I was going insane. The example in the demo worked fine and mine just didn't.

@stale
Copy link

stale bot commented Nov 8, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Nov 8, 2021
Akxe added a commit to Akxe/ng2-pdf-viewer that referenced this issue Nov 11, 2021
Giving the host `display: block` makes him immediately visible. `position: relative` is there to prevent VadimDez#811.
@VadimDez VadimDez added this to the 7.0.2 milestone Nov 15, 2021
@stale stale bot removed the stale label Nov 15, 2021
@VadimDez
Copy link
Owner

Checkout 7.0.2 release, should be better now, I've also included breaking change note.

gigadev0915 pushed a commit to gigadev0915/angular-pdf-viewer that referenced this issue Jul 12, 2023
Giving the host `display: block` makes him immediately visible. `position: relative` is there to prevent VadimDez/ng2-pdf-viewer#811.
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

No branches or pull requests

5 participants