Socket
Socket
Sign inDemoInstall

@types/videojs-seek-buttons

Package Overview
Dependencies
1
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @types/videojs-seek-buttons

TypeScript definitions for videojs-seek-buttons


Version published
Weekly downloads
2.3K
decreased by-14.32%
Maintainers
1
Install size
241 kB
Created
Weekly downloads
 

Readme

Source

Installation

npm install --save @types/videojs-seek-buttons

Summary

This package contains type definitions for videojs-seek-buttons (https://github.com/mister-ben/videojs-seek-buttons#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/videojs-seek-buttons.

index.d.ts

// eslint-disable-next-line @definitelytyped/no-import-default-of-export-equals
import videojs from "video.js";

/**
 * A video.js plugin.
 *
 * In the plugin function, the value of `this` is a video.js `Player`
 * instance. You cannot rely on the player being in a "ready" state here,
 * depending on how the plugin is invoked. This may or may not be important
 * to you; if not, remove the wait for "ready"!
 *
 * @param     [options={}]
 *           An object of options left to the plugin author to define.
 */
declare function seekButtons(options?: seekButtons.Options): void;

declare namespace seekButtons {
    const VERSION: typeof videojs.VERSION;
    interface SeekButtonOptions {
        direction: "forward" | "back";
        seconds: number;
    }

    class SeekButton extends videojs.Button {
        /**
         * Constructor for class
         *
         * @param player The player
         * @param options Button options
         */
        constructor(player: videojs.Player, options?: SeekButtonOptions);
        /**
         * Return button class names which include the seek amount.
         *
         * @return css class string
         */
        buildCSSClass(): string;
        /**
         * Seek with the button's configured offset
         */
        handleClick(): void;
    }

    interface Options {
        /**
         * if a number greater than 0, a seek forward button will be added which seeks that number of seconds
         */
        forward?: number | undefined;
        /**
         * if a number greater than 0, a seek back button will be added which seeks that number of seconds
         */
        back?: number | undefined;
        /**
         * the position in the control bar to insert the button.
         * @default 1
         */
        forwardIndex?: number | undefined;
        /**
         * the position in the control bar to insert the button
         * @default 1
         */
        backIndex?: number | undefined;
    }
}

export = seekButtons;

declare module "video.js" {
    interface VideoJsPlayer {
        seekButtons: typeof seekButtons;
    }
    interface VideoJsPlayerPluginOptions {
        seekButtons?: seekButtons.Options;
    }
}

Additional Details

  • Last updated: Tue, 07 Nov 2023 15:11:36 GMT
  • Dependencies: @types/video.js

Credits

These definitions were written by Piotr Błażejewicz.

FAQs

Last updated on 07 Nov 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc