Skip to content

Commit f39de78

Browse files
Karthik-B-06kodiakhq[bot]
authored andcommitted
chore(progress-bar): 💄 wrap tailwind classnames with cx
1 parent edf65bd commit f39de78

File tree

1 file changed

+13
-7
lines changed

1 file changed

+13
-7
lines changed

src/components/progress/ProgressBar.tsx

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import {
1313

1414
import { AnimatedBox, BoxProps } from "../../primitives";
1515
import { useTheme } from "../../theme/context";
16-
import { createComponent, styleAdapter } from "../../utils";
16+
import { createComponent, cx, styleAdapter } from "../../utils";
1717

1818
export type ProgressBarSizes = "sm" | "md" | "lg" | "xl";
1919
export type ProgressBarTheme = "base" | "primary";
@@ -113,8 +113,10 @@ export const RNProgressBar: React.FC<Partial<ProgressProps>> = forwardRef<
113113
ref={ref}
114114
style={[
115115
tailwind.style(
116-
progressTheme.size[size]?.container,
117-
progressTheme.themeColor[themeColor]?.track,
116+
cx(
117+
progressTheme.size[size]?.container,
118+
progressTheme.themeColor[themeColor]?.track,
119+
),
118120
),
119121
styleAdapter(style, { pressed: false }, false),
120122
]}
@@ -124,8 +126,10 @@ export const RNProgressBar: React.FC<Partial<ProgressProps>> = forwardRef<
124126
<AnimatedBox
125127
style={[
126128
tailwind.style(
127-
progressTheme.size[size]?.bar,
128-
progressTheme.themeColor[themeColor]?.filled,
129+
cx(
130+
progressTheme.size[size]?.bar,
131+
progressTheme.themeColor[themeColor]?.filled,
132+
),
129133
),
130134
styleAdapter(trackStyle, { pressed: false }, false),
131135
translatingStyle,
@@ -136,8 +140,10 @@ export const RNProgressBar: React.FC<Partial<ProgressProps>> = forwardRef<
136140
<AnimatedBox
137141
style={[
138142
tailwind.style(
139-
progressTheme.size[size]?.bar,
140-
progressTheme.themeColor[themeColor]?.filled,
143+
cx(
144+
progressTheme.size[size]?.bar,
145+
progressTheme.themeColor[themeColor]?.filled,
146+
),
141147
),
142148
styleAdapter(trackStyle, { pressed: false }, false),
143149
animatingWidth,

0 commit comments

Comments
 (0)