Add “Update available” navigation item at top of navbar when new Mastodon versions are available (#39705)
This commit is contained in:
1 parent
7db2a99504
commit
f4cdbb9015
5 files changed
+12
-3
No files matched your search
@@ -1226,6 +1226,7 @@ en:
|
||||
other: Used by %{count} people over the last week
|
||||
title: Recommendations & Trends
|
||||
trending: Trending
|
||||
update_available: Update available
|
||||
username_blocks:
|
||||
add_new: Add new
|
||||
block_registrations: Block registrations
|
||||
|
||||
@@ -7,10 +7,12 @@ SimpleNavigation::Configuration.run do |navigation|
|
||||
n.item :web, safe_join([material_symbol('chevron_left'), t('settings.back')]), root_path
|
||||
|
||||
n.item :software_updates,
|
||||
safe_join([material_symbol('report'), t('admin.critical_update_pending')]),
|
||||
safe_join(
|
||||
SoftwareUpdate.urgent_pending? ? [material_symbol('report'), t('admin.critical_update_pending')] : [material_symbol('system_update_alt'), t('admin.update_available')]
|
||||
),
|
||||
admin_software_updates_path,
|
||||
if: -> { Rails.configuration.x.mastodon.software_update_url.present? && current_user.can?(:view_devops) && SoftwareUpdate.urgent_pending? },
|
||||
html: { class: 'warning' }
|
||||
html: { class: SoftwareUpdate.urgent_pending? ? 'warning' : nil },
|
||||
if: -> { Rails.configuration.x.mastodon.software_update_url.present? && current_user.can?(:view_devops) && SoftwareUpdate.pending? }
|
||||
|
||||
n.item :profile, safe_join([material_symbol('person'), t('settings.profile')]), settings_profile_path, if: -> { current_user.functional? && !self_destruct }, highlights_on: %r{/settings/profile|/settings/featured_tags|/settings/verification}
|
||||
n.item :privacy, safe_join([material_symbol('globe'), t('privacy.title')]), settings_privacy_path, if: -> { current_user.functional? && !self_destruct }, highlights_on: %r{/settings/privacy}
|
||||
|
||||
Reference in new issue
Block a user