File tree Expand file tree Collapse file tree
packages/ra-ui-materialui/src/button Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -73,12 +73,13 @@ const sanitizeRestProps = ({
7373} : Omit < CloneButtonProps , 'label' | 'scrollToTop' | 'icon' > ) => rest ;
7474
7575interface Props {
76+ resource ?: string ;
7677 record ?: any ;
7778 icon ?: ReactNode ;
7879 scrollToTop ?: boolean ;
7980}
8081
81- export type CloneButtonProps = Props & ButtonProps ;
82+ export type CloneButtonProps = Props & Omit < ButtonProps < typeof LinkBase > , 'to' > ;
8283
8384export default memo ( CloneButton ) ;
8485
Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ interface Props<RecordType extends RaRecord = any> {
122122}
123123
124124export type EditButtonProps < RecordType extends RaRecord = any > =
125- Props < RecordType > & ButtonProps ;
125+ Props < RecordType > & Omit < ButtonProps < typeof LinkBase > , 'to' > ;
126126
127127const PREFIX = 'RaEditButton' ;
128128
Original file line number Diff line number Diff line change @@ -115,7 +115,7 @@ interface Props {
115115 scrollToTop ?: boolean ;
116116}
117117
118- export type ListButtonProps = Props & ButtonProps ;
118+ export type ListButtonProps = Props & Omit < ButtonProps < typeof LinkBase > , 'to' > ;
119119
120120const PREFIX = 'RaListButton' ;
121121
You can’t perform that action at this time.
0 commit comments