Skip to content

Commit b6ecabf

Browse files
committed
chore(ra-ui-materialui): omit to from link button props
1 parent 0b7d80e commit b6ecabf

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

packages/ra-ui-materialui/src/button/CloneButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ interface Props {
7979
scrollToTop?: boolean;
8080
}
8181

82-
export type CloneButtonProps = Props & ButtonProps<typeof LinkBase>;
82+
export type CloneButtonProps = Props & Omit<ButtonProps<typeof LinkBase>, 'to'>;
8383

8484
export default memo(CloneButton);
8585

packages/ra-ui-materialui/src/button/EditButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ interface Props<RecordType extends RaRecord = any> {
122122
}
123123

124124
export type EditButtonProps<RecordType extends RaRecord = any> =
125-
Props<RecordType> & ButtonProps<typeof LinkBase>;
125+
Props<RecordType> & Omit<ButtonProps<typeof LinkBase>, 'to'>;
126126

127127
const PREFIX = 'RaEditButton';
128128

packages/ra-ui-materialui/src/button/ListButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ interface Props {
115115
scrollToTop?: boolean;
116116
}
117117

118-
export type ListButtonProps = Props & ButtonProps<typeof LinkBase>;
118+
export type ListButtonProps = Props & Omit<ButtonProps<typeof LinkBase>, 'to'>;
119119

120120
const PREFIX = 'RaListButton';
121121

0 commit comments

Comments
 (0)