Skip to content

Commit 6c6c60c

Browse files
committed
Display other roles than just "project leader" on the "Team" page
1 parent d18705f commit 6c6c60c

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

_data/governance.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,7 @@ leaders:
88
DavideD:
99
- reactive
1010
koentsje:
11-
- tools
11+
- tools
12+
roles:
13+
gavinking:
14+
- '<a href="https://github.com/orgs/commonhaus/teams/cf-egc">Project Representative to the CommonHaus Foundation for Hibernate</a>'

community/team.html.haml

+6
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ title: Hibernate Team
4444
:javascript
4545
$(document).ready(function() {
4646
var contributorsNameMapping = #{site.data_json['contributors-name-mapping']}
47+
var governance = #{site.data_json['governance']}
4748
$.getJSON( "https://api.github.com/orgs/hibernate/public_members", function( data ) {
4849
var items = [];
4950
data.forEach( function( member ) {
@@ -53,6 +54,11 @@ title: Hibernate Team
5354
.append( $( '<div class="image"/>' ).append( $('<img src="' + member.avatar_url + '" />' ) ) )
5455
.append( $( '<div class="content" />' ).append( $( '<div class="header" />' ).append( $( '<a href="' + member.html_url + '" />' ).text( memberName ) ) ) )
5556

57+
var roles = governance.roles[member.login]
58+
if ( roles ) {
59+
item.append( $( '<div class="extra content" />' ).html( roles.join(', ') + '.' ) );
60+
}
61+
5662
var leaderItem = $( '.leader-list [data-github-login=' + member.login + ']' )
5763
if ( leaderItem.length ) {
5864
item.append( $( '<div class="extra content" />' ).text( 'Leader of ' + leaderItem.data( 'project-names' ) + '.' ) );

0 commit comments

Comments
 (0)