View Single Post
Old 06-28-2025, 06:52 PM   #68
Falkor
Connoisseur
Falkor began at the beginning.
 
Posts: 90
Karma: 10
Join Date: Dec 2024
Device: Tolino Shine 5
Quote:
Originally Posted by RbnJrg View Post
Do the try and write:

Code:
@supports(display: flex) {
   p {
      background: yellow;
   }
}
ADE 4.x supports "display: flex" so if @supports is honored, then paragraphs should have a yellow background color. Once you check the property is supported, erase the code to do the try.



Do the try for example by setting a width of an element of "width: calc(100% - 10em);" and watch if the element's width was reduced.
Done that. Works fine.
Code:
@supports (display: flex) {
  hr {width: calc(100% - 14em)}
  }
Quote:
Originally Posted by RbnJrg View Post
If you don't set "float" then you will have fragmentation in your epub. But you didn't say if you tested it or not in Thorium and Calibre. You said that my sample didn't work there and in the screenshoot I posted you can see that the epub looks fine those ereaders. My code is not for ADE 4.x; as I said in my previous post, ADE needs additional statements in order the things work there.
I found the error in my epub that caused the issues with Thorium and Calibre and I wrote about it in #47.

For ADE and Books I just found a way to make your epub work with float: Don't set the margin to 0. It needs to be bigger (or not set at all). The left and right margins should be set to auto to keep things centered. Works fine in ADE, Books, Thorium and Calibre viewer
Falkor is offline   Reply With Quote