Skip to:
Content

BuddyPress.org

Changeset 12348


Ignore:
Timestamp:
02/28/2019 10:37:06 PM (6 years ago)
Author:
boonebgorges
Message:

Nouveau: Update Favorite button tooltip after AJAX action.

Props joncadams.
Fixes #8028.

Location:
trunk/src/bp-templates/bp-nouveau
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-nouveau/includes/activity/ajax.php

    r12175 r12348  
    143143
    144144    if ( bp_activity_remove_user_favorite( $_POST['id'] ) ) {
    145         $response = array( 'content' => __( 'Favorite', 'buddypress' ) );
     145        $response = array( 'content' => __( 'Mark as Favorite', 'buddypress' ) );
    146146
    147147        $fav_count = (int) bp_get_total_favorite_count_for_user( bp_loggedin_user_id() );
  • trunk/src/bp-templates/bp-nouveau/includes/activity/template-tags.php

    r12156 r12348  
    376376                    'link_class'       => 'button fav bp-secondary-action bp-tooltip',
    377377                    'data_bp_tooltip'  => __( 'Mark as Favorite', 'buddypress' ),
    378                     'link_text'        => __( 'Favorite', 'buddypress' ),
     378                    'link_text'        => __( 'Mark as Favorite', 'buddypress' ),
    379379                    'aria-pressed'     => 'false',
    380380                    'link_attr'        => bp_get_activity_favorite_link(),
  • trunk/src/bp-templates/bp-nouveau/js/buddypress-activity.js

    r12156 r12348  
    462462                                $( this ).html( response.data.content );
    463463                            }
    464                             $( this ).prop( 'title', response.data.content );
     464                            $( this ).attr( 'data-bp-tooltip', response.data.content );
    465465
    466466                            if ('false' === $(this).attr('aria-pressed') ) {
Note: See TracChangeset for help on using the changeset viewer.