Skip to:
Content

BuddyPress.org

Changeset 13185


Ignore:
Timestamp:
12/12/2021 03:14:40 PM (2 years ago)
Author:
imath
Message:

Improve /* translators:*/ comments consistency

Fixes #8575

Location:
trunk/src
Files:
16 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-friends/bp-friends-blocks.php

    r13140 r13185  
    9696    $link = trailingslashit( bp_core_get_user_domain( $user_id ) . bp_get_friends_slug() );
    9797
    98     /* translators: %s is the member's display name */
     98    /* translators: %s: member name */
    9999    $title = sprintf( __( '%s\'s Friends', 'buddypress' ), bp_core_get_user_displayname( $user_id ) );
    100100
     
    165165                    $extra = sprintf( _n( '%s friend', '%s friends', $user->total_friend_count, 'buddypress' ), number_format_i18n( $user->total_friend_count ) );
    166166                } else {
    167                     /* translators: %s: a human time diff. */
     167                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    168168                    $extra = sprintf( __( 'Active %s', 'buddypress' ), bp_core_time_since( $user->last_activity ) );
    169169                }
  • trunk/src/bp-groups/bp-groups-blocks.php

    r13140 r13185  
    440440                    $extra = sprintf( _n( '%s member', '%s members', $count, 'buddypress' ), bp_core_number_format( $count ) );
    441441                } else {
    442                     /* translators: %s: a human time diff. */
     442                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    443443                    $extra = sprintf( __( 'Active %s', 'buddypress' ), bp_get_group_last_active( $group ) );
    444444                }
  • trunk/src/bp-groups/bp-groups-functions.php

    r13184 r13185  
    22672267
    22682268    if ( ! empty( $membership_id ) ){
     2269        /* translators: 1: the name of the method. 2: the name of the file. */
    22692270        _deprecated_argument( __METHOD__, '5.0.0', sprintf( __( 'Argument `membership_id` passed to %1$s is deprecated. See the inline documentation at %2$s for more details.', 'buddypress' ), __METHOD__, __FILE__ ) );
    22702271    }
     
    23042305function groups_delete_membership_request( $membership_id, $user_id = 0, $group_id = 0 ) {
    23052306    if ( ! empty( $membership_id ) ){
    2306         /* translators: 1: method name. 2: file name. */
     2307        /* translators: 1: the name of the method. 2: the name of the file. */
    23072308        _deprecated_argument( __METHOD__, '5.0.0', sprintf( __( 'Argument `membership_id` passed to %1$s is deprecated. See the inline documentation at %2$s for more details.', 'buddypress' ), __METHOD__, __FILE__ ) );
    23082309    }
  • trunk/src/bp-groups/bp-groups-template.php

    r13184 r13185  
    22232223        $count        = (int) $group->total_member_count;
    22242224        $count_string = sprintf(
    2225             // translators: %s: total member count for the group.
     2225            /* translators: %s is the number of Group members */
    22262226            _n( '%s member', '%s members', $count, 'buddypress' ),
    22272227            bp_core_number_format( $count )
     
    40804080                'type'    => 'full',
    40814081                'email'   => $members_template->member->user_email,
     4082                /* translators: %s: member name */
    40824083                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), $members_template->member->display_name )
    40834084            )
     
    41224123                'type'    => 'thumb',
    41234124                'email'   => $members_template->member->user_email,
     4125                /* translators: %s: member name */
    41244126                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), $members_template->member->display_name )
    41254127            )
     
    41664168                'type'    => 'thumb',
    41674169                'email'   => $members_template->member->user_email,
     4170                /* translators: %s: member name */
    41684171                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), $members_template->member->display_name ),
    41694172                'width'   => absint( $width ),
     
    57775780     * @param string $value HTML markup for the user's avatar thumbnail.
    57785781     */
    5779     echo apply_filters( 'bp_group_request_user_avatar_thumb', bp_core_fetch_avatar( array( 'item_id' => $requests_template->request->user_id, 'type' => 'thumb', 'alt' => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_core_get_user_displayname( $requests_template->request->user_id ) ) ) ) );
     5782    echo apply_filters(
     5783        'bp_group_request_user_avatar_thumb',
     5784        bp_core_fetch_avatar(
     5785            array(
     5786                'item_id' => $requests_template->request->user_id,
     5787                'type'    => 'thumb',
     5788                /* translators: %s: member name */
     5789                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_core_get_user_displayname( $requests_template->request->user_id ) )
     5790            )
     5791        )
     5792    );
    57805793}
    57815794
  • trunk/src/bp-groups/classes/class-bp-groups-group.php

    r13184 r13185  
    207207                '1.6.0',
    208208                sprintf(
    209                     /* translators: 1: the name of the method. 2: the name of the file. */
     209                    /* translators: 1: the name of the function. 2: the name of the file. */
    210210                    esc_html__( '%1$s no longer accepts arguments. See the inline documentation at %2$s for more details.', 'buddypress' ),
    211211                    __METHOD__,
  • trunk/src/bp-members/bp-members-blocks.php

    r13140 r13185  
    458458                    $extra = sprintf( _n( '%s friend', '%s friends', $user->total_friend_count, 'buddypress' ), number_format_i18n( $user->total_friend_count ) );
    459459                } else {
    460                     /* translators: %s: a human time diff. */
     460                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    461461                    $extra = sprintf( __( 'Active %s', 'buddypress' ), bp_core_time_since( $user->last_activity ) );
    462462                }
  • trunk/src/bp-members/bp-members-notifications.php

    r13168 r13185  
    7272                $amount = 'multiple';
    7373
     74                /* translators: %d: is the number of people who requested site membership */
    7475                $text = sprintf( __( '%d people have requested site membership.', 'buddypress' ), (int) $total_items );
    7576            } else {
  • trunk/src/bp-members/bp-members-template.php

    r13184 r13185  
    861861                'id'      => false,
    862862                'no_grav' => false,
    863                 // translators: %s is the full name of the user.
     863                /* translators: %s: member name */
    864864                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), $fullname ),
    865865            )
     
    16721672                'height'  => false,
    16731673                'html'    => true,
     1674                /* translators: %s: member name */
    16741675                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_loggedin_user_fullname() )
    16751676            )
     
    17301731                'height'  => false,
    17311732                'html'    => true,
     1733                /* translators: %s: member name */
    17321734                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_displayed_user_fullname() )
    17331735            )
  • trunk/src/bp-members/classes/class-bp-members-component.php

    r13167 r13185  
    707707                'item_id' => bp_displayed_user_id(),
    708708                'type'    => 'thumb',
     709                /* translators: %s: member name */
    709710                'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), $bp->bp_options_title )
    710711            ) );
  • trunk/src/bp-messages/bp-messages-template.php

    r13148 r13185  
    765765
    766766        $fullname = bp_core_get_user_displayname( $messages_template->thread->last_sender_id );
    767         $alt      = sprintf( __( 'Profile picture of %s', 'buddypress' ), $fullname );
     767
     768        /* translators: %s: member name */
     769        $alt = sprintf( __( 'Profile picture of %s', 'buddypress' ), $fullname );
    768770
    769771        $r = bp_parse_args(
  • trunk/src/bp-messages/classes/class-bp-messages-component.php

    r13144 r13185  
    409409                    'item_id' => bp_displayed_user_id(),
    410410                    'type'    => 'thumb',
     411                    /* translators: %s: member name */
    411412                    'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_displayed_user_fullname() )
    412413                ) );
  • trunk/src/bp-notifications/classes/class-bp-notifications-component.php

    r13093 r13185  
    293293                    'item_id' => bp_displayed_user_id(),
    294294                    'type'    => 'thumb',
     295                    /* translators: %s: member name */
    295296                    'alt'     => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_displayed_user_fullname() )
    296297                ) );
  • trunk/src/bp-templates/bp-nouveau/buddypress/members/single/groups/invites.php

    r12156 r13185  
    3737                            <?php
    3838                            printf(
    39                                 /* translators: %s = number of members */
     39                                /* translators: %s is the number of Group members */
    4040                                _n(
    4141                                    '%s member',
  • trunk/src/js/bp-friends/js/friends.js

    r13002 r13185  
    2828            friends.forEach( ( friend ) => {
    2929                if ( 'active' === type && friend.last_activity ) {
    30                     /* translators: %s: a human time diff. */
     30                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    3131                    friend.extra = sprintf( __( 'Active %s', 'buddypress' ), friend.last_activity.timediff );
    3232                } else if ( 'popular' === type && friend.total_friend_count ) {
  • trunk/src/js/bp-groups/js/dynamic-groups.js

    r13004 r13185  
    4040                        group.extra = __( '1 member', 'buddypress' );
    4141                    } else {
    42                         /* translators: %s is the number of Group members (more than 1). */
     42                        /* translators: %s is the number of Group members */
    4343                        group.extra = sprintf( __( '%s members', 'buddypress' ), group.total_member_count );
    4444                    }
    4545                } else {
    46                     /* translators: %s: a human time diff. */
     46                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    4747                    group.extra = sprintf( __( 'Active %s', 'buddypress' ), group.last_activity_diff );
    4848                }
  • trunk/src/js/bp-members/js/dynamic-members.js

    r13003 r13185  
    3030            members.forEach( ( member ) => {
    3131                if ( 'active' === type && member.last_activity ) {
    32                     /* translators: %s: a human time diff. */
     32                    /* translators: %s: last activity timestamp (e.g. "Active 1 hour ago") */
    3333                    member.extra = sprintf( __( 'Active %s', 'buddypress' ), member.last_activity.timediff );
    3434                } else if ( 'popular' === type && member.total_friend_count ) {
Note: See TracChangeset for help on using the changeset viewer.