Internationalization improvements in 6.7

Various internationalization (i18n) improvements are in WordPress 6.7, and this developers note focuses on these.

Determining whether a translationtranslation The process (or result) of changing text, words, and display formatting to support another language. Also see localization, internationalization. exists

Sometimes it can be useful to know whether a translation already exists for in memory without having to first load the translation for the given text domain. The new has_translation() function allows for exactly that.

See #52696 / [59029] for more details.

Sending emails in the adminadmin (and super admin)’s localeLocale A locale is a combination of language and regional dialect. Usually locales correspond to countries, as is the case with Portuguese (Portugal) and Portuguese (Brazil). Other examples of locales include Canadian English and U.S. English.

Back in version 4.7, WordPress added the ability for users to set their preferred locale. When sending emails to a user, they are always sent in that locale, and everyone else receives the email in the site’s locale.

Now, WordPress 6.7 is going a step further: every time an email is sent to the administrator email address (admin_email), WordPress checks if a user with the same email address exists. If so, the email is sent in that user’s locale.

See #61518 / [59128] for more details.

Warnings if translations are loaded too early

WordPress now warns developers if they are loading translations too early in a pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party or theme, before the current user is known. Existing functions like load_plugin_textdomain() and load_theme_textdomain() were updated to defer the actual loading to the existing just-in-time translation logic in coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress.. This reduces the likelihood of triggering the warning, and even improves performance in some situations by avoiding loading translations if they are not needed on a given page.

Reminder: if your plugin or theme is hosted on WordPress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/ and is still using load_*_textdomain(), you can remove this call. Since WordPress 4.6, plugins and themes no longer need load_plugin_textdomain() or load_theme_textdomain(). WordPress automatically loads the translations for you when needed. If you still support older WordPress versions or do not host your plugin/theme on WordPress.org, move the function call to a later hook such as init.

When attempting to load translations before after_setup_theme or init, WordPress tries to load the current user earlier than usual, without giving other plugins a chance to potentially hook into the process. It also prevents any plugins from filtering translation calls, e.g. for switching the locale or file location. Hence the addition of this warning to call out this unexpected behavior.

See #44937, [59127], and [59157] for more details.

Your plugin might be _doing_it_wrong() if you for example directly call get_plugin_data() (which attempts to load translations by default) or __() without waiting for the init hook. Here is a common example that was found in an actual plugin that was fixed:

/**
 * Plugin Name: Awesome Plugin
 */

function myplugin_get_version() {
	require_once ABSPATH . 'wp-admin/includes/plugin.php';
	// Prevent early translation call by setting $translate to false.
	$plugin_data = get_plugin_data( __FILE__, false, /* $translate */ false );
	return $plugin_data['Version'];
}

define( 'MYPLUGIN_VERSION', myplugin_get_version() );

If you do not explicitly set $translate set to false when calling get_plugin_data(), the function translates the plugin metadata by default. Since this plugin just needs the version number, there is no need for translating any of the other fields.

Another example:

/**
 * Plugin Name: Awesome Plugin
 */

class My_Awesome_Plugin {
	public $name;
	public function __construct() {
		// This triggers just-in-time translation loading
		$this->name = __( 'My Awesome Plugin', 'my-awesome-plugin' );

		// ... do something
	}
}

// This immediately instantiates the class, way before `init`.
$myplugin = new My_Awesome_Plugin();

Here, a class is immediately instantiated in the main plugin file, and code within the class constructor uses a translation function. This can be avoided by deferring the class instantiation until after init, or deferring the translation call until later when it is actually needed.

If your plugin is affected by this warning, you can use code like follows to find out the code path that triggers it:

add_action(
	'doing_it_wrong_run',
	static function ( $function_name ) {
		if ( '_load_textdomain_just_in_time' === $function_name ) {
			debug_print_backtrace();
		}
	}
);

Developer tools such as Query Monitor are also helpful in situations like this.


Props to @ocean90, @fabiankaegy for review.

#6-7, #dev-notes, #dev-notes-6-7, #i18n

WordPress 6.8 Call for Volunteers

As a follow-up to the release calendar proposal for 2025, let’s gather interest in being part of the release squad for the next major releasemajor release A release, identified by the first two numbers (3.6), which is the focus of a full release cycle and feature development. WordPress uses decimaling count for major release versions, so 2.8, 2.9, 3.0, and 3.1 are sequential and comparable in scope., WordPress 6.8.

Proposed WordPress 6.8 tentative schedule

Based on that calendar proposal for next year, the WordPress 6.8 tentative schedule is as follows:

