diff --git a/app/assets/stylesheets/budgets/groups_and_headings.scss b/app/assets/stylesheets/budgets/groups_and_headings.scss index 44c36f108..1be85a2be 100644 --- a/app/assets/stylesheets/budgets/groups_and_headings.scss +++ b/app/assets/stylesheets/budgets/groups_and_headings.scss @@ -1,10 +1,27 @@ .groups-and-headings { + $spacing: rem-calc(4); + + .headings-list { + display: flex; + flex-wrap: wrap; + list-style: none; + margin-left: -$spacing; + } .heading { border: 1px solid $border; border-radius: rem-calc(3); - display: inline-block; margin-bottom: $line-height / 2; + margin-left: $spacing; + width: 100%; + + @include breakpoint(medium) { + width: calc(100% / 3 - #{$spacing}); + } + + @include breakpoint(large) { + width: calc(100% / 6 - #{$spacing}); + } a { display: block; diff --git a/app/components/budgets/groups_and_headings_component.html.erb b/app/components/budgets/groups_and_headings_component.html.erb index dfb997032..6c88b9850 100644 --- a/app/components/budgets/groups_and_headings_component.html.erb +++ b/app/components/budgets/groups_and_headings_component.html.erb @@ -1,9 +1,9 @@