The WordPress coreCoreCore is the set of software required to run WordPress. The Core Development Team builds WordPress. development team builds WordPress! Follow this site forย general updates, status reports, and the occasional code debate. Thereโs lots of ways to contribute:
Found a bugbugA 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.?Create a ticket in the bug tracker.
Welcome back to a new issue ofย Week inย CoreCoreCore is the set of software required to run WordPress. The Core Development Team builds WordPress.. Letโs take a look at what changed onย TracTracAn open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress.ย between July 10 and July 17, 2023.
78 commits
135 contributors
61 tickets created
12 tickets reopened
70 tickets closed
TicketticketCreated for both bug reports and feature development on the bug tracker.ย numbers are based on theย Trac timeline for the period above. The following is a summary of commits, organized by component and/or focus.
Code changes
Administration
Add a missing closing `span>tagtagA directory in Subversion. WordPress uses tags to store a single snapshot of a version (3.6, 3.6.1, etc.), the common convention of tags in version control systems. (Not to be confused with post tags.) for column sorting indicators โ #32170, #57839
Bootstrap/Load
Require wp-includes/compat.php in src/index.php โ #58206
Build/Test Tools
Remove outmoded jsvalidate task from Gruntfil โ #58645, #26615
fix height of featured images in Twenty Twenty Three โ #58766
Twenty Seventeen: Use wp_register_script() to register HTML5 Shiv script โ #56699
Twenty Twenty-Three: Add a border to Quote blockBlockBlock 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. โ #57506
Twenty Twenty-Three: Remove the perPage attribute where the query inherits from the global query. The global attribute should be used instead โ #58581
Add test for context setting in Comment Template block โ #58839
Fix a PHPPHPThe web scripting language in which WordPress is primarily architected. WordPress requires PHP 7.4 or higher notice appearing when adding a new template part โ #57851
Fix bugbugA 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. where it was not possible to style custom block elements in theme.json โ #57868
Fix layout of no-js state in site editor โ #56228
Fix open_basedir warnings on the classic Edit Post screen when additional TinyMCE plugins are use โ #54354
Lazily load Duotone settings only when needed โ #58673
fix duotone filters in classic themes โ #58734 โ #46132
fix since annotation in rest blocks controller class โ #58677
remove one preloaded navigation endpoint โ #58749
trim footnote anchors from post excerpts โ #58805
update npm packages with bug fixes and blessed tasks โ #58745
update npm packages with first round of bug fixes for 6.3 RC1 โ #58804
update npm packages with second round of bug fixes for 6.3 RC1 โ #58804
update string incorrectly marked for translationtranslationThe process (or result) of changing text, words, and display formatting to support another language. Also see localization, internationalization. in Chrome โ #58716
External Libraries
Update deprecated jQuery code in Farbtastic lib โ #57946
Filesystem APIAPIAn 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.
Ensure wp_tempnam() does not produce file names longer than 255 characters as this is the limit on most filesystems โ #35755
General
Escape nonce used for block theme activation โ #58712
Add a โGet Involvedโ tab to the About page โ #23348
Adjust horizontal padding on the tabs under 960 pixels width โ #23348
Fix closing contextual help when scrolled โ #55342
Fix typo in [56171]: support forumSupport ForumWordPress Support Forums is a place to go for help and conversations around using WordPress. Also the place to go to report issues that are caused by errors with the WordPress code and implementations. โtopicโ, not โticketโ
String changes in the Contribute screen โ #23348
Update โGet Involvedโ tab content with the latest edits โ #23348
I18ni18nInternationalization, or the act of writing and preparing code to be fully translatable into other languages. Also see localization. Often written with a lowercase i so it is not confused with a lowercase L or the numeral 1. Often an acquired skill.
Improve the use of dashicons-external icon for external links โ #47303
Move translator comments inside sprintf for tagline field description โ #57675
Media
Fix adminadmin(and super admin) image editor layout at intermediary widths โ #58692
A Week in Core, July 17 โ props to @audrasjb โ 135 people contributed to coreCoreCore is the set of software required to run WordPress. The Core Development Team builds WordPress. on TracTracAn open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress. last week, and 23 of them were new to core Trac contribution!
WordPress 6.3 Field Guide is coming together and was published with RC1 to help inform WordPress developers, extenders and others.
WordPress 6.4 โ Whatโs on your wish list? โ great post by @chanthaboune inviting community feedback on what tickets you would like to see, any UXUXUser experience main pain points, and whatโs needed for component maintainers for this next release. Feedback deadline August 15, 2023.
Forthcoming release updates
Next major WordPress release: 6.3
6.3 is scheduled for release on August 8, 2023.
Stay in theย loopLoopThe Loop is PHP code used by WordPress to display posts. Using The Loop, WordPress processes each post to be displayed on the current page, and formats it according to how it matches specified criteria within The Loop tags. Any HTML or PHP code in the Loop will be processed on each post. https://codex.wordpress.org/The_Loopย with 6.3 โ links for reference:
6.3 Release Parties schedule โ this can change at the last minute, but this post gives the expected start time for each planned release party for the 6.3 milestones
Please add any items for this part of the agenda to the comments. If you can not attend dev chat live, donโt worry, include a note and the facilitator can highlight a ticketticketCreated for both bug reports and feature development on the bug tracker. if needed. This part of the agenda will focus on items for 6.3.
Open floor
If you have any additional items to add to the agenda, please respond in the comments below to help the facilitator highlight them during the meeting.
WP 6.3ย Release Candidaterelease candidateOne 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).ย 1 is today
Reminder: Working on a WordPress 6.3 performance highlights post โ please add suggestions to theย documentย by July 21
@spacedmonkey Most of my focus last week wasย https://github.com/WordPress/wordpress-develop/commit/fc538206ecd6a6b2f07a07701475d2cd3867d9aa Basically the new changes to Duotone resulted in a performnace regressionregressionA software bug that breaks or degrades something that previously worked. Regressions are often treated as critical bugs or blockers. Recent regressions may be given higher priorities. A "3.6 regression" would be a bug in 3.6 that worked as intended in 3.5..
Discovery โย https://github.com/WordPress/wordpress-develop/pull/4857. This is regarding lazily loading blockBlockBlock 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. variants. The template part block does a WP_Query on every page load, even when not needed
JavaScriptJavaScriptJavaScript 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 & CSSCSSCascading Style Sheets.
@10upsimon Not much of an update here at this point, other than to say that we made it to coreCoreCore is the set of software required to run WordPress. The Core Development Team builds WordPress. for 6.3 regarding enhancing the scripts APIAPIAn 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. with a loading strategy
@westonruter Now that we have Script Loading Strategies committed, Iโve started exploring how we can take advantage of them to improve frontend performance in core/themes/plugins. As a first step, I wanted to try one set of enhancements to see what is involved and what the impact is to see whether the effort is worth it. As an initial exploration, I focused on the scripts that GutenbergGutenbergThe 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/ adds to the frontend, that is the block view scripts. These are unfortunately all added to theย headย and are all blocking. So opened a PR to leverage async and defer, and my findings a 19.3% reduction in LCP-TTFB!ย https://github.com/WordPress/gutenberg/pull/52536#:~:text=Performance%20Analysis
@flixos90 In addition to the above PR byย @westonruter it would be great if we could define what we want to accomplish with the script loading strategy for WP 6.4. There are probably a couple places where we can adopt it, in core, in the default themes etc., so it would be good to capture that somewhere
@westonruter Next step is I want to try a performance analysis using an old low-powered Android phone to see the impact there as well
@flixos90 Maybe in aย WordPress/performanceย GH issue for overview, and then we can open and link to TracTracAn open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress. tickets, Gutenberg issues, etc. from there
@joemcgill I noticed that @adamsilverstein has been looking int AVIF and JPEG XL support. Iโm wondering if this is something we want to consider adding via the Performance Lab pluginPluginA 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. soonish?
@flixos90 For AVIF, we could literally almost duplicate the WebP Uploads module. Or we could somehow add it into it and allow users to choose which format to generate. Unsure about JPEG XL, since its situation is unclear and support rather poor
@spacedmonkey Safari added support lately didnโt they?
@adamsilverstein safari did adopt support, no word yet from the other browsers on JPEG XL. For AVIF support, Edge has added in Canary โ once it lands in Stable, we can consider merging support into coreย
@flixos90 Chrome deprecated support for JPEG XL as far as I know, so thatโs a reverse signal
@spacedmonkey I think allow users to upload these format is fine.
@adamsilverstein thats what i mean when i say landing support in core
@adamsilverstein it never quite made it to chrome stable, it was always behind a feature flag
@flixos90 Yeah but now itโs not even available there anymore
@spacedmonkey We have other formats at are not web safe that we allow to upload. For example HEIC
@flixos90 Sure, in terms of experimentation we can always allow those things. But I wonder whatโs the value is. Especially JPEG XLโs future is unclear, so for that format Iโd be in favor of not supporting in core just yet. Itโs less about safety than about the web ecosystem and standards
@adamsilverstein iโm not certain the hooksHooksIn WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. are in place to add support seamlessly in the plugin, suopport for the format needs to be added in numerous places
@joemcgill It would definitely be best to explore support via the PL plugin in advance of any core consideration so we can work out the details.
@adamsilversteinwe can try, but i suspect we wonโt be able to add full support for AVIF via the plugin
@joemcgill Iโd like to see us add an option in the PL plugin that would allow WP to serve AVIF versions of images that are uploaded as JPEG. But happy to have that conversation elsewhere
Discussion paused here and @clarkeemily suggested to move discussions over to https://github.com/WordPress/performance/issues/11
@flixos90 I worked on some exploration for UIUIUser interface to add metrics to theย Server-Timingย headerHeaderThe header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitorโs opinion about your content and you/ your organizationโs brand. It may also look different on different screen sizes. yesterday, seeย https://wordpress.slack.com/archives/C02KGN5K076/p1689639916131339 Would love to get some feedback on this
It would simplify local benchmarking a lot, since you could e.g. add a specific action to capture its performance, then useย benchmark-server-timingย to get its data. Without such a UI, that always involved writing some custom code, which was cumbersome and slow
@mukesh27 We have started theย QA testingย phase this week, and itโs going well so far. You can keep track of our progress on GitHubGitHubGitHub 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 by the repository owner. https://github.com/ using this link:ย https://github.com/10up/plugin-check/ย We welcome everyone to take a look at the testing process and the code changes. If you have any thoughts, ideas, or feedback, please feel free to share them on the repository. Your input is highly valuable to us!
@10upsimon From my end, work is ongoing. No relevant updates from me at this point.
Open Floor
@clarkeemily Worth noting, yesterday saw the release of versionย 2.5.0ย of the Performance Lab plugin
@spacedmonkey I have been working on automating compare server response time between WP versions. I made some pretty graphs [link] I will share the bash script I used to generate this and the raw data.
I think our benchmarking tools need the ability to compare two results or more. ATM, the benchmark tools just output one result and you have manually format it to a google doc / excel. I would love for do multiple runs and it saves it into a CSV file or something.
@westonruter And add a column that shows the difference. I did this manually myself yesterday as well
@spacedmonkey Should I create a ticketticketCreated for both bug reports and feature development on the bug tracker., someone could work on it with some spare time. Feels like we are doing some of manual work, that could be automated.
@westonruter Being able to pass multiple URLs into the tool would work when youโre dealing with multiple environments, but it wouldnโt work so well when youโre reusing the same environment and just changing a branchbranchA directory in Subversion. WordPress uses branches to store the latest development code for each major release (3.9, 4.0, etc.). Branches are then updated with code for any minor releases of that branch. Sometimes, a major version of WordPress and its minor versions are collectively referred to as a "branch", such as "the 4.0 branch"., for example.
@spacedmonkey I thought about that, what if you say, run 3 times, after the first time, it stops and needs you press enter to continue. That way you could just run it, change your branch and press enter
@westonruter yeah. Or it could accept an arg that points to a script that performs env setup.
With WP6.3 scheduled for release on August 8th, letโs start planning for WP6.4! We always aim to fix bugs, add new tools, andย makeย WordPress better than ever for users. Polish and refinement of Phase 2 items are high on our list as are any items in the Phase 3: Collaborationย roadmap:ย Real-Time Collaboration,ย Workflows,ย Revisions,ย Media Library,ย Block Library, andย Admin Design.
What other tickets do you think need some attention in this release cycle?
Share Your Feedback!
What do you want to see included in WP6.4?
What are the currentย UXUXUser experienceย pain points?
What features can we add or iterate on?
Component Maintainers: what tickets of yours do you think will be ready to ship in WP6.4 and need some review/feedback/approval/etc?
Note: Adding yourย ticketticketCreated for both bug reports and feature development on the bug tracker.ย here wonโt necessarily guarantee inclusion. But no one can fix things they canโt see, so bravely share your thoughts!
Deadline August 15, 2023
After the deadline passes, the release squad will discuss wishlist items and the release leadRelease LeadThe community member ultimately responsible for the Release. will make final decisions based on what is aligned with the roadmap and has an owner, feasible in the time we have*, and high impact for the most users.
* This release is shorter than normal, so thatโs part of the decision making criteria.
This guide shares more of the in-depth changes that you will find in 6.3 and is published with Release Candidaterelease candidateOne 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). 1 to help inform WordPress developers, extenders, and others.
GutenbergGutenbergThe 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/ included in this release has 1737 pull requests: 307 enhancements, 481 bugbugA 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, and 55 accessibilityAccessibilityAccessibility (commonly shortened to a11y) refers to the design of products, devices, services, or environments for people with disabilities. The concept of accessible design ensures both โdirect accessโ (i.e. unassisted) and โindirect accessโ meaning compatibility with a personโs assistive technology (for example, computer screen readers). (https://en.wikipedia.org/wiki/Accessibility) improvements.
Changes in 6.3 are spread across 43 core components. Below is the breakdown of the most important ones.
BlockBlockBlock 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. Editor
WordPress 6.3 is bringing 10 Gutenberg releases into the core โ 15.2, 15.3, 15.4, 15.5, 15.6, 15.7, 15.8, 15.9, 16.0, and 16.1. You will find new Block APIs, Block properties, Block editing mode, Block layout support, color classes, Command Palette, Reusable Blocks renamed to Synced Patterns, and many other changes in these 10 pluginPluginA 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. releases.
Bundled default themes have dropped support for Internet Explorer scripts and styles, which also removed skip-link focus fix script for navigating by keyboard in Internet Explorer and old versions of Chrome.
In addition, special stylesheets and HTML5 Shiv scripts are not enqueued or included in the header.php template for the following themes: Twenty Thirteen (its conditional code is also removed), Twenty Fifteen, and Twenty Seventeen. (#56699)
Theme developers who wish to continue to support IE can add code snippets to their themes that restore the functionalities.
Cache APIAPIAn 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.
The Cache API has undergone several improvements: introducing new cache groups specific to queries and offering developers greater control over the handling of objects within these groups.
You can now set the expiration time for a cache group, clear specific cache groups, set last changed value for a cache group, and declare specific cache groups as non-persistent. With these changes, you can implement your own custom cache invalidation strategies, allowing you to invalidate an entire cache group programmatically.
Other improvements include improved validation, ensuring that only an array of unique integers are passed as input.
Hidden (. prefixed) files can now be included in list_files() with a new optional $include_hidden parameter. Defaults to false for backward compatibility. (#53659)
General
A new constant WP_DEVELOPMENT_MODE is introduced to signify context-specific development mode. The constant can have the value โcoreโ, โpluginโ, โthemeโ, โallโ, or an empty string. The latter of which means no development mode, which is also the default.
Two new helper functions wp_is_development_mode( $mode ) and wp_get_development_mode() are introduced as the recommended ways to interact with this new configuration value.
The different development modes affect specific caching functionality; for example, caching is only bypassed during theme development, but not during core development. (#57487)
The current value of the WP_DEVELOPMENT_MODE constant is also accessible under Tools > Site Health > Info, in the WordPress Constants section. (#58646)
WP_DEVELOPMENT_MODE serves as an addition to existing debugging constants: WP_DEBUG, SCRIPT_DEBUG, and WP_ENVIRONMENT_TYPE.
I18Ni18nInternationalization, or the act of writing and preparing code to be fully translatable into other languages. Also see localization. Often written with a lowercase i so it is not confused with a lowercase L or the numeral 1. Often an acquired skill.
Improvements include the ability to short-circuit load_textdomainfilterFilterFilters 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 reducing loading time for just-in-time translationtranslationThe process (or result) of changing text, words, and display formatting to support another language. Also see localization, internationalization..
The media component has been updated with several enhancements that improve load time performance for content with images. WordPress now automatically adds the fetchpriority attribute with a value of โhighโ to the image that it determines most likely to be the โLCP (Largest Contentful Paint) imageโ. Other enhancements have been implemented to improve the automatic handling of lazy-loading via the loading attribute to more reliably detect when to omit the attribute from some images.
Metadata API has undergone significant improvement in the area of lazy loading capabilitiescapabilityAย capabilityย is permission to perform one or more types of task. Checking if a user has a capability is performed by the current_user_can function. Each user of a WordPress site might have some permissions but not others, depending on theirย role. For example, users who have the Author role usually have permission to edit their own posts (the โedit_postsโ capability), but not permission to edit other usersโ posts (the โedit_others_postsโ capability). for term, comment, and site metadata. Lazy loading refers to a technique where data is loaded only when it is actually needed. This reduces unnecessary database queries or cache lookups and improves overall performance.
The function get_pages() has been revised to utilize WP_Query internally. This improvement significantly reduces the complexity of the get_pages() function by offloading the burden of querying databases and handling the cache to WP_Query. (#55806 and #12821)
Support for HTMLHTMLHyperText Markup Language. The semantic scripting language primarily used for outputting content in web browsers. 5 โasyncโ and โdeferโ attributes has been added, which allows developers to register scripts with a loading strategy. The loading strategy can be enabled by overloading the $in_footer parameter as an array that contains the loading strategy to the wp_register_script() and wp_enqueue_script() functions. If present, the loading strategy attribute will be added to the script tagtagA directory in Subversion. WordPress uses tags to store a single snapshot of a version (3.6, 3.6.1, etc.), the common convention of tags in version control systems. (Not to be confused with post tags.).
The intended loading strategy that you pass via the $args parameter may not be the final (chosen) strategy since the scriptโs dependency tree (its dependencies and/or dependents) is taken into account, but it will never be detrimental to (or stricter than) the intended strategy.
The rollback feature will automatically restore the previously installed plugin/theme version if the manual update process fails. This enhancementenhancementEnhancements are simple improvements to WordPress, such as the addition of a hook, a new feature, or an improvement to an existing feature. makes the update process more reliable and ensures that if a plugin or theme update fails, the previous version can be safely restored and the website remains available to its users.
When updating a plugin or theme, the old version is moved to a temporary backup directory:
wp-content/upgrade-temp-backup/plugins/[plugin-slug] for plugins
wp-content/upgrade-temp-backup/themes/[theme-slug] for themes.
If the update fails, then the backup kept in the temporary backup directory is restored to its original location.
If the update succeeds, the temporary backup is deleted.
To further help troubleshoot plugin and theme updates, two new checks were added to the Site Health screen:
Check to make sure the upgrade-temp-backup directory is writable.
Check there is enough disk-space available to safely perform updates.
Please take note, the rollback feature cannot be used to โroll backโ a plugin/theme to a previous version after a successful update (the feature is only applicable to failed manualupdates).
An enhancement has been made to the caching of database queries in WP_User_Query class, the only remaining query class lacking this caching capabilitycapabilityAย capabilityย is permission to perform one or more types of task. Checking if a user has a capability is performed by the current_user_can function. Each user of a WordPress site might have some permissions but not others, depending on theirย role. For example, users who have the Author role usually have permission to edit their own posts (the โedit_postsโ capability), but not permission to edit other usersโ posts (the โedit_others_postsโ capability)..
All calls to WP_User_Query will be automatically cached by default, unless setting the relevant parameters otherwise. You can also globally disable caching by using a filter.
A new global cache group named โuser-queriesโ is introduced to store the results of queries. Caching will be disabled for user queries that utilize the field parameter and request more than 3 fields.
Finally, plugins utilizing the users_pre_query hook to modify the returned values will bypass caching and the behaviors will remain the same as before.
The cron memory limit has been increased to WP_MAX_MEMORY_LIMIT (256MB by default) during cron event processing if the default memory limit is lower than this value. Note that this will not affect external means of processing cron events, such as the wp cron command in WP-CLIWP-CLIWP-CLI is the Command Line Interface for WordPress, used to do administrative and development tasks in a programmatic way. The project page is http://wp-cli.org/https://make.wordpress.org/cli/, server-level crontab events, or any other cron event processing mechanism that bypasses wp-cron.php.
A new filter cron_memory_limit has been introduced to adjust this value if necessary. (#56628)
Editor
A new source attribute is added to Block patterns allowing them to be filtered by that source. (#58622)
Embeds
Anghami has been added as a trusted oEmbed provider. (#49850)
Support for TikTok creator profiles has been added. (#55784)
Formatting
Added aria content attributes aria-controls, aria-expanded, and aria-current to allowed attributes in KSES. (#55370)
CSSCSSCascading Style Sheets.repeat() function support has been added for KSES. (#58551)
General
In KSES, the safecss_filter_attr() function has been revised to allow the filter property to accept a URLURLA specific web address of a website or web page on the Internet, such as a websiteโs URL www.wordpress.org, as a reference to an SVG filter element. (#57780)
Replacing strpos() and substr() for code modernization (note: for PHP versions lower than v8.0, the three replacement functions have been polyfilled since WP v5.9):
The usage of 0 === strpos() or 0 !== strpos() has been replaced with str_starts_with().
The usage of false === strpos() or false !== strpos() has been replaced with str_contains().
The usage of $needle === substr( $string, 0, $length ) has been replaced with str_starts_with( $haystack, $needle ). The value of $length should be the length of $needle.
The usage of $needle === substr( $string, $offset ) where $offset is negative has been replacedย with str_ends_with( $haystack, $needle ). The absolute value of $offset should be the length of $needle. (#58012, #58206, #58220)
Performance
In the WP_Comments_List_Table class, when the function get_comments() is called, the parameter update_comment_post_cache is passed with a value of true. This primes all the related posts for the displayed comments and improves performance. (#57802)
The _wp_array_get() function is the most called function on the front end of a site, up to ~23k times on each page-load when using a block theme. A few minor performance optimizations have been introduced, which adds up to a noticeable improvement. (#58376)
Quick/Bulk Edit
A new bulk_edit_posts action hook is introduced, which triggers after processing the post data for bulk edit and before it returns its results. For example, it allows developers to save additional data without having to perform any .ajax() call. (#28112)
REST APIREST APIThe REST API is an acronym for the RESTful Application Program Interface (API) that uses HTTP requests to GET, PUT, POST and DELETE data. It is how the front end of an application (think โphone appโ or โwebsiteโ) can communicate with the data store (think โdatabaseโ or โfile systemโ)
https://developer.wordpress.org/rest-api/
The Themes REST API can now indicate whether a theme supports the Site Editor by adding an is_block_theme property to each theme in the wp/v2/themes API response. (#58123)
A revisionsRevisionsThe WordPress revisions system stores a record of each saved draft or published update. The revision system allows you to see what changes were made in each revision by dragging a slider (or using the Next/Previous buttons). The display indicates what has changed in each revision. endpoint for global styles, /wp/v2/global-styles/revisions, has been added to the REST API. (#58524)
WP_REST_Templates_Controller has a new modified field for template and template part objects that returns post modified datetime for Templates. (#58540)
Revisions
When a post is saved with an unchanged autosave, the existing autosave will be returned, instead of returning an error. (#58739)
Themes
A new public function wp_get_remote_theme_patterns() has been added to query the patterns datum from theme.json and substitutes current usage of private APIs. (#58460)
New Action HooksHooksIn WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same.
rest_allowed_cors_headers (#57752) and rest_exposed_cors_headers (#57752)
edit_custom_thumbnail_sizes has been deprecated and replaced with image_edit_thumbnails_separately (#57685)
Deprecated Files
The wp-admin/media.php file has been deprecated. Users visiting the file will be redirected to the media library wp-admin/upload.php. A user-facing warning will be displayed when the media library is reached via a deprecated link. (#57612)
External Library Updates
The following libraries were updated to the latest versions:
Added the no-store and private directives to the Cache-ControlheaderHeaderThe header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitorโs opinion about your content and you/ your organizationโs brand. It may also look different on different screen sizes. to prevent caching for logged in users. This prevents sensitive data on logged-in users from being cached and available to others, for example, via the browser history after the user logs out. (#21938)
External Libraries
jQueryย has been updated from v3.6.4 to v3.7.0. (#58083)
The latest version of jQuery includes bugbugA 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, a new method called .uniqueSort(), Sizzle selector engine, and a performance improvement for some use cases when using manipulation methods like .append().
The .uniqueSort() method is used to sort an array or an array-like object of DOM elements and remove any duplicate nodes.
Sizzle, its selector engine, has been included as inlined code and removed as a project dependency, along with the removal of some workarounds for legacy browsers in the process.
Adding required attributes to username and password input fields
In WordPress 6.3, the WordPress login form includes the required attributes for username and password fields, resolving ticketticketCreated for both bug reports and feature development on the bug tracker.#32510. This change, while minor, may have some ramifications for pluginPluginA 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. developers.
The change adds semantic clarity to explicitly mark these fields as required, reinforcing the implied expectation that has always been in place for login fields.
Impact for Developers
Plugins that bypass login fields or login via alternative methods using the login page may need to adapt by removing the input fields or removing the required attribute.
Props @joedolson for the dev notedev noteEach 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..
Media
The fallback return value in get_the_author() is corrected to return an empty string if called before $authordata is set. This fixes PHPPHPThe web scripting language in which WordPress is primarily architected. WordPress requires PHP 7.4 or higher 8.1 โnull to non-nullableโ deprecation notice in ent2ncr() function that is hooked via the_authorfilterFilterFilters 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.. (#58157)
Plugins
A new plugins_list filter hook is introduced, which can be used to filter the list of plugins (including those that are โmust-use / muโ) that are displayed on the WP Adminadmin(and super admin) Plugins screen. (#57278)
A new post type label item_trashed is introduced, which allows the blockBlockBlock 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. editor to announce the correct message when an entity is moved to the TrashTrashTrash in WordPress is like the Recycle Bin on your PC or Trash in your Macintosh computer. Users with the proper permission level (administrators and editors) have the ability to delete a post, page, and/or comments. When you delete the item, it is moved to the trash folder where it will remain for 30 days.. (#51387)
Themes
Non-block themes without theme.json can opt-in to block link color tools and block border tools via add_theme_support(). (#58597 and #58598)
In the callback function that is hooked to the after_setup_theme action in your functions.php of your theme, add the following inside the function:
WP 6.3 Release Candidaterelease candidateOne 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). 1 is today
Reminder: Working on a WordPress 6.3 performance highlights post โ please add suggestions to the document by July 21
Due to very low traffic from Internet Explorer users, and because WordPress no longer supports this obsolete browser, default themes have removed some IE-specific scripts and styles to give everyone else a better experience.
Most default themes had a skip-link focus fix script for navigating by keyboard in Internet Explorer and old versions of Chrome. As of WordPress 6.3, Twenty Thirteen and Twenty Fourteen no longer include it in their functions.js files, and the six themes from Twenty Fifteen to Twenty Twenty-One do not enqueue or print the script.
In addition, special stylesheets and the HTML5 Shiv script are not enqueued or included in the header.php template for three themes:
Twenty Thirteen (its conditional code is also removed)
Twenty Fifteen
Twenty Seventeen
Future versions of Twenty Eleven, Twenty Twelve, Twenty Fourteen and Twenty Sixteen may remove their special styles and conditional code too.
What if I want to continue supporting Internet Explorer?
Restoring the skip-link focus fix
Twenty Thirteen users can add a minified version of the script found in later themes:
Twenty Fourteen would need an adjustment for the fixed headerHeaderThe header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitorโs opinion about your content and you/ your organizationโs brand. It may also look different on different screen sizes.:
Sites may have been severely broken when using old versions of Internet Explorer, even with the HTML5 Shiv script and IE-specific styles, but you could add them again.
If you have a child themeChild themeA Child Theme is a customized theme based upon a Parent Theme. Itโs considered best practice to create a child theme if you want to modify the CSS of your theme. https://developer.wordpress.org/themes/advanced-topics/child-themes/ of Twenty Thirteen, you can ensure it has a header.php template that includes the conditional code and HTML5 script from previous versions of the theme. Then you could enqueue the styles in the child theme functions (or a pluginPluginA 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.).
For Twenty Fifteen, you could enqueue the two IE stylesheets. If a child theme does not already have the HTML5 script in a header.php template, the same function could enqueue that too.
function wpdocs_twentyfifteen_ie_restore() {
// Enqueue stylesheets.
wp_enqueue_style( 'twentyfifteen-ie' );
wp_enqueue_style( 'twentyfifteen-ie7' );
// If the header template does not have the HTML5 script already, enqueue it.
wp_enqueue_script(
'twentyfifteen-html5',
get_template_directory_uri() . '/js/html5.js',
array(),
'3.7.0',
false
);
wp_script_add_data( 'twentyfifteen-html5', 'conditional', 'lt IE 9' );
}
add_action( 'wp_enqueue_scripts', 'wpdocs_twentyfifteen_ie_restore' );
With Twenty Seventeen, both the style and script can be enqueued.
For more details, see TracTracAn open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress. tickets #54421 and #56699.
In this post, you will find dev notesdev noteEach 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. for smaller changes to the editor in WordPress 6.3.
Table of contents
Post editor iframed
From WordPress 6.3 on, the post editor will be iframed if all registered blocks have a Block API version 3 or higher. Adding version 3 support means that the blockBlockBlock 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. should work inside an iframeiframeiFrame is an acronym for an inline frame. An iFrame is used inside a webpage to load another HTML document and render it. This HTML document may also contain JavaScript and/or CSS which is loaded at the time when iframe tag is parsed by the userโs browser., though the block may still be rendered outside the iframe if not all blocks support version 3.
It is worth noting that the Site Editor and Page Template Editor have always been iframed, alongside block and pattern previews, and will continue to be iframed regardless of the Block APIAPIAn 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. version.
To make adoption easier, all assets (styles and scripts) added through theย enqueue_block_assetsย PHPPHPThe web scripting language in which WordPress is primarily architected. WordPress requires PHP 7.4 or higher action will now also be enqueued for the iframe. For more details, seeย #48286.
Itโs also worth noting that enqueue_block_editor_assets should not be used to add stylesheets for editor content. Please use enqueue_block_assets instead. If you donโt want styles to load on the front-end, you can use an is_admin() condition.
For backward compatibility, we will clone stylesheets added via enqueue_block_editor_assets if the stylesheet contains a .editor-styles-wrapper, .wp-block, or .wp-block-* selector, but a warning message will be logged. You should use enqueue_block_assets instead, or block.json if youโre adding block styles, theme.json for block-based themes, or add_editor_style() for classic themes.
PluginPluginA 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. developers are asked to make blocks compatible with the iframed methods and support version 3 and to report any problems with those changes. In a future version of WordPress, the editor content will load within an iframe regardless of the Block API version.
Props to@ellatrixย for the dev notedev noteEach 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..
Publish types for plugins packages enabled
TypeScript developers appreciate having great in-editor type-hints and compiler warnings. With the changes for WordPress 6.3, contributors reduced the reliance on DefinitelyTyped, and increase code maintainability. Various wordpress packages were published to allow TypeScript to emit types by parsing the JSDoc comments.
With some small tweaks to assist its inference capabilitiescapabilityAย capabilityย is permission to perform one or more types of task. Checking if a user has a capability is performed by the current_user_can function. Each user of a WordPress site might have some permissions but not others, depending on theirย role. For example, users who have the Author role usually have permission to edit their own posts (the โedit_postsโ capability), but not permission to edit other usersโ posts (the โedit_others_postsโ capability)., TypeScript can generate extensive type definitions even for store objects without migrating much code to TypeScript. So far, the following packages are using this process now:
Allow dragging-and-dropping images from the inserter to image blocks
The updates to theย onDragStartย prop of theย <Draggable>ย component switched the synchronous callback function from an asynchronous one. Previously, it used to be called asynchronously with a slight delay set byย setTimeout(onDragStart, 0). The previous behavior posed a limitation as users were unable to add additional data for the drag event due toย security measures implemented by web browsers.
This change should have minimal impact on existing code. However, if it does affect your code, you can maintain the original behavior by wrapping your event callback inside aย setTimeoutย function as shown below:
New slot in the site editorโs Template sidebarSidebarA 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.
Extenders can now add additional information in the site editorโs Templateย sidebar. With the new slot namedย PluginTemplateSettingPanel the information will appear below the main information, similar to below example of the Template Card. (See Code Example)
Block Transformsย is theย APIย that allows aย blockย to be transformedย fromย andย toย other blocks, as well asย fromย other entities.
From now on, via the optionalย transformsย key of the block configuration, blocks can use theย ungroupย subkey to define the blocks that will replace the block being processed. These new blocks will usually be a subset of the existing inner blocks, but could also include new blocks.
If a block has anย ungroupย transform, it is eligible for ungrouping without the requirement of being the default grouping block. Theย UIUIUser interfaceย used to ungroup a block with this API is the same as the one used for the default grouping block. For the Ungroup button to be displayed, you must have a single grouped block selected, which also contains some inner blocks.
ungroupย is a callback function that receives the attributes and inner blocks of the block being processed. It should return an array of block objects.
Block Variations is the API that allows a block to have similar versions of it, but all these versions share some common functionality. Each block variation is differentiated from the others by setting some initial attributes or inner blocks. Then, when a block is inserted, these attributes and/or inner blocks are applied.
From now on, variations with a scope: transform will be prioritized in the block switcher menu so that they are easier surfaced in existing user interface (UI) patterns. Noting that the existing UI in the blockโs inspector controls regarding the variation transformations is preserved as is.
In this PR, we added a way to control what blocks are shown in the block inserter for a particular block. This allows a block to suggest particular blocks which are going to be most useful.
For example, when inserting a block within the Navigation block, we specify core/navigation-link and core/navigation-link/page as these are the most commonly used inner blocks.
prioritizedInserterBlocks is a property of the InnerBlocks component. To use it, pass prioritizedInserterBlocks as a property of the options argument passed to useInnerBlocksProps.
prioritizedInserterBlocks takes an array of the form {blockName}/{variationName}, where {variationName} is optional.
As a result, the blocks you specify in prioritizedInserterBlocks should be the first ones in the block inserter:
Reusable blocks have been renamed to Patterns in WordPress 6.3. For backward compatibility, the default behavior of ย core/blockย remains exactly the same as with Reusable blocks. The block content is still saved to theย wp_blockย CPT and any changes to the block content are reflected across all instances of the block. This default behavior of the Pattern block is referred to in the UI as โsyncedโ.
The Pattern block also has a second option in 6.3 which is โunsyncedโ. When โunsyncedโ, the block will behave the same as the existing theme and plugin patterns, i.e. the patterns blocks will be inserted as standalone blocks, and any edits affect only that instance.
In order to track the synced and unsynced status, a new postmeta field has been registered for theย wp_blockย CPT calledย wp_pattern_sync_status. If this postmeta field is undefined, the pattern is considered synced, and if the pattern is unsynced, this will be set toย unsynced. Because this is a coreCoreCore is the set of software required to run WordPress. The Core Development Team builds WordPress. field, it is exposed as a top-level field in the REST APIREST APIThe REST API is an acronym for the RESTful Application Program Interface (API) that uses HTTP requests to GET, PUT, POST and DELETE data. It is how the front end of an application (think โphone appโ or โwebsiteโ) can communicate with the data store (think โdatabaseโ or โfile systemโ)
https://developer.wordpress.org/rest-api/ instead of aย metaMetaMeta 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.ย property, so it will appear on theย wp_blockย asย entity.wp_sync_status.
Because the synced Patterns do not require the new postmeta field, we donโt anticipate any impact on plugins that may modify the existing reusable block behavior. The only impact we anticipate is on any plugins that manipulate the DOM based on selectors that depend on the textย Reusable block(s)ย existing in the UI. These selectors would need to be adjusted to expect the textย Patternย instead.
In WordPress 6.2, we introduced a new modal for creating templates. This modal presents the option to start a new template from a โblankโ state or use the current fallback of the template. In WordPress 6.3, we expanded this modalโs functionality to display patterns that are suitable for a given template.
For a pattern to appear in the modal, it needs to specify a property called templateTypes, which is an array containing the templates where the patterns can be used as the full content.
Hereโs an example that demonstrates adding a pattern to the start of a 404 template:
You must be logged in to post a comment.