Mobile profile header on My Kudos page
I'm modifying our mobile site, and I want to have this component <component id="profile-header"/> appear at the top of the MobileMyKudosPage (both received and given).
I've added it to the XML but it does not appear.
I already have this code written for the menu, which displays the avatar, rank and link to profile page:
<#assign avatarUrl = rest("/users/id/${user.id}/profiles/avatar/url").value />
<#assign rankingName = rest("users/id/${user.id}/ranking/name").value />
<#assign profileUrl = "/t5/user/viewprofilepage/user-id/${user.id}" />
<a class="menuProfile" href="${profileUrl}"> <#-- User profile URL -->
<img src="${avatarUrl}" /> <#-- User avatar -->
${rankingName} <#-- User ranking name -->
</a>
However, it does not display the 2 additional icons that sometimes appear next to the name, your Rank icon (like Moderator or Admin), and the 2nd special icon that company representatives can have. (screenshot)
How can I either:
A) make the profile header widget work on the mobilemykudos page, or
B) modify my above code to output those additional 2 icons
Thanks!
Hi,
you can use the following component:
<@component id="common.widget.user-name" user="conv:${user.login}" />
it take care of showing the username, linking to the user profile page and adds the left and right rank icons if present.
Just did a quick test and seems to work fine on mobile as well...