Skip to content

Commit

Permalink
Allow BreakdownLabelSelector to clear other attributes / select attri…
Browse files Browse the repository at this point in the history
…bute select
  • Loading branch information
joey-grafana committed Apr 19, 2024
1 parent c559cbd commit 15aa86f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/components/Explore/BreakdownLabelSelector.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,17 +60,19 @@ export function BreakdownLabelSelector({ options, value, onChange }: Props) {
{...{ value }}
placeholder={'Other attributes'}
options={otherOptions}
onChange={(selected) => onChange(selected.value)}
onChange={(selected) => onChange(selected?.value ?? 'All')}
className={styles.select}
isClearable={true}
/>
</>
) : (
<Select
{...{ value }}
placeholder={'Select attribute'}
options={options}
onChange={(selected) => onChange(selected.value)}
onChange={(selected) => onChange(selected?.value ?? 'All')}
className={styles.select}
isClearable={true}
/>
)}
</div>
Expand Down

0 comments on commit 15aa86f

Please sign in to comment.