Skip to content

Commit b15f504

Browse files
committed
Add cursor pointer for stepper when navigation is enabled
1 parent 2eaf9ff commit b15f504

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/theme.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,16 @@ import type { DeepPartial } from "ts-essentials"
44
import type { ChakraStylesConfig } from "chakra-react-select"
55
import type { SelectOption } from "./types"
66

7-
type CSSObjectWithActiveStep = CSSObject & { _activeStep: CSSObject }
8-
97
const StepsComponent: typeof StepsTheme = {
108
...StepsTheme,
119
baseStyle: (props: any) => {
10+
const navigationEnabled = !!props.onClickStep
1211
return {
1312
...StepsTheme.baseStyle(props),
13+
stepContainer: {
14+
...StepsTheme.baseStyle(props).stepContainer,
15+
cursor: navigationEnabled ? "pointer" : "initial",
16+
},
1417
label: {
1518
...StepsTheme.baseStyle(props).label,
1619
color: "textColor",

0 commit comments

Comments
 (0)