Skip to content

Commit

Permalink
Prettier and fix import name
Browse files Browse the repository at this point in the history
  • Loading branch information
MBilalShafi committed Aug 22, 2024
1 parent ef21ca8 commit b9f5292
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
4 changes: 2 additions & 2 deletions packages/x-data-grid/src/hooks/utils/useGridSelector.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react';
import { fastObjectShallowCompare } from '@mui/x-internals/fastObjectShallowCompare';
import type { GridApiCommon } from '../../models/api/gridApiCommon';
import { OutputSelector, OutputArgumentsSelector } from '../../utils/createSelector';
import { OutputSelector, OutputSelectorV8 } from '../../utils/createSelector';
import { useLazyRef } from './useLazyRef';
import { useOnMount } from './useOnMount';
import { warnOnce } from '../../internals/utils/warning';
Expand All @@ -15,7 +15,7 @@ function isOutputSelector<Api extends GridApiCommon, T>(

type Selector<Api extends GridApiCommon, Args, T> =
| ((state: Api['state']) => T)
| OutputArgumentsSelector<Api['state'], Args, T>;
| OutputSelectorV8<Api['state'], Args, T>;

// TODO v8: Remove this function
function applySelector<Api extends GridApiCommon, T>(
Expand Down
6 changes: 1 addition & 5 deletions packages/x-data-grid/src/utils/createSelector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,7 @@ type CreateSelectorFunction = <Selectors extends ReadonlyArray<Selector<any>>, R
) => OutputSelector<StateFromSelectorList<Selectors>, Result>;

// TODO v8: Rename this type to `CreateSelectorFunction`
type CreateSelectorFunctionV8 = <
Selectors extends ReadonlyArray<Selector<any>>,
Args,
Result,
>(
type CreateSelectorFunctionV8 = <Selectors extends ReadonlyArray<Selector<any>>, Args, Result>(
...items: SelectorArgsV8<Selectors, Args, Result>
) => OutputSelectorV8<StateFromSelectorList<Selectors>, Args, Result>;

Expand Down

0 comments on commit b9f5292

Please sign in to comment.