/** * WordPress dependencies */ import { useSelect } from '@safe-wordpress/data'; import { createInterpolateElement } from '@safe-wordpress/element'; import { _x, sprintf } from '@safe-wordpress/i18n'; /** * External dependencies */ import { dateI18n } from '@nelio-content/date'; /** * Internal dependencies */ import { store as NC_ACCOUNT } from '~/nelio-content-pages/account/store'; const DATE_FORMAT = _x( 'Y-m-d', 'text (date)', 'nelio-content' ); export const Explanation = (): JSX.Element | null => { const account = useSelect( ( select ) => select( NC_ACCOUNT ).getAccount(), [] ); if ( account.plan === 'free' ) { return null; } const { mode, deactivationDate, nextChargeDate, nextChargeTotal, state } = account; if ( 'invitation' === mode ) { return (