Skip to content

Commit 363f0f4

Browse files
committed
button
1 parent 6544312 commit 363f0f4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

packages/styled-react/src/index.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,15 @@ type StyledProps = SxProp &
4141

4242
type SegmentedControlProps = PrimerSegmentedControlProps & Omit<StyledProps, keyof PrimerSegmentedControlProps>
4343

44-
const SegmentedControl = forwardRef<HTMLUListElement, SegmentedControlProps>(function SegmentedControl(props, ref) {
44+
const SegmentedControlImpl = forwardRef<HTMLUListElement, SegmentedControlProps>(function SegmentedControl(props, ref) {
4545
return <Box as={PrimerSegmentedControl} ref={ref} {...props} />
4646
})
4747

48+
const SegmentedControl = Object.assign(SegmentedControlImpl, {
49+
Button: PrimerSegmentedControl.Button,
50+
IconButton: PrimerSegmentedControl.IconButton,
51+
})
52+
4853
type StateLabelProps = PrimerStateLabelProps & SxProp
4954

5055
const StateLabel = forwardRef<HTMLSpanElement, StateLabelProps>(function StateLabel(props, ref) {

0 commit comments

Comments
 (0)