VideoJsOptions class

Constructors

VideoJsOptions({bool? controls, bool? loop, bool? muted, String? poster, String? aspectRatio, bool? fluid, String? language, bool? liveui, String? notSupportedMessage, List<double>? playbackRates, bool? preferFullWindow, bool? responsive, List<Source>? sources, bool? suppressNotSupportedError})

Properties

aspectRatio String?
Puts the player in fluid mode and the value is used when calculating the dynamic size of the player. The value should represent a ratio - two numbers separated by a colon (e.g. "16:9" or "4:3"). Alternatively, the classes vjs-16-9, vjs-9-16, vjs-4-3 or vjs-1-1 can be added to the player.
final
controls bool?
Determines whether or not the player has controls that the user can interact with. Without controls the only way to start the video playing is with the autoplay attribute or through the Player API.
final
fluid bool?
When true, the Video.js player will have a fluid size. In other words, it will scale to fit its container at the video's intrinsic aspect ratio, or at a specified aspectRatio
final
hashCode int
The hash code for this object.
no setterinherited
language String?
A language code matching one of the available languages in the player. This sets the initial language for a player, but it can always be changed.
final
liveui bool?
Allows the player to use the new live ui that includes:
final
loop bool?
Causes the video to start over as soon as it ends.
final
muted bool?
Will silence any audio by default.
final
notSupportedMessage String?
Allows overriding the default message that is displayed when Video.js cannot play back a media source.
final
playbackRates List<double>?
An array of numbers strictly greater than 0, where 1 means regular speed (100%), 0.5 means half-speed (50%), 2 means double-speed (200%), etc. If specified, Video.js displays a control (of class vjs-playback-rate) allowing the user to choose playback speed from among the array of choices. The choices are presented in the specified order from bottom to top.
final
poster String?
A URL to an image that displays before the video begins playing. This is often a frame of the video or a custom title screen. As soon as the user hits "play" the image will go away.
final
preferFullWindow bool?
Setting this to true will change fullscreen behaviour on devices which do not support the HTML5 fullscreen API but do support fullscreen on the video element, i.e. iPhone. Instead of making the video fullscreen, the player will be stretched to fill the browser window.
final
responsive bool?
Setting this option to true will cause the player to customize itself based on responsive breakpoints (see: breakpoints option). When this option is false (the default), responsive breakpoints will be ignored.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sources List<Source>?
An array of objects that mirror the native
final
suppressNotSupportedError bool?
If set to true, then the no compatible source error will not be triggered immediately and instead will occur on the first user interaction. This is useful for Google's "mobile friendly" test tool, which can't play video but where you might not want to see an error displayed.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited