mirror of
https://github.com/elastic/kibana.git
synced 2025-06-28 03:01:21 -04:00
fix(slo): burn rate lookback window component (#166118)
This commit is contained in:
parent
6754699eed
commit
57f103613f
1 changed files with 14 additions and 18 deletions
|
@ -5,12 +5,12 @@
|
|||
* 2.0.
|
||||
*/
|
||||
|
||||
import { EuiFieldNumber, EuiFlexGroup, EuiFlexItem, EuiFormRow, EuiIconTip } from '@elastic/eui';
|
||||
import { EuiFieldNumber, EuiFormRow, EuiIconTip } from '@elastic/eui';
|
||||
import { i18n } from '@kbn/i18n';
|
||||
import React, { ChangeEvent, useState } from 'react';
|
||||
|
||||
import { toMinutes } from '../../utils/slo/duration';
|
||||
import { Duration } from '../../typings';
|
||||
import { toMinutes } from '../../utils/slo/duration';
|
||||
|
||||
interface Props {
|
||||
shortWindowDuration: Duration;
|
||||
|
@ -36,22 +36,18 @@ export function LongWindowDuration({
|
|||
|
||||
return (
|
||||
<EuiFormRow label={getRowLabel(shortWindowDuration)} fullWidth isInvalid={hasError}>
|
||||
<EuiFlexGroup direction="row">
|
||||
<EuiFlexItem>
|
||||
<EuiFieldNumber
|
||||
isInvalid={hasError}
|
||||
min={1}
|
||||
max={72}
|
||||
step={1}
|
||||
value={String(durationValue)}
|
||||
onChange={onDurationValueChange}
|
||||
aria-label={i18n.translate('xpack.observability.slo.rules.longWindow.valueLabel', {
|
||||
defaultMessage: 'Lookback period in hours',
|
||||
})}
|
||||
data-test-subj="durationValueInput"
|
||||
/>
|
||||
</EuiFlexItem>
|
||||
</EuiFlexGroup>
|
||||
<EuiFieldNumber
|
||||
isInvalid={hasError}
|
||||
min={1}
|
||||
max={72}
|
||||
step={1}
|
||||
value={String(durationValue)}
|
||||
onChange={onDurationValueChange}
|
||||
aria-label={i18n.translate('xpack.observability.slo.rules.longWindow.valueLabel', {
|
||||
defaultMessage: 'Lookback period in hours',
|
||||
})}
|
||||
data-test-subj="durationValueInput"
|
||||
/>
|
||||
</EuiFormRow>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue