Skip to content

Commit

Permalink
[PROD-7208] Fix Prevent GIF picker from hiding when user clicks on se…
Browse files Browse the repository at this point in the history
…arch input
  • Loading branch information
amincdev committed May 9, 2024
1 parent 6f1218e commit d7280a1
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/bp-templates/bp-nouveau/js/buddypress-activity.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ window.bp = window.bp || {};
if (
$( '#activity-modal:visible' ).length > 0 &&
0 === $( '#bp-nouveau-activity-form-placeholder:visible' ).length &&
! $( event.target ).closest( '#activity-modal' ).length
! $( event.target ).closest( '#activity-modal' ).length &&
! $( event.target ).closest( '.gif-media-search-dropdown-standalone' ).length
) {
this.closeActivity( event );
this.activitySyncOnModalClose( event, activityId );
Expand Down
2 changes: 1 addition & 1 deletion src/bp-templates/bp-nouveau/js/buddypress-activity.min.js

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions src/bp-templates/bp-nouveau/js/buddypress-media.js
Original file line number Diff line number Diff line change
Expand Up @@ -2112,6 +2112,9 @@ window.bp = window.bp || {};

if ( !_.isUndefined( BP_Nouveau.media ) && !_.isUndefined( BP_Nouveau.media.gif_api_key ) &&
!$targetEl.closest( '.post-gif' ).length ) {
if( $targetEl.closest( '.gif-media-search-dropdown' ).length ) {
return;
}
target.find( 'form' ).find( '.gif-media-search-dropdown' ).removeClass( 'open' );
if ( $( '.gif-media-search-dropdown-standalone.open' ).length > 0 ) {
target.find( '.gif-media-search-dropdown-standalone' ).removeClass( 'open' );
Expand Down
2 changes: 1 addition & 1 deletion src/bp-templates/bp-nouveau/js/buddypress-media.min.js

Large diffs are not rendered by default.

0 comments on commit d7280a1

Please sign in to comment.