import React from 'react'; import { assetUrl } from '../../utils/url'; import { useTranslation } from 'react-i18next'; export type NewsListItem = { id: number | string; title: string; excerpt?: string; image?: string; slug?: string; }; const NewsList: React.FC<{ items: NewsListItem[]; emptyText?: string; seeAllHref?: string; seeAllLabel?: string; }> = ({ items, emptyText, seeAllHref, seeAllLabel }) => { const { t } = useTranslation(); // Use provided text or fallback to translations const emptyTextFinal = emptyText || t('news.no_news'); const seeAllLabelFinal = seeAllLabel || t('news.view_all_news'); return ( <>
{emptyTextFinal}