Commit 79260866 authored by 吕祺's avatar 吕祺 ⛹🏽

update warning header

parent b33ec8c3
...@@ -83,6 +83,11 @@ ...@@ -83,6 +83,11 @@
color: #444; color: #444;
cursor: pointer; cursor: pointer;
} }
.header-index.emphasis-warn{
background: #ffcb05;
line-height: 1;
padding: 4px 4px 0;
}
.header-index a { .header-index a {
color: #444; color: #444;
text-decoration: none; text-decoration: none;
......
...@@ -19,11 +19,12 @@ export class Header extends React.PureComponent { ...@@ -19,11 +19,12 @@ export class Header extends React.PureComponent {
this.renderLinks = this.renderLinks.bind(this) this.renderLinks = this.renderLinks.bind(this)
this.renderCollapse = this.renderCollapse.bind(this) this.renderCollapse = this.renderCollapse.bind(this)
} }
genLink(en, curPage, path, txt, txtEN, query=null) { genLink(en, curPage, path, txt, txtEN, query=null, emphasis=false) {
return ( return (
<span <span
className={classnames({ className={classnames({
'header-index': true, 'header-index': true,
'emphasis-warn': emphasis,
active: curPage === path active: curPage === path
})} })}
> >
...@@ -176,7 +177,7 @@ export class Header extends React.PureComponent { ...@@ -176,7 +177,7 @@ export class Header extends React.PureComponent {
ronghuiEN ronghuiEN
)} )}
{this.genLink(en, curPage + '.html', 'news.html', news, newsEN)} {this.genLink(en, curPage + '.html', 'news.html', news, newsEN)}
{this.genLink(en, curPage + '.html', 'post.html', warn, warnEN, {t: "news", d: "20210514014133435"})} {this.genLink(en, curPage + '.html', 'post.html', warn, warnEN, {t: "news", d: "20210514014133435"}, true)}
{!collapse && en !== null && ( {!collapse && en !== null && (
<span <span
className={classnames({ className={classnames({
......
...@@ -6,11 +6,11 @@ portfolio: 投资企业 ...@@ -6,11 +6,11 @@ portfolio: 投资企业
team: 团队 team: 团队
ronghui: 榕汇 ronghui: 榕汇
news: 动态 news: 动态
warn: 声明 warn: 严正声明
aboutEN: About aboutEN: About
portfolioEN: Portfolio portfolioEN: Portfolio
teamEN: Team teamEN: Team
ronghuiEN: Community ronghuiEN: Community
newsEN: News newsEN: News
warnEN: 声明 warnEN: 严正声明
--- ---
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