fix: 🐛 prevent layout shift from lazy loaded images
This commit is contained in:
parent
2c06226078
commit
6e954e4099
1 changed files with 4 additions and 8 deletions
|
@ -65,15 +65,10 @@
|
|||
position: relative;
|
||||
|
||||
grid-row: track;
|
||||
display: grid;
|
||||
place-content: center;
|
||||
|
||||
font-size: 1.25em;
|
||||
color: var(--clr-text);
|
||||
|
||||
width: 0;
|
||||
height: 0;
|
||||
|
||||
cursor: pointer;
|
||||
|
||||
background-color: var(--clr-box-background);
|
||||
|
@ -91,6 +86,7 @@
|
|||
&::after {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
align-content: center;
|
||||
}
|
||||
|
||||
&:disabled {
|
||||
|
@ -101,7 +97,7 @@
|
|||
|
||||
& .prev {
|
||||
grid-column: prev;
|
||||
margin-inline: 0.75em 0;
|
||||
left: 0.5em;
|
||||
|
||||
&::after {
|
||||
content: '«' / 'Previous';
|
||||
|
@ -110,7 +106,7 @@
|
|||
|
||||
& .next {
|
||||
grid-column: next;
|
||||
margin-inline: 0 0.75em;
|
||||
right: 0.5em;
|
||||
|
||||
&::after {
|
||||
content: '»' / 'Next';
|
||||
|
@ -142,7 +138,7 @@
|
|||
|
||||
& .ref-image img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
height: 35em;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue