Skip to content
This repository has been archived by the owner on Jan 12, 2021. It is now read-only.

Commit

Permalink
Merge pull request #1 from piotr-cz/feature-nofade
Browse files Browse the repository at this point in the history
Adding ability to keep watermark permanently visible
  • Loading branch information
brookslyrette authored Sep 14, 2016
2 parents 8de25b7 + 0fe8763 commit 2cd7eff
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ npm install --save videojs-watermark

**position:** The location to place the watermark (top-left, top-right, bottom-left, bottom-right). Defaults to 'top-right'.

**fadeTime:** The amount of time in milliseconds for the initial watermark fade. Defaults to 3000.
**fadeTime:** The amount of time in milliseconds for the initial watermark fade. Defaults to 3000. To make watermark permanently visible, use `null`.

**url:** A url to be linked to from the watermark. If the user clicks the watermark the video will be paused and the link will open in a new window.

Expand Down
6 changes: 6 additions & 0 deletions src/plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ const onPlayerReady = (player, options) => {
return;
}
setupWatermark(player, options);

// Setup watermark autofade
if (options.fadeTime === null) {
return;
}

player.on('play', () => fadeWatermark(options));
};

Expand Down

0 comments on commit 2cd7eff

Please sign in to comment.