Code Monkey home page Code Monkey logo

Comments (7)

KANekT avatar KANekT commented on August 10, 2024

use https://capacitorjs.com/docs/apis/filesystem#requestpermissions

from capacitor-file-picker.

robingenz avatar robingenz commented on August 10, 2024

@kyleabens I'm not sure if it's the same bug but unfortunately embedding locale videos in the img tag on Android doesn't work at the moment, see ionic-team/capacitor#6021

@KANekT Can you share your use case where you need to request permission? In my tests on Android (Android 13, Pixel 5) and iOS, request permissions has not been necessary so far. If you really need this, then i have to implement the method in this plugin.

from capacitor-file-picker.

KANekT avatar KANekT commented on August 10, 2024

sorry, I did not know that such a bug already exists in the core Capacitor

I thought it was just a file permissions issue.

but - requestpermissions may be fix error in current ...

from capacitor-file-picker.

kyleabens avatar kyleabens commented on August 10, 2024

@KANekT I tried adding requestPermission and that unfortunately didn't resolve my issue.

@robingenz What I'm doing is giving users the ability to select images and videos and then display them in a modal that they can then upload to our server. Images work fine on Android, it's only videos that are not displaying. Also videos are not being placed in an img tag, I'm using the video tag for those (Eg. <video><source src="path"></video>). I don't want to convert the videos to base64 since that's memory intensive and unnecessary for simply displaying them before uploading.

Again this works on browser and iOS no problem. I'm assuming it has something to do with the videos I'm selecting being on Google photos? However images work fine so idk. At the end of the day I'm just trying to display a video in the html based on the path of that video

from capacitor-file-picker.

kyleabens avatar kyleabens commented on August 10, 2024

Might have to use something like this for the time being https://github.com/jepiqueau/capacitor-video-player

from capacitor-file-picker.

robingenz avatar robingenz commented on August 10, 2024

What I'm doing is giving users the ability to select images and videos and then display them in a modal that they can then upload to our server. Images work fine on Android, it's only videos that are not displaying. Also videos are not being placed in an img tag, I'm using the video tag for those (Eg. ).

Yes, that's the issue i linked: ionic-team/capacitor#6021

One of my clients has the same problem. Therefore, this plugin will probably generate thumbnails for videos in the next version, which can be displayed to the user. Maybe you have another use case and this isn't a solution for you.

from capacitor-file-picker.

robingenz avatar robingenz commented on August 10, 2024

As this is not a bug in this plugin, i am closing the issue.

from capacitor-file-picker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.