increase dropdown box max-height (#19)

This commit is contained in:
saml33 2021-05-27 23:44:25 +10:00 committed by GitHub
parent 7558165c27
commit 407bdd8c0d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 2 deletions

View File

@ -36,7 +36,7 @@ const Select = ({
{open ? ( {open ? (
<Listbox.Options <Listbox.Options
static static
className={`text-th-fgd-1 max-h-40 overflow-auto z-20 w-full p-1 absolute left-0 mt-1 bg-th-bkg-1 origin-top-left divide-y divide-th-bkg-3 shadow-lg outline-none rounded-md thin-scroll`} className={`text-th-fgd-1 max-h-56 overflow-auto z-20 w-full p-1 absolute left-0 mt-1 bg-th-bkg-1 origin-top-left divide-y divide-th-bkg-3 shadow-lg outline-none rounded-md thin-scroll`}
> >
{children} {children}
</Listbox.Options> </Listbox.Options>

View File

@ -5,12 +5,14 @@ import 'tippy.js/animations/scale.css'
type TooltipProps = { type TooltipProps = {
content: ReactNode content: ReactNode
className?: string className?: string
placement?: any
} }
const Tooltip: FunctionComponent<TooltipProps> = ({ const Tooltip: FunctionComponent<TooltipProps> = ({
children, children,
content, content,
className, className,
placement,
}) => { }) => {
return ( return (
<Tippy <Tippy
@ -25,6 +27,7 @@ const Tooltip: FunctionComponent<TooltipProps> = ({
{content} {content}
</div> </div>
} }
placement={placement}
> >
<div className="outline-none focus:outline-none">{children}</div> <div className="outline-none focus:outline-none">{children}</div>
</Tippy> </Tippy>

View File

@ -434,7 +434,11 @@ const WithdrawModal = ({ isOpen, onClose }) => {
suffix={withdrawTokenSymbol} suffix={withdrawTokenSymbol}
/> />
{simulation ? ( {simulation ? (
<Tooltip content="Account Leverage" className="py-1"> <Tooltip
content="Projected Leverage"
className="py-1"
placement="bottom"
>
<span <span
className={`${getAccountStatusColor( className={`${getAccountStatusColor(
simulation.collateralRatio simulation.collateralRatio