primitives
primitives copied to clipboard
[New Primitive] `CommandPalette`
Feature request
Overview
Having a set of primitives to build a Command Palette component would be great so that developers can spend less time researching and implementing third-party solutions, and end-users can enjoy a superior user experience.
Examples in other libraries
Other inspiring examples are:
- Spotlight
- GitHub's command palette
- Vercel's command palette
- Tailwind's command palette
- Linear's command palette
Who does this impact? Who is this for?
This is for all of us. It's a new primitive! 🍬
Additional context
I'd be happy to collaborate on this.
Let's discuss what features we want to support and how the API would look like. It would be also worth to describe use cases.
This is largely the same as #1342 but perhaps with extra functionality given it opens in a dialog, with a global shortcut, etc Feels like we should build this only after #1342 is done.
Another amazing example of a Command Palette is the Raycast macOS app. It's a desktop app but it has a lot of complex features that would probably be desirable and worth considering in a Command Palette component, they also highlight how different a Command Palette component could be from a simple Combobox. Here are some highlights:
The use-case for some features (I'm thinking about the Complex Layouts for instance) may be less applicable to the web platform, but it might be worth exploring and discussing at some point.
Another example is https://github.com/pacocoursey/cmdk
I have just found this (https://www.commandpalette.org)! Very useful. I'll add it to the description.