Skip to content

Commit

Permalink
fix(ui): Reoreding filters (argoproj#44)
Browse files Browse the repository at this point in the history
* fix(ui): Reoreding filters

* fix
  • Loading branch information
rpelczar authored and alexmt committed May 20, 2024
1 parent 0302d0b commit 11337f1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {ComparisonStatusIcon, HealthStatusIcon} from '../utils';
const optionsFrom = (options: string[], filter: string[]) => {
return options
.filter(s => filter.indexOf(s) === -1)
.sort((a, b) => a.localeCompare(b))
.map(item => {
return {label: item};
});
Expand Down Expand Up @@ -60,7 +61,7 @@ const LabelsFilter = (props: AppFilterProps) => {
suggestions.push(labelStats.key);
labelStats.values.forEach(val => suggestions.push(`${labelStats.key}=${val}`));
});
const labelOptions = suggestions.map(s => {
const labelOptions = suggestions.sort((a, b) => a.localeCompare(b)).map(s => {
return {label: s};
});

Expand Down

0 comments on commit 11337f1

Please sign in to comment.