Browse Source

feat:修改标题样式

master
zhaobing 9 months ago
parent
commit
b51fda8c6d
  1. 7
      web-screen/client/src/layout/components/header/index.js
  2. 3
      web-screen/client/src/layout/components/header/style.css

7
web-screen/client/src/layout/components/header/index.js

@ -29,6 +29,7 @@ const Header = props => {
const [deviceManageTabsVisible, setDeviceManageTabsVisible] = useState(false)
const [currentSubMenuTab, setCurrentSubMenuTab] = useState('')
const [tab, setTab] = useState('leader')
const [projectName, setProjectName ]= useState('')
const [weather, setWeather] = useState([])
let headerTitleStyle = {
position: 'absolute',
@ -39,6 +40,7 @@ const Header = props => {
fontWeight: 600,
fontFamily: 'PangMenZhengDao',
letterSpacing: '.5231rem',
width:'39rem'
}
let headerTabStyle = {
width: '4.375rem',
@ -52,12 +54,15 @@ const Header = props => {
useEffect(() => {
queryWeather()
const projectName = JSON.parse(sessionStorage.getItem('user')).projectName
setProjectName(projectName)
const timeUpdate = setInterval(() => {
queryWeather()
}, WEATHERMARGIN)
return () => {
clearInterval(timeUpdate)
}
}, [])
const queryWeather = () => {
@ -105,7 +110,7 @@ const Header = props => {
<div className={styles['header-fold']}>
{/* <img src='/assets/images/logo.svg' style={{ margin: '-14px 12px 0 0', height: 24 }} /> */}
<div className={styles['header-title']} style={{}}>
<span style={headerTitleStyle}>河州路河州路河州路河州路河州路</span>
<span style={headerTitleStyle}>{projectName}</span>
</div>
</div>
<div

3
web-screen/client/src/layout/components/header/style.css

@ -18,6 +18,9 @@
display: inline-block;
color: #fff;
text-shadow: 0 .25rem .1875rem rgba(54, 77, 108, 0.20);
text-align: center;
width: 39rem;
line-height: 4.75rem;
}
.header-title .title-cn {

Loading…
Cancel
Save