Skip to content

Commit

Permalink
fixed empty published date
Browse files Browse the repository at this point in the history
  • Loading branch information
Florin H committed Oct 12, 2023
1 parent 3ab675f commit 584df65
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions ui/src/components/Publication/SidebarCard/General/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,16 @@ const General: React.FC<Props> = (props): React.ReactElement => {
{Helpers.formatPublicationType(props.publicationVersion.publication.type)}
</span>
</div>
<div className="flex">
<span className="mr-2 text-sm font-semibold text-grey-800 transition-colors duration-500 dark:text-grey-100">
Published:
</span>
<time className=" text-sm font-medium text-grey-800 transition-colors duration-500 dark:text-white-50">
{props.publicationVersion.publishedDate &&
Helpers.formatDate(props.publicationVersion.publishedDate)}
</time>
</div>
{props.publicationVersion.publishedDate && (
<div className="flex">
<span className="mr-2 text-sm font-semibold text-grey-800 transition-colors duration-500 dark:text-grey-100">
Published:
</span>
<time className=" text-sm font-medium text-grey-800 transition-colors duration-500 dark:text-white-50">
{Helpers.formatDate(props.publicationVersion.publishedDate)}
</time>
</div>
)}
<div className="flex">
<span className="mr-2 text-sm font-semibold text-grey-800 transition-colors duration-500 dark:text-grey-100">
Language:
Expand Down

0 comments on commit 584df65

Please sign in to comment.