Skip to content

Commit 29bdf67

Browse files
committed
fix(banner): update icon class handling to conditionally apply styles based on iconColor
1 parent bc0c694 commit 29bdf67

File tree

1 file changed

+6
-2
lines changed
  • packages/bezier-react/src/components/Banner

1 file changed

+6
-2
lines changed

packages/bezier-react/src/components/Banner/Banner.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,14 +96,18 @@ export const Banner = forwardRef<HTMLDivElement, BannerProps>(function Banner(
9696
<div className={styles.Center}>
9797
{isBezierIcon(icon) ? (
9898
<Icon
99-
className={styles.Icon}
99+
className={classNames({
100+
[styles.Icon]: !iconColor,
101+
})}
100102
source={icon}
101103
color={iconColor}
102104
size="s"
103105
/>
104106
) : (
105107
<LegacyIcon
106-
className={styles.Icon}
108+
className={classNames({
109+
[styles.Icon]: !iconColor,
110+
})}
107111
name={icon}
108112
color={iconColor}
109113
size="s"

0 commit comments

Comments
 (0)