baseweb icon indicating copy to clipboard operation
baseweb copied to clipboard

Star rating Item forward refs error

Open alessandrotesoro opened this issue 4 years ago • 1 comments

Hi there,

I need to replace the svg icon used by the star rating component with a custom one however, when doing so via the overrides, the following error pops up in the console:

Warning: Function components cannot be given refs. Attempts to access this ref will fail. Did you mean to use React.forwardRef()?

See the issue here https://codesandbox.io/s/base-web-starrating-forked-w3d9n?file=/src/example.js

Current Behavior

Overriding the Item property causes the error mentioned above.

Expected Behavior

No error should appear.

Your Environment

Tech Version
Base UI v10.5.0
  • [x] I have searched the issues of this repository and believe that this is not a duplicate.

alessandrotesoro avatar Jan 05 '22 16:01 alessandrotesoro

I am experiencing the same error when overriding the DropdownListItem property of the Select component.

alexandreabeh avatar Mar 25 '22 23:03 alexandreabeh