Skip to content

Commit

Permalink
www: fix links in the about page
Browse files Browse the repository at this point in the history
Somehow <Link> forces relative links and breaks external URLs
(ex: https://buildbot.buildbot.net/#/about/http://buildbot.net). It
might be fixed with react-router 6.7.1 [1], while I prefer to just use
basic `<a>`.

While I'm at it, I also updated the link to use HTTPS.

[1] remix-run/react-router#9900
  • Loading branch information
yan12125 authored and mokibit committed Aug 26, 2024
1 parent 645d286 commit feb8ab6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions newsfragments/www-fix-about-page-links.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix links to external URLs in the about pages.
4 changes: 2 additions & 2 deletions www/base/src/views/AboutView/AboutView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ export const AboutView = observer(() => {
<Card.Body>
<h2>
<img src="icon.svg" alt="" width="64px" className="nut-spin"/>&nbsp;About this&nbsp;
<Link to="http://buildbot.net">buildbot</Link>&nbsp;running for&nbsp;
<Link to={config.titleURL}>{config.title}</Link>
<a href="https://buildbot.net">buildbot</a>&nbsp;running for&nbsp;
<a href={config.titleURL}>{config.title}</a>
</h2>
<div className="col-sm-12">
<ul>
Expand Down
6 changes: 3 additions & 3 deletions www/react-base/src/views/AboutView/AboutView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ export const AboutView = observer(() => {
<Card bg="light">
<Card.Body>
<h2>
<img src="img/icon.svg" alt="" width="64px" className="nut-spin"/>&nbsp;About this&nbsp;
<Link to="http://buildbot.net">buildbot</Link>&nbsp;running for&nbsp;
<Link to={config.titleURL}>{config.title}</Link>
<img src="icon.svg" alt="" width="64px" className="nut-spin"/>&nbsp;About this&nbsp;
<a href="https://buildbot.net">buildbot</a>&nbsp;running for&nbsp;
<a href={config.titleURL}>{config.title}</a>
</h2>
<div className="col-sm-12">
<ul>
Expand Down

0 comments on commit feb8ab6

Please sign in to comment.