MCPcopy Create free account
hub / github.com/sourcebot-dev/sourcebot / toggleAll

Function toggleAll

packages/web/src/components/ui/multi-select.tsx:183–191  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

181 };
182
183 const toggleAll = () => {
184 if (selectedValues.length === options.length) {
185 handleClear();
186 } else {
187 const allValues = options.map((option) => option.value);
188 setSelectedValues(allValues);
189 onValueChange(allValues);
190 }
191 };
192
193 return (
194 <Popover

Callers

nothing calls this directly

Calls 1

handleClearFunction · 0.70

Tested by

no test coverage detected