Fix scrollbar in upgrade modal (#7076)

## Issue
5848 Remove scroll-bar in update prompt

## Changes
- Make scrollbars appear only when necessary.
- Style the scrollbar. Similar to other areas, we skip this for Mac (can't recall why we need to skip).
This commit is contained in:
infinite-persistence 2021-09-13 23:35:26 +08:00 committed by GitHub
parent 539cf780d7
commit d5e8f2d18c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 2 deletions

View file

@ -3,6 +3,8 @@ import React from 'react';
import { Modal } from 'modal/modal'; import { Modal } from 'modal/modal';
import LastReleaseChanges from 'component/lastReleaseChanges'; import LastReleaseChanges from 'component/lastReleaseChanges';
const IS_MAC = navigator.userAgent.indexOf('Mac OS X') !== -1;
type Props = { type Props = {
downloadUpgrade: () => void, downloadUpgrade: () => void,
skipUpgrade: () => void, skipUpgrade: () => void,
@ -14,6 +16,7 @@ class ModalUpgrade extends React.PureComponent<Props> {
return ( return (
<Modal <Modal
className={IS_MAC ? '' : 'main-wrapper--scrollbar'}
isOpen isOpen
contentLabel={__('Upgrade available')} contentLabel={__('Upgrade available')}
title={__('LBRY leveled up')} title={__('LBRY leveled up')}

View file

@ -485,7 +485,7 @@ textarea {
.release__notes { .release__notes {
max-height: 50vh; max-height: 50vh;
overflow: scroll; overflow: auto;
} }
.signup__odysee-logo { .signup__odysee-logo {

View file

@ -488,7 +488,7 @@ textarea {
.release__notes { .release__notes {
max-height: 50vh; max-height: 50vh;
overflow: scroll; overflow: auto;
} }
.signup__odysee-logo { .signup__odysee-logo {