Fix sizing and header alignment
This commit is contained in:
parent
11ab27d5f4
commit
f1add7a639
1 changed files with 23 additions and 53 deletions
|
|
@ -71,13 +71,6 @@ const createFrameFigure = (thumbnail: HTMLAnchorElement): HTMLElement => {
|
|||
image.removeAttribute('loading');
|
||||
image.decoding = 'async';
|
||||
|
||||
// Reserve the photo's final size before it loads (see --frame-ratio in CSS).
|
||||
const ratio =
|
||||
Number(image.getAttribute('width')) / Number(image.getAttribute('height'));
|
||||
if (Number.isFinite(ratio) && ratio > 0) {
|
||||
figure.style.setProperty('--frame-ratio', String(ratio));
|
||||
}
|
||||
|
||||
figure.append(picture);
|
||||
|
||||
return figure;
|
||||
|
|
|
|||
Loading…
Reference in a new issue