mirror of
https://github.com/fleetdm/fleet
synced 2026-05-23 00:49:03 +00:00
Fleet UI: More truncation fixes after QA (#28209)
This commit is contained in:
parent
c91beea408
commit
c70c00cedc
6 changed files with 25 additions and 26 deletions
|
|
@ -65,7 +65,7 @@ const generateDefaultTableHeaders = (
|
|||
);
|
||||
}
|
||||
|
||||
const { name, os_version_id } = cellProps.row.original;
|
||||
const { name, os_version_id, platform } = cellProps.row.original;
|
||||
|
||||
const softwareOsDetailsPath = getPathWithQueryParams(
|
||||
PATHS.SOFTWARE_OS_DETAILS(os_version_id),
|
||||
|
|
@ -83,12 +83,9 @@ const generateDefaultTableHeaders = (
|
|||
<LinkCell
|
||||
path={softwareOsDetailsPath}
|
||||
customOnClick={onClickSoftware}
|
||||
value={
|
||||
<>
|
||||
<SoftwareIcon name={cellProps.row.original.platform} />
|
||||
<span className="software-name">{name}</span>
|
||||
</>
|
||||
}
|
||||
tooltipTruncate
|
||||
prefix={<SoftwareIcon name={platform} />}
|
||||
value={name}
|
||||
/>
|
||||
);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
/** software/titles/:id > Second section */
|
||||
|
||||
import React, { useCallback, useContext, useState } from "react";
|
||||
|
||||
import PATHS from "router/paths";
|
||||
|
|
|
|||
|
|
@ -245,14 +245,13 @@ const SoftwareTable = ({
|
|||
};
|
||||
|
||||
const handleRowSelect = (row: IRowProps) => {
|
||||
if (row.original.id) {
|
||||
const path = getPathWithQueryParams(
|
||||
PATHS.SOFTWARE_TITLE_DETAILS(row.original.id.toString()),
|
||||
{ team_id: teamId }
|
||||
);
|
||||
if (!row.original.id) return;
|
||||
|
||||
router.push(path);
|
||||
}
|
||||
const detailsPath = showVersions
|
||||
? PATHS.SOFTWARE_VERSION_DETAILS(row.original.id.toString())
|
||||
: PATHS.SOFTWARE_TITLE_DETAILS(row.original.id.toString());
|
||||
|
||||
router.push(getPathWithQueryParams(detailsPath, { team_id: teamId }));
|
||||
};
|
||||
|
||||
const renderSoftwareCount = () => {
|
||||
|
|
|
|||
|
|
@ -44,12 +44,9 @@ const generateColumnConfigs = (
|
|||
return (
|
||||
<LinkCell
|
||||
path={path}
|
||||
value={
|
||||
<>
|
||||
<SoftwareIcon name={platform} />
|
||||
<span className="os-version-name">{name}</span>
|
||||
</>
|
||||
}
|
||||
tooltipTruncate
|
||||
prefix={<SoftwareIcon name={platform} />}
|
||||
value={name}
|
||||
/>
|
||||
);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -43,12 +43,9 @@ const generateColumnConfigs = (
|
|||
return (
|
||||
<LinkCell
|
||||
path={path}
|
||||
value={
|
||||
<>
|
||||
<SoftwareIcon name={name} />
|
||||
<span className="vuln-sw-name">{name}</span>
|
||||
</>
|
||||
}
|
||||
tooltipTruncate
|
||||
prefix={<SoftwareIcon name={name} />}
|
||||
value={name}
|
||||
/>
|
||||
);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -241,6 +241,13 @@ $max-width: 2560px;
|
|||
z-index: 100;
|
||||
line-height: 1.375;
|
||||
white-space: initial;
|
||||
|
||||
// Hyphenated words will still break at hyphens first
|
||||
// while non-hyphenated strings will break only when necessary
|
||||
overflow-wrap: break-word; // Preferred property for modern browsers
|
||||
word-wrap: break-word; // Fallback for older browsers e.g. IE
|
||||
word-break: break-word; // Ensures words break when necessary
|
||||
|
||||
p {
|
||||
margin: 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue