import { PercentFormat } from '@graphcommerce/next-ui' import type { BoxProps } from '@mui/material' import { Box } from '@mui/material' import type { ProductListItemFragment } from '../../graphql' export type ProductDiscountLabelProps = Pick & Omit export function ProductDiscountLabel(props: ProductDiscountLabelProps) { const { price_range, ...boxProps } = props const discount = Math.floor(price_range.minimum_price.discount?.percent_off ?? 0) return ( <> {discount > 0 && ( )} ) }