diff --git a/packages/grafana-ui/src/components/PanelOptionsGroup/PanelOptionsGroup.tsx b/packages/grafana-ui/src/components/PanelOptionsGroup/PanelOptionsGroup.tsx deleted file mode 100644 index 4a361a4a67a..00000000000 --- a/packages/grafana-ui/src/components/PanelOptionsGroup/PanelOptionsGroup.tsx +++ /dev/null @@ -1,39 +0,0 @@ -// Libraries -import React, { FunctionComponent } from 'react'; -import { Icon } from '../Icon/Icon'; - -interface Props { - title?: string | JSX.Element; - onClose?: () => void; - children: JSX.Element | JSX.Element[] | boolean; - onAdd?: () => void; -} - -export const PanelOptionsGroup: FunctionComponent = props => { - return ( -
- {props.onAdd ? ( -
- -
- ) : ( - props.title && ( -
- {props.title} - {props.onClose && ( - - )} -
- ) - )} - {props.children &&
{props.children}
} -
- ); -}; diff --git a/packages/grafana-ui/src/components/PanelOptionsGroup/_PanelOptionsGroup.scss b/packages/grafana-ui/src/components/PanelOptionsGroup/_PanelOptionsGroup.scss deleted file mode 100644 index 75b60807e9a..00000000000 --- a/packages/grafana-ui/src/components/PanelOptionsGroup/_PanelOptionsGroup.scss +++ /dev/null @@ -1,34 +0,0 @@ -.panel-options-group { - border-bottom: $panel-border; -} - -.panel-options-group__header { - padding: 8px 16px 8px 8px; - position: relative; - display: flex; - align-items: center; - cursor: pointer; - font-weight: 500; - color: $text-color-semi-weak; - - &:hover { - color: $text-color; - - .panel-options-group__icon { - color: $text-color; - } - } -} - -.panel-options-group__icon { - color: $text-color-weak; - margin-right: 8px; -} - -.panel-options-group__title { - position: relative; -} - -.panel-options-group__body { - padding: 8px 16px 16px 32px; -} diff --git a/packages/grafana-ui/src/components/index.scss b/packages/grafana-ui/src/components/index.scss index e870c298c38..232206f2d4a 100644 --- a/packages/grafana-ui/src/components/index.scss +++ b/packages/grafana-ui/src/components/index.scss @@ -5,7 +5,6 @@ @import 'EmptySearchResult/EmptySearchResult'; @import 'FormField/FormField'; @import 'PanelOptionsGrid/PanelOptionsGrid'; -@import 'PanelOptionsGroup/PanelOptionsGroup'; @import 'RefreshPicker/RefreshPicker'; @import 'Forms/Legacy/Select/Select'; @import 'TableInputCSV/TableInputCSV'; diff --git a/packages/grafana-ui/src/components/index.ts b/packages/grafana-ui/src/components/index.ts index c05e4435e8d..5f6c22741dc 100644 --- a/packages/grafana-ui/src/components/index.ts +++ b/packages/grafana-ui/src/components/index.ts @@ -16,7 +16,6 @@ export { ButtonCascader } from './ButtonCascader/ButtonCascader'; export { LoadingPlaceholder, LoadingPlaceholderProps } from './LoadingPlaceholder/LoadingPlaceholder'; export { ColorPicker, SeriesColorPicker } from './ColorPicker/ColorPicker'; export { SeriesColorPickerPopover, SeriesColorPickerPopoverWithTheme } from './ColorPicker/SeriesColorPickerPopover'; -export { PanelOptionsGroup } from './PanelOptionsGroup/PanelOptionsGroup'; export { PanelOptionsGrid } from './PanelOptionsGrid/PanelOptionsGrid'; export { EmptySearchResult } from './EmptySearchResult/EmptySearchResult'; export { PieChart, PieChartType } from './PieChart/PieChart'; diff --git a/public/app/plugins/panel/piechart/PieChartOptionsBox.tsx b/public/app/plugins/panel/piechart/PieChartOptionsBox.tsx index 062c88d8ca6..36b62031415 100644 --- a/public/app/plugins/panel/piechart/PieChartOptionsBox.tsx +++ b/public/app/plugins/panel/piechart/PieChartOptionsBox.tsx @@ -2,7 +2,7 @@ import React, { PureComponent } from 'react'; // Components -import { LegacyForms, InlineFormLabel, PanelOptionsGroup } from '@grafana/ui'; +import { LegacyForms, InlineFormLabel } from '@grafana/ui'; const { Select, FormField } = LegacyForms; // Types @@ -27,7 +27,7 @@ export class PieChartOptionsBox extends PureComponent + <>
Type