mirror of
https://github.com/strapi/strapi.git
synced 2025-09-21 14:31:16 +00:00
DynamicTable: avoid wrapping single components in flex components
This commit is contained in:
parent
f58b78c39e
commit
37468e0824
@ -1,9 +1,7 @@
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { Flex } from '@strapi/design-system/Flex';
|
||||
import { Tooltip } from '@strapi/design-system/Tooltip';
|
||||
import { Typography } from '@strapi/design-system/Typography';
|
||||
import { stopPropagation } from '@strapi/helper-plugin';
|
||||
|
||||
import CellValue from '../CellValue';
|
||||
|
||||
@ -12,13 +10,11 @@ const SingleComponentCell = ({ value, metadatas }) => {
|
||||
const content = value[mainField.name];
|
||||
|
||||
return (
|
||||
<Flex {...stopPropagation}>
|
||||
<Tooltip label={content}>
|
||||
<Typography textColor="neutral800" ellipsis>
|
||||
<CellValue type={mainField.type} value={content} />
|
||||
</Typography>
|
||||
</Tooltip>
|
||||
</Flex>
|
||||
<Tooltip label={content}>
|
||||
<Typography textColor="neutral800" ellipsis>
|
||||
<CellValue type={mainField.type} value={content} />
|
||||
</Typography>
|
||||
</Tooltip>
|
||||
);
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user