fix
This commit is contained in:
parent
4aaa12b630
commit
8f3a94f431
@ -1,35 +1,33 @@
|
|||||||
|
import React, { useState } from 'react';
|
||||||
|
|
||||||
import React, { useState } from 'react'
|
import icon1 from '@/assets/CenterChart2icon1.svg';
|
||||||
|
import icon2 from '@/assets/CenterChart2icon2.svg';
|
||||||
|
import icon3 from '@/assets/CenterChart2icon3.svg';
|
||||||
|
import icon4 from '@/assets/CenterChart2icon4.svg';
|
||||||
|
|
||||||
import icon1 from '@/assets/CenterChart2icon1.svg'
|
import cls from './leftbox.module.less';
|
||||||
import icon2 from '@/assets/CenterChart2icon2.svg'
|
|
||||||
import icon3 from '@/assets/CenterChart2icon3.svg'
|
|
||||||
import icon4 from '@/assets/CenterChart2icon4.svg'
|
|
||||||
|
|
||||||
import cls from './leftbox.module.less'
|
|
||||||
|
|
||||||
const Chart2 = () => {
|
const Chart2 = () => {
|
||||||
|
const [data, setData] = useState([
|
||||||
|
{ icon: icon1, label: '换火时间', value: '08:34' },
|
||||||
|
{ icon: icon3, label: '剩余时间', value: '1170s' },
|
||||||
|
{ icon: icon2, label: '当前火向', value: '南向' },
|
||||||
|
// { icon: icon4, label: '车间温度', value: '28℃' },
|
||||||
|
]);
|
||||||
|
|
||||||
const [data, setData] = useState([
|
return (
|
||||||
{ icon: icon1, label: '换火时间', value: '12:08:34' },
|
<div className={`${cls.leftbox} flex h-half`}>
|
||||||
{ icon: icon3, label: '剩余时间', value: '11h' },
|
{data.map((item) => (
|
||||||
{ icon: icon2, label: '当前火向', value: '南向' },
|
<div className={cls.box} key={item.label}>
|
||||||
// { icon: icon4, label: '车间温度', value: '28℃' },
|
<img src={item.icon} alt="Error" className="box__logo" />
|
||||||
])
|
<div className={cls.box__inner}>
|
||||||
|
<h2 className={cls.box__label}>{item.label}</h2>
|
||||||
return (
|
<h2 className={cls.box__value}> {item.value}</h2>
|
||||||
<div className={`${cls.leftbox} flex h-half`}>
|
</div>
|
||||||
{data.map(item =>
|
</div>
|
||||||
<div className={cls.box} key={item.label}>
|
))}
|
||||||
<img src={item.icon} alt="Error" className='box__logo' />
|
</div>
|
||||||
<div className={cls.box__inner} >
|
);
|
||||||
<h2 className={cls.box__label}>{item.label}</h2>
|
};
|
||||||
<h2 className={cls.box__value}> {item.value}</h2>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
</div >
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
export default Chart2;
|
export default Chart2;
|
||||||
|
Loading…
Reference in New Issue
Block a user