@charcoal-ui/react 3.6.0 → 3.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/dist/_lib/compat.d.ts +1 -0
  2. package/dist/_lib/compat.d.ts.map +1 -1
  3. package/dist/components/Button/StyledButton.d.ts +13 -0
  4. package/dist/components/Button/StyledButton.d.ts.map +1 -0
  5. package/dist/components/Button/index.d.ts +3 -2
  6. package/dist/components/Button/index.d.ts.map +1 -1
  7. package/dist/components/Button/index.story.d.ts +16 -32
  8. package/dist/components/Button/index.story.d.ts.map +1 -1
  9. package/dist/components/Button/lib/variantToBackground.d.ts +3 -0
  10. package/dist/components/Button/lib/variantToBackground.d.ts.map +1 -0
  11. package/dist/components/Button/lib/variantToFont.d.ts +3 -0
  12. package/dist/components/Button/lib/variantToFont.d.ts.map +1 -0
  13. package/dist/components/Checkbox/index.d.ts.map +1 -1
  14. package/dist/components/Checkbox/index.story.d.ts +6 -16
  15. package/dist/components/Checkbox/index.story.d.ts.map +1 -1
  16. package/dist/components/Clickable/index.story.d.ts +4 -6
  17. package/dist/components/Clickable/index.story.d.ts.map +1 -1
  18. package/dist/components/DropdownSelector/ListItem/index.story.d.ts +7 -7
  19. package/dist/components/DropdownSelector/ListItem/index.story.d.ts.map +1 -1
  20. package/dist/components/DropdownSelector/MenuList/index.story.d.ts +6 -9
  21. package/dist/components/DropdownSelector/MenuList/index.story.d.ts.map +1 -1
  22. package/dist/components/DropdownSelector/Popover/index.story.d.ts +3 -7
  23. package/dist/components/DropdownSelector/Popover/index.story.d.ts.map +1 -1
  24. package/dist/components/DropdownSelector/index.d.ts.map +1 -1
  25. package/dist/components/DropdownSelector/index.story.d.ts +9 -11
  26. package/dist/components/DropdownSelector/index.story.d.ts.map +1 -1
  27. package/dist/components/Icon/index.story.d.ts +4 -26
  28. package/dist/components/Icon/index.story.d.ts.map +1 -1
  29. package/dist/components/IconButton/index.d.ts +1 -0
  30. package/dist/components/IconButton/index.d.ts.map +1 -1
  31. package/dist/components/IconButton/index.story.d.ts +6 -25
  32. package/dist/components/IconButton/index.story.d.ts.map +1 -1
  33. package/dist/components/LoadingSpinner/LoadingSpinnerIcon.story.d.ts +8 -0
  34. package/dist/components/LoadingSpinner/LoadingSpinnerIcon.story.d.ts.map +1 -0
  35. package/dist/components/LoadingSpinner/index.d.ts +2 -2
  36. package/dist/components/LoadingSpinner/index.d.ts.map +1 -1
  37. package/dist/components/LoadingSpinner/index.story.d.ts +4 -7
  38. package/dist/components/LoadingSpinner/index.story.d.ts.map +1 -1
  39. package/dist/components/Modal/index.story.d.ts +16 -41
  40. package/dist/components/Modal/index.story.d.ts.map +1 -1
  41. package/dist/components/MultiSelect/index.d.ts.map +1 -1
  42. package/dist/components/Radio/index.d.ts +0 -2
  43. package/dist/components/Radio/index.d.ts.map +1 -1
  44. package/dist/components/Radio/index.story.d.ts +12 -23
  45. package/dist/components/Radio/index.story.d.ts.map +1 -1
  46. package/dist/components/SegmentedControl/RadioGroupContext.d.ts +1 -1
  47. package/dist/components/SegmentedControl/RadioGroupContext.d.ts.map +1 -1
  48. package/dist/components/SegmentedControl/index.story.d.ts +5 -8
  49. package/dist/components/SegmentedControl/index.story.d.ts.map +1 -1
  50. package/dist/components/Switch/index.d.ts.map +1 -1
  51. package/dist/components/Switch/index.story.d.ts +7 -12
  52. package/dist/components/Switch/index.story.d.ts.map +1 -1
  53. package/dist/components/TagItem/index.d.ts.map +1 -1
  54. package/dist/components/TagItem/index.story.d.ts +14 -24
  55. package/dist/components/TagItem/index.story.d.ts.map +1 -1
  56. package/dist/components/TextArea/TextArea.story.d.ts +7 -25
  57. package/dist/components/TextArea/TextArea.story.d.ts.map +1 -1
  58. package/dist/components/TextField/TextField.story.d.ts +13 -20
  59. package/dist/components/TextField/TextField.story.d.ts.map +1 -1
  60. package/dist/components/TextField/index.d.ts.map +1 -1
  61. package/dist/index.cjs.js +418 -206
  62. package/dist/index.cjs.js.map +1 -1
  63. package/dist/index.esm.js +387 -175
  64. package/dist/index.esm.js.map +1 -1
  65. package/dist/styled.d.ts +4 -4
  66. package/package.json +17 -20
  67. package/src/_lib/compat.ts +8 -0
  68. package/src/components/Button/StyledButton.tsx +71 -0
  69. package/src/components/Button/__snapshots__/index.story.storyshot +314 -118
  70. package/src/components/Button/index.story.tsx +141 -138
  71. package/src/components/Button/index.tsx +15 -104
  72. package/src/components/Button/lib/variantToBackground.tsx +19 -0
  73. package/src/components/Button/lib/variantToFont.tsx +19 -0
  74. package/src/components/Checkbox/__snapshots__/index.story.storyshot +12 -27
  75. package/src/components/Checkbox/index.story.tsx +82 -88
  76. package/src/components/Checkbox/index.tsx +2 -12
  77. package/src/components/Clickable/__snapshots__/index.story.storyshot +2 -2
  78. package/src/components/Clickable/index.story.tsx +12 -9
  79. package/src/components/DropdownSelector/DropdownMenuItem.tsx +1 -14
  80. package/src/components/DropdownSelector/ListItem/__snapshots__/index.story.storyshot +42 -37
  81. package/src/components/DropdownSelector/ListItem/index.story.tsx +8 -4
  82. package/src/components/DropdownSelector/MenuList/__snapshots__/index.story.storyshot +38 -38
  83. package/src/components/DropdownSelector/MenuList/index.story.tsx +33 -27
  84. package/src/components/DropdownSelector/Popover/__snapshots__/index.story.storyshot +11 -5
  85. package/src/components/DropdownSelector/Popover/index.story.tsx +6 -6
  86. package/src/components/DropdownSelector/__snapshots__/index.story.storyshot +313 -151
  87. package/src/components/DropdownSelector/index.story.tsx +207 -171
  88. package/src/components/DropdownSelector/index.tsx +22 -22
  89. package/src/components/Icon/__snapshots__/index.story.storyshot +1 -1
  90. package/src/components/Icon/index.story.tsx +8 -12
  91. package/src/components/IconButton/__snapshots__/index.story.storyshot +130 -13
  92. package/src/components/IconButton/index.story.tsx +30 -23
  93. package/src/components/IconButton/index.tsx +32 -20
  94. package/src/components/LoadingSpinner/LoadingSpinnerIcon.story.tsx +12 -0
  95. package/src/components/LoadingSpinner/__snapshots__/LoadingSpinnerIcon.story.storyshot +28 -0
  96. package/src/components/LoadingSpinner/__snapshots__/index.story.storyshot +1 -35
  97. package/src/components/LoadingSpinner/index.story.tsx +11 -54
  98. package/src/components/LoadingSpinner/index.tsx +1 -1
  99. package/src/components/Modal/__snapshots__/index.story.storyshot +231 -194
  100. package/src/components/Modal/index.story.tsx +139 -133
  101. package/src/components/MultiSelect/__snapshots__/index.story.storyshot +56 -4
  102. package/src/components/MultiSelect/index.tsx +3 -0
  103. package/src/components/Radio/__snapshots__/index.story.storyshot +981 -121
  104. package/src/components/Radio/index.story.tsx +128 -63
  105. package/src/components/Radio/index.tsx +10 -16
  106. package/src/components/SegmentedControl/RadioGroupContext.tsx +1 -1
  107. package/src/components/SegmentedControl/__snapshots__/index.story.storyshot +11 -11
  108. package/src/components/SegmentedControl/index.story.tsx +24 -29
  109. package/src/components/SegmentedControl/index.tsx +1 -1
  110. package/src/components/Switch/__snapshots__/index.story.storyshot +184 -26
  111. package/src/components/Switch/index.story.tsx +72 -48
  112. package/src/components/Switch/index.tsx +2 -7
  113. package/src/components/TagItem/__snapshots__/index.story.storyshot +72 -33
  114. package/src/components/TagItem/index.story.tsx +154 -159
  115. package/src/components/TagItem/index.tsx +2 -6
  116. package/src/components/TextArea/TextArea.story.tsx +29 -32
  117. package/src/components/TextArea/__snapshots__/TextArea.story.storyshot +139 -83
  118. package/src/components/TextField/TextField.story.tsx +67 -66
  119. package/src/components/TextField/__snapshots__/TextField.story.storyshot +198 -162
  120. package/src/components/TextField/index.tsx +0 -7
  121. package/dist/components/Checkbox/performance.test.d.ts +0 -4
  122. package/dist/components/Checkbox/performance.test.d.ts.map +0 -1
  123. package/dist/components/Checkbox/snapshot.test.d.ts +0 -2
  124. package/dist/components/Checkbox/snapshot.test.d.ts.map +0 -1
  125. package/src/components/Checkbox/__snapshots__/snapshot.test.tsx.snap +0 -1093
  126. package/src/components/Checkbox/performance.test.tsx +0 -30
  127. package/src/components/Checkbox/snapshot.test.tsx +0 -66
