Open 5e-Cleric opened 4 weeks ago
Using zoom
instead of scale
sacrifices animatability for fixing overflow issues, which are inavoidable via CSS only with scale:
Based on docs about Overflow related to transform (https://drafts.csswg.org/css-overflow-3/)
The scrollable overflow area is the union of:
- The scroll container’s own padding box.
- All line boxes directly contained by the scroll container.
- The border boxes of all boxes for which it is the containing block and whose border boxes are positioned not wholly in the negative scrollable overflow region, accounting for transforms by projecting each box onto the plane of the element that establishes its 3D rendering context. [CSS3-TRANSFORMS]
From which i gather that the scroll container's scrollable overflow area is calculated based on the original size of the child element. This means that even though the scaled-down child element might visually occupy less space, the scrollable overflow area is determined by the original size of the element.
Zoom does change the natural size, affecting the layout, which gets rid of most problems inside the scrollable parent: (from https://drafts.csswg.org/css-viewport/#zoom-property)
To apply zoom, the used value of a CSS property is pre-multiplied (before any other steps in the used value stage) by the used value of zoom for the element. It also multiplies the natural size of all replaced elements, background images, and nested frames
@calculuschild can i get a deployment?
Deployment up.
Converted to draft until i figure out the page works.
Hmm as the scroll function scrolls to the top of the page, and the function getting the page gets if the footer is visible, page logic is flawed at the moment.
AS per right now, only adds a zoom feature.
Creates toolbar in a separate file: toolbar.jsx
Zoom is set in toolbar, then passed to brewRenderer, and then set there in a style tag.
Two problems right now: