For the next step please check our Storm JavaScript Player - Translations guide where you’ll learn how to customize your player messages.
In this guide, you will learn about the parameters related to the interface and styling that you can customize using the Storm Player configuration object.
/**
* Standard player configuration object
*/
const playerConfig = {
containerID: "container",
width: "100%",
aspectRatio: "16:9",
title: "Awesome live stream",
subtitle: "This is going to be epic!",
interface: {
showBigPlayBTN: true,
showTimeline: false,
autoGUIHide: true,
autoGUIHideTime: 3,
nativeMobileGUI: true
},
style: {
loaderColor: "#ffffff",
progressBar: {
gradientColor1: "#ff915a",
gradientColor2: "#ff785a"
},
cuePoint: {
gradientColor1: "#ff915a",
gradientColor2: "#ff785a"
},
unmuteLabel: {
backgroundColor: "#ffffff",
primaryColor: "#000000"
},
icons: {
primaryColor: "#ffffff",
secondaryColor: "#000000",
activeColor: "#ff915a",
errorColor: "#df0f33"
},
backgroundColor: "#000000",
text: {
titleColor: "#ffffff",
subtitleColor: "#ffffff",
errorColor: "#ffffff"
},
waitingRoomRings: {
gradientColor1: "#ff915a",
gradientColor2: "#ff785a"
},
borderRadius: "10px",
watermark: {
imgURL: "image_url.jpg",
position: "bottom_right"
}
}
};
/**
* Each player instance must be provided with both player (gui) and library configs
*/
const storm = stormPlayer(playerConfig, streamConfig);
Parameter name | Parameter type | Required | Default | Description |
---|---|---|---|---|
interface:showTimeline | boolean | no | false | If set to "true", the player will display a progress bar. This function should be enabled for DVR options. |
interface:showBigPlayBTN | boolean | no | true | Determines whether a large "Play" button should be displayed at the center of the screen on the player. |
interface:autoGUIHide | boolean | no | true | Determines whenever the player interface should disappear in case of no user interaction. |
interface:autoGUIHideTime | number | no | 3 | The number of seconds after which the player interface disappears in case of no user interaction. |
loaderColor | string | no | #ffffff | Default color for the loader. |
progressBar:gradientColor1 | string | no | #ff915a | The first color of the progress bar gradient. |
progressBar:gradientColor2 | string | no | #ff785a | The second color of the progress bar gradient. |
progressBar:cuePoint1 | string | no | #ff915a | The first color of the cue point gradient. |
progressBar:cuePoint2 | string | no | #ff785a | The second color of the cue point gradient. |
unmuteLabel:backgroundColor | string | no | #ffffff | The background color of the side bar indicating the need to unmute the volume. |
unmuteLabel:primaryColor | string | no | #000000 | The color of the text and icon on the side bar indicating the need to unmute the volume. |
icons:primaryColor | string | no | #ffffff | The main color for interface icons. |
icons:secondaryColor | string | no | #000000 | The second additional color for interface icons. |
icons:activeColor | string | no | #ff915a | The color for active elements, such as on mouse hover. |
icons:errorColor | string | no | #df0f33 | The color for icons indicating an error. |
backgroundColor | string | no | #000000 | The background color of the player. |
waitingRoomRings:gradientColor1 | string | no | #ff915a | The first color of the rings gradient. |
waitingRoomRings:gradientColor2 | string | no | #ff785a | The second color of the rings gradient. |
text:titleColor | string | no | #ffffff | The color of the stream title. |
text:subtitleColor | string | no | #ffffff | The color of the stream subtitle. |
text:errorColor | string | no | #ffffff | The color of the text indicating an error. |
borderRadius | string | no | 10px | The border radius size of the player. |
watermark:imgURL | string | no | - | The address to the PNG/JPG/GIF file with the watermark. |
watermark:position | string | no | bottom_right | The position where the watermark should appear. Possible values are "bottom_right" and "bottom_left". |
Create a free ticket and our support team will provide you necessary assistance.