WIP on several user stories. BOD-10 BOD-52

This commit is contained in:
Patrick Fic
2020-03-23 17:40:48 -07:00
parent f04ba766ad
commit 7d33484294
10 changed files with 63 additions and 94 deletions

View File

@@ -1,8 +1,8 @@
import { useNProgress } from "@tanem/react-nprogress";
import React from "react";
import { connect } from "react-redux";
import { createStructuredSelector } from "reselect";
import { selectLoading } from "../../redux/application/application.selectors";
import { useNProgress } from "@tanem/react-nprogress";
const mapStateToProps = createStructuredSelector({
loading: selectLoading
@@ -11,6 +11,7 @@ const mapStateToProps = createStructuredSelector({
export default connect(mapStateToProps, null)(GlobalLoadingHeader);
function GlobalLoadingHeader({ loading }) {
const { animationDuration, isFinished, progress } = useNProgress({
isAnimating: loading
});
@@ -20,8 +21,7 @@ function GlobalLoadingHeader({ loading }) {
opacity: isFinished ? 0 : 1,
pointerEvents: "none",
transition: `opacity ${animationDuration}ms linear`
}}
>
}}>
<div
style={{
background: "#29d",
@@ -33,8 +33,7 @@ function GlobalLoadingHeader({ loading }) {
transition: `margin-left ${animationDuration}ms linear`,
width: "100%",
zIndex: 1031
}}
>
}}>
<div
style={{
boxShadow: "0 0 10px #29d, 0 0 5px #29d",