Browse Source
fix: scroll locking bug
Signed-off-by: Muthu Kumar <muthukumar@thefeathers.in>
pull/2/head
Failed to extract signature
2 changed files with
10 additions and
17 deletions
-
src/components/Container.tsx
-
src/index.css
|
|
@ -82,11 +82,6 @@ const Container: React.FC<{ |
|
|
|
child.style.removeProperty("transform"); |
|
|
|
}, 100 * idx); |
|
|
|
}); |
|
|
|
|
|
|
|
timer(() => { |
|
|
|
document.body.style.maxHeight = "auto"; |
|
|
|
document.body.style.overflow = "auto"; |
|
|
|
}, containerChildren.length * 100); |
|
|
|
} |
|
|
|
|
|
|
|
// cleanup
|
|
|
@ -118,8 +113,7 @@ const Container: React.FC<{ |
|
|
|
child.style.opacity = "0"; |
|
|
|
}); |
|
|
|
} |
|
|
|
document.body.style.maxHeight = "100vh"; |
|
|
|
document.body.style.overflow = "hidden"; |
|
|
|
|
|
|
|
try { |
|
|
|
const target = e.currentTarget! as HTMLButtonElement; |
|
|
|
target.style.width = "0"; |
|
|
@ -167,11 +161,12 @@ const Container: React.FC<{ |
|
|
|
padding-block-start: 15rem; |
|
|
|
padding-block-end: 8rem; |
|
|
|
padding-inline: calc(100vw / 8); |
|
|
|
overflow-x: hidden; |
|
|
|
overflow: hidden; |
|
|
|
min-height: 100vh; |
|
|
|
position: relative; |
|
|
|
`}>
|
|
|
|
<div |
|
|
|
aria-hidden |
|
|
|
className={cx( |
|
|
|
"fog", |
|
|
|
css` |
|
|
|
|
|
@ -6,6 +6,9 @@ |
|
|
|
--primary-colour: rgb(255, 85, 85); |
|
|
|
--text-colour: rgb(211, 207, 201); |
|
|
|
--text-subdued: rgb(150, 150, 150); |
|
|
|
--card-active: rgb(45, 45, 45); |
|
|
|
--card-active-border: rgb(60, 60, 60); |
|
|
|
--card-hover: rgb(15, 15, 15); |
|
|
|
font-weight: 500; |
|
|
|
font-size: max(16px, 0.8vw); |
|
|
|
} |
|
|
@ -13,19 +16,15 @@ |
|
|
|
* { |
|
|
|
box-sizing: border-box; |
|
|
|
scroll-behavior: smooth; |
|
|
|
} |
|
|
|
|
|
|
|
body { |
|
|
|
margin: 0; |
|
|
|
font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", |
|
|
|
"Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", |
|
|
|
sans-serif; |
|
|
|
color: var(--text-colour); |
|
|
|
height: 100vh; |
|
|
|
} |
|
|
|
|
|
|
|
#root { |
|
|
|
height: 100%; |
|
|
|
body { |
|
|
|
margin: 0; |
|
|
|
color: var(--text-colour); |
|
|
|
overflow-x: hidden; |
|
|
|
} |
|
|
|
|
|
|
|
code { |
|
|
@ -77,7 +76,6 @@ h4 { |
|
|
|
a { |
|
|
|
color: var(--text-colour); |
|
|
|
text-decoration: none; |
|
|
|
font-family: Inter; |
|
|
|
font-weight: 800; |
|
|
|
transition: all 200ms; |
|
|
|
} |
|
|
|