LFFE-10 responsive debug
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
import Chart from "@/core/components/Chart";
|
||||
import {useTheme} from "@mui/material/styles";
|
||||
import {useMediaQuery} from "@mui/material";
|
||||
|
||||
|
||||
const Pie = ({data}) => {
|
||||
const theme = useTheme();
|
||||
const windowsWidth = window.innerWidth;
|
||||
const upperSm = useMediaQuery((theme.breakpoints.up("sm")))
|
||||
const specialOption = {
|
||||
title: {
|
||||
text: undefined,
|
||||
@@ -21,7 +22,7 @@ const Pie = ({data}) => {
|
||||
},
|
||||
},
|
||||
legend: {
|
||||
show: windowsWidth > theme.breakpoints.values.sm
|
||||
show: upperSm
|
||||
}
|
||||
};
|
||||
const series = data.map((item) => +item.percentage)
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import Chart from "@/core/components/Chart";
|
||||
import {useTheme} from "@mui/material/styles";
|
||||
import {useMediaQuery} from "@mui/material";
|
||||
|
||||
const PolarChart = ({data}) => {
|
||||
const theme = useTheme();
|
||||
const windowsWidth = window.innerWidth;
|
||||
const upperSm = useMediaQuery((theme.breakpoints.up("sm")))
|
||||
const specialOption = {
|
||||
title: {
|
||||
text: undefined,
|
||||
@@ -28,7 +29,7 @@ const PolarChart = ({data}) => {
|
||||
},
|
||||
},
|
||||
legend: {
|
||||
show: windowsWidth > theme.breakpoints.values.sm
|
||||
show: upperSm
|
||||
}
|
||||
};
|
||||
const series = data.map((item) => +item.percentage)
|
||||
|
||||
Reference in New Issue
Block a user