Skip to content

Commit

Permalink
fix(site): remove iframe padding on iOS aduros#85
Browse files Browse the repository at this point in the history
  • Loading branch information
FaberVitale committed Dec 19, 2021
1 parent b7a7e81 commit 5b4d4a3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion site/src/components/AspectRatio.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export function AspectRatio({
return (
<div {...otherProps} className={clsx(className, styles.ratio)}>
<svg className={styles.innerSvg} viewBox={`0 0 ${width} ${height}`}></svg>
{children}
<div className={styles.content}>{children}</div>
</div>
);
}
11 changes: 11 additions & 0 deletions site/src/components/AspectRatio.module.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.ratio {
display: grid;
padding: 0;
position: relative;
}

.ratio > * {
Expand All @@ -10,3 +11,13 @@
.innerSvg {
visibility: hidden;
}

.content {
position: absolute;
width: 100%;
height: 100%;
overflow: hidden;
left: 0;
padding: 0;
right: 0;
}
1 change: 1 addition & 0 deletions site/src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,5 @@ html[data-theme='dark'] .header-github-link:before {
.game-embed {
width: 100%;
height: 100%;
padding: 0;
}

0 comments on commit 5b4d4a3

Please sign in to comment.