-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[material-ui][Accordion] Deprecate *Props props and classes for v6 (#…
- Loading branch information
1 parent
d12b654
commit e6af147
Showing
14 changed files
with
650 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { SxProps } from '@mui/system'; | ||
import { SlotComponentProps } from '@mui/base'; | ||
|
||
export type SlotCommonProps = { | ||
component?: React.ElementType; | ||
sx?: SxProps; | ||
}; | ||
|
||
export type SlotProps< | ||
TSlotComponent extends React.ElementType, | ||
TOverrides, | ||
TOwnerState, | ||
> = SlotComponentProps<TSlotComponent, SlotCommonProps & TOverrides, TOwnerState>; | ||
|
||
/** | ||
* Use the keys of `Slots` to make sure that K contains all of the keys | ||
* | ||
* @example CreateSlotsAndSlotProps<{ root: React.ElementType, decorator: React.ElementType }, { root: ..., decorator: ... }> | ||
*/ | ||
export type CreateSlotsAndSlotProps<Slots, K extends Record<keyof Slots, any>> = { | ||
/** | ||
* The components used for each slot inside. | ||
* @default {} | ||
*/ | ||
slots?: Slots; | ||
/** | ||
* The props used for each slot inside. | ||
* @default {} | ||
*/ | ||
slotProps?: { | ||
[P in keyof K]?: K[P]; | ||
}; | ||
}; |
Oops, something went wrong.