Skip to content

Commit 97037ec

Browse files
committed
feat(pathways): add company website link to job panel
1 parent 43f533b commit 97037ec

File tree

1 file changed

+22
-3
lines changed

1 file changed

+22
-3
lines changed

apps/registry/app/pathways/components/graph/PathwaysJobPanel.js

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import {
1515
ThumbsUp,
1616
Send,
1717
Link2,
18+
Building2,
1819
} from 'lucide-react';
1920
import WhyMatch from '../WhyMatch';
2021

@@ -65,6 +66,7 @@ export function PathwaysJobPanel({
6566
: jobInfo.skills?.slice(0, 8);
6667

6768
const hnUrl = `https://news.ycombinator.com/item?id=${selectedNode.id}`;
69+
const companyUrl = jobInfo.website || jobInfo.url || jobInfo.companyUrl;
6870

6971
return (
7072
<div className="absolute top-4 right-4 w-96 bg-white rounded-xl shadow-xl border border-gray-200 overflow-hidden">
@@ -75,9 +77,26 @@ export function PathwaysJobPanel({
7577
<h3 className="font-semibold text-gray-900">
7678
{highlightText(jobInfo.title, filterText)}
7779
</h3>
78-
<p className="text-sm text-gray-600">
79-
{highlightText(jobInfo.company, filterText)}
80-
</p>
80+
{companyUrl ? (
81+
<a
82+
href={
83+
companyUrl.startsWith('http')
84+
? companyUrl
85+
: `https://${companyUrl}`
86+
}
87+
target="_blank"
88+
rel="noopener noreferrer"
89+
className="text-sm text-indigo-600 hover:text-indigo-700 flex items-center gap-1"
90+
>
91+
<Building2 className="w-3 h-3" />
92+
{highlightText(jobInfo.company, filterText)}
93+
<ExternalLink className="w-3 h-3" />
94+
</a>
95+
) : (
96+
<p className="text-sm text-gray-600">
97+
{highlightText(jobInfo.company, filterText)}
98+
</p>
99+
)}
81100
</div>
82101
<div className="flex items-center gap-1">
83102
<button

0 commit comments

Comments
 (0)