diff --git a/src/App.js b/src/App.js
index 8799135..668a3ff 100644
--- a/src/App.js
+++ b/src/App.js
@@ -13,7 +13,7 @@ import Form from './scenes/Form';
import Line from './scenes/Line';
import Pie from './scenes/Pie';
import FAQ from './scenes/FAQ';
-// import Geograph from './scenes/Geograph';
+import Geography from './scenes/Geography';
import Calendar from './scenes/Calendar';
function App() {
@@ -35,7 +35,7 @@ function App() {
} />
} />
} />
- {/* } /> */}
+ } />
} />
} />
diff --git a/src/components/Shared/Geography/index.jsx b/src/components/Shared/Geography/index.jsx
new file mode 100644
index 0000000..bf3f29e
--- /dev/null
+++ b/src/components/Shared/Geography/index.jsx
@@ -0,0 +1,97 @@
+import { useTheme } from '@mui/material';
+import { ResponsiveChoropleth } from '@nivo/geo';
+import PropTypes from 'prop-types';
+import { geoFeatures } from '../../../data/mockGeoFeatures';
+import { tokens } from '../../../theme';
+
+const GeographyChart = ({ data, isDashboard = false }) => {
+ const theme = useTheme();
+ const colors = tokens(theme.palette.mode);
+ return (
+
+ );
+};
+
+GeographyChart.propTypes = {
+ data: PropTypes.oneOfType(['object']).isRequired,
+ isDashboard: PropTypes.bool.isRequired,
+};
+
+export default GeographyChart;
diff --git a/src/components/Shared/LineChart/index.jsx b/src/components/Shared/LineChart/index.jsx
index 6fe09da..4158d8f 100644
--- a/src/components/Shared/LineChart/index.jsx
+++ b/src/components/Shared/LineChart/index.jsx
@@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
import { useTheme } from '@mui/material';
import { tokens } from '../../../theme';
-const LineChart = ({ data, isDashbord = false }) => {
+const LineChart = ({ data, isDashboard = false }) => {
const theme = useTheme();
const colors = tokens(theme.palette.mode);
@@ -43,7 +43,7 @@ const LineChart = ({ data, isDashbord = false }) => {
},
},
}}
- colors={isDashbord ? { datum: 'color' } : { scheme: 'nivo' }}
+ colors={isDashboard ? { datum: 'color' } : { scheme: 'nivo' }}
margin={{
top: 50, right: 110, bottom: 50, left: 60,
}}
@@ -63,7 +63,7 @@ const LineChart = ({ data, isDashbord = false }) => {
tickSize: 5,
tickPadding: 5,
tickRotation: 0,
- legend: isDashbord ? undefined : 'transportation',
+ legend: isDashboard ? undefined : 'transportation',
legendOffset: 36,
legendPosition: 'middle',
}}
@@ -71,7 +71,7 @@ const LineChart = ({ data, isDashbord = false }) => {
tickSize: 5,
tickPadding: 5,
tickRotation: 0,
- legend: isDashbord ? undefined : 'count',
+ legend: isDashboard ? undefined : 'count',
legendOffset: -40,
legendPosition: 'middle',
}}
@@ -116,7 +116,7 @@ const LineChart = ({ data, isDashbord = false }) => {
LineChart.propTypes = {
data: PropTypes.oneOfType(['object']).isRequired,
- isDashbord: PropTypes.bool.isRequired,
+ isDashboard: PropTypes.bool.isRequired,
};
export default LineChart;
diff --git a/src/components/Shared/PieChart/index.jsx b/src/components/Shared/PieChart/index.jsx
index 1ebdd34..8329a86 100644
--- a/src/components/Shared/PieChart/index.jsx
+++ b/src/components/Shared/PieChart/index.jsx
@@ -37,6 +37,11 @@ const PieChart = ({ data }) => {
fill: colors.grey[100],
},
},
+ tooltip: {
+ container: {
+ color: colors.primary[500],
+ },
+ },
}}
margin={{
top: 40, right: 80, bottom: 80, left: 80,
diff --git a/src/scenes/Geography/index.jsx b/src/scenes/Geography/index.jsx
new file mode 100644
index 0000000..3b58c12
--- /dev/null
+++ b/src/scenes/Geography/index.jsx
@@ -0,0 +1,22 @@
+import { Box, useTheme } from '@mui/material';
+import GeographyChart from '../../components/Shared/Geography';
+import Header from '../../components/Shared/Header/Header';
+import { mockGeographyData as data } from '../../data/mockData';
+import { tokens } from '../../theme';
+
+console.log(GeographyChart);
+const Geography = () => {
+ const theme = useTheme();
+ const colors = tokens(theme.palette.mode);
+
+ return (
+
+
+
+
+
+
+ );
+};
+
+export default Geography;