Skip to content

Commit 9599b39

Browse files
committed
Editor: Updated the bundled block pattern categories.
This adds descriptions to the existing pattern categories. It also updates backports the new pattern categories: banner, call to action, posts, team, testimonials, services, portfolio and contact. Fixes #57479. git-svn-id: https://develop.svn.wordpress.org/trunk@55098 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 48342a2 commit 9599b39

File tree

1 file changed

+120
-8
lines changed

1 file changed

+120
-8
lines changed

src/wp-includes/block-patterns.php

Lines changed: 120 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,126 @@ function _register_core_block_patterns_and_categories() {
3636
}
3737
}
3838

39-
register_block_pattern_category( 'buttons', array( 'label' => _x( 'Buttons', 'Block pattern category' ) ) );
40-
register_block_pattern_category( 'columns', array( 'label' => _x( 'Columns', 'Block pattern category' ) ) );
41-
register_block_pattern_category( 'featured', array( 'label' => _x( 'Featured', 'Block pattern category' ) ) );
42-
register_block_pattern_category( 'footer', array( 'label' => _x( 'Footers', 'Block pattern category' ) ) );
43-
register_block_pattern_category( 'gallery', array( 'label' => _x( 'Gallery', 'Block pattern category' ) ) );
44-
register_block_pattern_category( 'header', array( 'label' => _x( 'Headers', 'Block pattern category' ) ) );
45-
register_block_pattern_category( 'text', array( 'label' => _x( 'Text', 'Block pattern category' ) ) );
46-
register_block_pattern_category( 'query', array( 'label' => _x( 'Query', 'Block pattern category' ) ) );
39+
register_block_pattern_category( 'banner', array( 'label' => _x( 'Banners', 'Block pattern category' ) ) );
40+
register_block_pattern_category(
41+
'buttons',
42+
array(
43+
'label' => _x( 'Buttons', 'Block pattern category' ),
44+
'description' => __( 'Patterns that contain buttons and call to actions.' ),
45+
)
46+
);
47+
register_block_pattern_category(
48+
'columns',
49+
array(
50+
'label' => _x( 'Columns', 'Block pattern category' ),
51+
'description' => __( 'Multi-column patterns with more complex layouts.' ),
52+
)
53+
);
54+
register_block_pattern_category(
55+
'text',
56+
array(
57+
'label' => _x( 'Text', 'Block pattern category' ),
58+
'description' => __( 'Patterns containing mostly text.' ),
59+
)
60+
);
61+
register_block_pattern_category(
62+
'query',
63+
array(
64+
'label' => _x( 'Posts', 'Block pattern category' ),
65+
'description' => __( 'Display your latest posts in lists, grids or other layouts.' ),
66+
)
67+
);
68+
register_block_pattern_category(
69+
'featured',
70+
array(
71+
'label' => _x( 'Featured', 'Block pattern category' ),
72+
'description' => __( 'A set of high quality curated patterns.' ),
73+
)
74+
);
75+
register_block_pattern_category(
76+
'call-to-action',
77+
array(
78+
'label' => _x( 'Call to Action', 'Block pattern category' ),
79+
'description' => __( 'Sections whose purpose is to trigger a specific action.' ),
80+
)
81+
);
82+
register_block_pattern_category(
83+
'team',
84+
array(
85+
'label' => _x( 'Team', 'Block pattern category' ),
86+
'description' => __( 'A variety of designs to display your team members.' ),
87+
)
88+
);
89+
register_block_pattern_category(
90+
'testimonials',
91+
array(
92+
'label' => _x( 'Testimonials', 'Block pattern category' ),
93+
'description' => __( 'Share reviews and feedback about your brand/business.' ),
94+
)
95+
);
96+
register_block_pattern_category(
97+
'services',
98+
array(
99+
'label' => _x( 'Services', 'Block pattern category' ),
100+
'description' => __( 'Briefly describe what your business does and how you can help.' ),
101+
)
102+
);
103+
register_block_pattern_category(
104+
'contact',
105+
array(
106+
'label' => _x( 'Contact', 'Block pattern category' ),
107+
'description' => __( 'Display your contact information.' ),
108+
)
109+
);
110+
register_block_pattern_category(
111+
'about',
112+
array(
113+
'label' => _x( 'About', 'Block pattern category' ),
114+
'description' => __( 'Introduce yourself.' ),
115+
)
116+
);
117+
register_block_pattern_category(
118+
'portfolio',
119+
array(
120+
'label' => _x( 'Portfolio', 'Block pattern category' ),
121+
'description' => __( 'Showcase your latest work.' ),
122+
)
123+
);
124+
register_block_pattern_category(
125+
'gallery',
126+
array(
127+
'label' => _x( 'Gallery', 'Block pattern category' ),
128+
'description' => __( 'Different layouts for displaying images.' ),
129+
)
130+
);
131+
register_block_pattern_category(
132+
'media',
133+
array(
134+
'label' => _x( 'Media', 'Block pattern category' ),
135+
'description' => __( 'Different layouts containing video or audio.' ),
136+
)
137+
);
138+
register_block_pattern_category(
139+
'posts',
140+
array(
141+
'label' => _x( 'Posts', 'Block pattern category' ),
142+
'description' => __( 'Display your latest posts in lists, grids or other layouts.' ),
143+
)
144+
);
145+
register_block_pattern_category(
146+
'footer',
147+
array(
148+
'label' => _x( 'Footers', 'Block pattern category' ),
149+
'description' => __( 'A variety of footer designs displaying information and site navigation.' ),
150+
)
151+
);
152+
register_block_pattern_category(
153+
'header',
154+
array(
155+
'label' => _x( 'Headers', 'Block pattern category' ),
156+
'description' => __( 'A variety of header designs displaying your site title and navigation.' ),
157+
)
158+
);
47159
}
48160

49161
/**

0 commit comments

Comments
 (0)