@@ -1,76 +1,141 @@
1
- import { action } from '@storybook/addon-actions'
2
- import { css } from 'styled-components'
3
- import { Story } from '../../_lib/compat'
1
+ import styled from 'styled-components'
4
2
  import Radio, { RadioGroup } from '.'
5
3
  import { px } from '@charcoal-ui/utils'
6
-
7
- const options = ['value1', 'value2']
4
+ import { StoryObj } from '@storybook/react'
5
+ import { useState } from 'react'
8
6
 
9
7
  export default {
10
8
  title: 'Radio',
11
9
  component: Radio,
12
- argTypes: {
13
- value: {
14
- control: { type: 'select' },
15
- options,
16
- },
17
- },
18
10
  args: {
19
- invalid: false,
20
- parentDisabled: false,
21
- childDisabled: false,
22
- readonly: false,
11
+ name: 'name',
12
+ label: 'label',
13
+ },
14
+ parameters: {
15
+ layout: 'centered',
23
16
  },
24
17
  }
25
18
 
26
- interface Props {
27
- value?: string
28
- invalid: boolean
29
- parentDisabled: boolean
30
- childDisabled: boolean
31
- readonly: boolean
32
- className?: string
19
+ const LayoutDiv = styled.div`
20
+ display: flex;
21
+ flex-direction: column;
22
+ gap: ${({ theme }) => px(theme.spacing[24])};
23
+ `
24
+
25
+ export const Basic: StoryObj<typeof Radio> = {
26
+ render: function Render() {
27
+ const options = ['1', '2', '3']
28
+ const [value, setValue] = useState(options[0])
29
+ return (
30
+ <LayoutDiv>
31
+ <RadioGroup
32
+ label={'label'}
33
+ name={'name'}
34
+ value={value}
35
+ onChange={setValue}
36
+ >
37
+ {options.map((option) => (
38
+ <Radio key={option} value={option}>
39
+ Value {option}
40
+ </Radio>
41
+ ))}
42
+ </RadioGroup>
43
+ </LayoutDiv>
44
+ )
45
+ },
33
46
  }
34
47
 
35
- const Template: Story<Partial<Props>> = ({
36
- value,
37
- invalid,
38
- parentDisabled,
39
- childDisabled,
40
- readonly,
41
- className,
42
- }) => (
43
- <div
44
- css={css`
45
- display: flex;
46
- flex-direction: column;
47
- gap: ${({ theme }) => px(theme.spacing[24])};
48
- `}
49
- >
50
- {['name1', 'name2', 'name3'].map((name) => (
51
- <RadioGroup
52
- key={name}
53
- label={`選択肢-${name}`}
54
- name={name}
55
- value={value}
56
- onChange={action('onChange')}
57
- disabled={parentDisabled}
58
- readonly={readonly}
59
- invalid={invalid}
60
- >
61
- {options.map((option) => (
62
- <Radio
63
- key={option}
64
- value={option}
65
- disabled={childDisabled}
66
- className={className}
67
- >
68
- {name}({option})を選ぶ
69
- </Radio>
70
- ))}
71
- </RadioGroup>
72
- ))}
73
- </div>
74
- )
48
+ export const Disabled: StoryObj<typeof Radio> = {
49
+ render: function Render() {
50
+ const options = ['1', '2', '3']
51
+ const [value, setValue] = useState(options[0])
52
+ return (
53
+ <LayoutDiv>
54
+ <RadioGroup
55
+ label={'label'}
56
+ name={'name'}
57
+ value={value}
58
+ onChange={setValue}
59
+ disabled
60
+ >
61
+ {options.map((option) => (
62
+ <Radio key={option} value={option} disabled>
63
+ Value {option}
64
+ </Radio>
65
+ ))}
66
+ </RadioGroup>
67
+ </LayoutDiv>
68
+ )
69
+ },
70
+ }
75
71
 
76
- export const Default = Template.bind({})
72
+ export const PartialDisabled: StoryObj<typeof Radio> = {
73
+ render: function Render() {
74
+ const options = ['1', '2', '3']
75
+ const [value, setValue] = useState(options[0])
76
+ return (
77
+ <LayoutDiv>
78
+ <RadioGroup
79
+ label={'label'}
80
+ name={'name'}
81
+ value={value}
82
+ onChange={setValue}
83
+ >
84
+ {options.map((option) => (
85
+ <Radio key={option} value={option} disabled={option === '2'}>
86
+ Value {option}
87
+ </Radio>
88
+ ))}
89
+ </RadioGroup>
90
+ </LayoutDiv>
91
+ )
92
+ },
93
+ }
94
+
95
+ export const Readonly: StoryObj<typeof Radio> = {
96
+ render: function Render() {
97
+ const options = ['1', '2', '3']
98
+ const [value, setValue] = useState(options[0])
99
+ return (
100
+ <LayoutDiv>
101
+ <RadioGroup
102
+ label={'label'}
103
+ name={'name'}
104
+ value={value}
105
+ onChange={setValue}
106
+ readonly
107
+ >
108
+ {options.map((option) => (
109
+ <Radio key={option} value={option}>
110
+ Value {option}
111
+ </Radio>
112
+ ))}
113
+ </RadioGroup>
114
+ </LayoutDiv>
115
+ )
116
+ },
117
+ }
118
+
119
+ export const Invalid: StoryObj<typeof Radio> = {
120
+ render: function Render() {
121
+ const options = ['1', '2', '3']
122
+ const [value, setValue] = useState(options[0])
123
+ return (
124
+ <LayoutDiv>
125
+ <RadioGroup
126
+ label={'label'}
127
+ name={'name'}
128
+ value={value}
129
+ onChange={setValue}
130
+ invalid
131
+ >
132
+ {options.map((option) => (
133
+ <Radio key={option} value={option}>
134
+ Value {option}
135
+ </Radio>
136
+ ))}
137
+ </RadioGroup>
138
+ </LayoutDiv>
139
+ )
140
+ },
141
+ }
@@ -1,7 +1,8 @@
1
1
  import { memo, forwardRef, useCallback, useContext } from 'react'
2
2
  import * as React from 'react'
3
- import styled, { css } from 'styled-components'
3
+ import styled from 'styled-components'
4
4
  import warning from 'warning'
5
+ import { focusVisibleFocusRingCss } from '@charcoal-ui/styled'
5
6
 
6
7
  export type RadioProps = React.PropsWithChildren<{
7
8
  value: string
@@ -45,7 +46,7 @@ const Radio = forwardRef<HTMLInputElement, RadioProps>(function RadioInner(
45
46
  name={name}
46
47
  value={value}
47
48
  checked={isSelected}
48
- invalid={invalid}
49
+ aria-invalid={invalid}
49
50
  onChange={handleChange}
50
51
  disabled={isDisabled || isReadonly}
51
52
  ref={ref}
@@ -70,9 +71,7 @@ const RadioRoot = styled.label`
70
71
  }
71
72
  `
72
73
 
73
- export const RadioInput = styled.input.attrs({ type: 'radio' })<{
74
- invalid?: boolean
75
- }>`
74
+ export const RadioInput = styled.input.attrs({ type: 'radio' })`
76
75
  /** Make prior to browser default style */
77
76
  &[type='radio'] {
78
77
  appearance: none;
@@ -91,23 +90,18 @@ export const RadioInput = styled.input.attrs({ type: 'radio' })<{
91
90
 
92
91
  &:not(:disabled):not([aria-disabled]),
93
92
  &[aria-disabled='false'] {
94
- ${({ invalid = false }) =>
95
- invalid &&
96
- css`
97
- box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
98
- `}
99
-
100
93
  &:hover {
101
94
  background-color: var(--charcoal-surface1-hover);
102
95
  }
103
96
  &:active {
104
97
  background-color: var(--charcoal-surface1-press);
105
98
  }
106
- &:focus,
107
- &:active,
108
- &:focus-visible {
109
- outline: none;
110
- box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
99
+ ${focusVisibleFocusRingCss}
100
+ &[aria-invalid='true'] {
101
+ box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
102
+ &:focus {
103
+ box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
104
+ }
111
105
  }
112
106
  }
113
107
 
@@ -1,6 +1,6 @@
1
1
  import { createContext, useContext } from 'react'
2
2
  import * as React from 'react'
3
- import { RadioGroupState } from 'react-stately'
3
+ import type { RadioGroupState } from '@react-stately/radio'
4
4
 
5
5
  const RadioContext = createContext<RadioGroupState | null>(null)
6
6
 
@@ -1,6 +1,6 @@
1
1
  // Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
 
3
- exports[`Storyshots SegmentedControl Object Segments 1`] = `
3
+ exports[`Storybook Tests SegmentedControl ObjectSegments 1`] = `
4
4
  .c0 {
5
5
  display: -webkit-inline-box;
6
6
  display: -webkit-inline-flex;
@@ -95,7 +95,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
95
95
  aria-label="test"
96
96
  aria-orientation="vertical"
97
97
  className="c0"
98
- id="react-aria-1"
98
+ id="test-id"
99
99
  onBlur={[Function]}
100
100
  onFocus={[Function]}
101
101
  onKeyDown={[Function]}
@@ -110,7 +110,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
110
110
  checked={false}
111
111
  className="c2"
112
112
  disabled={false}
113
- name="test"
113
+ name="test-id"
114
114
  onChange={[Function]}
115
115
  onClick={[Function]}
116
116
  onDragStart={[Function]}
@@ -149,7 +149,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
149
149
  checked={false}
150
150
  className="c2"
151
151
  disabled={false}
152
- name="test"
152
+ name="test-id"
153
153
  onChange={[Function]}
154
154
  onClick={[Function]}
155
155
  onDragStart={[Function]}
@@ -188,7 +188,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
188
188
  checked={false}
189
189
  className="c2"
190
190
  disabled={false}
191
- name="test"
191
+ name="test-id"
192
192
  onChange={[Function]}
193
193
  onClick={[Function]}
194
194
  onDragStart={[Function]}
@@ -227,7 +227,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
227
227
  checked={false}
228
228
  className="c2"
229
229
  disabled={true}
230
- name="test"
230
+ name="test-id"
231
231
  onChange={[Function]}
232
232
  onClick={[Function]}
233
233
  onDragStart={[Function]}
@@ -259,7 +259,7 @@ exports[`Storyshots SegmentedControl Object Segments 1`] = `
259
259
  </div>
260
260
  `;
261
261
 
262
- exports[`Storyshots SegmentedControl String Segments 1`] = `
262
+ exports[`Storybook Tests SegmentedControl StringSegments 1`] = `
263
263
  .c0 {
264
264
  display: -webkit-inline-box;
265
265
  display: -webkit-inline-flex;
@@ -354,7 +354,7 @@ exports[`Storyshots SegmentedControl String Segments 1`] = `
354
354
  aria-label="test"
355
355
  aria-orientation="vertical"
356
356
  className="c0"
357
- id="react-aria-5"
357
+ id="test-id"
358
358
  onBlur={[Function]}
359
359
  onFocus={[Function]}
360
360
  onKeyDown={[Function]}
@@ -369,7 +369,7 @@ exports[`Storyshots SegmentedControl String Segments 1`] = `
369
369
  checked={false}
370
370
  className="c2"
371
371
  disabled={false}
372
- name="test"
372
+ name="test-id"
373
373
  onChange={[Function]}
374
374
  onClick={[Function]}
375
375
  onDragStart={[Function]}
@@ -408,7 +408,7 @@ exports[`Storyshots SegmentedControl String Segments 1`] = `
408
408
  checked={false}
409
409
  className="c2"
410
410
  disabled={false}
411
- name="test"
411
+ name="test-id"
412
412
  onChange={[Function]}
413
413
  onClick={[Function]}
414
414
  onDragStart={[Function]}
@@ -447,7 +447,7 @@ exports[`Storyshots SegmentedControl String Segments 1`] = `
447
447
  checked={false}
448
448
  className="c2"
449
449
  disabled={false}
450
- name="test"
450
+ name="test-id"
451
451
  onChange={[Function]}
452
452
  onClick={[Function]}
453
453
  onDragStart={[Function]}
@@ -1,37 +1,32 @@
1
- import { action } from '@storybook/addon-actions'
2
- import SegmentedControl, { SegmentedControlProps } from '.'
3
- import { Story } from '../../_lib/compat'
1
+ import SegmentedControl from '.'
2
+ import { Meta, StoryObj } from '@storybook/react'
4
3
 
5
4
  export default {
6
5
  title: 'SegmentedControl',
7
6
  component: SegmentedControl,
8
- }
9
-
10
- export const StringSegments: Story<SegmentedControlProps> = (props) => {
11
- return <SegmentedControl {...props} onChange={action('change')} />
12
- }
13
-
14
- StringSegments.args = {
15
- name: 'test',
16
- data: ['option1', 'option2', 'option3'],
17
- disabled: false,
18
- readonly: false,
19
- required: false,
20
- }
7
+ } as Meta<typeof SegmentedControl>
21
8
 
22
- export const ObjectSegments: Story<SegmentedControlProps> = (props) => {
23
- return <SegmentedControl {...props} onChange={action('change')} />
9
+ export const StringSegments: StoryObj<typeof SegmentedControl> = {
10
+ args: {
11
+ name: 'test',
12
+ data: ['option1', 'option2', 'option3'],
13
+ disabled: false,
14
+ readonly: false,
15
+ required: false,
16
+ },
24
17
  }
25
18
 
26
- ObjectSegments.args = {
27
- name: 'test',
28
- data: [
29
- { label: '選択肢1', value: 'option1' },
30
- { label: '選択肢2', value: 'option2' },
31
- { label: '選択肢3', value: 'option3' },
32
- { label: '選択肢4', value: 'option4', disabled: true },
33
- ],
34
- disabled: false,
35
- readonly: false,
36
- required: false,
19
+ export const ObjectSegments: StoryObj<typeof SegmentedControl> = {
20
+ args: {
21
+ name: 'test',
22
+ data: [
23
+ { label: '選択肢1', value: 'option1' },
24
+ { label: '選択肢2', value: 'option2' },
25
+ { label: '選択肢3', value: 'option3' },
26
+ { label: '選択肢4', value: 'option4', disabled: true },
27
+ ],
28
+ disabled: false,
29
+ readonly: false,
30
+ required: false,
31
+ },
37
32
  }
@@ -1,6 +1,6 @@
1
1
  import { ReactNode, forwardRef, memo, useMemo, useRef } from 'react'
2
2
  import * as React from 'react'
3
- import { useRadioGroupState } from 'react-stately'
3
+ import { useRadioGroupState } from '@react-stately/radio'
4
4
  import {
5
5
  AriaRadioGroupProps,
6
6
  AriaRadioProps,