diff --git a/app/static/style.css b/app/static/style.css index 036adbb..adbb4c3 100644 --- a/app/static/style.css +++ b/app/static/style.css @@ -135,7 +135,6 @@ code { background: var(--bg); padding: .15rem .4rem; border-radius: 4px; font-si .detail-meta dl { display: grid; grid-template-columns: auto 1fr; gap: .3rem 1rem; } .detail-meta dt { font-weight: 600; font-size: .78rem; color: var(--text-muted); } .detail-meta dd { font-size: .85rem; } -.detail-notes { margin-top: .75rem; padding: .5rem .75rem; background: var(--bg); border-radius: 6px; font-size: .8rem; color: var(--text-muted); white-space: pre-wrap; word-break: break-word; } /* Tabs */ .tabs { display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 1rem; } @@ -216,7 +215,7 @@ code { background: var(--bg); padding: .15rem .4rem; border-radius: 4px; font-si .postcard-row-action { flex-shrink: 0; } .postcard-row-date { font-size: .72rem; color: var(--text-muted); white-space: nowrap; } .postcard-row-detail { display: flex; flex-direction: column; gap: 0; font-size: .78rem; color: var(--text-muted); } -.postcard-row-notes { font-size: .72rem; color: var(--text-muted); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } +.postcard-row-notes { font-size: .72rem; color: var(--text-muted); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-left: auto; } .detail-title-row { display: flex; align-items: center; gap: .75rem; } .detail-title-row h1 { margin: 0; } .btn-back { padding: .35rem .6rem; font-size: 1rem; text-decoration: none; } diff --git a/app/templates/postcard_detail.html b/app/templates/postcard_detail.html index b92431a..ee20719 100644 --- a/app/templates/postcard_detail.html +++ b/app/templates/postcard_detail.html @@ -60,10 +60,10 @@
收到时间
{{ postcard.receive_time.strftime('%Y-%m-%d') if postcard.receive_time else '-' }}
{% endif %}
所属 Profile
{{ postcard.profile.nickname }}
+ {% if postcard.notes %} +
备注
{{ postcard.notes }}
+ {% endif %} - {% if postcard.notes %} -
{{ postcard.notes }}
- {% endif %} {% endblock %} diff --git a/app/templates/postcards.html b/app/templates/postcards.html index 19e83e1..95358e9 100644 --- a/app/templates/postcards.html +++ b/app/templates/postcards.html @@ -44,13 +44,13 @@ {{ pc.country|flag }} {{ pc.country or '-' }} → {{ pc.recipient_name or '-' }} - {% if pc.notes %}{{ pc.notes[:50] }}{% if pc.notes|length > 50 %}…{% endif %}{% endif %} {{ {'sent':'已寄出','delivered':'已送达'}.get(pc.status) }} {% if pc.send_time %}{{ pc.send_time.strftime('%Y-%m-%d') }}寄出{% endif %} {% if pc.arrival_time %}
{{ pc.arrival_time.strftime('%Y-%m-%d') }}送达{% endif %}
+ {% if pc.notes %}{{ pc.notes[:50] }}{% if pc.notes|length > 50 %}…{% endif %}{% endif %}
{% if pc.status == 'sent' %}
@@ -81,9 +81,9 @@
← {{ pc.sender_name or '-' }}
- {% if pc.notes %}{{ pc.notes[:50] }}{% if pc.notes|length > 50 %}…{% endif %}{% endif %} {% if pc.receive_time %}{{ pc.receive_time.strftime('%Y-%m-%d') }}收到{% endif %}
+ {% if pc.notes %}{{ pc.notes[:50] }}{% if pc.notes|length > 50 %}…{% endif %}{% endif %} {% endfor %} {% else %}