Skip to:
Content

BuddyPress.org

Changeset 8454


Ignore:
Timestamp:
05/27/2014 05:22:39 AM (11 years ago)
Author:
johnjamesjacoby
Message:

Bring BP Default's global.js activity stream public mention animation & focus experience up to par with BP Legacy's. See r8453, #5208

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-themes/bp-default/_inc/global.js

    r8453 r8454  
    1818
    1919    /* Object filter and scope set. */
    20     var objects = [ 'members', 'groups', 'blogs', 'forums' ];
     20    var objects = [ 'members', 'groups', 'blogs', 'forums' ],
     21        $whats_new = jq('#whats-new');
     22
    2123    bp_init_objects( objects );
    2224
    2325    /* @mention Compose Scrolling */
    24     if ( bp_get_querystring('r') && jq('textarea#whats-new').length ) {
     26    if ( $whats_new.length && bp_get_querystring('r') ) {
     27        var $member_nicename = $whats_new.val();
     28
    2529        jq('#whats-new-options').animate({
    2630            height:'40px'
    2731        });
    28         jq("form#whats-new-form textarea").animate({
     32
     33        $whats_new.animate({
    2934            height:'50px'
    3035        });
    31         jq.scrollTo( jq('textarea#whats-new'), 500, {
     36
     37        jq.scrollTo( $whats_new, 500, {
    3238            offset:-125,
    3339            easing:'swing'
    3440        } );
    35         jq('textarea#whats-new').focus();
     41
     42        $whats_new.val('').focus().val( $member_nicename );
    3643    }
    3744
Note: See TracChangeset for help on using the changeset viewer.