In the Icon component changed props.className to props.class
This commit is contained in:
parent
78e351e71b
commit
eeeb8f2271
|
@ -4,7 +4,7 @@ import type { JSX } from 'solid-js'
|
||||||
import './Icon.css'
|
import './Icon.css'
|
||||||
|
|
||||||
type IconProps = {
|
type IconProps = {
|
||||||
className?: string
|
class?: string
|
||||||
iconClassName?: string
|
iconClassName?: string
|
||||||
style?: string | JSX.CSSProperties
|
style?: string | JSX.CSSProperties
|
||||||
title?: string
|
title?: string
|
||||||
|
@ -16,7 +16,7 @@ export const Icon = (passedProps: IconProps) => {
|
||||||
const props = mergeProps({ title: '', counter: 0 }, passedProps)
|
const props = mergeProps({ title: '', counter: 0 }, passedProps)
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div class={clsx('icon', props.className)} style={props.style}>
|
<div class={clsx('icon', props.class)} style={props.style}>
|
||||||
<img src={`/icons/${props.name}.svg`} alt={props.title ?? props.name} class={props.iconClassName} />
|
<img src={`/icons/${props.name}.svg`} alt={props.title ?? props.name} class={props.iconClassName} />
|
||||||
<Show when={props.counter}>
|
<Show when={props.counter}>
|
||||||
<div class="notifications-counter">{props.counter}</div>
|
<div class="notifications-counter">{props.counter}</div>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user