Reproduce:
If you use reflected component as a children for Radix UI component with asChild prop you will get this error:
Warning: Function components cannot be given refs. Attempts to access this ref will fail. Did you mean to use React.forwardRef()?
I think the reason for this error is that the reflected components are not wrapped with forwardRef