diff --git a/packages/grafana-ui/src/components/Select/SelectBase.tsx b/packages/grafana-ui/src/components/Select/SelectBase.tsx index 73853d84a36..995098d7448 100644 --- a/packages/grafana-ui/src/components/Select/SelectBase.tsx +++ b/packages/grafana-ui/src/components/Select/SelectBase.tsx @@ -186,7 +186,7 @@ export function SelectBase({ const selectableValue = findSelectedValue(v.value ?? v, options); // If the select allows custom values there likely won't be a selectableValue in options // so we must return a new selectableValue - if (!allowCustomValue || selectableValue) { + if (selectableValue) { return selectableValue; } return typeof v === 'string' ? toOption(v) : v; diff --git a/public/app/features/alerting/unified/AlertGroups.test.tsx b/public/app/features/alerting/unified/AlertGroups.test.tsx index 23a848d50f0..45066ea5de7 100644 --- a/public/app/features/alerting/unified/AlertGroups.test.tsx +++ b/public/app/features/alerting/unified/AlertGroups.test.tsx @@ -189,6 +189,8 @@ describe('AlertGroups', () => { renderAmNotifications(); await waitForElementToBeRemoved(ui.loadingIndicator.query()); + // reset the input of the MultiSelect component + await user.type(ui.groupByInput.get(), '{backspace}'); await user.type(ui.groupByInput.get(), 'appName{enter}'); const groups = await ui.group.findAll();