personal gifts for my husband gifted child 5 year old gift giver meaning fermacell fugenkleber giftig crest white strips coupon printable 2012 best man thank you gift ideas
Sunday, December 4, 2022
HomeiOS Developmentios - Portrait/Vertical Youtube dwell video inside webview doesn't get correct top

ios – Portrait/Vertical Youtube dwell video inside webview doesn’t get correct top


Devices i have tried it in: iPhone 11 iOS: 15, iPhone 6s iOS: 14, iPhone 8 iOS 14, Environment: App's webview, Safari, Chrome

We have followed iframe api reference(https://developers.google.com/youtube/iframe_api_reference) and using Youtube iframe in a webview accessible on our iOS app,
While live-streaming using youtube mobile app “go live” in portrait mode, on iOS, the video inside iframe's height is very small and is equivalent to a horizontal video.
WIDTH given to iFrame: 100vw
HEIGHT given to iFrame: 177vw. there is only iFrame on the page and nothing else

IMAGE: Youtube vertical video Issue in IOS

const DebugVertical = (props) => {
    const { videoId } = props.match.params;
    return (
        <iframe
        id={`youtube-embed-${videoId}`}
        src={`https://www.youtube.com/embed/${videoId}?enablejsapi=1&controls=0&playsinline=1&rel=0&fs=0`}
        frameBorder="0"
        allow="accelerometer; autoplay; encrypted-media; gyroscope"
        style={{ width: "100vw", height: "177vw" }}
        />
    );
};

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments