mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-25 16:51:13 -05:00
Make entity names clickable
Update various components to wrap display names (parks, rides, manufacturers, designers, operators, etc.) in Link elements so they navigate to detail pages, aligning with the ParkDetail change. This includesRideDetail, RideListView, RideCreditCard, ParkDetail, and related imports, to enhance cohesion, interactivity, and browseability across the app.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { useState, lazy, Suspense, useEffect } from 'react';
|
||||
import { useParams, useNavigate } from 'react-router-dom';
|
||||
import { useParams, useNavigate, Link } from 'react-router-dom';
|
||||
import { Header } from '@/components/layout/Header';
|
||||
import { getBannerUrls } from '@/lib/cloudflareImageUtils';
|
||||
import { trackPageView } from '@/lib/viewTracking';
|
||||
@@ -471,9 +471,12 @@ export default function RideDetail() {
|
||||
<Users className="w-4 h-4 text-muted-foreground" />
|
||||
<div>
|
||||
<div className="font-medium">Manufacturer</div>
|
||||
<div className="text-sm text-muted-foreground">
|
||||
<Link
|
||||
to={`/manufacturers/${ride.manufacturer.slug}`}
|
||||
className="text-sm text-primary hover:underline"
|
||||
>
|
||||
{ride.manufacturer.name}
|
||||
</div>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
@@ -483,9 +486,12 @@ export default function RideDetail() {
|
||||
<Users className="w-4 h-4 text-muted-foreground" />
|
||||
<div>
|
||||
<div className="font-medium">Designer</div>
|
||||
<div className="text-sm text-muted-foreground">
|
||||
<Link
|
||||
to={`/designers/${ride.designer.slug}`}
|
||||
className="text-sm text-primary hover:underline"
|
||||
>
|
||||
{ride.designer.name}
|
||||
</div>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user