I am having trouble resizing the VOD embed for past streams on the site. I managed to get it working and centered, but it is far too small. I have tried using the Twitch documentation on the VOD embeds, and also tried browsing the internet (eg. Stack Overflow) for solutions.
Twitch documentation: Embedding Twitch | Twitch Developers
Here is an image and some of my code.
Uploading: image.png(1)…
HTML is below, CSS is below the HTML.
<body>
<div id="vidscript">
<div id="twitch-embed">
<!-- Load the Twitch embed script -->
<script src="https://player.twitch.tv/js/embed/v1.js"></script>
<!-- Create a Twitch.Player object. This will render within the placeholder div -->
<script type="text/javascript">
new Twitch.Player("twitch-embed", {
video: "1501464684"
});
</script>
</script>
</div>
</div>
</body>
</html>
.twitch-embed {
transform: translateX(10px), translateY(1px);
transform-origin: safe center;
}
.vidscript {
height: "100%", width: "100%",
}
div.Twitch.Player {
width: 130;
height: 150px;
}
Current HTML is this :
<script src="https://player.twitch.tv/js/embed/v1.js"></script>
<div id="<laststream>">
<div id="twitch-embed"></div>
<!-- Load the Twitch embed script -->
<script src="https://player.twitch.tv/js/embed/v1.js"></script>
<!-- Create a Twitch.Player object. This will render within the placeholder div -->
<script type="text/javascript">
new Twitch.Player("twitch-embed", {
video: "1501464684"
});
</script>
var player = new Twitch.Player("
<laststream>", options); player.setVolume(0.5);
</script>
</div>
I’m certain there’s something i’m missing but i’m not sure what it might be.
