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

position: absolute and top: 0px has no effect #2214

Closed
maluramichael opened this issue Jul 31, 2024 · 3 comments
Closed

position: absolute and top: 0px has no effect #2214

maluramichael opened this issue Jul 31, 2024 · 3 comments

Comments

@maluramichael
Copy link

This is our html preview
image
And this is the generated pdf
image

This would be the related html code

<td class="material-icon text-block-icon-level-0 position-relative">
    <img class="position-absolute" width="18" height="18" src="xxx/chevron_right.svg" alt="">
    <div class="level-placeholder">
    </div>
</td>

And here the css

.text-block-element-list .text-blocks .text-block .position-relative {
    position: relative;
}

.text-block-element-list .text-blocks .text-block .material-icon .position-absolute {
    position: absolute;
    top: 0;
}

We are using the same css without media queries i guess. Is it possible that position absolute has to be treated differently and is not working or am i doing something wrong?

@liZe
Copy link
Member

liZe commented Jul 31, 2024

Here’s an example I tried:

<table>
  <td style="position: relative; background: pink">
    <img src="chevron-right-svgrepo-com.svg" style="position: absolute; top: 0; width: 20px">
    <div style="padding-left: 25px">
      abc<br>
      abc<br>
      abc<br>
      abc<br>
      abc<br>
      abc<br>
    </div>
  </td>
</table>

It gives the correct rendering.

Could you please provide a full example that shows your problem?

@liZe
Copy link
Member

liZe commented Aug 7, 2024

Can we do anything to help you?

@maluramichael
Copy link
Author

I think we can close this for now. I worked around it and now it looks fine.

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

2 participants