mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Chore: DataSourcePicker- Replace HorizontalGroup with Stack (#86389)
This commit is contained in:
@@ -697,9 +697,6 @@ exports[`better eslint`] = {
|
|||||||
"packages/grafana-runtime/src/analytics/types.ts:5381": [
|
"packages/grafana-runtime/src/analytics/types.ts:5381": [
|
||||||
[0, 0, 0, "Unexpected any. Specify a different type.", "0"]
|
[0, 0, 0, "Unexpected any. Specify a different type.", "0"]
|
||||||
],
|
],
|
||||||
"packages/grafana-runtime/src/components/DataSourcePicker.tsx:5381": [
|
|
||||||
[0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"]
|
|
||||||
],
|
|
||||||
"packages/grafana-runtime/src/config.ts:5381": [
|
"packages/grafana-runtime/src/config.ts:5381": [
|
||||||
[0, 0, 0, "Do not use any type assertions.", "0"],
|
[0, 0, 0, "Do not use any type assertions.", "0"],
|
||||||
[0, 0, 0, "Do not use any type assertions.", "1"],
|
[0, 0, 0, "Do not use any type assertions.", "1"],
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import {
|
|||||||
SelectableValue,
|
SelectableValue,
|
||||||
} from '@grafana/data';
|
} from '@grafana/data';
|
||||||
import { selectors } from '@grafana/e2e-selectors';
|
import { selectors } from '@grafana/e2e-selectors';
|
||||||
import { ActionMeta, HorizontalGroup, PluginSignatureBadge, Select } from '@grafana/ui';
|
import { ActionMeta, PluginSignatureBadge, Select, Stack } from '@grafana/ui';
|
||||||
|
|
||||||
import { getDataSourceSrv } from '../services/dataSourceSrv';
|
import { getDataSourceSrv } from '../services/dataSourceSrv';
|
||||||
|
|
||||||
@@ -209,9 +209,9 @@ export class DataSourcePicker extends PureComponent<DataSourcePickerProps, DataS
|
|||||||
getOptionLabel={(o) => {
|
getOptionLabel={(o) => {
|
||||||
if (o.meta && isUnsignedPluginSignature(o.meta.signature) && o !== value) {
|
if (o.meta && isUnsignedPluginSignature(o.meta.signature) && o !== value) {
|
||||||
return (
|
return (
|
||||||
<HorizontalGroup align="center" justify="space-between" height="auto">
|
<Stack alignItems="center" justifyContent="space-between">
|
||||||
<span>{o.label}</span> <PluginSignatureBadge status={o.meta.signature} />
|
<span>{o.label}</span> <PluginSignatureBadge status={o.meta.signature} />
|
||||||
</HorizontalGroup>
|
</Stack>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
return o.label || '';
|
return o.label || '';
|
||||||
|
|||||||
Reference in New Issue
Block a user