Grafana UI: CellActions - Replace HorizontalGroup with Stack (#85860)

This commit is contained in:
Laura Fernández
2024-04-11 10:59:23 +02:00
committed by GitHub
parent 1ed3dc22d5
commit 2986273273
2 changed files with 3 additions and 6 deletions
-3
View File
@@ -933,9 +933,6 @@ exports[`better eslint`] = {
[0, 0, 0, "Unexpected any. Specify a different type.", "1"],
[0, 0, 0, "Unexpected any. Specify a different type.", "2"]
],
"packages/grafana-ui/src/components/Table/CellActions.tsx:5381": [
[0, 0, 0, "\'HorizontalGroup\' import from \'../Layout/Layout\' is restricted from being used by a pattern. Use Stack component instead.", "0"]
],
"packages/grafana-ui/src/components/Table/Filter.tsx:5381": [
[0, 0, 0, "Unexpected any. Specify a different type.", "0"]
],
@@ -2,7 +2,7 @@ import React, { useCallback, useState } from 'react';
import { IconSize } from '../../types/icon';
import { IconButton } from '../IconButton/IconButton';
import { HorizontalGroup } from '../Layout/Layout';
import { Stack } from '../Layout/Stack/Stack';
import { TooltipPlacement } from '../Tooltip';
import { TableCellInspectModal } from './TableCellInspectModal';
@@ -49,7 +49,7 @@ export function CellActions({ field, cell, previewMode, showFilters, onCellFilte
return (
<>
<div className={`cellActions${isRightAligned ? ' cellActionsLeft' : ''}`}>
<HorizontalGroup spacing="xs">
<Stack gap={0.5}>
{inspectEnabled && (
<IconButton
name="eye"
@@ -66,7 +66,7 @@ export function CellActions({ field, cell, previewMode, showFilters, onCellFilte
{showFilters && (
<IconButton name={'search-minus'} onClick={onFilterOut} tooltip="Filter out value" {...commonButtonProps} />
)}
</HorizontalGroup>
</Stack>
</div>
{isInspecting && (