Widgets.us.mx.season.soccer.CupRoster

A us.mx.season.soccer.cupRoster brings soccer playoff matchups.

All properties are optional but in order to render a cupRoster you will need to provide one of the following parameter combinations:

  1. seasonId,
  2. matchId or tid or utid (are used to obtain current seasonId).

new CupRoster(props)

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

Match Id.

seasonId number

Season Id.

utid number

Unique Tournament Id.

tid number

Tournament Id.

mode string <optional>
tree

Default layout, accepts tree or list.

onItemClick function <optional>

Function/event handler. Emits { matchId: matchId, seasonId: seasonId } on click or touch.

commonProps props

More props that can be used to style mx widgets Widgets.mx.theming.

Examples

HTML/Declarative

<div id="sr-widget" data-sr-widget="us.mx.season.soccer.cupRoster" data-sr-match-id="20692481" data-sr-show-only-selected-group="true"></div>
<script type="application/javascript" src="https://widgets.media.sportradar.com/uscommon/widgetloader" 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'
    });
    USW('addWidget', '#sr-widget', 'us.mx.season.soccer.cupRoster', {matchId: 20692481, showOnlySelectedGroup: true});
</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'
    });
    USW('addWidget', '#sr-widget', 'us.mx.season.soccer.cupRoster', {matchId: 20692481, showOnlySelectedGroup: true, onItemClick: function(type, obj){alert('matchId: ' + obj.matchId + ', seasonId: ' + obj.seasonId);}});
</script>
<div id="sr-widget"></div>