Widgets.nfl.player.TopSpeedComparison

Widget nfl.player.topSpeedComparison brings direct top speed comparison between any two players across any team or position grouping. Excludes all special teams plays.

For the widget to render you need to provide seasonId, other properties are optional.


new TopSpeedComparison(props)

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

Season Id.

leftTeamId string <optional>

Left Team Id. Selects team from left team menu.
If it's not provided, left team selection menu defaults to first team name in AFC conference and alphabetical order.

leftPositionId string <optional>
wide_receivers

Left Position Id. Selects position from left position menu. Valid values: quarterbacks, running_backs, wide_receivers, tightends, offensive_linemen, defensive_backs, linebackers, defensive_linemen.

leftPlayerId string <optional>

Left Player Id. Selects player from left player menu.
If it's not provided or leftPlayerId does not match any of the players shown, left player menu defaults to current left selection top player.


This prop requires:

  • leftTeamId
rightTeamId string <optional>

Right Team Id. Selects team from right team menu.
If it's not provided, right team selection menu defaults to first team name in NFC conference and alphabetical order.

rightPositionId string <optional>
wide_receivers

Right Position Id. Selects position from right position menu. Valid values: quarterbacks, running_backs, wide_receivers, tightends, offensive_linemen, defensive_backs, linebackers, defensive_linemen.

rightPlayerId string <optional>

Right Player Id. Selects player from right player menu.
If it's not provided or rightPlayerId does not match any of the players shown, left player menu defaults to current right selection top player.


This prop requires:

  • rightTeamId
disableTeamMenu bool <optional>
false

When set to true, disables the team selection menus.


This prop requires:

  • leftTeamId
  • rightTeamId
disableTeamAndPlayerMenu bool <optional>
false

When set to true, disables all the team and player selection menus.


This prop requires:

  • leftTeamId
  • rightTeamId
  • leftPlayerId
  • rightPlayerId
useTeamColors boolean <optional>
null

Valid values are:

  • null (the default) = settings from the client configuration are used. If the client is configured to use team colors, then the theme can be overriden with the teamColorsTheme parameter.
  • true = team colors will be used, as specified with the teamColorsTheme parameter. If the teamColorsTheme is not specified and the client configuration does not specify a team colors theme, or if the teamColorsTheme contains an invalid theme name, then team colors will not be used.
  • false = team colors will not be used.
teamColorsTheme string <optional>
null

When set (and not disabled by useTeamColors), specifies the name of the formula to calculate team colors (e.g. mono-team-colors-light).

onTrack function <optional>

Function/event handler, see Widgets.onTrack

Examples

HTML/Declarative

<div id="sr-widget" data-sr-widget="nfl.player.topspeedcomparison" data-sr-season-id="2016"></div>
 <script type="application/javascript" src="https://widgets.media.sportradar.com/sportradar/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/sportradar/widgetloader","USW", {
        language: 'en'
    });
    USW('addWidget', '#sr-widget', 'nfl.player.topspeedcomparison', {seasonId: 2016});
</script>
<div id="sr-widget"></div>