fix: prevent selection clicking outside the table (#14007)

Fixed issue #13869

Added flag to prevent selection of content inside ScrollWrapper based on
value of preventTextSelection flag this will prevent selection of its
all child. For to select title and description I added custom css for
that to allow selection for title and description.

Demo : 


https://github.com/user-attachments/assets/d10a7e5f-6498-4f8d-9aa2-26f48559ce23

---------

Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
This commit is contained in:
Kailash Rajput
2025-08-21 15:10:42 +05:30
committed by GitHub
parent f0a59829a5
commit 7ae26f04dd
2 changed files with 6 additions and 1 deletions
@@ -2,9 +2,9 @@ import { css, useTheme } from '@emotion/react';
import styled from '@emotion/styled';
import { Link } from 'react-router-dom';
import { type SettingsFieldType } from '@/settings/data-model/types/SettingsFieldType';
import { getSettingsFieldTypeConfig } from '@/settings/data-model/utils/getSettingsFieldTypeConfig';
import { type IconComponent, IconTwentyStar } from 'twenty-ui/display';
import { type SettingsFieldType } from '@/settings/data-model/types/SettingsFieldType';
type SettingsObjectFieldDataTypeProps = {
to?: string;
@@ -28,6 +28,9 @@ const StyledDataType = styled.div<{
height: 20px;
overflow: hidden;
text-decoration: none;
user-select: none;
${({ to, theme }) =>
to
? css`
@@ -30,6 +30,8 @@ const StyledNameLabel = styled.div`
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
user-select: none;
`;
type SettingsRolePermissionsObjectLevelObjectFieldPermissionTableRowProps = {