diff --git a/app/cells/decidim/budgets/project_l_cell.rb b/app/cells/decidim/budgets/project_l_cell.rb index f40657c..38a4bb9 100644 --- a/app/cells/decidim/budgets/project_l_cell.rb +++ b/app/cells/decidim/budgets/project_l_cell.rb @@ -5,7 +5,7 @@ module Decidim module Budgets # This cell renders a project with its L-size card. - class ProjectLCell < Decidim::Budgets::ProjectGCell + class ProjectLCell < Decidim::Budgets::ProjectCell def card_classes classes = super classes = classes.split unless classes.is_a?(Array) diff --git a/app/cells/decidim/budgets/project_list_item/project_text.erb b/app/cells/decidim/budgets/project_list_item/project_text.erb index 84066c4..55664b0 100644 --- a/app/cells/decidim/budgets/project_list_item/project_text.erb +++ b/app/cells/decidim/budgets/project_list_item/project_text.erb @@ -20,7 +20,7 @@ <%= link_to resource_path, class: "card__link" do %> <%= t(".more_info_with_title", title: resource_title) %> diff --git a/app/cells/decidim/budgets/project_m/votes_counter.erb b/app/cells/decidim/budgets/project_m/votes_counter.erb index 20913d1..530e4eb 100644 --- a/app/cells/decidim/budgets/project_m/votes_counter.erb +++ b/app/cells/decidim/budgets/project_m/votes_counter.erb @@ -1,3 +1,3 @@ -<%= icon("circle-check", class: "icon--small", aria_label: "#{t("decidim.budgets.project_m.votes_count")}:", role: "img") %> +<%= icon("checkbox-circle-line", class: "icon--small", aria_label: "#{t("decidim.budgets.project_m.votes_count")}:", role: "img") %> <%= " " %> <%= votes_count %> diff --git a/app/cells/decidim/budgets/project_m/voting_buttons.erb b/app/cells/decidim/budgets/project_m/voting_buttons.erb index d9e7cb5..0e51bfc 100644 --- a/app/cells/decidim/budgets/project_m/voting_buttons.erb +++ b/app/cells/decidim/budgets/project_m/voting_buttons.erb @@ -7,7 +7,7 @@ label: t("view_detailed", scope: "decidim.budgets.projects.project", name: title) } do %> <%= t("view", scope: "decidim.budgets.projects.project") %> - <%= icon "chevron-right", role: "img", "aria-hidden": true %> + <%= icon "arrow-right-s-line", role: "img", "aria-hidden": true %> <% end %>
diff --git a/app/controllers/concerns/decidim/budgeting_pipeline/projects_controller_extensions.rb b/app/controllers/concerns/decidim/budgeting_pipeline/projects_controller_extensions.rb index 57d854b..a72417d 100644 --- a/app/controllers/concerns/decidim/budgeting_pipeline/projects_controller_extensions.rb +++ b/app/controllers/concerns/decidim/budgeting_pipeline/projects_controller_extensions.rb @@ -30,7 +30,7 @@ def default_filter_params { search_text_cont: "", with_any_status: %w(all), - with_any_scope: default_filter_scope_params, + with_any_scope: nil, with_any_category: "all", decidim_budgets_budget_id_eq: nil, budget_amount_gteq: 0, diff --git a/app/controllers/decidim/budgets/votes_controller.rb b/app/controllers/decidim/budgets/votes_controller.rb index 5a05c1a..2ec1fa0 100644 --- a/app/controllers/decidim/budgets/votes_controller.rb +++ b/app/controllers/decidim/budgets/votes_controller.rb @@ -293,7 +293,7 @@ def default_filter_params { search_text_cont: "", with_any_status: %w(all), - with_any_scope: default_filter_scope_params, + with_any_scope: nil, with_any_category: "all", decidim_budgets_budget_id_eq: nil, budget_amount_gteq: 0, diff --git a/app/views/decidim/budgets/admin/budgets/_form.html.erb b/app/views/decidim/budgets/admin/budgets/_form.html.erb index 6c95c6b..453e145 100644 --- a/app/views/decidim/budgets/admin/budgets/_form.html.erb +++ b/app/views/decidim/budgets/admin/budgets/_form.html.erb @@ -1,33 +1,40 @@ -
-
-

<%= title %>

-
- -
-
- <%= form.translated :text_field, :title, autofocus: true %> +
+
+
+
+ <%= form.translated :text_field, :title, autofocus: true, aria: { label: :title } %> +
- <%= form.number_field :weight %> +
+ <%= form.number_field :weight %> +
- <%= form.translated :editor, :description %> +
+ <%= form.translated :editor, :description, toolbar: :content, aria: { label: :description } %> +
- <%= form.upload :list_image %> + <%= form.upload :list_image, button_class: "button button__sm button__transparent-secondary" %>
- <%= form.number_field :total_budget %> +
+ <%= form.number_field :total_budget %> +
<% if current_component.settings.geocoding_enabled %> - <%= form.number_field :center_latitude %> +
+ <%= form.number_field :center_latitude %> - <%= form.number_field :center_longitude %> + <%= form.number_field :center_longitude %> +
<% end %> <% if current_component.has_subscopes? %>
- <%= scopes_picker_field form, :decidim_scope_id, root: current_component.scope %> + <%= scopes_select_field form, :decidim_scope_id, root: current_component.scope %>
<% end %> +
diff --git a/app/views/decidim/budgets/admin/budgets/index.html.erb b/app/views/decidim/budgets/admin/budgets/index.html.erb index 0a4eda5..be91109 100644 --- a/app/views/decidim/budgets/admin/budgets/index.html.erb +++ b/app/views/decidim/budgets/admin/budgets/index.html.erb @@ -1,70 +1,69 @@ -
-
-

-
- <%= t(".title") %> -
-
- <% if allowed_to? :export, :budget %> - <%= export_dropdown %> +<% add_decidim_page_title(t(".title")) %> +
+
+

+ <%= t(".title") %> + <% if allowed_to? :export, :budget %> + <%= export_dropdown %> + <% end %> +
+ <%= link_to t("actions.new_budget", scope: "decidim.budgets"), new_budget_path, class: "button button__sm button__secondary" if allowed_to? :create, :budget %> + <%= link_to t("decidim.budgets.admin.helps.index.title"), helps_path, class: "button button__sm button__secondary" %> + <% if allowed_to? :export_results, :budgets %> + <%= link_to t("actions.export_results", scope: "decidim.budgets.admin"), new_results_export_path, class: "button button__sm button__secondary" %> <% end %> -
- <%= link_to t("actions.new", scope: "decidim.budgets", name: t("models.budget.name", scope: "decidim.budgets.admin")), new_budget_path, class: "button tiny button--title" if allowed_to? :create, :budget %> - <%= link_to t("decidim.budgets.admin.helps.index.title"), helps_path, class: "button tiny button--title" %> - <% if allowed_to? :export_results, :budgets %> - <%= link_to t("actions.export_results", scope: "decidim.budgets.admin"), new_results_export_path, class: "button tiny button--title" %> - <% end %> -
-

+ <%= render partial: "decidim/admin/components/resource_action" %> +

+
+ + + + + + + <%= th_resource_scope_label %> + + + + + <% budgets.each do |budget| %> + + + + + <%= td_resource_scope_for(budget.scope) %> + + + <% end %> + +
<%= t("models.budget.fields.name", scope: "decidim.budgets") %><%= t("models.budget.fields.total_budget", scope: "decidim.budgets") %><%= t("models.budget.fields.projects_count", scope: "decidim.budgets") %><%= t("actions.title", scope: "decidim.budgets") %>
+ <% if allowed_to? :update, :budget, budget: budget %> + <%= link_to translated_attribute(budget.title), budget_projects_path(budget) %>
+ <% else %> + <%= translated_attribute(budget.title) %> + <% end %> +
+ <%= number_to_currency budget.total_budget, unit: Decidim.currency_unit, precision: 0 %> + + <%= link_to budget.projects.count, budget_projects_path(budget) %> + + <% if allowed_to? :update, :budget, budget: budget %> + <%= icon_link_to "pencil-line", edit_budget_path(budget), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> + <% else %> + <%= icon "pencil-line", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.edit", scope: "decidim.budgets") %> + <% end %> -
-
- - - - - - - <%= th_resource_scope_label %> - - - - - <% budgets.each do |budget| %> - - - - - <%= td_resource_scope_for(budget.scope) %> - - - <% end %> - -
<%= t("models.budget.fields.name", scope: "decidim.budgets") %><%= t("models.budget.fields.total_budget", scope: "decidim.budgets") %><%= t("models.budget.fields.projects_count", scope: "decidim.budgets") %><%= t("actions.title", scope: "decidim.budgets") %>
- <%= link_to translated_attribute(budget.title), resource_locator(budget).path %> - - <%= number_to_currency budget.total_budget, unit: Decidim.currency_unit, precision: 0 %> - - <%= link_to budget.projects.count, budget_projects_path(budget) %> - - <%= icon_link_to "eye", resource_locator(budget).path, t("actions.preview", scope: "decidim.budgets"), class: "action-icon--preview", target: :blank %> - - <%= icon_link_to "list", budget_projects_path(budget), t("actions.edit_projects", scope: "decidim.budgets"), class: "action-icon--edit-projects" %> + <%= icon_link_to "list-check", budget_projects_path(budget), t("actions.edit_projects", scope: "decidim.budgets"), class: "action-icon--edit-projects" %> - <% if allowed_to? :update, :budget, budget: budget %> - <%= icon_link_to "pencil", edit_budget_path(budget), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> - <% else %> - <%= icon "pencil", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.edit", scope: "decidim.budgets") %> - <% end %> + <%= icon_link_to "eye-line", resource_locator(budget).path, t("actions.preview", scope: "decidim.budgets"), class: "action-icon--preview", target: :blank, data: { "external-link": false } %> - <% if allowed_to? :delete, :budget, budget: budget %> - <%= icon_link_to "circle-x", budget_path(budget), t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> - <% else %> - <%= icon "circle-x", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> - <% end %> -
-
+ <% if allowed_to? :delete, :budget, budget: budget %> + <%= icon_link_to "delete-bin-line", budget_path(budget), t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> + <% else %> + <%= icon "delete-bin-line", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> + <% end %> +
diff --git a/app/views/decidim/budgets/admin/help_sections/_form.html.erb b/app/views/decidim/budgets/admin/help_sections/_form.html.erb index cc541c8..9531146 100644 --- a/app/views/decidim/budgets/admin/help_sections/_form.html.erb +++ b/app/views/decidim/budgets/admin/help_sections/_form.html.erb @@ -1,27 +1,29 @@ -
-
-

-
- <%= link_to t("decidim.budgets.admin.helps.index.title"), helps_path %> > - <%= link_to container.name, help_sections_path(container.key) %> > - <%= title %> -
-

-
+
+
+
+

+
+ <%= link_to t("decidim.budgets.admin.helps.index.title"), helps_path %> > + <%= link_to container.name, help_sections_path(container.key) %> > + <%= title %> +
+

+
-
-
- <%= form.translated :text_field, :title, autofocus: true %> +
+
+ <%= form.translated :text_field, :title, autofocus: true %> - <%= form.number_field :weight %> + <%= form.number_field :weight %> - <%= form.translated :editor, :description %> + <%= form.translated :editor, :description %> - <%= form.translated :text_field, :link_text %> + <%= form.translated :text_field, :link_text %> - <%= form.text_field :link %> + <%= form.text_field :link %> - <%= form.upload :image %> + <%= form.upload :image, button_class: "button button__sm button__transparent-secondary" %> +
diff --git a/app/views/decidim/budgets/admin/help_sections/edit.html.erb b/app/views/decidim/budgets/admin/help_sections/edit.html.erb index e85a245..85e4230 100644 --- a/app/views/decidim/budgets/admin/help_sections/edit.html.erb +++ b/app/views/decidim/budgets/admin/help_sections/edit.html.erb @@ -1,7 +1,9 @@ -<%= decidim_form_for(@form, url: help_section_path(container.key, @form), html: { class: "form edit_help_section" }) do |f| %> +<%= decidim_form_for(@form, url: help_section_path(container.key, @form), html: { class: "form form-defaults edit_help_section" }) do |f| %> <%= render partial: "form", object: f, locals: { title: t(".title") } %> -
- <%= f.submit t(".update") %> -
+
+
+ <%= f.submit t(".update"), class: "button button__sm button__secondary" %> +
+
<% end %> diff --git a/app/views/decidim/budgets/admin/help_sections/index.html.erb b/app/views/decidim/budgets/admin/help_sections/index.html.erb index 3c34144..64a325d 100644 --- a/app/views/decidim/budgets/admin/help_sections/index.html.erb +++ b/app/views/decidim/budgets/admin/help_sections/index.html.erb @@ -1,16 +1,15 @@ -
-
-

+<% add_decidim_page_title(t("decidim.budgets.admin.helps.index.title")) %> +
+
+

<%= link_to t("decidim.budgets.admin.helps.index.title"), helps_path %> > <%= container.name%>
-
- <% if allowed_to? :export, :budget %> - <%= export_dropdown %> - <% end %> +
+ <%= export_dropdown if allowed_to? :export, :budget %>
- <%= link_to t("actions.new", scope: "decidim.budgets", name: t("models.help_section.name", scope: "decidim.budgets.admin")), new_help_section_path, class: "button tiny button--title" if allowed_to? :create, :help_section %> + <%= link_to t("help_sections.new.title", scope: "decidim.budgets.admin", name: t("models.help_section.name", scope: "decidim.budgets.admin")), new_help_section_path, class: "button button__sm button__secondary" if allowed_to? :create, :help_section %>

@@ -37,15 +36,15 @@ <% if allowed_to? :update, :help_section, help_section: section %> - <%= icon_link_to "pencil", edit_help_section_path(container.key, section), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> + <%= icon_link_to "pencil-line", edit_help_section_path(container.key, section), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> <% else %> - <%= icon "pencil", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.edit", scope: "decidim.budgets") %> + <%= icon "pencil-line", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.edit", scope: "decidim.budgets") %> <% end %> <% if allowed_to? :delete, :help_section, help_section: section %> - <%= icon_link_to "circle-x", help_section_path(container.key, section), t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> + <%= icon_link_to "delete-bin-line", help_section_path(container.key, section), t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> <% else %> - <%= icon "circle-x", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> + <%= icon "delete-bin-line", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> <% end %> diff --git a/app/views/decidim/budgets/admin/help_sections/new.html.erb b/app/views/decidim/budgets/admin/help_sections/new.html.erb index 0dc0305..4dcf7d9 100644 --- a/app/views/decidim/budgets/admin/help_sections/new.html.erb +++ b/app/views/decidim/budgets/admin/help_sections/new.html.erb @@ -1,7 +1,9 @@ -<%= decidim_form_for(@form, html: { class: "form new_help_section" }) do |f| %> +<%= decidim_form_for(@form, html: { class: "form form-defaults new_help_section" }) do |f| %> <%= render partial: "form", object: f, locals: { title: t(".title") } %> -
- <%= f.submit t(".create") %> -
+
+
+ <%= f.submit t(".create"), class: "button button__sm button__secondary" %> +
+
<% end %> diff --git a/app/views/decidim/budgets/admin/helps/index.html.erb b/app/views/decidim/budgets/admin/helps/index.html.erb index c170076..f20ff75 100644 --- a/app/views/decidim/budgets/admin/helps/index.html.erb +++ b/app/views/decidim/budgets/admin/helps/index.html.erb @@ -1,10 +1,11 @@ -
-
-

+<% add_decidim_page_title(t(".title")) %> +
+
+

<%= t(".title") %>
-

+

@@ -23,7 +24,7 @@ <%= link_to container.name, help_sections_path(container.key) %> - <%= icon_link_to "eye", help_sections_path(container.key), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--preview" %> + <%= icon_link_to "eye-line", help_sections_path(container.key), t("actions.edit", scope: "decidim.budgets"), class: "action-icon--preview" %> <% end %> diff --git a/app/views/decidim/budgets/admin/projects/_form.html.erb b/app/views/decidim/budgets/admin/projects/_form.html.erb index 6010180..8d59102 100644 --- a/app/views/decidim/budgets/admin/projects/_form.html.erb +++ b/app/views/decidim/budgets/admin/projects/_form.html.erb @@ -1,77 +1,73 @@ -
-
-

- <%= title.html_safe %> -

-
- -
-
- <%= form.translated :text_field, :title, autofocus: true %> -
- -
- <%= form.translated :text_area, :summary, rows: 4 %> -
- -
- <%= form.translated :editor, :description %> -
- -
- <%= form.upload :main_image %> -
- -
- <%= form.number_field :budget_amount %> -
- -
- <%= form.number_field :budget_amount_min %> -
- - <% if @form.geocoding_enabled? %> +
+
+
- <%= form.geocoding_field :address %> + <%= form.translated :text_field, :title, autofocus: true, aria: { label: :title } %>
- <% end %> - <% if current_component.has_subscopes? %>
- <%= scopes_picker_field form, :decidim_scope_id, root: budget.scope %> + <%= form.translated :text_area, :summary, rows: 4 %>
- <% end %> -
- <%= form.categories_select :decidim_category_id, current_participatory_space.categories, include_blank: true, disable_parents: false %> -
+
+ <%= form.translated :editor, :description, aria: { label: :description } %> +
- <% if defined?(Decidim::Proposals::Proposal) %>
- <%= proposals_picker(form, :proposals, proposals_picker_projects_path) %> + <%= form.upload :main_image %>
- <% end %> - <% if defined?(Decidim::Ideas::Idea) %>
- <%= cell("decidim/ideas/ideas_picker_field", form) %> + <%= form.number_field :budget_amount %>
- <% end %> - <% if defined?(Decidim::Plans::Plan) %>
- <%= cell("decidim/plans/plans_picker_field", form) %> + <%= form.number_field :budget_amount_min %>
- <% end %> - <%= render partial: "decidim/admin/shared/gallery", locals: { form: form } %> + <% if @form.geocoding_enabled? %> +
+ <%= form.geocoding_field :address %> +
+ <% end %> + + <% if current_component.has_subscopes? %> +
+ <%= scopes_select_field form, :decidim_scope_id, root: budget.scope %> +
+ <% end %> - <% if form.object.persisted? %>
- <%= form.check_box :selected %> -

<%= t ".selected_help" %>

+ <%= form.categories_select :decidim_category_id, current_participatory_space.categories, include_blank: true, disable_parents: false %>
- <% end %> + + <% if defined?(Decidim::Proposals::Proposal) %> +
+ <%= render partial: "decidim/proposals/proposals/proposals_picker", locals: { form:, field: :proposals } %> +
+ <% end %> + + <% if defined?(Decidim::Ideas::Idea) %> +
+ <%= cell("decidim/ideas/ideas_picker_field", form) %> +
+ <% end %> + + <% if defined?(Decidim::Plans::Plan) %> +
+ <%= cell("decidim/plans/plans_picker_field", form) %> +
+ <% end %> + + <%= render partial: "decidim/admin/shared/gallery", locals: { form: } %> + + <% if form.object.persisted? %> +
+ <%= form.check_box :selected %> +

<%= t ".selected_help" %>

+
+ <% end %> +
diff --git a/app/views/decidim/budgets/admin/projects/index.html.erb b/app/views/decidim/budgets/admin/projects/index.html.erb index 43f9e31..cd91cae 100644 --- a/app/views/decidim/budgets/admin/projects/index.html.erb +++ b/app/views/decidim/budgets/admin/projects/index.html.erb @@ -1,6 +1,7 @@ -
-
-

+<% add_decidim_page_title(t(".title")) %> +
+
+

<%= link_to translated_attribute(budget.title), budgets_path %> > <%= t(".title") %> @@ -9,75 +10,76 @@ <%= link_to t("actions.import", scope: "decidim.budgets", name: t("models.project.name", scope: "decidim.budgets.admin")), new_budget_proposals_import_path(budget), class: "button tiny button--title" if allowed_to? :import_proposals, :project %> <%= link_to t("actions.new", scope: "decidim.budgets", name: t("models.project.name", scope: "decidim.budgets.admin")), new_budget_project_path, class: "button tiny button--title new" if allowed_to? :create, :project %>
-

+

- -
-
- - - - - - - <% if component_settings.geocoding_enabled? %> - - <% end %> - <%= th_resource_scope_label %> - - - - - <% projects.each do |project| %> - - + + <% end %> + +
<%= t("models.project.fields.title", scope: "decidim.budgets") %><%= t("index.confirmed_orders_count") %><%= t(".selected") %><%= t("models.project.fields.address", scope: "decidim.budgets") %><%= t("actions.title", scope: "decidim.budgets") %>
+
+ + + + + + + <% if component_settings.geocoding_enabled? %> + + <% end %> + <%= th_resource_scope_label %> + + + + + <% projects.each do |project| %> + + - - - <% if component_settings.geocoding_enabled? %> - <% end %> - <%= td_resource_scope_for(project.scope) %> - + + + <% if component_settings.geocoding_enabled? %> + + <% end %> + <%= td_resource_scope_for(project.scope) %> + - - <% end %> - -
<%= t("models.project.fields.title", scope: "decidim.budgets") %><%= t("index.confirmed_orders_count") %><%= t(".selected") %><%= t("models.project.fields.address", scope: "decidim.budgets") %><%= t("actions.title", scope: "decidim.budgets") %>
+ <% if allowed_to? :update, :project, project: project %> + <%= link_to translated_attribute(project.title), resource_locator([budget, project]).edit %>
+ <% else %> <%= translated_attribute(project.title) %>
-
- <%= project.confirmed_orders_count %> - - <% if project.selected? %> - <%= content_tag :strong, t(".selected"), class: "text-success" %> - <% else %> - <%= content_tag :span, "×", class: "text-muted" %> - <% end %> - - <%= static_map_link(project) if project.latitude.present? && project.longitude.present? %> - - <%= icon_link_to "eye", resource_locator([budget, project]).path, t("actions.preview", scope: "decidim.budgets"), target: :blank, class: "action-icon--preview" %> + + <%= project.confirmed_orders_count %> + + <% if project.selected? %> + <%= content_tag :strong, t(".selected"), class: "text-success" %> + <% else %> + <%= content_tag :span, "×", class: "text-muted" %> + <% end %> + + <%= static_map_link(project) if project.latitude.present? && project.longitude.present? %> + + <%= icon_link_to "eye-line", resource_locator([budget, project]).path, t("actions.preview", scope: "decidim.budgets"), target: :blank, class: "action-icon--preview", data: { "external-link": false } %> - <% if allowed_to? :update, :project, project: project %> - <%= icon_link_to "pencil", resource_locator([budget, project]).edit, t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> - <% end %> + <% if allowed_to? :update, :project, project: project %> + <%= icon_link_to "pencil-line", resource_locator([budget, project]).edit, t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> + <% end %> - <% if allowed_to? :update, :project, project: project %> - <%= icon_link_to "folder", project_attachment_collections_path(project), t("actions.attachment_collections", scope: "decidim.budgets"), class: "action-icon--attachment_collections" %> - <% end %> + <% if allowed_to? :update, :project, project: project %> + <%= icon_link_to "folder-line", project_attachment_collections_path(project), t("actions.attachment_collections", scope: "decidim.budgets"), class: "action-icon--attachment_collections" %> + <% end %> - <% if allowed_to? :update, :project, project: project %> - <%= icon_link_to "paperclip", project_attachments_path(project), t("actions.attachments", scope: "decidim.budgets"), class: "action-icon--attachments" %> - <% end %> + <% if allowed_to? :update, :project, project: project %> + <%= icon_link_to "attachment-line", project_attachments_path(project), t("actions.attachments", scope: "decidim.budgets"), class: "action-icon--attachments" %> + <% end %> - <%= resource_permissions_link(project) %> + <%= resource_permissions_link(project) %> - <% if allowed_to? :destroy, :project, project: project %> - <%= icon_link_to "circle-x", resource_locator([budget, project]).show, t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> - <% else %> - <%= icon "circle-x", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> - <% end %> -
- <%= paginate projects, theme: "decidim" %> -
+ <% if allowed_to? :destroy, :project, project: project %> + <%= icon_link_to "delete-bin-line", resource_locator([budget, project]).show, t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> + <% else %> + <%= icon "delete-bin-line", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> + <% end %> +
+ <%= decidim_paginate projects %>
<%= t ".finished_orders" %>: <%= finished_orders.count %> diff --git a/app/views/decidim/budgets/budgets/index.html.erb b/app/views/decidim/budgets/budgets/index.html.erb deleted file mode 100644 index 8f57b16..0000000 --- a/app/views/decidim/budgets/budgets/index.html.erb +++ /dev/null @@ -1,5 +0,0 @@ -<%= render partial: "decidim/shared/component_announcement" %> - -<%= cell("decidim/budgets/budgets_header", current_workflow) %> - -<%= cell("decidim/budgets/budgets_list", current_workflow) %> diff --git a/app/views/decidim/budgets/line_items/_error_message.html.erb b/app/views/decidim/budgets/line_items/_error_message.html.erb index ceec604..b22404d 100644 --- a/app/views/decidim/budgets/line_items/_error_message.html.erb +++ b/app/views/decidim/budgets/line_items/_error_message.html.erb @@ -1,6 +1,6 @@

- <%= icon "information", role: "img", "aria-hidden": true %> + <%= icon "information-line", role: "img", "aria-hidden": true %> <%= t(".error.#{@error_reason}.title") %>

<%= t(".error.#{@error_reason}.description") %>

diff --git a/app/views/decidim/budgets/orders/index.html.erb b/app/views/decidim/budgets/orders/index.html.erb index 276c414..facaa3b 100644 --- a/app/views/decidim/budgets/orders/index.html.erb +++ b/app/views/decidim/budgets/orders/index.html.erb @@ -28,7 +28,7 @@
<%= link_to projects_path, class: "action-link" do %> - <%= icon "arrow-left", class: "icon--small", "aria-hidden": true %> + <%= icon "arrow-left-line", class: "icon--small", "aria-hidden": true %> <%= t(".back") %> <% end %>
diff --git a/app/views/decidim/budgets/projects/_filters.html.erb b/app/views/decidim/budgets/projects/_filters.html.erb index 7821fa2..f8dcd9d 100644 --- a/app/views/decidim/budgets/projects/_filters.html.erb +++ b/app/views/decidim/budgets/projects/_filters.html.erb @@ -41,11 +41,11 @@ type_suffix = defined?(type) ? "_#{type}" : ""
@@ -89,7 +89,7 @@ type_suffix = defined?(type) ? "_#{type}" : ""
diff --git a/app/views/decidim/budgets/projects/_filters_small_view.html.erb b/app/views/decidim/budgets/projects/_filters_small_view.html.erb index 62fc5a5..ed9ac08 100644 --- a/app/views/decidim/budgets/projects/_filters_small_view.html.erb +++ b/app/views/decidim/budgets/projects/_filters_small_view.html.erb @@ -1,7 +1,7 @@
diff --git a/app/views/decidim/budgets/projects/_linked_projects.html.erb b/app/views/decidim/budgets/projects/_linked_projects.html.erb deleted file mode 100644 index a69b2ac..0000000 --- a/app/views/decidim/budgets/projects/_linked_projects.html.erb +++ /dev/null @@ -1,12 +0,0 @@ -
- <% resources.each do |project| %> -
- <%= icon "actions", class: "card--list__icon", role: "img", "aria-hidden": true, remove_icon_class: true %> - <%= link_to resource_locator([project.budget, project]).path, class: "card--list__text card__link card__link--block" do %> -
- <%= translated_attribute(project.title) %> -
- <% end %> -
- <% end %> -
diff --git a/app/views/decidim/budgets/projects/_project.html.erb b/app/views/decidim/budgets/projects/_project.html.erb index 3c4dd33..07c7526 100644 --- a/app/views/decidim/budgets/projects/_project.html.erb +++ b/app/views/decidim/budgets/projects/_project.html.erb @@ -1 +1,2 @@ -<%= cell("decidim/budgets/project_l", project) %> +<% show_only_added ||= params.dig(:filter, :addition_type) == "added" %> +<%= card_for project, render_extra_data: true, link_whole_card: false, wrapper_class: "project-item", show_only_added: %> diff --git a/app/views/decidim/budgets/projects/_project_actions.html.erb b/app/views/decidim/budgets/projects/_project_actions.html.erb index b740b4e..9129a36 100644 --- a/app/views/decidim/budgets/projects/_project_actions.html.erb +++ b/app/views/decidim/budgets/projects/_project_actions.html.erb @@ -7,7 +7,7 @@ <% end %> @@ -16,7 +16,7 @@
<%= link_to "#comments", class: "action-link" do %> <%= t ".show_comments" %> - <%= icon "comment-square", role: "img", "aria-hidden": true %> + <%= icon "question-answer-line", role: "img", "aria-hidden": true %> <% end %>
<% end %> @@ -24,7 +24,7 @@
@@ -33,7 +33,7 @@ <% if false %>
diff --git a/app/views/decidim/budgets/projects/_project_budget_button.html.erb b/app/views/decidim/budgets/projects/_project_budget_button.html.erb index dff8a1e..a63d5be 100644 --- a/app/views/decidim/budgets/projects/_project_budget_button.html.erb +++ b/app/views/decidim/budgets/projects/_project_budget_button.html.erb @@ -15,7 +15,7 @@ class: style == :link ? "link" : "button small expanded primary hollow", "aria-label": t("decidim.budgets.projects.project_budget_button.remove_descriptive", resource_name: translated_attribute(project.title)) ) do %> - <%= icon("x", role: "img", "aria-hidden": true) %> + <%= icon("close-circle-line", role: "img", "aria-hidden": true) %> <%= t("decidim.budgets.projects.project_budget_button.remove_from_vote") %> <% end %> <% elsif current_user.present? %> @@ -33,7 +33,7 @@ class: style == :link ? "link" : "button small expanded primary", "aria-label": t("decidim.budgets.projects.project_budget_button.add_descriptive", resource_name: translated_attribute(project.title)) ) do %> - <%= icon("plus", role: "img", "aria-hidden": true) %> + <%= icon("add-line", role: "img", "aria-hidden": true) %> <%= t("decidim.budgets.projects.project_budget_button.add_to_vote") %> <% end %> <% end %> diff --git a/app/views/decidim/budgets/projects/_project_modal.html.erb b/app/views/decidim/budgets/projects/_project_modal.html.erb index 0e825f6..dbd0019 100644 --- a/app/views/decidim/budgets/projects/_project_modal.html.erb +++ b/app/views/decidim/budgets/projects/_project_modal.html.erb @@ -1,26 +1,27 @@ -