-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #325 from celestiaorg/feature/light-node-page
Feature/light node page
- Loading branch information
Showing
31 changed files
with
404 additions
and
395 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,40 @@ | ||
import * as React from "react" | ||
import {Link} from "gatsby"; | ||
import * as React from "react"; | ||
import { Link } from "gatsby"; | ||
import { AnchorLink } from "gatsby-plugin-anchor-links"; | ||
|
||
export default class Button extends React.Component { | ||
render() { | ||
var buttonTitle = this.props.text | ||
render() { | ||
var buttonTitle = this.props.text; | ||
|
||
if(this.props.class.includes('external') || this.props.class.includes('external-big')){ | ||
buttonTitle = this.props.text + '<i class="icon-external-link"></i>'; | ||
} | ||
if(this.props.class === 'icon'){ | ||
buttonTitle = this.props.text + '<i class="icon-'+this.props.icon+'"></i>'; | ||
} | ||
if (this.props.class.includes("external") || this.props.class.includes("external-big")) { | ||
buttonTitle = this.props.text + '<i class="icon-external-link"></i>'; | ||
} | ||
if (this.props.class === "icon") { | ||
buttonTitle = this.props.text + '<i class="icon-' + this.props.icon + '"></i>'; | ||
} | ||
|
||
if(this.props.type === 'internal'){ | ||
return <Link to={`${this.props.url}`} className={'button button-'+this.props.class} dangerouslySetInnerHTML={{__html: buttonTitle}}/> | ||
} | ||
else if(this.props.type === 'external' || this.props.type === 'external-big'){ | ||
return <a href={`${this.props.url}`} target={'_blank'} rel="noreferrer" className={'button button-'+this.props.class} aria-label={this.props.text} dangerouslySetInnerHTML={{__html: buttonTitle}}/> | ||
} | ||
else if(this.props.type === 'anchor'){ | ||
return ( | ||
<AnchorLink to={`${this.props.url}`} className={'button button-'+this.props.class}> | ||
{buttonTitle} | ||
</AnchorLink> | ||
) | ||
} | ||
} | ||
if (this.props.type === "internal") { | ||
return ( | ||
<Link to={`${this.props.url}`} className={"button button-" + this.props.class} dangerouslySetInnerHTML={{ __html: buttonTitle }} /> | ||
); | ||
} else if (this.props.type === "external" || this.props.type === "external-big") { | ||
return ( | ||
<a | ||
href={`${this.props.url}`} | ||
target={"_blank"} | ||
rel='noreferrer' | ||
className={"button button-" + this.props.class} | ||
aria-label={this.props.text} | ||
dangerouslySetInnerHTML={{ __html: buttonTitle }} | ||
/> | ||
); | ||
} else if (this.props.type === "anchor") { | ||
let path = typeof window !== "undefined" ? window.location.pathname : "/"; | ||
return ( | ||
<AnchorLink to={`${path}#${this.props.url}`} className={"button button-" + this.props.class}> | ||
{buttonTitle} | ||
</AnchorLink> | ||
); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
export const heroData = { | ||
title: 'The first modular blockchain network', | ||
text: 'Celestia is a modular data availability network that securely scales with the number of users, making it easy for anyone to launch their own blockchain.', | ||
buttons:[ | ||
{ | ||
text: 'Build modular', | ||
class: 'simple plausible-event-name=Build_Modular_Button--Homepage-Hero', | ||
type: 'internal', | ||
url: '/developer-portal/' | ||
}, | ||
{ | ||
text: 'Explore', | ||
class: 'white plausible-event-name=Explore_Button--Homepage-Hero', | ||
type: 'anchor', | ||
url: '/#explore-celestia' | ||
} | ||
] | ||
} | ||
title: "The first modular blockchain network", | ||
text: "Celestia is a modular data availability network that securely scales with the number of users, making it easy for anyone to launch their own blockchain.", | ||
buttons: [ | ||
{ | ||
text: "Build modular", | ||
class: "simple plausible-event-name=Build_Modular_Button--Homepage-Hero", | ||
type: "internal", | ||
url: "/developer-portal/", | ||
}, | ||
{ | ||
text: "Explore", | ||
class: "white plausible-event-name=Explore_Button--Homepage-Hero", | ||
type: "anchor", | ||
url: "explore-celestia", | ||
}, | ||
], | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
export const heroData = { | ||
title: "Run a light node", | ||
text: "Join the collective powering an open internet. Run a light node on Celestia to secure your assets and become sovereign.", | ||
title: "Directly verify", | ||
text: "Join the network or integrate the Celestia light node.", | ||
buttons: [ | ||
{ | ||
text: "Show me how to start", | ||
text: "Run a node", | ||
class: "simple", | ||
type: "anchor", | ||
url: "start-up-a-node", | ||
}, | ||
{ | ||
text: "Ask a question", | ||
text: "Integrate", | ||
class: "white", | ||
type: "anchor", | ||
url: "https://www.google.com/", | ||
} | ||
url: "integrate", | ||
}, | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
export const joinTheNetwork = { | ||
title: "Join the network", | ||
items: [ | ||
{ | ||
id: 1, | ||
title: "Beginner", | ||
text: "Deploy a light node in two commands with Vimana’s on-demand hardware.", | ||
type: "external", | ||
image: "run-a-node/beginner-image.png", | ||
link: { | ||
text: "Deploy on Vimana", | ||
url: "https://docs.vistara.dev/the-vistara-workflow/getting-started", | ||
}, | ||
}, | ||
{ | ||
id: 2, | ||
title: "Intermediate", | ||
text: "Power up a light node in under 3 minutes with Docker.", | ||
type: "external", | ||
image: "run-a-node/intermediate-image.png", | ||
link: { | ||
text: "Follow the tutorial", | ||
url: "https://docs.celestia.org/nodes/docker-images", | ||
}, | ||
}, | ||
{ | ||
id: 3, | ||
title: "Advanced", | ||
text: "Start a light node with the command line.", | ||
type: "external", | ||
image: "run-a-node/advanced-image.png", | ||
link: { | ||
text: "Read the guide", | ||
url: "https://docs.celestia.org/nodes/light-node", | ||
}, | ||
}, | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
export const lightNode = { | ||
title: "Light nodes for developers", | ||
button: { | ||
text: "Start light node", | ||
class: "simple", | ||
type: "external", | ||
url: "https://docs.celestia.org/nodes/light-node", | ||
}, | ||
description: "How developers can use a Celestia light node for their chain", | ||
items: [ | ||
{ | ||
id: 1, | ||
title: "Publish data", | ||
text: "Publish transaction data to Celestia’s DA network.", | ||
type: "external", | ||
image: "run-a-node/publish-image.png", | ||
link: { | ||
text: "Submit data to Celestia", | ||
url: "https://docs.celestia.org/developers/node-tutorial", | ||
}, | ||
}, | ||
{ | ||
id: 2, | ||
title: "Retrieve data", | ||
text: "Retrieve transaction data from Celestia’s DA network.", | ||
type: "external", | ||
image: "run-a-node/retrieve-image.png", | ||
link: { | ||
text: "Retrieve data from Celestia", | ||
url: "https://docs.celestia.org/developers/node-tutorial#retrieving-data", | ||
}, | ||
}, | ||
{ | ||
id: 3, | ||
title: "Manage Tia wallet", | ||
text: "Generate a Celestia wallet to store Tia and pay for publishing transaction data to Celestia.", | ||
type: "external", | ||
image: "run-a-node/manage-image.png", | ||
link: { | ||
text: "Setup wallet", | ||
url: "https://docs.celestia.org/developers/celestia-node-key", | ||
}, | ||
}, | ||
], | ||
}; |
Oops, something went wrong.