- Timestamp:
- 05/21/2018 01:00:36 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-templates/bp-nouveau/includes/groups/functions.php
r12082 r12104 25 25 } 26 26 27 $message = '<div class=" bp-feedback ' . $type . '"><span class="bp-icon" aria-hidden="true"></span><p>' . $message. '</p></div>';27 $message = '<div class=" ' . esc_attr( "bp-feedback {$type}" ) . '"><span class="bp-icon" aria-hidden="true"></span><p>' . esc_html( $message ) . '</p></div>'; 28 28 29 29 return $message; … … 150 150 'loading' => __( 'Loading members. Please wait.', 'buddypress' ), 151 151 'invites_form' => __( 'Use the "Send" button to send your invite or the "Cancel" button to abort.', 'buddypress' ), 152 'invites_form_reset' => __( ' Invites cleared. Please use one of the available tabs to select members to invite.', 'buddypress' ),153 'invites_sending' => __( 'Sending the invites. Please wait.', 'buddypress' ),154 'removeUserInvite' => __( ' Disinvite%s', 'buddypress' ),152 'invites_form_reset' => __( 'Group invitations cleared. Please use one of the available tabs to select members to invite.', 'buddypress' ), 153 'invites_sending' => __( 'Sending group invitations. Please wait.', 'buddypress' ), 154 'removeUserInvite' => __( 'Cancel invitation %s', 'buddypress' ), 155 155 'group_id' => ! bp_get_current_group_id() ? bp_get_new_group_id() : bp_get_current_group_id(), 156 156 'is_group_create' => bp_is_group_create(), … … 295 295 /** 296 296 * @since 3.0.0 297 * @todo I don't see any reason why to restrict group invites to friends..298 297 */ 299 298 function bp_nouveau_group_invites_create_steps( $steps = array() ) { 300 299 if ( bp_is_active( 'friends' ) && isset( $steps['group-invites'] ) ) { 301 300 // Simply change the name 302 $steps['group-invites']['name'] = _x( 'Invite', 'Group screen nav', 'buddypress' );301 $steps['group-invites']['name'] = _x( 'Invite', 'Group invitations menu title', 'buddypress' ); 303 302 return $steps; 304 303 } … … 306 305 // Add the create step if friends component is not active 307 306 $steps['group-invites'] = array( 308 'name' => _x( 'Invite', 'Group screen nav', 'buddypress' ),307 'name' => _x( 'Invite', 'Group invitations menu title', 'buddypress' ), 309 308 'position' => 30, 310 309 ); … … 326 325 327 326 $bp->groups->nav->edit_nav( 328 array( 'name' => _x( 'Invite', ' My Group screen nav', 'buddypress' ) ),327 array( 'name' => _x( 'Invite', 'Group invitations menu title', 'buddypress' ) ), 329 328 'send-invites', 330 329 bp_get_current_group_slug() … … 337 336 338 337 bp_core_new_subnav_item( array( 339 'name' => _x( 'Invite', ' My Group screen nav', 'buddypress' ),338 'name' => _x( 'Invite', 'Group invitations menu title', 'buddypress' ), 340 339 'slug' => 'send-invites', 341 340 'parent_url' => $group_link, … … 395 394 'avatar_url' => $item_avatar_url, 396 395 'object_type' => 'group', 397 'is_public' => 'public' === $item->status,396 'is_public' => ( 'public' === $item->status ), 398 397 ); 399 398 } … … 413 412 414 413 bp_core_new_subnav_item( array( 415 'name' => _x( 'Group Invites', ' My Group Invites settings screen nav', 'buddypress' ),414 'name' => _x( 'Group Invites', 'Group invitations main menu title', 'buddypress' ), 416 415 'slug' => 'invites', 417 416 'parent_url' => trailingslashit( $user_domain . $slug ), … … 441 440 'parent' => 'my-account-' . buddypress()->settings->id, 442 441 'id' => 'my-account-' . buddypress()->settings->id . '-invites', 443 'title' => _x( 'Group Invites', ' My Account Settings sub nav', 'buddypress' ),442 'title' => _x( 'Group Invites', 'Group invitations main menu title', 'buddypress' ), 444 443 'href' => trailingslashit( $settings_link . 'invites/' ), 445 444 ); … … 694 693 'panel' => 'bp_nouveau_panel', 695 694 'priority' => 40, 696 'description' => __( 'Customize the navigation menu for groups. See your changes by navigating to a group in the live-preview window. .', 'buddypress' ),695 'description' => __( 'Customize the navigation menu for groups. See your changes by navigating to a group in the live-preview window.', 'buddypress' ), 697 696 ), 698 697 ) ); … … 801 800 ), 802 801 'group_front_boxes' => array( 803 'label' => __( 'Enable widget region for group homepages. (When enabled, the site admin can add widgets to group pages via the Widgets panel.)', 'buddypress' ),802 'label' => __( 'Enable widget region for group homepages. When enabled, the site admin can add widgets to group pages via the Widgets panel.', 'buddypress' ), 804 803 'section' => 'bp_nouveau_group_front_page', 805 804 'settings' => 'bp_nouveau_appearance[group_front_boxes]', … … 807 806 ), 808 807 'group_front_description' => array( 809 'label' => __( 'Display the group description in the body of the group\'s front page.', 'buddypress' ),808 'label' => __( "Display the group description in the body of the group's front page.", 'buddypress' ), 810 809 'section' => 'bp_nouveau_group_front_page', 811 810 'settings' => 'bp_nouveau_appearance[group_front_description]', … … 819 818 ), 820 819 'group_nav_tabs' => array( 821 'label' => __( 'Use tab styling for primary nav .', 'buddypress' ),820 'label' => __( 'Use tab styling for primary navigation.', 'buddypress' ), 822 821 'section' => 'bp_nouveau_group_primary_nav', 823 822 'settings' => 'bp_nouveau_appearance[group_nav_tabs]', … … 825 824 ), 826 825 'group_subnav_tabs' => array( 827 'label' => __( 'Use tab styling for secondary nav .', 'buddypress' ),826 'label' => __( 'Use tab styling for secondary navigation.', 'buddypress' ), 828 827 'section' => 'bp_nouveau_group_primary_nav', 829 828 'settings' => 'bp_nouveau_appearance[group_subnav_tabs]', … … 844 843 ), 845 844 'groups_layout' => array( 846 'label' => _ _( 'Groups', 'buddypress' ),845 'label' => _x( 'Groups', 'Customizer control label', 'buddypress' ), 847 846 'section' => 'bp_nouveau_loops_layout', 848 847 'settings' => 'bp_nouveau_appearance[groups_layout]', … … 955 954 // Loop in the hierarchy to fill it for the requested template part 956 955 foreach ( $bp_nouveau->groups->current_group_hierarchy as $part ) { 957 $templates[] = sprintf( $part, $template);956 $templates[] = sprintf( $part, sanitize_file_name( $template ) ); 958 957 } 959 958 … … 1010 1009 */ 1011 1010 function bp_nouveau_group_is_home_widgets() { 1012 return true === bp_nouveau()->groups->is_group_home_sidebar;1011 return ( true === bp_nouveau()->groups->is_group_home_sidebar ); 1013 1012 } 1014 1013 … … 1198 1197 array( 1199 1198 'id' => 'member_promoted_to_admin', 1200 'label' => __( 'Group Admin promotions', 'buddypress' ),1199 'label' => __( 'Group Administrator promotions', 'buddypress' ), 1201 1200 'position' => 85, 1202 1201 ), … … 1208 1207 array( 1209 1208 'id' => 'group_invite', 1210 'label' => __( 'Group invit es', 'buddypress' ),1209 'label' => __( 'Group invitations', 'buddypress' ), 1211 1210 'position' => 105, 1212 1211 ),
Note: See TracChangeset
for help on using the changeset viewer.