11import React from 'react' ;
22
3- import { Box , Button , descriptors , Flex , Icon , Text } from '@/customizables' ;
3+ import { Box , descriptors , Flex , Icon , SimpleButton , Text } from '@/customizables' ;
44import { CaretRight , Check } from '@/icons' ;
55
66import type { StepperItemProps , StepperProps } from './types' ;
@@ -26,7 +26,7 @@ const Root = ({ children }: StepperProps): JSX.Element => {
2626 elementDescriptor = { descriptors . configureSSOStepperSeparator }
2727 icon = { CaretRight }
2828 size = 'md'
29- sx = { theme => ( { color : theme . colors . $colorMutedForeground } ) }
29+ colorScheme = 'neutral'
3030 />
3131 ) }
3232 </ React . Fragment >
@@ -44,7 +44,7 @@ const Item = ({
4444 children,
4545} : StepperItemProps ) : JSX . Element => {
4646 return (
47- < Button
47+ < SimpleButton
4848 elementDescriptor = { descriptors . configureSSOStepperItem }
4949 isActive = { isCurrent }
5050 variant = 'unstyled'
@@ -54,6 +54,9 @@ const Item = ({
5454 gap : theme . space . $1x5 ,
5555 padding : 0 ,
5656 color : isCurrent || isCompleted ? theme . colors . $colorForeground : theme . colors . $colorMutedForeground ,
57+ '&:disabled,&[data-disabled]' : {
58+ opacity : 1 ,
59+ } ,
5760 } ) }
5861 >
5962 < Flex
@@ -69,7 +72,7 @@ const Item = ({
6972 ? theme . colors . $colorForeground
7073 : isCompleted
7174 ? theme . colors . $success500
72- : theme . colors . $neutralAlpha400 ,
75+ : theme . colors . $colorMutedForeground ,
7376 } ) }
7477 >
7578 { isCompleted && ! isCurrent ? (
@@ -82,14 +85,15 @@ const Item = ({
8285 as = 'span'
8386 sx = { theme => ( {
8487 fontSize : theme . fontSizes . $xs ,
85- fontWeight : theme . fontWeights . $semibold ,
88+ fontWeight : theme . fontWeights . $medium ,
8689 color : theme . colors . $colorBackground ,
8790 } ) }
8891 >
8992 { bullet }
9093 </ Text >
9194 ) }
9295 </ Flex >
96+
9397 < Text
9498 elementDescriptor = { descriptors . configureSSOStepperItemLabel }
9599 as = 'span'
@@ -98,35 +102,11 @@ const Item = ({
98102 >
99103 { children }
100104 </ Text >
101- </ Button >
105+ </ SimpleButton >
102106 ) ;
103107} ;
104108Item . displayName = 'Stepper.Item' ;
105109
106- const ItemSkeleton = ( ) : JSX . Element => (
107- < Flex
108- align = 'center'
109- sx = { t => ( { gap : t . space . $1x5 } ) }
110- >
111- < Box
112- sx = { t => ( {
113- width : t . sizes . $4 ,
114- height : t . sizes . $4 ,
115- borderRadius : t . radii . $circle ,
116- backgroundColor : t . colors . $neutralAlpha100 ,
117- } ) }
118- />
119- < Box
120- sx = { t => ( {
121- width : t . sizes . $17 ,
122- height : t . sizes . $1x5 ,
123- borderRadius : t . radii . $md ,
124- backgroundColor : t . colors . $neutralAlpha100 ,
125- } ) }
126- />
127- </ Flex >
128- ) ;
129-
130110type SkeletonProps = {
131111 totalSteps ?: number ;
132112} ;
@@ -149,14 +129,39 @@ const Skeleton = ({ totalSteps = 4 }: SkeletonProps): JSX.Element => (
149129 elementDescriptor = { descriptors . configureSSOStepperSeparator }
150130 icon = { CaretRight }
151131 size = 'md'
152- sx = { theme => ( { color : theme . colors . $neutralAlpha100 } ) }
132+ colorScheme = 'neutral'
133+ sx = { { opacity : 0.16 } }
153134 />
154135 ) }
155136 </ React . Fragment >
156137 ) ) }
157138 </ Flex >
158139) ;
159140
141+ const ItemSkeleton = ( ) : JSX . Element => (
142+ < Flex
143+ align = 'center'
144+ sx = { t => ( { gap : t . space . $1x5 , minHeight : t . sizes . $4x5 , opacity : 0.16 } ) }
145+ >
146+ < Box
147+ sx = { t => ( {
148+ width : t . sizes . $4 ,
149+ height : t . sizes . $4 ,
150+ borderRadius : t . radii . $circle ,
151+ backgroundColor : t . colors . $colorMutedForeground ,
152+ } ) }
153+ />
154+ < Box
155+ sx = { t => ( {
156+ width : t . sizes . $17 ,
157+ height : t . sizes . $1x5 ,
158+ borderRadius : t . radii . $md ,
159+ backgroundColor : t . colors . $colorMutedForeground ,
160+ } ) }
161+ />
162+ </ Flex >
163+ ) ;
164+
160165/**
161166 * Numbered step indicator — purely presentational.
162167 *
0 commit comments