-
Notifications
You must be signed in to change notification settings - Fork 41
Open
Labels
bugSomething isn't workingSomething isn't working
Description
- Using combobox property in vscode-multi-select
- 2 options are pre-selected (Afghanistan, Albania)
- In the searchbox, only the one option is being displayed.
- Even user de-selects all the options, still the value doesn't disappear.
Expected Behaviour
- None of the selected option should be displayed in the search input OR all the selected options should be displayed
Using vscode-elements - v2.3.0
Sample Code (React + vite) -
import "@vscode-elements/elements/dist/vscode-multi-select";
import "@vscode-elements/elements/dist/vscode-option";
function App() {
const countries = [
{ name: "Afghanistan", selected: true },
{ name: "Albania", selected: true },
{ name: "Algeria", selected: false },
];
return (
<>
<p> Sample vscode-elem</p>
<vscode-multi-select id="combobox-example" combobox>
{countries.map((country) => (
<vscode-option key={country.name} selected={country.selected}>
{country.name}
</vscode-option>
))}
</vscode-multi-select>
</>
);
}
export default App;
Also, could you please let me know if there's a way to identify whether an option is selected or deselected, and capture its value accordingly.
costinsin
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
