hhm-client/src/components/aside/AsideNews.tsx

42 lines
1.1 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// Modules
import { Link } from 'react-router-dom';
// Images
import { ReactComponent as ArrRight } from '../../assets/icons/arrow-right.svg';
// Components
import NewsCategory from '../global/NewsCategory';
import NewsDate from '../global/NewsDate';
interface Props {
title: string;
category: string;
date: string;
img: string;
link: string;
}
const AsideNews = ({ title, category, date, img, link }: Props) => {
return (
<div className="aside-news">
<div className="aside-news-wrapper">
<div className="aside-news-image">
<img src={img} alt="img" />
</div>
<div className="aside-news-info">
<div className="aside-news-info-inner">
<div className="aside-news-status">
<NewsCategory title="политика" link="" />
<NewsDate date={date} />
</div>
<h2 className="aside-news-title">{title}</h2>
</div>
<Link to={`/${link}`} className="aside-news-link">
<span>прочитать все</span> <ArrRight />
</Link>
</div>
</div>
</div>
);
};
export default AsideNews;