mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
TagsInput: Prevent adding duplicate tags + refactor, restyle (#56485)
This commit is contained in:
@@ -101,7 +101,7 @@ export function GeneralSettingsUnconnected({
|
||||
<Input id="description-input" name="description" onBlur={onBlur} defaultValue={dashboard.description} />
|
||||
</Field>
|
||||
<Field label="Tags">
|
||||
<TagsInput id="tags-input" tags={dashboard.tags} onChange={onTagsChange} />
|
||||
<TagsInput id="tags-input" tags={dashboard.tags} onChange={onTagsChange} width={40} />
|
||||
</Field>
|
||||
<Field label="Folder">
|
||||
<FolderPicker
|
||||
|
||||
@@ -94,7 +94,7 @@ export const LinkSettingsEdit: React.FC<LinkSettingsEditProps> = ({ editLinkIdx,
|
||||
{linkSettings.type === 'dashboards' && (
|
||||
<>
|
||||
<Field label="With tags">
|
||||
<TagsInput tags={linkSettings.tags} placeholder="add tags" onChange={onTagsChange} />
|
||||
<TagsInput tags={linkSettings.tags} onChange={onTagsChange} />
|
||||
</Field>
|
||||
</>
|
||||
)}
|
||||
|
||||
@@ -49,7 +49,7 @@ export const AnnotationEditor = (props: QueryEditorProps<GraphiteDatasource, Gra
|
||||
|
||||
<div className="gf-form">
|
||||
<InlineFormLabel width={12}>Graphite events tags</InlineFormLabel>
|
||||
<TagsInput id="tags-input" tags={tags} onChange={onTagsChange} placeholder="Example: event_tag" />
|
||||
<TagsInput id="tags-input" width={50} tags={tags} onChange={onTagsChange} placeholder="Example: event_tag" />
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user