Swap order of avatar links

If the conditional CSS rules failed to match for some reason, we should
prefer the general avatar image rather than the "my" avatar one. That
way the fallback mode will still look correct.
This commit is contained in:
Kevin McConnell
2025-12-15 11:22:00 +00:00
parent 88ab0beb24
commit d4cbc86113
+2 -2
View File
@@ -44,8 +44,8 @@ module AvatarsHelper
def avatar_image_tag(user, **options)
tag.span data: { creator_id: user.id } do
safe_join [
image_tag(user_avatar_url(user, script_name: user.account.slug), aria: { hidden: "true" }, size: 48, title: user.name, data: { only_visible_to_others: true }, **options),
image_tag(my_avatar_url(script_name: user.account.slug), aria: { hidden: "true" }, size: 48, title: user.name, data: { only_visible_to_you: true }, **options)
image_tag(my_avatar_url(script_name: user.account.slug), aria: { hidden: "true" }, size: 48, title: user.name, data: { only_visible_to_you: true }, **options),
image_tag(user_avatar_url(user, script_name: user.account.slug), aria: { hidden: "true" }, size: 48, title: user.name, data: { only_visible_to_others: true }, **options)
]
end
end