Skip to content
This repository has been archived by the owner on Dec 3, 2019. It is now read-only.

Added countdown #89

Merged
merged 4 commits into from
Mar 1, 2019
Merged
Show file tree
Hide file tree
Changes from 2 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
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"react-scripts": "^2.1.3",
"react-tooltip": "^3.9.2",
"react-vertical-timeline-component": "^2.3.1",
"reactjs-countdown": "0.0.8",
"redux": "^4.0.1",
"redux-thunk": "^2.3.0",
"vertical-timeline-component-for-react": "^1.0.6"
Expand Down
4 changes: 4 additions & 0 deletions src/components/HomePage.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import EventsList from '../components/EventsList';
import Logo from '../img/anshumanvisallstackdeveloper.png';
import CountDown from 'reactjs-countdown';

const scrollDown = () => {
window.scrollTo({
Expand All @@ -15,6 +16,9 @@ const HomePage = () => (
<div className="homepage__logo-wrapper">
<img src={Logo} alt="Logo" className="homepage__logo" />
</div>
<div className="countdown">
<CountDown deadline="Sat, 02 Mar 2019 14:00:00 GMT"/>
</div>
<div className="scrollButton" onClick = {scrollDown}>
<span className = "scrollLink">
<img alt="Arrow Down Icon" src="https://www.solodev.com/assets/anchor/arrow-down.png"/>
Expand Down
33 changes: 33 additions & 0 deletions src/sass/pages/_homepage.scss
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
.homepage__logo {
max-width: 100%;
padding: 3%;
top: -15%;
position: relative;
}

.scrollButton {
Expand All @@ -43,3 +45,34 @@
}

}

.react-countdown {
display: inline-block;
margin: 0;
top: 66%;
left: 0;
right: 0;
position: absolute;
padding: 0;
}

.countdown {
text-align: center;
}

.react-countdown .digit {
font-size: 52px;
color: #c6c6c6;
}
.react-countdown .text {
font-size: 25px;
color: rgba(94, 201, 248, 0.9);
}

.react-countdown li:after {
right: -20px;
}

.react-countdown li {
margin: 0 15px;
}