feat(system-resources-widget): add has-shadow option (#4093)
This commit is contained in:
1 parent
312e084e2c
commit
3c2e6a852f
10 files changed
+37
-15
No files matched your search
@@ -10,10 +10,12 @@ import { CommonChart } from "./common-chart";
|
||||
export const NetworkTrafficChart = ({
|
||||
usageOverTime,
|
||||
isUp,
|
||||
hasShadow,
|
||||
labelDisplayMode,
|
||||
}: {
|
||||
usageOverTime: number[];
|
||||
isUp: boolean;
|
||||
hasShadow: boolean;
|
||||
labelDisplayMode: LabelDisplayModeOption;
|
||||
}) => {
|
||||
const chartData = usageOverTime.map((usage, index) => ({ index, usage }));
|
||||
@@ -31,6 +33,7 @@ export const NetworkTrafficChart = ({
|
||||
icon={isUp ? IconArrowUp : IconArrowDown}
|
||||
yAxisProps={{ domain: [0, upperBound] }}
|
||||
lastValue={`${humanFileSize(Math.round(max))}/s`}
|
||||
chartType={hasShadow ? "area" : "line"}
|
||||
labelDisplayMode={labelDisplayMode}
|
||||
tooltipProps={{
|
||||
content: ({ payload }) => {
|
||||
|
||||
Reference in new issue
Block a user