Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ux modal for the admin to a group #18

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion decidim-core/app/cells/decidim/group_admins/show.erb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<%= link_to(
decidim.demote_group_manage_user_path(model.nickname, membership),
method: :post,
data: { confirm: t("decidim.group_admins.actions.are_you_sure") },
data: { confirm: t("decidim.group_admins.actions.remove_from_admin_confirm") },
class: "button button__sm button__transparent-secondary"
) do %>
<span><%= t("decidim.group_admins.actions.demote_admin") %></span>
Expand Down
4 changes: 2 additions & 2 deletions decidim-core/app/cells/decidim/group_members/show.erb
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@
t("decidim.group_members.actions.promote_to_admin"),
decidim.promote_group_manage_user_path(model.nickname, membership),
method: :post,
data: { confirm: t("decidim.group_members.actions.are_you_sure") },
data: { confirm: t("decidim.group_members.actions.promote_to_admin_confirm") },
class: "button button__sm button__transparent-secondary"
) %>

<%= link_to(
decidim.group_manage_user_path(model.nickname, membership),
method: :delete,
data: { confirm: t("decidim.group_members.actions.are_you_sure") },
data: { confirm: t("decidim.group_members.actions.remove_from_group_confirm") },
class: "button button__sm button__transparent-secondary"
) do %>
<span><%= t("decidim.group_members.actions.remove_from_group") %></span>
Expand Down
2 changes: 1 addition & 1 deletion decidim-core/app/packs/stylesheets/decidim/_modal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}

[data-dialog-container] {
@apply grid grid-cols-[auto_1fr] items-start md:items-center gap-2 text-left;
@apply flex flex-col items-start gap-2 text-left;

> svg {
@apply w-6 h-6 text-gray fill-current flex-none;
Expand Down
5 changes: 2 additions & 3 deletions decidim-core/app/views/decidim/shared/_confirm_modal.html.erb
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<%= decidim_modal id: "confirm-modal" do %>
<div data-dialog-container>
<%= icon "delete-bin-line" %>
<h2 class="h2" data-dialog-title id="dialog-title-confirm-modal"><%= t("title", scope: "decidim.shared.confirm_modal") %></h2>
<h2 class="h2" data-dialog-title id="dialog-title-confirm-modal"><%= t("title", scope: "decidim.group_members.actions.confirm_modal") %></h2>

<div data-confirm-modal-content></div>
</div>
Expand All @@ -11,7 +10,7 @@
<span><%= t("cancel", scope: "decidim.shared.confirm_modal") %></span>
</button>
<button class="button button__lg button__secondary" data-confirm-ok>
<span><%= t("ok", scope: "decidim.shared.confirm_modal") %></span>
<span><%= t("ok", scope: "decidim.group_members.actions.confirm_modal") %></span>
</button>
</div>
<% end %>
Loading