1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-25 21:06:42 +07:00

random titles

This commit is contained in:
Fedor Katurov 2019-11-13 15:09:05 +07:00
parent 7583a57b04
commit 9233ccbada
10 changed files with 63 additions and 11 deletions

View file

@ -3,6 +3,7 @@ import { INotification, NOTIFICATION_TYPES } from '~/redux/types';
import styles from './styles.scss';
import { NotificationMessage } from '../NotificationMessage';
import { Icon } from '~/components/input/Icon';
import { getRandomPhrase } from '~/constants/phrases';
interface IProps {
notifications: INotification[];
@ -14,13 +15,15 @@ const NOTIFICATION_RENDERERS = {
};
const NotificationBubble: FC<IProps> = ({ notifications, onClick }) => {
const placeholder = getRandomPhrase('NOTHING_HERE');
return (
<div className={styles.wrap}>
<div className={styles.list}>
{notifications.length === 0 && (
<div className={styles.placeholder}>
<Icon icon="bell_ring" />
<div>НЕТ УВЕДОМЛЕНИЙ</div>
<div>{placeholder}</div>
</div>
)}
{notifications.length > 0 &&

View file

@ -87,6 +87,10 @@ $notification_color: darken($content_bg, 2%);
flex-direction: column;
text-transform: uppercase;
font: $font_16_semibold;
box-sizing: border-box;
padding: 80px;
text-align: center;
line-height: 1.6em;
svg {
width: 120px;