From 79fca7dce41fbaaf2e47f248aaf1dcb6fff34310 Mon Sep 17 00:00:00 2001 From: Tobias Skarhed <1438972+tskarhed@users.noreply.github.com> Date: Fri, 15 Dec 2023 10:29:34 +0100 Subject: [PATCH] Chore: Remove gf-form and change to CSS object in Graphite function editor (#79446) Chore: remove gf-form and add CSS fumction object --- .betterer.results | 3 --- .../datasource/graphite/components/FunctionEditor.tsx | 8 ++++---- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.betterer.results b/.betterer.results index bc541f1749a..3389c352d95 100644 --- a/.betterer.results +++ b/.betterer.results @@ -5152,9 +5152,6 @@ exports[`better eslint`] = { "public/app/plugins/datasource/graphite/components/AddGraphiteFunction.tsx:5381": [ [0, 0, 0, "Styles should be written using objects.", "0"] ], - "public/app/plugins/datasource/graphite/components/FunctionEditor.tsx:5381": [ - [0, 0, 0, "Styles should be written using objects.", "0"] - ], "public/app/plugins/datasource/graphite/components/FunctionParamEditor.tsx:5381": [ [0, 0, 0, "Styles should be written using objects.", "0"] ], diff --git a/public/app/plugins/datasource/graphite/components/FunctionEditor.tsx b/public/app/plugins/datasource/graphite/components/FunctionEditor.tsx index 1971664c446..44ced255c2d 100644 --- a/public/app/plugins/datasource/graphite/components/FunctionEditor.tsx +++ b/public/app/plugins/datasource/graphite/components/FunctionEditor.tsx @@ -14,12 +14,12 @@ interface FunctionEditorProps extends FunctionEditorControlsProps { const getStyles = (theme: GrafanaTheme2) => { return { - icon: css` - margin-right: ${theme.spacing(0.5)}; - `, + icon: css({ + marginRight: theme.spacing(0.5), + }), label: css({ fontWeight: theme.typography.fontWeightMedium, - fontSize: theme.typography.bodySmall.fontSize, // to match .gf-form-label + fontSize: theme.typography.bodySmall.fontSize, cursor: 'pointer', display: 'inline-block', }),