sanity-io / ui

UI building blocks for Sanity.
https://sanity.io/ui
MIT License
130 stars 19 forks source link

Content of popovers / dropdowns is not visible #1301

Open ryanleichty opened 5 months ago

ryanleichty commented 5 months ago

Describe the bug

Content of popovers / dropdowns is not visible.

To Reproduce

Steps to reproduce the behavior:

  1. Update @sanity/ui to 2.1.8
  2. Click on any element that has a popover / dropdown menu
  3. The content of the popover / dropdown does not appear
  4. The console displays the following warning
The component Styled(Component) with the id of "sc-hMxHxi" has been created dynamically.
You may see this warning because you've called styled inside another component.
To resolve this only create new StyledComponents outside of any render method and function component. 
    at li
    at AutocompleteOption (webpack-internal:///(app-pages-browser)/./node_modules/@sanity/ui/dist/index.mjs:4697:11)
...

Expected behavior

You should see the content of the popover / dropdown.

Screenshots If applicable, add screenshots to help explain your problem.

CleanShot 2024-05-16 at 21 51 03 2@2x

CleanShot 2024-05-16 at 21 51 13 2@2x

CleanShot 2024-05-16 at 21 51 20 2@2x

Which versions of Sanity are you using?

@sanity/cli (global) 3.41.1 (latest: 3.42.1) @sanity/icons 2.11.8 (up to date) @sanity/image-url 1.0.2 (up to date) @sanity/preview-url-secret 1.6.13 (up to date) @sanity/react-loader 1.9.19 (up to date) @sanity/ui 2.1.8 (latest: 2.1.10) @sanity/vision 3.42.1 (up to date) sanity 3.42.1 (up to date)

What operating system are you using?

macOS 14.4.1 (23E224)

Which versions of Node.js / npm are you running?

10.7.0 v20.11.0

Additional context

Add any other context about the problem here.

stipsan commented 5 months ago

Does it happen in v2.1.11?