mirror of
https://github.com/grafana/grafana.git
synced 2025-02-14 01:23:32 -06:00
A11y: Fix prometheus issues (#42671)
This commit is contained in:
parent
698f452e0d
commit
8722c19cc3
@ -101,6 +101,7 @@ export class Select<T> extends PureComponent<LegacySelectProps<T>> {
|
|||||||
onOpenMenu,
|
onOpenMenu,
|
||||||
allowCustomValue,
|
allowCustomValue,
|
||||||
formatCreateLabel,
|
formatCreateLabel,
|
||||||
|
'aria-label': ariaLabel,
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
let widthClass = '';
|
let widthClass = '';
|
||||||
@ -151,6 +152,7 @@ export class Select<T> extends PureComponent<LegacySelectProps<T>> {
|
|||||||
onMenuOpen={onOpenMenuInternal}
|
onMenuOpen={onOpenMenuInternal}
|
||||||
onMenuClose={onCloseMenuInternal}
|
onMenuClose={onCloseMenuInternal}
|
||||||
tabSelectsValue={tabSelectsValue}
|
tabSelectsValue={tabSelectsValue}
|
||||||
|
aria-label={ariaLabel}
|
||||||
{...creatableOptions}
|
{...creatableOptions}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
@ -161,6 +161,7 @@ export class PromQueryEditor extends PureComponent<PromQueryEditorProps, State>
|
|||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
className="gf-form-input width-8"
|
className="gf-form-input width-8"
|
||||||
|
aria-label="Set lower limit for the step parameter"
|
||||||
placeholder={interval}
|
placeholder={interval}
|
||||||
onChange={this.onIntervalChange}
|
onChange={this.onIntervalChange}
|
||||||
onBlur={this.onRunQuery}
|
onBlur={this.onRunQuery}
|
||||||
@ -171,6 +172,7 @@ export class PromQueryEditor extends PureComponent<PromQueryEditorProps, State>
|
|||||||
<div className="gf-form">
|
<div className="gf-form">
|
||||||
<div className="gf-form-label">Resolution</div>
|
<div className="gf-form-label">Resolution</div>
|
||||||
<Select
|
<Select
|
||||||
|
aria-label="Select resolution"
|
||||||
menuShouldPortal
|
menuShouldPortal
|
||||||
isSearchable={false}
|
isSearchable={false}
|
||||||
options={INTERVAL_FACTOR_OPTIONS}
|
options={INTERVAL_FACTOR_OPTIONS}
|
||||||
@ -189,6 +191,7 @@ export class PromQueryEditor extends PureComponent<PromQueryEditorProps, State>
|
|||||||
options={FORMAT_OPTIONS}
|
options={FORMAT_OPTIONS}
|
||||||
onChange={this.onFormatChange}
|
onChange={this.onFormatChange}
|
||||||
value={formatOption}
|
value={formatOption}
|
||||||
|
aria-label="Select format"
|
||||||
/>
|
/>
|
||||||
<Switch label="Instant" checked={instant} onChange={this.onInstantChange} />
|
<Switch label="Instant" checked={instant} onChange={this.onInstantChange} />
|
||||||
|
|
||||||
|
@ -75,6 +75,7 @@ export const PromSettings = (props: Props) => {
|
|||||||
HTTP Method
|
HTTP Method
|
||||||
</InlineFormLabel>
|
</InlineFormLabel>
|
||||||
<Select
|
<Select
|
||||||
|
aria-label="Select HTTP method"
|
||||||
menuShouldPortal
|
menuShouldPortal
|
||||||
options={httpOptions}
|
options={httpOptions}
|
||||||
value={httpOptions.find((o) => o.value === options.jsonData.httpMethod)}
|
value={httpOptions.find((o) => o.value === options.jsonData.httpMethod)}
|
||||||
|
Loading…
Reference in New Issue
Block a user