Options
All
  • Public
  • Public/Protected
  • All
Menu

Volume controller element.

description

This class controls the media's volume level using semantic markup, such as input range and progress elements.

see

https://codepen.io/mi-lee/post/an-overview-of-html5-semantics

see

https://developer.mozilla.org/en-US/docs/Web/API/HTMLMediaElement/volume

see

https://developer.mozilla.org/en-US/Apps/Fundamentals/Audio_and_video_delivery/cross_browser_video_player#Volume

class

Volume

implements

PlayerComponent

Hierarchy

  • Volume

Implements

Index

Constructors

Properties

Methods

Object literals

Constructors

constructor

Properties

Private button

button: HTMLButtonElement

Mute button.

type

HTMLButtonElement

memberof

Volume

Private container

container: HTMLDivElement

Container for volume elements (display and slider input).

type

HTMLDivElement

memberof

Volume

Private display

display: HTMLProgressElement

Element that displays the media's current volume level.

type

HTMLProgressElement

memberof

Volume

Private player

player: Player

Instance of OpenPlayer.

type

Player

memberof

Settings

Private slider

slider: HTMLInputElement

Element that allows changing media's current volume.

type

HTMLInputElement

memberof

Volume

Private volume

volume: number

Storage of volume value to restore it when toggling mute.

type

number

memberof

Volume

Methods

create

  • create(): void

destroy

  • destroy(): void
  • Remove HTML associated to specific OpenPlayer's element.

    This method must include the removal of its previously set events.

    memberof

    PlayerComponent

    Returns void

Object literals

Private events

events: object

Events that will be triggered in Volume element:

  • button (to toggle mute in media).
  • media (to alter volume level and modify mute's icon depending of the volume level).
  • slider (events to be triggered when clicking or sliding volume rail to modify volume level).
type

EventsList

memberof

Volume

button

button: object

Type declaration

media

media: object

Type declaration

slider

slider: object

Type declaration

Generated using TypeDoc