shadcn-ui / ui

Beautifully designed components that you can copy and paste into your apps. Accessible. Customizable. Open Source.
https://ui.shadcn.com
MIT License
65.19k stars 3.74k forks source link

[bug]: shadcn/ui web page breaks when using combobox #4176

Open KPI01 opened 3 weeks ago

KPI01 commented 3 weeks ago

Describe the bug

This is an issue that I've found on the web page of the library, I was seeing the "combobox" component and using the different examples. When I reached the "Form" section it prompted a client-side error.

This isn't a problem that affects the use of the framework, but I guess it usefull to have the web page working correctly

Affected component/components

Combobox

How to reproduce

  1. Go to the web page
  2. Access the combobox component
  3. Go to the "Form" example
  4. Click on the component

Codesandbox/StackBlitz link

No response

Logs

97525-01e51dd4c392194a.js:1 TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator))
    at Function.from (<anonymous>)
    at O (69016-e46275a046c77977.js:1:8485)
    at M (69016-e46275a046c77977.js:1:7484)
    at 69016-e46275a046c77977.js:1:6256
    at 69016-e46275a046c77977.js:1:14852
    at Map.forEach (<anonymous>)
    at 69016-e46275a046c77977.js:1:14841
    at aI (eb2a38ac-8c1a930f3b668d8a.js:1:72883)
    at aU (eb2a38ac-8c1a930f3b668d8a.js:1:72943)
    at aV (eb2a38ac-8c1a930f3b668d8a.js:1:73382)
window.console.error @ 97525-01e51dd4c392194a.js:1

System Info

Brave browser
Version 1.67.123 Chromium: 126.0.6478.126 (Build oficial) (64 bits)

Also tried with

Firefox
127.0.2 (64-bit)

Before submitting

chaytan5 commented 3 weeks ago

You should wrap the items in command component with CommandList component.

RustamovRR commented 3 weeks ago

https://github.com/shadcn-ui/ui/pull/4178

KPI01 commented 2 weeks ago

4178

I guess this means that it is known, my intention wasn't to use the component (at least for the moment) but I think it was worth to mention because I don't know if it is actually a problem with the component or just a bug on the web page