/** * WordPress dependencies */ import { Button, Dashicon } from '@safe-wordpress/components'; import { useSelect } from '@safe-wordpress/data'; import { createInterpolateElement } from '@safe-wordpress/element'; import { _x } from '@safe-wordpress/i18n'; /** * External dependencies */ import type { PostQualityStatus } from '@nelio-content/types'; /** * Internal dependencies */ import './style.scss'; import { store as NC_EDIT_POST } from '../../../store'; export type QualityAnalysisSummaryProps = { readonly label?: string; readonly onClick?: () => void; }; export const QualityAnalysisSummary = ( { onClick, label: proposedLabel, }: QualityAnalysisSummaryProps ): JSX.Element => { const status = useSelect( ( select ) => select( NC_EDIT_POST ).getOverallPostQualityStatus(), [] ); const label = proposedLabel || getDefaultLabel( status ); return (