Skip to content

Commit

Permalink
Merge pull request #246 from marekdedic/specify-video-dims
Browse files Browse the repository at this point in the history
Added the option to put in video size
  • Loading branch information
marekdedic authored Jun 13, 2020
2 parents deb31bb + 4ce66b9 commit 7a332b7
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ they can switch to fullscreen mode by pressing enter.
Video can be displayed in imagelightbox, by including a `data-ilb2-video` attribute in the link. This attribute should contain a JSON-encoded list of parameters as they would be in an HTML5 video tag. For multiple video sources, the `sources` field can be added, containing a list of similarily encoded HTML5 source tags.

````html
<a data-ilb2-video='{"controls":"controls", "autoplay":"autoplay", "sources":[{"src":"images/video.m4v", "type":"video/mp4"}]}' data-imagelightbox="x">
<a data-ilb2-video='{"controls":"controls", "autoplay":"autoplay", "sources":[{"src":"images/video.m4v", "type":"video/mp4"}], "width": 1920, "height": 1080}' data-imagelightbox="x">
<img src="images/video-thumb.jpg">
</a>
````
Expand Down
Loading

0 comments on commit 7a332b7

Please sign in to comment.