Select: Changes default menu placement for Select from auto to bottom (#29837)

* Select: Changes default menuPlacement from auto to bottom

* Tests: Fixes snapshot
This commit is contained in:
Hugo Häggmark
2020-12-15 12:46:31 +01:00
committed by GitHub
parent b1a57c6f77
commit 5f4b528122
13 changed files with 26 additions and 51 deletions

View File

@@ -3,15 +3,15 @@ import React, { PureComponent } from 'react';
// Types
import { InlineFormLabel, LegacyForms, Select } from '@grafana/ui';
import { SelectableValue, QueryEditorProps } from '@grafana/data';
const { Switch } = LegacyForms;
import { QueryEditorProps, SelectableValue } from '@grafana/data';
import { PrometheusDatasource } from '../datasource';
import { PromQuery, PromOptions } from '../types';
import { PromOptions, PromQuery } from '../types';
import PromQueryField from './PromQueryField';
import PromLink from './PromLink';
const { Switch } = LegacyForms;
export type Props = QueryEditorProps<PrometheusDatasource, PromQuery, PromOptions>;
const FORMAT_OPTIONS: Array<SelectableValue<string>> = [
@@ -157,7 +157,6 @@ export class PromQueryEditor extends PureComponent<Props, State> {
<div className="gf-form-label">Resolution</div>
<Select
isSearchable={false}
menuPlacement="bottom"
options={INTERVAL_FACTOR_OPTIONS}
onChange={this.onIntervalFactorChange}
value={intervalFactorOption}