fix: tighten calendar card layout

This commit is contained in:
2026-04-13 10:23:58 +02:00
parent 1a889e0ee1
commit bfcf2b6930
2 changed files with 38 additions and 4 deletions

View File

@@ -644,6 +644,7 @@ p {
.calendar-day { .calendar-day {
min-height: 132px; min-height: 132px;
padding: 14px; padding: 14px;
overflow: hidden;
} }
.calendar-day strong { .calendar-day strong {
@@ -658,14 +659,40 @@ p {
.calendar-day__tasks { .calendar-day__tasks {
display: grid; display: grid;
gap: 8px; gap: 8px;
min-width: 0;
} }
.calendar-task { .calendar-task {
display: grid; display: grid;
gap: 4px; gap: 4px;
padding: 10px 12px; min-width: 0;
padding: 9px 10px;
border-radius: 14px; border-radius: 14px;
background: rgba(255, 255, 255, 0.72); background: rgba(255, 255, 255, 0.72);
overflow: hidden;
}
.calendar-task__title {
display: -webkit-box;
overflow: hidden;
min-width: 0;
font-size: 0.96rem;
line-height: 1.15;
font-weight: 600;
color: var(--text);
word-break: break-word;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
.calendar-task__person {
display: block;
overflow: hidden;
min-width: 0;
font-size: 0.74rem;
line-height: 1.2;
white-space: nowrap;
text-overflow: ellipsis;
} }
.calendar-task--open { .calendar-task--open {

View File

@@ -33,8 +33,16 @@
<div class="calendar-day__tasks"> <div class="calendar-day__tasks">
{% for task in tasks_by_day.get(day, []) %} {% for task in tasks_by_day.get(day, []) %}
<a href="{{ url_for('tasks.edit', task_id=task.id) }}" class="calendar-task calendar-task--{{ task.status }}"> <a href="{{ url_for('tasks.edit', task_id=task.id) }}" class="calendar-task calendar-task--{{ task.status }}">
<span>{{ task.title }}</span> <strong class="calendar-task__title">{{ task.title }}</strong>
<small>{{ task.points_awarded }} P</small> <small class="calendar-task__person">
{% if task.completed_by_user %}
Erledigt: {{ task.completed_by_user.name }}
{% elif task.assigned_user %}
Zuständig: {{ task.assigned_user.name }}
{% else %}
Ohne Zuweisung
{% endif %}
</small>
</a> </a>
{% endfor %} {% endfor %}
</div> </div>
@@ -63,4 +71,3 @@
</section> </section>
{% endif %} {% endif %}
{% endblock %} {% endblock %}