Closed grrowl closed 4 years ago
Although just realised these are boolean attributes — so this should be an if
instead of a when
— ~please stand by~
edit: this is done, thanks!
Added muted
too, since I happened to see this on the MDN docs for video
:
In some browsers (e.g. Chrome 70.0) autoplay doesn't work if no muted attribute is present.
There might be a better way handle simple boolean attributes in code (with a Map or something) but I'm a little bit new to hugo shortcodes, but happy to take suggestion. Thanks!
This is not forgotten, but I didn't have the time to integrate it yet :-/
Great feedback, thanks! Updated the PR
Now I can do this:
having any value defined for "autoplay" or "loop" will add the properties to the
video
element