UNPKG

@lifi/widget

Version:

LI.FI Widget for cross-chain bridging and swapping. It will drive your multi-chain strategy and attract new users from everywhere.

9 lines (8 loc) 426 B
import { useMediaQuery } from '@mui/material'; import { useWidgetConfig } from '../providers'; const defaultExpandableWidth = 852; export const useExpandableVariant = () => { const { variant, useRecommendedRoute } = useWidgetConfig(); const expandableAllowed = useMediaQuery((theme) => theme.breakpoints.up(defaultExpandableWidth)); return variant === 'expandable' && expandableAllowed && !useRecommendedRoute; };