2
0

Fix unfortunate action button wrapping in admin area (#36247)

This commit is contained in:
diondiondion
2025-09-24 10:57:18 +02:00
committed by GitHub
parent 37cec638df
commit 6cbc857ee0
8 changed files with 23 additions and 14 deletions

View File

@@ -9,7 +9,7 @@
- else
= l(announcement.created_at)
%div
.announcements-list__item__actions
- if can?(:distribute, announcement)
= table_link_to 'mail', t('admin.terms_of_service.notify_users'), admin_announcement_preview_path(announcement)
- if can?(:update, announcement)

View File

@@ -26,5 +26,5 @@
= link_to t('admin.roles.assigned_users', count: role.users.count), admin_accounts_path(role_ids: role.id)
·
%abbr{ title: role.permissions_as_keys.map { |privilege| I18n.t("admin.roles.privileges.#{privilege}") }.join(', ') }= t('admin.roles.permissions_count', count: role.permissions_as_keys.size)
%div
.announcements-list__item__actions
= table_link_to 'edit', t('admin.accounts.edit'), edit_admin_role_path(role) if can?(:update, role)

View File

@@ -3,7 +3,7 @@
#{rule_counter + 1}.
= truncate(rule.text)
.announcements-list__item__action-bar
.announcements-list__item__action-bar.no-wrap
.announcements-list__item__meta
= rule.hint

View File

@@ -6,5 +6,5 @@
.announcements-list__item__meta
= truncate(warning_preset.text)
%div
.announcements-list__item__actions
= table_link_to 'delete', t('admin.warning_presets.delete'), admin_warning_preset_path(warning_preset), method: :delete, data: { confirm: t('admin.accounts.are_you_sure') } if can?(:destroy, warning_preset)

View File

@@ -14,6 +14,6 @@
%abbr{ title: webhook.events.join(', ') }= t('admin.webhooks.enabled_events', count: webhook.events.size)
%div
.announcements-list__item__actions
= table_link_to 'edit', t('admin.webhooks.edit'), edit_admin_webhook_path(webhook) if can?(:update, webhook)
= table_link_to 'delete', t('admin.webhooks.delete'), admin_webhook_path(webhook), method: :delete, data: { confirm: t('admin.accounts.are_you_sure') } if can?(:destroy, webhook)