diff --git a/apps/www/app/(app)/examples/playground/components/model-selector.tsx b/apps/www/app/(app)/examples/playground/components/model-selector.tsx index 6eefef49459..98cffaf6129 100644 --- a/apps/www/app/(app)/examples/playground/components/model-selector.tsx +++ b/apps/www/app/(app)/examples/playground/components/model-selector.tsx @@ -149,7 +149,7 @@ function ModelItem({ model, isSelected, onSelect, onPeek }: ModelItemProps) { key={model.id} onSelect={onSelect} ref={ref} - className="aria-selected:bg-primary aria-selected:text-primary-foreground" + className="data-[selected=true]:bg-primary data-[selected=true]:text-primary-foreground" > {model.name} No framework found. - - {frameworks.map((framework) => ( - { - setValue(currentValue === value ? "" : currentValue) - setOpen(false) - }} - > - - {framework.label} - - ))} - + + + {frameworks.map((framework) => ( + { + setValue(currentValue === value ? "" : currentValue) + setOpen(false) + }} + > + + {framework.label} + + ))} + + diff --git a/apps/www/package.json b/apps/www/package.json index 73aa4006916..7cb12382c6b 100644 --- a/apps/www/package.json +++ b/apps/www/package.json @@ -52,7 +52,7 @@ "@vercel/og": "^0.0.21", "class-variance-authority": "^0.7.0", "clsx": "^1.2.1", - "cmdk": "^0.2.0", + "cmdk": "^1.0.0", "contentlayer": "0.3.4", "date-fns": "^2.30.0", "embla-carousel-autoplay": "8.0.0-rc15", diff --git a/apps/www/registry/default/example/combobox-demo.tsx b/apps/www/registry/default/example/combobox-demo.tsx index b16ad8fd7b5..3fa75499dc6 100644 --- a/apps/www/registry/default/example/combobox-demo.tsx +++ b/apps/www/registry/default/example/combobox-demo.tsx @@ -11,6 +11,7 @@ import { CommandGroup, CommandInput, CommandItem, + CommandList, } from "@/registry/default/ui/command" import { Popover, @@ -64,26 +65,28 @@ export default function ComboboxDemo() { No framework found. - - {frameworks.map((framework) => ( - { - setValue(currentValue === value ? "" : currentValue) - setOpen(false) - }} - > - - {framework.label} - - ))} - + + + {frameworks.map((framework) => ( + { + setValue(currentValue === value ? "" : currentValue) + setOpen(false) + }} + > + + {framework.label} + + ))} + + diff --git a/apps/www/registry/default/ui/command.tsx b/apps/www/registry/default/ui/command.tsx index 40f34c13c6a..870be1f959c 100644 --- a/apps/www/registry/default/ui/command.tsx +++ b/apps/www/registry/default/ui/command.tsx @@ -117,7 +117,7 @@ const CommandItem = React.forwardRef< No framework found. - - {frameworks.map((framework) => ( - { - setValue(currentValue === value ? "" : currentValue) - setOpen(false) - }} - > - {framework.label} - - - ))} - + + + {frameworks.map((framework) => ( + { + setValue(currentValue === value ? "" : currentValue) + setOpen(false) + }} + > + {framework.label} + + + ))} + + diff --git a/apps/www/registry/new-york/ui/command.tsx b/apps/www/registry/new-york/ui/command.tsx index 286b2b5eb5c..e9de195b0ab 100644 --- a/apps/www/registry/new-york/ui/command.tsx +++ b/apps/www/registry/new-york/ui/command.tsx @@ -117,7 +117,7 @@ const CommandItem = React.forwardRef< =6'} dev: false - /cmdk@0.2.0(@types/react@18.2.65)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-JQpKvEOb86SnvMZbYaFKYhvzFntWBeSZdyii0rZPhKJj9uwJBxu4DaVYDrRN7r3mPop56oPhRw+JYWTKs66TYw==} + /cmdk@1.0.0(@types/react-dom@18.2.22)(@types/react@18.2.65)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-gDzVf0a09TvoJ5jnuPvygTB77+XdOSwEmJ88L6XPFPlv7T3RxbP9jgenfylrAMD0+Le1aO0nVjQUzl2g+vjz5Q==} peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 dependencies: - '@radix-ui/react-dialog': 1.0.0(@types/react@18.2.65)(react-dom@18.2.0)(react@18.2.0) - command-score: 0.1.2 + '@radix-ui/react-dialog': 1.0.5(@types/react-dom@18.2.22)(@types/react@18.2.65)(react-dom@18.2.0)(react@18.2.0) + '@radix-ui/react-primitive': 1.0.3(@types/react-dom@18.2.22)(@types/react@18.2.65)(react-dom@18.2.0)(react@18.2.0) react: 18.2.0 react-dom: 18.2.0(react@18.2.0) transitivePeerDependencies: - '@types/react' + - '@types/react-dom' dev: false /code-block-writer@12.0.0: @@ -5418,10 +5268,6 @@ packages: /comma-separated-tokens@2.0.3: resolution: {integrity: sha512-Fu4hJdvzeylCfQPp9SGWidpzrMs7tTrlu6Vb8XGaRGck8QSNZJJp538Wrb60Lax4fPwR64ViY468OIUTbRlGZg==} - /command-score@0.1.2: - resolution: {integrity: sha512-VtDvQpIJBvBatnONUsPzXYFVKQQAhuf3XTNOAsdBxCNO/QCtUUd8LSgjn0GVarBkCad6aJCZfXgrjYbl/KRr7w==} - dev: false - /commander@10.0.0: resolution: {integrity: sha512-zS5PnTI22FIRM6ylNW8G4Ap0IEOyk62fhLSD0+uHRT9McRCLGpkVNvao4bjimpK/GShynyQkFFxHhwMcETmduA==} engines: {node: '>=14'} @@ -9848,25 +9694,6 @@ packages: tslib: 2.5.2 dev: false - /react-remove-scroll@2.5.4(@types/react@18.2.65)(react@18.2.0): - resolution: {integrity: sha512-xGVKJJr0SJGQVirVFAUZ2k1QLyO6m+2fy0l8Qawbp5Jgrv3DeLalrfMNBFSlmz5kriGGzsVBtGVnf4pTKIhhWA==} - engines: {node: '>=10'} - peerDependencies: - '@types/react': ^16.8.0 || ^17.0.0 || ^18.0.0 - react: ^16.8.0 || ^17.0.0 || ^18.0.0 - peerDependenciesMeta: - '@types/react': - optional: true - dependencies: - '@types/react': 18.2.65 - react: 18.2.0 - react-remove-scroll-bar: 2.3.4(@types/react@18.2.65)(react@18.2.0) - react-style-singleton: 2.2.1(@types/react@18.2.65)(react@18.2.0) - tslib: 2.6.0 - use-callback-ref: 1.3.0(@types/react@18.2.65)(react@18.2.0) - use-sidecar: 1.1.2(@types/react@18.2.65)(react@18.2.0) - dev: false - /react-remove-scroll@2.5.5(@types/react@18.2.65)(react@18.2.0): resolution: {integrity: sha512-ImKhrzJJsyXJfBZ4bzu8Bwpka14c/fQt0k+cyFp/PBhTfyDnU5hjOtM4AG/0AMyy8oKzOTR0lDgJIM7pYXI0kw==} engines: {node: '>=10'}