Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Template Loader: Add theme block template resolution. #18247
This PR follows the template loader work to support resolving theme block templates from a new
A theme block template is an HTML file named after the relevant template from the template hierarchy and it contains the serialized block content for the template.
The logic for resolving them is as follows:
After finding a suitable
Note that it's "higher priority" and not "higher or equal priority". Between a
"Using it" means creating a temporary auto-draft so that the rest of the template loading logic works as expected and so that the user can eventually make changes and persist them in a
How has this been tested?
It was verified that
Types of Changes
New Feature: Themes can now register block templates for the dynamic template hierarchy.
…rnmobile/gb-mobile-872-JSApplicationIllegalArgumentException-in-RCTAztecView * 'master' of https://github.com/WordPress/gutenberg: (56 commits) Update: Default gradients. (#18214) Fix: setting a preset color on pullquote default style makes the block invalid (#18194) Fix default featured image size (#15844) Fix postmeta radio regression. (#18183) Components: Switch screen-reader-text to VisuallyHidden (#18165) [rnmobile] Release 1.16.0 to master (#18261) Template Loader: Add theme block template resolution. (#18247) Add a README file for storybook directory (#18245) Add editor-gradient-presets to get_theme_support (#17841) Add "Image Title Attribute" as an editable attribute on the image block (#11070) enables horizontal movers in social blocks (#18234) [RNMobile] Add mobile Spacer component (#17896) Add experimental `ResponsiveBlockControl` component (#16790) Fix mover for floats. (#18230) Rename Component to WPComponent in docstring (#18226) Colors Selector: replace `Aa` text by SVG icon (#18222) Removed gif from README (#18200) makes the submenu items stacked vertically (#18221) Add block navigator to sidebar panel for nav block (#18202) Fix: consecutive updates may trigger a blocks reset (#18219) ...
* Template Loader: Add theme block template resolution. * Apply suggestions from code review Co-Authored-By: Weston Ruter <email@example.com> * Template Loader: Add missing `isset`. * Template Loader: Only create auto-draft of block template for editing in admin screens.