Skip to content

Commit

Permalink
Prevent using 2 lines of text for sub-header
Browse files Browse the repository at this point in the history
3 different layouts based on media queries:

 * >83rem: actions menu has 3 actions

 * 64rem <> 83rem: 4 actions

 * 50rem <> 64rem: 5 actions

 * <50rem: 6 actions
  • Loading branch information
yaaax committed Jul 8, 2024
1 parent 8816a55 commit 12ddee4
Showing 1 changed file with 21 additions and 6 deletions.
27 changes: 21 additions & 6 deletions confiture-web-app/src/components/audit/AuditGenerationHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ onMounted(() => {
:disabled="isOffline"
>
<ul role="list" class="fr-p-0 fr-m-0 dropdown-list">
<li class="dropdown-item mobile-dropdown-item">
<li class="dropdown-item notes-item mobile-dropdown-item">
<button
class="fr-btn fr-btn--tertiary-no-outline fr-btn--icon-left fr-icon-draft-line"
:disabled="isOffline"
Expand Down Expand Up @@ -604,15 +604,30 @@ onMounted(() => {
display: none;
}
@media (width < 62rem) {
.mobile-dropdown-item {
@media (width < 83rem) {
.report-item.mobile-dropdown-item {
display: block;
}
.settings-item:not(.mobile-dropdown-item),
.notes-item:not(.mobile-dropdown-item),
.report-item:not(.mobile-dropdown-item) {
display: none;
}
}
@media (width < 64rem) {
.settings-item.mobile-dropdown-item {
display: block;
}
.settings-item:not(.mobile-dropdown-item) {
display: none;
}
}
@media (width < 50rem) {
.notes-item.mobile-dropdown-item {
display: block;
}
.notes-item:not(.mobile-dropdown-item) {
display: none;
}
}
</style>

0 comments on commit 12ddee4

Please sign in to comment.