From e5f7e9561d8bdf190e68759a054596dd4a7d7376 Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Wed, 6 Oct 2021 18:34:02 -0600 Subject: [PATCH 01/10] Scaffold empty search package --- projects/packages/search/.gitattributes | 9 ++++ projects/packages/search/.gitignore | 1 + projects/packages/search/CHANGELOG.md | 6 +++ projects/packages/search/changelog/.gitkeep | 0 projects/packages/search/composer.json | 48 +++++++++++++++++++ projects/packages/search/phpunit.xml.dist | 16 +++++++ projects/packages/search/src/.gitkeep | 0 .../packages/search/tests/php/bootstrap.php | 11 +++++ 8 files changed, 91 insertions(+) create mode 100644 projects/packages/search/.gitattributes create mode 100644 projects/packages/search/.gitignore create mode 100644 projects/packages/search/CHANGELOG.md create mode 100644 projects/packages/search/changelog/.gitkeep create mode 100644 projects/packages/search/composer.json create mode 100644 projects/packages/search/phpunit.xml.dist create mode 100644 projects/packages/search/src/.gitkeep create mode 100644 projects/packages/search/tests/php/bootstrap.php diff --git a/projects/packages/search/.gitattributes b/projects/packages/search/.gitattributes new file mode 100644 index 0000000000000..44b456cb4a390 --- /dev/null +++ b/projects/packages/search/.gitattributes @@ -0,0 +1,9 @@ +# Files not needed to be distributed. +.gitattributes export-ignore +.github/ export-ignore +.gitignore export-ignore +phpunit.xml.dist export-ignore +tests/ export-ignore + +# Files not needed in the production build. +/changelog/** production-exclude diff --git a/projects/packages/search/.gitignore b/projects/packages/search/.gitignore new file mode 100644 index 0000000000000..554806723c0e3 --- /dev/null +++ b/projects/packages/search/.gitignore @@ -0,0 +1 @@ +wordpress diff --git a/projects/packages/search/CHANGELOG.md b/projects/packages/search/CHANGELOG.md new file mode 100644 index 0000000000000..03a962f457f66 --- /dev/null +++ b/projects/packages/search/CHANGELOG.md @@ -0,0 +1,6 @@ +# Changelog + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). diff --git a/projects/packages/search/changelog/.gitkeep b/projects/packages/search/changelog/.gitkeep new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/projects/packages/search/composer.json b/projects/packages/search/composer.json new file mode 100644 index 0000000000000..1bd73e9034eeb --- /dev/null +++ b/projects/packages/search/composer.json @@ -0,0 +1,48 @@ +{ + "name": "automattic/jetpack-search", + "description": "Tools to assist with enabling cloud search for Jetpack sites.", + "type": "library", + "license": "GPL-2.0-or-later", + "require": {}, + "require-dev": { + "automattic/jetpack-changelogger": "^2.0", + "yoast/phpunit-polyfills": "1.0.1" + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "scripts": { + "phpunit": [ + "./vendor/phpunit/phpunit/phpunit --colors=always" + ], + "test-coverage": [ + "@composer install", + "phpdbg -d memory_limit=2048M -d max_execution_time=900 -qrr ./vendor/bin/phpunit --coverage-clover \"$COVERAGE_DIR/clover.xml\"" + ], + "test-php": [ + "@composer install", + "@composer phpunit" + ], + "post-update-cmd": "php -r \"copy('vendor/automattic/wordbless/src/dbless-wpdb.php', 'wordpress/wp-content/db.php');\"" + }, + "repositories": [ + { + "type": "path", + "url": "../*", + "options": { + "monorepo": true + } + } + ], + "minimum-stability": "dev", + "prefer-stable": true, + "extra": { + "autotagger": true, + "mirror-repo": "Automattic/jetpack-search", + "changelogger": { + "link-template": "https://github.com/Automattic/jetpack-search/compare/v${old}...v${new}" + } + } +} diff --git a/projects/packages/search/phpunit.xml.dist b/projects/packages/search/phpunit.xml.dist new file mode 100644 index 0000000000000..47e186dc3d76a --- /dev/null +++ b/projects/packages/search/phpunit.xml.dist @@ -0,0 +1,16 @@ + + + + tests/php + + + + + . + + tests + vendor + + + + diff --git a/projects/packages/search/src/.gitkeep b/projects/packages/search/src/.gitkeep new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/projects/packages/search/tests/php/bootstrap.php b/projects/packages/search/tests/php/bootstrap.php new file mode 100644 index 0000000000000..f0a3c79976611 --- /dev/null +++ b/projects/packages/search/tests/php/bootstrap.php @@ -0,0 +1,11 @@ + Date: Thu, 7 Oct 2021 16:16:23 -0600 Subject: [PATCH 02/10] Move Helper and Options classes into Search package --- projects/packages/search/src/.gitkeep | 0 .../search/src/class-helper.php} | 78 +++++++++---------- .../search/src/class-options.php} | 4 +- .../search/class-jetpack-instant-search.php | 30 +++---- .../class-jetpack-search-customberg.php | 5 +- .../search/class-jetpack-search-customize.php | 27 +++---- .../search/class-jetpack-search-settings.php | 4 +- .../class.jetpack-search-template-tags.php | 2 + .../modules/search/class.jetpack-search.php | 6 +- .../class-excluded-post-types-control.php | 3 +- .../class-label-control.php | 3 +- .../jetpack/modules/widgets/search.php | 5 +- .../test-class-jetpack-instant-search.php | 2 - .../test-class.jetpack-search-helpers.php | 5 +- 14 files changed, 85 insertions(+), 89 deletions(-) delete mode 100644 projects/packages/search/src/.gitkeep rename projects/{plugins/jetpack/modules/search/class.jetpack-search-helpers.php => packages/search/src/class-helper.php} (92%) rename projects/{plugins/jetpack/modules/search/class-jetpack-search-options.php => packages/search/src/class-options.php} (97%) diff --git a/projects/packages/search/src/.gitkeep b/projects/packages/search/src/.gitkeep deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/projects/plugins/jetpack/modules/search/class.jetpack-search-helpers.php b/projects/packages/search/src/class-helper.php similarity index 92% rename from projects/plugins/jetpack/modules/search/class.jetpack-search-helpers.php rename to projects/packages/search/src/class-helper.php index f6866b33bcdf6..76ea607f65dfc 100644 --- a/projects/plugins/jetpack/modules/search/class.jetpack-search-helpers.php +++ b/projects/packages/search/src/class-helper.php @@ -7,16 +7,17 @@ * @since 5.8.0 */ -use Automattic\Jetpack\Constants; +namespace Automattic\Jetpack\Search; -require_once dirname( __FILE__ ) . '/class-jetpack-search-options.php'; +use GP_Locales; +use Jetpack; /** * Various helper functions for reuse throughout the Jetpack Search code. * * @since 5.8.0 */ -class Jetpack_Search_Helpers { +class Helper { /** * The search widget's base ID. @@ -33,10 +34,10 @@ class Jetpack_Search_Helpers { * * @return string The search URL. */ - static function get_search_url() { + public static function get_search_url() { $query_args = stripslashes_deep( $_GET ); - // Handle the case where a permastruct is being used, such as /search/{$query} + // Handle the case where a permastruct is being used, such as /search/{$query}. if ( ! isset( $query_args['s'] ) ) { $query_args['s'] = get_search_query(); } @@ -63,7 +64,7 @@ static function get_search_url() { * * @return string New URL query string (unescaped). */ - static function add_query_arg( $key, $value = false, $url = false ) { + public static function add_query_arg( $key, $value = false, $url = false ) { $url = empty( $url ) ? self::get_search_url() : $url; if ( is_array( $key ) ) { return add_query_arg( $key, $url ); @@ -80,11 +81,11 @@ static function add_query_arg( $key, $value = false, $url = false ) { * @since 5.8.0 * * @param string|array $key Query key or keys to remove. - * @param bool|string $query Optional. A URL to act upon. Defaults to the current search URL. + * @param bool|string $url Optional. A URL to act upon. Defaults to the current search URL. * * @return string New URL query string (unescaped). */ - static function remove_query_arg( $key, $url = false ) { + public static function remove_query_arg( $key, $url = false ) { $url = empty( $url ) ? self::get_search_url() : $url; return remove_query_arg( $key, $url ); @@ -97,7 +98,7 @@ static function remove_query_arg( $key, $url = false ) { * * @return string The search widget option name. */ - static function get_widget_option_name() { + public static function get_widget_option_name() { return sprintf( 'widget_%s', self::FILTER_WIDGET_BASE ); } @@ -108,10 +109,10 @@ static function get_widget_option_name() { * * @return array The widget options. */ - static function get_widgets_from_option() { + public static function get_widgets_from_option() { $widget_options = get_option( self::get_widget_option_name(), array() ); - // We don't need this + // We don't need this. if ( ! empty( $widget_options ) && isset( $widget_options['_multiwidget'] ) ) { unset( $widget_options['_multiwidget'] ); } @@ -126,7 +127,7 @@ static function get_widgets_from_option() { * * @return string The widget's numeric ID prefixed with the search widget base. */ - static function build_widget_id( $number ) { + public static function build_widget_id( $number ) { return sprintf( '%s-%d', self::FILTER_WIDGET_BASE, $number ); } @@ -141,7 +142,7 @@ static function build_widget_id( $number ) { * * @return bool Whether the widget is active or not. */ - static function is_active_widget( $widget_id ) { + public static function is_active_widget( $widget_id ) { return (bool) is_active_widget( false, $widget_id, self::FILTER_WIDGET_BASE, true ); } @@ -198,7 +199,7 @@ public static function get_filters_from_widgets( $allowed_widget_ids = null ) { * * @return string The filter label. */ - static function get_date_filter_type_name( $type, $is_updated = false ) { + public static function get_date_filter_type_name( $type, $is_updated = false ) { switch ( $type ) { case 'year': $string = ( $is_updated ) @@ -225,7 +226,7 @@ static function get_date_filter_type_name( $type, $is_updated = false ) { * * @return string The suggested filter name. */ - static function generate_widget_filter_name( $widget_filter ) { + public static function generate_widget_filter_name( $widget_filter ) { $name = ''; if ( ! isset( $widget_filter['type'] ) ) { @@ -283,12 +284,12 @@ static function generate_widget_filter_name( $widget_filter ) { * * @return bool */ - static function should_rerun_search_in_customizer_preview() { + public static function should_rerun_search_in_customizer_preview() { // Only update when in a customizer preview and data is being posted. // Check for $_POST removes an extra update when the customizer loads. // // Note: We use $GLOBALS['wp_customize'] here instead of is_customize_preview() to support unit tests. - if ( ! isset( $GLOBALS['wp_customize'] ) || ! $GLOBALS['wp_customize']->is_preview() || empty( $_POST ) ) { + if ( ! isset( $GLOBALS['wp_customize'] ) || ! $GLOBALS['wp_customize']->is_preview() || empty( $_POST ) ) { // phpcs:ignore return false; } @@ -301,12 +302,12 @@ static function should_rerun_search_in_customizer_preview() { * * @since 5.8.0 * - * @param array $array_1 - * @param array $array_2 + * @param array $array_1 The first array. + * @param array $array_2 The second array. * * @return array */ - static function array_diff( $array_1, $array_2 ) { + public static function array_diff( $array_1, $array_2 ) { // If the array counts are the same, then the order doesn't matter. If the count of // $array_1 is higher than $array_2, that's also fine. If the count of $array_2 is higher, // we need to swap the array order though. @@ -316,7 +317,7 @@ static function array_diff( $array_1, $array_2 ) { $array_2 = $temp; } - // Disregard keys + // Disregard keys. return array_values( array_diff( $array_1, $array_2 ) ); } @@ -329,7 +330,7 @@ static function array_diff( $array_1, $array_2 ) { * * @return bool */ - static function post_types_differ_searchable( $post_types ) { + public static function post_types_differ_searchable( $post_types ) { if ( empty( $post_types ) ) { return false; } @@ -349,7 +350,7 @@ static function post_types_differ_searchable( $post_types ) { * * @return bool */ - static function post_types_differ_query( $post_types ) { + public static function post_types_differ_query( $post_types ) { if ( empty( $post_types ) ) { return false; } @@ -379,7 +380,7 @@ static function post_types_differ_query( $post_types ) { * * @return array|false False if the widget wasn't updated, otherwise an array of the Tracks action and widget properties. */ - static function get_widget_tracks_value( $old_value, $new_value ) { + public static function get_widget_tracks_value( $old_value, $new_value ) { $old_value = (array) $old_value; if ( isset( $old_value['_multiwidget'] ) ) { unset( $old_value['_multiwidget'] ); @@ -393,13 +394,13 @@ static function get_widget_tracks_value( $old_value, $new_value ) { $old_keys = array_keys( $old_value ); $new_keys = array_keys( $new_value ); - if ( count( $new_keys ) > count( $old_keys ) ) { // This is the case for a widget being added + if ( count( $new_keys ) > count( $old_keys ) ) { // This is the case for a widget being added. $diff = self::array_diff( $new_keys, $old_keys ); $action = 'widget_added'; $widget = empty( $diff ) || ! isset( $new_value[ $diff[0] ] ) ? false : $new_value[ $diff[0] ]; - } elseif ( count( $old_keys ) > count( $new_keys ) ) { // This is the case for a widget being deleted + } elseif ( count( $old_keys ) > count( $new_keys ) ) { // This is the case for a widget being deleted. $diff = self::array_diff( $old_keys, $new_keys ); $action = 'widget_deleted'; $widget = empty( $diff ) || ! isset( $old_value[ $diff[0] ] ) @@ -417,14 +418,14 @@ static function get_widget_tracks_value( $old_value, $new_value ) { } $old_instance = $old_value[ $key ]; - // First, let's test the keys of each instance + // First, let's test the keys of each instance. $diff = self::array_diff( array_keys( $new_instance ), array_keys( $old_instance ) ); if ( ! empty( $diff ) ) { $widget = $new_instance; break; } - // Next, lets's loop over each value and compare it + // Next, lets's loop over each value and compare it. foreach ( $new_instance as $k => $v ) { if ( is_scalar( $v ) && (string) $v !== (string) $old_instance[ $k ] ) { $widget = $new_instance; @@ -468,7 +469,7 @@ static function get_widget_tracks_value( $old_value, $new_value ) { * * @return array The widget properties. */ - static function get_widget_properties_for_tracks( $widget ) { + public static function get_widget_properties_for_tracks( $widget ) { $sanitized = array(); foreach ( (array) $widget as $key => $value ) { @@ -499,7 +500,7 @@ static function get_widget_properties_for_tracks( $widget ) { * * @return array The filter properties. */ - static function get_filter_properties_for_tracks( $filters ) { + public static function get_filter_properties_for_tracks( $filters ) { if ( empty( $filters ) ) { return $filters; } @@ -579,12 +580,12 @@ public static function remove_active_from_post_type_buckets( $filters ) { * @return string The URL with added post types. */ public static function add_post_types_to_url( $url, $post_types ) { - $url = Jetpack_Search_Helpers::remove_query_arg( 'post_type', $url ); + $url = self::remove_query_arg( 'post_type', $url ); if ( empty( $post_types ) ) { return $url; } - $url = Jetpack_Search_Helpers::add_query_arg( + $url = self::add_query_arg( 'post_type', implode( ',', $post_types ), $url @@ -672,7 +673,7 @@ public static function are_filters_by_widget_disabled() { * @return int */ public static function get_max_posts_per_page() { - return Jetpack_Search_Options::site_has_vip_index() ? 1000 : 100; + return Options::site_has_vip_index() ? 1000 : 100; } /** @@ -683,7 +684,7 @@ public static function get_max_posts_per_page() { * @return int */ public static function get_max_offset() { - return Jetpack_Search_Options::site_has_vip_index() ? 9000 : 1000; + return Options::site_has_vip_index() ? 9000 : 1000; } /** @@ -719,7 +720,6 @@ public static function get_asset_version( $file ) { : JETPACK__VERSION; } - /** * Generates a customizer settings ID for a given post type. * @@ -728,7 +728,7 @@ public static function get_asset_version( $file ) { * @return string $customizer_id Customizer setting ID. */ public static function generate_post_type_customizer_id( $post_type ) { - return Jetpack_Search_Options::OPTION_PREFIX . 'disable_post_type_' . $post_type->name; + return Options::OPTION_PREFIX . 'disable_post_type_' . $post_type->name; } /** @@ -818,7 +818,7 @@ public static function generate_initial_javascript_state() { ); } - $prefix = Jetpack_Search_Options::OPTION_PREFIX; + $prefix = Options::OPTION_PREFIX; $posts_per_page = (int) get_option( 'posts_per_page' ); if ( ( $posts_per_page > 20 ) || ( $posts_per_page <= 0 ) ) { $posts_per_page = 20; @@ -839,7 +839,7 @@ public static function generate_initial_javascript_state() { $excluded_post_types = array(); } - $is_wpcom = defined( 'IS_WPCOM' ) && IS_WPCOM; + $is_wpcom = defined( 'IS_WPCOM' ) && constant( 'IS_WPCOM' ); $is_private_site = '-1' === get_option( 'blog_public' ); $is_jetpack_photon_enabled = method_exists( 'Jetpack', 'is_module_active' ) && Jetpack::is_module_active( 'photon' ); @@ -850,7 +850,7 @@ public static function generate_initial_javascript_state() { 'enableSort' => get_option( $prefix . 'enable_sort', '1' ) === '1', 'highlightColor' => get_option( $prefix . 'highlight_color', '#FFC' ), 'overlayTrigger' => get_option( $prefix . 'overlay_trigger', 'immediate' ), - 'resultFormat' => get_option( $prefix . 'result_format', Jetpack_Search_Options::RESULT_FORMAT_MINIMAL ), + 'resultFormat' => get_option( $prefix . 'result_format', Options::RESULT_FORMAT_MINIMAL ), 'showPoweredBy' => get_option( $prefix . 'show_powered_by', '1' ) === '1', // These options require kicking off a new search. diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-search-options.php b/projects/packages/search/src/class-options.php similarity index 97% rename from projects/plugins/jetpack/modules/search/class-jetpack-search-options.php rename to projects/packages/search/src/class-options.php index bc8874fff7316..573350a6a9ab4 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-search-options.php +++ b/projects/packages/search/src/class-options.php @@ -7,6 +7,8 @@ * @since 8.3.0 */ +namespace Automattic\Jetpack\Search; + use Automattic\Jetpack\Constants; /** @@ -14,7 +16,7 @@ * * @since 8.3.0 */ -class Jetpack_Search_Options { +class Options { /** * The search widget's base ID. diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-instant-search.php b/projects/plugins/jetpack/modules/search/class-jetpack-instant-search.php index 04624e3b5c85d..488a75e5f2c99 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-instant-search.php +++ b/projects/plugins/jetpack/modules/search/class-jetpack-instant-search.php @@ -6,6 +6,8 @@ * @package automattic/jetpack */ +use Automattic\Jetpack\Search; + /** * Class to load Instant Search experience on the site. * @@ -81,7 +83,7 @@ public function init_hooks() { add_action( 'init', array( $this, 'set_filters_from_widgets' ) ); add_action( 'wp_enqueue_scripts', array( $this, 'load_assets' ) ); - add_action( 'wp_footer', array( 'Jetpack_Search_Helpers', 'print_instant_search_sidebar' ) ); + add_action( 'wp_footer', array( 'Automattic\Jetpack\Search\Helper', 'print_instant_search_sidebar' ) ); add_filter( 'body_class', array( $this, 'add_body_class' ), 10 ); } else { add_action( 'update_option', array( $this, 'track_widget_updates' ), 10, 3 ); @@ -121,7 +123,7 @@ public function load_assets_with_parameters( $path_prefix, $plugin_base_path ) { return; } - $script_version = Jetpack_Search_Helpers::get_asset_version( $script_relative_path ); + $script_version = Search\Helper::get_asset_version( $script_relative_path ); $script_path = plugins_url( $script_relative_path, $plugin_base_path ); wp_enqueue_script( 'jetpack-instant-search', $script_path, array(), $script_version, true ); wp_set_script_translations( 'jetpack-instant-search', 'jetpack' ); @@ -162,7 +164,7 @@ protected function inject_translation_for_script( $payload_url, $before_handle = * Passes all options to the JS app. */ protected function inject_javascript_options() { - $options = Jetpack_Search_Helpers::generate_initial_javascript_state(); + $options = Search\Helper::generate_initial_javascript_state(); // Use wp_add_inline_script instead of wp_localize_script, see https://core.trac.wordpress.org/ticket/25280. wp_add_inline_script( 'jetpack-instant-search', 'var JetpackInstantSearchOptions=JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( $options ) ) . '"));', 'before' ); } @@ -379,7 +381,7 @@ public function auto_config_search() { } // Set default result format to "expanded". - update_option( Jetpack_Search_Options::OPTION_PREFIX . 'result_format', Jetpack_Search_Options::RESULT_FORMAT_EXPANDED ); + update_option( Search\Options::OPTION_PREFIX . 'result_format', Search\Options::RESULT_FORMAT_EXPANDED ); $this->auto_config_excluded_post_types(); $this->auto_config_overlay_sidebar_widgets(); @@ -394,7 +396,7 @@ public function auto_config_search() { public function auto_config_overlay_sidebar_widgets() { global $wp_registered_sidebars; $sidebars = get_option( 'sidebars_widgets', array() ); - $slug = Jetpack_Search_Helpers::FILTER_WIDGET_BASE; + $slug = Search\Helper::FILTER_WIDGET_BASE; if ( isset( $sidebars['jetpack-instant-search-sidebar'] ) ) { foreach ( (array) $sidebars['jetpack-instant-search-sidebar'] as $widget_id ) { @@ -418,14 +420,14 @@ public function auto_config_overlay_sidebar_widgets() { $sidebar_searchbox_idx = $idx; } if ( 0 === strpos( $widget_id, $slug ) ) { - $sidebar_id = (int) str_replace( Jetpack_Search_Helpers::FILTER_WIDGET_BASE . '-', '', $widget_id ); + $sidebar_id = (int) str_replace( Search\Helper::FILTER_WIDGET_BASE . '-', '', $widget_id ); break; } } } $next_id = 1; - $widget_opt_name = Jetpack_Search_Helpers::get_widget_option_name(); + $widget_opt_name = Search\Helper::get_widget_option_name(); $widget_options = get_option( $widget_opt_name, array() ); foreach ( $widget_options as $id => $w ) { if ( $id >= $next_id ) { @@ -441,7 +443,7 @@ public function auto_config_overlay_sidebar_widgets() { if ( ! isset( $sidebars['jetpack-instant-search-sidebar'] ) ) { $sidebars['jetpack-instant-search-sidebar'] = array(); } - array_unshift( $sidebars['jetpack-instant-search-sidebar'], Jetpack_Search_Helpers::build_widget_id( $next_id ) ); + array_unshift( $sidebars['jetpack-instant-search-sidebar'], Search\Helper::build_widget_id( $next_id ) ); update_option( 'sidebars_widgets', $sidebars ); return; @@ -456,15 +458,15 @@ public function auto_config_overlay_sidebar_widgets() { $widget_options[ $next_id ] = $preconfig_opts; if ( false !== $sidebar_searchbox_idx ) { // Replace Core search box. - $sidebars['sidebar-1'][ $sidebar_searchbox_idx ] = Jetpack_Search_Helpers::build_widget_id( $next_id ); + $sidebars['sidebar-1'][ $sidebar_searchbox_idx ] = Search\Helper::build_widget_id( $next_id ); } else { // Add to top. - array_unshift( $sidebars['sidebar-1'], Jetpack_Search_Helpers::build_widget_id( $next_id ) ); + array_unshift( $sidebars['sidebar-1'], Search\Helper::build_widget_id( $next_id ) ); } $next_id++; } $widget_options[ $next_id ] = $preconfig_opts; - array_unshift( $sidebars['jetpack-instant-search-sidebar'], Jetpack_Search_Helpers::build_widget_id( $next_id ) ); + array_unshift( $sidebars['jetpack-instant-search-sidebar'], Search\Helper::build_widget_id( $next_id ) ); update_option( $widget_opt_name, $widget_options ); update_option( 'sidebars_widgets', $sidebars ); @@ -557,7 +559,7 @@ public function auto_config_excluded_post_types() { ) ); $enabled_post_types = array(); - $widget_options = get_option( Jetpack_Search_Helpers::get_widget_option_name(), array() ); + $widget_options = get_option( Search\Helper::get_widget_option_name(), array() ); // Prior to Jetpack 8.8, post types were enabled via Jetpack Search widgets rather than disabled via the Customizer. // To continue supporting post types set up in the old way, we iterate through each Jetpack Search @@ -572,7 +574,7 @@ public function auto_config_excluded_post_types() { if ( ! empty( $enabled_post_types ) ) { $post_types_to_disable = array_diff( $post_types, $enabled_post_types ); - update_option( Jetpack_Search_Options::OPTION_PREFIX . 'excluded_post_types', join( ',', $post_types_to_disable ) ); + update_option( Search\Options::OPTION_PREFIX . 'excluded_post_types', join( ',', $post_types_to_disable ) ); } } @@ -591,7 +593,7 @@ public function auto_config_woo_result_format() { return false; } - update_option( Jetpack_Search_Options::OPTION_PREFIX . 'result_format', Jetpack_Search_Options::RESULT_FORMAT_PRODUCT ); + update_option( Search\Options::OPTION_PREFIX . 'result_format', Search\Options::RESULT_FORMAT_PRODUCT ); } /** diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php b/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php index 92bbb75421d59..f7fe5a6db7ca1 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php +++ b/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php @@ -11,7 +11,6 @@ use Automattic\Jetpack\Tracking; use Jetpack; use Jetpack_Plan; -use Jetpack_Search_Helpers; /** * Responsible for adding a search customization interface to wp-admin. @@ -68,7 +67,7 @@ public function add_wp_admin_page() { // Only load assets if Customberg is supported. if ( $this->wp_supports_customberg() ) { add_action( "admin_print_scripts-$hook", array( $this, 'load_assets' ) ); - add_action( 'admin_footer', array( 'Jetpack_Search_Helpers', 'print_instant_search_sidebar' ) ); + add_action( 'admin_footer', array( 'Helper', 'print_instant_search_sidebar' ) ); } else { add_action( "admin_print_scripts-$hook", array( $this, 'add_redirect_if_necessary' ) ); } @@ -160,7 +159,7 @@ public function load_assets_with_parameters( $path_prefix, $plugin_base_path ) { wp_set_script_translations( 'jp-search-configure', 'jetpack' ); // Use wp_add_inline_script instead of wp_localize_script, see https://core.trac.wordpress.org/ticket/25280. - wp_add_inline_script( 'jp-search-configure', 'var JetpackInstantSearchOptions=JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( Jetpack_Search_Helpers::generate_initial_javascript_state() ) ) . '"));', 'before' ); + wp_add_inline_script( 'jp-search-configure', 'var JetpackInstantSearchOptions=JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( Helper::generate_initial_javascript_state() ) ) . '"));', 'before' ); wp_add_inline_script( 'jp-search-configure', "window.jetpackSearchConfigureInit( 'jp-search-configure' )" diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-search-customize.php b/projects/plugins/jetpack/modules/search/class-jetpack-search-customize.php index 5dcc101cf89ee..21bef8cb2af1f 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-search-customize.php +++ b/projects/plugins/jetpack/modules/search/class-jetpack-search-customize.php @@ -10,9 +10,6 @@ exit; } -require_once __DIR__ . '/class.jetpack-search-helpers.php'; -require_once __DIR__ . '/class-jetpack-search-options.php'; - /** * Class to customize search on the site. * @@ -41,7 +38,7 @@ public function customize_register( $wp_customize ) { require_once dirname( JETPACK__PLUGIN_FILE ) . '/modules/search/customize-controls/class-label-control.php'; require_once dirname( JETPACK__PLUGIN_FILE ) . '/modules/search/customize-controls/class-excluded-post-types-control.php'; $section_id = 'jetpack_search'; - $setting_prefix = Jetpack_Search_Options::OPTION_PREFIX; + $setting_prefix = Automattic\Jetpack\Search\Options::OPTION_PREFIX; $wp_customize->add_section( $section_id, @@ -126,7 +123,7 @@ public function customize_register( $wp_customize ) { $wp_customize->add_setting( $id, array( - 'default' => Jetpack_Search_Options::OVERLAY_TRIGGER_IMMEDIATE, + 'default' => Automattic\Jetpack\Search\Options::OVERLAY_TRIGGER_IMMEDIATE, 'transport' => 'postMessage', 'type' => 'option', ) @@ -139,9 +136,9 @@ public function customize_register( $wp_customize ) { 'section' => $section_id, 'type' => 'select', 'choices' => array( - Jetpack_Search_Options::OVERLAY_TRIGGER_IMMEDIATE => __( 'Open when user starts typing', 'jetpack' ), - Jetpack_Search_Options::OVERLAY_TRIGGER_RESULTS => __( 'Open when results are available', 'jetpack' ), - Jetpack_Search_Options::OVERLAY_TRIGGER_SUBMIT => __( 'Open when user submits the form', 'jetpack' ), + Automattic\Jetpack\Search\Options::OVERLAY_TRIGGER_IMMEDIATE => __( 'Open when user starts typing', 'jetpack' ), + Automattic\Jetpack\Search\Options::OVERLAY_TRIGGER_RESULTS => __( 'Open when results are available', 'jetpack' ), + Automattic\Jetpack\Search\Options::OVERLAY_TRIGGER_SUBMIT => __( 'Open when user submits the form', 'jetpack' ), ), ) ); @@ -208,8 +205,8 @@ public function customize_register( $wp_customize ) { $id, array( 'default' => '1', - 'sanitize_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value' ), - 'sanitize_js_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value_for_js' ), + 'sanitize_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value' ), + 'sanitize_js_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value_for_js' ), 'transport' => 'postMessage', 'type' => 'option', ) @@ -228,8 +225,8 @@ public function customize_register( $wp_customize ) { $id, array( 'default' => '1', - 'sanitize_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value' ), - 'sanitize_js_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value_for_js' ), + 'sanitize_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value' ), + 'sanitize_js_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value_for_js' ), 'transport' => 'postMessage', 'type' => 'option', ) @@ -248,8 +245,8 @@ public function customize_register( $wp_customize ) { $id, array( 'default' => '1', - 'sanitize_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value' ), - 'sanitize_js_callback' => array( 'Jetpack_Search_Helpers', 'sanitize_checkbox_value_for_js' ), + 'sanitize_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value' ), + 'sanitize_js_callback' => array( 'Automattic\Jetpack\Search\Helper', 'sanitize_checkbox_value_for_js' ), 'transport' => 'postMessage', 'type' => 'option', ) @@ -271,7 +268,7 @@ public function customize_register( $wp_customize ) { */ public function customize_controls_enqueue_scripts() { $script_relative_path = 'modules/search/customize-controls/customize-controls.js'; - $script_version = Jetpack_Search_Helpers::get_asset_version( $script_relative_path ); + $script_version = Automattic\Jetpack\Search\Helper::get_asset_version( $script_relative_path ); $script_path = plugins_url( $script_relative_path, JETPACK__PLUGIN_FILE ); wp_enqueue_script( 'jetpack-instant-search-customizer', diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-search-settings.php b/projects/plugins/jetpack/modules/search/class-jetpack-search-settings.php index 909a99e6a3325..2298aa84716f7 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-search-settings.php +++ b/projects/plugins/jetpack/modules/search/class-jetpack-search-settings.php @@ -10,8 +10,6 @@ exit; } -require_once __DIR__ . '/class-jetpack-search-options.php'; - /** * Class to initialize search settings on the site. * @@ -36,7 +34,7 @@ public function __construct() { */ public function settings_register() { // NOTE: This contains significant code overlap with class-jetpack-search-customize. - $setting_prefix = Jetpack_Search_Options::OPTION_PREFIX; + $setting_prefix = Automattic\Jetpack\Search\Options::OPTION_PREFIX; $settings = array( array( $setting_prefix . 'color_theme', 'string', 'light' ), array( $setting_prefix . 'result_format', 'string', 'minimal' ), diff --git a/projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php b/projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php index 5e104d9267e9c..fc5f22347d630 100644 --- a/projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php +++ b/projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php @@ -7,6 +7,8 @@ * @since 5.8.0 */ +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; + /** * Class that has various methods for outputting functionality into a theme that doesn't support widgets. * Additionally the widget itself makes use of these class. diff --git a/projects/plugins/jetpack/modules/search/class.jetpack-search.php b/projects/plugins/jetpack/modules/search/class.jetpack-search.php index 11ef5c84f0256..aff7ba43f68d8 100644 --- a/projects/plugins/jetpack/modules/search/class.jetpack-search.php +++ b/projects/plugins/jetpack/modules/search/class.jetpack-search.php @@ -9,8 +9,7 @@ */ use Automattic\Jetpack\Connection\Client; - -require_once __DIR__ . '/class-jetpack-search-options.php'; +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; /** * The main class for the Jetpack Search module. @@ -139,7 +138,7 @@ public function __wakeup() { */ public static function instance() { if ( ! isset( self::$instance ) ) { - if ( Jetpack_Search_Options::is_instant_enabled() ) { + if ( Automattic\Jetpack\Search\Options::is_instant_enabled() ) { require_once __DIR__ . '/class-jetpack-instant-search.php'; self::$instance = new Jetpack_Instant_Search(); } else { @@ -199,7 +198,6 @@ public function load_php() { * Loads the PHP common to all search. Should be called from extending classes. */ protected function base_load_php() { - require_once __DIR__ . '/class.jetpack-search-helpers.php'; require_once __DIR__ . '/class.jetpack-search-template-tags.php'; require_once JETPACK__PLUGIN_DIR . 'modules/widgets/search.php'; } diff --git a/projects/plugins/jetpack/modules/search/customize-controls/class-excluded-post-types-control.php b/projects/plugins/jetpack/modules/search/customize-controls/class-excluded-post-types-control.php index 6fa6573fa1cbb..68f2d45514508 100644 --- a/projects/plugins/jetpack/modules/search/customize-controls/class-excluded-post-types-control.php +++ b/projects/plugins/jetpack/modules/search/customize-controls/class-excluded-post-types-control.php @@ -6,6 +6,8 @@ * @since 8.8.0 */ +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; + /** * Label Control class. */ @@ -22,7 +24,6 @@ class Excluded_Post_Types_Control extends WP_Customize_Control { * Enqueue styles related to this control. */ public function enqueue() { - require_once dirname( __DIR__ ) . '/class.jetpack-search-helpers.php'; $style_relative_path = 'modules/search/customize-controls/class-excluded-post-types-control.css'; $style_version = Jetpack_Search_Helpers::get_asset_version( $style_relative_path ); $style_path = plugins_url( $style_relative_path, JETPACK__PLUGIN_FILE ); diff --git a/projects/plugins/jetpack/modules/search/customize-controls/class-label-control.php b/projects/plugins/jetpack/modules/search/customize-controls/class-label-control.php index b563a9f98ecc6..3e41e7dc2196b 100644 --- a/projects/plugins/jetpack/modules/search/customize-controls/class-label-control.php +++ b/projects/plugins/jetpack/modules/search/customize-controls/class-label-control.php @@ -6,6 +6,8 @@ * @since 8.6.0 */ +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; + /** * Label Control class. */ @@ -14,7 +16,6 @@ class Label_Control extends WP_Customize_Control { * Enqueue styles related to this control. */ public function enqueue() { - require_once dirname( __DIR__ ) . '/class.jetpack-search-helpers.php'; $style_relative_path = 'modules/search/customize-controls/class-label-control.css'; $style_version = Jetpack_Search_Helpers::get_asset_version( $style_relative_path ); $style_path = plugins_url( $style_relative_path, JETPACK__PLUGIN_FILE ); diff --git a/projects/plugins/jetpack/modules/widgets/search.php b/projects/plugins/jetpack/modules/widgets/search.php index 18e89cb756430..45b51e4105a95 100644 --- a/projects/plugins/jetpack/modules/widgets/search.php +++ b/projects/plugins/jetpack/modules/widgets/search.php @@ -8,6 +8,8 @@ */ use Automattic\Jetpack\Redirect; +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; +use Automattic\Jetpack\Search\Options as Jetpack_Search_Options; use Automattic\Jetpack\Status; use Automattic\Jetpack\Tracking; @@ -21,9 +23,6 @@ function jetpack_search_widget_init() { return; } - require_once JETPACK__PLUGIN_DIR . 'modules/search/class.jetpack-search-helpers.php'; - require_once JETPACK__PLUGIN_DIR . 'modules/search/class-jetpack-search-options.php'; - register_widget( 'Jetpack_Search_Widget' ); } diff --git a/projects/plugins/jetpack/tests/php/modules/search/test-class-jetpack-instant-search.php b/projects/plugins/jetpack/tests/php/modules/search/test-class-jetpack-instant-search.php index 92bff06c42c52..f66b0531c42a4 100644 --- a/projects/plugins/jetpack/tests/php/modules/search/test-class-jetpack-instant-search.php +++ b/projects/plugins/jetpack/tests/php/modules/search/test-class-jetpack-instant-search.php @@ -10,8 +10,6 @@ } require_jetpack_file( 'modules/search/class.jetpack-search.php' ); -require_jetpack_file( 'modules/search/class.jetpack-search-helpers.php' ); -require_jetpack_file( 'modules/search/class-jetpack-search-options.php' ); require_jetpack_file( 'modules/search/class-jetpack-instant-search.php' ); /** diff --git a/projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php b/projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php index ad88e84c9e0da..28e85a7a6b7ca 100644 --- a/projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php +++ b/projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php @@ -5,10 +5,9 @@ } use Automattic\Jetpack\Constants; +use Automattic\Jetpack\Search\Helper as Jetpack_Search_Helpers; require_jetpack_file( 'modules/search/class.jetpack-search.php' ); -require_jetpack_file( 'modules/search/class.jetpack-search-helpers.php' ); -require_jetpack_file( 'modules/search/class-jetpack-search-options.php' ); class WP_Test_Jetpack_Search_Helpers_Customize { public $previewing = false; @@ -432,7 +431,7 @@ public function test_site_has_vip_index( $expected, $constant = null, $filter = add_filter( 'jetpack_search_has_vip_index', $filter ); } - $this->assertSame( $expected, Jetpack_Search_Options::site_has_vip_index() ); + $this->assertSame( $expected, Automattic\Jetpack\Search\Options::site_has_vip_index() ); } /** From cb9ed0dc8986a84e82ca943bcd35f7ba1e1a7caf Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 16:35:03 -0600 Subject: [PATCH 03/10] Update Jetpack composer config --- projects/plugins/jetpack/composer.json | 1 + projects/plugins/jetpack/composer.lock | 55 +++++++++++++++++++++++++- 2 files changed, 54 insertions(+), 2 deletions(-) diff --git a/projects/plugins/jetpack/composer.json b/projects/plugins/jetpack/composer.json index 0675012d1d003..b30ea2bb3256c 100644 --- a/projects/plugins/jetpack/composer.json +++ b/projects/plugins/jetpack/composer.json @@ -34,6 +34,7 @@ "automattic/jetpack-partner": "1.5.x-dev", "automattic/jetpack-redirect": "1.7.x-dev", "automattic/jetpack-roles": "1.4.x-dev", + "automattic/jetpack-search": "dev-master", "automattic/jetpack-status": "1.8.x-dev", "automattic/jetpack-sync": "1.26.x-dev", "automattic/jetpack-terms-of-service": "1.9.x-dev", diff --git a/projects/plugins/jetpack/composer.lock b/projects/plugins/jetpack/composer.lock index 2e74d2d62cb74..da082fa1019da 100644 --- a/projects/plugins/jetpack/composer.lock +++ b/projects/plugins/jetpack/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "a1be1f62cceb6030fe817d5bbaf3d49a", + "content-hash": "3a5228c5e984f3772597977f7c65f240", "packages": [ { "name": "automattic/jetpack-a8c-mc-stats", @@ -1303,6 +1303,56 @@ "relative": true } }, + { + "name": "automattic/jetpack-search", + "version": "dev-master", + "dist": { + "type": "path", + "url": "../../packages/search", + "reference": "3b9a50009915cd94403866c7f8a22f71c3c0465e" + }, + "require-dev": { + "automattic/jetpack-changelogger": "^2.0", + "yoast/phpunit-polyfills": "1.0.1" + }, + "type": "library", + "extra": { + "autotagger": true, + "mirror-repo": "Automattic/jetpack-search", + "changelogger": { + "link-template": "https://github.com/Automattic/jetpack-search/compare/v${old}...v${new}" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "scripts": { + "phpunit": [ + "./vendor/phpunit/phpunit/phpunit --colors=always" + ], + "test-coverage": [ + "@composer install", + "phpdbg -d memory_limit=2048M -d max_execution_time=900 -qrr ./vendor/bin/phpunit --coverage-clover \"$COVERAGE_DIR/clover.xml\"" + ], + "test-php": [ + "@composer install", + "@composer phpunit" + ], + "post-update-cmd": [ + "php -r \"copy('vendor/automattic/wordbless/src/dbless-wpdb.php', 'wordpress/wp-content/db.php');\"" + ] + }, + "license": [ + "GPL-2.0-or-later" + ], + "description": "Tools to assist with enabling cloud search for Jetpack sites.", + "transport-options": { + "monorepo": true, + "relative": true + } + }, { "name": "automattic/jetpack-status", "version": "dev-master", @@ -4807,6 +4857,7 @@ "automattic/jetpack-partner": 20, "automattic/jetpack-redirect": 20, "automattic/jetpack-roles": 20, + "automattic/jetpack-search": 20, "automattic/jetpack-status": 20, "automattic/jetpack-sync": 20, "automattic/jetpack-terms-of-service": 20, @@ -4824,5 +4875,5 @@ "platform-overrides": { "ext-intl": "0.0.0" }, - "plugin-api-version": "2.1.0" + "plugin-api-version": "2.0.0" } From 343af022b877249891a58736628a61f43161683c Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 16:35:10 -0600 Subject: [PATCH 04/10] Update PHPCS exclusion list --- tools/phpcs-excludelist.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/tools/phpcs-excludelist.json b/tools/phpcs-excludelist.json index bef3513fd3f11..245461b369432 100644 --- a/tools/phpcs-excludelist.json +++ b/tools/phpcs-excludelist.json @@ -258,7 +258,6 @@ "projects/plugins/jetpack/modules/related-posts.php", "projects/plugins/jetpack/modules/related-posts/class.related-posts-customize.php", "projects/plugins/jetpack/modules/related-posts/jetpack-related-posts.php", - "projects/plugins/jetpack/modules/search/class.jetpack-search-helpers.php", "projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php", "projects/plugins/jetpack/modules/seo-tools/jetpack-seo-posts.php", "projects/plugins/jetpack/modules/seo-tools/jetpack-seo-titles.php", @@ -436,7 +435,6 @@ "projects/plugins/jetpack/tests/php/modules/post-by-email/test-class.post-by-email-api.php", "projects/plugins/jetpack/tests/php/modules/publicize/test_class.publicize.php", "projects/plugins/jetpack/tests/php/modules/related-posts/test_class_related_posts.php", - "projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php", "projects/plugins/jetpack/tests/php/modules/sharedaddy/test-class.recaptcha.php", "projects/plugins/jetpack/tests/php/modules/shortcodes/test-class.archiveorg.php", "projects/plugins/jetpack/tests/php/modules/shortcodes/test-class.archives.php", From b93f645aa9ca27eebff2f1d4a79584e41501974b Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 16:37:40 -0600 Subject: [PATCH 05/10] Changelog --- .../packages/search/changelog/try-search-package-creation | 4 ++++ .../plugins/jetpack/changelog/try-search-package-creation | 4 ++++ 2 files changed, 8 insertions(+) create mode 100644 projects/packages/search/changelog/try-search-package-creation create mode 100644 projects/plugins/jetpack/changelog/try-search-package-creation diff --git a/projects/packages/search/changelog/try-search-package-creation b/projects/packages/search/changelog/try-search-package-creation new file mode 100644 index 0000000000000..9597e7aaa3830 --- /dev/null +++ b/projects/packages/search/changelog/try-search-package-creation @@ -0,0 +1,4 @@ +Significance: major +Type: added + +Add a new Search package with Helper and Options classes. diff --git a/projects/plugins/jetpack/changelog/try-search-package-creation b/projects/plugins/jetpack/changelog/try-search-package-creation new file mode 100644 index 0000000000000..a60d5eb255dea --- /dev/null +++ b/projects/plugins/jetpack/changelog/try-search-package-creation @@ -0,0 +1,4 @@ +Significance: minor +Type: other + +Search: Moved helper libraries into a separate package From 6ed8269a249d136bf52b14928b535b545a2d347f Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 16:46:19 -0600 Subject: [PATCH 06/10] Partially revert exclusion list commit --- tools/phpcs-excludelist.json | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/phpcs-excludelist.json b/tools/phpcs-excludelist.json index 245461b369432..ab9986fcba2f6 100644 --- a/tools/phpcs-excludelist.json +++ b/tools/phpcs-excludelist.json @@ -435,6 +435,7 @@ "projects/plugins/jetpack/tests/php/modules/post-by-email/test-class.post-by-email-api.php", "projects/plugins/jetpack/tests/php/modules/publicize/test_class.publicize.php", "projects/plugins/jetpack/tests/php/modules/related-posts/test_class_related_posts.php", + "projects/plugins/jetpack/tests/php/modules/search/test-class.jetpack-search-helpers.php", "projects/plugins/jetpack/tests/php/modules/sharedaddy/test-class.recaptcha.php", "projects/plugins/jetpack/tests/php/modules/shortcodes/test-class.archiveorg.php", "projects/plugins/jetpack/tests/php/modules/shortcodes/test-class.archives.php", From fcb50cb1650ce8e393f0a162034e4a9ec15cacbe Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 16:46:39 -0600 Subject: [PATCH 07/10] Add search package to renovate config --- .github/renovate.json | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/renovate.json b/.github/renovate.json index 898ec9775c7c8..c68795b0b1e70 100644 --- a/.github/renovate.json +++ b/.github/renovate.json @@ -46,6 +46,7 @@ "automattic/jetpack-post-list", "automattic/jetpack-redirect", "automattic/jetpack-roles", + "automattic/jetpack-search", "automattic/jetpack-status", "automattic/jetpack-sync", "automattic/jetpack-terms-of-service", From 1741ce17b7170b8aefae614446c3bbf91fd0b2a6 Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 17:22:22 -0600 Subject: [PATCH 08/10] Fix lint errors --- projects/packages/search/composer.json | 3 +++ projects/plugins/jetpack/composer.json | 2 +- projects/plugins/jetpack/composer.lock | 7 +++++-- projects/plugins/search/composer.json | 6 +++--- projects/plugins/search/composer.lock | 4 ++-- tools/phpcs-excludelist.json | 1 + 6 files changed, 15 insertions(+), 8 deletions(-) diff --git a/projects/packages/search/composer.json b/projects/packages/search/composer.json index 1bd73e9034eeb..889d38e13f67a 100644 --- a/projects/packages/search/composer.json +++ b/projects/packages/search/composer.json @@ -43,6 +43,9 @@ "mirror-repo": "Automattic/jetpack-search", "changelogger": { "link-template": "https://github.com/Automattic/jetpack-search/compare/v${old}...v${new}" + }, + "branch-alias": { + "dev-master": "0.1.x-dev" } } } diff --git a/projects/plugins/jetpack/composer.json b/projects/plugins/jetpack/composer.json index b30ea2bb3256c..6850bb1d7e4ab 100644 --- a/projects/plugins/jetpack/composer.json +++ b/projects/plugins/jetpack/composer.json @@ -34,7 +34,7 @@ "automattic/jetpack-partner": "1.5.x-dev", "automattic/jetpack-redirect": "1.7.x-dev", "automattic/jetpack-roles": "1.4.x-dev", - "automattic/jetpack-search": "dev-master", + "automattic/jetpack-search": "0.1.x-dev", "automattic/jetpack-status": "1.8.x-dev", "automattic/jetpack-sync": "1.26.x-dev", "automattic/jetpack-terms-of-service": "1.9.x-dev", diff --git a/projects/plugins/jetpack/composer.lock b/projects/plugins/jetpack/composer.lock index da082fa1019da..227f6496baebd 100644 --- a/projects/plugins/jetpack/composer.lock +++ b/projects/plugins/jetpack/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "3a5228c5e984f3772597977f7c65f240", + "content-hash": "416a2069a8cfac84e947bdcb7570adda", "packages": [ { "name": "automattic/jetpack-a8c-mc-stats", @@ -1309,7 +1309,7 @@ "dist": { "type": "path", "url": "../../packages/search", - "reference": "3b9a50009915cd94403866c7f8a22f71c3c0465e" + "reference": "bdefbd2d669ebb3a249f3d80b133d12a0df17c88" }, "require-dev": { "automattic/jetpack-changelogger": "^2.0", @@ -1321,6 +1321,9 @@ "mirror-repo": "Automattic/jetpack-search", "changelogger": { "link-template": "https://github.com/Automattic/jetpack-search/compare/v${old}...v${new}" + }, + "branch-alias": { + "dev-master": "0.1.x-dev" } }, "autoload": { diff --git a/projects/plugins/search/composer.json b/projects/plugins/search/composer.json index a7e01074811d2..20059b9a5415f 100644 --- a/projects/plugins/search/composer.json +++ b/projects/plugins/search/composer.json @@ -1,5 +1,5 @@ { - "name": "automattic/jetpack-search", + "name": "automattic/jetpack-search-plugin", "description": "A cloud-powered replacement for WordPress' search.", "type": "wordpress-plugin", "license": "GPL-2.0-or-later", @@ -40,11 +40,11 @@ "minimum-stability": "dev", "prefer-stable": true, "extra": { - "mirror-repo": "Automattic/jetpack-search", + "mirror-repo": "Automattic/jetpack-search-plugin", "release-branch-prefix": "search", "wp-plugin-slug": "jetpack-search", "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-search/compare/v${old}...v${new}" + "link-template": "https://github.com/Automattic/jetpack-search-plugin/compare/v${old}...v${new}" }, "autotagger": true } diff --git a/projects/plugins/search/composer.lock b/projects/plugins/search/composer.lock index 51a7be96aec55..d32468a29cb29 100644 --- a/projects/plugins/search/composer.lock +++ b/projects/plugins/search/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "ffdd021f8ef972ef5759a7862265a9af", + "content-hash": "f745dfe8cf5aa58434e94a29191e580b", "packages": [], "packages-dev": [ { @@ -3137,5 +3137,5 @@ "prefer-lowest": false, "platform": [], "platform-dev": [], - "plugin-api-version": "2.1.0" + "plugin-api-version": "2.0.0" } diff --git a/tools/phpcs-excludelist.json b/tools/phpcs-excludelist.json index ab9986fcba2f6..48392743be04e 100644 --- a/tools/phpcs-excludelist.json +++ b/tools/phpcs-excludelist.json @@ -18,6 +18,7 @@ "projects/packages/analyzer/src/class-differences.php", "projects/packages/analyzer/src/class-invocations.php", "projects/packages/analyzer/src/class-utils.php", + "projects/packages/search/src/class-helper.php", "projects/plugins/jetpack/_inc/lib/admin-pages/class.jetpack-admin-page.php", "projects/plugins/jetpack/_inc/lib/admin-pages/class.jetpack-landing-page.php", "projects/plugins/jetpack/_inc/lib/admin-pages/class.jetpack-react-page.php", From 5ffe4da1b49fbea807557031ab11f11f7f0db0e2 Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Thu, 7 Oct 2021 17:26:26 -0600 Subject: [PATCH 09/10] Changelog --- projects/plugins/search/changelog/try-search-package-creation | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 projects/plugins/search/changelog/try-search-package-creation diff --git a/projects/plugins/search/changelog/try-search-package-creation b/projects/plugins/search/changelog/try-search-package-creation new file mode 100644 index 0000000000000..947d9bb6f5dfc --- /dev/null +++ b/projects/plugins/search/changelog/try-search-package-creation @@ -0,0 +1,4 @@ +Significance: patch +Type: changed + +Updated name to automattic/jetpack-search-plugin From 1bf654c560d0bbeb0d17453a6895fa1b9161291e Mon Sep 17 00:00:00 2001 From: Jason Moon Date: Tue, 19 Oct 2021 17:11:10 -0600 Subject: [PATCH 10/10] Try moving classic and instant search --- pnpm-lock.yaml | 1503 ++++++++++++++++- projects/packages/search/.gitignore | 3 + projects/packages/search/babel.config.js | 43 + projects/packages/search/package.json | 57 + projects/packages/search/src/class-helper.php | 33 +- .../classic-search/class-classic-search.php} | 155 +- .../src/initializers/class-initializer.php | 27 + .../class-jetpack-initializer.php | 83 + .../search/src}/instant-search/README.md | 0 .../src}/instant-search/babel.config.js | 0 .../instant-search/class-instant-search.php} | 108 +- .../components/customizer-event-handler.jsx | 0 .../components/dom-event-handler.jsx | 0 .../components/gridicon/index.jsx | 0 .../components/gridicon/style.scss | 0 .../components/jetpack-colophon.jsx | 0 .../components/jetpack-colophon.scss | 0 .../src}/instant-search/components/notice.jsx | 0 .../instant-search/components/notice.scss | 0 .../instant-search/components/overlay.jsx | 0 .../instant-search/components/overlay.scss | 0 .../components/path-breadcrumbs.jsx | 0 .../components/path-breadcrumbs.scss | 0 .../components/photon-image.jsx | 0 .../components/post-type-icon.jsx | 0 .../components/product-price.jsx | 0 .../components/product-price.scss | 0 .../components/product-ratings.jsx | 0 .../components/product-ratings.scss | 0 .../components/scroll-button.jsx | 0 .../components/scroll-button.scss | 0 .../instant-search/components/search-app.jsx | 0 .../instant-search/components/search-app.scss | 0 .../instant-search/components/search-box.jsx | 0 .../instant-search/components/search-box.scss | 0 .../components/search-controls.jsx | 0 .../components/search-controls.scss | 0 .../components/search-filter.jsx | 0 .../components/search-filters.jsx | 0 .../components/search-filters.scss | 0 .../instant-search/components/search-form.jsx | 0 .../components/search-result-comments.jsx | 0 .../components/search-result-comments.scss | 0 .../components/search-result-expanded.jsx | 0 .../components/search-result-expanded.scss | 0 .../components/search-result-minimal.jsx | 0 .../components/search-result-minimal.scss | 0 .../components/search-result-product.jsx | 0 .../components/search-result-product.scss | 0 .../components/search-result.jsx | 0 .../components/search-result.scss | 0 .../components/search-results.jsx | 0 .../components/search-results.scss | 0 .../instant-search/components/search-sort.jsx | 0 .../components/search-sort.scss | 0 .../instant-search/components/sidebar.jsx | 0 .../instant-search/components/sidebar.scss | 0 .../components/test/.eslintrc.js | 0 .../instant-search/components/test/README.md | 0 .../test/__snapshots__/notice.test.js.snap | 0 .../components/test/notice.test.js | 0 .../components/test/photon-image.test.js | 0 .../components/widget-area-container.jsx | 0 .../components/widget-area-container.scss | 0 .../external/query-string-decode.js | 0 .../search/src}/instant-search/index.jsx | 0 .../search/src}/instant-search/lib/api.js | 0 .../src}/instant-search/lib/array-overlap.js | 0 .../search/src}/instant-search/lib/colors.js | 0 .../src}/instant-search/lib/constants.js | 0 .../src}/instant-search/lib/customize.js | 0 .../search/src}/instant-search/lib/dom.js | 0 .../src}/instant-search/lib/dummy-debug.js | 0 .../search/src}/instant-search/lib/filters.js | 0 .../instant-search/lib/hooks/use-photon.js | 0 .../src}/instant-search/lib/query-string.js | 0 .../search/src}/instant-search/lib/sort.js | 0 .../instant-search/lib/styles/_helper.scss | 0 .../instant-search/lib/styles/_mixins.scss | 0 .../instant-search/lib/styles/_variables.scss | 0 .../lib/test-helpers/tiny-lru.mock.js | 0 .../src}/instant-search/lib/test/.eslintrc.js | 0 .../src}/instant-search/lib/test/api.test.js | 0 .../instant-search/lib/test/filters.test.js | 0 .../search/src}/instant-search/lib/tracks.js | 0 .../search/src}/instant-search/loader.js | 0 .../instant-search/set-webpack-public-path.js | 0 .../src}/instant-search/store/actions.js | 0 .../src}/instant-search/store/effects.js | 0 .../search/src}/instant-search/store/index.js | 0 .../src}/instant-search/store/reducer/api.js | 0 .../instant-search/store/reducer/history.js | 0 .../instant-search/store/reducer/index.js | 0 .../store/reducer/query-string.js | 0 .../store/reducer/server-options.js | 0 .../src}/instant-search/store/selectors.js | 0 .../instant-search/store/test/.eslintrc.js | 0 .../instant-search/store/test/reducer.test.js | 0 .../store/test/selectors.test.js | 0 .../search/src/wpes/query-builder.php} | 3 +- .../search/src/wpes/query-parser.php} | 6 +- projects/packages/search/webpack.config.js | 6 + projects/packages/search/webpack.helpers.js | 31 + .../search/webpack.instant.config.js} | 86 +- projects/plugins/jetpack/composer.lock | 2 +- projects/plugins/jetpack/modules/search.php | 7 +- .../class-jetpack-search-customberg.php | 2 +- ...=> class-jetpack-search-template-tags.php} | 0 .../jetpack/modules/widgets/search.php | 22 +- projects/plugins/jetpack/package.json | 2 +- 110 files changed, 1892 insertions(+), 287 deletions(-) create mode 100644 projects/packages/search/babel.config.js create mode 100644 projects/packages/search/package.json rename projects/{plugins/jetpack/modules/search/class.jetpack-search.php => packages/search/src/classic-search/class-classic-search.php} (95%) create mode 100644 projects/packages/search/src/initializers/class-initializer.php create mode 100644 projects/packages/search/src/initializers/class-jetpack-initializer.php rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/README.md (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/babel.config.js (100%) rename projects/{plugins/jetpack/modules/search/class-jetpack-instant-search.php => packages/search/src/instant-search/class-instant-search.php} (87%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/customizer-event-handler.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/dom-event-handler.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/gridicon/index.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/gridicon/style.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/jetpack-colophon.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/jetpack-colophon.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/notice.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/notice.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/overlay.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/overlay.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/path-breadcrumbs.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/path-breadcrumbs.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/photon-image.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/post-type-icon.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/product-price.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/product-price.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/product-ratings.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/product-ratings.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/scroll-button.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/scroll-button.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-app.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-app.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-box.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-box.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-controls.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-controls.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-filter.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-filters.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-filters.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-form.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-comments.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-comments.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-expanded.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-expanded.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-minimal.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-minimal.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-product.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result-product.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-result.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-results.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-results.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-sort.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/search-sort.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/sidebar.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/sidebar.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/test/.eslintrc.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/test/README.md (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/test/__snapshots__/notice.test.js.snap (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/test/notice.test.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/test/photon-image.test.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/widget-area-container.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/components/widget-area-container.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/external/query-string-decode.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/index.jsx (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/api.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/array-overlap.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/colors.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/constants.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/customize.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/dom.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/dummy-debug.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/filters.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/hooks/use-photon.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/query-string.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/sort.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/styles/_helper.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/styles/_mixins.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/styles/_variables.scss (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/test-helpers/tiny-lru.mock.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/test/.eslintrc.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/test/api.test.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/test/filters.test.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/lib/tracks.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/loader.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/set-webpack-public-path.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/actions.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/effects.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/index.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/reducer/api.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/reducer/history.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/reducer/index.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/reducer/query-string.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/reducer/server-options.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/selectors.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/test/.eslintrc.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/test/reducer.test.js (100%) rename projects/{plugins/jetpack/modules/search => packages/search/src}/instant-search/store/test/selectors.test.js (100%) rename projects/{plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-builder.php => packages/search/src/wpes/query-builder.php} (99%) rename projects/{plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-parser.php => packages/search/src/wpes/query-parser.php} (98%) create mode 100644 projects/packages/search/webpack.config.js create mode 100644 projects/packages/search/webpack.helpers.js rename projects/{plugins/jetpack/tools/webpack.config.search.js => packages/search/webpack.instant.config.js} (50%) rename projects/plugins/jetpack/modules/search/{class.jetpack-search-template-tags.php => class-jetpack-search-template-tags.php} (100%) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 66ffa77302db3..03ddfe258aa32 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -394,6 +394,59 @@ importers: eslint: 7.32.0 webpack: 5.51.1 + projects/packages/search: + specifiers: + '@automattic/calypso-build': 9.0.0 + '@automattic/color-studio': 2.5.0 + '@babel/core': 7.15.8 + '@babel/plugin-proposal-nullish-coalescing-operator': 7.14.5 + '@babel/preset-env': 7.15.8 + '@babel/preset-react': 7.14.5 + '@babel/preset-typescript': 7.15.0 + '@size-limit/preset-app': 6.0.3 + '@wordpress/dependency-extraction-webpack-plugin': 3.2.1 + '@wordpress/i18n': 4.2.2 + fast-json-stable-stringify: 2.1.0 + lodash: 4.17.21 + photon: 4.0.0 + postcss: 8.3.11 + preact: 10.5.15 + q-flat: 1.0.7 + qss: 2.0.3 + react-redux: 7.2.5 + redux: 4.1.1 + refx: 3.1.1 + size-limit: 6.0.3 + strip: 3.0.0 + tiny-lru: 7.0.6 + webpack: 5.51.1 + dependencies: + '@automattic/color-studio': 2.5.0 + '@wordpress/i18n': 4.2.2 + fast-json-stable-stringify: 2.1.0 + lodash: 4.17.21 + photon: 4.0.0 + preact: 10.5.15 + q-flat: 1.0.7 + qss: 2.0.3 + react-redux: 7.2.5 + redux: 4.1.1 + refx: 3.1.1 + strip: 3.0.0 + tiny-lru: 7.0.6 + devDependencies: + '@automattic/calypso-build': 9.0.0_postcss@8.3.11+webpack@5.51.1 + '@babel/core': 7.15.8 + '@babel/plugin-proposal-nullish-coalescing-operator': 7.14.5_@babel+core@7.15.8 + '@babel/preset-env': 7.15.8_@babel+core@7.15.8 + '@babel/preset-react': 7.14.5_@babel+core@7.15.8 + '@babel/preset-typescript': 7.15.0_@babel+core@7.15.8 + '@size-limit/preset-app': 6.0.3_size-limit@6.0.3 + '@wordpress/dependency-extraction-webpack-plugin': 3.2.1_webpack@5.51.1 + postcss: 8.3.11 + size-limit: 6.0.3 + webpack: 5.51.1 + projects/plugins/backup: specifiers: '@automattic/calypso-build': 9.0.0 @@ -1123,6 +1176,75 @@ packages: - webpack-dev-server dev: true + /@automattic/calypso-build/9.0.0_postcss@8.3.11+webpack@5.51.1: + resolution: {integrity: sha512-5HUUBkInuV53BjYXvslYG/CtzxfC+4Bt2f5afRjWsDQbZv9DZ5JQgItK5GPRXDMzd5X2or8YmsNzxkYN6m+H3g==} + hasBin: true + peerDependencies: + enzyme: ^3.11.0 + jest: '>=27.0.6' + postcss: ^8.2.15 + react: ^16.0.0 + react-dom: ^16.0.0 + webpack: ^5.46.0 + dependencies: + '@automattic/webpack-rtl-plugin': 5.0.0_webpack@5.51.1 + '@babel/cli': 7.15.7_@babel+core@7.15.5 + '@babel/compat-data': 7.15.0 + '@babel/core': 7.15.5 + '@babel/helpers': 7.15.4 + '@babel/plugin-proposal-class-properties': 7.14.5_@babel+core@7.15.5 + '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.5 + '@babel/plugin-transform-runtime': 7.15.0_@babel+core@7.15.5 + '@babel/preset-env': 7.15.6_@babel+core@7.15.5 + '@babel/preset-react': 7.14.5_@babel+core@7.15.5 + '@babel/preset-typescript': 7.15.0_@babel+core@7.15.5 + '@types/webpack-env': 1.16.2 + '@wordpress/babel-plugin-import-jsx-pragma': 3.1.0_@babel+core@7.15.5 + '@wordpress/browserslist-config': 3.0.3 + '@wordpress/dependency-extraction-webpack-plugin': 3.2.1_webpack@5.51.1 + autoprefixer: 10.3.4_postcss@8.3.11 + babel-jest: 27.2.1_@babel+core@7.15.5 + babel-loader: 8.2.2_80927b313c74087b681f254ee0e3e2fc + browserslist: 4.17.0 + cache-loader: 4.1.0_webpack@5.51.1 + css-loader: 5.2.7_webpack@5.51.1 + css-minimizer-webpack-plugin: 1.3.0_webpack@5.51.1 + duplicate-package-checker-webpack-plugin: 3.0.0 + enzyme-adapter-react-16: /@wojtekmaj/enzyme-adapter-react-17/0.6.3 + enzyme-to-json: 3.6.2 + jest-config: 27.2.1 + jest-emotion: 10.0.32 + jest-enzyme: 7.1.2 + mini-css-extract-plugin: 1.6.2_webpack@5.51.1 + postcss: 8.3.11 + postcss-custom-properties: 11.0.0_postcss@8.3.11 + postcss-loader: 5.3.0_postcss@8.3.11+webpack@5.51.1 + recursive-copy: 2.0.13 + sass: 1.39.0 + sass-loader: 11.1.1_sass@1.39.0+webpack@5.51.1 + semver: 7.3.5 + terser-webpack-plugin: 5.2.4_webpack@5.51.1 + thread-loader: 3.0.4_webpack@5.51.1 + typescript: 4.4.3 + webpack: 5.51.1 + webpack-cli: 4.8.0_webpack@5.51.1 + transitivePeerDependencies: + - '@swc/core' + - '@webpack-cli/generators' + - '@webpack-cli/migrate' + - bufferutil + - canvas + - esbuild + - fibers + - node-sass + - supports-color + - ts-node + - uglify-js + - utf-8-validate + - webpack-bundle-analyzer + - webpack-dev-server + dev: true + /@automattic/calypso-build/9.0.0_webpack@5.51.1: resolution: {integrity: sha512-5HUUBkInuV53BjYXvslYG/CtzxfC+4Bt2f5afRjWsDQbZv9DZ5JQgItK5GPRXDMzd5X2or8YmsNzxkYN6m+H3g==} hasBin: true @@ -1196,7 +1318,6 @@ packages: /@automattic/color-studio/2.5.0: resolution: {integrity: sha512-gZWaJbx3p1oennAIoJtMGluTmoM95Efk4rc44TSBxWSZZ8gH3Am2eh1o3i1NhrZmg2Zt3AiVFeZZ4AJccIpBKQ==} - dev: true /@automattic/components/1.0.0-alpha.3_react-dom@17.0.2+react@17.0.2: resolution: {integrity: sha512-6PgogtcbvKEM7dQDXMUBbnGkwhf+0h29p/6sd8jfNoDlSxJJylcfZCio0yWuVKiSLAm9KWozeY5cqgI0nRcuzg==} @@ -1287,6 +1408,26 @@ packages: '@nicolo-ribaudo/chokidar-2': 2.1.8-no-fsevents.3 chokidar: 3.5.2 + /@babel/cli/7.15.7_@babel+core@7.15.5: + resolution: {integrity: sha512-YW5wOprO2LzMjoWZ5ZG6jfbY9JnkDxuHDwvnrThnuYtByorova/I0HNXJedrUfwuXFQfYOjcqDA4PU3qlZGZjg==} + engines: {node: '>=6.9.0'} + hasBin: true + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.5 + commander: 4.1.1 + convert-source-map: 1.8.0 + fs-readdir-recursive: 1.1.0 + glob: 7.1.7 + make-dir: 2.1.0 + slash: 2.0.0 + source-map: 0.5.7 + optionalDependencies: + '@nicolo-ribaudo/chokidar-2': 2.1.8-no-fsevents.3 + chokidar: 3.5.2 + dev: true + /@babel/code-frame/7.10.4: resolution: {integrity: sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==} dependencies: @@ -1305,6 +1446,12 @@ packages: dependencies: '@babel/highlight': 7.14.5 + /@babel/code-frame/7.15.8: + resolution: {integrity: sha512-2IAnmn8zbvC/jKYhq5Ki9I+DwjlrtMPUCH/CpHvqI4dNnlwHwsxoIhlc8WcYY5LSYknXQtAlFYuHfqAFCvQ4Wg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/highlight': 7.14.5 + /@babel/compat-data/7.15.0: resolution: {integrity: sha512-0NqAC1IJE0S0+lL1SWFMxMkz1pKCNCjI4tr2Zx4LJSXxCLAdr6KyArnY+sno5m3yH9g737ygOyPABDsnXkpxiA==} engines: {node: '>=6.9.0'} @@ -1377,6 +1524,29 @@ packages: transitivePeerDependencies: - supports-color + /@babel/core/7.15.8: + resolution: {integrity: sha512-3UG9dsxvYBMYwRv+gS41WKHno4K60/9GPy1CJaH6xy3Elq8CTtvtjT5R5jmNhXfCYLX2mTw+7/aq5ak/gOE0og==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/code-frame': 7.15.8 + '@babel/generator': 7.15.8 + '@babel/helper-compilation-targets': 7.15.4_@babel+core@7.15.8 + '@babel/helper-module-transforms': 7.15.8 + '@babel/helpers': 7.15.4 + '@babel/parser': 7.15.8 + '@babel/template': 7.15.4 + '@babel/traverse': 7.15.4 + '@babel/types': 7.15.6 + convert-source-map: 1.8.0 + debug: 4.3.2 + gensync: 1.0.0-beta.2 + json5: 2.2.0 + semver: 6.3.0 + source-map: 0.5.7 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/eslint-parser/7.15.0_@babel+core@7.15.0+eslint@7.32.0: resolution: {integrity: sha512-+gSPtjSBxOZz4Uh8Ggqu7HbfpB8cT1LwW0DnVVLZEJvzXauiD0Di3zszcBkRmfGGrLdYeHUwcflG7i3tr9kQlw==} engines: {node: ^10.13.0 || ^12.13.0 || >=14.0.0} @@ -1399,6 +1569,15 @@ packages: jsesc: 2.5.2 source-map: 0.5.7 + /@babel/generator/7.15.8: + resolution: {integrity: sha512-ECmAKstXbp1cvpTTZciZCgfOt6iN64lR0d+euv3UZisU5awfRawOvg07Utn/qBGuH4bRIEZKrA/4LzZyXhZr8g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.15.6 + jsesc: 2.5.2 + source-map: 0.5.7 + dev: true + /@babel/helper-annotate-as-pure/7.15.4: resolution: {integrity: sha512-QwrtdNvUNsPCj2lfNQacsGSQvGX8ee1ttrBrcozUP2Sv/jylewBP/8QFe6ZkBsC8T/GYWonNAWJV4aRR9AL2DA==} engines: {node: '>=6.9.0'} @@ -1436,6 +1615,19 @@ packages: browserslist: 4.17.0 semver: 6.3.0 + /@babel/helper-compilation-targets/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-rMWPCirulnPSe4d+gwdWXLfAXTTBj8M3guAf5xFQJ0nvFY7tfNAFnWdqaHegHlgDZOCT4qvhF3BYlSJag8yhqQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/compat-data': 7.15.0 + '@babel/core': 7.15.8 + '@babel/helper-validator-option': 7.14.5 + browserslist: 4.17.0 + semver: 6.3.0 + dev: true + /@babel/helper-create-class-features-plugin/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==} engines: {node: '>=6.9.0'} @@ -1469,6 +1661,23 @@ packages: - supports-color dev: true + /@babel/helper-create-class-features-plugin/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-7ZmzFi+DwJx6A7mHRwbuucEYpyBwmh2Ca0RvI6z2+WLZYCqV0JOaLb+u0zbtmDicebgKBZgqbYfLaKNqSgv5Pw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + '@babel/helper-function-name': 7.15.4 + '@babel/helper-member-expression-to-functions': 7.15.4 + '@babel/helper-optimise-call-expression': 7.15.4 + '@babel/helper-replace-supers': 7.15.4 + '@babel/helper-split-export-declaration': 7.15.4 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/helper-create-regexp-features-plugin/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==} engines: {node: '>=6.9.0'} @@ -1490,6 +1699,17 @@ packages: regexpu-core: 4.8.0 dev: true + /@babel/helper-create-regexp-features-plugin/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + regexpu-core: 4.8.0 + dev: true + /@babel/helper-define-polyfill-provider/0.1.5_@babel+core@7.15.0: resolution: {integrity: sha512-nXuzCSwlJ/WKr8qxzW816gwyT6VZgiJG17zR40fou70yfAcqjoNyTLl/DQ+FExw5Hx5KNqshmN8Ldl/r2N7cTg==} peerDependencies: @@ -1561,6 +1781,24 @@ packages: - supports-color dev: true + /@babel/helper-define-polyfill-provider/0.2.3_@babel+core@7.15.8: + resolution: {integrity: sha512-RH3QDAfRMzj7+0Nqu5oqgO5q9mFtQEVvCRsi8qCEfzLR9p2BHfn5FzhSB2oj1fF7I2+DcTORkYaQ6aTR9Cofew==} + peerDependencies: + '@babel/core': ^7.4.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-compilation-targets': 7.15.4_@babel+core@7.15.8 + '@babel/helper-module-imports': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/traverse': 7.15.4 + debug: 4.3.2 + lodash.debounce: 4.0.8 + resolve: 1.20.0 + semver: 6.3.0 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/helper-explode-assignable-expression/7.15.4: resolution: {integrity: sha512-J14f/vq8+hdC2KoWLIQSsGrC9EFBKE4NFts8pfMpymfApds+fPqR30AOUWc4tyr56h9l/GA1Sxv2q3dLZWbQ/g==} engines: {node: '>=6.9.0'} @@ -1620,6 +1858,22 @@ packages: transitivePeerDependencies: - supports-color + /@babel/helper-module-transforms/7.15.8: + resolution: {integrity: sha512-DfAfA6PfpG8t4S6npwzLvTUpp0sS7JrcuaMiy1Y5645laRJIp/LiLGIBbQKaXSInK8tiGNI7FL7L8UvB8gdUZg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-module-imports': 7.15.4 + '@babel/helper-replace-supers': 7.15.4 + '@babel/helper-simple-access': 7.15.4 + '@babel/helper-split-export-declaration': 7.15.4 + '@babel/helper-validator-identifier': 7.15.7 + '@babel/template': 7.15.4 + '@babel/traverse': 7.15.4 + '@babel/types': 7.15.6 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/helper-optimise-call-expression/7.15.4: resolution: {integrity: sha512-E/z9rfbAOt1vDW1DR7k4SzhzotVV5+qMciWV6LaG1g4jeFrkDlJedjtV4h0i4Q/ITnUu+Pk08M7fczsB9GXBDw==} engines: {node: '>=6.9.0'} @@ -1715,6 +1969,11 @@ packages: engines: {node: '>=6.0.0'} hasBin: true + /@babel/parser/7.15.8: + resolution: {integrity: sha512-BRYa3wcQnjS/nqI8Ac94pYYpJfojHVvVXJ97+IDCImX4Jc8W8Xv1+47enbruk+q1etOpsQNwnfFcNGw+gtPGxA==} + engines: {node: '>=6.0.0'} + hasBin: true + /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-eBnpsl9tlhPhpI10kU06JHnrYXwg3+V6CaP2idsCXNef0aeslpqyITXQ74Vfk5uHgY7IG7XP0yIH8b42KSzHog==} engines: {node: '>=6.9.0'} @@ -1738,6 +1997,18 @@ packages: '@babel/plugin-proposal-optional-chaining': 7.14.5_@babel+core@7.15.5 dev: true + /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-eBnpsl9tlhPhpI10kU06JHnrYXwg3+V6CaP2idsCXNef0aeslpqyITXQ74Vfk5uHgY7IG7XP0yIH8b42KSzHog==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.13.0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-skip-transparent-expression-wrappers': 7.15.4 + '@babel/plugin-proposal-optional-chaining': 7.14.5_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-async-generator-functions/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-2zt2g5vTXpMC3OmK6uyjvdXptbhBXfA77XGrd3gh93zwG8lZYBLOBImiGBEG0RANu3JqKEACCz5CGk73OJROBw==} engines: {node: '>=6.9.0'} @@ -1765,6 +2036,20 @@ packages: - supports-color dev: true + /@babel/plugin-proposal-async-generator-functions/7.15.8_@babel+core@7.15.8: + resolution: {integrity: sha512-2Z5F2R2ibINTc63mY7FLqGfEbmofrHU9FitJW1Q7aPaKFhiPvSq6QEt/BoWN5oME3GVyjcRuNNSRbb9LC0CSWA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-remap-async-to-generator': 7.15.4 + '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-proposal-class-properties/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg==} engines: {node: '>=6.9.0'} @@ -1790,6 +2075,19 @@ packages: - supports-color dev: true + /@babel/plugin-proposal-class-properties/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-class-features-plugin': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-proposal-class-static-block/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-M682XWrrLNk3chXCjoPUQWOyYsB93B9z3mRyjtqqYJWDf2mfCdIYgDrA11cgNVhAQieaq6F2fn2f3wI0U4aTjA==} engines: {node: '>=6.9.0'} @@ -1817,6 +2115,20 @@ packages: - supports-color dev: true + /@babel/plugin-proposal-class-static-block/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-M682XWrrLNk3chXCjoPUQWOyYsB93B9z3mRyjtqqYJWDf2mfCdIYgDrA11cgNVhAQieaq6F2fn2f3wI0U4aTjA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.12.0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-class-features-plugin': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-class-static-block': 7.14.5_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-proposal-decorators/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-WNER+YLs7avvRukEddhu5PSfSaMMimX2xBFgLQS7Bw16yrUxJGWidO9nQp+yLy9MVybg5Ba3BlhAw+BkdhpDmg==} engines: {node: '>=6.9.0'} @@ -1866,6 +2178,17 @@ packages: '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-dynamic-import/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-ExjiNYc3HDN5PXJx+bwC50GIx/KKanX2HiggnIUAYedbARdImiCU4RhhHfdf0Kd7JNXGpsBBBCOm+bBVy3Gb0g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-export-default-from/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-T8KZ5abXvKMjF6JcoXjgac3ElmXf0AWzJwi2O/42Jk+HmCky3D9+i1B7NPP1FblyceqTevKeV/9szeikFoaMDg==} engines: {node: '>=6.9.0'} @@ -1909,8 +2232,19 @@ packages: '@babel/plugin-syntax-export-namespace-from': 7.8.3_@babel+core@7.15.5 dev: true - /@babel/plugin-proposal-json-strings/7.14.5_@babel+core@7.15.0: - resolution: {integrity: sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ==} + /@babel/plugin-proposal-export-namespace-from/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-g5POA32bXPMmSBu5Dx/iZGLGnKmKPc5AiY7qfZgurzrCYgIztDlHFbznSNCoQuv57YQLnQfaDi7dxCtLDIdXdA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-export-namespace-from': 7.8.3_@babel+core@7.15.8 + dev: true + + /@babel/plugin-proposal-json-strings/7.14.5_@babel+core@7.15.0: + resolution: {integrity: sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -1930,6 +2264,17 @@ packages: '@babel/plugin-syntax-json-strings': 7.8.3_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-json-strings/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-json-strings': 7.8.3_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-logical-assignment-operators/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-YGn2AvZAo9TwyhlLvCCWxD90Xq8xJ4aSgaX3G5D/8DW94L8aaT+dS5cSP+Z06+rCJERGSr9GxMBZ601xoc2taw==} engines: {node: '>=6.9.0'} @@ -1951,6 +2296,17 @@ packages: '@babel/plugin-syntax-logical-assignment-operators': 7.10.4_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-logical-assignment-operators/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-YGn2AvZAo9TwyhlLvCCWxD90Xq8xJ4aSgaX3G5D/8DW94L8aaT+dS5cSP+Z06+rCJERGSr9GxMBZ601xoc2taw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-nullish-coalescing-operator/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg==} engines: {node: '>=6.9.0'} @@ -1972,6 +2328,17 @@ packages: '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-nullish-coalescing-operator/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-numeric-separator/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg==} engines: {node: '>=6.9.0'} @@ -1993,6 +2360,17 @@ packages: '@babel/plugin-syntax-numeric-separator': 7.10.4_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-numeric-separator/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-numeric-separator': 7.10.4_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-object-rest-spread/7.12.1_@babel+core@7.12.9: resolution: {integrity: sha512-s6SowJIjzlhx8o7lsFx5zmY4At6CTtDvgNQDdPzkBQucle58A6b/TTeEBYtyDgmcXjUTM+vE8YOGHZzzbc/ioA==} peerDependencies: @@ -2031,6 +2409,20 @@ packages: '@babel/plugin-transform-parameters': 7.15.4_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-object-rest-spread/7.15.6_@babel+core@7.15.8: + resolution: {integrity: sha512-qtOHo7A1Vt+O23qEAX+GdBpqaIuD3i9VRrWgCJeq7WO6H2d14EK3q11urj5Te2MAeK97nMiIdRpwd/ST4JFbNg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/compat-data': 7.15.0 + '@babel/core': 7.15.8 + '@babel/helper-compilation-targets': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-object-rest-spread': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-transform-parameters': 7.15.4_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-optional-catch-binding/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ==} engines: {node: '>=6.9.0'} @@ -2052,6 +2444,17 @@ packages: '@babel/plugin-syntax-optional-catch-binding': 7.8.3_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-optional-catch-binding/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-optional-catch-binding': 7.8.3_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-optional-chaining/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ==} engines: {node: '>=6.9.0'} @@ -2075,6 +2478,18 @@ packages: '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.15.5 dev: true + /@babel/plugin-proposal-optional-chaining/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-skip-transparent-expression-wrappers': 7.15.4 + '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.15.8 + dev: true + /@babel/plugin-proposal-private-methods/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g==} engines: {node: '>=6.9.0'} @@ -2100,6 +2515,19 @@ packages: - supports-color dev: true + /@babel/plugin-proposal-private-methods/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-class-features-plugin': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-proposal-private-property-in-object/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-X0UTixkLf0PCCffxgu5/1RQyGGbgZuKoI+vXP4iSbJSYwPb7hu06omsFGBvQ9lJEvwgrxHdS8B5nbfcd8GyUNA==} engines: {node: '>=6.9.0'} @@ -2129,6 +2557,21 @@ packages: - supports-color dev: true + /@babel/plugin-proposal-private-property-in-object/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-X0UTixkLf0PCCffxgu5/1RQyGGbgZuKoI+vXP4iSbJSYwPb7hu06omsFGBvQ9lJEvwgrxHdS8B5nbfcd8GyUNA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + '@babel/helper-create-class-features-plugin': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-private-property-in-object': 7.14.5_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-proposal-unicode-property-regex/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q==} engines: {node: '>=4'} @@ -2150,6 +2593,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-proposal-unicode-property-regex/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q==} + engines: {node: '>=4'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-regexp-features-plugin': 7.14.5_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-async-generators/7.8.4_@babel+core@7.15.0: resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} peerDependencies: @@ -2165,6 +2619,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-async-generators/7.8.4_@babel+core@7.15.8: + resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-bigint/7.8.3_@babel+core@7.15.0: @@ -2175,6 +2637,14 @@ packages: '@babel/core': 7.15.0 '@babel/helper-plugin-utils': 7.14.5 + /@babel/plugin-syntax-bigint/7.8.3_@babel+core@7.15.5: + resolution: {integrity: sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.5 + '@babel/helper-plugin-utils': 7.14.5 + /@babel/plugin-syntax-class-properties/7.12.13_@babel+core@7.15.0: resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} peerDependencies: @@ -2190,6 +2660,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-class-properties/7.12.13_@babel+core@7.15.8: + resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-class-static-block/7.14.5_@babel+core@7.15.0: @@ -2211,6 +2689,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-syntax-class-static-block/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-decorators/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-c4sZMRWL4GSvP1EXy0woIP7m4jkVcEuG8R1TOZxPBPtp4FSM/kiPZub9UIs/Jrb5ZAOzvTUSGYrWsrSu1JvoPw==} engines: {node: '>=6.9.0'} @@ -2248,6 +2736,15 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-syntax-dynamic-import/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-export-default-from/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-snWDxjuaPEobRBnhpqEfZ8RMxDbHt8+87fiEioGuE+Uc0xAKgSD8QiuL3lF93hPVQfZFAcYwrrf+H5qUhike3Q==} engines: {node: '>=6.9.0'} @@ -2285,6 +2782,15 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-syntax-export-namespace-from/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-flow/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-9WK5ZwKCdWHxVuU13XNT6X73FGmutAXeor5lGFq6qhOFtMFUF4jkbijuyUdZZlpYq6E2hZeZf/u3959X9wsv0Q==} engines: {node: '>=6.9.0'} @@ -2303,6 +2809,14 @@ packages: '@babel/core': 7.15.0 '@babel/helper-plugin-utils': 7.14.5 + /@babel/plugin-syntax-import-meta/7.10.4_@babel+core@7.15.5: + resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.5 + '@babel/helper-plugin-utils': 7.14.5 + /@babel/plugin-syntax-json-strings/7.8.3_@babel+core@7.15.0: resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} peerDependencies: @@ -2318,6 +2832,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-json-strings/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-jsx/7.12.1_@babel+core@7.12.9: @@ -2357,6 +2879,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-syntax-jsx/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-ohuFIsOMXJnbOMRfX7/w7LocdR6R7whhuRD4ax8IipLcLPlZGJKkBxgHp++U4N/vKyU16/YDQr2f5seajD3jIw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-logical-assignment-operators/7.10.4_@babel+core@7.15.0: resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} peerDependencies: @@ -2372,6 +2904,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-logical-assignment-operators/7.10.4_@babel+core@7.15.8: + resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-nullish-coalescing-operator/7.8.3_@babel+core@7.15.0: @@ -2389,6 +2929,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-nullish-coalescing-operator/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-numeric-separator/7.10.4_@babel+core@7.15.0: @@ -2406,6 +2954,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-numeric-separator/7.10.4_@babel+core@7.15.8: + resolution: {integrity: sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-object-rest-spread/7.8.3_@babel+core@7.12.9: @@ -2432,6 +2988,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-object-rest-spread/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-optional-catch-binding/7.8.3_@babel+core@7.15.0: @@ -2449,6 +3013,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-optional-catch-binding/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-optional-chaining/7.8.3_@babel+core@7.15.0: @@ -2466,6 +3038,14 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-optional-chaining/7.8.3_@babel+core@7.15.8: + resolution: {integrity: sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-private-property-in-object/7.14.5_@babel+core@7.15.0: @@ -2487,6 +3067,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-syntax-private-property-in-object/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-syntax-top-level-await/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} engines: {node: '>=6.9.0'} @@ -2504,6 +3094,15 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-top-level-await/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-syntax-typescript/7.14.5_@babel+core@7.15.0: @@ -2523,6 +3122,15 @@ packages: dependencies: '@babel/core': 7.15.5 '@babel/helper-plugin-utils': 7.14.5 + + /@babel/plugin-syntax-typescript/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-u6OXzDaIXjEstBRRoBCQ/uKQKlbuaeE5in0RvWdA4pN6AhqxTIwUsnHPU1CFZA/amYObMsuWhYfRl3Ch90HD0Q==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 dev: true /@babel/plugin-transform-arrow-functions/7.14.5_@babel+core@7.15.0: @@ -2544,6 +3152,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-arrow-functions/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-KOnO0l4+tD5IfOdi4x8C1XmEIRWUjNRV8wc6K2vz/3e8yAOoZZvsRXRRIF/yo/MAOFb4QjtAw9xSxMXbSMRy8A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-async-to-generator/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA==} engines: {node: '>=6.9.0'} @@ -2571,6 +3189,20 @@ packages: - supports-color dev: true + /@babel/plugin-transform-async-to-generator/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-module-imports': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-remap-async-to-generator': 7.15.4 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-block-scoped-functions/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ==} engines: {node: '>=6.9.0'} @@ -2590,6 +3222,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-block-scoped-functions/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-block-scoping/7.15.3_@babel+core@7.15.0: resolution: {integrity: sha512-nBAzfZwZb4DkaGtOes1Up1nOAp9TDRRFw4XBzBBSG9QK7KVFmYzgj9o9sbPv7TX5ofL4Auq4wZnxCoPnI/lz2Q==} engines: {node: '>=6.9.0'} @@ -2609,6 +3251,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-block-scoping/7.15.3_@babel+core@7.15.8: + resolution: {integrity: sha512-nBAzfZwZb4DkaGtOes1Up1nOAp9TDRRFw4XBzBBSG9QK7KVFmYzgj9o9sbPv7TX5ofL4Auq4wZnxCoPnI/lz2Q==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-classes/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-Yjvhex8GzBmmPQUvpXRPWQ9WnxXgAFuZSrqOK/eJlOGIXwvv8H3UEdUigl1gb/bnjTrln+e8bkZUYCBt/xYlBg==} engines: {node: '>=6.9.0'} @@ -2644,6 +3296,24 @@ packages: - supports-color dev: true + /@babel/plugin-transform-classes/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-Yjvhex8GzBmmPQUvpXRPWQ9WnxXgAFuZSrqOK/eJlOGIXwvv8H3UEdUigl1gb/bnjTrln+e8bkZUYCBt/xYlBg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + '@babel/helper-function-name': 7.15.4 + '@babel/helper-optimise-call-expression': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-replace-supers': 7.15.4 + '@babel/helper-split-export-declaration': 7.15.4 + globals: 11.12.0 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-computed-properties/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg==} engines: {node: '>=6.9.0'} @@ -2663,6 +3333,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-computed-properties/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-destructuring/7.14.7_@babel+core@7.15.0: resolution: {integrity: sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw==} engines: {node: '>=6.9.0'} @@ -2682,6 +3362,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-destructuring/7.14.7_@babel+core@7.15.8: + resolution: {integrity: sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-dotall-regex/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw==} engines: {node: '>=6.9.0'} @@ -2703,6 +3393,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-dotall-regex/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-regexp-features-plugin': 7.14.5_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-duplicate-keys/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A==} engines: {node: '>=6.9.0'} @@ -2722,6 +3423,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-duplicate-keys/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-exponentiation-operator/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA==} engines: {node: '>=6.9.0'} @@ -2743,6 +3454,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-exponentiation-operator/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-builder-binary-assignment-operator-visitor': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-flow-strip-types/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-KhcolBKfXbvjwI3TV7r7TkYm8oNXHNBqGOy6JDVwtecFaRoKYsUUqJdS10q0YDKW1c6aZQgO+Ys3LfGkox8pXA==} engines: {node: '>=6.9.0'} @@ -2773,6 +3495,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-for-of/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-DRTY9fA751AFBDh2oxydvVm4SYevs5ILTWLs6xKXps4Re/KG5nfUkr+TdHCrRWB8C69TlzVgA9b3RmGWmgN9LA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-function-name/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ==} engines: {node: '>=6.9.0'} @@ -2794,6 +3526,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-function-name/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-function-name': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-literals/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A==} engines: {node: '>=6.9.0'} @@ -2813,6 +3556,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-literals/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-member-expression-literals/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q==} engines: {node: '>=6.9.0'} @@ -2832,26 +3585,50 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-member-expression-literals/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-modules-amd/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.15.0 + '@babel/core': 7.15.0 + '@babel/helper-module-transforms': 7.15.7 + '@babel/helper-plugin-utils': 7.14.5 + babel-plugin-dynamic-import-node: 2.3.3 + transitivePeerDependencies: + - supports-color + + /@babel/plugin-transform-modules-amd/7.14.5_@babel+core@7.15.5: + resolution: {integrity: sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.5 '@babel/helper-module-transforms': 7.15.7 '@babel/helper-plugin-utils': 7.14.5 babel-plugin-dynamic-import-node: 2.3.3 transitivePeerDependencies: - supports-color + dev: true - /@babel/plugin-transform-modules-amd/7.14.5_@babel+core@7.15.5: + /@babel/plugin-transform-modules-amd/7.14.5_@babel+core@7.15.8: resolution: {integrity: sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.15.5 + '@babel/core': 7.15.8 '@babel/helper-module-transforms': 7.15.7 '@babel/helper-plugin-utils': 7.14.5 babel-plugin-dynamic-import-node: 2.3.3 @@ -2888,6 +3665,21 @@ packages: - supports-color dev: true + /@babel/plugin-transform-modules-commonjs/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-qg4DPhwG8hKp4BbVDvX1s8cohM8a6Bvptu4l6Iingq5rW+yRUAhe/YRup/YcW2zCOlrysEWVhftIcKzrEZv3sA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-module-transforms': 7.15.7 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-simple-access': 7.15.4 + babel-plugin-dynamic-import-node: 2.3.3 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-modules-systemjs/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-fJUnlQrl/mezMneR72CKCgtOoahqGJNVKpompKwzv3BrEXdlPspTcyxrZ1XmDTIr9PpULrgEQo3qNKp6dW7ssw==} engines: {node: '>=6.9.0'} @@ -2919,6 +3711,22 @@ packages: - supports-color dev: true + /@babel/plugin-transform-modules-systemjs/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-fJUnlQrl/mezMneR72CKCgtOoahqGJNVKpompKwzv3BrEXdlPspTcyxrZ1XmDTIr9PpULrgEQo3qNKp6dW7ssw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-hoist-variables': 7.15.4 + '@babel/helper-module-transforms': 7.15.7 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-validator-identifier': 7.15.7 + babel-plugin-dynamic-import-node: 2.3.3 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-modules-umd/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA==} engines: {node: '>=6.9.0'} @@ -2944,6 +3752,19 @@ packages: - supports-color dev: true + /@babel/plugin-transform-modules-umd/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-module-transforms': 7.15.7 + '@babel/helper-plugin-utils': 7.14.5 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-named-capturing-groups-regex/7.14.9_@babel+core@7.15.0: resolution: {integrity: sha512-l666wCVYO75mlAtGFfyFwnWmIXQm3kSH0C3IRnJqWcZbWkoihyAdDhFm2ZWaxWTqvBvhVFfJjMRQ0ez4oN1yYA==} engines: {node: '>=6.9.0'} @@ -2963,6 +3784,16 @@ packages: '@babel/helper-create-regexp-features-plugin': 7.14.5_@babel+core@7.15.5 dev: true + /@babel/plugin-transform-named-capturing-groups-regex/7.14.9_@babel+core@7.15.8: + resolution: {integrity: sha512-l666wCVYO75mlAtGFfyFwnWmIXQm3kSH0C3IRnJqWcZbWkoihyAdDhFm2ZWaxWTqvBvhVFfJjMRQ0ez4oN1yYA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-regexp-features-plugin': 7.14.5_@babel+core@7.15.8 + dev: true + /@babel/plugin-transform-new-target/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ==} engines: {node: '>=6.9.0'} @@ -2982,6 +3813,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-new-target/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-object-super/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg==} engines: {node: '>=6.9.0'} @@ -3007,6 +3848,19 @@ packages: - supports-color dev: true + /@babel/plugin-transform-object-super/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-replace-supers': 7.15.4 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-parameters/7.15.4_@babel+core@7.12.9: resolution: {integrity: sha512-9WB/GUTO6lvJU3XQsSr6J/WKvBC2hcs4Pew8YxZagi6GkTdniyqp8On5kqdK8MN0LMeu0mGbhPN+O049NV/9FQ==} engines: {node: '>=6.9.0'} @@ -3036,6 +3890,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-parameters/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-9WB/GUTO6lvJU3XQsSr6J/WKvBC2hcs4Pew8YxZagi6GkTdniyqp8On5kqdK8MN0LMeu0mGbhPN+O049NV/9FQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-property-literals/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw==} engines: {node: '>=6.9.0'} @@ -3055,6 +3919,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-property-literals/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-react-display-name/7.15.1_@babel+core@7.15.0: resolution: {integrity: sha512-yQZ/i/pUCJAHI/LbtZr413S3VT26qNrEm0M5RRxQJA947/YNYwbZbBaXGDrq6CG5QsZycI1VIP6d7pQaBfP+8Q==} engines: {node: '>=6.9.0'} @@ -3074,6 +3948,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-react-display-name/7.15.1_@babel+core@7.15.8: + resolution: {integrity: sha512-yQZ/i/pUCJAHI/LbtZr413S3VT26qNrEm0M5RRxQJA947/YNYwbZbBaXGDrq6CG5QsZycI1VIP6d7pQaBfP+8Q==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-react-jsx-development/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-rdwG/9jC6QybWxVe2UVOa7q6cnTpw8JRRHOxntG/h6g/guAOe6AhtQHJuJh5FwmnXIT1bdm5vC2/5huV8ZOorQ==} engines: {node: '>=6.9.0'} @@ -3093,6 +3977,16 @@ packages: '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.5 dev: true + /@babel/plugin-transform-react-jsx-development/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-rdwG/9jC6QybWxVe2UVOa7q6cnTpw8JRRHOxntG/h6g/guAOe6AhtQHJuJh5FwmnXIT1bdm5vC2/5huV8ZOorQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.8 + dev: true + /@babel/plugin-transform-react-jsx/7.14.9_@babel+core@7.15.0: resolution: {integrity: sha512-30PeETvS+AeD1f58i1OVyoDlVYQhap/K20ZrMjLmmzmC2AYR/G43D4sdJAaDAqCD3MYpSWbmrz3kES158QSLjw==} engines: {node: '>=6.9.0'} @@ -3120,6 +4014,20 @@ packages: '@babel/types': 7.15.6 dev: true + /@babel/plugin-transform-react-jsx/7.14.9_@babel+core@7.15.8: + resolution: {integrity: sha512-30PeETvS+AeD1f58i1OVyoDlVYQhap/K20ZrMjLmmzmC2AYR/G43D4sdJAaDAqCD3MYpSWbmrz3kES158QSLjw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + '@babel/helper-module-imports': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-jsx': 7.14.5_@babel+core@7.15.8 + '@babel/types': 7.15.6 + dev: true + /@babel/plugin-transform-react-pure-annotations/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-3X4HpBJimNxW4rhUy/SONPyNQHp5YRr0HhJdT2OH1BRp0of7u3Dkirc7x9FRJMKMqTBI079VZ1hzv7Ouuz///g==} engines: {node: '>=6.9.0'} @@ -3141,6 +4049,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-react-pure-annotations/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-3X4HpBJimNxW4rhUy/SONPyNQHp5YRr0HhJdT2OH1BRp0of7u3Dkirc7x9FRJMKMqTBI079VZ1hzv7Ouuz///g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-annotate-as-pure': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-regenerator/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg==} engines: {node: '>=6.9.0'} @@ -3160,6 +4079,16 @@ packages: regenerator-transform: 0.14.5 dev: true + /@babel/plugin-transform-regenerator/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + regenerator-transform: 0.14.5 + dev: true + /@babel/plugin-transform-reserved-words/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg==} engines: {node: '>=6.9.0'} @@ -3179,6 +4108,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-reserved-words/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-runtime/7.15.0_@babel+core@7.15.0: resolution: {integrity: sha512-sfHYkLGjhzWTq6xsuQ01oEsUYjkHRux9fW1iUA68dC7Qd8BS1Unq4aZ8itmQp95zUzIcyR2EbNMTzAicFj+guw==} engines: {node: '>=6.9.0'} @@ -3195,6 +4134,23 @@ packages: transitivePeerDependencies: - supports-color + /@babel/plugin-transform-runtime/7.15.0_@babel+core@7.15.5: + resolution: {integrity: sha512-sfHYkLGjhzWTq6xsuQ01oEsUYjkHRux9fW1iUA68dC7Qd8BS1Unq4aZ8itmQp95zUzIcyR2EbNMTzAicFj+guw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.5 + '@babel/helper-module-imports': 7.15.4 + '@babel/helper-plugin-utils': 7.14.5 + babel-plugin-polyfill-corejs2: 0.2.2_@babel+core@7.15.5 + babel-plugin-polyfill-corejs3: 0.2.4_@babel+core@7.15.5 + babel-plugin-polyfill-regenerator: 0.2.2_@babel+core@7.15.5 + semver: 6.3.0 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-shorthand-properties/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g==} engines: {node: '>=6.9.0'} @@ -3214,6 +4170,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-shorthand-properties/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-spread/7.14.6_@babel+core@7.15.0: resolution: {integrity: sha512-Zr0x0YroFJku7n7+/HH3A2eIrGMjbmAIbJSVv0IZ+t3U2WUQUA64S/oeied2e+MaGSjmt4alzBCsK9E8gh+fag==} engines: {node: '>=6.9.0'} @@ -3235,6 +4201,17 @@ packages: '@babel/helper-skip-transparent-expression-wrappers': 7.15.4 dev: true + /@babel/plugin-transform-spread/7.15.8_@babel+core@7.15.8: + resolution: {integrity: sha512-/daZ8s2tNaRekl9YJa9X4bzjpeRZLt122cpgFnQPLGUe61PH8zMEBmYqKkW5xF5JUEh5buEGXJoQpqBmIbpmEQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-skip-transparent-expression-wrappers': 7.15.4 + dev: true + /@babel/plugin-transform-sticky-regex/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A==} engines: {node: '>=6.9.0'} @@ -3254,6 +4231,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-sticky-regex/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-template-literals/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg==} engines: {node: '>=6.9.0'} @@ -3273,6 +4260,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-template-literals/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-typeof-symbol/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw==} engines: {node: '>=6.9.0'} @@ -3292,6 +4289,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-typeof-symbol/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-typescript/7.15.4_@babel+core@7.15.0: resolution: {integrity: sha512-sM1/FEjwYjXvMwu1PJStH11kJ154zd/lpY56NQJ5qH2D0mabMv1CAy/kdvS9RP4Xgfj9fBBA3JiSLdDHgXdzOA==} engines: {node: '>=6.9.0'} @@ -3319,6 +4326,20 @@ packages: - supports-color dev: true + /@babel/plugin-transform-typescript/7.15.4_@babel+core@7.15.8: + resolution: {integrity: sha512-sM1/FEjwYjXvMwu1PJStH11kJ154zd/lpY56NQJ5qH2D0mabMv1CAy/kdvS9RP4Xgfj9fBBA3JiSLdDHgXdzOA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-class-features-plugin': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-syntax-typescript': 7.14.5_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/plugin-transform-unicode-escapes/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA==} engines: {node: '>=6.9.0'} @@ -3338,6 +4359,16 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-unicode-escapes/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/plugin-transform-unicode-regex/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw==} engines: {node: '>=6.9.0'} @@ -3359,6 +4390,17 @@ packages: '@babel/helper-plugin-utils': 7.14.5 dev: true + /@babel/plugin-transform-unicode-regex/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-create-regexp-features-plugin': 7.14.5_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + dev: true + /@babel/preset-env/7.15.0_@babel+core@7.15.0: resolution: {integrity: sha512-FhEpCNFCcWW3iZLg0L2NPE9UerdtsCR6ZcsGHUX6Om6kbCQeL5QZDqFDmeNHC6/fy6UH3jEge7K4qG5uC9In0Q==} engines: {node: '>=6.9.0'} @@ -3610,6 +4652,90 @@ packages: - supports-color dev: true + /@babel/preset-env/7.15.8_@babel+core@7.15.8: + resolution: {integrity: sha512-rCC0wH8husJgY4FPbHsiYyiLxSY8oMDJH7Rl6RQMknbN9oDDHhM9RDFvnGM2MgkbUJzSQB4gtuwygY5mCqGSsA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/compat-data': 7.15.0 + '@babel/core': 7.15.8 + '@babel/helper-compilation-targets': 7.15.4_@babel+core@7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-validator-option': 7.14.5 + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-proposal-async-generator-functions': 7.15.8_@babel+core@7.15.8 + '@babel/plugin-proposal-class-properties': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-class-static-block': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-proposal-dynamic-import': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-export-namespace-from': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-json-strings': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-logical-assignment-operators': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-nullish-coalescing-operator': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-numeric-separator': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-object-rest-spread': 7.15.6_@babel+core@7.15.8 + '@babel/plugin-proposal-optional-catch-binding': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-optional-chaining': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-private-methods': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-proposal-private-property-in-object': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-proposal-unicode-property-regex': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.15.8 + '@babel/plugin-syntax-class-properties': 7.12.13_@babel+core@7.15.8 + '@babel/plugin-syntax-class-static-block': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-export-namespace-from': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-json-strings': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4_@babel+core@7.15.8 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-numeric-separator': 7.10.4_@babel+core@7.15.8 + '@babel/plugin-syntax-object-rest-spread': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-optional-catch-binding': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.15.8 + '@babel/plugin-syntax-private-property-in-object': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-syntax-top-level-await': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-arrow-functions': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-async-to-generator': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-block-scoped-functions': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-block-scoping': 7.15.3_@babel+core@7.15.8 + '@babel/plugin-transform-classes': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-transform-computed-properties': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-destructuring': 7.14.7_@babel+core@7.15.8 + '@babel/plugin-transform-dotall-regex': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-duplicate-keys': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-exponentiation-operator': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-for-of': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-transform-function-name': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-literals': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-member-expression-literals': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-modules-amd': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-modules-commonjs': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-transform-modules-systemjs': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-transform-modules-umd': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-named-capturing-groups-regex': 7.14.9_@babel+core@7.15.8 + '@babel/plugin-transform-new-target': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-object-super': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-parameters': 7.15.4_@babel+core@7.15.8 + '@babel/plugin-transform-property-literals': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-regenerator': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-reserved-words': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-shorthand-properties': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-spread': 7.15.8_@babel+core@7.15.8 + '@babel/plugin-transform-sticky-regex': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-template-literals': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-typeof-symbol': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-unicode-escapes': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-unicode-regex': 7.14.5_@babel+core@7.15.8 + '@babel/preset-modules': 0.1.4_@babel+core@7.15.8 + '@babel/types': 7.15.6 + babel-plugin-polyfill-corejs2: 0.2.2_@babel+core@7.15.8 + babel-plugin-polyfill-corejs3: 0.2.5_@babel+core@7.15.8 + babel-plugin-polyfill-regenerator: 0.2.2_@babel+core@7.15.8 + core-js-compat: 3.18.0 + semver: 6.3.0 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/preset-flow/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-pP5QEb4qRUSVGzzKx9xqRuHUrM/jEzMqdrZpdMA+oUCRgd5zM1qGr5y5+ZgAL/1tVv1H0dyk5t4SKJntqyiVtg==} engines: {node: '>=6.9.0'} @@ -3647,6 +4773,19 @@ packages: esutils: 2.0.3 dev: true + /@babel/preset-modules/0.1.4_@babel+core@7.15.8: + resolution: {integrity: sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/plugin-proposal-unicode-property-regex': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-dotall-regex': 7.14.5_@babel+core@7.15.8 + '@babel/types': 7.15.6 + esutils: 2.0.3 + dev: true + /@babel/preset-react/7.14.5_@babel+core@7.15.0: resolution: {integrity: sha512-XFxBkjyObLvBaAvkx1Ie95Iaq4S/GUEIrejyrntQ/VCMKUYvKLoyKxOBzJ2kjA3b6rC9/KL6KXfDC2GqvLiNqQ==} engines: {node: '>=6.9.0'} @@ -3667,13 +4806,28 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.15.5 + '@babel/core': 7.15.5 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-validator-option': 7.14.5 + '@babel/plugin-transform-react-display-name': 7.15.1_@babel+core@7.15.5 + '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.5 + '@babel/plugin-transform-react-jsx-development': 7.14.5_@babel+core@7.15.5 + '@babel/plugin-transform-react-pure-annotations': 7.14.5_@babel+core@7.15.5 + dev: true + + /@babel/preset-react/7.14.5_@babel+core@7.15.8: + resolution: {integrity: sha512-XFxBkjyObLvBaAvkx1Ie95Iaq4S/GUEIrejyrntQ/VCMKUYvKLoyKxOBzJ2kjA3b6rC9/KL6KXfDC2GqvLiNqQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 '@babel/helper-plugin-utils': 7.14.5 '@babel/helper-validator-option': 7.14.5 - '@babel/plugin-transform-react-display-name': 7.15.1_@babel+core@7.15.5 - '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.5 - '@babel/plugin-transform-react-jsx-development': 7.14.5_@babel+core@7.15.5 - '@babel/plugin-transform-react-pure-annotations': 7.14.5_@babel+core@7.15.5 + '@babel/plugin-transform-react-display-name': 7.15.1_@babel+core@7.15.8 + '@babel/plugin-transform-react-jsx': 7.14.9_@babel+core@7.15.8 + '@babel/plugin-transform-react-jsx-development': 7.14.5_@babel+core@7.15.8 + '@babel/plugin-transform-react-pure-annotations': 7.14.5_@babel+core@7.15.8 dev: true /@babel/preset-typescript/7.15.0_@babel+core@7.15.0: @@ -3703,6 +4857,20 @@ packages: - supports-color dev: true + /@babel/preset-typescript/7.15.0_@babel+core@7.15.8: + resolution: {integrity: sha512-lt0Y/8V3y06Wq/8H/u0WakrqciZ7Fz7mwPDHWUJAXlABL5hiUG42BNlRXiELNjeWjO5rWmnNKlx+yzJvxezHow==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-plugin-utils': 7.14.5 + '@babel/helper-validator-option': 7.14.5 + '@babel/plugin-transform-typescript': 7.15.4_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /@babel/register/7.15.3_@babel+core@7.15.0: resolution: {integrity: sha512-mj4IY1ZJkorClxKTImccn4T81+UKTo4Ux0+OFSV9hME1ooqS9UV+pJ6BjD0qXPK4T3XW/KNa79XByjeEMZz+fw==} engines: {node: '>=6.9.0'} @@ -3762,8 +4930,8 @@ packages: resolution: {integrity: sha512-UgBAfEa1oGuYgDIPM2G+aHa4Nlo9Lh6mGD2bDBGMTbYnc38vulXPuC1MGjYILIEmlwl6Rd+BPR9ee3gm20CBtg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.14.5 - '@babel/parser': 7.15.7 + '@babel/code-frame': 7.15.8 + '@babel/parser': 7.15.8 '@babel/types': 7.15.6 /@babel/traverse/7.15.0: @@ -4521,7 +5689,7 @@ packages: resolution: {integrity: sha512-xmB5vh81KK8DiiCMtI5vI59mP+GggNmc9BiN+fg4mKdQHV369+WuZc1Lq2xWFCOCsRPHt24D9h7Idp4YaMB1Ww==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/core': 7.15.0 + '@babel/core': 7.15.5 '@jest/types': 27.1.1 babel-plugin-istanbul: 6.0.0 chalk: 4.1.2 @@ -5002,7 +6170,7 @@ packages: resolution: {integrity: sha512-dNZafjM93Y+F+sfwTO5gTpsGXlnc/0Q+c2+62ViqP3gkMWvHEMSKkaEHgVJLcLg3i/g19GSIPziiKpgyne07Bw==} engines: {node: '>=8'} dependencies: - debug: 4.3.1 + debug: 4.3.2 transitivePeerDependencies: - supports-color dev: true @@ -5017,6 +6185,16 @@ packages: size-limit: 5.0.3 dev: true + /@size-limit/file/6.0.3_size-limit@6.0.3: + resolution: {integrity: sha512-OfDrkJBB7OAWtnedz6jpmL1pjlha1MpgtvYwUSP2442qB96nwMN5Ig78XR3ldPj2cbxq1FVoNnc2vfWMi40vQA==} + engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + peerDependencies: + size-limit: 6.0.3 + dependencies: + semver: 7.3.5 + size-limit: 6.0.3 + dev: true + /@size-limit/preset-app/4.10.2_size-limit@5.0.3: resolution: {integrity: sha512-B/+okE4Jn/N4rqIhy+ZpgdQ72BMQwpkxIHp+rCdFDib1H7VVbgLwyei9mfIco4cKNzk/EkQ6wd4Hyit6OsY0pQ==} peerDependencies: @@ -5031,6 +6209,20 @@ packages: - utf-8-validate dev: true + /@size-limit/preset-app/6.0.3_size-limit@6.0.3: + resolution: {integrity: sha512-pfCJNmQsqDHYdaxRXI/LtTuUpElHVjFH5COkRoDhokCoazhZVvSRT6rvWsNbk9ONM8vg2n5vVOpzWe2vp2yYwg==} + peerDependencies: + size-limit: 6.0.3 + dependencies: + '@size-limit/file': 6.0.3_size-limit@6.0.3 + '@size-limit/time': 6.0.3_size-limit@6.0.3 + size-limit: 6.0.3 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate + dev: true + /@size-limit/time/4.10.2_size-limit@5.0.3: resolution: {integrity: sha512-zvpCDojR0+B1gHCAiLWCm4eLlapLMZYuNLE+SVOn0QR1/L9UwERFvXy5/sIJO62qX/MNusyhBmC2NkqB9gOtjg==} peerDependencies: @@ -5045,6 +6237,21 @@ packages: - utf-8-validate dev: true + /@size-limit/time/6.0.3_size-limit@6.0.3: + resolution: {integrity: sha512-p6JpZg1wUr7e4ja9NozXo7IqdodcPEHswr4TeiruvhcMILGkUbSu8+fQ0kDTZt1Gju8BrsFvIWAiC+TWd07pqw==} + engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + peerDependencies: + size-limit: 6.0.3 + dependencies: + estimo: 2.2.8 + react: 17.0.2 + size-limit: 6.0.3 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate + dev: true + /@storybook/addon-a11y/6.3.8_react@17.0.2: resolution: {integrity: sha512-Ili7hX+l4s9ILc/Hp19PoS9P942+139oawkzW5aW3Z6iwmP5J0ySXT4xcF9tFe2X8PeNTk5t2wXEUtBjmoE9Sg==} peerDependencies: @@ -6617,6 +7824,13 @@ packages: '@types/unist': 2.0.6 dev: true + /@types/hoist-non-react-statics/3.3.1: + resolution: {integrity: sha512-iMIqiko6ooLrTh1joXodJK5X9xeEALT1kM5G3ZLhD3hszxBdIEd5C75U834D9mLcINgD4OyZf5uQXjkuYydWvA==} + dependencies: + '@types/react': 17.0.22 + hoist-non-react-statics: 3.3.2 + dev: false + /@types/html-minifier-terser/5.1.2: resolution: {integrity: sha512-h4lTMgMJctJybDp8CQrxTUiiYmedihHWkjnF/8Pxseu2S6Nlfcy8kwboQ8yejh456rP2yWoEVm1sS/FVsfM48w==} dev: true @@ -6748,6 +7962,15 @@ packages: dependencies: '@types/react': 16.14.15 + /@types/react-redux/7.1.20: + resolution: {integrity: sha512-q42es4c8iIeTgcnB+yJgRTTzftv3eYYvCZOh1Ckn2eX/3o5TdsQYKUWpLoLuGlcY/p+VAhV9IOEZJcWk/vfkXw==} + dependencies: + '@types/hoist-non-react-statics': 3.3.1 + '@types/react': 17.0.22 + hoist-non-react-statics: 3.3.2 + redux: 4.1.1 + dev: false + /@types/react-syntax-highlighter/11.0.5: resolution: {integrity: sha512-VIOi9i2Oj5XsmWWoB72p3KlZoEbdRAcechJa8Ztebw7bDl2YmR+odxIqhtJGp1q2EozHs02US+gzxJ9nuf56qg==} dependencies: @@ -6773,7 +7996,6 @@ packages: '@types/prop-types': 15.7.4 '@types/scheduler': 0.16.2 csstype: 3.0.9 - dev: true /@types/resolve/1.17.1: resolution: {integrity: sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw==} @@ -7151,7 +8373,7 @@ packages: webpack: 4.x.x || 5.x.x webpack-cli: 4.x.x dependencies: - webpack: 5.51.1_webpack-cli@4.8.0 + webpack: 5.51.1 webpack-cli: 4.8.0_webpack@5.51.1 /@webpack-cli/info/1.3.0_webpack-cli@4.8.0: @@ -7326,6 +8548,15 @@ packages: dependencies: '@babel/core': 7.15.0 + /@wordpress/babel-plugin-import-jsx-pragma/3.1.0_@babel+core@7.15.5: + resolution: {integrity: sha512-518mL3goaSeXtJCQcPK9OYHUUiA0sjXuoGWHBwRalkyTIQZZy5ZZzlwrlSc9ESZcOw9BZ+Uo8CJRjV2OWnx+Zw==} + engines: {node: '>=12'} + peerDependencies: + '@babel/core': ^7.12.9 + dependencies: + '@babel/core': 7.15.5 + dev: true + /@wordpress/babel-preset-default/6.3.2: resolution: {integrity: sha512-RKKO5rhUlEtYYd2kHRkuSY97irq+MTxPYy/IJzM5D8Z17irasNRWs1GwOlbelewHUXA9BIHkX465R5ec7D7OHw==} engines: {node: '>=12'} @@ -8332,7 +9563,7 @@ packages: resolution: {integrity: sha512-nVR6V9kPxl8+aYQzQJdoDt+aKBKHHD0zplcYZbu2MHxjmHMvppAeL9mjzVhQZj/3n10NR2Ftk94mHQzHWfhCCg==} engines: {node: '>=12'} dependencies: - '@babel/runtime': 7.15.3 + '@babel/runtime': 7.15.4 /@wordpress/html-entities/3.2.1: resolution: {integrity: sha512-DHuIQ7MMyAcmkMM/VY8RibIcLiIcstk6Og09f4EWQegOgage6yMgnG7eI0nf2LBe65mttnda1EL51slc7XjaXg==} @@ -9506,6 +10737,22 @@ packages: normalize-range: 0.1.2 postcss-value-parser: 4.1.0 + /autoprefixer/10.3.4_postcss@8.3.11: + resolution: {integrity: sha512-EKjKDXOq7ug+jagLzmnoTRpTT0q1KVzEJqrJd0hCBa7FiG0WbFOBCcJCy2QkW1OckpO3qgttA1aWjVbeIPAecw==} + engines: {node: ^10 || ^12 || >=14} + hasBin: true + peerDependencies: + postcss: ^8.1.0 + dependencies: + browserslist: 4.17.0 + caniuse-lite: 1.0.30001258 + colorette: 1.4.0 + fraction.js: 4.1.1 + normalize-range: 0.1.2 + postcss: 8.3.11 + postcss-value-parser: 4.1.0 + dev: true + /autoprefixer/9.8.6: resolution: {integrity: sha512-XrvP4VVHdRBCdX1S3WXVD8+RyG9qeb1D5Sn1DeLiG2xfSpzellk5k54xbUERJ3M5DggQxes39UGOTP8CFrEGbg==} hasBin: true @@ -9686,6 +10933,24 @@ packages: transitivePeerDependencies: - supports-color + /babel-jest/27.2.1_@babel+core@7.15.5: + resolution: {integrity: sha512-kkaekSJHew1zfDW3cA2QiSBPg4uiLpiW0OwJKqFv0r2/mFgym/IBn7hxPntL6FvS66G/ROh+lz4pRiCJAH1/UQ==} + engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} + peerDependencies: + '@babel/core': ^7.8.0 + dependencies: + '@babel/core': 7.15.5 + '@jest/transform': 27.2.1 + '@jest/types': 27.1.1 + '@types/babel__core': 7.1.16 + babel-plugin-istanbul: 6.0.0 + babel-preset-jest: 27.2.0_@babel+core@7.15.5 + chalk: 4.1.2 + graceful-fs: 4.2.8 + slash: 3.0.0 + transitivePeerDependencies: + - supports-color + /babel-loader/8.2.2_080b9887a086cbf3e61f158e7c92b566: resolution: {integrity: sha512-JvTd0/D889PQBtUXJ2PXaKU/pjZDMtHA9V2ecm+eNRmmBCMR09a+fmpGTNwnJtFmFl5Ei7Vy47LjBb+L0wQ99g==} engines: {node: '>= 8.9'} @@ -9913,6 +11178,19 @@ packages: - supports-color dev: true + /babel-plugin-polyfill-corejs2/0.2.2_@babel+core@7.15.8: + resolution: {integrity: sha512-kISrENsJ0z5dNPq5eRvcctITNHYXWOA4DUZRFYCz3jYCcvTb/A546LIddmoGNMVYg2U38OyFeNosQwI9ENTqIQ==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/compat-data': 7.15.0 + '@babel/core': 7.15.8 + '@babel/helper-define-polyfill-provider': 0.2.3_@babel+core@7.15.8 + semver: 6.3.0 + transitivePeerDependencies: + - supports-color + dev: true + /babel-plugin-polyfill-corejs3/0.1.7_@babel+core@7.15.0: resolution: {integrity: sha512-u+gbS9bbPhZWEeyy1oR/YaaSpod/KDT07arZHb80aTpl8H5ZBq+uN1nN9/xtX7jQyfLdPfoqI4Rue/MQSWJquw==} peerDependencies: @@ -9960,6 +11238,18 @@ packages: - supports-color dev: true + /babel-plugin-polyfill-corejs3/0.2.5_@babel+core@7.15.8: + resolution: {integrity: sha512-ninF5MQNwAX9Z7c9ED+H2pGt1mXdP4TqzlHKyPIYmJIYz0N+++uwdM7RnJukklhzJ54Q84vA4ZJkgs7lu5vqcw==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-define-polyfill-provider': 0.2.3_@babel+core@7.15.8 + core-js-compat: 3.18.0 + transitivePeerDependencies: + - supports-color + dev: true + /babel-plugin-polyfill-regenerator/0.2.2_@babel+core@7.15.0: resolution: {integrity: sha512-Goy5ghsc21HgPDFtzRkSirpZVW35meGoTmTOb2bxqdl60ghub4xOidgNTHaZfQ2FaxQsKmwvXtOAkcIS4SMBWg==} peerDependencies: @@ -9981,6 +11271,17 @@ packages: - supports-color dev: true + /babel-plugin-polyfill-regenerator/0.2.2_@babel+core@7.15.8: + resolution: {integrity: sha512-Goy5ghsc21HgPDFtzRkSirpZVW35meGoTmTOb2bxqdl60ghub4xOidgNTHaZfQ2FaxQsKmwvXtOAkcIS4SMBWg==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.15.8 + '@babel/helper-define-polyfill-provider': 0.2.3_@babel+core@7.15.8 + transitivePeerDependencies: + - supports-color + dev: true + /babel-plugin-react-docgen/4.2.1: resolution: {integrity: sha512-UQ0NmGHj/HAqi5Bew8WvNfCk8wSsmdgNd8ZdMjBCICtyCJCq9LiqgqvjCYe570/Wg7AQArSq1VQ60Dd/CHN7mQ==} dependencies: @@ -10061,6 +11362,25 @@ packages: '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.15.0 '@babel/plugin-syntax-top-level-await': 7.14.5_@babel+core@7.15.0 + /babel-preset-current-node-syntax/1.0.1_@babel+core@7.15.5: + resolution: {integrity: sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.15.5 + '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.15.5 + '@babel/plugin-syntax-bigint': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-class-properties': 7.12.13_@babel+core@7.15.5 + '@babel/plugin-syntax-import-meta': 7.10.4_@babel+core@7.15.5 + '@babel/plugin-syntax-json-strings': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4_@babel+core@7.15.5 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-numeric-separator': 7.10.4_@babel+core@7.15.5 + '@babel/plugin-syntax-object-rest-spread': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-optional-catch-binding': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.15.5 + '@babel/plugin-syntax-top-level-await': 7.14.5_@babel+core@7.15.5 + /babel-preset-jest/27.2.0_@babel+core@7.15.0: resolution: {integrity: sha512-z7MgQ3peBwN5L5aCqBKnF6iqdlvZvFUQynEhu0J+X9nHLU72jO3iY331lcYrg+AssJ8q7xsv5/3AICzVmJ/wvg==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} @@ -10071,6 +11391,16 @@ packages: babel-plugin-jest-hoist: 27.2.0 babel-preset-current-node-syntax: 1.0.1_@babel+core@7.15.0 + /babel-preset-jest/27.2.0_@babel+core@7.15.5: + resolution: {integrity: sha512-z7MgQ3peBwN5L5aCqBKnF6iqdlvZvFUQynEhu0J+X9nHLU72jO3iY331lcYrg+AssJ8q7xsv5/3AICzVmJ/wvg==} + engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.15.5 + babel-plugin-jest-hoist: 27.2.0 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.15.5 + /babel-preset-minify/0.3.0: resolution: {integrity: sha512-+VV2GWEyak3eDOmzT1DDMuqHrw3VbE9nBNkx2LLVs4pH/Me32ND8DRpVDd8IRvk1xX5p75nygyRPtkMh6GIAbQ==} dependencies: @@ -14974,7 +16304,7 @@ packages: dependencies: '@tootallnate/once': 1.1.2 agent-base: 6.0.2 - debug: 4.3.1 + debug: 4.3.2 transitivePeerDependencies: - supports-color @@ -15849,10 +17179,10 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.15.0 + '@babel/core': 7.15.5 '@jest/test-sequencer': 27.2.1 '@jest/types': 27.1.1 - babel-jest: 27.2.1_@babel+core@7.15.0 + babel-jest: 27.2.1_@babel+core@7.15.5 chalk: 4.1.2 deepmerge: 4.2.2 glob: 7.1.7 @@ -16353,17 +17683,17 @@ packages: resolution: {integrity: sha512-8CTg2YrgZuQbPHW7G0YvLTj4yTRXLmSeEO+ka3eC5lbu5dsTRyoDNS1L7x7EFUTyYQhFH9HQG1/TNlbUgR9Lug==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/core': 7.15.0 + '@babel/core': 7.15.5 '@babel/generator': 7.15.4 '@babel/parser': 7.15.7 - '@babel/plugin-syntax-typescript': 7.14.5_@babel+core@7.15.0 + '@babel/plugin-syntax-typescript': 7.14.5_@babel+core@7.15.5 '@babel/traverse': 7.15.4 '@babel/types': 7.15.6 '@jest/transform': 27.2.1 '@jest/types': 27.1.1 '@types/babel__traverse': 7.14.2 '@types/prettier': 2.3.2 - babel-preset-current-node-syntax: 1.0.1_@babel+core@7.15.0 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.15.5 chalk: 4.1.2 expect: 27.2.1 graceful-fs: 4.2.8 @@ -16397,7 +17727,7 @@ packages: dependencies: '@jest/types': 27.1.1 '@types/node': 16.9.4 - chalk: 4.1.1 + chalk: 4.1.2 graceful-fs: 4.2.8 is-ci: 3.0.0 picomatch: 2.3.0 @@ -17760,6 +19090,12 @@ packages: engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true + /nanoid/3.1.30: + resolution: {integrity: sha512-zJpuPDwOv8D2zq2WRoMe1HsfZthVewpel9CAvTfc/2mBD1uUT/agc5f7GHGWXlYkFvi1mVxe4IjvP2HNrop7nQ==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true + dev: true + /nanomatch/1.2.13: resolution: {integrity: sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==} engines: {node: '>=0.10.0'} @@ -17776,6 +19112,12 @@ packages: snapdragon: 0.8.2 to-regex: 3.0.2 + /nanospinner/0.3.2: + resolution: {integrity: sha512-ToZuxmiRuuNe3McB7CVzP7PCOhzWAy4qx6ndb5QWxJFp6INdg3n0mVm8f7HR6Fz8raRg3/vzglIZYrOSna8vkg==} + dependencies: + picocolors: 1.0.0 + dev: true + /native-url/0.2.6: resolution: {integrity: sha512-k4bDC87WtgrdD362gZz6zoiXQrl40kYlBmpfmSjwRO1VU0V5ccwJTlxuE72F6m3V0vc1xOf6n3UCP9QyerRqmA==} dependencies: @@ -18621,14 +19963,22 @@ packages: /photon/4.0.0: resolution: {integrity: sha512-RD3buB17jW9B+OOPjIqv/cE9imCyR+WJ4ALWtb1Q1mVg8OfYnHAyvdVTxa/+bZFNI2FWaQBKry3i1mItmW3H3A==} dependencies: - '@babel/runtime': 7.15.3 + '@babel/runtime': 7.15.4 crc32: 0.2.2 - debug: 4.3.1 + debug: 4.3.2 seed-random: 2.2.0 transitivePeerDependencies: - supports-color dev: false + /picocolors/0.2.1: + resolution: {integrity: sha512-cMlDqaLEqfSaW8Z7N5Jw+lyIW869EzT73/F5lhtY9cLGoVxSXznfgfXMO0Z5K0o0Q2TkTXq+0KFsdnSe3jDViA==} + dev: true + + /picocolors/1.0.0: + resolution: {integrity: sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==} + dev: true + /picomatch/2.2.3: resolution: {integrity: sha512-KpELjfwcCDUb9PeigTs2mBJzXUPzAuP2oPcA989He8Rte0+YUAjw1JVedDhuTKPkHjSYzMN3npC9luThGYEKdg==} engines: {node: '>=8.6'} @@ -18812,6 +20162,16 @@ packages: dependencies: postcss-values-parser: 4.0.0 + /postcss-custom-properties/11.0.0_postcss@8.3.11: + resolution: {integrity: sha512-Fhnx/QLt+CTt23A/KKVx1anZD9nmVpOxKCKv5owWacMoOsBXFhMAD6SZYbmPMH4nHdIeMUnWOvLZnlY4niS0sA==} + engines: {node: '>=10.0.0'} + peerDependencies: + postcss: ^8.1.0 + dependencies: + postcss: 8.3.11 + postcss-values-parser: 4.0.0 + dev: true + /postcss-discard-comments/4.0.2: resolution: {integrity: sha512-RJutN259iuRf3IW7GZyLM5Sw4GLTOH8FmsXBnv8Ab/Tc2k4SR4qbV4DNbyyY4+Sjo362SyDmW2DQ7lBSChrpkg==} engines: {node: '>=6.9.0'} @@ -18851,6 +20211,20 @@ packages: webpack: 5.51.1 dev: true + /postcss-loader/5.3.0_postcss@8.3.11+webpack@5.51.1: + resolution: {integrity: sha512-/+Z1RAmssdiSLgIZwnJHwBMnlABPgF7giYzTN2NOfr9D21IJZ4mQC1R2miwp80zno9M4zMD/umGI8cR+2EL5zw==} + engines: {node: '>= 10.13.0'} + peerDependencies: + postcss: ^7.0.0 || ^8.0.1 + webpack: ^5.0.0 + dependencies: + cosmiconfig: 7.0.1 + klona: 2.0.4 + postcss: 8.3.11 + semver: 7.3.5 + webpack: 5.51.1 + dev: true + /postcss-loader/5.3.0_webpack@5.51.1: resolution: {integrity: sha512-/+Z1RAmssdiSLgIZwnJHwBMnlABPgF7giYzTN2NOfr9D21IJZ4mQC1R2miwp80zno9M4zMD/umGI8cR+2EL5zw==} engines: {node: '>= 10.13.0'} @@ -19124,6 +20498,15 @@ packages: source-map: 0.6.1 supports-color: 6.1.0 + /postcss/8.3.11: + resolution: {integrity: sha512-hCmlUAIlUiav8Xdqw3Io4LcpA1DOt7h3LSTAC4G6JGHFFaWzI6qvFt9oilvl8BmkbBRX1IhM90ZAmpk68zccQA==} + engines: {node: ^10 || ^12 || >=14} + dependencies: + nanoid: 3.1.30 + picocolors: 1.0.0 + source-map-js: 0.6.2 + dev: true + /postcss/8.3.6: resolution: {integrity: sha512-wG1cc/JhRgdqB6WHEuyLTedf3KIRuD0hG6ldkFEZNCjRxiC+3i6kkWUUbiJQayP28iwG35cEmAbe98585BYV0A==} engines: {node: ^10 || ^12 || >=14} @@ -19136,6 +20519,10 @@ packages: resolution: {integrity: sha512-15vItUAbViaYrmaB/Pbw7z6qX2xENbFSTA7Ii4tgbPtasxm5v6ryKhKtL91tpWovDJzTiZqdwzhcFBCwiMVdVw==} dev: false + /preact/10.5.15: + resolution: {integrity: sha512-5chK29n6QcJc3m1lVrKQSQ+V7K1Gb8HeQY6FViQ5AxCAEGu3DaHffWNDkC9+miZgsLvbvU9rxbV1qinGHMHzqA==} + dev: false + /preact/10.5.7: resolution: {integrity: sha512-4oEpz75t/0UNcwmcsjk+BIcDdk68oao+7kxcpc1hQPNs2Oo3ZL9xFz8UBf350mxk/VEdD41L5b4l2dE3Ug3RYg==} dev: false @@ -19995,6 +21382,26 @@ packages: redux: 4.0.5 dev: false + /react-redux/7.2.5: + resolution: {integrity: sha512-Dt29bNyBsbQaysp6s/dN0gUodcq+dVKKER8Qv82UrpeygwYeX1raTtil7O/fftw/rFqzaf6gJhDZRkkZnn6bjg==} + peerDependencies: + react: ^16.8.3 || ^17 + react-dom: '*' + react-native: '*' + peerDependenciesMeta: + react-dom: + optional: true + react-native: + optional: true + dependencies: + '@babel/runtime': 7.15.4 + '@types/react-redux': 7.1.20 + hoist-non-react-statics: 3.3.2 + loose-envify: 1.4.0 + prop-types: 15.7.2 + react-is: 16.13.1 + dev: false + /react-refresh/0.8.3: resolution: {integrity: sha512-X8jZHc7nCMjaCqoU+V2I0cOhNW+QMBwSUkeXnTi8IPe6zaRWfn60ZzvFDZqWPfmSJfjub7dDW1SP0jaHWLu/hg==} engines: {node: '>=0.10.0'} @@ -21356,6 +22763,28 @@ packages: sass: 1.38.1 webpack: 5.51.1 + /sass-loader/11.1.1_sass@1.39.0+webpack@5.51.1: + resolution: {integrity: sha512-fOCp/zLmj1V1WHDZbUbPgrZhA7HKXHEqkslzB+05U5K9SbSbcmH91C7QLW31AsXikxUMaxXRhhcqWZAxUMLDyA==} + engines: {node: '>= 10.13.0'} + peerDependencies: + fibers: '>= 3.1.0' + node-sass: ^4.0.0 || ^5.0.0 || ^6.0.0 + sass: ^1.3.0 + webpack: ^5.0.0 + peerDependenciesMeta: + fibers: + optional: true + node-sass: + optional: true + sass: + optional: true + dependencies: + klona: 2.0.4 + neo-async: 2.6.2 + sass: 1.39.0 + webpack: 5.51.1 + dev: true + /sass-loader/12.1.0_sass@1.39.0: resolution: {integrity: sha512-FVJZ9kxVRYNZTIe2xhw93n3xJNYZADr+q69/s98l9nTCrWASo+DR2Ot0s5xTKQDDEosUkatsGeHxcH4QBp5bSg==} engines: {node: '>= 12.13.0'} @@ -21680,6 +23109,20 @@ packages: mico-spinner: 1.2.2 dev: true + /size-limit/6.0.3: + resolution: {integrity: sha512-bvZuNG1dPJ8GTkFq3lXkW8H1+ybVV3D7GecowAGlfbNO2T1Mcvy8kCoCpwVOWnq1wV+TraRUtExnQzIyyV94NQ==} + engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + hasBin: true + dependencies: + bytes-iec: 3.1.1 + chokidar: 3.5.2 + ci-job-number: 1.2.2 + globby: 11.0.4 + lilconfig: 2.0.3 + nanospinner: 0.3.2 + picocolors: 0.2.1 + dev: true + /slash/1.0.0: resolution: {integrity: sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=} engines: {node: '>=0.10.0'} @@ -22369,6 +23812,7 @@ packages: /svgo/1.3.2: resolution: {integrity: sha512-yhy/sQYxR5BkC98CY7o31VGsg014AKLEPxdfhora76l36hD9Rdy5NZA/Ocn6yayNPgSamYdtX2rFJdcv07AYVw==} engines: {node: '>=4.0.0'} + deprecated: This SVGO version is no longer supported. Upgrade to v2.x.x. hasBin: true dependencies: chalk: 2.4.2 @@ -23575,7 +25019,7 @@ packages: interpret: 2.2.0 rechoir: 0.7.1 v8-compile-cache: 2.3.0 - webpack: 5.51.1_webpack-cli@4.8.0 + webpack: 5.51.1 webpack-merge: 5.8.0 /webpack-dev-middleware/4.3.0_webpack@5.51.1: @@ -23967,6 +25411,7 @@ packages: /yargs-parser/20.2.4: resolution: {integrity: sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==} engines: {node: '>=10'} + dev: true /yargs-parser/20.2.9: resolution: {integrity: sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==} @@ -24037,7 +25482,7 @@ packages: require-directory: 2.1.1 string-width: 4.2.2 y18n: 5.0.8 - yargs-parser: 20.2.4 + yargs-parser: 20.2.9 /yargs/17.1.1: resolution: {integrity: sha512-c2k48R0PwKIqKhPMWjeiF6y2xY/gPMUlro0sgxqXpbOIohWiLNXWslsootttv7E1e73QPAMQSg5FeySbVcpsPQ==} diff --git a/projects/packages/search/.gitignore b/projects/packages/search/.gitignore index 554806723c0e3..61729d70d7563 100644 --- a/projects/packages/search/.gitignore +++ b/projects/packages/search/.gitignore @@ -1 +1,4 @@ +.cache/ +build/ +node_modules/ wordpress diff --git a/projects/packages/search/babel.config.js b/projects/packages/search/babel.config.js new file mode 100644 index 0000000000000..a1a416a062051 --- /dev/null +++ b/projects/packages/search/babel.config.js @@ -0,0 +1,43 @@ +/** + * A babel preset wrapper to set @babel/plugin-transform-runtime's absoluteRuntime to true. + * + * @param {string|Function} preset - The preset being wrapped. + * @returns {Function} The wrapped preset-function. + */ +function presetOverrideBabelPluginTransformRuntimeAbsoluteRuntime(preset) { + if ('string' === typeof preset) { + preset = require(preset); + } + return (api, opts) => { + const ret = preset(api, opts); + // Override the configuration for @babel/plugin-transform-runtime to set absoluteRuntime true. + // This prevents it from blowing up when other workspace projects are symlinked. + ret.plugins.forEach(p => { + if (Array.isArray(p) && /[\\/]@babel[\\/]plugin-transform-runtime[\\/]/.test(p[0])) { + p[1].absoluteRuntime = true; + } + }); + return ret; + }; +} + +const config = { + presets: [ + presetOverrideBabelPluginTransformRuntimeAbsoluteRuntime( + '@automattic/calypso-build/babel/default' + ), + ], + plugins: ['@babel/plugin-proposal-nullish-coalescing-operator'], + overrides: [ + { + test: './src/instant-search', + presets: [ + presetOverrideBabelPluginTransformRuntimeAbsoluteRuntime( + './src/instant-search/babel.config.js' + ), + ], + }, + ], +}; + +module.exports = config; diff --git a/projects/packages/search/package.json b/projects/packages/search/package.json new file mode 100644 index 0000000000000..6adf1dc585d12 --- /dev/null +++ b/projects/packages/search/package.json @@ -0,0 +1,57 @@ +{ + "name": "jetpack-search", + "version": "1.0.0-alpha", + "description": "Package for Jetpack Search products", + "main": "main.js", + "directories": { + "test": "tests" + }, + "scripts": { + "build-instant": "webpack --config ./webpack.instant.config.js", + "clean": "rm -rf build/*", + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/Automattic/jetpack-search.git" + }, + "author": "Automattic", + "license": "GPL-2.0-or-later", + "bugs": { + "url": "https://github.com/Automattic/jetpack-search/issues" + }, + "homepage": "https://github.com/Automattic/jetpack-search#readme", + "engines": { + "node": "^14.17.6 || ^16.7.0", + "pnpm": "^6.5.0", + "yarn": "use pnpm instead - see docs/yarn-upgrade.md" + }, + "dependencies": { + "@automattic/color-studio": "2.5.0", + "@wordpress/i18n": "4.2.2", + "fast-json-stable-stringify": "2.1.0", + "lodash": "4.17.21", + "photon": "4.0.0", + "preact": "10.5.15", + "q-flat": "1.0.7", + "qss": "2.0.3", + "react-redux": "7.2.5", + "redux": "4.1.1", + "refx": "3.1.1", + "strip": "3.0.0", + "tiny-lru": "7.0.6" + }, + "devDependencies": { + "@automattic/calypso-build": "9.0.0", + "@babel/core": "7.15.8", + "@babel/plugin-proposal-nullish-coalescing-operator": "7.14.5", + "@babel/preset-env": "7.15.8", + "@babel/preset-react": "7.14.5", + "@babel/preset-typescript": "7.15.0", + "@size-limit/preset-app": "6.0.3", + "@wordpress/dependency-extraction-webpack-plugin": "3.2.1", + "postcss": "8.3.11", + "size-limit": "6.0.3", + "webpack": "5.51.1" + } +} diff --git a/projects/packages/search/src/class-helper.php b/projects/packages/search/src/class-helper.php index 76ea607f65dfc..e59d4c097e4aa 100644 --- a/projects/packages/search/src/class-helper.php +++ b/projects/packages/search/src/class-helper.php @@ -1,10 +1,8 @@ $posts_per_page, 'siteId' => class_exists( 'Jetpack' ) && method_exists( 'Jetpack', 'get_option' ) ? Jetpack::get_option( 'id' ) : get_current_blog_id(), 'postTypes' => $post_type_labels, - 'webpackPublicPath' => plugins_url( '_inc/build/instant-search/', JETPACK__PLUGIN_FILE ), + 'webpackPublicPath' => plugins_url( '/build/instant-search/', __DIR__ ), 'isPhotonEnabled' => ( $is_wpcom || $is_jetpack_photon_enabled ) && ! $is_private_site, // config values related to private site support. @@ -904,4 +905,26 @@ public static function print_instant_search_sidebar() { setup(); + self::$instance = new static(); + self::$instance->setup( $blog_id ); } return self::$instance; } /** - * Perform various setup tasks for the class. - * - * Checks various pre-requisites and adds hooks. + * Performs setup tasks for the singleton. To be used exclusively after singleton instantitaion. * - * @since 5.0.0 + * @param string $blog_id Blog id. */ - public function setup() { - if ( ! Jetpack::is_connection_ready() || ! $this->is_search_supported() ) { - /** - * Fires when the Jetpack Search fails and would fallback to MySQL. - * - * @module search - * @since 7.9.0 - * - * @param string $reason Reason for Search fallback. - * @param mixed $data Data associated with the request, such as attempted search parameters. - */ - do_action( 'jetpack_search_abort', 'inactive', null ); - return; - } - - $this->jetpack_blog_id = Jetpack::get_option( 'id' ); - - if ( ! $this->jetpack_blog_id ) { - /** This action is documented in modules/search/class.jetpack-search.php */ - do_action( 'jetpack_search_abort', 'no_blog_id', null ); + public function setup( $blog_id ) { + if ( ! $blog_id ) { return; } - $this->load_php(); + $this->jetpack_blog_id = $blog_id; $this->init_hooks(); } /** - * Loads the php for this version of search + * Prevent __clone()'ing of this class. * - * @since 8.3.0 + * @since 5.0.0 */ - public function load_php() { - $this->base_load_php(); + public function __clone() { + wp_die( "Please don't __clone Jetpack_Search" ); } /** - * Loads the PHP common to all search. Should be called from extending classes. + * Prevent __wakeup()'ing of this class. + * + * @since 5.0.0 */ - protected function base_load_php() { - require_once __DIR__ . '/class.jetpack-search-template-tags.php'; - require_once JETPACK__PLUGIN_DIR . 'modules/widgets/search.php'; + public function __wakeup() { + wp_die( "Please don't __wakeup Jetpack_Search" ); } /** @@ -226,19 +168,6 @@ public function init_hooks() { add_action( 'jetpack_deactivate_module_search', array( $this, 'move_search_widgets_to_inactive' ) ); } - /** - * Is search supported on the current plan - * - * @since 6.0 - * Loads scripts for Tracks analytics library - */ - public function is_search_supported() { - if ( method_exists( 'Jetpack_Plan', 'supports' ) ) { - return Jetpack_Plan::supports( 'search' ); - } - return false; - } - /** * Does this site have a VIP index * Get the version number to use when loading the file. Allows us to bypass cache when developing. @@ -878,8 +807,6 @@ public function filter__add_date_filter_to_query( array $es_wp_query_args, WP_Qu * @return array Array of ES style query arguments. */ public function convert_wp_es_to_es_args( array $args ) { - jetpack_require_lib( 'jetpack-wpes-query-builder/jetpack-wpes-query-parser' ); - $defaults = array( 'blog_id' => get_current_blog_id(), 'query' => null, // Search phrase. @@ -1909,7 +1836,7 @@ public function track_widget_updates( $option, $old_value, $new_value ) { return; } - $tracking = new Automattic\Jetpack\Tracking(); + $tracking = new \Automattic\Jetpack\Tracking(); $tracking->tracks_record_event( wp_get_current_user(), sprintf( 'jetpack_search_widget_%s', $event['action'] ), diff --git a/projects/packages/search/src/initializers/class-initializer.php b/projects/packages/search/src/initializers/class-initializer.php new file mode 100644 index 0000000000000..aa118accc56c5 --- /dev/null +++ b/projects/packages/search/src/initializers/class-initializer.php @@ -0,0 +1,27 @@ + 405 ) + ); + } +} diff --git a/projects/packages/search/src/initializers/class-jetpack-initializer.php b/projects/packages/search/src/initializers/class-jetpack-initializer.php new file mode 100644 index 0000000000000..a4f68fb75065a --- /dev/null +++ b/projects/packages/search/src/initializers/class-jetpack-initializer.php @@ -0,0 +1,83 @@ +setup(); - } - - return self::$instance; - } - - /** - * Loads the php for this version of search - * - * @since 8.3.0 - */ - public function load_php() { - $this->base_load_php(); - - require_once __DIR__ . '/class-jetpack-search-settings.php'; - new Jetpack_Search_Settings(); - - if ( class_exists( 'WP_Customize_Manager' ) ) { - require_once __DIR__ . '/class-jetpack-search-customize.php'; - new Jetpack_Search_Customize(); - } - } - /** * Setup the various hooks needed for the plugin to take over search duties. * @@ -107,24 +72,32 @@ public function init_hooks() { * Loads assets for Jetpack Instant Search Prototype featuring Search As You Type experience. */ public function load_assets() { - $this->load_assets_with_parameters( '', JETPACK__PLUGIN_FILE ); + + // TODO: Move this into the initializer. + /** + * Location of built instant search assets, does not include trailing slash. + * + * @var string + */ + define( 'JETPACK_SEARCH_PLUGIN_DIRECTORY', dirname( dirname( __DIR__ ) ) ); + define( 'JETPACK_SEARCH_BUILD_DIRECTORY', 'jetpack-search/build/instant-search' ); + + $this->load_assets_with_parameters( + defined( 'JETPACK_SEARCH_BUILD_DIRECTORY' ) ? constant( 'JETPACK_SEARCH_BUILD_DIRECTORY' ) : '', + defined( 'JETPACK_SEARCH_PLUGIN_DIRECTORY' ) ? constant( 'JETPACK_SEARCH_PLUGIN_DIRECTORY' ) : '' + ); } /** * Loads assets according to parameters provided. * * @param string $path_prefix - Prefix for assets' relative paths. - * @param string $plugin_base_path - Base path for use in plugins_url. */ - public function load_assets_with_parameters( $path_prefix, $plugin_base_path ) { - $script_relative_path = $path_prefix . '_inc/build/instant-search/jp-search-main.bundle.js'; - - if ( ! file_exists( JETPACK__PLUGIN_DIR . $script_relative_path ) ) { - return; - } + public function load_assets_with_parameters( $path_prefix, $plugin_path ) { + $script_relative_path = $path_prefix . '/jp-search-main.bundle.js'; $script_version = Search\Helper::get_asset_version( $script_relative_path ); - $script_path = plugins_url( $script_relative_path, $plugin_base_path ); + $script_path = plugins_url( $script_relative_path, $plugin_path ); wp_enqueue_script( 'jetpack-instant-search', $script_path, array(), $script_version, true ); wp_set_script_translations( 'jetpack-instant-search', 'jetpack' ); $this->load_and_initialize_tracks(); @@ -132,10 +105,7 @@ public function load_assets_with_parameters( $path_prefix, $plugin_base_path ) { // It only inline the translations for the script, but does not load it. $this->inject_translation_for_script( - plugins_url( - $path_prefix . '_inc/build/instant-search/jp-search.chunk-main-payload.min.js', - $plugin_base_path - ) + plugins_url( $path_prefix . '/jp-search.chunk-main-payload.min.js', $plugin_path ) ); } @@ -238,8 +208,6 @@ public function action__parse_query() { return; } - jetpack_require_lib( 'jetpack-wpes-query-builder/jetpack-wpes-query-builder' ); - $builder = new Jetpack_WPES_Query_Builder(); $this->add_aggregations_to_es_query_builder( $this->aggregations, $builder ); $this->search_result = $this->instant_api( @@ -584,12 +552,12 @@ public function auto_config_excluded_post_types() { * @since 9.6.0 */ public function auto_config_woo_result_format() { - if ( ! method_exists( 'Jetpack', 'get_active_plugins' ) ) { - return false; - } - // Check if WooCommerce plugin is active (based on https://docs.woocommerce.com/document/create-a-plugin/). - if ( ! in_array( 'woocommerce/woocommerce.php', apply_filters( 'active_plugins', Jetpack::get_active_plugins() ), true ) ) { + if ( ! in_array( + 'woocommerce/woocommerce.php', + apply_filters( 'active_plugins', Search\Helper::get_active_plugins() ), + true + ) ) { return false; } @@ -626,18 +594,18 @@ public function remove_wp_migrated_widgets( $sidebars_widgets ) { empty( $this->old_sidebars_widgets ) || ! is_array( $this->old_sidebars_widgets ) || ! is_array( $sidebars_widgets ) - || ! array_key_exists( static::JETPACK_INSTANT_SEARCH_SIDEBAR, $sidebars_widgets ) - || ! array_key_exists( static::JETPACK_INSTANT_SEARCH_SIDEBAR, $this->old_sidebars_widgets ) + || ! array_key_exists( static::INSTANT_SEARCH_SIDEBAR, $sidebars_widgets ) + || ! array_key_exists( static::INSTANT_SEARCH_SIDEBAR, $this->old_sidebars_widgets ) // If the new Jetpack sidebar already has fewer widgets, skip execution. // Uses less than comparison for defensive programming. - || count( $sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ] ) <= count( $this->old_sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ] ) + || count( $sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ] ) <= count( $this->old_sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ] ) ) { return $sidebars_widgets; } - $lost_widgets = array_diff( $sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ], $this->old_sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ] ); - $sidebars_widgets['wp_inactive_widgets'] = array_merge( $lost_widgets, (array) $sidebars_widgets['wp_inactive_widgets'] ); - $sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ] = $this->old_sidebars_widgets[ static::JETPACK_INSTANT_SEARCH_SIDEBAR ]; + $lost_widgets = array_diff( $sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ], $this->old_sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ] ); + $sidebars_widgets['wp_inactive_widgets'] = array_merge( $lost_widgets, (array) $sidebars_widgets['wp_inactive_widgets'] ); + $sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ] = $this->old_sidebars_widgets[ static::INSTANT_SEARCH_SIDEBAR ]; // Reset $this->old_sidebars_widgets because we want to run the function only once after theme switch. $this->old_sidebars_widgets = null; diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/customizer-event-handler.jsx b/projects/packages/search/src/instant-search/components/customizer-event-handler.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/customizer-event-handler.jsx rename to projects/packages/search/src/instant-search/components/customizer-event-handler.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/dom-event-handler.jsx b/projects/packages/search/src/instant-search/components/dom-event-handler.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/dom-event-handler.jsx rename to projects/packages/search/src/instant-search/components/dom-event-handler.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/gridicon/index.jsx b/projects/packages/search/src/instant-search/components/gridicon/index.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/gridicon/index.jsx rename to projects/packages/search/src/instant-search/components/gridicon/index.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/gridicon/style.scss b/projects/packages/search/src/instant-search/components/gridicon/style.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/gridicon/style.scss rename to projects/packages/search/src/instant-search/components/gridicon/style.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/jetpack-colophon.jsx b/projects/packages/search/src/instant-search/components/jetpack-colophon.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/jetpack-colophon.jsx rename to projects/packages/search/src/instant-search/components/jetpack-colophon.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/jetpack-colophon.scss b/projects/packages/search/src/instant-search/components/jetpack-colophon.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/jetpack-colophon.scss rename to projects/packages/search/src/instant-search/components/jetpack-colophon.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/notice.jsx b/projects/packages/search/src/instant-search/components/notice.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/notice.jsx rename to projects/packages/search/src/instant-search/components/notice.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/notice.scss b/projects/packages/search/src/instant-search/components/notice.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/notice.scss rename to projects/packages/search/src/instant-search/components/notice.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/overlay.jsx b/projects/packages/search/src/instant-search/components/overlay.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/overlay.jsx rename to projects/packages/search/src/instant-search/components/overlay.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/overlay.scss b/projects/packages/search/src/instant-search/components/overlay.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/overlay.scss rename to projects/packages/search/src/instant-search/components/overlay.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/path-breadcrumbs.jsx b/projects/packages/search/src/instant-search/components/path-breadcrumbs.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/path-breadcrumbs.jsx rename to projects/packages/search/src/instant-search/components/path-breadcrumbs.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/path-breadcrumbs.scss b/projects/packages/search/src/instant-search/components/path-breadcrumbs.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/path-breadcrumbs.scss rename to projects/packages/search/src/instant-search/components/path-breadcrumbs.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/photon-image.jsx b/projects/packages/search/src/instant-search/components/photon-image.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/photon-image.jsx rename to projects/packages/search/src/instant-search/components/photon-image.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/post-type-icon.jsx b/projects/packages/search/src/instant-search/components/post-type-icon.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/post-type-icon.jsx rename to projects/packages/search/src/instant-search/components/post-type-icon.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/product-price.jsx b/projects/packages/search/src/instant-search/components/product-price.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/product-price.jsx rename to projects/packages/search/src/instant-search/components/product-price.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/product-price.scss b/projects/packages/search/src/instant-search/components/product-price.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/product-price.scss rename to projects/packages/search/src/instant-search/components/product-price.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/product-ratings.jsx b/projects/packages/search/src/instant-search/components/product-ratings.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/product-ratings.jsx rename to projects/packages/search/src/instant-search/components/product-ratings.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/product-ratings.scss b/projects/packages/search/src/instant-search/components/product-ratings.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/product-ratings.scss rename to projects/packages/search/src/instant-search/components/product-ratings.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/scroll-button.jsx b/projects/packages/search/src/instant-search/components/scroll-button.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/scroll-button.jsx rename to projects/packages/search/src/instant-search/components/scroll-button.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/scroll-button.scss b/projects/packages/search/src/instant-search/components/scroll-button.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/scroll-button.scss rename to projects/packages/search/src/instant-search/components/scroll-button.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-app.jsx b/projects/packages/search/src/instant-search/components/search-app.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-app.jsx rename to projects/packages/search/src/instant-search/components/search-app.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-app.scss b/projects/packages/search/src/instant-search/components/search-app.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-app.scss rename to projects/packages/search/src/instant-search/components/search-app.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-box.jsx b/projects/packages/search/src/instant-search/components/search-box.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-box.jsx rename to projects/packages/search/src/instant-search/components/search-box.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-box.scss b/projects/packages/search/src/instant-search/components/search-box.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-box.scss rename to projects/packages/search/src/instant-search/components/search-box.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-controls.jsx b/projects/packages/search/src/instant-search/components/search-controls.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-controls.jsx rename to projects/packages/search/src/instant-search/components/search-controls.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-controls.scss b/projects/packages/search/src/instant-search/components/search-controls.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-controls.scss rename to projects/packages/search/src/instant-search/components/search-controls.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-filter.jsx b/projects/packages/search/src/instant-search/components/search-filter.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-filter.jsx rename to projects/packages/search/src/instant-search/components/search-filter.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-filters.jsx b/projects/packages/search/src/instant-search/components/search-filters.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-filters.jsx rename to projects/packages/search/src/instant-search/components/search-filters.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-filters.scss b/projects/packages/search/src/instant-search/components/search-filters.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-filters.scss rename to projects/packages/search/src/instant-search/components/search-filters.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-form.jsx b/projects/packages/search/src/instant-search/components/search-form.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-form.jsx rename to projects/packages/search/src/instant-search/components/search-form.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-comments.jsx b/projects/packages/search/src/instant-search/components/search-result-comments.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-comments.jsx rename to projects/packages/search/src/instant-search/components/search-result-comments.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-comments.scss b/projects/packages/search/src/instant-search/components/search-result-comments.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-comments.scss rename to projects/packages/search/src/instant-search/components/search-result-comments.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-expanded.jsx b/projects/packages/search/src/instant-search/components/search-result-expanded.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-expanded.jsx rename to projects/packages/search/src/instant-search/components/search-result-expanded.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-expanded.scss b/projects/packages/search/src/instant-search/components/search-result-expanded.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-expanded.scss rename to projects/packages/search/src/instant-search/components/search-result-expanded.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-minimal.jsx b/projects/packages/search/src/instant-search/components/search-result-minimal.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-minimal.jsx rename to projects/packages/search/src/instant-search/components/search-result-minimal.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-minimal.scss b/projects/packages/search/src/instant-search/components/search-result-minimal.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-minimal.scss rename to projects/packages/search/src/instant-search/components/search-result-minimal.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-product.jsx b/projects/packages/search/src/instant-search/components/search-result-product.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-product.jsx rename to projects/packages/search/src/instant-search/components/search-result-product.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result-product.scss b/projects/packages/search/src/instant-search/components/search-result-product.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result-product.scss rename to projects/packages/search/src/instant-search/components/search-result-product.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result.jsx b/projects/packages/search/src/instant-search/components/search-result.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result.jsx rename to projects/packages/search/src/instant-search/components/search-result.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-result.scss b/projects/packages/search/src/instant-search/components/search-result.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-result.scss rename to projects/packages/search/src/instant-search/components/search-result.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-results.jsx b/projects/packages/search/src/instant-search/components/search-results.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-results.jsx rename to projects/packages/search/src/instant-search/components/search-results.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-results.scss b/projects/packages/search/src/instant-search/components/search-results.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-results.scss rename to projects/packages/search/src/instant-search/components/search-results.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-sort.jsx b/projects/packages/search/src/instant-search/components/search-sort.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-sort.jsx rename to projects/packages/search/src/instant-search/components/search-sort.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/search-sort.scss b/projects/packages/search/src/instant-search/components/search-sort.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/search-sort.scss rename to projects/packages/search/src/instant-search/components/search-sort.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/sidebar.jsx b/projects/packages/search/src/instant-search/components/sidebar.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/sidebar.jsx rename to projects/packages/search/src/instant-search/components/sidebar.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/sidebar.scss b/projects/packages/search/src/instant-search/components/sidebar.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/sidebar.scss rename to projects/packages/search/src/instant-search/components/sidebar.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/test/.eslintrc.js b/projects/packages/search/src/instant-search/components/test/.eslintrc.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/test/.eslintrc.js rename to projects/packages/search/src/instant-search/components/test/.eslintrc.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/test/README.md b/projects/packages/search/src/instant-search/components/test/README.md similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/test/README.md rename to projects/packages/search/src/instant-search/components/test/README.md diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/test/__snapshots__/notice.test.js.snap b/projects/packages/search/src/instant-search/components/test/__snapshots__/notice.test.js.snap similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/test/__snapshots__/notice.test.js.snap rename to projects/packages/search/src/instant-search/components/test/__snapshots__/notice.test.js.snap diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/test/notice.test.js b/projects/packages/search/src/instant-search/components/test/notice.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/test/notice.test.js rename to projects/packages/search/src/instant-search/components/test/notice.test.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/test/photon-image.test.js b/projects/packages/search/src/instant-search/components/test/photon-image.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/test/photon-image.test.js rename to projects/packages/search/src/instant-search/components/test/photon-image.test.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/widget-area-container.jsx b/projects/packages/search/src/instant-search/components/widget-area-container.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/widget-area-container.jsx rename to projects/packages/search/src/instant-search/components/widget-area-container.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/components/widget-area-container.scss b/projects/packages/search/src/instant-search/components/widget-area-container.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/components/widget-area-container.scss rename to projects/packages/search/src/instant-search/components/widget-area-container.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/external/query-string-decode.js b/projects/packages/search/src/instant-search/external/query-string-decode.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/external/query-string-decode.js rename to projects/packages/search/src/instant-search/external/query-string-decode.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/index.jsx b/projects/packages/search/src/instant-search/index.jsx similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/index.jsx rename to projects/packages/search/src/instant-search/index.jsx diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/api.js b/projects/packages/search/src/instant-search/lib/api.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/api.js rename to projects/packages/search/src/instant-search/lib/api.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/array-overlap.js b/projects/packages/search/src/instant-search/lib/array-overlap.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/array-overlap.js rename to projects/packages/search/src/instant-search/lib/array-overlap.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/colors.js b/projects/packages/search/src/instant-search/lib/colors.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/colors.js rename to projects/packages/search/src/instant-search/lib/colors.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/constants.js b/projects/packages/search/src/instant-search/lib/constants.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/constants.js rename to projects/packages/search/src/instant-search/lib/constants.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/customize.js b/projects/packages/search/src/instant-search/lib/customize.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/customize.js rename to projects/packages/search/src/instant-search/lib/customize.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/dom.js b/projects/packages/search/src/instant-search/lib/dom.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/dom.js rename to projects/packages/search/src/instant-search/lib/dom.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/dummy-debug.js b/projects/packages/search/src/instant-search/lib/dummy-debug.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/dummy-debug.js rename to projects/packages/search/src/instant-search/lib/dummy-debug.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/filters.js b/projects/packages/search/src/instant-search/lib/filters.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/filters.js rename to projects/packages/search/src/instant-search/lib/filters.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/hooks/use-photon.js b/projects/packages/search/src/instant-search/lib/hooks/use-photon.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/hooks/use-photon.js rename to projects/packages/search/src/instant-search/lib/hooks/use-photon.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/query-string.js b/projects/packages/search/src/instant-search/lib/query-string.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/query-string.js rename to projects/packages/search/src/instant-search/lib/query-string.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/sort.js b/projects/packages/search/src/instant-search/lib/sort.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/sort.js rename to projects/packages/search/src/instant-search/lib/sort.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/styles/_helper.scss b/projects/packages/search/src/instant-search/lib/styles/_helper.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/styles/_helper.scss rename to projects/packages/search/src/instant-search/lib/styles/_helper.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/styles/_mixins.scss b/projects/packages/search/src/instant-search/lib/styles/_mixins.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/styles/_mixins.scss rename to projects/packages/search/src/instant-search/lib/styles/_mixins.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/styles/_variables.scss b/projects/packages/search/src/instant-search/lib/styles/_variables.scss similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/styles/_variables.scss rename to projects/packages/search/src/instant-search/lib/styles/_variables.scss diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/test-helpers/tiny-lru.mock.js b/projects/packages/search/src/instant-search/lib/test-helpers/tiny-lru.mock.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/test-helpers/tiny-lru.mock.js rename to projects/packages/search/src/instant-search/lib/test-helpers/tiny-lru.mock.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/test/.eslintrc.js b/projects/packages/search/src/instant-search/lib/test/.eslintrc.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/test/.eslintrc.js rename to projects/packages/search/src/instant-search/lib/test/.eslintrc.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/test/api.test.js b/projects/packages/search/src/instant-search/lib/test/api.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/test/api.test.js rename to projects/packages/search/src/instant-search/lib/test/api.test.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/test/filters.test.js b/projects/packages/search/src/instant-search/lib/test/filters.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/test/filters.test.js rename to projects/packages/search/src/instant-search/lib/test/filters.test.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/lib/tracks.js b/projects/packages/search/src/instant-search/lib/tracks.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/lib/tracks.js rename to projects/packages/search/src/instant-search/lib/tracks.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/loader.js b/projects/packages/search/src/instant-search/loader.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/loader.js rename to projects/packages/search/src/instant-search/loader.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/set-webpack-public-path.js b/projects/packages/search/src/instant-search/set-webpack-public-path.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/set-webpack-public-path.js rename to projects/packages/search/src/instant-search/set-webpack-public-path.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/actions.js b/projects/packages/search/src/instant-search/store/actions.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/actions.js rename to projects/packages/search/src/instant-search/store/actions.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/effects.js b/projects/packages/search/src/instant-search/store/effects.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/effects.js rename to projects/packages/search/src/instant-search/store/effects.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/index.js b/projects/packages/search/src/instant-search/store/index.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/index.js rename to projects/packages/search/src/instant-search/store/index.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/reducer/api.js b/projects/packages/search/src/instant-search/store/reducer/api.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/reducer/api.js rename to projects/packages/search/src/instant-search/store/reducer/api.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/reducer/history.js b/projects/packages/search/src/instant-search/store/reducer/history.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/reducer/history.js rename to projects/packages/search/src/instant-search/store/reducer/history.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/reducer/index.js b/projects/packages/search/src/instant-search/store/reducer/index.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/reducer/index.js rename to projects/packages/search/src/instant-search/store/reducer/index.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/reducer/query-string.js b/projects/packages/search/src/instant-search/store/reducer/query-string.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/reducer/query-string.js rename to projects/packages/search/src/instant-search/store/reducer/query-string.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/reducer/server-options.js b/projects/packages/search/src/instant-search/store/reducer/server-options.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/reducer/server-options.js rename to projects/packages/search/src/instant-search/store/reducer/server-options.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/selectors.js b/projects/packages/search/src/instant-search/store/selectors.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/selectors.js rename to projects/packages/search/src/instant-search/store/selectors.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/test/.eslintrc.js b/projects/packages/search/src/instant-search/store/test/.eslintrc.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/test/.eslintrc.js rename to projects/packages/search/src/instant-search/store/test/.eslintrc.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/test/reducer.test.js b/projects/packages/search/src/instant-search/store/test/reducer.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/test/reducer.test.js rename to projects/packages/search/src/instant-search/store/test/reducer.test.js diff --git a/projects/plugins/jetpack/modules/search/instant-search/store/test/selectors.test.js b/projects/packages/search/src/instant-search/store/test/selectors.test.js similarity index 100% rename from projects/plugins/jetpack/modules/search/instant-search/store/test/selectors.test.js rename to projects/packages/search/src/instant-search/store/test/selectors.test.js diff --git a/projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-builder.php b/projects/packages/search/src/wpes/query-builder.php similarity index 99% rename from projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-builder.php rename to projects/packages/search/src/wpes/query-builder.php index d4f1459b6a31d..71910d8f72414 100644 --- a/projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-builder.php +++ b/projects/packages/search/src/wpes/query-builder.php @@ -22,8 +22,9 @@ * */ -class Jetpack_WPES_Query_Builder { +namespace Automattic\Jetpack\Search\WPES; +class Query_Builder { protected $es_filters = array(); // Custom boosting with function_score diff --git a/projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-parser.php b/projects/packages/search/src/wpes/query-parser.php similarity index 98% rename from projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-parser.php rename to projects/packages/search/src/wpes/query-parser.php index 979a22998f28a..36895f9312733 100644 --- a/projects/plugins/jetpack/_inc/lib/jetpack-wpes-query-builder/jetpack-wpes-query-parser.php +++ b/projects/packages/search/src/wpes/query-parser.php @@ -30,7 +30,6 @@ * * Example usage (from Search on Reader Manage): * - * require_lib( 'jetpack-wpes-query-builder/jetpack-wpes-search-query-parser' ); * $parser = new Jetpack_WPES_Search_Query_Parser( $args['q'], array( $lang ) ); * * //author @@ -107,10 +106,9 @@ * */ -jetpack_require_lib( 'jetpack-wpes-query-builder' ); - -class Jetpack_WPES_Search_Query_Parser extends Jetpack_WPES_Query_Builder { +namespace Automattic\Jetpack\Search\WPES; +class Query_Parser extends Query_Builder { protected $orig_query = ''; protected $current_query = ''; protected $langs; diff --git a/projects/packages/search/webpack.config.js b/projects/packages/search/webpack.config.js new file mode 100644 index 0000000000000..0cd3d77c94852 --- /dev/null +++ b/projects/packages/search/webpack.config.js @@ -0,0 +1,6 @@ +/** + * Internal dependencies + */ +const instantSearchConfig = require('./webpack.instant.config'); + +module.exports = [instantSearchConfig]; diff --git a/projects/packages/search/webpack.helpers.js b/projects/packages/search/webpack.helpers.js new file mode 100644 index 0000000000000..1a78d4b3b30c6 --- /dev/null +++ b/projects/packages/search/webpack.helpers.js @@ -0,0 +1,31 @@ +/** + * External dependencies + */ +const webpack = require( 'webpack' ); + +/** + * Returns an instance of the DefinePlugin that adds color-studio colors as literals. + * + * @returns {object} DefinePlugin instance. + */ +function definePaletteColorsAsStaticVariables() { + return new webpack.DefinePlugin( { + // Replace palette colors as individual literals in the bundle. + PALETTE: ( () => { + const colors = require( '@automattic/color-studio' ).colors; + const stringifiedColors = {}; + + // DefinePlugin replaces the values as unescaped text. + // We therefore need to double-quote each value, to ensure it ends up as a string. + for ( const color in colors ) { + stringifiedColors[ color ] = `"${ colors[ color ] }"`; + } + + return stringifiedColors; + } )(), + } ); +} + +module.exports = { + definePaletteColorsAsStaticVariables, +}; diff --git a/projects/plugins/jetpack/tools/webpack.config.search.js b/projects/packages/search/webpack.instant.config.js similarity index 50% rename from projects/plugins/jetpack/tools/webpack.config.search.js rename to projects/packages/search/webpack.instant.config.js index acc5d877eefdd..2c1357df03952 100644 --- a/projects/plugins/jetpack/tools/webpack.config.search.js +++ b/projects/packages/search/webpack.instant.config.js @@ -1,61 +1,47 @@ /** * External dependencies */ -const getBaseWebpackConfig = require( '@automattic/calypso-build/webpack.config.js' ); -const DependencyExtractionWebpackPlugin = require( '@wordpress/dependency-extraction-webpack-plugin' ); +const DependencyExtractionWebpackPlugin = require('@wordpress/dependency-extraction-webpack-plugin'); +const getBaseWebpackConfig = require('@automattic/calypso-build/webpack.config.js'); +const path = require('path'); const { defaultRequestToExternal, defaultRequestToHandle, -} = require( '@wordpress/dependency-extraction-webpack-plugin/lib/util' ); -const path = require( 'path' ); -const webpack = require( 'webpack' ); - -/** - * Internal dependencies - */ -const { definePaletteColorsAsStaticVariables } = require( './webpack.helpers' ); +} = require('@wordpress/dependency-extraction-webpack-plugin/lib/util'); +const { definePaletteColorsAsStaticVariables } = require('./webpack.helpers'); const isDevelopment = process.env.NODE_ENV !== 'production'; -const baseWebpackConfig = getBaseWebpackConfig( - { WP: false }, - { - entry: { - main: path.join( __dirname, '../modules/search/instant-search/loader.js' ), - }, - // Putting a cache buster in the query string is not documented, but confirmed by the author of Webpack. - // `But better use the hash in filename and use no query parameter.` - // The reason probably is because it's not the best way to do cache busting. - // More information: https://github.com/webpack/webpack/issues/2329 - 'output-chunk-filename': 'jp-search.chunk-[name].min.js?ver=[contenthash]', - 'output-filename': 'jp-search-[name].bundle.js', - 'output-path': path.join( __dirname, '../_inc/build/instant-search' ), - // Calypso-build defaults this to "window", which breaks things if no library.name is set. - 'output-library-target': '', - } -); - /** * Determines if the module import request should be externalized. * * @param {string} request - Requested module * @returns {(string|string[]|undefined)} Script global */ -function requestToExternal( request ) { +function requestToExternalForInstantSearch(request) { // Prevent React from being externalized. This ensures that React will be properly aliased to preact/compat. - if ( request === 'react' || request === 'react-dom' ) { + if (request === 'react' || request === 'react-dom') { return; } - return defaultRequestToExternal( request ); + return defaultRequestToExternal(request); } -const moduleConfig = { ...baseWebpackConfig.module }; -// NOTE: tiny-lru publishes non-ES5 as a browser target. It's necessary to let babel-loader transpile this module. -moduleConfig.rules[ 0 ].exclude = /[\\/]node_modules[\\/](?!(\.pnpm|tiny-lru)[\\/])/; +const baseWebpackConfig = getBaseWebpackConfig( + { WP: false }, + { + entry: { + main: path.join(__dirname, 'src/instant-search/loader.js'), + }, + 'output-chunk-filename': 'jp-search.chunk-[name].[contenthash:20].min.js', + 'output-filename': 'jp-search-[name].bundle.js', + 'output-path': path.join(__dirname, 'build/instant-search'), + // Calypso-build defaults this to "window", which breaks things if no library.name is set. + 'output-library-target': '', + } +); -module.exports = { +const instantSearchConfig = { ...baseWebpackConfig, - module: moduleConfig, resolve: { ...baseWebpackConfig.resolve, alias: { @@ -65,32 +51,28 @@ module.exports = { 'react-dom': 'preact/compat', // Must be aliased after test-utils fs: false, }, - modules: [ - path.resolve( __dirname, '../_inc/client' ), - path.resolve( __dirname, '../node_modules' ), - 'node_modules', - ], + modules: [path.resolve(__dirname, 'node_modules'), 'node_modules'], // We want the compiled version, not the "calypso:src" sources. - mainFields: baseWebpackConfig.resolve.mainFields.filter( entry => 'calypso:src' !== entry ), + mainFields: baseWebpackConfig.resolve.mainFields.filter(entry => 'calypso:src' !== entry), }, devtool: isDevelopment ? 'source-map' : false, plugins: [ ...baseWebpackConfig.plugins, // Replace 'debug' module with a dummy implementation in production - ...( isDevelopment + ...(isDevelopment ? [] : [ new webpack.NormalModuleReplacementPlugin( /^debug$/, - path.resolve( __dirname, '../modules/search/instant-search/lib/dummy-debug' ) + path.resolve(__dirname, 'src/instant-search/lib/dummy-debug') ), - ] ), - new DependencyExtractionWebpackPlugin( { + ]), + new DependencyExtractionWebpackPlugin({ injectPolyfill: true, useDefaults: false, - requestToExternal, + requestToExternal: requestToExternalForInstantSearch, requestToHandle: defaultRequestToHandle, - } ), + }), definePaletteColorsAsStaticVariables(), ], optimization: { @@ -104,3 +86,11 @@ module.exports = { concatenateModules: false, }, }; + +// NOTE: tiny-lru publishes non-ES5 as a browser target. It's necessary to let babel-loader transpile this module. +instantSearchConfig.module.rules[0].exclude = /[\\/]node_modules[\\/](?!(\.pnpm|tiny-lru)[\\/])/; + +// Do not try to reassign NODE_ENV during execution. This will raise a warning during build. +delete instantSearchConfig.plugins[0].definitions['process.env.NODE_ENV']; + +module.exports = instantSearchConfig; diff --git a/projects/plugins/jetpack/composer.lock b/projects/plugins/jetpack/composer.lock index 227f6496baebd..143bd1a18816a 100644 --- a/projects/plugins/jetpack/composer.lock +++ b/projects/plugins/jetpack/composer.lock @@ -4878,5 +4878,5 @@ "platform-overrides": { "ext-intl": "0.0.0" }, - "plugin-api-version": "2.0.0" + "plugin-api-version": "2.1.0" } diff --git a/projects/plugins/jetpack/modules/search.php b/projects/plugins/jetpack/modules/search.php index c902904874391..d396d9c650070 100644 --- a/projects/plugins/jetpack/modules/search.php +++ b/projects/plugins/jetpack/modules/search.php @@ -14,9 +14,4 @@ * @package automattic/jetpack */ -// Include everything. -require_once __DIR__ . '/search/class.jetpack-search.php'; -require_once __DIR__ . '/search/class-jetpack-search-customberg.php'; - -Jetpack_Search::instance(); -Automattic\Jetpack\Search\Jetpack_Search_Customberg::instance(); +Automattic\Jetpack\Search\Jetpack_Initializer::initialize(); diff --git a/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php b/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php index f7fe5a6db7ca1..fbb6d7d4e37b6 100644 --- a/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php +++ b/projects/plugins/jetpack/modules/search/class-jetpack-search-customberg.php @@ -67,7 +67,7 @@ public function add_wp_admin_page() { // Only load assets if Customberg is supported. if ( $this->wp_supports_customberg() ) { add_action( "admin_print_scripts-$hook", array( $this, 'load_assets' ) ); - add_action( 'admin_footer', array( 'Helper', 'print_instant_search_sidebar' ) ); + add_action( 'admin_footer', array( 'Automattic\Jetpack\Search\Helper', 'print_instant_search_sidebar' ) ); } else { add_action( "admin_print_scripts-$hook", array( $this, 'add_redirect_if_necessary' ) ); } diff --git a/projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php b/projects/plugins/jetpack/modules/search/class-jetpack-search-template-tags.php similarity index 100% rename from projects/plugins/jetpack/modules/search/class.jetpack-search-template-tags.php rename to projects/plugins/jetpack/modules/search/class-jetpack-search-template-tags.php diff --git a/projects/plugins/jetpack/modules/widgets/search.php b/projects/plugins/jetpack/modules/widgets/search.php index 45b51e4105a95..c8aaad9b15acf 100644 --- a/projects/plugins/jetpack/modules/widgets/search.php +++ b/projects/plugins/jetpack/modules/widgets/search.php @@ -1,6 +1,6 @@ update_search_results_aggregations(); + Automattic\Jetpack\Search\Classic_Search::instance( $blog_id )->update_search_results_aggregations(); } - $filters = Jetpack_Search::instance()->get_filters(); + $filters = Automattic\Jetpack\Search\Classic_Search::instance( $blog_id )->get_filters(); if ( ! Jetpack_Search_Helpers::are_filters_by_widget_disabled() && ! $this->should_display_sitewide_filters() ) { $filters = array_filter( $filters, array( $this, 'is_for_current_widget' ) ); @@ -421,11 +427,13 @@ public function widget_non_instant( $args, $instance ) { * @param array $instance The current widget instance. */ public function widget_instant( $args, $instance ) { + $blog_id = Jetpack::get_option( 'id' ); + if ( Jetpack_Search_Helpers::should_rerun_search_in_customizer_preview() ) { - Jetpack_Search::instance()->update_search_results_aggregations(); + Automattic\Jetpack\Search\Instant_Search::instance( $blog_id )->update_search_results_aggregations(); } - $filters = Jetpack_Search::instance()->get_filters(); + $filters = Automattic\Jetpack\Search\Instant_Search::instance( $blog_id )->get_filters(); if ( ! Jetpack_Search_Helpers::are_filters_by_widget_disabled() && ! $this->should_display_sitewide_filters() ) { $filters = array_filter( $filters, array( $this, 'is_for_current_widget' ) ); } diff --git a/projects/plugins/jetpack/package.json b/projects/plugins/jetpack/package.json index 61bf5f4412216..cbda4fa87d31c 100644 --- a/projects/plugins/jetpack/package.json +++ b/projects/plugins/jetpack/package.json @@ -29,7 +29,7 @@ "build-production-php": "COMPOSER_MIRROR_PATH_REPOS=1 COMPOSER_ROOT_VERSION=dev-master composer install -o --no-dev --classmap-authoritative --prefer-dist", "build-production-search": "NODE_ENV=production BABEL_ENV=production pnpm run build-search && pnpm run validate-es10 -- ./_inc/build/instant-search/", "build-search": "pnpm run clean-search && pnpm run build-search-app && pnpm run build-search-configure", - "build-search-app": "webpack --config ./tools/webpack.config.search.js", + "build-search-app": "echo 'Instant Search build not yet implemented in Jetpack plugin, build manually in Search package.'", "build-search-configure": "webpack --config ./tools/webpack.config.search-configure.js", "build-widget-visibility": "webpack --config ./tools/webpack.config.widget-visibility.js", "clean": "pnpm run clean-client && pnpm run clean-extensions && pnpm run clean-composer",