Fix search field styles

This commit is contained in:
David Kaltschmidt 2018-12-09 14:39:25 -08:00
parent 9293ff06cd
commit 117adbbe5d

View File

@ -16,6 +16,11 @@ import { parseQuery, formatQuery } from '../query_utils';
const PRISM_SYNTAX = 'promql'; const PRISM_SYNTAX = 'promql';
const SEARCH_FIELD_STYLES = {
width: '66%',
marginLeft: 3,
};
export function willApplySuggestion(suggestion: string, { typeaheadContext, typeaheadText }: QueryFieldState): string { export function willApplySuggestion(suggestion: string, { typeaheadContext, typeaheadText }: QueryFieldState): string {
// Modify suggestion based on context // Modify suggestion based on context
switch (typeaheadContext) { switch (typeaheadContext) {
@ -256,7 +261,7 @@ class LokiQueryField extends React.PureComponent<LokiQueryFieldProps, LokiQueryF
</div> </div>
) : null} ) : null}
</div> </div>
<div className="prom-query-field-wrapper"> <div className="prom-query-field-wrapper" style={SEARCH_FIELD_STYLES}>
<QueryField <QueryField
additionalPlugins={this.pluginsSearch} additionalPlugins={this.pluginsSearch}
disabled={searchDisabled} disabled={searchDisabled}