summaryrefslogtreecommitdiff
path: root/opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js
diff options
context:
space:
mode:
authorFabian Mastenbroek <mail.fabianm@gmail.com>2021-05-17 12:16:10 +0200
committerFabian Mastenbroek <mail.fabianm@gmail.com>2021-05-18 15:46:43 +0200
commit53623fad76274e39206b8e073e371775ea96946b (patch)
treea57d23d9c1f6a924753dbb4a3a9bc9cbca5385dd /opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js
parent688a25e560db3355e2a3ee369c2e6f4b55aab2a6 (diff)
ui: Migrate to FontAwesome 5 React library
This change updates the frontend to use the FontAwesome 5 React library that renders SVG icons as opposed to CSS icon fonts. This migration resolves a couple of issues we had with server-side rendering of the previous FontAwesome icons.
Diffstat (limited to 'opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js')
-rw-r--r--opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js b/opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js
index 0d3217f9..98aa0af2 100644
--- a/opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js
+++ b/opendc-web/opendc-web-ui/src/components/home/JumbotronHeader.js
@@ -1,6 +1,9 @@
import React from 'react'
+import Image from 'next/image'
import { Container, Jumbotron, Button } from 'reactstrap'
import { jumbotronHeader, jumbotron, dc } from './JumbotronHeader.module.scss'
+import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
+import { faExternalLinkAlt } from '@fortawesome/free-solid-svg-icons'
const JumbotronHeader = () => (
<section className={jumbotronHeader}>
@@ -10,7 +13,9 @@ const JumbotronHeader = () => (
Open<span className={dc}>DC</span>
</h1>
<p className="lead">Collaborative Datacenter Simulation and Exploration for Everybody</p>
- <img src="img/logo.png" className="img-responsive mt-3" alt="OpenDC" />
+ <div className="mt-5">
+ <Image src="/img/logo.png" layout="intrinsic" height={110} width={110} alt="OpenDC" />
+ </div>
<p className="lead mt-5">
<Button
tag="a"
@@ -18,7 +23,7 @@ const JumbotronHeader = () => (
href="https://atlarge-research.com/pdfs/ccgrid21-opendc-paper.pdf"
color="warning"
>
- Read about <strong>OpenDC 2.0</strong> <i className="fa fa-external-link" />
+ Read about <strong>OpenDC 2.0</strong> <FontAwesomeIcon icon={faExternalLinkAlt} />
</Button>
</p>
</Jumbotron>