From 435747764caf5cc7f4b1f657e889620728f87a71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Thu, 18 Feb 2021 23:39:59 +0100 Subject: [PATCH] Group links to create budgets with the heading We're going to add help content here and having a floating button would make the button disappear when creating content for mobile phones. I'm not sure having the link in the
tag is semantically correct, but is consistent to what we did to create local targets in the SDG content section. Note we're changing the style of the link to create local targets so it's consistent with the link to create budgets/groups/headings. --- app/assets/stylesheets/admin.scss | 2 +- app/views/admin/budget_groups/index.html.erb | 9 ++++----- app/views/admin/budget_headings/index.html.erb | 9 ++++----- app/views/admin/budgets/index.html.erb | 9 ++++----- 4 files changed, 13 insertions(+), 16 deletions(-) diff --git a/app/assets/stylesheets/admin.scss b/app/assets/stylesheets/admin.scss index 0e53b4abf..428390f91 100644 --- a/app/assets/stylesheets/admin.scss +++ b/app/assets/stylesheets/admin.scss @@ -659,7 +659,7 @@ code { display: flex; a { - @include hollow-button; + @include regular-button; margin-left: auto; } } diff --git a/app/views/admin/budget_groups/index.html.erb b/app/views/admin/budget_groups/index.html.erb index 195642d43..74185970c 100644 --- a/app/views/admin/budget_groups/index.html.erb +++ b/app/views/admin/budget_groups/index.html.erb @@ -2,11 +2,10 @@
-

<%= @budget.name %>

- -<%= link_to t("admin.budget_groups.form.create"), - new_admin_budget_group_path, - class: "button float-right" %> +
+

<%= @budget.name %>

+ <%= link_to t("admin.budget_groups.form.create"), new_admin_budget_group_path %> +
<% if @groups.any? %>

<%= t("admin.budget_groups.amount", count: @groups.count) %>

diff --git a/app/views/admin/budget_headings/index.html.erb b/app/views/admin/budget_headings/index.html.erb index 7ffd37ff7..e609af000 100644 --- a/app/views/admin/budget_headings/index.html.erb +++ b/app/views/admin/budget_headings/index.html.erb @@ -1,10 +1,9 @@ <%= back_link_to admin_budget_groups_path(@budget), t("admin.budget_headings.index.back") %> -
-

<%= "#{@budget.name} / #{@group.name}" %>

-<%= link_to t("admin.budget_headings.form.create"), - new_admin_budget_group_heading_path, - class: "button float-right" %> +
+

<%= "#{@budget.name} / #{@group.name}" %>

+ <%= link_to t("admin.budget_headings.form.create"), new_admin_budget_group_heading_path %> +
<% if @headings.any? %>

<%= t("admin.budget_headings.amount", count: @headings.count) %>

diff --git a/app/views/admin/budgets/index.html.erb b/app/views/admin/budgets/index.html.erb index 9140973af..448a55215 100644 --- a/app/views/admin/budgets/index.html.erb +++ b/app/views/admin/budgets/index.html.erb @@ -1,8 +1,7 @@ -

<%= t("admin.budgets.index.title") %>

- -<%= link_to t("admin.budgets.index.new_link"), - new_admin_budget_path, - class: "button float-right" %> +
+

<%= t("admin.budgets.index.title") %>

+ <%= link_to t("admin.budgets.index.new_link"), new_admin_budget_path %> +
<%= render "shared/filter_subnav", i18n_namespace: "admin.budgets.index" %>