forked from grafana/grafana-infinity-datasource
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
8 changed files
with
191 additions
and
105 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
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,37 @@ | ||
import React from 'react'; | ||
|
||
export const Badges = () => { | ||
const badges = [ | ||
{ | ||
link: 'https://github.com/yesoreyeram/grafana-infinity-datasource/actions?query=workflow%3A%22Build+%26+Publish%22', | ||
imgSrc: 'https://github.com/yesoreyeram/grafana-infinity-datasource/workflows/Build%20&%20Publish/badge.svg', | ||
}, | ||
{ | ||
link: 'https://github.com/yesoreyeram/grafana-infinity-datasource/issues', | ||
imgSrc: 'https://img.shields.io/github/issues/yesoreyeram/grafana-infinity-datasource', | ||
}, | ||
{ | ||
link: 'https://github.com/yesoreyeram/grafana-infinity-datasource/blob/main/LICENSE', | ||
imgSrc: 'https://img.shields.io/github/license/yesoreyeram/grafana-infinity-datasource', | ||
}, | ||
{ | ||
link: 'http://makeapullrequest.com', | ||
imgSrc: 'https://img.shields.io/badge/PRs-welcome-brightgreen.svg', | ||
}, | ||
{ | ||
link: 'https://GitHub.com/yesoreyeram/grafana-infinity-datasource/graphs/commit-activity', | ||
imgSrc: 'https://img.shields.io/badge/Maintained%3F-yes-green.svg', | ||
}, | ||
]; | ||
return ( | ||
<p className="text-center my-4"> | ||
{badges.map((b) => { | ||
return ( | ||
<a href={b.link} target="_blank" className="mx-2" rel="noreferrer"> | ||
<img src={b.imgSrc} /> | ||
</a> | ||
); | ||
})} | ||
</p> | ||
); | ||
}; |
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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import React, { useState, useEffect } from 'react'; | ||
import { Link } from 'gatsby'; | ||
import { TypeWriter } from './TypeWritter'; | ||
|
||
export const HeroSection = () => { | ||
const [hasRan, setHasRan] = useState(false); | ||
const [screenSize, setScreenSize] = useState({ height: 0, width: 0 }); | ||
useEffect(() => { | ||
if (!hasRan) { | ||
setHasRan(true); | ||
updateScreenSize(); | ||
} | ||
window.addEventListener('resize', updateScreenSize); | ||
return () => window.removeEventListener('resize', updateScreenSize); | ||
}, [screenSize, hasRan]); | ||
const updateScreenSize = () => { | ||
const width = window.innerWidth; | ||
const height = window.innerHeight; | ||
setScreenSize({ width, height }); | ||
}; | ||
return ( | ||
<div className="position-relative overflow-hidden mainbg" style={{ width: '100%', height: `${screenSize.height - 40}px` }}> | ||
<div className="col-md-12 p-lg-5 mx-auto" style={{ marginTop: `${screenSize.height / 4}px` }}> | ||
<h1 className="display-4 fw-bolder" id="banner-title"> | ||
Grafana Infinity data source | ||
</h1> | ||
<br /> | ||
<TypeWriter /> | ||
<br /> | ||
<p className="fw-normal text-white"> | ||
<span style={{ color: '#ccc' }}>Visualize data from JSON, CSV, XML, GraphQL, HTML & REST APIs. Also turns any website into grafana dashboard.</span> | ||
</p> | ||
<br /> | ||
<Link className="btn btn-primary" to="/getting-started"> | ||
Getting started | ||
</Link> | ||
<a className="btn btn-primary mx-4" href="https://grafana-infinity-datasource.herokuapp.com/d/try/try?orgId=1&editPanel=2" target="_blank" rel="noreferrer"> | ||
Try online | ||
</a> | ||
</div> | ||
</div> | ||
); | ||
}; |
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,41 @@ | ||
import React from 'react'; | ||
import Typewriter from 'typewriter-effect'; | ||
export const TypeWriter = () => { | ||
return ( | ||
<> | ||
<h3 style={{ color: 'whitesmoke' }}> | ||
<Typewriter | ||
options={{ | ||
autoStart: true, | ||
loop: true, | ||
}} | ||
onInit={(typewriter) => { | ||
typewriter | ||
.pasteString('Spice up Grafana with data from ', this) | ||
.typeString('CSV') | ||
.pauseFor(1000) | ||
.deleteChars(3) | ||
.typeString('JSON') | ||
.pauseFor(1000) | ||
.deleteChars(4) | ||
.typeString('GraphQL') | ||
.pauseFor(1000) | ||
.deleteChars(7) | ||
.typeString('XML') | ||
.pauseFor(1000) | ||
.deleteChars(3) | ||
.typeString('HTML') | ||
.pauseFor(1000) | ||
.deleteChars(4) | ||
.typeString('beautiful series') | ||
.pauseFor(1000) | ||
.deleteChars(16) | ||
.typeString('Infinity Datasource') | ||
.pauseFor(5000) | ||
.start(); | ||
}} | ||
/> | ||
</h3> | ||
</> | ||
); | ||
}; |
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