Comments (7)
use https://capacitorjs.com/docs/apis/filesystem#requestpermissions
from capacitor-file-picker.
@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.
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.
@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.
Might have to use something like this for the time being https://github.com/jepiqueau/capacitor-video-player
from capacitor-file-picker.
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.
As this is not a bug in this plugin, i am closing the issue.
from capacitor-file-picker.
Related Issues (20)
- bug: Blob is not generated for android , Works fine for web HOT 2
- Wrong default value in docs for 'readData'
- What happens if multiple = true on Android? HOT 1
- bug: select multiple documents ios HOT 4
- feat: checkPermissions/requestPermissions HOT 1
- rename `File` interface to not sow confusion with builtin `File` interface
- feat: On Android I can't select files on SD card - I see only Photos and Google drive HOT 7
- bug: Multiple: True (pickMedia, pickImages, pickVideo) only returns the first selected item HOT 4
- feat: Option for Max Limit when multiple: true HOT 1
- bug: pickImages multiple not working HOT 1
- duration is in milliseconds, whereas `HTMLMediaElement.duration` is in seconds HOT 1
- bug: image/heic width/height not present HOT 4
- bug: returns `ms` but only divisible by `1000` and `Math.floored`
- feat: add the ability to convert `image/heic` to `image/jpeg` on the fly in order to be able to show in `<img />` tag HOT 2
- feat: modifiedDate per file in result of pickFiles() HOT 2
- bug: pickVideos not working in android12 HOT 14
- bug: pickImages() throws Cannot load representation of type public.image HOT 4
- bug: NullpointerException for unknown mime type
- check if a picked file needs to be downloaded from iCloud or not HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from capacitor-file-picker.