MilestoneDate
Alpha (trunktrunk A directory in Subversion containing the latest development code in preparation for the next major release cycle. If you are running "trunk", then you are on the latest revision. open for 6.8 release)October 22, 2024
BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 1March 4 2025
Beta 2March 11, 2025
Beta 3March 18, 2025
Release Candidaterelease candidate One of the final stages in the version release cycle, this version signals the potential to be a final release to the public. Also see alpha (beta). 1March 25, 2025
Release Candidate 2April 1, 2025
Release Candidate 3April 8, 2025
Dry RunApril 14, 2025
WordPress 6.8 General ReleaseApril 15, 2025

According to the schedule above and the GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ release cadence, WordPress 6.8 would include up to Gutenberg 20.4 for a maximum of 11 releases, depending on the end-of-year Gutenberg release adjustments (according to an unaltered schedule, Gutenberg 20.0 RCrelease candidate One of the final stages in the version release cycle, this version signals the potential to be a final release to the public. Also see alpha (beta). and stable would land on December 25th and January 1st, respectively).

Release Leads call for volunteers

Following the release squad structure from the last release, except for the default theme role, as WordPress 6.8 won’t deliver a new default theme, these are the minimum roles that need filling:

  • Release Coordinator(s)
  • CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. Tech Lead(s)
  • Editor Tech Lead(s)
  • Core Triagetriage The act of evaluating and sorting bug reports, in order to decide priority, severity, and other factors. Lead(s)
  • Editor Triage Lead(s)
  • Documentation Lead(s)
  • Test Lead(s)
  • Design Lead(s)
  • Performance Lead(s)

It’s worth noting that WordPress 6.7 experimented with not having an explicit Marketing Lead; depending on feedback from the last release, the 6.8 squad might add back that role or other missing ones. As usual, the Release LeadRelease Lead The community member ultimately responsible for the Release. role will be filled by project leadership. Check the Core Handbook to learn more about the release team’s roles and responsibilities.

All release decisions will ultimately be this release team’s to make and communicate, while gathering input from the community, including finalizing the release schedule.

If you are interested in participating in WordPress 6.8’s release squad as a lead, please show interest in the comments below, clearly specifying your desired role, by December 6th.


Thanks to @aaroncampbell and @jeffpaul for reviewing this post.

#planning #6-8

What’s new in Gutenberg 19.7? (20 November)

