Fixed icons

This commit is contained in:
kvakazyambra 2022-11-13 21:56:58 +03:00
parent 53634b997e
commit fd15d04231
2 changed files with 2 additions and 3 deletions

View File

@ -177,8 +177,7 @@ export const Header = (props: Props) => {
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose, 'loginbtn')}>
<a href="?modal=auth&mode=login" onClick={handleClientRouteLinkClick}>
<span class={styles.textLabel}>{t('Enter')}</span>
{/* TODO: заменить иконку */}
<Icon name="inbox-white" class={styles.icon} counter={session()?.news?.unread || 0} />
<Icon name="user-anonymous" class={styles.icon} />
</a>
</div>
}

View File

@ -16,7 +16,7 @@ export const Icon = (passedProps: IconProps) => {
const props = mergeProps({ title: '', counter: 0 }, passedProps)
return (
<div class={clsx(styles.icon, props.class)} style={props.style}>
<div class={clsx('icon', styles.icon, props.class)} style={props.style}>
<img src={`/icons/${props.name}.svg`} alt={props.title ?? props.name} class={props.iconClassName} />
<Show when={props.counter}>
<div class={styles.notificationsCounter}>{props.counter}</div>