diff --git a/app/assets/stylesheets/admin/table_actions.scss b/app/assets/stylesheets/admin/table_actions.scss index 9d782a4be..0409e43a9 100644 --- a/app/assets/stylesheets/admin/table_actions.scss +++ b/app/assets/stylesheets/admin/table_actions.scss @@ -9,4 +9,17 @@ > p { align-self: flex-start; } + + a { + @include button($style: hollow); + border-color: $link !important; + color: $link !important; + font-size: $base-font-size; + margin-bottom: 0; + + &.destroy-link { + border-color: $alert-color !important; + color: $alert-color !important; + } + } } diff --git a/app/components/admin/budgets/table_actions_component.html.erb b/app/components/admin/budgets/table_actions_component.html.erb index 9540163e0..8bc788c34 100644 --- a/app/components/admin/budgets/table_actions_component.html.erb +++ b/app/components/admin/budgets/table_actions_component.html.erb @@ -1,10 +1,14 @@ <%= render Admin::TableActionsComponent.new(budget, actions: [:edit], edit_text: t("admin.budgets.index.edit_budget")) do %> <%= link_to t("admin.budgets.index.budget_investments"), admin_budget_budget_investments_path(budget_id: budget.id), - class: "button hollow medium" %> - <%= link_to t("admin.budgets.index.edit_groups"), admin_budget_groups_path(budget) %> + class: "investments-link" %> + <%= link_to t("admin.budgets.index.edit_groups"), + admin_budget_groups_path(budget), + class: "groups-link" %> <% if budget.poll.present? %> - <%= link_to t("admin.budgets.index.admin_ballots"), admin_poll_booth_assignments_path(budget.poll) %> + <%= link_to t("admin.budgets.index.admin_ballots"), + admin_poll_booth_assignments_path(budget.poll), + class: "ballots-link" %> <% else %> <%= link_to_create_budget_poll %> <% end %> diff --git a/app/components/admin/budgets/table_actions_component.rb b/app/components/admin/budgets/table_actions_component.rb index 0250eb1d7..46c642a86 100644 --- a/app/components/admin/budgets/table_actions_component.rb +++ b/app/components/admin/budgets/table_actions_component.rb @@ -13,10 +13,12 @@ class Admin::Budgets::TableActionsComponent < ApplicationComponent link_to t("admin.budgets.index.admin_ballots"), admin_polls_path(poll: { - name: budget.name, - budget_id: budget.id, - starts_at: balloting_phase.starts_at, - ends_at: balloting_phase.ends_at }), + name: budget.name, + budget_id: budget.id, + starts_at: balloting_phase.starts_at, + ends_at: balloting_phase.ends_at + }), + class: "ballots-link", method: :post end end diff --git a/app/components/admin/hidden_table_actions_component.html.erb b/app/components/admin/hidden_table_actions_component.html.erb index 7cf58e888..dad308a78 100644 --- a/app/components/admin/hidden_table_actions_component.html.erb +++ b/app/components/admin/hidden_table_actions_component.html.erb @@ -2,11 +2,11 @@ <%= link_to restore_text, restore_path, method: :put, data: { confirm: t("admin.actions.confirm") }, - class: "button hollow warning" %> + class: "restore-link" %> <% unless record.confirmed_hide? %> <%= link_to confirm_hide_text, confirm_hide_path, method: :put, - class: "button" %> + class: "confirm-hide-link" %> <% end %> <% end %> diff --git a/app/components/admin/organizations/table_actions_component.html.erb b/app/components/admin/organizations/table_actions_component.html.erb index 5c0b565ab..dd9c521a1 100644 --- a/app/components/admin/organizations/table_actions_component.html.erb +++ b/app/components/admin/organizations/table_actions_component.html.erb @@ -2,12 +2,12 @@ <% if can_verify? %> <%= link_to t("admin.organizations.index.verify"), verify_admin_organization_path(organization, request.query_parameters), - method: :put, class: "button success small-5" %> + method: :put, class: "verify-link" %> <% end %> <% if can_reject? %> <%= link_to t("admin.organizations.index.reject"), reject_admin_organization_path(organization, request.query_parameters), - method: :put, class: "button hollow alert small-5" %> + method: :put, class: "reject-link" %> <% end %> <% end %> diff --git a/app/components/admin/poll/officers/officers_component.html.erb b/app/components/admin/poll/officers/officers_component.html.erb index baf93a50f..3ef36fd13 100644 --- a/app/components/admin/poll/officers/officers_component.html.erb +++ b/app/components/admin/poll/officers/officers_component.html.erb @@ -3,7 +3,7 @@ <%= t("admin.poll_officers.officer.name") %> <%= t("admin.poll_officers.officer.email") %> - <%= t("admin.actions.actions") %> + <%= t("admin.actions.actions") %> @@ -19,14 +19,15 @@ <% if officer.persisted? %> <%= render Admin::TableActionsComponent.new(officer, actions: [:destroy], - destroy_text: t("admin.poll_officers.officer.delete") + destroy_text: t("admin.poll_officers.officer.delete"), + destroy_options: { class: "destroy-officer-link" } ) %> <% else %> <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> <%= actions.link_to t("admin.poll_officers.officer.add"), add_user_path(officer), method: :post, - class: "button success expanded" %> + class: "create-officer-link" %> <% end %> <% end %> diff --git a/app/components/admin/roles/table_actions_component.html.erb b/app/components/admin/roles/table_actions_component.html.erb index 0531450cc..59aed5763 100644 --- a/app/components/admin/roles/table_actions_component.html.erb +++ b/app/components/admin/roles/table_actions_component.html.erb @@ -1,7 +1,10 @@ <% if already_has_role? %> - <%= render Admin::TableActionsComponent.new(record, actions: actions) %> + <%= render Admin::TableActionsComponent.new(record, + actions: actions, + destroy_options: { class: "destroy-role-link" } + ) %> <% else %> <%= render Admin::TableActionsComponent.new(actions: []) do %> - <%= link_to add_user_text, add_user_path, method: :post, class: "button success expanded" %> + <%= link_to add_user_text, add_user_path, method: :post, class: "create-role-link" %> <% end %> <% end %> diff --git a/app/components/admin/table_actions_component.rb b/app/components/admin/table_actions_component.rb index e43c5294d..990f54c74 100644 --- a/app/components/admin/table_actions_component.rb +++ b/app/components/admin/table_actions_component.rb @@ -22,7 +22,7 @@ class Admin::TableActionsComponent < ApplicationComponent end def edit_options - { class: "button hollow" }.merge(options[:edit_options] || {}) + { class: "edit-link" }.merge(options[:edit_options] || {}) end def destroy_text @@ -36,7 +36,7 @@ class Admin::TableActionsComponent < ApplicationComponent def destroy_options { method: :delete, - class: "button hollow alert", + class: "destroy-link", data: { confirm: destroy_confirmation } }.merge(options[:destroy_options] || {}) end diff --git a/app/views/admin/admin_notifications/index.html.erb b/app/views/admin/admin_notifications/index.html.erb index ad284ce11..d51ac2c8b 100644 --- a/app/views/admin/admin_notifications/index.html.erb +++ b/app/views/admin/admin_notifications/index.html.erb @@ -9,7 +9,7 @@ <%= t("admin.admin_notifications.index.title") %> <%= t("admin.admin_notifications.index.segment_recipient") %> <%= t("admin.admin_notifications.index.sent") %> - <%= t("admin.admin_notifications.index.actions") %> + <%= t("admin.admin_notifications.index.actions") %> @@ -33,13 +33,13 @@ <%= render Admin::TableActionsComponent.new(admin_notification) do |actions| %> <%= actions.link_to t("admin.admin_notifications.index.preview"), admin_admin_notification_path(admin_notification), - class: "button" %> + class: "preview-link" %> <% end %> <% else %> <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> <%= actions.link_to t("admin.admin_notifications.index.view"), admin_admin_notification_path(admin_notification), - class: "button" %> + class: "show-link" %> <% end %> <% end %> diff --git a/app/views/admin/administrators/search.html.erb b/app/views/admin/administrators/search.html.erb index d5ccddf38..e407ef4f5 100644 --- a/app/views/admin/administrators/search.html.erb +++ b/app/views/admin/administrators/search.html.erb @@ -10,7 +10,7 @@ <%= t("admin.administrators.index.name") %> <%= t("admin.administrators.index.email") %> - <%= t("admin.shared.actions") %> + <%= t("admin.shared.actions") %> <% @users.each do |user| %> diff --git a/app/views/admin/audits/_audits.html.erb b/app/views/admin/audits/_audits.html.erb index 684c246a3..aa72d36b8 100644 --- a/app/views/admin/audits/_audits.html.erb +++ b/app/views/admin/audits/_audits.html.erb @@ -37,7 +37,7 @@ <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> <%= actions.link_to t("shared.show"), admin_polymorphic_path(audit), - class: "button hollow primary" %> + class: "show-link" %> <% end %> diff --git a/app/views/admin/banners/index.html.erb b/app/views/admin/banners/index.html.erb index 1a0783c2a..67b151d86 100644 --- a/app/views/admin/banners/index.html.erb +++ b/app/views/admin/banners/index.html.erb @@ -13,7 +13,7 @@ <%= Banner.human_attribute_name(:post_started_at) %> <%= Banner.human_attribute_name(:post_ended_at) %> - <%= t("admin.actions.actions") %> + <%= t("admin.actions.actions") %> diff --git a/app/views/admin/budget_groups/index.html.erb b/app/views/admin/budget_groups/index.html.erb index 293078dd3..195642d43 100644 --- a/app/views/admin/budget_groups/index.html.erb +++ b/app/views/admin/budget_groups/index.html.erb @@ -28,7 +28,8 @@ <%= render Admin::TableActionsComponent.new(group) do |actions| %> <%= actions.link_to t("admin.budget_groups.headings_manage"), - admin_budget_group_headings_path(@budget, group) %> + admin_budget_group_headings_path(@budget, group), + class: "headings-link" %> <% end %> diff --git a/app/views/admin/dashboard/actions/index.html.erb b/app/views/admin/dashboard/actions/index.html.erb index 2e32b97d6..38b4cba02 100644 --- a/app/views/admin/dashboard/actions/index.html.erb +++ b/app/views/admin/dashboard/actions/index.html.erb @@ -17,7 +17,7 @@ <%= t("admin.dashboard.actions.index.day_offset") %> <%= t("admin.dashboard.actions.index.required_supports") %> <%= t("admin.dashboard.actions.index.order") %> - <%= t("admin.actions.actions") %> + <%= t("admin.actions.actions") %> diff --git a/app/views/admin/geozones/index.html.erb b/app/views/admin/geozones/index.html.erb index 31bae3f73..c8dabf366 100644 --- a/app/views/admin/geozones/index.html.erb +++ b/app/views/admin/geozones/index.html.erb @@ -10,7 +10,7 @@ <%= t("admin.geozones.geozone.external_code") %> <%= t("admin.geozones.geozone.census_code") %> <%= t("admin.geozones.geozone.coordinates") %> - <%= t("admin.actions.actions") %> + <%= t("admin.actions.actions") %> diff --git a/app/views/admin/managers/search.html.erb b/app/views/admin/managers/search.html.erb index 442fe3194..60a5fcc54 100644 --- a/app/views/admin/managers/search.html.erb +++ b/app/views/admin/managers/search.html.erb @@ -10,7 +10,7 @@ <%= t("admin.managers.index.name") %> <%= t("admin.managers.index.email") %> - <%= t("admin.shared.actions") %> + <%= t("admin.shared.actions") %> <% @users.each do |user| %> diff --git a/app/views/admin/milestones/_milestones.html.erb b/app/views/admin/milestones/_milestones.html.erb index b36a7c545..ae80be88d 100644 --- a/app/views/admin/milestones/_milestones.html.erb +++ b/app/views/admin/milestones/_milestones.html.erb @@ -53,7 +53,7 @@ <% end %> <% end %> - + <%= render Admin::TableActionsComponent.new(milestone, destroy_text: t("admin.milestones.index.delete") ) %> diff --git a/app/views/admin/moderators/search.html.erb b/app/views/admin/moderators/search.html.erb index d3b1d69d1..2b4607947 100644 --- a/app/views/admin/moderators/search.html.erb +++ b/app/views/admin/moderators/search.html.erb @@ -10,7 +10,7 @@ <%= t("admin.moderators.index.name") %> <%= t("admin.moderators.index.email") %> - <%= t("admin.shared.actions") %> + <%= t("admin.shared.actions") %> <% @users.each do |user| %> diff --git a/app/views/admin/newsletters/index.html.erb b/app/views/admin/newsletters/index.html.erb index a86d704c3..e5c0e2427 100644 --- a/app/views/admin/newsletters/index.html.erb +++ b/app/views/admin/newsletters/index.html.erb @@ -9,7 +9,7 @@ <%= t("admin.newsletters.index.subject") %> <%= t("admin.newsletters.index.segment_recipient") %> <%= t("admin.newsletters.index.sent") %> - <%= t("admin.newsletters.index.actions") %> + <%= t("admin.newsletters.index.actions") %> @@ -32,7 +32,7 @@ <%= render Admin::TableActionsComponent.new(newsletter) do |actions| %> <%= actions.link_to t("admin.newsletters.index.preview"), admin_newsletter_path(newsletter), - class: "button" %> + class: "preview-link" %> <% end %> diff --git a/app/views/admin/poll/booth_assignments/_booth_assignment.html.erb b/app/views/admin/poll/booth_assignments/_booth_assignment.html.erb index acbddc7fa..fbf8664aa 100644 --- a/app/views/admin/poll/booth_assignments/_booth_assignment.html.erb +++ b/app/views/admin/poll/booth_assignments/_booth_assignment.html.erb @@ -31,8 +31,7 @@ admin_poll_booth_assignments_path(@poll, booth_id: booth.id), method: :post, remote: true, - title: t("admin.booth_assignments.manage.actions.assign"), - class: "button hollow expanded" %> + class: "assign-booth-link" %> <% end %> <% end %> diff --git a/app/views/admin/poll/booths/_booth.html.erb b/app/views/admin/poll/booths/_booth.html.erb index 8814016ed..5c9c5d839 100644 --- a/app/views/admin/poll/booths/_booth.html.erb +++ b/app/views/admin/poll/booths/_booth.html.erb @@ -10,7 +10,7 @@ <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> <%= actions.link_to t("admin.booths.booth.shifts"), new_admin_booth_shift_path(booth), - class: "button hollow" %> + class: "shifts-link" %> <% end %> <% else %> <%= render Admin::TableActionsComponent.new(booth, diff --git a/app/views/admin/poll/polls/_poll.html.erb b/app/views/admin/poll/polls/_poll.html.erb index 2cad1f6cd..e367d7708 100644 --- a/app/views/admin/poll/polls/_poll.html.erb +++ b/app/views/admin/poll/polls/_poll.html.erb @@ -14,7 +14,7 @@ ) do |actions| %> <%= actions.link_to t("admin.actions.configure"), admin_poll_path(poll), - class: "button hollow " %> + class: "configure-link" %> <% end %> diff --git a/app/views/admin/poll/polls/_questions.html.erb b/app/views/admin/poll/polls/_questions.html.erb index 130f899c6..2cde94099 100644 --- a/app/views/admin/poll/polls/_questions.html.erb +++ b/app/views/admin/poll/polls/_questions.html.erb @@ -8,11 +8,11 @@ <%= t("admin.polls.show.no_questions") %> <% else %> - +
- + <% @poll.questions.each do |question| %> @@ -30,7 +30,7 @@ diff --git a/app/views/admin/poll/polls/booth_assignments.html.erb b/app/views/admin/poll/polls/booth_assignments.html.erb index 7fa9b2e01..ece854d29 100644 --- a/app/views/admin/poll/polls/booth_assignments.html.erb +++ b/app/views/admin/poll/polls/booth_assignments.html.erb @@ -18,7 +18,7 @@ <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> <%= actions.link_to t("admin.booth_assignments.manage_assignments"), manage_admin_poll_booth_assignments_path(poll), - class: "button hollow" %> + class: "manage-link" %> <% end %> diff --git a/app/views/admin/poll/questions/_questions.html.erb b/app/views/admin/poll/questions/_questions.html.erb index b8d411689..d83428879 100644 --- a/app/views/admin/poll/questions/_questions.html.erb +++ b/app/views/admin/poll/questions/_questions.html.erb @@ -7,12 +7,12 @@ <%= t("admin.questions.index.no_questions") %> <% else %> -
<%= t("admin.polls.show.table_title") %><%= t("admin.actions.actions") %><%= t("admin.actions.actions") %>
<%= render Admin::TableActionsComponent.new(question) do |actions| %> <%= actions.link_to t("admin.polls.show.edit_answers"), admin_question_path(question), - class: "button hollow" %> + class: "answers-link" %> <% end %>
+
- + @@ -29,7 +29,7 @@ diff --git a/app/views/admin/poll/questions/_successful_proposals.html.erb b/app/views/admin/poll/questions/_successful_proposals.html.erb index b0e91ebfa..1a4b06aad 100644 --- a/app/views/admin/poll/questions/_successful_proposals.html.erb +++ b/app/views/admin/poll/questions/_successful_proposals.html.erb @@ -1,4 +1,4 @@ -
<%= t("admin.questions.index.table_question") %> <%= t("admin.questions.index.table_poll") %><%= t("admin.actions.actions") %><%= t("admin.actions.actions") %>
<%= render Admin::TableActionsComponent.new(question) do |actions| %> <%= actions.link_to t("admin.polls.show.edit_answers"), admin_question_path(question), - class: "button hollow" %> + class: "answers-link" %> <% end %>
+
@@ -16,10 +16,10 @@ diff --git a/app/views/admin/poll/questions/answers/documents.html.erb b/app/views/admin/poll/questions/answers/documents.html.erb index 0a1d66573..786c38cd9 100644 --- a/app/views/admin/poll/questions/answers/documents.html.erb +++ b/app/views/admin/poll/questions/answers/documents.html.erb @@ -44,7 +44,7 @@ document.attachment.url, target: "_blank", rel: "nofollow", - class: "button hollow" %> + class: "download-link" %> <% end %> diff --git a/app/views/admin/poll/shifts/_shifts.html.erb b/app/views/admin/poll/shifts/_shifts.html.erb index af3c0e662..d3cda31fb 100644 --- a/app/views/admin/poll/shifts/_shifts.html.erb +++ b/app/views/admin/poll/shifts/_shifts.html.erb @@ -1,5 +1,5 @@

