diff --git a/frontend/src/app.css b/frontend/src/app.css
index 0ef333e86e..ab615b4b49 100644
--- a/frontend/src/app.css
+++ b/frontend/src/app.css
@@ -46,6 +46,7 @@ body {
background-color: #e2e8f0;
z-index: 9999;
box-shadow: none;
+ fill: none;
}
.skeleton::before {
diff --git a/frontend/src/assets/icons/projectIcon.svg b/frontend/src/assets/icons/projectIcon.svg
new file mode 100644
index 0000000000..d4604c184d
--- /dev/null
+++ b/frontend/src/assets/icons/projectIcon.svg
@@ -0,0 +1,9 @@
+
diff --git a/frontend/src/common.styles.js b/frontend/src/common.styles.js
index 61c6f9de38..f962781817 100644
--- a/frontend/src/common.styles.js
+++ b/frontend/src/common.styles.js
@@ -62,4 +62,21 @@ export const useCommonStyles = makeStyles(theme => ({
fontWeight: 'bold',
marginBottom: '0.5rem',
},
+ fadeInBottomStart: {
+ opacity: '0',
+ position: 'fixed',
+ right: '40px',
+ bottom: '40px',
+ transform: 'translateY(400px)',
+ },
+ fadeInBottomEnter: {
+ transform: 'translateY(0)',
+ opacity: '1',
+ transition: 'transform 0.6s ease, opacity 1s ease',
+ },
+ fadeInBottomLeave: {
+ transform: 'translateY(400px)',
+ opacity: '0',
+ transition: 'transform 1.25s ease, opacity 1s ease',
+ },
}));
diff --git a/frontend/src/component/Reporting/ReportCard/ReportCard.jsx b/frontend/src/component/Reporting/ReportCard/ReportCard.jsx
index 927db4b64b..368f6071d1 100644
--- a/frontend/src/component/Reporting/ReportCard/ReportCard.jsx
+++ b/frontend/src/component/Reporting/ReportCard/ReportCard.jsx
@@ -7,61 +7,16 @@ import CheckIcon from '@material-ui/icons/Check';
import ReportProblemOutlinedIcon from '@material-ui/icons/ReportProblemOutlined';
import ConditionallyRender from '../../common/ConditionallyRender/ConditionallyRender';
-import { isFeatureExpired } from '../utils';
-
import styles from './ReportCard.module.scss';
-const ReportCard = ({ features }) => {
- const getActiveToggles = () => {
- const result = features.filter(feature => !feature.stale);
-
- if (result === 0) return 0;
-
- return result;
- };
-
- const getPotentiallyStaleToggles = activeToggles => {
- const result = activeToggles.filter(
- feature => isFeatureExpired(feature) && !feature.stale
- );
-
- return result;
- };
-
- const getHealthRating = (
- total,
- staleTogglesCount,
- potentiallyStaleTogglesCount
- ) => {
- const startPercentage = 100;
-
- const stalePercentage = (staleTogglesCount / total) * 100;
-
- const potentiallyStalePercentage =
- (potentiallyStaleTogglesCount / total) * 100;
-
- return Math.round(
- startPercentage - stalePercentage - potentiallyStalePercentage
- );
- };
-
- const total = features.length;
- const activeTogglesArray = getActiveToggles();
- const potentiallyStaleToggles =
- getPotentiallyStaleToggles(activeTogglesArray);
-
- const activeTogglesCount = activeTogglesArray.length;
- const staleTogglesCount = features.length - activeTogglesCount;
- const potentiallyStaleTogglesCount = potentiallyStaleToggles.length;
-
- const healthRating = getHealthRating(
- total,
- staleTogglesCount,
- potentiallyStaleTogglesCount
- );
-
- const healthLessThan50 = healthRating < 50;
- const healthLessThan75 = healthRating < 75;
+const ReportCard = ({
+ health,
+ activeCount,
+ staleCount,
+ potentiallyStaleCount,
+}) => {
+ const healthLessThan50 = health < 50;
+ const healthLessThan75 = health < 75;
const healthClasses = classnames(styles.reportCardHealthRating, {
[styles.healthWarning]: healthLessThan75,
@@ -71,23 +26,21 @@ const ReportCard = ({ features }) => {
const renderActiveToggles = () => (
<>
{healthRating}%
- } + condition={health > -1} + show={{health}%
} />