baronha / react-native-photo-editor Goto Github PK
View Code? Open in Web Editor NEW🌄 Photo editor using native modules for iOS and Android. Inherit from 2 available libraries, ZLImageEditor (iOS) and PhotoEditor (Android)
License: MIT License
🌄 Photo editor using native modules for iOS and Android. Inherit from 2 available libraries, ZLImageEditor (iOS) and PhotoEditor (Android)
License: MIT License
how can i customize font size, font style, fontFamily
Module PhotoEditor requires main queue setup since it overrides `init` but doesn't implement `requiresMainQueueSetup`.
In a future release React Native will default to initializing all native modules on a background thread unless explicitly opted-out of.
I am seeing this warning every time the app launches, please investigate.
This seems to be a solution, but I can't find which file to edit for this library.
When adding stickers using the Sticker tool, stickers can be added outside of image frames (from the upside) (android)
Is there a way to store/load an edited format to make changes to the image later?
Can I change the language of the buttons? for example the "Shape" for another word in another language?
After adding Sticker and Text but I can not resize it, do you know how to resize it, Thank you so much.
main getting problem for android, when open the edit the whole app will be closed.
would like to check the android setup with details, thanks
I am using
"react": "18.2.0",
"react-native": "^0.71.11",
On IOS I can not open the photo editor by .open() when I use local path URI ( it works by remote URL )
example: path: "file:///Users/abc/Library/Developer/CoreSimulator/Devices/EEA5C63E-7295-4A7A-B170-44827A3648C8/data/Containers/Data/Application/773955FB-5A11-4C0C-9744-C3E3DBD6AC0D/tmp/C772C64E-6113-47A3-8CCE-898E52CB0FB9.jpg"
Could you help me how to show the editor when using a URI local or captured by the camera?
This is a great library. 👍
But i need hide some button(ex: sticker,... ) non-use.
How i can do that?
Thank for reply! 😄
since i got this comment "Cannot read property 'open' of null" when using .open() method on Android , while it is doing well in ios.
Hi, I notice the crash issue of SDWebImage below version 5.13.4 as you can see here
SDWebImage/SDWebImage#3273
So could you please update SDWebImage version? Thanks so much
Hi, are there any plans to update this library to the react native new architecture?
Hi,
Instead of Brightroom ios library you can use the below mentioned library.
https://github.com/longitachi/ZLImageEditor
This library has a matching modules respective to the Android Native library.
I'm getting this error while I run the command pod install in iOS folder
[!] CocoaPods could not find compatible versions for pod "react-native-photo-editor":
In Podfile:
react-native-photo-editor (from ../node_modules/@baronha/react-native-photo-editor
)
Specs satisfying the react-native-photo-editor (from
../node_modules/@baronha/react-native-photo-editor)
dependency were found, but they required a higher minimum deployment target.
please help me
react-native version latest
platform :ios, '11.0'
Hi,
I am using this plugin for react native app which is used for editing image in both android and ios. It is working fine for android but for ios it is giving this error
Showing All Errors Only
Undefined symbol: (extension in Accelerate):__C.vImage_Buffer.free() -> ()
$defer #1 () -> () in (extension in react_native_photo_editor):__C.UIImage.resize_vI(__C.CGSize) -> __C.UIImage? in libreact-native-photo-editor.a(UIImage+ZLImageEditor.o)
ld: symbol(s) not found for architecture x86_64
I have done the setup mentioned in the doc.
I'm having an issue with the PhotoEditor.open() function: The function works perfectly fine on Android, but when running the same code on iOS, the function call terminates without any error messages and the editor does not open.
The image picker function (launchImageLibrary) is working correctly and providing a valid file URI on both platforms.
On Android, the image editor opens as expected after the image is selected.
On iOS, after selecting an image, the PhotoEditor.open() function gets called, but the editor doesn't open. There are no error messages or exceptions thrown, the function just terminates.
Code Sample:
const content = await launchImageLibrary({
mediaType: "mixed",
durationLimit: 15,
});
const path = content.assets[0].uri;
const Options = { path: path, stickers: [] };
const edited_path = await PhotoEditor.open(Options);
im new to react native i dont know how to install this library on android kindly guide me i can buy you a coffee
Android build is failing.
Compilation error. See log for more details
Hi, what should the path to the local file look like? It just works with web URL. I've tried:
const result = await PhotoEditor.open({ path: './assets/logo.png' });
and
const result = await PhotoEditor.open({ path: require('./assets/logo.png') });
and it doesn't work.
I use this photo editor but the opacity slider changes. And the opacity doesn't change.
It would be awesome if this library could ship an expo-config-plugin for EXPO SDK.
I just run "npm i @baronha/react-native-photo-editor" && "npx react-native run-android ". Then it execution failed.
The error message is :
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':@baronha/react-native-photo-editor:compileDebugKotlin'.
> Compilation error. See log for more details
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
Could you help to fix it?
I can't launch image editor in IOS simulator.
I had add pod in Podfile and run pod install.
But when I call ImageEditor.open, The program will get stuck there and the .then will not be called
My react native version: 0.71.0
After editing an image..Image size getting larger. 4x
Fatal Exception: java.lang.RuntimeException
An error occurred while executing doInBackground()
android.os.AsyncTask$4.done (AsyncTask.java:399)
java.lang.Thread.run (Thread.java:919)
Caused by java.lang.IndexOutOfBoundsException
Index: 1, Size: 0
java.util.ArrayList.get (ArrayList.java:437)
android.view.View.draw (View.java:23185)
ja.burhanrashid52.photoeditor.PhotoSaverTask.captureView (PhotoSaverTask.java:161)
ja.burhanrashid52.photoeditor.PhotoSaverTask.buildBitmap (PhotoSaverTask.java:104)
ja.burhanrashid52.photoeditor.PhotoSaverTask.saveImageInFile (PhotoSaverTask.java:88)
ja.burhanrashid52.photoeditor.PhotoSaverTask.doInBackground (PhotoSaverTask.java:70)
ja.burhanrashid52.photoeditor.PhotoSaverTask.doInBackground (PhotoSaverTask.java:23)
I see same issue in native library too => burhanrashid52/PhotoEditor#374
Can you look into this please @baronha
we are not able to check if the image is edited or not
with all version - react-native 0.63
Hi, I got error on invalid Kotlin version when running react-native run-android
React Native version: 0.69.3
e: /Users/wilson/work/carlink/CarlinkApp/node_modules/@baronha/react-native-photo-editor/android/src/main/java/com/reactnativephotoeditor/activity/PhotoEditorActivity.kt: (105, 5): Class 'kotlin.Unit' was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.6.0, expected version is 1.1.15.
assuming this is not a library, could you publish apk releases ? it would make it easy for me to install and update, thanks
Hi, does anyone encounter similar issue where pinch to zoom not working in Android but works in iOS?
React Native version: 0.69.3
Thanks.
I seems that the ZLImage editor lib causes a swift compile error here:
https://github.com/baronha/react-native-photo-editor/blob/master/ios/ZLImageEditor/Sources/General/ZLEditImageViewController.swift#L289
I am seeing the error "Type of expression is ambiguous without more context"
on ios:
how can I disable white background on any change,
I want to have transparent background but on everychange library changes the background to white color,
Thanks for the support in advance,
Hello,
Thank you for your great work!
We would like to know whether you can add crop feature for Android as well
Thanks
[stderr] Attribute application@allowBackup value=(true) from AndroidManifest.xml:16:162-188
[stderr] is also present at [:baronha_react-native-photo-editor] AndroidManifest.xml:14:9-36 value=(false).
[stderr] Suggestion: add 'tools:replace="android:allowBackup"' to element at AndroidManifest.xml:6:5-117 to override.
Task :expo-dev-client:compileDebugJavaWithJavac
Task :baronha_react-native-photo-editor:compileDebugKotlin FAILED
I've gotten the android build to build successfully before with this package INCLUDED in the package.json. However the build crashes on start up with the package installed. I recently updated to expo 47 recently and after that I can't get a successful build on android even with adding the tools:replace.... suggestion.
How do you fix this for android? The application builds fine for iOS with eas but fails for android.
Is this just not EXPO/EAS compatible for android?
Any help would be great, thanks in advance.
I am attempting to make it so that react-native-crop-picker passes into the photo editor; however, it is failing. I verified that the path from the crop picker is valid by putting it in an Image component.
Here is the error:
[Error: Load image failed: /private/var/mobile/Containers/Data/Application/100886D7-BA63-4F9C-AE14-5CB00CB60E73/tmp/react-native-image-crop-picker/73334332-A74B-4D15-AFEA-CFB07A702D4A.jpg]
Why isn't react-native-photo-editor able to access an image in this path?
Hi! Soon i will try to update native libraries, cuz they both have new versions. And will send PR @baronha
App is crashing on calling const result = await PhotoEditor.open(Options); But no errors are showing.
Code is working for me in IOS, but not Android receiving message while using example code:
Null cannot be cast to non-null type com.facebook.react.bridge.readableArray
Is there any option I could change the language? Even If I change the text manually, it would be great
As soon as I run yarn run android the library breaks, and it doesn't let me build it, the error is this:
FAILURE: Build failed with an exception.
Compilation error. See log for more details
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
Run with --scan to get full insights.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.