BuddyPress 6.0.0-beta1 is ready for testing

Hi contributors,

We’ve just published the first beta version of BuddyPress 6.0.0. Feel free to test it and help us polish our next major release 😍

https://buddypress.org/2020/03/buddypress-6-0-0-beta1/

#6-0-0, #beta

BP Dev Chat Summary: March 25th, 2020

BuddyPress Survey

@mercime has prepared 17 questions for the survey. She asked about the possible GraphQL question @espellcaste suggested to add during our previous dev-chat. If Renato has ideas about it, she will be able to insert it. About the survey publication date, @im4th suggested to add a link inside the “Hello BuddyPress 6.0.0” screen. @mercime was thinking about publishing it earlier to be able to close it before 6.0.0 release. @mercime will decide what’s the best option.

Progress about 6.0.0 release

@im4th reminded the dev-chat participants, the beta was scheduled 6 days later (at this time, today at the time I’m writing this summary!). He asked if a ticket or a feature needed an extra delay to be fixed : it wasn’t the case.

@mercime and @dcavins said they will give a test to the new BuddyPress blocks that had just been added to BuddyPress core (See #8048).

@im4th shared he still needed to work on the inclusion of the BP REST API remaining endpoints into BuddyPress 6.0.0. #7156 has been committed since.

BP REST API documentation update.

Once BuddyPress 6.0.0-beta1 will be released, we’ll need to update the BP REST API reference so that the new endpoints are documented before 6.0.0 stable release.

@mercime & @dcavins volunteered to give a hand 😍. @im4th will write some explanations about how to update the documentation on the https://developer.buddypress.org site.

6.0.0 schedule & main features

  • Schedule:
    • First beta in a few hours!
    • Final release at the end of April.
  • Main Features:
    • BP REST API remaining endpoints ✅
    • BP Blocks ✅

Next dev chat

It will happen on April 8 at 19:00 UTC (a few days before first beta 🙄) and of course in #BuddyPress. If you have ideas or questions, feel free (and we are strongly encouraging you) to comment this summary to share them!

#6-0-0

Welcome to the first BuddyPress Blocks

Hi BuddyPress contributors,

We’re very excited to share with you this announcement: after 5 months working from a separate GitHub repository on BuddyPress blocks, the 2 first and a BP Block API have been merged into BuddyPress Core. If you checkout our development version using our SVN repository or clone its Git read-only mirror, you will be able to early play with them.

One of the top features of the 6.0.0 release

These 2 BP blocks will be widely spread to our community thanks to our next major release. Some of us will be able to contribute to their fine tuning thanks to the first beta of this release which should be available in the coming days (Everyone is very welcome to do so !!).

Although BuddyPress is compatible with WordPress back to the 4.8 version, please note that you will need WordPress 5.0 to enjoy BP Blocks. If you wish to contribute using our development version (SVN or Git), you will need to install and activate the BP REST plugin (we are using it to develop the BP REST API). If you can wait until BuddyPress 6.0.0-beta1 and all the following releases, the BP REST API (just like it’s the case in the 5.0 releases) will be included so you won’t need the BP REST plugin.

About inserting BP Blocks into your posts or pages.

In 5.0.0, we’ve introduced a specific category for BuddyPress blocks into the WordPress Block Editor. This category is only appearing if there is at least one block attached to it and if you’re writing a post or a page. So most of you should haven’t noticed this category within the Block Inserter so far. Here’s what you will see once BuddyPress 6.0.0 will be released.

You just need to click on the block of your choice from the BuddyPress category of the inserter or you can also use the “/” autocompleter to add one of these blocks to your content.

Featuring a member of your community site.

That’s the goal of the BP Member block. Once added, you’ll need to start typing the name of your member from the autocomplete control to select the one you want to feature in your post or page.

By default, the block uses all the display options available. You can customize them from its settings panel.

Featuring a group of your community site.

The BP Group block is behaving just like the BP Member block. This time start typing the name of the group you wish to feature to view how it will be displayed into your content.

You will be able to adjust the appearance of the block using its settings panel.

Advanced customizations.

Post type customizations

If you wish to make the BuddyPress Block category available to a specific custom post type or restrict the post types which can use BP Blocks, you can use this filter: bp_block_category_post_types. The example below shows you how to restrict the category to posts only.

/**
 * Filters the supported post types for the BuddyPress blocks category.
 *
 * @since 1.0.0
 *
 * @param array $value The list of supported post types.
 */
function vingt_vingt_restrict_bp_blocks_to_posts( $post_types = array() ) {
    return array( 'post' );
}
add_filter( 'bp_block_category_post_types', 'vingt_vingt_restrict_bp_blocks_to_posts', 10, 1 );

Block output customizations

You can completely override the output of the BP Member and the BP Group blocks using the following filters:

Blocksfilter nameparameters
Memberbp_members_render_member_block_output1. string $output the HTML output ;

2. array $params An associative array containing these keys:
* integer $params['itemID']: the user ID ;
* string $params['avatarSize']: ‘full’ or ‘thumb’ ;
* boolean $params['displayMentionSlug']: true to display the @mention name, false otherwise ;
* boolean $params['displayActionButton']: True to display the action button, false otherwise ;
* boolean $params['displayCoverImage']: True to display the cover image, false otherwise ;
* string $params['username']: User’s username ;
* string $params['display_name']: User’s display name ;
* string $params['member_link']: User’s profile URL ;
* string $params['avatar']: User’s avatar URL ;
* string $params['cover_image']: User’s cover image URL ;
Groupbp_groups_render_group_block_output1. string $output the HTML output ;

2. BP_Groups_Group $group the group object ;

3. array $params An associative array containing these keys:
* integer $params['itemID']: the group ID ;
* string $params['avatarSize']: ‘full’ or ‘thumb’ ;
* boolean $params['displayDescription']: true to display the group description, false otherwise ;
* boolean $params['displayActionButton']: True to display the action button, false otherwise ;
* boolean $params['displayCoverImage']: True to display the cover image, false otherwise ;
* string $params['group_name']: Group’s name ;
* string $params['group_description']: Group’s description ;
* string $params['group_link']: Group’s home URL ;
* string $params['avatar']: User’s avatar URL ;
* string $params['cover_image']: User’s cover image URL ;

Disabling one or more component’s block(s)

You can disable a specific or all component’s blocks using the dynamic filter "bp_{component_id}_register_blocks". Here’s how you can disable all the Groups component blocks.

add_filter( 'bp_groups_register_blocks', '__return_empty_array' );

So far there’s only one block for this component, but we will add more in next releases! So if you want to disable a specific component’s block, here’s how you can do.

/**
 * Filters the Groups Blocks to disable the BP Group Block one.
 *
 * @since 1.0.0
 *
 * @param array $blocks The list of BP Blocks for the component.
 * @return array        The list of BP Blocks for the component.
 */
function vingt_vingt_disable_bp_group_blocks( $blocks = array() ) {
	// Use the block's ID to disable it.
	unset( $blocks['bp/group'] );

	return $blocks;
}
add_filter( 'bp_groups_register_blocks', 'vingt_vingt_disable_bp_group_blocks', 10, 1 );

Using a custom stylesheet for a BP Block

If you need to adapt the blocks appearance to match your active theme’s one, you can use the same dynamic filter ("bp_{component_id}_register_blocks") to override the style_url property to use a different CSS file. For example, here’s how you can do for the BP Member block.

/**
 * Filters the Members Blocks to override the style the BP Member one.
 *
 * @since 1.0.0
 *
 * @param array $blocks The list of BP Blocks for the component.
 * @return array        The list of BP Blocks for the component.
 */
function vingt_vingt_bp_member_block_custom_style( $blocks = array() ) {
	$blocks['bp/member']['style_url'] = get_theme_file_uri( 'css/member.css' );

	return $blocks;
}
add_filter( 'bp_members_register_blocks', 'vingt_vingt_bp_member_block_custom_style', 10, 1 );

What’s the BP Block API you’re talking about into the first lines of this post?

We will soon write a documentation page about it into our Codex. In a few words, we are using a specific function bp_register_block() that extends the WordPress one (register_block_type()) so that scripts, styles & translations registration is automagically handled.

About the next blocks?

Let’s build them together! You’re very welcome to contribute to the GitHub repository we are using to create the future of BuddyPress blocks.

#6-0-0

BP Dev Chat Agenda for March 25, 2020

Hi!

Next dev-chat is scheduled this Wednesday (March 25) at 19:00 UTC. As usual it will happen in #BuddyPress. We will discuss about :

  1. The BuddyPress 2020 survey,
  2. Progress about the 6.0.0 main features (we’ll be a few days away from first beta release 😱),
  3. Open floor.

Reminder, 6.0.0 schedule is:

  • First beta at the end of march.
  • Final release at the end of April.

If you have anything you wish to add (or remove) to this agenda or specific items related to those listed above, please leave a comment below.

#6-0-0

BP Dev Chat Summary: March 11th, 2020

BuddyPress Survey

We’ve been discussing about adding questions about 2 topics : BuddyPress integration with e-commerce plugins and BuddyPress alternatives. We found a compromise about the second topic and @mercime will add this question:

What other networking/membership plugin/software have you considered or used?

@espellcaste suggested to add a question about BP GraphQL consideration. @im4th suggested to add this feedback to the Google doc @mercime uses to work on the survey questions.

Progress about 6.0.0 release

@im4th asked about the BP REST API complete merge into BuddyPress core now all remaining endpoints are ready. @espellcaste prefers to keep maintaining it from its GitHub repository for now.

@im4th has decided to merge the BP Blocks plugin into BuddyPress core, following @johnjamesjacoby advice to reconsider his first idea about only merging “JavaScript built” blocks. A complete merge seems a better option to make sure to generate a pot file taking in account JavaScript translations. He recently added a patch on #8048 to make this happen, feedbacks welcome.

@dcavins was a bit worried he needed more than 2 weeks to end the Network invites work. If it’s the case, he will only include a portion of the code into 6.0.0.

Finally @im4th asked for help about #7729 @rayisme has been working on during. It’s about removing the legacy BuddyBar.

6.0.0 schedule & main features

  • Schedule:
    • First beta at the end of march.
    • Final release at the end of April.
  • Main Features:
    • BP REST API remaining endpoints ✅
    • BP Blocks ✅
    • Network invitation & Membership requests 😬
    • & maybe some surprises! 😬

Next dev chat

It will happen on March 25 at 19:00 UTC (a few days before first beta 🙄) and of course in #BuddyPress. If you have ideas or questions, feel free (and we are strongly encouraging you) to comment this summary to share them!

#6-0-0

BP Dev Chat Agenda for March 11, 2020

Hi!

Next dev-chat is scheduled this Wednesday (March 11) at 19:00 UTC. As usual it will happen in #BuddyPress. We will discuss about :

  1. The BuddyPress 2020 survey,
  2. Progress about the 6.0.0 main features (we’ll be 2 weeks away from first beta release 😱),
  3. Open floor.

Reminder, 6.0.0 schedule is:

  • First beta at the end of march.
  • Final release at the end of April.

If you have anything you wish to add (or remove) to this agenda or specific items related to those listed above, please leave a comment below.

#6-0-0

BP Dev Chat Summary: February 26, 2020

6.0.0 Progress

@espellcaste shared about the work he’s been doing about improving the BP REST API (activity scope, member type, group type, friendship). The last issue we need to deal with is the Blogs Avatar endpoint (2 unit tests are failing mysteriously). @im4th will give it a second look before next dev-chat.

@dcavins & @im4th didn’t find the time to work on #8139 & #8048 😬

@im4th shared about his wish to solve two tickets (#8156 & #8172) asap to inform the BuddyPress contributors early about the introduced changes. They are now solved, so please make sure to have a look at these 2 posts:

BuddyPress Survey

Open floor

@im4th asked if anyone had an opportunity to look at GitHub actions to see if this was a way to ease the release packaging process. If a BuddyPress contributor could explore it, he’d be very happy 😍

@espellcaste asked about the status #5525 : the testing site is still open for review, but @im4th already found some issues about o2 as soon as it’s not used on the home page of the site. He will work on a fix about it.

@espellcaste shared his worries about the meta ticket related to the BP GraphQL handbook creation for the developer.buddypress.org site. @im4th is confident it will be fixed soon 🤗

6.0.0 schedule & main features

  • Schedule:
    • First beta at the end of march.
    • Final release at the end of April.
  • Main Features:
    • BP REST API remaining endpoints
    • BP Blocks ✅
    • Network invitation & Membership requests
    • & maybe some surprises!

Next dev chat

It will happen on March 11 at 19:00 UTC ( ~ 2 weeks before first beta 🙄) and of course in #BuddyPress. If you have ideas or questions, feel free (and we are strongly encouraging you) to comment this summary to share them!

#6-0-0