Skip to:
Content

BuddyPress.org

Changeset 13095


Ignore:
Timestamp:
08/25/2021 09:27:43 AM (3 years ago)
Author:
imath
Message:

BP Nouveau: unbind Custom Group Boxes from WordPress widgets

Custom Group Boxes can be used by plugins using the BP Group Extension API to include content into BP Nouveau Groups single item homepages. This feature shouldn't influence the display of the feedback informing the Admin he can use WordPress widgets into Groups single item homepages.

Fixes #8557

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

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-nouveau/buddypress/groups/single/default-front.php

    r12595 r13095  
    44 *
    55 * @since 3.0.0
    6  * @version 3.2.0
     6 * @version 10.0.0
    77 */
    88?>
     
    1010<div class="group-front-page">
    1111
    12     <?php if ( ! is_active_sidebar( 'sidebar-buddypress-groups' ) || ! bp_nouveau_groups_do_group_boxes() ) : ?>
    13         <?php if ( ! is_customize_preview() && bp_current_user_can( 'bp_moderate' ) ) : ?>
     12    <?php if ( ! is_customize_preview() && bp_current_user_can( 'bp_moderate' ) && ! is_active_sidebar( 'sidebar-buddypress-groups' ) ) : ?>
     13        <div class="bp-feedback custom-homepage-info info no-icon">
     14            <strong><?php esc_html_e( 'Manage the Groups default front page', 'buddypress' ); ?></strong>
    1415
    15             <div class="bp-feedback custom-homepage-info info no-icon">
    16                 <strong><?php esc_html_e( 'Manage the Groups default front page', 'buddypress' ); ?></strong>
     16            <p>
     17            <?php
     18            printf(
     19                /* translators: 1: link to the customizer option. 2: link to the customizer widgets section. */
     20                esc_html__( 'You can set your preferences for the %1$s or add %2$s to it.', 'buddypress' ),
     21                bp_nouveau_groups_get_customizer_option_link(),
     22                bp_nouveau_groups_get_customizer_widgets_link()
     23            );
     24            ?>
     25            </p>
    1726
    18                 <p>
    19                 <?php
    20                 printf(
    21                     /* translators: 1: link to the customizer option. 2: link to the customizer widgets section. */
    22                     esc_html__( 'You can set your preferences for the %1$s or add %2$s to it.', 'buddypress' ),
    23                     bp_nouveau_groups_get_customizer_option_link(),
    24                     bp_nouveau_groups_get_customizer_widgets_link()
    25                 );
    26                 ?>
    27                 </p>
    28 
    29             </div>
    30 
    31         <?php endif; ?>
     27        </div><!-- .custom-homepage-info -->
    3228    <?php endif; ?>
    3329
  • trunk/src/bp-templates/bp-nouveau/includes/groups/functions.php

    r12908 r13095  
    44 *
    55 * @since 3.0.0
    6  * @version 7.2.1
     6 * @version 10.0.0
    77 */
    88
     
    855855        ),
    856856        'group_front_boxes' => array(
    857             'label'      => __( 'Enable widget region for group homepages. When enabled, the site admin can add widgets to group pages via the Widgets panel.', 'buddypress' ),
     857            'label'      => __( 'Enable custom boxes for group homepages. When enabled, Plugins using the BuddyPress Group Extension API can include content into these boxes.', 'buddypress' ),
    858858            'section'    => 'bp_nouveau_group_front_page',
    859859            'settings'   => 'bp_nouveau_appearance[group_front_boxes]',
Note: See TracChangeset for help on using the changeset viewer.