Skip to content

Commit 748e769

Browse files
Merge branch 'trunk' into feature/instant-search-default-query
2 parents d83ec89 + 0154339 commit 748e769

File tree

216 files changed

+2664
-2444
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

216 files changed

+2664
-2444
lines changed

.github/workflows/rnmobile-android-runner.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
uses: ./.github/setup-node
3838

3939
- name: Restore tests setup cache
40-
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
40+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
4141
with:
4242
path: |
4343
~/.appium
@@ -52,7 +52,7 @@ jobs:
5252
# AVD cache disabled as it caused emulator termination to hang indefinitely.
5353
# https://github.com/ReactiveCircus/android-emulator-runner/issues/385
5454
# - name: AVD cache
55-
# uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
55+
# uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
5656
# id: avd-cache
5757
# with:
5858
# path: |

.github/workflows/rnmobile-ios-runner.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
uses: ./.github/setup-node
4343

4444
- name: Restore tests setup cache
45-
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
45+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
4646
with:
4747
path: |
4848
~/.appium
@@ -55,15 +55,15 @@ jobs:
5555
run: find package-lock.json packages/react-native-editor/ios packages/react-native-aztec/ios packages/react-native-bridge/ios -type f -print0 | sort -z | xargs -0 shasum | tee ios-checksums.txt
5656

5757
- name: Restore build cache
58-
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
58+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
5959
with:
6060
path: |
6161
packages/react-native-editor/ios/build/GutenbergDemo/Build/Products/Release-iphonesimulator/GutenbergDemo.app
6262
packages/react-native-editor/ios/build/WDA
6363
key: ${{ runner.os }}-ios-build-${{ matrix.xcode }}-${{ matrix.device }}-${{ hashFiles('ios-checksums.txt') }}
6464

6565
- name: Restore pods cache
66-
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
66+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
6767
with:
6868
path: |
6969
packages/react-native-editor/ios/Pods

.github/workflows/unit-test.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ jobs:
296296
run: echo "date=$(/bin/date -u --date='last Mon' "+%F")" >> $GITHUB_OUTPUT
297297

298298
- name: Cache PHPCS scan cache
299-
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
299+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
300300
with:
301301
path: .cache/phpcs.json
302302
key: ${{ runner.os }}-date-${{ steps.get-date.outputs.date }}-phpcs-cache-${{ hashFiles('**/composer.json', 'phpcs.xml.dist') }}

backport-changelog/6.8/7069.md

+1
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ https://github.com/WordPress/wordpress-develop/pull/7069
33
* https://github.com/WordPress/gutenberg/pull/63401
44
* https://github.com/WordPress/gutenberg/pull/66918
55
* https://github.com/WordPress/gutenberg/pull/67018
6+
* https://github.com/WordPress/gutenberg/pull/67552

backport-changelog/6.8/7976.md

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
https://github.com/WordPress/wordpress-develop/pull/7976
2+
3+
* https://github.com/WordPress/gutenberg/pull/67716

