Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/app/cypress/e2e/csv-export.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('CSV Export', () => {
});

it('reliability chart has CSV export option', () => {
cy.get('[data-testid="tab-trigger-reliability"]').click();
cy.visit('/reliability');
cy.get('[data-testid="reliability-chart-display"]').should('exist');

cy.get('[data-testid="export-button"]').first().click();
Expand Down
11 changes: 8 additions & 3 deletions packages/app/cypress/e2e/tabs.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,21 @@ describe('Chart Section Tabs — E2E', () => {
cy.get('[data-testid="tab-trigger-calculator"]').click();
cy.url().should('include', '/calculator');

cy.get('[data-testid="tab-trigger-reliability"]').click();
cy.url().should('include', '/reliability');

cy.get('[data-testid="tab-trigger-gpu-specs"]').click();
cy.url().should('include', '/gpu-specs');

cy.get('[data-testid="tab-trigger-inference"]').click();
cy.url().should('include', '/inference');
});

it('opens GPU Reliability from the footer link', () => {
cy.get('[data-testid="tab-trigger-reliability"]').should('not.exist');

cy.get('[data-testid="footer-link-reliability"]').scrollIntoView().click();
cy.url().should('include', '/reliability');
cy.get('[data-testid="reliability-chart-display"]').should('exist');
});

it('shows mobile chart select dropdown on small viewport', () => {
cy.viewport(375, 812);
cy.visit('/inference');
Expand Down
12 changes: 11 additions & 1 deletion packages/app/src/components/footer/footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const Footer = ({ starCount }: { starCount?: number | null }) => {
</div>

{/* Center — Links */}
<div data-testid="footer-links" className="flex justify-evenly gap-6">
<div data-testid="footer-links" className="grid grid-cols-3 gap-x-6 gap-y-8">
<div data-testid="footer-links-semianalysis" className="flex flex-col gap-2.5">
<span className="text-sm font-medium text-foreground">SemiAnalysis</span>
<a
Expand Down Expand Up @@ -114,6 +114,16 @@ export const Footer = ({ starCount }: { starCount?: number | null }) => {
Frontend
</a>
</div>
<div data-testid="footer-links-more" className="flex flex-col gap-2.5">
<span className="text-sm font-medium text-foreground">More</span>
<Link
data-testid="footer-link-reliability"
href="/reliability"
className="text-sm text-muted-foreground hover:text-foreground transition-colors"
>
GPU Reliability
</Link>
</div>
</div>

{/* Right — CTA + Social */}
Expand Down
8 changes: 5 additions & 3 deletions packages/app/src/components/tab-nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,13 @@ const TAB_LINKS = [
{ href: '/evaluation', label: 'Accuracy Evals', testId: 'tab-trigger-evaluation' },
{ href: '/historical', label: 'Historical Trends', testId: 'tab-trigger-historical' },
{ href: '/calculator', label: 'TCO Calculator', testId: 'tab-trigger-calculator' },
{ href: '/reliability', label: 'GPU Reliability', testId: 'tab-trigger-reliability' },
{ href: '/gpu-specs', label: 'GPU Specs', testId: 'tab-trigger-gpu-specs' },
{ href: '/gpu-metrics', label: 'PowerX', testId: 'tab-trigger-gpu-metrics', gated: true },
{ href: '/submissions', label: 'Submissions', testId: 'tab-trigger-submissions', gated: true },
] as const;

const TAB_VALUES = new Set(TAB_LINKS.map((t) => t.href.slice(1)));

function activeTab(pathname: string): string {
const seg = pathname.split('/').filter(Boolean)[0] || 'inference';
return seg;
Expand All @@ -85,6 +86,7 @@ export function TabNav() {
const router = useRouter();
const featureGateUnlocked = useFeatureGate();
const current = activeTab(pathname);
const selectedTab = TAB_VALUES.has(current) ? current : '';

const handleMobileChange = (value: string) => {
window.dispatchEvent(new CustomEvent('inferencex:tab-change'));
Expand All @@ -105,9 +107,9 @@ export function TabNav() {
<Card>
<div className="space-y-2">
<Label htmlFor="chart-select">Select Chart</Label>
<Select value={current} onValueChange={handleMobileChange}>
<Select value={selectedTab} onValueChange={handleMobileChange}>
<SelectTrigger id="chart-select" data-testid="mobile-chart-select" className="w-full">
<SelectValue />
<SelectValue placeholder="Select Chart" />
</SelectTrigger>
<SelectContent>
{TAB_LINKS.map((tab) => {
Expand Down
Loading