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.
deleted the statement about the anchorRef,ย anchorRect,ย getAnchorRect and __unstableShift props being scheduled for removal in the Popover component. The related deprecation messaged will be updated in the WordPress 6.1.1 release;
deleted the statement about the useAnchorRef hook being scheduled for removal. The related deprecation messaged will be updated in the WordPress 6.1.1 release;
added a statement about the removal of the range prop in the Popover component.
Changes to the Popover component
Theย Popoverย component from theย @wordpress/componentsย package has been almost entirely rewritten, in an effort to make it more stable, more reliable and more performant.
Below is a list with the main 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. changes:
a newย placementย prop has been introduced. This prop is meant to replace the legacyย positionย prop (which will be marked as deprecated in the near future);
a newย anchorย prop has been introduced. This prop is meant to replace all previous anchor-related props (anchorRef,ย anchorRect,ย getAnchorRect). These older anchor-related props are now marked as deprecated;
theย __unstableForcePositionย prop has been marked as deprecated, in favor of newย flipย andย resizeย props. Theย __unstableForcePositionย is currently scheduled for removal in WordPress 6.3;
theย __unstableObserveElementย prop has been removed, since itโs not necessary anymore after the recent updates to theย Popover;
the range prop has been removed, as it hasnโt been having any effects on the component for a while.
The changes to theย Popoverย component also affected theย @wordpress/rich-text package, where a newย useAnchorย hook was introduced. The olderย useAnchorRefย hook has been marked as deprecated.
Preparing CustomSelectControl to take up the entire width of its parent.
To improve consistency withย SelectControl, the CSSCSSCascading Style Sheets. styles forย CustomSelectControlย will be changed to take up the full width available, regardless of how short the option strings are. To start opting into these new unconstrained width styles, set theย __nextUnconstrainedWidthย prop toย true. These styles will become the default in 6.4.
To keep yourย CustomSelectControlย similar to the previous styling, add width constraints to a wrapper div.
Props toย @0mirka00ย for writing thisย 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..ย (top)
Components with deprecated margin styles.
Several UIUIUser interface components currently ship with styles that give them top and/or bottom margins. This can make it hard to reuse them in arbitrary layouts, where you want different amounts of gap or margin between components.
To better suit modern layout needs, we will gradually deprecate these outer margins. A deprecation will begin with an opt-in period where you can choose to apply the new margin-free styles on a given component instance. Eventually in a future version, the margins will be completely removed.
In WordPress 6.1, the outer margins on the following components have been deprecated.
AnglePickerControl
FontSizePicker
GradientPicker
CustomGradientPicker
To start opting into the new margin-free styles, set theย __nextHasNoMarginBottomย prop toย true.