Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace img with Image/Next #26

Merged
merged 2 commits into from
Apr 1, 2024
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
13 changes: 9 additions & 4 deletions components/Footer.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from "react";
import { Col, Row } from "react-bootstrap";
import FooterBg from "../svgs/FooterBg.js";
import Image from 'next/image'

function Footer(props) {
const pagePos = props.pagePos;
Expand Down Expand Up @@ -91,17 +92,21 @@ function Footer(props) {
</nav>
<div className="logoWrapper">
<a href="https://ipfs.io/" target="_blank" rel="noreferrer">
<img
<Image
className="logo ipfs"
src="images/IPFS-logo.svg"
src="/images/IPFS-logo.svg"
alt="IPFS Logo"
height={30}
width={30}
/>
</a>
<a href="https://filecoin.io/" target="_blank" rel="noreferrer">
<img
<Image
className="logo"
src="images/filecoin-logo.svg"
src="/images/filecoin-logo.svg"
alt="Filecoin Logo"
height={30}
width={30}
/>
</a>
</div>
Expand Down
13 changes: 9 additions & 4 deletions components/Header.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React, { useEffect, useState } from "react";
import Image from "next/image";

import {
disableBodyScroll,
Expand Down Expand Up @@ -101,17 +102,21 @@ function Header(props) {
</div>
<div className="centerWrapper">
<a href="https://ipfs.io/" target="_blank" rel="noreferrer">
<img
<Image
className="logo ipfs"
src="images/IPFS-logo.svg"
src="/images/IPFS-logo.svg"
alt="IPFS Logo"
height={36}
width={36}
/>
</a>
<a href="https://filecoin.io/" target="_blank" rel="noreferrer">
<img
<Image
className="logo"
src="images/filecoin-logo.svg"
src="/images/filecoin-logo.svg"
alt="Filecoin Logo"
height={36}
width={36}
/>
</a>
</div>
Expand Down
4 changes: 4 additions & 0 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ const nextConfig = {
reactStrictMode: true,
swcMinify: true,
assetPrefix: './',
images: {
loader: 'akamai',
path: '',
},
}

module.exports = nextConfig
26 changes: 14 additions & 12 deletions pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import LookupBg from "../svgs/LookupBg.js";
import { Waypoint } from "react-waypoint";
import Slider from "react-slick";
import cbor from "cbor";
import Image from "next/image";

export default function Home(props) {
const setPagePos = props.setPagePos;
Expand Down Expand Up @@ -1071,7 +1072,7 @@ export default function Home(props) {
<div className="rowWrapper">
<Row>
<Col xs={12} md={4} className="imgCol pe-md-5 mb-5 mb-md-0">
<img src="images/about-1.svg" alt="Map" />
<Image src="/images/about-1.svg" alt="Map" width={172} height={120} />
</Col>
<Col xs={12} md={8} className="textCol">
<p>
Expand All @@ -1085,7 +1086,7 @@ export default function Home(props) {
</Row>
<Row>
<Col xs={12} md={4} className="imgCol pe-md-5 mb-5 mb-md-0">
<img src="images/about-2.svg" alt="Solarsystem" />
<Image src="/images/about-2.svg" alt="Solarsystem" width={197} height={120}/>
</Col>
<Col xs={12} md={8} className="textCol">
<p>
Expand All @@ -1101,7 +1102,7 @@ export default function Home(props) {
</Row>
<Row>
<Col xs={12} md={4} className="imgCol pe-md-5 mb-5 mb-md-0">
<img src="images/about-3.svg" alt="Connected Circles" />
<Image src="/images/about-3.svg" alt="Connected Circles" width={193} height={120} />
</Col>
<Col xs={12} md={8} className="textCol">
<p>
Expand Down Expand Up @@ -1142,55 +1143,56 @@ export default function Home(props) {
target="_blank"
rel="noreferrer"
>
<img src="images/kenLabs.svg" alt="Ken Labs Logo" />
<Image src="/images/kenLabs.svg" alt="Ken Labs Logo" width={322} height={89}/>
</a>
<a
href="https://www.leewayhertz.com/"
target="_blank"
rel="noreferrer"
>
<img src="images/LeewayHertz.svg" alt="Leeway Hertz Logo" />
<Image src="/images/LeewayHertz.svg" alt="Leeway Hertz Logo" width={322} height={43} />
</a>
<a
href="https://www.piknik.com/"
target="_blank"
rel="noreferrer"
>
<img src="images/PiKNiK.svg" alt="PiKNiK Logo" />
<Image src="/images/PiKNiK.svg" alt="PiKNiK Logo" width={322} height={82}/>
</a>
<a
href="https://www.filswan.com/"
target="_blank"
rel="noreferrer"
>
<img src="images/FilSwan-logo.svg" alt="FilSwan Logo" />
<Image src="/images/FilSwan-logo.svg" alt="FilSwan Logo" width={322} height={76}/>
</a>
<a
href="https://www.sxxfuture.com/"
target="_blank"
rel="noreferrer"
>
<img
src="images/SanXiaXingFutureData.svg"
<Image
src="/images/SanXiaXingFutureData.svg"
alt="San Xia Xing Future Data Logo"
width={322} height={82}
/>
</a>
<a href="https://infura.io/" target="_blank" rel="noreferrer">
<img src="images/Infura.svg" alt="Infura Logo" />
<Image src="/images/Infura.svg" alt="Infura Logo" width={322} height={89} />
</a>
<a
href="https://distributedstorage.com/"
target="_blank"
rel="noreferrer"
>
<img src="images/dss.svg" alt="DSS Logo" />
<Image src="/images/dss.svg" alt="DSS Logo" width={322} height={112} />
</a>
<a
href="https://www.cloudflare.com/"
target="_blank"
rel="noreferrer"
>
<img src="images/Cloudflare.svg" alt="Cloudflare Logo" />
<Image src="/images/Cloudflare.svg" alt="Cloudflare Logo" width={322} height={89} />
</a>
</Slider>
</div>
Expand Down
1 change: 1 addition & 0 deletions sass/_about.scss
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
padding: 6px;
border-radius: 6px;
margin: 0;
overflow: auto;
}
}
}
Expand Down
Loading