docs/contributors/code/e2e/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ To encourage better practices for querying elements, selectors are [strict](http
7575

7676
### Favor Page Object Model over utils
7777

78-
As mentioned above, [Page Object Model](https://playwright.dev/docs/test-pom) is the preferred way to create reusable utility functions on a certain page.
78+
As mentioned above, [Page Object Model](https://playwright.dev/docs/pom) is the preferred way to create reusable utility functions on a certain page.
7979

8080
The rationale behind using a POM is to group utils under namespaces to be easier to discover and use. In fact, `PageUtils` in the `e2e-test-utils-playwright` package is also a POM, which avoids the need for global variables, and utils can reference each other with `this`.
8181

docs/reference-guides/core-blocks.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@ Contains the block elements used to render a post, like the title, date, feature
660660

661661
- **Name:** core/post-template
662662
- **Category:** theme
663-
- **Parent:** core/query
663+
- **Ancestor:** core/query
664664
- **Supports:** align (full, wide), color (background, gradients, link, text), interactivity (clientNavigation), layout, spacing (blockGap), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
665665

666666
## Post Terms
@@ -724,7 +724,7 @@ Contains the block elements used to render content when no query results are fou
724724

725725
- **Name:** core/query-no-results
726726
- **Category:** theme
727-
- **Parent:** core/query
727+
- **Ancestor:** core/query
728728
- **Supports:** align, color (background, gradients, link, text), interactivity (clientNavigation), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
729729

730730
## Pagination

lib/class-wp-theme-json-gutenberg.php

+2
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,8 @@ public function get_settings() {
13191319
* - `variables`: only the CSS Custom Properties for presets & custom ones.
13201320
* - `styles`: only the styles section in theme.json.
13211321
* - `presets`: only the classes for the presets.
1322+
* - `base-layout-styles`: only the base layout styles.
1323+
* - `custom-css`: only the custom CSS.
13221324
* @param array $origins A list of origins to include. By default it includes VALID_ORIGINS.
13231325
* @param array $options An array of options for now used for internal purposes only (may change without notice).
13241326
* The options currently supported are:

lib/compat/wordpress-6.8/blocks.php

+15-10
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ function gutenberg_stabilize_experimental_block_supports( $args ) {
7171
}
7272

7373
$stabilize_config = function ( $unstable_config, $stable_support_key ) use ( $experimental_support_properties, $common_experimental_properties ) {
74+
if ( ! is_array( $unstable_config ) ) {
75+
return $unstable_config;
76+
}
77+
7478
$stable_config = array();
7579
foreach ( $unstable_config as $key => $value ) {
7680
// Get stable key from support-specific map, common properties map, or keep original.
@@ -116,18 +120,19 @@ function gutenberg_stabilize_experimental_block_supports( $args ) {
116120
( $key_positions[ $support ] ?? PHP_INT_MAX ) <
117121
( $key_positions[ $stable_support_key ] ?? PHP_INT_MAX );
118122

119-
if ( is_array( $args['supports'][ $stable_support_key ] ) ) {
120-
/*
121-
* To merge the alternative support config effectively, it also needs to be
122-
* stabilized before merging to keep stabilized and experimental flags in
123-
* sync.
124-
*/
125-
$args['supports'][ $stable_support_key ] = $stabilize_config( $args['supports'][ $stable_support_key ], $stable_support_key );
126-
$stable_config = $experimental_first
123+
/*
124+
* To merge the alternative support config effectively, it also needs to be
125+
* stabilized before merging to keep stabilized and experimental flags in
126+
* sync.
127+
*/
128+
$args['supports'][ $stable_support_key ] = $stabilize_config( $args['supports'][ $stable_support_key ], $stable_support_key );
129+
// Prevents reprocessing this support as it was stabilized above.
130+
$done[ $stable_support_key ] = true;
131+
132+
if ( is_array( $stable_config ) && is_array( $args['supports'][ $stable_support_key ] ) ) {
133+
$stable_config = $experimental_first
127134
? array_merge( $stable_config, $args['supports'][ $stable_support_key ] )
128135
: array_merge( $args['supports'][ $stable_support_key ], $stable_config );
129-
// Prevents reprocessing this support as it was merged above.
130-
$done[ $stable_support_key ] = true;
131136
} else {
132137
$stable_config = $experimental_first
133138
? $args['supports'][ $stable_support_key ]

lib/experimental/blocks.php

+19
Original file line numberDiff line numberDiff line change
@@ -179,3 +179,22 @@ function gutenberg_block_core_query_add_search_query_filtering( $query ) {
179179
'pre_get_posts',
180180
'gutenberg_block_core_query_add_search_query_filtering'
181181
);
182+
183+
/**
184+
* Additional data to expose to the view script module in the Form block.
185+
*/
186+
function gutenberg_block_core_form_view_script_module( $data ) {
187+
if ( ! gutenberg_is_experiment_enabled( 'gutenberg-form-blocks' ) ) {
188+
return $data;
189+
}
190+
191+
$data['nonce'] = wp_create_nonce( 'wp-block-form' );
192+
$data['ajaxUrl'] = admin_url( 'admin-ajax.php' );
193+
$data['action'] = 'wp_block_form_email_submit';
194+
195+
return $data;
196+
}
197+
add_filter(
198+
'script_module_data_@wordpress/block-library/form/view',
199+
'gutenberg_block_core_form_view_script_module'
200+
);

lib/global-styles-and-settings.php

+3-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* Returns the stylesheet resulting of merging core, theme, and user data.
1010
*
1111
* @param array $types Types of styles to load. Optional.
12-
* It accepts as values: 'variables', 'presets', 'styles', 'base-layout-styles.
12+
* See {@see 'WP_Theme_JSON::get_stylesheet'} for all valid types.
1313
* If empty, it'll load the following:
1414
* - for themes without theme.json: 'variables', 'presets', 'base-layout-styles'.
1515
* - for themes with theme.json: 'variables', 'presets', 'styles'.
@@ -142,6 +142,8 @@ function gutenberg_get_global_settings( $path = array(), $context = array() ) {
142142
/**
143143
* Gets the global styles custom css from theme.json.
144144
*
145+
* @deprecated Gutenberg 18.6.0 Use {@see 'gutenberg_get_global_stylesheet'} instead for top-level custom CSS, or {@see 'WP_Theme_JSON_Gutenberg::get_styles_for_block'} for block-level custom CSS.
146+
*
145147
* @return string
146148
*/
147149
function gutenberg_get_global_styles_custom_css() {

0 commit comments

Comments
 (0)