import { ExpandableWidget, List } from '@components/WidgetParts'; import { t } from '@lingui/macro'; import { TopicPreview } from '@ts/types/taxonomies'; import Link from 'next/link'; const RelatedTopics = ({ topics }: { topics: TopicPreview[] }) => { const sortedTopics = [...topics].sort((a, b) => a.title.localeCompare(b.title) ); const topicsList = sortedTopics.map((topic) => { return (
  • {topic.title}
  • ); }); return ( 1 ? t`Related topics` : t`Related topic`} withBorders={true} > ); }; export default RelatedTopics;