Wrap Long text fields (textarea) (#8557)

Here we add the option for Text inputs to be wrapped, and to select on
how many lines text should be displayed.

Fix #7552

---------

Co-authored-by: guillim <guillaume@twenty.com>
This commit is contained in:
Guillim
2024-11-18 17:36:19 +01:00
committed by GitHub
parent 83b5eb69b0
commit 2f3c41620c
14 changed files with 235 additions and 27 deletions

View File

@ -1,3 +0,0 @@
import { TextDisplay } from './TextDisplay';
export const DoubleTextDisplay = TextDisplay;

View File

@ -2,8 +2,9 @@ import { OverflowingTextWithTooltip } from 'twenty-ui';
type TextDisplayProps = {
text: string;
displayedMaxRows?: number;
};
export const TextDisplay = ({ text }: TextDisplayProps) => (
<OverflowingTextWithTooltip text={text} />
export const TextDisplay = ({ text, displayedMaxRows }: TextDisplayProps) => (
<OverflowingTextWithTooltip text={text} displayedMaxRows={displayedMaxRows} />
);