Hovering Username

In JIRA hovering username or display name of a user pops up a preview of user’s profile. Even user mention text in rendered issue description has this capability. Look at the following screenshot to refresh your memory for better understanding which feature I am mentioning.

Hovering on username or display name

It is surprisingly easy to include this capability in your own applications. The only thing you should do is adding two attributes to your html element:

class=”user-hover” rel=”username_of_user”

CSS class is always “user-hover” but value of rel attribute should be set to username of the user (not display name) you like display when user hover the mouse on the element.

Following code sample is a complete implementation from Worklog PRO jira plugin. Yes, it is that simple.

<span class="user-hover" rel="$worklogSummary.username">$worklogSummary.userDisplayName</span>