Skip to content
Open
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -133,10 +133,16 @@ public void open(Context context, final ReadableMap options, final Promise promi
setColor(builder, options, KEY_NAVIGATION_BAR_COLOR, "setNavigationBarColor", "navigation bar");
setColor(builder, options, KEY_NAVIGATION_BAR_DIVIDER_COLOR, "setNavigationBarDividerColor", "navigation bar divider");

if (options.hasKey(KEY_DEFAULT_SHARE_MENU_ITEM) &&
options.getBoolean(KEY_DEFAULT_SHARE_MENU_ITEM)) {
builder.addDefaultShareMenuItem();
if (options.hasKey(KEY_DEFAULT_SHARE_MENU_ITEM)) {
if (options.getBoolean(KEY_DEFAULT_SHARE_MENU_ITEM)) {
builder.setShareState(CustomTabsIntent.SHARE_STATE_ON);
} else {
builder.setShareState(CustomTabsIntent.SHARE_STATE_OFF);
}
} else {
builder.setShareState(CustomTabsIntent.SHARE_STATE_OFF);
Copy link
Member

Choose a reason for hiding this comment

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

@hrishiakhade I think we can remove this else condition, so users can specify this option to enable/disable that share state instead, what do you think?

Copy link
Member

Choose a reason for hiding this comment

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

@twocs oh I added a small comment here, sorry for the delay folks!
Next time, please send me a message from WhatsApp or Telegram, this is my profile: https://bio.link/jdnichollsc 🙏

}

if (options.hasKey(KEY_ANIMATIONS)) {
final ReadableMap animations = options.getMap(KEY_ANIMATIONS);
applyAnimation(context, builder, animations);
Expand Down