Widgets.us.team.HeaderSmall

us.team.headerSmall shows the team and its standings in hte given season, for soccer, nba, mlb, nhl, ncaaf and ncaab.

For the widget to render you need to provide teamUid and seasonId.


new HeaderSmall(props)

Parameters
Name Type Description
props object
Properties
Name Type Argument Description
teamUid number

Unique Team id.

seasonId number

Season id.

leagueType string <optional>

Which league to show for the team standings. Valid values are full, division, conference, all

tiedRankIndicator boolean <optional>

If true displays a tie ranking indicator based solely on win percentage or total points (depending on the sport). It does not factor in all tiebreaking scenarios that you would otherwise see using the regular standings positions.

border boolean <optional>

If true enables a border around the widget.

onItemClick function <optional>

Function/event handler. Emits uniqueTournamentId on click or touch.

Examples

HTML/Declarative

<div class="sr-widget" data-sr-widget="us.team.headerSmall" data-sr-team-uid="3428" data-sr-season-id="34465"></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.headerSmall', {teamUid: 3428, seasonId: 34465});
</script>
<div id="sr-widget"></div>

JS/Example of using Event Handler

<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.headerSmall', {teamUid: 3428, seasonId: 34465, onItemClick: function(type, obj){alert(JSON.stringify(obj));}});
</script>
<div id="sr-widget"></div>