Skip to content

Video controls in IOS Webview #1003

@Subramanian8

Description

@Subramanian8

Describe the bug
Not able to remove video controls in IOS Webview (Flutter)

const scanner = new Html5Qrcode("reader");
const config = {
            fps: 5,
            qrbox: { width: 250, height: 250 },
            disableFlip: true,
            focusMode: "continuous",
            experimentalFeatures: { useBarCodeDetectorIfSupported: true }
        };
scanner.start({ facingMode: "environment" }, config, handleScanSuccess, handleScanError).then(() => {
const video = document.querySelector("#reader video") as HTMLVideoElement;
            if (video) {
video.setAttribute("playsinline", "true");
                video.setAttribute("webkit-playsinline", "true");
                video.setAttribute("autoplay", "true");
                video.setAttribute("muted", "true");
                video.setAttribute("disablePictureInPicture", "false");
                video.setAttribute("controlsList", "nodownload nofullscreen noremoteplayback");
                video.removeAttribute("controls");
}
}).catch((error) => {
console.error("Camera access error:", error);
})

Used this to remove controls of video tag.
video.removeAttribute("controls");

Image

It is not removed in webview.
but it works properly in browsers.

Desktop (please complete the following information):

  • OS: [iOS iPhone 15]
  • Version [18.5]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions