PluginProbe
ActivityPub / 9.0.1
ActivityPub v9.0.1
9.3.1 9.3.0 9.2.2 9.2.1 9.2.0 9.1.0 9.0.2 9.0.1 9.0.0 8.3.0 8.2.1 8.2.0 8.1.1 1.0.5 1.0.6 1.0.7 1.0.8 1.0.9 1.1.0 1.2.0 1.3.0 2.0.0 2.0.1 2.1.0 2.1.1 All 160 releases
activitypub / patterns / social-sidebar.php

social-sidebar.php in ActivityPub 9.0.1, at patterns/social-sidebar.php

41 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Fediverse Sidebar pattern.
4 *
5 * @package Activitypub
6 */
7
8 \register_block_pattern(
9 'activitypub/social-sidebar',
10 array(
11 'title' => _x( 'Fediverse Sidebar', 'Block pattern title', 'activitypub' ),
12 'categories' => array( 'activitypub' ),
13 'keywords' => array(
14 _x( 'sidebar', 'Block pattern keyword', 'activitypub' ),
15 _x( 'widget', 'Block pattern keyword', 'activitypub' ),
16 _x( 'fediverse', 'Block pattern keyword', 'activitypub' ),
17 _x( 'follow', 'Block pattern keyword', 'activitypub' ),
18 _x( 'followers', 'Block pattern keyword', 'activitypub' ),
19 ),
20 'description' => _x( 'Compact sidebar widget with follow button and followers list.', 'Block pattern description', 'activitypub' ),
21 'viewportWidth' => 400,
22 'blockTypes' => array( 'core/template-part/sidebar' ),
23 'content' => '<!-- wp:group {"layout":{"type":"constrained"}} -->
24 <div class="wp-block-group">
25 <!-- wp:heading {"level":3} -->
26 <h3 class="wp-block-heading">' . esc_html_x( 'Follow on Fediverse', 'Block pattern content', 'activitypub' ) . '</h3>
27 <!-- /wp:heading -->
28 <!-- wp:activitypub/follow-me {"selectedUser":"inherit","className":"is-style-button"} /-->
29 <!-- wp:spacer {"height":"16px"} -->
30 <div style="height:16px" aria-hidden="true" class="wp-block-spacer"></div>
31 <!-- /wp:spacer -->
32 <!-- wp:activitypub/followers {"selectedUser":"inherit","per_page":5} -->
33 <!-- wp:heading {"level":4} -->
34 <h4 class="wp-block-heading">' . esc_html_x( 'Recent Followers', 'Block pattern content', 'activitypub' ) . '</h4>
35 <!-- /wp:heading -->
36 <!-- /wp:activitypub/followers -->
37 </div>
38 <!-- /wp:group -->',
39 )
40 );
41