Widgets.us.team.soccer.TeamLeaderboard

A us.team.soccer.teamLeaderboard brings team's rankings across four statistical categories: Goals, Assists, Cards and Injuries.

For the widget to render you need to provide one of the following parameter combinations:

  1. matchId and team (home or away),
  2. teamUid and seasonId,
  3. teamUid and tournamentId,
  4. teamUid and uniqueTournamentId.

new TeamLeaderboard(props)

Parameters
Name Type Description
props object
Properties
Name Type Argument Default Description
matchId number

Match Id.

seasonId number

Season Id.

uniqueTournamentId number

Unique Tournament Id.

teamUid number

Team Uid.

tournamentId number

Tournament Id.

team string <optional>
home

Shows the stats for the home or away team.

categories string <optional>
goals, assists, cards, injuries

A comma-separated list of categories goals, assists, cards, injuries to display. Categories will be displayed in the same order as they have been defined. Does not work with dynamic change.

disableWidgetHeader boolean <optional>
true

When set to true, hides widget header.

limit number <optional>
5

Limits number of rows.

disableContrChart boolean <optional>
false

When set to true, hides contribution chart. Does not work with dynamic change.

activeTab string <optional>
id_tab_goals

Determines active category tab. Valid values are id_tab_goals, id_tab_assists, id_tab_cards, id_tab_injuries.

onTrack function <optional>

Function/event handler, see Widgets.onTrack.

border boolean <optional>

When set to true, draws border around widget.

Examples

HTML/Declarative

<div class="sr-widget" data-sr-widget="us.team.soccer.teamLeaderboard" data-sr-match-id="20064536" data-sr-team="home" data-sr-categories="goals, cards, assists, injuries" data-sr-disable-widget-header="false"></div>
<script type="application/javascript" src="https://widgets.media.sportradar.com/uscommon/widgetloader" data-sr-language="en_us" async></script>

JS/Programmatic

<script>
    (function(a,b,c,d,e,f,g,h,i){a[e]||(i=a[e]=function(){(a[e].q=a[e].q||[]).push(arguments)},i.l=1*new Date,i.o=f,
    g=b.createElement(c),h=b.getElementsByTagName(c)[0],g.async=1,g.src=d,g.setAttribute("n",e),h.parentNode.insertBefore(g,h)
    )})(window,document,"script","https://widgets.media.sportradar.com/uscommon/widgetloader","USW", {
        language: 'en_us'
    });
    USW('addWidget', '#sr-widget', 'us.team.soccer.teamLeaderboard', {matchId: 20064536, team: 'home', categories: 'goals, cards, assists, injuries', disableWidgetHeader: false});
</script>
<div id="sr-widget"></div>