OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
use icon button instead of action menu
Behrokh Satarnejad40c4f8248ca7
diff --git a/app/components/users/sessions/row_component.rb b/app/components/users/sessions/row_component.rbindex 09975f60a3e..1abf96279e1 100644--- a/app/components/users/sessions/row_component.rb+++ b/app/components/users/sessions/row_component.rb@@ -72,47 +72,28 @@ module Usersendend- def actions- action_menu- end-privatedef button_links- [action_menu]- end-- def action_menu- render(Primer::Alpha::ActionMenu.new(anchor_align: :end)) do |menu|- menu.with_show_button(- icon: "kebab-horizontal",- "aria-label": t(:label_more),- scheme: :invisible,-- data: { "test-selector": "more-button" }- )- delete_action(menu)- end+ [delete_button]end- def delete_action(menu)+ def delete_buttonreturn if current?-- menu.with_item(- label: I18n.t(:button_delete),- scheme: :danger,- href: url_for({ controller: "/my/sessions", action: "destroy", id: session }),- tag: :button,- form_arguments: { method: :delete },- content_arguments: {+ render(+ Primer::Beta::IconButton.new(+ icon: :x,+ scheme: :invisible,+ tag: :a,+ href: url_for(controller: "/my/sessions", action: "destroy", id: session),+ "aria-label": I18n.t(:button_revoke),data: {+ method: :delete,confirm: I18n.t(:text_are_you_sure),disable_with: I18n.t(:label_loading)}- }- ) do |item|- item.with_leading_visual_icon(icon: :trash)- end+ )+ )endendend