@charcoal-ui/react 3.0.0 → 3.1.1
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.
- package/dist/components/DropdownSelector/index.d.ts.map +1 -1
- package/dist/components/DropdownSelector/index.story.d.ts +1 -0
- package/dist/components/DropdownSelector/index.story.d.ts.map +1 -1
- package/dist/components/Icon/index.story.d.ts +1 -1
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/index.cjs.js +2 -2
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +2 -2
- package/dist/index.esm.js.map +1 -1
- package/package.json +6 -6
- package/src/components/DropdownSelector/index.story.tsx +22 -0
- package/src/components/DropdownSelector/index.tsx +1 -0
- package/src/components/Modal/index.tsx +1 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@charcoal-ui/react",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"main": "./dist/index.cjs.js",
|
|
6
6
|
"module": "./dist/index.esm.js",
|
|
@@ -49,10 +49,10 @@
|
|
|
49
49
|
"typescript": "^4.9.5"
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@charcoal-ui/icons": "^3.
|
|
53
|
-
"@charcoal-ui/styled": "^3.
|
|
54
|
-
"@charcoal-ui/theme": "^3.
|
|
55
|
-
"@charcoal-ui/utils": "^3.
|
|
52
|
+
"@charcoal-ui/icons": "^3.1.1",
|
|
53
|
+
"@charcoal-ui/styled": "^3.1.1",
|
|
54
|
+
"@charcoal-ui/theme": "^3.1.1",
|
|
55
|
+
"@charcoal-ui/utils": "^3.1.1",
|
|
56
56
|
"@react-aria/button": "^3.7.0",
|
|
57
57
|
"@react-aria/checkbox": "^3.8.0",
|
|
58
58
|
"@react-aria/dialog": "^3.5.0",
|
|
@@ -88,5 +88,5 @@
|
|
|
88
88
|
"url": "https://github.com/pixiv/charcoal.git",
|
|
89
89
|
"directory": "packages/react"
|
|
90
90
|
},
|
|
91
|
-
"gitHead": "
|
|
91
|
+
"gitHead": "33a7278e64d0177b536edb4f43a291a319ca7e2d"
|
|
92
92
|
}
|
|
@@ -72,6 +72,28 @@ export const Basic: Story<DropdownSelectorProps> = (
|
|
|
72
72
|
|
|
73
73
|
Basic.args = { ...baseProps }
|
|
74
74
|
|
|
75
|
+
export const InFormTag: Story<DropdownSelectorProps> = (
|
|
76
|
+
props: DropdownSelectorProps
|
|
77
|
+
) => {
|
|
78
|
+
const [selected, setSelected] = useState('')
|
|
79
|
+
return (
|
|
80
|
+
<form style={{ width: 288 }}>
|
|
81
|
+
<DropdownSelector
|
|
82
|
+
{...props}
|
|
83
|
+
onChange={(value) => {
|
|
84
|
+
setSelected(value)
|
|
85
|
+
}}
|
|
86
|
+
value={selected}
|
|
87
|
+
label="label"
|
|
88
|
+
>
|
|
89
|
+
<DropdownMenuItem value={'10'}>Apple</DropdownMenuItem>
|
|
90
|
+
<DropdownMenuItem value={'20'}>Banana</DropdownMenuItem>
|
|
91
|
+
<DropdownMenuItem value={'30'}>Orange</DropdownMenuItem>
|
|
92
|
+
</DropdownSelector>
|
|
93
|
+
</form>
|
|
94
|
+
)
|
|
95
|
+
}
|
|
96
|
+
|
|
75
97
|
export const CustomChildren: Story<DropdownSelectorProps> = (
|
|
76
98
|
props: DropdownSelectorProps
|
|
77
99
|
) => {
|
|
@@ -188,7 +188,7 @@ const ModalContext = React.createContext<{
|
|
|
188
188
|
|
|
189
189
|
const ModalBackground = animated(styled.div<{ zIndex: number }>`
|
|
190
190
|
z-index: ${({ zIndex }) => zIndex};
|
|
191
|
-
overflow:
|
|
191
|
+
overflow: auto;
|
|
192
192
|
display: flex;
|
|
193
193
|
position: fixed;
|
|
194
194
|
top: 0;
|
|
@@ -241,7 +241,6 @@ const ModalDialog = animated(styled.div<{
|
|
|
241
241
|
}>`
|
|
242
242
|
position: relative;
|
|
243
243
|
margin: auto;
|
|
244
|
-
padding: 24px 0;
|
|
245
244
|
|
|
246
245
|
${theme((o) => [o.bg.background1, o.borderRadius(24)])}
|
|
247
246
|
@media ${({ theme }) => maxWidth(theme.breakpoint.screen1)} {
|