import classnames from 'classnames'; import PropTypes from 'prop-types'; import React, { useState } from 'react'; import CheckBox from '../../ui/check-box'; import { useI18nContext } from '../../../hooks/useI18nContext'; import { usePermissionDescriptions } from '../../../hooks/usePermissionDescriptions'; const ConnectedAccountsPermissions = ({ permissions }) => { const t = useI18nContext(); const [expanded, setExpanded] = useState(false); const getPermissionDescription = usePermissionDescriptions(); const toggleExpanded = () => { setExpanded((_expanded) => !_expanded); }; if (!permissions.length) { return null; } return (
{t('permissions')}
{t('authorizedPermissions')}: