From bac9253fdcef789185b6acf17139d6b6f449b9f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Jamr=C3=B3z?= Date: Wed, 5 Jan 2022 19:28:28 +0100 Subject: [PATCH] A11y: Fix a11y issues in OpenTSDB (#43714) * Fix a11y issues in OpenTSDB configuration page * Fix a11y issues in OpenTSDB editor * Link labels to inputs where possible Co-authored-by: kay delaney --- .../opentsdb/components/OpenTsdbDetails.tsx | 18 +++++++++++++++--- .../opentsdb/partials/query.editor.html | 8 +++++--- 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/public/app/plugins/datasource/opentsdb/components/OpenTsdbDetails.tsx b/public/app/plugins/datasource/opentsdb/components/OpenTsdbDetails.tsx index f14848e20cf..e91ab6eb329 100644 --- a/public/app/plugins/datasource/opentsdb/components/OpenTsdbDetails.tsx +++ b/public/app/plugins/datasource/opentsdb/components/OpenTsdbDetails.tsx @@ -3,6 +3,7 @@ import { InlineFormLabel, LegacyForms } from '@grafana/ui'; const { Select, Input } = LegacyForms; import { DataSourceSettings, SelectableValue } from '@grafana/data'; import { OpenTsdbOptions } from '../types'; +import { useUniqueId } from '../../influxdb/components/useUniqueId'; const tsdbVersions = [ { label: '<=2.1', value: 1 }, @@ -23,12 +24,17 @@ interface Props { export const OpenTsdbDetails = (props: Props) => { const { onChange, value } = props; + const idSuffix = useUniqueId(); + return ( <>
OpenTSDB settings
- Version + + Version + { />
- Lookup limit + + Lookup limit +
- @@ -62,9 +63,10 @@
-