Skip to content

enhancement: Use Next.js Link instead of native anchor tag for Scoring Methodology CTA in ResultDashboard #259

Open

Description

@O2sa

In src/features/comparison/components/result-dashboard.tsx line 644:

<a
  href={methodologyHref}
  className="inline-flex items-center rounded-lg bg-primary px-3 py-2 text-sm font-semibold text-white transition-colors hover:bg-blue-600 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary"
>
  {t("methodology.cta.button")}
</a>

Using native <a> causes a full browser page refresh instead of client-side SPA navigation, dropping existing client state. Additionally, text-white and hover:bg-blue-600 are hardcoded rather than using design tokens.

Motivation

Preserving client navigation avoids full reload latency and keeps theme and session state responsive.

Tasks

  • Replace <a> with Next.js <Link href={methodologyHref as Route}> (or wrap with <Button asChild>).
  • Use design token classes text-primary-foreground hover:bg-primary/90 instead of hardcoded text-white hover:bg-blue-600.

Files to Check

  • src/features/comparison/components/result-dashboard.tsx

Tip

🚀 Want to contribute?
Comment assign me to be automatically assigned to this issue via our GitHub Actions bot. Happy coding! ✨

Activity

  1. aryansinha1908 commented on Oct 21, 2026

    @aryansinha1908

    I would like to work on this issue. Please, assign it to me.

  2. github-actions commented on Oct 21, 2026

    @github-actions

    🎉 Issue assigned to @aryansinha1908! Happy coding!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions