File tree Expand file tree Collapse file tree 2 files changed +10
-12
lines changed Expand file tree Collapse file tree 2 files changed +10
-12
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " react-share " : patch
3+ ---
4+
5+ Fixed ` createIcon ` defaultProps warning with React 18.
Original file line number Diff line number Diff line change @@ -17,11 +17,11 @@ type IconConfig = {
1717
1818export default function createIcon ( iconConfig : IconConfig ) {
1919 const Icon : React . FC < Props > = ( {
20- bgStyle,
21- borderRadius,
22- iconFillColor,
23- round,
24- size,
20+ bgStyle = { } ,
21+ borderRadius = 0 ,
22+ iconFillColor = 'white' ,
23+ round = false ,
24+ size = 64 ,
2525 ...rest
2626 } ) => (
2727 < svg viewBox = "0 0 64 64" width = { size } height = { size } { ...rest } >
@@ -42,12 +42,5 @@ export default function createIcon(iconConfig: IconConfig) {
4242 </ svg >
4343 ) ;
4444
45- Icon . defaultProps = {
46- bgStyle : { } ,
47- borderRadius : 0 ,
48- iconFillColor : 'white' ,
49- size : 64 ,
50- } ;
51-
5245 return Icon ;
5346}
You can’t perform that action at this time.
0 commit comments