Skip to content

Commit

Permalink
Merge pull request ampproject#7816 from ampproject/update/wp-deps
Browse files Browse the repository at this point in the history
Bump minimum required WP to 6.3
  • Loading branch information
thelovekesh authored Jun 24, 2024
2 parents 22012c5 + f508f83 commit fa0a9f2
Show file tree
Hide file tree
Showing 131 changed files with 6,072 additions and 7,657 deletions.
2 changes: 2 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,8 @@ module.exports = {
'jest/prefer-expect-assertions': 'off',
'jest/prefer-inline-snapshots': 'off',
'jest/unbound-method': 'off',
// Disabling because it's not the Jest environment.
'jest/prefer-importing-jest-globals': 'off',
},
},
{
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build-test-measure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -328,11 +328,11 @@ jobs:
external-http: true

- php: '7.4'
wp: '5.3'
wp: '6.3'
phpunit: '7'

- php: '7.4'
wp: '5.3'
wp: '6.3'
phpunit: '7'
external-http: true
steps:
Expand Down Expand Up @@ -507,7 +507,7 @@ jobs:
wp: 'latest'

- php: '7.4'
wp: '5.3'
wp: '6.3'
steps:
- name: Shutdown default MySQL service
if: needs.pre-run.outputs.changed-php-count > 0
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ node_modules

/vendor
/build
/artifacts
/wiki
/amp.zip
/assets/css/*
Expand Down
1 change: 0 additions & 1 deletion .phpcs.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

<!-- @TODO(P0): Fix these once WPCS is merged on develop and remove the exclusions. -->
<exclude name="PSR2.Methods.FunctionClosingBrace.SpacingBeforeClose" />
<exclude name="WordPress.Security.EscapeOutput.OutputNotEscaped" />
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.SpaceAfterFunction" />
<exclude name="Universal.NamingConventions.NoReservedKeywordParameterNames.stringFound" />
<exclude name="PSR2.Files.EndFileNewline.TooMany" />
Expand Down
1 change: 0 additions & 1 deletion .phpstorm.meta.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
'admin.amp_themes' => \AmpProject\AmpWP\Admin\AmpThemes::class,
'amp_slug_customization_watcher' => \AmpProject\AmpWP\AmpSlugCustomizationWatcher::class,
'background_task_deactivator' => \AmpProject\AmpWP\BackgroundTask\BackgroundTaskDeactivator::class,
'block_uniqid_transformer' => \AmpProject\AmpWP\BlockUniqidTransformer::class,
'cli.command_namespace' => \AmpProject\AmpWP\Cli\CommandNamespaceRegistration::class,
'cli.optimizer_command' => \AmpProject\AmpWP\Cli\OptimizerCommand::class,
'cli.transformer_command' => \AmpProject\AmpWP\Cli\TransformerCommand::class,
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ An easier path to great Page Experience for everyone. Powered by AMP.

**Contributors:** [google](https://profiles.wordpress.org/google), [xwp](https://profiles.wordpress.org/xwp), [rtcamp](https://profiles.wordpress.org/rtcamp), [automattic](https://profiles.wordpress.org/automattic), [westonruter](https://profiles.wordpress.org/westonruter), [albertomedina](https://profiles.wordpress.org/albertomedina), [schlessera](https://profiles.wordpress.org/schlessera), [delawski](https://profiles.wordpress.org/delawski/), [swissspidy](https://profiles.wordpress.org/swissspidy), [pierlo](https://profiles.wordpress.org/pierlo), [joshuawold](https://profiles.wordpress.org/joshuawold), [thelovekesh](https://profiles.wordpress.org/thelovekesh/)
**Tags:** [page experience](https://wordpress.org/plugins/tags/page-experience), [performance](https://wordpress.org/plugins/tags/performance), [amp](https://wordpress.org/plugins/tags/amp), [mobile](https://wordpress.org/plugins/tags/mobile), [optimization](https://wordpress.org/plugins/tags/optimization)
**Requires at least:** 5.3
**Requires at least:** 6.3
**Tested up to:** 6.5
**Stable tag:** 2.5.3
**License:** [GPLv2 or later](http://www.gnu.org/licenses/gpl-2.0.html)
Expand Down
2 changes: 1 addition & 1 deletion amp.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* Author URI: https://github.com/ampproject/amp-wp/graphs/contributors
* Version: 2.5.4-alpha
* License: GPLv2 or later
* Requires at least: 5.3
* Requires at least: 6.3
* Requires PHP: 7.4
*
* @package AMP
Expand Down
11 changes: 3 additions & 8 deletions assets/src/block-editor/components/amp-preview-button.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ import { __ } from '@wordpress/i18n';
* Internal dependencies
*/
import { isAMPEnabled } from '../helpers';
import ampFilledIcon from '../../../images/amp-icon.svg';
import ampBlackIcon from '../../../images/amp-black-icon.svg';
import { AMPFilledIcon, AMPBlackIcon } from '../../icons';

/**
* Writes the message and graphic in the new preview window that was opened.
Expand All @@ -30,7 +29,7 @@ import ampBlackIcon from '../../../images/amp-black-icon.svg';
function writeInterstitialMessage(targetDocument) {
let markup = renderToString(
<div className="editor-post-preview-button__interstitial-message">
<Icon icon={ampBlackIcon({ viewBox: '0 0 98 98' })} />
<Icon icon={<AMPBlackIcon viewBox="0 0 98 98" />} />
<p>{__('Generating AMP preview…', 'amp')}</p>
</div>
);
Expand Down Expand Up @@ -231,11 +230,7 @@ class AmpPreviewButton extends Component {
onClick={this.openPreviewWindow}
ref={this.buttonRef}
>
{ampFilledIcon({
viewBox: '0 0 62 62',
width: 18,
height: 18,
})}
<AMPFilledIcon viewBox="0 0 62 62" height={18} width={18} />
<VisuallyHidden as="span">
{
/* translators: accessibility text */
Expand Down
5 changes: 5 additions & 0 deletions assets/src/block-editor/helpers/test/addAMPAttributes.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
/**
* External dependencies
*/
import { describe, expect, it } from '@jest/globals';

/**
* Internal dependencies
*/
Expand Down
5 changes: 5 additions & 0 deletions assets/src/block-editor/store/test/selectors.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
/**
* External dependencies
*/
import { describe, expect, it } from '@jest/globals';

/**
* Internal dependencies
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ import { useDispatch, useSelect } from '@wordpress/data';
/**
* Internal dependencies
*/
import AMPValidationErrorsKeptIcon from '../../../../images/amp-validation-errors-kept.svg';
import BellIcon from '../../../../images/bell-icon.svg';
import { BellIcon, AMPValidationErrorsKeptIcon } from '../../../icons';
import { store as blockValidationStore } from '../../store';
import { StatusIcon } from '../icon';
import { SidebarNotification } from '../sidebar-notification';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* External dependencies
*/
import { render, fireEvent } from '@testing-library/react';
import { beforeAll, describe, expect, it, jest } from '@jest/globals';

/**
* WordPress dependencies
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* External dependencies
*/
import { render, fireEvent } from '@testing-library/react';
import { beforeEach, describe, expect, it, jest } from '@jest/globals';

/**
* Internal dependencies
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { useDispatch, useSelect } from '@wordpress/data';
* Internal dependencies
*/
import { store as blockValidationStore } from '../../store';
import BellIcon from '../../../../images/bell-icon.svg';
import { BellIcon } from '../../../icons';
import { SidebarNotification } from '../sidebar-notification';
import { useErrorsFetchingStateChanges } from '../../hooks/use-errors-fetching-state-changes';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { useDispatch, useSelect } from '@wordpress/data';
/**
* Internal dependencies
*/
import AMPValidationErrorsKeptIcon from '../../../../images/amp-validation-errors-kept.svg';
import { AMPValidationErrorsKeptIcon } from '../../../icons';
import { store as blockValidationStore } from '../../store';
import { StatusIcon } from '../icon';
import { SidebarNotification } from '../sidebar-notification';
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit fa0a9f2

Please sign in to comment.