mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Chore: reduce strict errors for variables (#31241)
* Chore: reduces a lot of variable errors * Chore: reduces variable Editor errors * Chore: reduces variable Picker errors * Chore: reduce error count * Chore: reduces errors for ChangeEvent instead of FormEvent * Chore: reduces errors with CombinedState * Chore: reduces ComponentType errors * Chore: reduce errors in reducers * Chore: reduces misc errors * Chore: reduce AdhocPicker errors * Chore: reduce error limit * Update public/app/features/variables/adhoc/picker/AdHocFilterValue.tsx Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com> * Chore: updates after PR comments * Chore: small refactor Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import React, { ChangeEvent, FocusEvent, PureComponent } from 'react';
|
||||
import React, { FormEvent, PureComponent } from 'react';
|
||||
import { CustomVariableModel, VariableWithMultiSupport } from '../types';
|
||||
import { SelectionOptionsEditor } from '../editor/SelectionOptionsEditor';
|
||||
import { OnPropChangeArguments, VariableEditorProps } from '../editor/types';
|
||||
@@ -21,10 +21,10 @@ interface DispatchProps {
|
||||
export type Props = OwnProps & ConnectedProps & DispatchProps;
|
||||
|
||||
class CustomVariableEditorUnconnected extends PureComponent<Props> {
|
||||
onChange = (event: ChangeEvent<HTMLTextAreaElement>) => {
|
||||
onChange = (event: FormEvent<HTMLTextAreaElement>) => {
|
||||
this.props.onPropChange({
|
||||
propName: 'query',
|
||||
propValue: event.target.value,
|
||||
propValue: event.currentTarget.value,
|
||||
});
|
||||
};
|
||||
|
||||
@@ -32,10 +32,10 @@ class CustomVariableEditorUnconnected extends PureComponent<Props> {
|
||||
this.props.onPropChange({ propName, propValue, updateOptions: true });
|
||||
};
|
||||
|
||||
onBlur = (event: FocusEvent<HTMLTextAreaElement>) => {
|
||||
onBlur = (event: FormEvent<HTMLTextAreaElement>) => {
|
||||
this.props.onPropChange({
|
||||
propName: 'query',
|
||||
propValue: event.target.value,
|
||||
propValue: event.currentTarget.value,
|
||||
updateOptions: true,
|
||||
});
|
||||
};
|
||||
|
Reference in New Issue
Block a user