text wrapping
This commit is contained in:
@@ -96,13 +96,16 @@ const compareJobs = (a: Job, b: Job, sort: JobSort) => {
|
|||||||
value = statusRank[a.status] - statusRank[b.status];
|
value = statusRank[a.status] - statusRank[b.status];
|
||||||
break;
|
break;
|
||||||
case "score":
|
case "score":
|
||||||
if (a.suitabilityScore == null && b.suitabilityScore == null) {
|
const aScore = a.suitabilityScore;
|
||||||
|
const bScore = b.suitabilityScore;
|
||||||
|
|
||||||
|
if (aScore == null && bScore == null) {
|
||||||
value = 0;
|
value = 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (a.suitabilityScore == null) return 1;
|
if (aScore == null) return 1;
|
||||||
if (b.suitabilityScore == null) return -1;
|
if (bScore == null) return -1;
|
||||||
value = compareNumber(a.suitabilityScore, b.suitabilityScore);
|
value = compareNumber(aScore, bScore);
|
||||||
break;
|
break;
|
||||||
case "discoveredAt":
|
case "discoveredAt":
|
||||||
value = compareNullable(dateValue(a.discoveredAt), dateValue(b.discoveredAt), compareNumber);
|
value = compareNullable(dateValue(a.discoveredAt), dateValue(b.discoveredAt), compareNumber);
|
||||||
|
|||||||
@@ -181,12 +181,12 @@ export const JobTable: React.FC<JobTableProps> = ({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<TableRow key={job.id}>
|
<TableRow key={job.id}>
|
||||||
<TableCell className="max-w-[520px]">
|
<TableCell className="align-top">
|
||||||
<Button
|
<Button
|
||||||
asChild
|
asChild
|
||||||
variant="link"
|
variant="link"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto justify-start p-0 text-left leading-snug"
|
className="h-auto justify-start p-0 text-left leading-snug whitespace-normal break-words"
|
||||||
>
|
>
|
||||||
<a href={jobLink} target="_blank" rel="noopener noreferrer">
|
<a href={jobLink} target="_blank" rel="noopener noreferrer">
|
||||||
{job.title}
|
{job.title}
|
||||||
@@ -194,8 +194,8 @@ export const JobTable: React.FC<JobTableProps> = ({
|
|||||||
</Button>
|
</Button>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
|
|
||||||
<TableCell className="max-w-[320px] truncate">
|
<TableCell className="align-top whitespace-normal break-words">
|
||||||
<span className="truncate">{job.employer}</span>
|
{job.employer}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
|
|
||||||
<TableCell>
|
<TableCell>
|
||||||
@@ -204,7 +204,7 @@ export const JobTable: React.FC<JobTableProps> = ({
|
|||||||
</Badge>
|
</Badge>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
|
|
||||||
<TableCell className="max-w-[260px] truncate text-muted-foreground">
|
<TableCell className="align-top whitespace-normal break-words text-muted-foreground">
|
||||||
{job.location || "—"}
|
{job.location || "—"}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user