-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Table text wrapping #8683
Fix Table text wrapping #8683
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Summary
This PR fixes text wrapping behavior in tables by adding a wrap
property across multiple components to ensure text displays in a single line with ellipsis instead of wrapping.
- Added
wrap
property toGenericFieldContextType
in/packages/twenty-front/src/modules/object-record/record-field/contexts/FieldContext.ts
- Fixed inconsistent wrap settings:
wrap: true
inRecordInlineCell.tsx
contradicts the PR's goal of preventing wrapping - Modified
OverflowingTextWithTooltip
in/packages/twenty-ui/src/display/tooltip/OverflowingTextWithTooltip.tsx
to only wrap text whenwrap
,displayedMaxRows
, and!isLabel
are all true - Added wrap control to
TextDisplay
component with proper ellipsis handling - Potential conflict in
SettingsDataModelFieldPreview.tsx
betweenwrap: true
andwhite-space: nowrap
styles
9 file(s) reviewed, 3 comment(s)
Edit PR Review Bot Settings | Greptile
.../src/modules/settings/data-model/fields/preview/components/SettingsDataModelFieldPreview.tsx
Outdated
Show resolved
Hide resolved
packages/twenty-front/src/modules/object-record/record-field/contexts/FieldContext.ts
Outdated
Show resolved
Hide resolved
...nt/src/modules/object-record/record-field/meta-types/display/components/TextFieldDisplay.tsx
Outdated
Show resolved
Hide resolved
.../twenty-front/src/modules/object-record/record-field/meta-types/hooks/useTextFieldDisplay.ts
Outdated
Show resolved
Hide resolved
Thanks @guillim for your contribution! |
As discovered during the last release, text fields in the table were wrapped. This PR fixes this unwanted behaviour
Current :
Wanted :
One line ellipsed