Skip to content

Commit

Permalink
fix(calculator): max height for mobile landscape
Browse files Browse the repository at this point in the history
  • Loading branch information
42tte committed Oct 17, 2023
1 parent 0a4e565 commit f740b7a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/advanced-calculator/calculator.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ input[type='number'] {
grid-row: span 1;
padding: 1.5rem;
}

.calculator-content {
display: grid;
grid-gap: 1rem;
Expand Down Expand Up @@ -175,6 +176,11 @@ input[type='number'] {
grid-row: 2 / 4;
}

.calculator-content-wrapper {
max-height: 70vh;
overflow: auto;
}

.calculator-content {
display: unset;
}
Expand Down
2 changes: 2 additions & 0 deletions src/advanced-calculator/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ export default function Calculator(props: SalaryCalculatorProps) {
: style['calculator-controls--mobileHidden'],
)}
>
<div className={style['calculator-content-wrapper']}>
{mobileVisible && (
<motion.div
id="controls-content"
Expand Down Expand Up @@ -267,6 +268,7 @@ export default function Calculator(props: SalaryCalculatorProps) {
{mobileVisible ? 'Skjul' : 'Endre'}
</Button>
</div>
</div>
</div>
</AnimatePresence>

Expand Down

0 comments on commit f740b7a

Please sign in to comment.