Skip to content

Commit

Permalink
Add button props to select menu item
Browse files Browse the repository at this point in the history
  • Loading branch information
colebemis committed Apr 1, 2021
1 parent 1c7ea7f commit f66e4bc
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/SelectMenu/SelectMenuItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,13 @@ const StyledItem = styled.a.attrs(() => ({
${sx};
`

type SelectMenuItemInteralProps = {
type SelectMenuItemInternalProps = {
as?: React.ElementType
selected?: boolean
} & ComponentProps<typeof StyledItem>
} & ComponentProps<typeof StyledItem> &
React.ComponentProps<'button'>

const SelectMenuItem = forwardRef<HTMLAnchorElement, SelectMenuItemInteralProps>(
const SelectMenuItem = forwardRef<HTMLAnchorElement, SelectMenuItemInternalProps>(
({children, selected, theme, onClick, ...rest}, forwardedRef) => {
const menuContext = useContext(MenuContext)
const backupRef = useRef<HTMLAnchorElement>(null)
Expand Down

0 comments on commit f66e4bc

Please sign in to comment.