Nutritious Pancake Mountain

    @inlasningstjanst/begreppa-video

    3.13.2 • Public • Published

    Begreppa video player

    Begreppa video player is a module for showing videos from Inlasningstjanst.se

    Installation

    Use the package manager npm to install Begreppa video player.

    npm install @inlasningstjanst/begreppa-video

    Usage

    Javascript

    // If you use ES Modules
    import  VideoContainer  from  '@inlasningstjanst/begreppa-video'
    
    // You'll need a css-loader to import
    // the css for the videoplayer for example: "sass-loader"
    import  '@inlasningstjanst/begreppa-video/dist/style.css'
    
    var  authToken  =  'token'
    var  elementID  =  'film_container'
    var  domain  =  'xxxxxxxx.inlasningstjanst.se'
    var  videoID  =  1
    var  video  =  new  VideoContainer()
    
    video.init(authToken,  videoID,  domain,  elementID)
    
    // Video can also be initialized with an optional parameter "options"
    
    // Example
    var options = {
        'extraButtons': ['theatre','subtitleSize'],
        'theatreContainerID': 'theatre_container', 
        'disabledLanguageTooltip': 'Example text'
    }
    // 'theatreContainerID' must be defined if 'extraButtons' contains 'theatre'
    video.init(authToken,  videoID,  domain,  elementID, options)

    HTML

    <!DOCTYPE  html>
    <html>
    	<script  type="text/javascript"  src="path/to/js"></script>
    	<link  rel="stylesheet"  type="text/css"  href="path/to/css">
    	<body>
    		<div  id="film_container"></div>
    	</body>
    </html>

    HTML (with theatreContainerID)

    <!DOCTYPE  html>
    <html>
    	<script  type="text/javascript"  src="path/to/js"></script>
    	<link  rel="stylesheet"  type="text/css"  href="path/to/css">
    	<body>
    		<div id="theatre_container">
    			<div id="film_container"></div>
    			<div id="optional_additional_container">For example a list of films</div>
    		</div>
    	</body>
    </html>

    Keywords

    none

    Install

    npm i @inlasningstjanst/begreppa-video

    DownloadsWeekly Downloads

    55

    Version

    3.13.2

    License

    UNLICENSED

    Unpacked Size

    798 kB

    Total Files

    23

    Last publish

    Collaborators

    • adam.ilt
    • inlasningstjanst.se
    • lerudiconsulting