File tree Expand file tree Collapse file tree 1 file changed +5
-17
lines changed
Expand file tree Collapse file tree 1 file changed +5
-17
lines changed Original file line number Diff line number Diff line change @@ -32,26 +32,14 @@ import { PALETTE } from "@/theme/palette"
3232import { TYPOGRAPHY } from "@/theme/typography"
3333import { lh , pxToRem } from "@/theme/units"
3434
35- type GridSortIconProps = React . ComponentProps < typeof SvgIcon > & {
36- sortingOrder ?: unknown
37- }
38-
3935const createGridSortIcon = (
40- IconComponent : React . ComponentType < React . SVGProps < SVGElement > > ,
36+ IconComponent : React . FC < React . SVGProps < SVGElement > > ,
4137 displayName : string ,
4238) => {
43- const GridSortIcon = React . forwardRef < SVGSVGElement , GridSortIconProps > (
44- ( props , ref ) => {
45- const iconProps = { ...props }
46- delete iconProps . sortingOrder
47-
48- return (
49- < SvgIcon ref = { ref } inheritViewBox { ...iconProps } >
50- < IconComponent />
51- </ SvgIcon >
52- )
53- } ,
54- )
39+ const GridSortIcon = React . forwardRef <
40+ SVGElement ,
41+ React . SVGProps < SVGElement > & { sortingOrder ?: unknown }
42+ > ( ( { sortingOrder, ...props } , ref ) => < IconComponent ref = { ref } { ...props } /> )
5543
5644 GridSortIcon . displayName = displayName
5745
You can’t perform that action at this time.
0 commit comments