import React from 'react'; import { Button, Popover } from 'antd' import MetaItem from '../MetaItem'; import { Icon } from 'UI' import { useTranslation } from 'react-i18next'; interface Props { list: any[]; maxLength: number; } export default function MetaMoreButton(props: Props) { const { list, maxLength } = props; const { t } = useTranslation(); return ( (
{list.length - maxLength}{' '} {t(`More ${list.length - maxLength === 1 ? "attribute" : "attributes"}`)} {list.slice(maxLength).map(({ label, value }, index) => ( ))}
)} placement="bottom" >
); }