import GroupSettingsButton from '@/features/subscription/components/dashboard/group-settings-button' import getMeta from '@/utils/meta' import { Trans, useTranslation } from 'react-i18next' import { useSubscriptionDashboardContext } from '../../context/subscription-dashboard-context' import { RowLink } from './row-link' export default function ManagedGroupSubscriptions() { const { t } = useTranslation() const { managedGroupSubscriptions } = useSubscriptionDashboardContext() if (!managedGroupSubscriptions) { return null } const groupSettingsEnabledFor = getMeta( 'ol-groupSettingsEnabledFor', [] ) as string[] return ( <> {managedGroupSubscriptions.map(subscription => { return (

{subscription.userIsGroupMember ? ( , // eslint-disable-next-line react/jsx-key , ]} values={{ planName: subscription.planLevelName, groupName: subscription.teamName || '', adminEmail: subscription.admin_id.email, }} shouldUnescape tOptions={{ interpolation: { escapeValue: true } }} /> ) : ( , // eslint-disable-next-line react/jsx-key , ]} values={{ planName: subscription.planLevelName, groupName: subscription.teamName || '', adminEmail: subscription.admin_id.email, }} shouldUnescape tOptions={{ interpolation: { escapeValue: true } }} /> )}

{groupSettingsEnabledFor?.includes(subscription._id) && ( )}
) })} ) }