-
Notifications
You must be signed in to change notification settings - Fork 127
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 Jagpreet153/fix-issue-143
fix issue #167
- Loading branch information
Showing
6 changed files
with
61 additions
and
1 deletion.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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
Large diffs are not rendered by default.
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
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,10 @@ | ||
.pre{ | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
} | ||
|
||
.preloader{ | ||
width: 30vw; | ||
height: 30vh; | ||
} |
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,29 @@ | ||
import React ,{useState,useEffect} from 'react'; | ||
import pre from '../Images/preloader.json' | ||
import Lottie from 'lottie-react'; | ||
import App from '../App'; | ||
import './Preloader.css' | ||
function Preloader() { | ||
const [loading,setLoading]=useState(false); | ||
useEffect(()=>{ | ||
setLoading(true); | ||
setTimeout(() =>{ | ||
setLoading(false) | ||
},1700) | ||
},[]) | ||
return ( | ||
|
||
loading ? | ||
<div className='pre'> | ||
<Lottie className="preloader" animationData={pre}/> | ||
</div> | ||
|
||
: | ||
//Rest Code | ||
<App/> | ||
|
||
|
||
|
||
); | ||
} | ||
export default Preloader; |