Closed TheDelta closed 2 months ago
Please see the suggested fix and activate it via fix_shorts_in_eu: true
flag in your config file for YouTube.
YouTube video player and YouTube player for shorts is the same thing. It seems they style they differently via CSS based on the aspect-ratio.
In https://github.com/itteco/iframely/issues/326 the consent issue was described for YouTube (and Google Maps). and the fix is to fetch it over the API (requires token) or to use a custom plugin.
The latest version of iframely doesn't handle unfortunately YouTube shorts url. My fix is to simply add the shorts url to the regex as well:
custom_plugins/domains/youtube.video.js
but this will embed the short as a youtube video.
The other way to make it work (and display as embedded short) would be to set the cookie consent with the request. Based on: https://stackoverflow.com/a/74132453/5152479
a new custom plugin
custom_plugins/domains/youtube.short.js
This will make the request with accepted consent and does the fetch like with an US based server and proper short embed. But once youtube changes the format, this will most likely break.
Would be great to have some discussion and maybe a better solutions by the developers.