ok
This commit is contained in:
+8
-3
@@ -45,8 +45,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.card img {
|
.card img {
|
||||||
width: 48px;
|
width: 100%;
|
||||||
height: 48px;
|
max-width: 180px;
|
||||||
|
height: auto; /* 自动保持比例 */
|
||||||
object-fit: contain;
|
object-fit: contain;
|
||||||
margin-bottom: 6px;
|
margin-bottom: 6px;
|
||||||
}
|
}
|
||||||
@@ -79,7 +80,11 @@
|
|||||||
<div class="card-container">
|
<div class="card-container">
|
||||||
{% for item in ptqy %}
|
{% for item in ptqy %}
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<img src="{{ icons.serendipity.劝学记 }}" alt="{{ item.event }}">
|
{% if icons.serendipity.get(item.event) %}
|
||||||
|
<img src="{{ icons.serendipity[item.event] }}" alt="{{ item.event }}">
|
||||||
|
{% else %}
|
||||||
|
<div class="event-name">{{ item.event }}</div>
|
||||||
|
{% endif %}
|
||||||
<div class="time">{{ item.time }}</div>
|
<div class="time">{{ item.time }}</div>
|
||||||
</div>
|
</div>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|||||||
Reference in New Issue
Block a user