LabelFilters: Remove redundant css styling (#56653)
* LabelFilters: Remove redundant css * Remove unused import
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import { css } from '@emotion/css';
|
||||
import { uniqBy } from 'lodash';
|
||||
import React, { useState } from 'react';
|
||||
|
||||
@@ -58,16 +57,6 @@ export function LabelFilterItem({
|
||||
return uniqBy([...selectedOptions, ...labelValues], 'value');
|
||||
};
|
||||
|
||||
/**
|
||||
* !important here is necessary to show invalid border on all 4 sides of select.
|
||||
* Without it, the invalid state is only visible on 3 sides as the right side is overridden in InputGroup.
|
||||
*/
|
||||
const invalidClassNameOverride = invalidLabel
|
||||
? css`
|
||||
margin-left: 0 !important;
|
||||
`
|
||||
: '';
|
||||
|
||||
return (
|
||||
<div data-testid="prometheus-dimensions-filter-item">
|
||||
<InputGroup>
|
||||
@@ -107,7 +96,6 @@ export function LabelFilterItem({
|
||||
onChange({ ...item, op: change.value } as any as QueryBuilderLabelFilter);
|
||||
}
|
||||
}}
|
||||
className={invalidClassNameOverride}
|
||||
/>
|
||||
|
||||
<Select
|
||||
|
||||
Reference in New Issue
Block a user