缅怀逝者,致敬英雄 - 悼念抗疫英雄烈士

为表达全国各族人民对抗击新冠肺炎疫情斗争牺牲烈士和逝世同胞的深切哀悼,本博客响应号召,2020年4月4日全站黑白默哀一天。

基于Icarus 主题作出的修改

CSS

1
2
3
4
5
6
7
.event-4-4-Memorial-Day {
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
-ms-filter: grayscale(100%);
-o-filter: grayscale(100%);
filter: grayscale(100%);
}

JS

1
2
3
4
5
6
7
8
9
10
11
12
13
14
let now = new Date();
let timeData = {
year: now.getFullYear(),
month: now.getMonth() + 1,
date: now.getDate(),
hour: now.getHours(),
minute: now.getMinutes(),
second: now.getSeconds(),
}
// 4.4 Memorial Day
if(timeData.month === 4 && timeData.date === 4){
$('html').addClass('event-4-4-Memorial-Day');
$('#event-4-4-Memorial-Day').show();
}

横幅 HTML

1
2
3
4
5
6
7
8
9
10
11
12
<div class="container" id="event-4-4-Memorial-Day" style="display: none;">
<div class="card" style="margin-bottom: 1.5rem; background-color: #555555;">
<div class="card-content">
<h1 class="title is-size-3 is-size-4-mobile has-text-weight-normal" style="text-align: center; color: #FFFFFF !important;">
缅怀逝者,致敬英雄
</h1>
<h1 class="title is-size-5 is-size-6-mobile has-text-weight-normal" style="text-align: center; color: #FFFFFF !important;">
Remember the dead and honor the hero
</h1>
</div>
</div>
</div>

评论

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×