import React, { PureComponent } from 'react'; import { InlineFormLabel, TextArea } from '@grafana/ui'; import InfluxDatasource from '../datasource'; import { FluxQueryEditor } from './FluxQueryEditor'; interface Props { query: string; // before flux, it was always a string onChange: (query?: string) => void; datasource: InfluxDatasource; } export default class VariableQueryEditor extends PureComponent { onRefresh = () => { // noop }; render() { let { query, datasource, onChange } = this.props; if (datasource.isFlux) { return ( onChange(v.query)} /> ); } return (
Query