Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ <h3>Vaccinations</h3>

{% if "vaccinations" in allowed_categories %}

<div style="overflow-x: auto;">
<div class="table-responsive" tabindex="0" role="region" aria-label="Vaccinations table">
<table id="vaccination-table">
<thead>
<tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ <h3>Batch measurement entry</h3>
{{ formset.management_form }}

{% if rows %}
<div class="table-responsive" tabindex="0" role="region" aria-label="Batch measurements table">
<table role="grid">
<thead>
<tr>
Expand Down Expand Up @@ -48,6 +49,7 @@ <h3>Batch measurement entry</h3>
{% endfor %}
</tbody>
</table>
</div>
{% else %}
<p>No animals available. <a href="{% url 'animal_create' %}">Add an animal</a> first, or ask an owner to share one with you.</p>
{% endif %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ <h4>Notification</h4>
<p>Time of sending: {{ note.daily_timestamp }} for timezone: {{ note.timezone }}</p>
<p>Period: {{ note.start_date }} – {% if note.end_date %}{{ note.end_date }}{% else %}ongoing{% endif %}</p>

<div class="table-responsive" tabindex="0" role="region" aria-label="Notification schedule for {{ note.receiver_name }}">
<table>
<thead>
<tr>
Expand All @@ -49,6 +50,7 @@ <h4>Notification</h4>
</tr>
</tbody>
</table>
</div>

<article>
<header>The message to send:</header>
Expand Down
12 changes: 12 additions & 0 deletions static/css/custom_pico.css
Original file line number Diff line number Diff line change
Expand Up @@ -504,3 +504,15 @@ footer nav ul li > button {
padding: 1.5rem 0;
text-align: center;
}

/* Keeps horizontal overflow local to the table instead of stretching the page. */
.table-responsive {
max-width: 100%;
overflow-x: auto;
-webkit-overflow-scrolling: touch;
}

.table-responsive:focus-visible {
outline: 2px solid var(--pico-primary);
outline-offset: 2px;
}