1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

make namespace filter multi select and change onChange (#987)

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton 2020-09-28 10:30:23 -04:00 committed by GitHub
parent bc228c9e36
commit 34e141e517
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -91,7 +91,8 @@ export class NamespaceSelectFilter extends React.Component {
closeMenuOnSelect={false} closeMenuOnSelect={false}
isOptionSelected={() => false} isOptionSelected={() => false}
controlShouldRenderValue={false} controlShouldRenderValue={false}
onChange={({ value: namespace }: SelectOption) => toggleContext(namespace)} isMulti
onChange={([{ value }]: SelectOption[]) => toggleContext(value)}
formatOptionLabel={({ value: namespace }: SelectOption) => { formatOptionLabel={({ value: namespace }: SelectOption) => {
const isSelected = hasContext(namespace); const isSelected = hasContext(namespace);
return ( return (