feat: Improve advanced fields styling

on mobile it text align center
Increased the font size so its easier to click
Added translations
This commit is contained in:
billybonks 2024-02-07 15:01:30 +08:00 committed by Christopher Charbonneau Wells
parent 232cde19ee
commit b7743674d8
2 changed files with 17 additions and 4 deletions

View File

@ -53,7 +53,17 @@
}
}
form .row details {
@include media-breakpoint-down(md) {
.advanced-fields__summary {
text-align: center;
}
}
.advanced-fields__summary > * {
display: inline
}
.advanced-fields {
// removing this causes slight mis-alignment between fields in the details and the rest of the fields
//on the form at the left hand side of the box
padding-right: 0;

View File

@ -1,7 +1,10 @@
{% load i18n %}
<div class="row">
<div class="row mb-3">
<details ontoggle="rememberAdvancedToggle(event)">
<summary>Advanced</summary>
<details ontoggle="rememberAdvancedToggle(event)" class="advanced-fields">
<summary class="advanced-fields__summary">
<h4>{% trans "Advanced Fields" %}</h4>
</summary>
{% for field in fieldset.fields %}
<div class="row">{% include "babybuddy/form_field.html" %}</div>
{% endfor %}