File tree Expand file tree Collapse file tree 4 files changed +5
-14
lines changed Expand file tree Collapse file tree 4 files changed +5
-14
lines changed Original file line number Diff line number Diff line change @@ -285,8 +285,6 @@ The following options are available:
285285| swipeClose | bool | true | Swipe up to close Tobii. |
286286| draggable | bool | true | Use dragging and touch swiping. |
287287| threshold | number | 100 | Touch and mouse dragging threshold (in px). |
288- | autoplayVideo | bool | false | Videos will automatically start playing as soon as they can do so without stopping to finish loading the data. |
289- | autoplayAudio | bool | false | Audio will automatically start playing. |
290288
291289### Data attributes
292290
Original file line number Diff line number Diff line change @@ -127,7 +127,6 @@ export default function Tobii (userOptions) {
127127 threshold : 100 ,
128128 rtl : false , // TODO
129129 loop : false , // TODO
130- autoplayVideo : false ,
131130 modal : false ,
132131 theme : 'tobii--theme-default'
133132 }
Original file line number Diff line number Diff line change @@ -34,18 +34,14 @@ class HtmlType {
3434 VIDEO . currentTime = VIDEO . getAttribute ( 'data-time' )
3535 }
3636
37- if ( this . userSettings . autoplayVideo ) {
38- // Start playback (and loading if necessary)
39- VIDEO . play ( )
40- }
37+ // Start playback (and loading if necessary)
38+ VIDEO . play ( )
4139 }
4240
4341 const audio = container . querySelector ( 'audio' )
4442 if ( audio ) {
45- if ( this . userSettings . autoplayAudio ) {
46- // Start playback (and loading if necessary)
47- audio . play ( )
48- }
43+ // Start playback (and loading if necessary)
44+ audio . play ( )
4945 }
5046
5147 container . classList . add ( 'tobii-group-' + group )
Original file line number Diff line number Diff line change @@ -40,9 +40,7 @@ class YoutubeType {
4040 }
4141
4242 onLoad ( container ) {
43- if ( this . userSettings . autoplayVideo ) {
44- this . PLAYER [ container . getAttribute ( 'data-player' ) ] . playVideo ( )
45- }
43+ this . PLAYER [ container . getAttribute ( 'data-player' ) ] . playVideo ( )
4644 }
4745
4846 onLeave ( container ) {
You can’t perform that action at this time.
0 commit comments