From 7f75345c03c21336cff68370eede0879c6bdf6ab Mon Sep 17 00:00:00 2001 From: Haishan Date: Tue, 30 Oct 2018 23:37:42 +0800 Subject: refactor(chart): lazy load Chart.js with suspense - chore: add ico favicon - chore: lint - chore: add react-hooks lint rules --- src/components/Loading.js | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'src/components/Loading.js') diff --git a/src/components/Loading.js b/src/components/Loading.js index 1b8d373..7949a4b 100644 --- a/src/components/Loading.js +++ b/src/components/Loading.js @@ -1,14 +1,19 @@ import React from 'react'; +import PropTypes from 'prop-types'; -import style from './Loading.module.scss'; +import s0 from './Loading.module.scss'; -const Loading = () => { +const Loading = ({ height }) => { + const style = height ? { height } : {}; return ( -
-
-
+
+
); }; +Loading.propTypes = { + height: PropTypes.string +}; + export default Loading; -- cgit v1.3.1