Skip to content

Commit db2a19a

Browse files
release: fixes
- Fixed Navigation block error - Fixed Starter Sites loading and the problem with saving in the template cloud
2 parents a1fc7b9 + ebecb8f commit db2a19a

File tree

10 files changed

+51
-21
lines changed

10 files changed

+51
-21
lines changed

.github/workflows/test-php.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Setup PHP version
1717
uses: shivammathur/setup-php@v1
1818
with:
19-
php-version: '7.1'
19+
php-version: '7.4'
2020
extensions: simplexml
2121
tools: composer:v2.1
2222
- name: Checkout source code
@@ -52,7 +52,7 @@ jobs:
5252
- name: Setup PHP version
5353
uses: shivammathur/setup-php@v2
5454
with:
55-
php-version: '7.1'
55+
php-version: '7.4'
5656
extensions: simplexml, mysql
5757
tools: phpunit-polyfills
5858
- name: Checkout source code

bin/e2e-env.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ init_environment(){
3434
# Install dependent plugins
3535
docker-compose -f $DOCKER_FILE run --rm -u root cli wp --allow-root plugin install --force --activate otter-blocks
3636
docker-compose -f $DOCKER_FILE run --rm -u root cli wp --allow-root plugin install --force --activate optimole-wp
37+
38+
# Disable Neve Onboarding
39+
docker-compose -f $DOCKER_FILE run --rm -u root cli wp --allow-root config set TI_ONBOARDING_DISABLED true --raw
40+
41+
# Disable Otter Onboarding
42+
docker-compose -f $DOCKER_FILE run --rm -u root cli wp --allow-root config set ENABLE_OTTER_PRO_DEV true --raw
3743
}
3844

3945
docker-compose -f $DOCKER_FILE run --rm -u root wordpress mkdir -p /var/www/html/wp-content/uploads

composer.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
describe( 'Gutenberg Editor', () => {
2+
beforeEach(() => {
3+
cy.visit('/');
4+
cy.visit('/wp-admin/post-new.php');
5+
});
6+
7+
it( 'Add a navigation block', () => {
8+
cy.intercept({
9+
method: 'OPTIONS',
10+
url: '/wp-json/wp/v2/navigation/**'
11+
}).as('getNavigation');
12+
13+
cy.window().then( win => {
14+
const navBlock = win.wp.blocks.createBlock( 'core/navigation' );
15+
win.wp.data.dispatch( 'core/block-editor' ).insertBlocks( navBlock ).then(() => {
16+
cy.wait('@getNavigation') // Wait for navigation to pull its data.
17+
.then(() => {
18+
// We should have no rendering warning.
19+
cy.get('.block-editor-warning__message').should('not.exist');
20+
});
21+
})
22+
} );
23+
} );
24+
});

editor/src/plugins/site-editor-extension.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import {
1010
TextControl,
1111
} from '@wordpress/components';
1212
import { useDispatch, useSelect } from '@wordpress/data';
13-
import { PluginSidebar, PluginSidebarMoreMenuItem } from '@wordpress/edit-site';
13+
import { PluginSidebar, PluginSidebarMoreMenuItem } from '@wordpress/edit-post';
1414
import { Fragment, useEffect, useState } from '@wordpress/element';
1515
import { store as coreStore } from '@wordpress/core-data';
1616
import api from '@wordpress/api';

includes/Admin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -634,7 +634,7 @@ public function enqueue() {
634634
wp_style_add_data( 'tiobObd', 'rtl', 'replace' );
635635
wp_enqueue_style( 'tiobObd' );
636636

637-
wp_register_script( 'tiobObd', TIOB_URL . 'onboarding/build/index.js', array_merge( $onboarding_dependencies['dependencies'], array( 'updates' ) ), $onboarding_dependencies['version'], true );
637+
wp_register_script( 'tiobObd', TIOB_URL . 'onboarding/build/index.js', array_merge( $onboarding_dependencies['dependencies'], array( 'updates', 'regenerator-runtime' ) ), $onboarding_dependencies['version'], true );
638638
wp_localize_script( 'tiobObd', 'tiobDash', apply_filters( 'neve_dashboard_page_data', $this->get_localization() ) );
639639
wp_enqueue_script( 'tiobObd' );
640640

@@ -667,7 +667,7 @@ public function enqueue() {
667667
wp_style_add_data( 'tiob', 'rtl', 'replace' );
668668
wp_enqueue_style( 'tiob' );
669669

670-
wp_register_script( 'tiob', TIOB_URL . 'assets/build/app.js', array_merge( $dependencies['dependencies'], array( 'updates' ) ), $dependencies['version'], true );
670+
wp_register_script( 'tiob', TIOB_URL . 'assets/build/app.js', array_merge( $dependencies['dependencies'], array( 'updates', 'regenerator-runtime' ) ), $dependencies['version'], true );
671671
$tiob_dash = apply_filters( 'neve_dashboard_page_data', $this->get_localization() );
672672
if ( $is_tiob_page ) {
673673
$tiob_dash['hideStarterSites'] = true;

includes/Editor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ public function register_block() {
7171
wp_register_script(
7272
$this->handle,
7373
TIOB_URL . 'editor/build/index.js',
74-
array_merge( $deps['dependencies'], array( 'wp-api' ) ),
74+
array_merge( $deps['dependencies'], array( 'wp-api', 'regenerator-runtime' ) ),
7575
$deps['version']
7676
);
7777

tests/digital-test.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public static function wpSetUpBeforeClass( $factory ) {
4141
/**
4242
* setUp
4343
*/
44-
public function setUp() {
44+
public function setUp(): void {
4545
parent::setUp();
4646
wp_set_current_user( self::$admin_id );
4747
add_theme_support(

tests/import-test.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*/
1515
class Import_Test extends WP_UnitTestCase {
1616

17-
public function setUp() {
17+
public function setUp(): void {
1818
parent::setUp();
1919
register_taxonomy(
2020
'product_type',

tests/rest-test.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public static function wpSetUpBeforeClass( $factory ) {
4040
/**
4141
* setUp
4242
*/
43-
public function setUp() {
43+
public function setUp(): void {
4444
parent::setUp();
4545
wp_set_current_user( self::$admin_id );
4646
add_theme_support( 'themeisle-demo-import', [

0 commit comments

Comments
 (0)