From 4ce8fff98af348efb5663fd5d34f15b272fab13e Mon Sep 17 00:00:00 2001 From: Ben Sully Date: Fri, 25 Aug 2023 14:59:38 +0100 Subject: [PATCH] Fix Grafana ML icon (#73813) `grafana-ml` was added to the `availableIconsIndex` object in but no corresponding SVG was added, nor was the Icon bundle updated. This commit adds the real Grafana ML icon as gf-ml.svg, renames the key in the availableIconsIndex accordingly, and updates the Icon bundle using the documented script. Note that the name was changed to `gf-ml` rather than `grafana-ml` because otherwise the wrong directory is used (unicons rather than custom). The main motivation for adding this is because plugin extensions need to specify a valid icon name, and we want to use the Grafana ML icon for our extensions, which requires the icon to be part of core Grafana. --- packages/grafana-data/src/types/icon.ts | 2 +- public/img/icons/custom/gf-ml.svg | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 public/img/icons/custom/gf-ml.svg diff --git a/packages/grafana-data/src/types/icon.ts b/packages/grafana-data/src/types/icon.ts index 3a9c6c891c4..82dc4feb381 100644 --- a/packages/grafana-data/src/types/icon.ts +++ b/packages/grafana-data/src/types/icon.ts @@ -119,6 +119,7 @@ export const availableIconsIndex = { 'gf-landscape': true, 'gf-layout-simple': true, 'gf-logs': true, + 'gf-ml': true, 'gf-movepane-left': true, 'gf-movepane-right': true, 'gf-portrait': true, @@ -129,7 +130,6 @@ export const availableIconsIndex = { 'gf-traces': true, grafana: true, 'graph-bar': true, - 'grafana-ml': true, heart: true, 'heart-rate': true, 'heart-break': true, diff --git a/public/img/icons/custom/gf-ml.svg b/public/img/icons/custom/gf-ml.svg new file mode 100644 index 00000000000..3ebe54581e7 --- /dev/null +++ b/public/img/icons/custom/gf-ml.svg @@ -0,0 +1 @@ + \ No newline at end of file