-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove hasTranslation check added from 93926
- Loading branch information
1 parent
a4c3be4
commit 27c9d24
Showing
1 changed file
with
3 additions
and
8 deletions.
There are no files selected for viewing
11 changes: 3 additions & 8 deletions
11
packages/components/src/highlight-cards/highlight-cards-heading.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,13 @@ | ||
import { useHasEnTranslation } from '@automattic/i18n-utils'; | ||
import { useTranslate } from 'i18n-calypso'; | ||
|
||
export default function HighlightCardsHeading( { children }: { children: React.ReactNode } ) { | ||
const translate = useTranslate(); | ||
const hasEnTranslation = useHasEnTranslation(); | ||
const hasTranslation = hasEnTranslation( 'Updates every 30 minutes' ); | ||
return ( | ||
<div className="highlight-cards-heading__wrapper"> | ||
<h3 className="highlight-cards-heading">{ children }</h3> | ||
{ hasTranslation && ( | ||
<div className="highlight-cards-heading__update-frequency"> | ||
<span>{ translate( 'Updates every 30 minutes' ) }</span> | ||
</div> | ||
) } | ||
<div className="highlight-cards-heading__update-frequency"> | ||
<span>{ translate( 'Updates every 30 minutes' ) }</span> | ||
</div> | ||
</div> | ||
); | ||
} |