“What’s new in GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/…” posts (labeled with the #gutenberg-new tag) are posted following every Gutenberg release on a biweekly basis, showcasing new features included in each release. As a reminder, here’s an overview of different ways to keep up with Gutenberg and the Editor.



Gutenberg 19.7 has been released and is available for download!

  1. Global Styles available on the main site editor sidebar
  2. Swifter hiding & showing the template
  3. Set image blocks as featured image
  4. Changelog
  5. First-time contributors
  6. Contributors

Global Styles available on the main site editor sidebarSidebar A sidebar in WordPress is referred to a widget-ready area used by WordPress themes to display information that is not a part of the main content. It is not always a vertical column on the side. It can be a horizontal rectangle below or above the content area, footer, header, or any where in the theme.

The site editor sidebar is getting increasingly powerful, serving as the entry point to manage all-things your site. Up until this version, the styles panel offered limited style settings, focusing on style variations, color palettes, and typographies. Gutenberg 19.7 changes this by introducing a full-fledged Global Styles panel in its place, giving users site-wide granular control on styles at the top level.

Swifter hiding & showing the template

Switching between editing your site templates and content pages should be as smooth and seamless as possible; sometimes, you need to focus on the post content and hide the rest of the template. This was previously possible in the post settings, but now it is much easier thanks to the `Show template` toggle directly on the preview dropdown in the top toolbar.

Featured images offer a nice touch in external previews, making them more attractive to potential readers. However, it can be easy to forget to set one! To help set featured images more easily, image blocks now offer a dropdown action to directly set them as the featured image of the post or page containing the blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience..

Continue reading

#gutenberg, #gutenberg-new

Proposal: Major releases for 2025

With WordPress 6.7 out the door, it’s time to plan for next year’s releases. The following dates try to account for flagship events and major international holidays:

  • 6.8 – BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 1 on March 4, stable release on April 15 (Beta 1 ten days after WC Asia)
  • 6.9 – Beta 1 on June 24, stable release on August 5 (WCEU in early June)
  • 7.0 – Beta 1 on  September 30, stable release on November 11 (no flagship events nearby)

The release cadence is similar to past years, with a longer initial release cycle, including the end-of-year festivities and ~4-month ones. Please leave your feedback below or through a SlackSlack Slack is a Collaborative Group Chat Platform https://slack.com/. The WordPress community has its own Slack Channel at https://make.wordpress.org/chat/. DM by November 29.

Although the 6.8 dates aren’t final yet, they are close to final enough to let contributors know their availability around that time. If you want to participate in the WordPress 6.8 release, stay tuned for an upcoming post with the call for volunteers.

Props to @jeffpaul for reviewing the proposed dates and this post.

#planning

#6-8, #6-9, #7-0

Introducing Twenty Twenty-Five

The WordPress 6.7 release will feature a new default theme: Twenty Twenty-Five.

Four public domain film photographs: one showing a historical building, the other a close up of flowers, the other shows birds and the other an African woman. Below it is written Twenty Twenty-Five.

Concept

While ideating Twenty Twenty-Five, one recurring idea was that simple things should be intuitive while complex things should be possible. This concept of simplicity and complexity leads to a reliable foundation for extending a default WordPress experience to make it yours.

Twenty Twenty-Five embodies ultimate flexibility and adaptability, showcasing the many ways WordPress enables people to tell their stories with many patterns and styles to choose from. The glimpses of natural beauty and ancestry woven into the theme evoke ideas of impermanence, the passage of time, and continuous evolution.

The demo content imagery, all from the Public Domain, carries a poetic, universal, and ubiquitous tone that complements the coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. concept. There was an opportunity to visually lean into a positive tone to bring softness, lightness, and inspiration through its aesthetic.

A collage kind of composition showing many of the photographs used in the 2025 default theme.

Patterns

Structurally, Twenty Twenty-Five offers a robust set of patterns, promoting interoperability and enabling users to compose intentional pages quickly. A broad range of patterns was designed for categories such as services, about, landing pages, products, calls to actions, events, and others.

A broad range of patterns designed for the 2025 theme in categories like services, about, landing pages, products, calls to actions, events, etc.

Styles

Given the theme’s global use, high-quality and comprehensive fonts that support multiple languages have been considered from the first conceptual steps of the design. Furthermore, we’re refining a set of diverse color palettes to be bundled within the theme as style variations.

Eight different color palettes that were designed for the 2025 default theme.
Eight different typography pairings that were designed for the 2025 default theme.
Showing nine examples applied to different templates of style variations designed for the 2025 theme.

Templates

Twenty Twenty-Five also features a versatile set of blogblog (versus network, site) templates: text-centric blogs with sidebars, photo blogs that highlight featured images, and more complex blogs with diverse content. Twenty Twenty-Five will be fully compatible with the Site Editor and will use many of the new design tools like the Grid blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. and Pattern/Section Styles.

Personal Blog (Default)

In keeping with the idea of simplicity, the personal blog tendency is to lean on a default template that just works, whether you want to write a post with a title and featured imageFeatured image A featured image is the main image used on your blog archive page and is pulled when the post or page is shared on social media. The image can be used to display in widget areas on your site or in a summary list of posts. or not, and showing all the post’s content out-of-the-box, instead of just excerpts.

Two mockups: the one on the left shows blog posts with an image, a post title and the full content of the post and the one on the right shows a single post.

Photo Blog (Alternative)

The alternative “photo blog” templates tailored primarily for photography or portfolios lean on an image-heavy approach, with interesting layouts that can be used for a variety of purposes.

Two mockups: the one on the left shows just the featured image of blog posts and the one on the right shows a single post with a full width image.

Complex Blog (Alternative)

Lastly, the set of complex blog alternative templates would be more suitable for websites with greater complexity in content. Some of these templates, with more variety in type scales and more opinionated designs can also appeal to different audiences.

Two mockups: the one on the left shows a 3 column grid with blog posts containing featured images and post titles followed by a 2 column grid, and the one on the right shows a single post with a big left-aligned title, post meta and a wide image, followed by post content with a sidebar on the right.

Development

As part of the 6.7 release, Carolina Nymark (@poena) and Juanfra Aldasoro (@juanfra) are leading development while Beatriz Fialho (@beafialho) is leading design. If you’re interested in contributing, make sure you’re following this blog; we look forward to your involvement and support throughout the process. 

The Figma file is the design source of truth. Comments in the main file are open, and anyone should feel free to duplicate the Figma to their drafts and remix. Both of these actions are free, whereas every edit access is paid and therefore reserved.

Theme development will happen on the Twenty Twenty-Five GitHub repository. You can contribute by submitting and reviewing pull requests or opening new issues and, as usual, once the theme is stable, it will be merged into Core and the GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ repository will be archived.

Starting on Wednesday August 21st at 3:00 PM UTC , there will be weekly Slack meetings in #core-themes to coordinate development of the theme. Agenda notes will be posted before meetings and summaries posted after the meeting.

Learn more

For information about previous default themes, read the following posts:

Here are a few resources if you’re interested in learning more about Block Themes and the Site Editor:

+make.wordpress.org/themes/

Props @richtabor, @karmatosed, @priethor, @poena, @cbringmann and @joen for helping co-create this post and to @luminuu for proofreading it.

#6-7, #bundled-theme, #twenty-twenty-five

New Plugin Template Registration API in WordPress 6.7

Since the introduction of blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. themes, theme authors have been able to create custom block templates. However, this possibility was limited to themes, leaving plugins without a straightforward way to register their own templates. To achieve similar functionality, plugins had to resort to complex methods, including hooking into multiple PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 7.4 or higher filters, manually creating WP_Block_Template objects, and replicating internal WordPress logic.

WordPress 6.7 introduces a new APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. that will significantly simplify the process for plugins to register their own block templates. To enable this, two new functions have been introduced: register_block_template() for registering a block template and unregister_block_template() for unregistering it.

register_block_template( string $template_name, $args = array() ) accepts two parameters, that define how the template is registered:

  • $template_name: The name of the template in the form of plugin_uri//template_name (note that this requires a double //).
  • $args: An array of arguments for defining the template:
    • title: An internationalized title for the template.
    • description: An internationalized description of the template.
    • content: The default content (block markup) for the template when rendered in the editor or on the front end.
    • post_types: An array of post type slugs to make available to users as per-post custom templates.

For example, a pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party can register a template with the following snippet:


register_block_template( 'devblog-plugin-templates//my-template', [
	'title'   	=> __( 'Example', 'devblog-plugin-templates' ),
	'description' => __( 'An example block template from a plugin.', 'devblog-plugin-templates' ),
	'content' 	=> '
    	<!-- wp:template-part {"slug":"header","area":"header","tagName":"header"} /-->
    	<!-- wp:group {"tagName":"main"} -->
    	<main class="wp-block-group">
        	<!-- wp:group {"layout":{"type":"constrained"}} -->
        	<div class="wp-block-group">
            	<!-- wp:paragraph -->
            	<p>This is a plugin-registered template.</p>
            	<!-- /wp:paragraph -->
        	</div>
        	<!-- /wp:group -->
    	</main>
    	<!-- /wp:group -->
    	<!-- wp:template-part {"slug":"footer","area":"footer","tagName":"footer"} /-->'
] );

Once registered, the template will appear alongside all other templates in the Site Editor:

And, if needed, could later unregister it with:

unregister_block_template( 'devblog-plugin-templates//my-template' )

Plugins can also override templates from the WordPress template hierarchy, such as the archive page of a custom post typeCustom Post Type WordPress can hold and display many different types of content. A single item of such a content is generally called a post, although post is also a specific post type. Custom Post Types gives your site the ability to have templated posts, to simplify the concept. or a specific author page.

Theme templates take priority over plugin-registered templates, allowing themes to override specific plugin templates just as they can with WordPress templates.

Currently, this API is limited to block templates and does not allow the registration of block template parts.

You can read more about this new feature in the following links:

Props to @aljullu for writing this dev notedev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase.. And thanks to @fabiankaegy for reviewing

#6-7, #dev-notes, #dev-notes-6-7

Update on Phase 3: Collaboration efforts

Over the last year, Phase 3 of the GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ roadmap has begun to take form and with it comes a need for an update around what’s been done, how to follow along, and what to expect going forward. This post seeks to provide answers at a high level view of these questions. As a reminder Phase 3 is centered around fostering seamless collaboration, tying together the user experience, and streamlining the content management flows to improve the way creators and teams work together within WordPress. As work progresses, feedback is needed and welcomed to ensure broader adoption.

Real-time collaboration

Over the last few months, Kevin Jahns, the author of Yjs, a popular framework for building collaborative applications has been sponsored by Automattic to work on real-time collaboration, after an initial experiment landed. He kicked off his efforts with some research and dialogue in this discussion issue. More recently, he’s pulled together some prototypes ahead of sharing a full proposal for how to proceed. Right now, consider this work as being in a strong experimental stage without a final approach. The next step is to get the initial approach into a PR for folks to give feedback on and discuss openly. 

Below is a demo showing syncing content only relying on HTTPHTTP HTTP is an acronym for Hyper Text Transfer Protocol. HTTP is the underlying protocol used by the World Wide Web and this protocol defines how messages are formatted and transmitted, and what actions Web servers and browsers should take in response to various commands. APIs with the autosave interval set to 3 seconds. Because it relies on HTTP APIs, this demo would work on all WordPress instances:

Going a step further, you can see more demos in a recent update including adding y-webrtc into the experience to show how real time collaboration would work for users who can establish a peer-to-peer WebRTC connection.

Follow along in this dedicated GitHub issue and/or in the #feature-realtime-collaboration slackSlack Slack is a Collaborative Group Chat Platform https://slack.com/. The WordPress community has its own Slack Channel at https://make.wordpress.org/chat/. channel.

Async collaboration: In-line comments

An initial experiment for block-level inline comments landed with Gutenberg 19.6, breaking ground on the first of many async collaboration upgrades. At this point, another iteration on this initial feature is already planned and underway to refine the current experience further. If you’d like to help test and shape the feature further, stay tuned for a dedicated call for testing or start testing today with this WordPress Playground instance and open issues in the Gutenberg GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ repository. The aim is to get early feedback and quickly iterate in order to land this new feature in an upcoming major WordPress release. Below is a look at the near term design slated to be shipped next with visuals for adding a comment, leaving a comment, toggling to see resolved comments, and the resulting view when looking at resolved comments:

Follow along in this dedicated GitHub issue

Adminadmin (and super admin) redesign: DataView & DataForm

DataViews is the foundational component of the initial overall admin design efforts. By design, these views are being built out only in the Site Editor, with a few efforts branching out including an experiment for a new, separate Posts experience using Data Views and an early Media Library powered by Data Views proof of concept.  

As a next step of the initial development of DataViews, the more recent DataForm API was later introduced in Gutenberg 18.8 with the aim to reduce expected duplication to create forms in Data Views. Work has continued progressively from there with DataViews and DataForm components influencing each other’s development. You can view each in their respective Storybook views: DataViews and DataForm.

Both of these components have been created with extensibility at the heart of everything being built! For now, pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party and agency developers can already start using the DataViews component for their WordPress customizations with two different Developer Blogblog (versus network, site) tutorials to get you started: Using Data Views to display and interact with data in plugins and Actions from Data Views: Adding images to the Media Library. If you want to go on a deeper dive, watch a recent hallway hangout that goes through both of these components with folks actively working on them. Expect a continual focus on extensibility as these components evolve. Below is a look at how DataViews comes together with the DataForm work with an easy option to quick edit within one’s pages:

Follow along in this dedicated DataViews component issue and this DataForm component issue. For early design work in this area and beyond, check out the biweekly design updates.


Thanks to @priethor @youknowriad @4thhubbard @matveb for reviewing this post and for @joen and @jameskoster for the design assets.

#gutenberg, #phase-3

WordPress 6.7.1 Release Schedule

Since WordPress 6.7 was released last week, contributors have kept a close eye on incoming reports to the WordPress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/ Support Forums, TracTrac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress., and the GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ repository on GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/. Though volume has not been meaningfully higher than normal after a major releasemajor release A release, identified by the first two numbers (3.6), which is the focus of a full release cycle and feature development. WordPress uses decimaling count for major release versions, so 2.8, 2.9, 3.0, and 3.1 are sequential and comparable in scope., most reports are describing a small set of issues that should be addressed expeditiously.

Schedule

WordPress 6.7.1 will be targeted for release on Thursday, November 21, 2024 with a very specific focus of only fixing bugs there were introduced in the 6.7 release. The goal is to deliver a small handful of high-impact bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. fixes for added stability prior to the busy online commerce holiday week consisting of Black Friday, Cyber Monday, and Giving Tuesday.

The release will be lead by myself (@desrosj) and @cbravobernal. If you’re interested in volunteering, please comment below or drop a message in the #6-7-release-squad channel in SlackSlack Slack is a Collaborative Group Chat Platform https://slack.com/. The WordPress community has its own Slack Channel at https://make.wordpress.org/chat/..

Date/TimeEvent
Tuesday, November 19, 2024Continued triagetriage The act of evaluating and sorting bug reports, in order to decide priority, severity, and other factors., testing, and committing/backporting fixes.
Wednesday, November 20, 2024 at 13:00PM UTCGutenberg package updates released/pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party update released (if necessary).
Wednesday, November 20, 2024 at 17:00PM UTCWordPress 6.7.1 RC1
Thursday, November 21, 2024 at 13:30PM UTCWordPress 6.7.1 General Release

Targeted Fixes

The following are the high priority items that cumulatively make a fast-follow release necessary:

  • sizes=auto causing images to show smaller than they should (#62413)
  • Translations not being applied properly (#62337)
  • Patterns without categories break the editor when browsing uncategorized patterns (GB-66944/GB-66888)
  • Zoom in doesn’t focus on the right area of the screen based on selected item (a few PRs issues for this)
  • Zoom out button goes missing when plugins register toolbar items (GB-66884)

The following are bugs that should be included if ready, but as understood now are not affecting as many people or are less problematic:

  • Using the Upload button in image-based blocks in Safari unexpectedly converts images to HEIC with a temporary file name (#62447)
  • CategoryCategory The 'category' taxonomy lets you group posts / content together that share a common bond. Categories are pre-defined and broad ranging. management in the Classic Editor is broken (#62440)
  • CSSCSS Cascading Style Sheets. targets changed on the login screen affecting custom logos (#62410)

Finally, the following are minor bug fixes introduced in 6.7 that should also be considered:

  • Horizontal scroll bar in the CustomizerCustomizer Tool built into WordPress core that hooks into most modern themes. You can use it to preview and modify many of your site’s appearance settings. (#62313)
  • Undefined key warning in wp_salt() (#62424)
  • Untranslatable strings in nav-menu.js (#62402)

There is currently only one ticketticket Created for both bug reports and feature development on the bug tracker. that does not represent a bug introduced during 6.7 being considered: #62331. This is a pretty significant performance problem for sites using GD for image editing that should be considered. It was only discovered 2 weeks ago, too late to be considered for 6.7.

A full list of tickets being considered for 6.7.x minor releases can be found on Trac and the WordPress 6.7.x project board on GitHub.

Props @joemcgill for review.

Agenda, Dev Chat, Nov 20, 2024

Notice: This week the Dev Chat time will be changing back to 20:00 UTC.

The next WordPress Developers Chat will take place on Wednesday at 20:00 UTC in the core channel on Make WordPress Slack. Please note that this has changed to the original time which is later than the previous Dev Chats during the 6.7 release.

The live meeting will focus on the discussion for upcoming releases, and have an open floor section.

Additional items will be referred to in the various curated agenda sections below. If you have ticketticket Created for both bug reports and feature development on the bug tracker. requests for help, please continue to post details in the comments section at the end of this agenda.

Announcements

WordPress 6.7 “Rollins” was released on November 12, 2024. Thank you and congratulations to everyone who participated in this release!

Forthcoming releases

Next major releasemajor release A release, identified by the first two numbers (3.6), which is the focus of a full release cycle and feature development. WordPress uses decimaling count for major release versions, so 2.8, 2.9, 3.0, and 3.1 are sequential and comparable in scope.: 6.8

We are currently in the WordPress 6.8 release cycle.

Next maintenance release: 6.7.1

We are discussing releasing 6.7.1 for this week, with @desrosj offering to lead the release.

Next GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ release: 19.7

The next Gutenberg release will be 19.7, scheduled for November 20. It will include the following issues.

Discussions

The discussion section of the agenda is to provide a place to discuss important topics affecting the upcoming release or larger initiatives that impact the CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. Team.

This week, we can discuss the 6.7.1 maintenance release, including which issues should be included (trac milestone, Editor board) and who is available to help as part of the release squad. It’s worth noting that GB 19.6.3 was released on Nov 18, which may or may not mitigate #62413 (see thread)

If you want to nominate a topic for discussion, please leave a comment on this agenda with a summary of the topic, any relevant links that will help people get context for the discussion, and what kind of feedback you are looking for from others participating in the discussion.

Highlighted Posts

Editor updates

You can keep up to date with the major Editor features that are currently in progress by viewing these Iteration issues.

Open floor

Any topic can be raised for discussion in the comments, as well as requests for assistance on tickets. Tickets in the milestone for the next major or maintenance release will be prioritized.

Please include details of tickets / PRs and the links in the comments, and if you intend to be available during the meeting for discussion or if you will be async.

Thanks @joemcgill for reviewing

#6-7-1, #6-8, #agenda, #dev-chat

Block Bindings: Improvements to the Editor Experience in 6.7

WordPress 6.7 introduces various improvements to the BlockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. Bindings APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. and the built-in post metaMeta Meta is a term that refers to the inside workings of a group. For us, this is the team that works on internal WordPress sites like WordCamp Central and Make WordPress. source, including a default UIUI User interface and the beginnings of a public editor API.

For an introduction to Block Bindings, first introduced in WordPress 6.5, see the prior dev note.

New Block Bindings UI

Compatible blocks — which currently include Heading, Paragraph, Image, and Button — have received a new default UI for viewing bindings.

Called Attributes, you can find the new tool panel in block settings whenever a compatible block is selected in either the post or site editor.

The panel shows active bindings on the current block. If there are any post meta available, the panel is also interactive, allowing you to bind attributes to those custom fields via the built-in post meta block bindings source.

Currently, there are two limitations to the panel:

  1. It will not allow users to bind attributes to custom sources just yet. 

    Bindings to custom sources, which can be added via the code editor or other programmatic means, will still display in the panel — they just can’t be connected via the UI for the moment in WordPress 6.7.

    A flexible API for connecting custom sources to the Attributes panel is currently under development and is planned for public release in the future.

    For now, the rollout of that API has started with the built-in post meta source to allow time for gathering feedback.
  2. For each attribute, the panel will only show custom fields that match its data type. For example, an attribute of type string or rich-text can only be connected to a custom fieldCustom Field Custom Field, also referred to as post meta, is a feature in WordPress. It allows users to add additional information when writing a post, eg contributors’ names, auth. WordPress stores this information as metadata. Users can display this meta data by using template tags in their WordPress themes. of type string, and an attribute of number can only be connected to another number.

New Post Meta Label Attribute

To improve how custom fields appear in the editor UI, a new label attribute has been created for post meta, which can be defined during registration:

If specified, the label will render in place of the meta key in the Attributes panel — in this example, the label would replace movie_director. The label will also render under certain circumstances in other parts of the editor, including as a placeholder for Rich Text if a block is bound to the post meta source and a default value is undefined.

Usage In Custom Post Templates

One of the primary use cases for Block Bindings is to assist in creating templates for custom post types. Given a custom post typeCustom Post Type WordPress can hold and display many different types of content. A single item of such a content is generally called a post, although post is also a specific post type. Custom Post Types gives your site the ability to have templated posts, to simplify the concept. called movie, for example, one can define how custom fields for that post type will render, such as via connected images, headings, paragraphs, and buttons.

Here is an example of how one could use connected blocks to create a layout:

One can override the content in connected blocks for each instance of the custom post type, a much simpler and more flexible way of creating layouts than in the past — all without needing to create custom blocks.

Default Permissions

Accompanying this UI is a new canUpdateBlockBindings editor setting, used to determine whether the UI is interactive for users or not.

By default, this editor setting is set to a new edit_block_binding capability, which maps to a user’s ability to either:

  1. Edit the post type (in the post editor), or
  2. Edit the theme options (in the site editor)

This means that the setting is by default set to true for administrators, and false for other users.

This default setting can be overridden using the block_editor_settings_all filterFilter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. and modifying $editor_settings['canUpdateBlockBindings'] as follows:

function my_plugin_override_can_update_block_bindings( $settings ) {
    $settings['canUpdateBlockBindings'] = true;
    return $settings;
}
add_action( 'block_editor_settings_all', 'my_plugin_override_can_update_block_bindings' );

New Public Editor APIs

Several functions have been exposed to enable the use of block bindings in the editor.

Registration API

Source Bootstrapping 

As part of the new editor API, Block Bindings will automatically register custom sources defined on the server with bootstrapped values in the editor. This will allow existing sources registered using just the server APIs to render in the UI.

This means that any sources already registered using the server APIs, available since 6.5, will appear in the UI, at least minimally, without any action required.

For example, given the following server registration and block markup…

Server Registration
function my_plugin_register_block_bindings_post_attributes() {
    register_block_bindings_source(
        'my-plugin/post-attributes',
        array(
            'label'              => _x( 'Post Attributes', 'block bindings source', 'my-plugin' ),
            'get_value_callback' => 'my_plugin_block_bindings_post_attributes_get_value',
            'uses_context'       => array( 'postId' ),
        )
    );
}
add_action( 'init', 'my_plugin_register_block_bindings_post_attributes' );

function my_plugin_block_bindings_post_attributes_get_value( array $source_args, $block_instance ) {
    $allowed_fields = array( 'title', 'excerpt' );
    if ( ! in_array( $source_args['key'], $allowed_fields ) ) {
        return null;
    }
    $post = get_post( $block_instance->context['postId'] );
    return $post->{'post_' . $source_args['key']};
}
Block Markup
<!-- wp:paragraph {"metadata":{"bindings":{"content":{"source":"my-plugin/post-attributes","args":{"key":"title"}}}}} -->
<p></p>
<!-- /wp:paragraph -->

…the source will get registered in the editor with the source’s name my-plugin/post-attributes, label, and uses_context values. This is enough for the UI to render as follows:

In this case, however, the bound paragraph in the block canvas will simply show the source label and will not be dynamic. Further customization of the editor experience requires using the new editor registration functions, detailed in the next section.

Editor Registration

The following functions have been exposed to allow customization of the editor experience:

  • registerBlockBindingsSource: Registers a source on the client (using this function will override the bootstrapped registration).
  • unregisterBlockBindingsSource: Unregisters an existing source.
  • getBlockBindingsSource: Gets a specific registered source and its properties.
  • getBlockBindingsSources: Gets all the registered sources in the client.

These are based on other registration APIs like block types, block variations, or block collections.

Source Properties

Registered sources in the client can include the following properties:

  • name: The unique and machine-readable name.
  • label: Human-readable label. Will overwrite preexisting label if it has already been registered on the server.
  • usesContext: Array of context needed by the source only in the editor. Will be merged with existing uses_context if it has already been registered on the server.
  • getValues: Function to get the values from the source. It receives select, clientId, context, and the block bindings created for that specific source. It must return an object with attribute: value. Similar to getBlockAttributes.
  • setValues: Function to update multiple values connected to the source. It receives select, clientId, dispatch, context, and the block bindings created for that specific source, including the new value. Similar to updateBlockAttributes.
  • canUserEditValue: Function to let the editor know if the block attribute connected should be editable or not. It receives select, context, and the source arguments.
Example Usages 
Register a Block Bindings Source

Building on the example server registration, use the following JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. to register in the editor by enqueuing on the enqueue_block_editor_assets hook:

import { registerBlockBindingsSource } from '@wordpress/blocks';
import { __ } from '@wordpress/i18n';
import { store as coreEditorStore } from '@wordpress/editor';

const allowedAttributes = [ 'title', 'excerpt' ];

registerBlockBindingsSource( {
    name: 'my-plugin/post-attributes',
    usesContext: [ 'postType' ],	
    getValues( { select, bindings } ) {
        const values = {};
        for ( const [ attributeName, source ] of Object.entries( bindings ) ) {
            if ( allowedAttributes.includes( source.args.key ) ) {
                values[ attributeName ] = select( coreEditorStore ).getEditedPostAttribute( source.args.key );
            }
        }
        return values;
    },
    setValues( { dispatch, bindings } ) {
        const newValues = {};
        for ( const [ attributeName, source ] of Object.entries( bindings ) ) {
            if ( allowedAttributes.includes( source.args.key ) ) {
                newValues[ source.args.key ] = source.newValue;
            }
        }
        if ( Object.keys( newValues ).length > 0 ) {
            dispatch( coreEditorStore ).editPost( newValues );
        }
    },
    canUserEditValue( { context, args } ) {
        return allowedAttributes.includes( args.key ) && 'post' === context.postType;
    },
} );

To connect example blocks to the source, go to the post editor, open the code editor, and use the following markup:

<!-- wp:paragraph {"metadata":{"bindings":{"content":{"source":"my-plugin/post-attributes","args":{"key":"title"}}}}} -->
<p></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph {"metadata":{"bindings":{"content":{"source":"my-plugin/post-attributes","args":{"key":"excerpt"}}}}} -->
<p></p>
<!-- /wp:paragraph -->

For a more in-depth example of how these properties can be defined in a real-world scenario, see the registration for the built-in post meta source.

Unregister a Block Bindings Source
import { unregisterBlockBindingsSource } from '@wordpress/blocks';

unregisterBlockBindingsSource( 'plugin/my-custom-source' );
Get All Block Bindings Sources
import { getBlockBindingsSources } from '@wordpress/blocks';

const registeredSources = getBlockBindingsSources();
Get a Block Bindings Source
import { getBlockBindingsSource } from '@wordpress/blocks';

const blockBindingsSource = getBlockBindingsSource( 'plugin/my-custom-source' );

Note: If desired, sources may be registered only on the client and not on the server at all. This could be useful for creating forms in the adminadmin (and super admin), or otherwise using bindings to interact with other parts of WordPress, or other dynamic data.

Block Bindings Utils

The useBlockBindingsUtils hook returns helper functions to modify the metadata.bindings attribute. The hook accepts an optional clientId argument. If the clientId is not specified, the helper functions will execute in the current block edit context.

Right now, the helpers include:

  • updateBlockBindings: This works similarly to updateBlockAttributes. It can be used to create, update, or remove specific connections.
  • removeAllBlockBindings: This is used to remove all existing connections in a block.

Example usage

import { useBlockBindingsUtils } from '@wordpress/block-editor';

const { updateBlockBindings, removeAllBlockBindings } = useBlockBindingsUtils();

// Updates bindings for url and alt attributes.
updateBlockBindings( {
    url: {
        source: 'core/post-meta',
        args: {
            key: 'url_custom_field',
        },
    },
    alt: {
        source: 'core/post-meta',
        args: {
            key: 'alt_custom_field',
        },
    },
} );

// Removes all bindings set for the block.
removeAllBlockBindings();

Used internally by the default UI for the post meta source and pattern overrides, these utils can be useful in building custom UI for other sources.

For more examples of how these functions are used in practice by the built-in UI, see the calls to updateBlockBindings and removeAllBlockBindings.

New Server Filter

A block_bindings_source_value filter has been introduced to allow for overriding of the value returned by a source in a bound block. It takes the following arguments:

  • value: Value returned by the source.
  • name: Name of the source.
  • source_args: Arguments passed to the source.
  • block_instance: The bound block.
  • attribute_name: The connected attribute in the bound block.
function modify_block_bindings_source_value( $value, $name, $source_args, $block_instance, $attribute_name ) {
    if ( 'core/post-meta' === $name && 'movie_runtime' === $source_args['key'] ) {
        return $value . ' minutes';
    }
    return $value;
}
add_filter( 'block_bindings_source_value', 'modify_block_bindings_source_value', 10, 5 );

Conclusion

The developers behind Block Bindings are always happy to hear feedback. Please feel free to share bugs, feature requests, or other thoughts by creating issues on GithubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ or leaving a comment on this post.

Anyone can also follow and comment on Block Bindings development via the latest iteration, which is posted in the Block Bindings tracking issue at the beginning of each release cycle. Be sure to subscribe to the tracking issue for updates!

Lastly, if you’d like to help shape the roadmap for Block Bindings by sharing your use cases, feel free to post in Block Bindings discussions.

Props to @santosguillamot @gziolo @cbravobernal @greenshady @fabiankaegy and @welcher for their help compiling this post.

#6-7, #block-bindings, #dev-notes, #dev-notes-6-7