<%= t("admin.poll_shifts.new.shifts") %>

-
<%= t("admin.questions.index.table_proposal") %> <%= render Admin::TableActionsComponent.new(actions: []) do |actions| %> - <%= actions.link_to t("admin.shared.view"), proposal_path(proposal), class: "button hollow" %> + <%= actions.link_to t("admin.shared.view"), proposal_path(proposal), class: "show-link" %> <%= actions.link_to t("admin.questions.index.create_question"), new_admin_question_path(proposal_id: proposal.id), - class: "button hollow" %> + class: "new-link" %> <% end %>
+
diff --git a/app/views/admin/site_customization/pages/index.html.erb b/app/views/admin/site_customization/pages/index.html.erb index 47f31da97..6d0d8f6e9 100644 --- a/app/views/admin/site_customization/pages/index.html.erb +++ b/app/views/admin/site_customization/pages/index.html.erb @@ -16,7 +16,7 @@ - + @@ -31,13 +31,13 @@ <%= render Admin::TableActionsComponent.new(page) do |actions| %> <%= actions.link_to t("admin.site_customization.pages.page.see_cards"), admin_site_customization_page_cards_path(page), - class: "button hollow expanded" %> + class: "cards-link" %> <% if page.status == "published" %> <%= actions.link_to t("admin.site_customization.pages.index.see_page"), page.url, target: "_blank", - class: "button hollow" %> + class: "show-link" %> <% end %> <% end %> diff --git a/app/views/admin/system_emails/index.html.erb b/app/views/admin/system_emails/index.html.erb index c70793954..bcbca17c2 100644 --- a/app/views/admin/system_emails/index.html.erb +++ b/app/views/admin/system_emails/index.html.erb @@ -22,16 +22,16 @@ <% if system_email_actions.include?("view") %> <%= actions.link_to t("admin.shared.view"), admin_system_email_view_path(system_email_title), - class: "button hollow" %> + class: "show-link" %> <% end %> <% if system_email_actions.include?("preview_pending") %> <%= actions.link_to t("admin.system_emails.preview_pending.action"), admin_system_email_preview_pending_path(system_email_title), - class: "button" %> + class: "preview-pending-link" %> <%= actions.link_to t("admin.system_emails.preview_pending.send_pending"), admin_system_email_send_pending_path(system_email_title), - class: "button success", + class: "send-pending-link", method: :put %> <% end %> diff --git a/app/views/admin/valuators/_valuator_row.html.erb b/app/views/admin/valuators/_valuator_row.html.erb index 6a8f28968..c85e159cd 100644 --- a/app/views/admin/valuators/_valuator_row.html.erb +++ b/app/views/admin/valuators/_valuator_row.html.erb @@ -22,7 +22,7 @@ <%= render Admin::TableActionsComponent.new(valuator) do |actions| %> <%= actions.link_to t("admin.shared.view"), admin_valuator_path(valuator), - class: "button hollow" %> + class: "show-link" %> <% end %> diff --git a/app/views/admin/valuators/_valuators.html.erb b/app/views/admin/valuators/_valuators.html.erb index cd80dc7f2..5f9abbc3e 100644 --- a/app/views/admin/valuators/_valuators.html.erb +++ b/app/views/admin/valuators/_valuators.html.erb @@ -5,7 +5,7 @@ - + <% valuators.each do |valuator| %>
<%= t("admin.poll_shifts.new.date") %><%= t("admin.site_customization.pages.page.created_at") %> <%= t("admin.site_customization.pages.page.updated_at") %> <%= t("admin.site_customization.pages.page.status") %><%= t("admin.actions.actions") %><%= t("admin.actions.actions") %>
<%= t("admin.valuators.index.description") %> <%= t("admin.valuators.index.group") %> <%= t("admin.valuators.index.abilities") %><%= t("admin.actions.actions") %><%= t("admin.actions.actions") %>