[v9.4.x] Alerting: Show 'start typing' message in evaluation group folder in case of empty options. (#62665)
Alerting: Show 'start typing' message in evaluation group folder in case of empty options. (#62611)
Show start typing message in evaluation group folder in case of empty options
(cherry picked from commit c0865c863d)
Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
This commit is contained in:
co-authored by
Sonia Aguilar
parent
89f9081658
commit
68fb4da24a
@@ -1,11 +1,11 @@
|
||||
import { css } from '@emotion/css';
|
||||
import { debounce } from 'lodash';
|
||||
import React, { useState, useRef, useEffect, useCallback, useMemo } from 'react';
|
||||
import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { useFormContext } from 'react-hook-form';
|
||||
|
||||
import { GrafanaTheme2, SelectableValue } from '@grafana/data';
|
||||
import { Stack } from '@grafana/experimental';
|
||||
import { AsyncSelect, Field, InputControl, Label, useStyles2, LoadingPlaceholder } from '@grafana/ui';
|
||||
import { AsyncSelect, Field, InputControl, Label, LoadingPlaceholder, useStyles2 } from '@grafana/ui';
|
||||
import { FolderPickerFilter } from 'app/core/components/Select/FolderPicker';
|
||||
import { contextSrv } from 'app/core/core';
|
||||
import { DashboardSearchHit } from 'app/features/search/types';
|
||||
@@ -235,6 +235,7 @@ export function FolderAndGroup({ initialFolder }: FolderAndGroupProps) {
|
||||
value={selectedGroup}
|
||||
allowCustomValue
|
||||
formatCreateLabel={(_) => '+ Add new '}
|
||||
noOptionsMessage="Start typing to create evaluation group"
|
||||
/>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user