JSFiddle - React, Tailwind, and code Playground
by ibroom
HTML
<script src="https://cdn.embedly.com/widgets/platform.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/foundation/6.2.0/foundation.css">
<div class="row">
<div class="small-8 columns small-centered text-right">
<a class="button">Play</a>
</div>
</div>
<div class="row">
<div class="small-10 columns small-centered">
<blockquote class="embedly-card" data-card-key="1d5c48f7edc34c54bdae4c37b681ea2b">
<h4><a href="https://vimeo.com/158773447">Seeking Nirvana Pt. 2 ~ Cabin Fever</a></h4>
<p>Childhood friends embark on a journey past roads-end. Far from civilization, deep in the wilds of British Columbia, time slows as they align with their surroundings. Battling blizzards they quest towards untracked landscapes of powder glory. Through
trial and triumph they tirelessly press on. The snow falls, the angst builds.</p>
</blockquote>
</div>
</div>
CSS
.button {
width: 100%;
margin: 2rem 0;
}
JavaScript
var players = [];
var current,duration,complete;
embedly('player', function(player) {
players.push(player);
});
$('.button').on('click', function() {
players.forEach(function(player) {
player.play();
/* setInterval(function ()
{ */
player.on('timeupdate', function(data){
// autoplay the video.
console.log('Duration: '+ data.duration);
console.log('Current Time: '+ data.seconds);
});
//},1000);
});
return false;
});