Commit e3b48dbb authored by 周宏民's avatar 周宏民

fix: 确山 历史数据,grid模式,只有个图表时,100%显示

parent f2829e5b
......@@ -77,7 +77,7 @@ const GridChart = memo((props) => {
option: option,
};
});
return _options
return _options;
}, [gridData, smooth, curveCenter]);
return (
......@@ -88,7 +88,14 @@ const GridChart = memo((props) => {
!item.option.series.length ||
!item.option.series.find((e) => e.data && e.data.length > 0);
return (
<div key={item.key} className={`${prefixCls}-grid-item`}>
<div
key={item.key}
className={`${prefixCls}-grid-item`}
style={{
height: gridData.length === 1 ? '100%' : '',
width: gridData.length === 1 ? '100%' : '',
}}
>
<div className={`${prefixCls}-grid-item-wrap`}>
<ChartTitle prefixCls={prefixCls} title={sensorName} unit={unit} />
{isEmpty ? (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment