Git Product home page Git Product logo

clappr-thumbnails-plugin's Introduction

Clappr thumbnails plugin

At first this project was a clone of the Tom Jenkinson's clappr thumbnails plugin, a lot of the current code was written by he.

Diferrences between this and the original plugin:

Lazy-load (original loaded every image at once). One image at a time (original showed just like a gallery). Lazy-load thumbnail request url:

Parameters

getThumbnailForTime - Function that will be called once a thumbnail will be shown, the function argument will be the time where the user has hovered (in milliseconds), and the function must return the url where it should look for the image

roundBase - (default is 5) Number to round the seconds to, example, if the roundBase is 5, once the user hovers 29 seconds, your function will be called as it was just 25 seconds.

Example

var player = new Clappr.Player({
    source: "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4",
    parentId: "#player",
    plugins: {
        core: [ClapprThumbnailsPlugin],
    },
    thumbnailPlugin: {
        getThumbnailForTime: time => `https://mycdn.com/my-awesome-video/thumb-at-${time}.jpg`
    }
});

clappr-thumbnails-plugin's People

Contributors

luanraithz avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

luanraithz

clappr-thumbnails-plugin's Issues

include dist in repo?

Would make things easier for non node projects if you could include the dist in the repo? Your demo points to it but its not here.

thanks for the enhancement plugin!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.