Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

720-Add support for giphy and pexel images #1469

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
cdcd68f
Added support to open giphy and pexel picker
marecar3 Oct 18, 2019
fa362ec
Update release notes
marecar3 Oct 18, 2019
d703d87
Fixed typo in release notes
marecar3 Oct 18, 2019
6130d0c
Added missing method implementations
marecar3 Oct 18, 2019
f326576
Added empty method implementation for giphy and pexels on iOS
marecar3 Oct 18, 2019
ae19042
Merge branch 'develop' into issue/720_pexels-and-giphy-search-not-ava…
marecar3 Oct 18, 2019
ab2b2fe
Fixed failed build
marecar3 Oct 18, 2019
52d2491
Merge branch 'develop' into issue/720_pexels-and-giphy-search-not-ava…
marecar3 Oct 21, 2019
79c3ee8
Update gb reference
marecar3 Oct 21, 2019
c3516e1
Update gb reference
marecar3 Oct 21, 2019
81e9d9f
Removed unused import
marecar3 Oct 21, 2019
bc0f09f
Use MediaUploadCallback instead of MediaSelectedCallback
marecar3 Oct 23, 2019
8cbce18
Update gb reference
marecar3 Oct 23, 2019
a2f50cf
Update gb reference
marecar3 Oct 23, 2019
b5b9e19
Fixes tests
marecar3 Oct 23, 2019
262494f
Merge branch 'develop' into issue/720_pexels-and-giphy-search-not-ava…
marecar3 Oct 24, 2019
86116ce
Fix typo in requestOtherMediaPickFrom
marecar3 Oct 24, 2019
7551068
Update gb reference
marecar3 Oct 24, 2019
c7a5c3d
Update gb reference
marecar3 Oct 24, 2019
41e99a9
Edit release notes to match current implementation (exclude giphy sup…
marecar3 Oct 24, 2019
706d976
Update gb reference
marecar3 Oct 25, 2019
ac6d631
Fix iOS tests
marecar3 Oct 25, 2019
e19a386
Merge branch 'develop' into issue/720_pexels-and-giphy-search-not-ava…
marecar3 Oct 28, 2019
b7c27e5
Update gb reference
marecar3 Oct 28, 2019
e4ff3b2
Merge branch 'develop' into issue/720_pexels-and-giphy-search-not-ava…
marecar3 Oct 29, 2019
8395eac
Update gb reference
marecar3 Oct 29, 2019
3b03798
Update gb reference
marecar3 Oct 29, 2019
c4feb40
Update gutenberg reference
marecar3 Oct 29, 2019
6666209
Update gb reference
marecar3 Oct 29, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions RELEASE-NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
1.16.0
------
* Add support for pexels images
* Add left, center, and right image alignment controls

1.15.0
Expand Down
14 changes: 12 additions & 2 deletions android/app/src/main/java/com/gutenberg/MainApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public void responseHtml(String title, String html, boolean changed) {
}

@Override
public void requestMediaImport(String url, MediaSelectedCallback mediaSelectedCallback) {
public void requestMediaImport(String url, MediaUploadCallback mediaUploadCallback) {
}

@Override
Expand All @@ -49,7 +49,7 @@ public void requestMediaPickFromDeviceLibrary(MediaUploadCallback mediaUploadCal
}

@Override
public void requestMediaPickFromMediaLibrary(MediaSelectedCallback mediaSelectedCallback, Boolean allowMultipleSelection, MediaType mediaType) {
public void requestMediaPickFromMediaLibrary(MediaUploadCallback mediaUploadCallback, Boolean allowMultipleSelection, MediaType mediaType) {
}


Expand Down Expand Up @@ -77,6 +77,16 @@ public void editorDidMount(ReadableArray unsupportedBlockNames) {
public void editorDidAutosave() {
}

@Override
public void getOtherMediaPickerOptions(OtherMediaOptionsReceivedCallback otherMediaOptionsReceivedCallback, MediaType mediaType) {

}

@Override
public void requestMediaPickFrom(String mediaSource, MediaUploadCallback mediaUploadCallback, Boolean allowMultipleSelection) {

}

@Override
public void editorDidEmitLog(String message, LogLevel logLevel) {
switch (logLevel) {
Expand Down
3 changes: 3 additions & 0 deletions react-native-gutenberg-bridge/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,9 @@ dependencies {
implementation "org.webkit:android-jsc:r241213"
implementation project(':react-native-aztec')

// For animated GIF support
implementation 'com.facebook.fresco:animated-gif:2.0.0'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps this should be removed with Giphy code?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question @cameronvoell!
I was thinking to remove it but then I realize that we might need it as the user could already have gif in his Wordpress Library and it would be cool that he can see animated gif while editing the Post.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just tested this, very cool!


if (rootProject.ext.buildGutenbergFromSource) {
println "using gutenberg from source"
implementation project(':react-native-svg')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
import com.facebook.react.bridge.ReadableArray;
import com.facebook.react.bridge.WritableMap;

import org.wordpress.mobile.WPAndroidGlue.MediaOption;

import java.util.ArrayList;
import java.util.List;

public interface GutenbergBridgeJS2Parent {
Expand All @@ -17,8 +20,8 @@ interface RNMedia {

void editorDidMount(ReadableArray unsupportedBlockNames);

interface MediaSelectedCallback {
void onMediaSelected(List<RNMedia> mediaList);
interface OtherMediaOptionsReceivedCallback {
void onOtherMediaOptionsReceived(ArrayList<MediaOption> mediaList);
}

interface MediaUploadCallback {
Expand Down Expand Up @@ -76,13 +79,13 @@ public static MediaType getEnum(String value) {
}
}

void requestMediaPickFromMediaLibrary(MediaSelectedCallback mediaSelectedCallback, Boolean allowMultipleSelection, MediaType mediaType);
void requestMediaPickFromMediaLibrary(MediaUploadCallback mediaUploadCallback, Boolean allowMultipleSelection, MediaType mediaType);

void requestMediaPickFromDeviceLibrary(MediaUploadCallback mediaUploadCallback, Boolean allowMultipleSelection, MediaType mediaType);

void requestMediaPickerFromDeviceCamera(MediaUploadCallback mediaUploadCallback, MediaType mediaType);

void requestMediaImport(String url, MediaSelectedCallback mediaSelectedCallback);
void requestMediaImport(String url, MediaUploadCallback mediaUploadCallback);

void mediaUploadSync(MediaUploadCallback mediaUploadCallback);

Expand All @@ -95,4 +98,8 @@ public static MediaType getEnum(String value) {
void editorDidEmitLog(String message, LogLevel logLevel);

void editorDidAutosave();

void getOtherMediaPickerOptions(OtherMediaOptionsReceivedCallback otherMediaOptionsReceivedCallback, MediaType mediaType);

void requestMediaPickFrom(String mediaSource, MediaUploadCallback mediaUploadCallback, Boolean allowMultipleSelection);
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@
import com.facebook.react.bridge.WritableNativeMap;
import com.facebook.react.modules.core.DeviceEventManagerModule;

import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaSelectedCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaType;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.OtherMediaOptionsReceivedCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.RNMedia;
import org.wordpress.mobile.WPAndroidGlue.MediaOption;

import java.util.ArrayList;
import java.util.List;

public class RNReactNativeGutenbergBridgeModule extends ReactContextBaseJavaModule {
Expand Down Expand Up @@ -110,14 +112,19 @@ public void editorDidMount(ReadableArray unsupportedBlockNames) {
public void requestMediaPickFrom(String mediaSource, ReadableArray filter, Boolean allowMultipleSelection, final Callback onUploadMediaSelected) {
MediaType mediaType = getMediaTypeFromFilter(filter);
if (mediaSource.equals(MEDIA_SOURCE_MEDIA_LIBRARY)) {
mGutenbergBridgeJS2Parent.requestMediaPickFromMediaLibrary(getNewMediaSelectedCallback(allowMultipleSelection, onUploadMediaSelected), allowMultipleSelection, mediaType);
mGutenbergBridgeJS2Parent.requestMediaPickFromMediaLibrary(getNewUploadMediaCallback(allowMultipleSelection, onUploadMediaSelected), allowMultipleSelection, mediaType);
} else if (mediaSource.equals(MEDIA_SOURCE_DEVICE_LIBRARY)) {
mGutenbergBridgeJS2Parent.requestMediaPickFromDeviceLibrary(getNewUploadMediaCallback(allowMultipleSelection, onUploadMediaSelected), allowMultipleSelection, mediaType);
} else if (mediaSource.equals(MEDIA_SOURCE_DEVICE_CAMERA)) {
mGutenbergBridgeJS2Parent.requestMediaPickerFromDeviceCamera(getNewUploadMediaCallback(false, onUploadMediaSelected), mediaType);
}
}

@ReactMethod
public void requestOtherMediaPickFrom(String mediaSource, Boolean allowMultipleSelection, final Callback onUploadMediaSelected) {
mGutenbergBridgeJS2Parent.requestMediaPickFrom(mediaSource, getNewUploadMediaCallback(allowMultipleSelection, onUploadMediaSelected), allowMultipleSelection);
}

private MediaType getMediaTypeFromFilter(ReadableArray filter) {
switch (filter.size()) {
case 1:
Expand All @@ -137,7 +144,7 @@ private MediaType getMediaTypeFromFilter(ReadableArray filter) {

@ReactMethod
public void requestMediaImport(String url, final Callback onUploadMediaSelected) {
mGutenbergBridgeJS2Parent.requestMediaImport(url, getNewMediaSelectedCallback(false, onUploadMediaSelected));
mGutenbergBridgeJS2Parent.requestMediaImport(url, getNewUploadMediaCallback(false, onUploadMediaSelected));
}

@ReactMethod
Expand Down Expand Up @@ -170,18 +177,21 @@ public void editorDidAutosave() {
mGutenbergBridgeJS2Parent.editorDidAutosave();
}

private MediaSelectedCallback getNewMediaSelectedCallback(final Boolean allowMultipleSelection, final Callback jsCallback) {
return new MediaSelectedCallback() {
@Override public void onMediaSelected(List<RNMedia> mediaList) {
if(allowMultipleSelection) {
WritableArray writableArray = new WritableNativeArray();
for (RNMedia media : mediaList) {
writableArray.pushMap(media.toMap());
}
jsCallback.invoke(writableArray);
} else {
jsCallback.invoke(mediaList.get(0).toMap());
@ReactMethod
public void getOtherMediaOptions(ReadableArray filter, final Callback jsCallback) {
OtherMediaOptionsReceivedCallback otherMediaOptionsReceivedCallback = getNewOtherMediaReceivedCallback(jsCallback);
MediaType mediaType = getMediaTypeFromFilter(filter);
mGutenbergBridgeJS2Parent.getOtherMediaPickerOptions(otherMediaOptionsReceivedCallback, mediaType);
}

private OtherMediaOptionsReceivedCallback getNewOtherMediaReceivedCallback(final Callback jsCallback) {
return new OtherMediaOptionsReceivedCallback() {
@Override public void onOtherMediaOptionsReceived(ArrayList<MediaOption> mediaOptions) {
WritableArray writableArray = new WritableNativeArray();
for (MediaOption mediaOption : mediaOptions) {
writableArray.pushMap(mediaOption.toMap());
}
jsCallback.invoke(writableArray);
}
};
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package org.wordpress.mobile.WPAndroidGlue;

import com.facebook.react.bridge.WritableMap;
import com.facebook.react.bridge.WritableNativeMap;

public class MediaOption {

private static final String KEY_VALUE = "value";
private static final String KEY_LABEL = "label";

private String mId;
private String mName;

public MediaOption(String id, String name) {
mId = id;
mName = name;
}

public String getId() {
return mId;
}

public String getName() {
return mName;
}

public WritableMap toMap() {
WritableMap map = new WritableNativeMap();
map.putString(KEY_VALUE, mId);
map.putString(KEY_LABEL, mName);
return map;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
import org.wordpress.android.util.AppLog;
import org.wordpress.mobile.ReactNativeAztec.ReactAztecPackage;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaSelectedCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaUploadCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.RNMedia;
import org.wordpress.mobile.ReactNativeGutenbergBridge.RNReactNativeGutenbergBridgePackage;
Expand All @@ -59,7 +58,6 @@ public class WPAndroidGlueCode {
private ReactInstanceManager mReactInstanceManager;
private ReactContext mReactContext;
private RNReactNativeGutenbergBridgePackage mRnReactNativeGutenbergBridgePackage;
private MediaSelectedCallback mPendingMediaSelectedCallback;
private MediaUploadCallback mPendingMediaUploadCallback;
private boolean mMediaPickedByUserOnBlock;

Expand Down Expand Up @@ -116,6 +114,8 @@ public interface OnMediaLibraryButtonListener {
void onRetryUploadForMediaClicked(int mediaId);
void onCancelUploadForMediaClicked(int mediaId);
void onCancelUploadForMediaDueToDeletedBlock(int mediaId);
ArrayList<MediaOption> onGetOtherMediaImageOptions();
void onOtherMediaButtonClicked(String mediaSource, boolean allowMultipleSelection);
}

public interface OnReattachQueryListener {
Expand Down Expand Up @@ -153,9 +153,9 @@ public void responseHtml(String title, String html, boolean changed) {
}

@Override
public void requestMediaPickFromMediaLibrary(MediaSelectedCallback mediaSelectedCallback, Boolean allowMultipleSelection, MediaType mediaType) {
public void requestMediaPickFromMediaLibrary(MediaUploadCallback mediaSelectedCallback, Boolean allowMultipleSelection, MediaType mediaType) {
mMediaPickedByUserOnBlock = true;
mPendingMediaSelectedCallback = mediaSelectedCallback;
mPendingMediaUploadCallback = mediaSelectedCallback;
if (mediaType == MediaType.IMAGE) {
mOnMediaLibraryButtonListener.onMediaLibraryImageButtonClicked(allowMultipleSelection);
} else if (mediaType == MediaType.VIDEO) {
Expand Down Expand Up @@ -190,7 +190,7 @@ public void requestMediaPickerFromDeviceCamera(MediaUploadCallback mediaUploadCa
}

@Override
public void requestMediaImport(String url, MediaSelectedCallback mediaSelectedCallback) {
public void requestMediaImport(String url, MediaUploadCallback mediaSelectedCallback) {
// no op - we don't need to paste images on Android, but the method needs to exist
// to match the iOS counterpart
}
Expand Down Expand Up @@ -252,6 +252,26 @@ public void editorDidEmitLog(String message, LogLevel logLevel) {
break;
}
}

@Override
public void getOtherMediaPickerOptions(OtherMediaOptionsReceivedCallback otherMediaOptionsReceivedCallback,
MediaType mediaType) {
if (mediaType == MediaType.IMAGE || mediaType == MediaType.MEDIA) {
ArrayList<MediaOption> otherMediaImageOptions = mOnMediaLibraryButtonListener.onGetOtherMediaImageOptions();
otherMediaOptionsReceivedCallback.onOtherMediaOptionsReceived(otherMediaImageOptions);
} else {
otherMediaOptionsReceivedCallback.onOtherMediaOptionsReceived(new ArrayList<MediaOption>());
}
}

@Override
public void requestMediaPickFrom(String mediaSource,
MediaUploadCallback mediaSelectedCallback,
Boolean allowMultipleSelection) {
mPendingMediaUploadCallback = mediaSelectedCallback;
mMediaPickedByUserOnBlock = true;
mOnMediaLibraryButtonListener.onOtherMediaButtonClicked(mediaSource, allowMultipleSelection);
}
});

return Arrays.asList(
Expand Down Expand Up @@ -522,21 +542,6 @@ private String getMediaType(final boolean isVideo) {
return isVideo ? "video" : "image";
}

public void appendMediaFile(int mediaId, final String mediaUrl, final boolean isVideo) {
if (mPendingMediaSelectedCallback != null && mMediaPickedByUserOnBlock) {
String mediaType = getMediaType(isVideo);
mMediaPickedByUserOnBlock = false;
List<RNMedia> mediaList = new ArrayList<>();
mediaList.add(new Media(mediaId, mediaUrl, mediaType));
mPendingMediaSelectedCallback.onMediaSelected(mediaList);
mPendingMediaSelectedCallback = null;
} else {
// we can assume we're being passed a new image from share intent as there was no selectMedia callback
sendOrDeferAppendMediaSignal(mediaId, mediaUrl, isVideo);
}
}


public void toggleEditorMode(boolean htmlModeEnabled) {
// Turn off hardware acceleration for Oreo
// see https://github.com/wordpress-mobile/gutenberg-mobile/issues/1268#issuecomment-535887390
Expand All @@ -551,23 +556,6 @@ public void toggleEditorMode(boolean htmlModeEnabled) {
mRnReactNativeGutenbergBridgePackage.getRNReactNativeGutenbergBridgeModule().toggleEditorMode();
}

public void appendMediaFiles(ArrayList<Media> mediaList) {
if (mPendingMediaSelectedCallback != null && mMediaPickedByUserOnBlock) {
mMediaPickedByUserOnBlock = false;
List<RNMedia> rnMediaList = new ArrayList<>();
for (Media media : mediaList) {
rnMediaList.add(new Media(media.getId(), media.getUrl()));
}
mPendingMediaSelectedCallback.onMediaSelected(rnMediaList);
mPendingMediaSelectedCallback = null;
}
}


public void toggleEditorMode() {
mRnReactNativeGutenbergBridgePackage.getRNReactNativeGutenbergBridgeModule().toggleEditorMode();
}

public void appendUploadMediaFile(final int mediaId, final String mediaUri, final boolean isVideo) {
if (isMediaUploadCallbackRegistered() && mMediaPickedByUserOnBlock) {
String mediaType = getMediaType(isVideo);
Expand Down
8 changes: 8 additions & 0 deletions react-native-gutenberg-bridge/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,12 @@ export function requestImageUploadCancel( mediaId ) {
return RNReactNativeGutenbergBridge.requestImageUploadCancel( mediaId );
}

export function getOtherMediaOptions( filter, callback ) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want to block on this to get this feature out, but why are these "other"? Is there something intrinsically different in requesting an image from the device library or pexels?

I understand we might need to pass the available options through the bridge because we want to show them in the existing bottom sheet (although I think a native one is in the works), but other than that, I think the apps should define which options are available more generally.

Copy link
Contributor Author

@marecar3 marecar3 Oct 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a good question @koke.

Main idea is to provide 3rd party media sources from native applications so that in the future we can just change native apps WPAndroid or WPiOS and everything should work (without changing JS side or bridge).

I agree that it would be easier to control which options are available from one place (JS) and not from two places (WPAndroid and WPiOS), but we can see in the future if this current solution has some big downsides and if's true, we can change approach.

maybe also @etoledom can share his opinion on this one.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that it would be easier to control which options are available from one place (JS) and not from two places (WPAndroid and WPiOS)

I actually think it makes more sense to define those in the apps, and avoid gutenberg making any assumptions about the available options.

As an example, the demo app still offers device library, camera, and wp media library, but only the device library works as expected. The camera option does nothing in the iOS simulator (it has no camera), and the media library option inserts a sample image/video.

It would be better if gutenberg just asked about the available options to present them in the picker, and then request the selected one. In the demo app, we could have some options like Choose from device, Add sample image, and Add sample video, instead of pretending to support options that won't work.

I'm not sure how much effort this would be, but if we are already requesting the "others" through the bridge, it doesn't feel like it would be a hard thing to request all the options.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I missed the point at first but now it's clear.
Yeah, we can do that, it does make sense, then we can easily mock resources for the demo apps also :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually think it makes more sense to define those in the apps, and avoid gutenberg making any assumptions about the available options.

Actually, the only option on gutenberg web (stand alone) is to add an image from a link. The WordPress Media Picker is some kind of "add on" iirc.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd suggest to implement the bridge with this new options as it is now, and on a second step, migrate the "older" options to be handled on this new way.

Hopefully we keep the testing steps and possible issues lower on this PR this way.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds like a good plan @etoledom
Here is the ticket: #1492

Thanks, @koke for the points.

return RNReactNativeGutenbergBridge.getOtherMediaOptions( filter, callback );
}

export function requestOtherMediaPickFrom( mediaSource, multiple, callback ) {
return RNReactNativeGutenbergBridge.requestOtherMediaPickFrom( mediaSource, multiple, callback );
}

export default RNReactNativeGutenbergBridge;
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ @interface RCT_EXTERN_MODULE(RNReactNativeGutenbergBridge, NSObject)

RCT_EXTERN_METHOD(provideToNative_Html:(NSString *)html title:(NSString *)title changed:(BOOL)changed)
RCT_EXTERN_METHOD(requestMediaPickFrom:(NSString *)source filter:(NSArray<NSString *> *)filter allowMultipleSelection:(BOOL)allowMultipleSelection callback:(RCTResponseSenderBlock)callback)
RCT_EXTERN_METHOD(requestOtherMediaPickFrom:(NSString *)source allowMultipleSelection:(BOOL)allowMultipleSelection callback:(RCTResponseSenderBlock)callback)
RCT_EXTERN_METHOD(getOtherMediaOptions:(NSArray<NSString *> *)filter callback:(RCTResponseSenderBlock)callback)
RCT_EXTERN_METHOD(mediaUploadSync)
RCT_EXTERN_METHOD(requestImageFailedRetryDialog:(int)mediaID)
RCT_EXTERN_METHOD(requestImageUploadCancelDialog:(int)mediaID)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,16 @@ public class RNReactNativeGutenbergBridge: RCTEventEmitter {
})
}
}

@objc
func requestOtherMediaPickFrom(_ source: String, allowMultipleSelection: Bool, callback: @escaping RCTResponseSenderBlock) {
//TODO implement me
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just curious when these will be implemented, perhaps during the iOS implementation for Pexel?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great questions @cameronvoell !
Yes, that's correct. The idea is to merge JS and Android part and then @etoledom will work on iOS side of it.

}

@objc
func getOtherMediaOptions(_ filter: [String]?, callback: @escaping RCTResponseSenderBlock) {
//TODO implement me
}

@objc
func requestMediaImport(_ urlString: String, callback: @escaping RCTResponseSenderBlock) {
Expand Down